growlf wrote:Hello all,
I was a bit frustrated with some of the hue bridge options (not properly handling to UPnP requests, malformed responses, etc.) so I set out to write a better hue hub emulator. That was several months ago, and I ended up distracted with other work. That said, I finally finished something up, and I think it might be useful to the Indigo community.
1. It allows you to define devices very easily in a config file.
2. You can point it at your Indigo server (assuming web services are active) and it will read the devices and make them all available as hue bulbs.
3. "Weird" devices can be controlled by creating virtual on/off devices. Works fine on my garage door.
4. For most people with lights, it should take about a minute to setup and run, assuming you can run a python script.
Here it is:
https://github.com/johnray/hueAndMeAnyway, works for me. I'll update it and fix bugs (maybe add error handling) as time allows.
Best wishes,
John
Awesome work. I haven't been able to get this to load for some off reason. I keep getting a traceback related to UPNP and address binding. I have tried various ports for the "server" section, with no luck. I have validated I do not have any services running on the ports I tried. Does this need to use an IP different than the main IP of the machine? Im running this on the same machine as Indigo. I tried the loopback IP (127.0.0.1) as well as the LAN IP of the computer. Ive also tried "guess" as the first attempt
bash-3.2# python hueAndMe.py
Loaded 0 devices from config file.
Adding Dining Room...
Loaded 1 devices from Indigo.
Exception in thread Thread-1:
Traceback (most recent call last):
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 810, in __bootstrap_inner
self.run()
File "hueAndMe.py", line 58, in run
sock.bind(('', UPNP_PORT))
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py", line 228, in meth
return getattr(self._sock,name)(*args)
error: [Errno 48] Address already in use
Thanks,
James