Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using multiple SKY-Q boxes #31

Open
darkbluedad opened this issue Aug 10, 2022 · 3 comments
Open

Using multiple SKY-Q boxes #31

darkbluedad opened this issue Aug 10, 2022 · 3 comments

Comments

@darkbluedad
Copy link

Haven't tested it or anything, but this commit might help. Obviously you need to add your skybox-002 in appliances again. It won't work for any 'scenes' eg netflix, spotify etc, as then the endpointId becomes the scene name. If you wanted them, you could add them in appliances as well, with a different applianceId, and different friendly name. Then you could edit the code to something like:

if endpointID == 'skybox-002' or endpointID == 'skyq-netflix-2':

Hope that helps, let me know if it works.

Originally posted by @ndg63276 in #11 (comment)

@darkbluedad
Copy link
Author

To make the code more elegant I'm using a consistent 5 character prefix for the ID for appliance/scenes so I can check the first 5 characters of endpointId to select the Port.

@darkbluedad
Copy link
Author

port = int(environ['PORT'])
zzzzz = endpointId[:5]
if zzzzz == 'study':
port = int(environ['PORTSTUDY'])
s.connect((environ['HOST'], port))

@darkbluedad
Copy link
Author

Just realised that I can use wake-up scenes to avoid having to use sky’s sleep function. I can run an Alexa routine to power down the boxes overnight and wake them again in the morning.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant