2014-01-11, 03:59
OK, so I did one more try and FINALLY got it working. Here's what I did in case anyone else has a Hue Lights setup and would like to control them with Cinema Experience. Also, thanks opeters for your help! You got me on the right track!
First off, I downloaded the newest version 3.0.7 from github and noticed there was some changes to the home_automation.py file (this may have helped)
Second, I used the following code which seems to work well:
Of course, the Hue Bridge IP and Key need to be changed to your setup, and in the body content you can use your own custom settings.
Finally, I inserted the following line near the top of the code:
Now, everything works like a charm. Thanks again!
First off, I downloaded the newest version 3.0.7 from github and noticed there was some changes to the home_automation.py file (this may have helped)
Second, I used the following code which seems to work well:
Code:
connection = httplib.HTTPConnection('MYHUEBRIDGEIP')
body_content = '{"on":true}'
connection.request('PUT', '/api/MYHUEKEY/groups/7/action', body_content)
result = connection.getresponse()
Of course, the Hue Bridge IP and Key need to be changed to your setup, and in the body content you can use your own custom settings.
Finally, I inserted the following line near the top of the code:
Code:
import httplib
Now, everything works like a charm. Thanks again!