Page 1 of 1

Multiple Philips Hue hubs

PostPosted: Sat Jan 24, 2015 4:19 am
by crsarnelli
Hello All,

We are in the process of our home renovation, so far Indigo and Nathan's plug in has been working exceptionally.

It seems that we may go over the 50 lights hue hub limit when everything is all completed. For that reason I was wondering if I will be able to control my Hue lights through Indigo having at least two hue hubs or if there is a way to have two copies of the hue plug in for indigo to control the lights with two different hue hubs?

Thank you,

Carlos

Re: Multiple Philips Hue hubs

PostPosted: Mon Jan 26, 2015 3:04 am
by nsheldon
Hi Carlos.

I'm glad the plugin is working well for you guys so far.

Unfortunately, the Hue Lights plugin only supports 1 Hue hub at a time. It'd probably be possible to copy the plugin, edit the "info.plist" file and load the copy as a separate instance of the Hue Lights plugin, though I haven't tried that. If you duplicated the plugin (or downloaded another copy), before installing it, you'd need to right-click on the plugin icon and choose "Show Package Contents". Inside the "Contents" folder, you'd need to edit the "info.plist" file. Xcode makes it easy to edit, as it has a plist editor built-in, but TextEdit will work too. You'd need to change the Bundle Display Name (to perhaps to "Hue Lights 2") and the Bundle Identifier (to perhaps com.nathansheldon.indigoplugin.HueLights2"). Once you've changed those values, install the plugin (by double-clicking on the plugin icon while on the Indigo server machine). You should be prompted to setup the plugin just like you did with the Hue Lights plugin the first time. The second plugin can be used for the 2nd Hue hub. Of course, the 2 plugin copies will be completely independent. So Presets from one won't be accessible from the other and embedded Python scripts used to script one plugin won't work with the other until you change the Bundle Identifier in the scripts to match the 2nd plugin's bundle ID.

Again, I haven't tested this, but it should work.

Re: Multiple Philips Hue hubs

PostPosted: Mon Jan 26, 2015 6:01 am
by crsarnelli
That is just great!

Thanks for the information, I should have all I need and the lights should be ready for install in about two weeks. I will let you know how everything turns out.

Thanks again,

Carlos

Re: Multiple Philips Hue hubs

PostPosted: Mon Jan 26, 2015 10:27 am
by nsheldon
Glad I could help. I look forward to hearing how it goes.

Re: Multiple Philips Hue hubs

PostPosted: Tue Feb 03, 2015 5:56 am
by crsarnelli
Dear Nathan,

I tried to change the plist with Xcode as suggested. But I received the following error when the plug in was trying to install in indigo.

Feb 3, 2015, 3:52:41 PM
Installing and enabling plugin "Hue LightsII" v1.3.10
Error ReloadPlugin() caught exception: FileIOError -- cannot move: destination file exists
Error (client) UpdatePluginStatusUI() caught exception: IllegalParameterError -- illegal XML tag name character


Any idea what went wrong?

Thank you,

Carlos

Re: Multiple Philips Hue hubs

PostPosted: Tue Feb 03, 2015 7:01 am
by crsarnelli
Hey Nathan!

Quick update, after not being able to connect the second hub I went to

Library/Application Support/Perceptive Automation/Indigo 6/ Preferences/Pluging/com.nathansheldon.indigoplugin.Huelights.indiPref

and I duplicate the com.nathansheldon.indigoplugin.Huelights.indiPref and renamed it to com.nathansheldon.indigoplugin.Huelights2.indiPref

later I went to

Library/Application Support/Perceptive Automation/Indigo 6/Plugins/Hue Lights.indigoPlugin
and duplicate Hue Lights.indigoPlugin and later rename it to Hue Lights2.indigoPlugin

Last I open the package content and edited the info.plist display name to Hue Lights2 and the bundle identifier to ...HueLights2

Last but not least reloaded indigo and Hue Light2 plugin was there!

Then I change the configuration on Hue Lights 2 with the 2nd hub IP and magic, I was able to load at least the only bulb that is connected to the new hub.

Once I have everything up and running by the end of this week or the beginning of the next one, I will let you know the findings.

Thanks a lot!

Carlos

Re: Multiple Philips Hue hubs

PostPosted: Tue Feb 03, 2015 7:12 am
by DaveL17
Within info.plist, there are three keys that need to be edited in addition to renaming the base plugin file name:

CFBundleDisplayName
CFBundleName
CFBundleIdentifier

I only see two in your screenshot. Perhaps XCode is managing the third automatically; not sure as I edit plist files by hand.

Sounds like you may have it working though. Good luck.

Cheers,
Dave

Re: Multiple Philips Hue hubs

PostPosted: Wed Feb 04, 2015 12:27 am
by nsheldon
Great Carlos! Glad to hear you got it working, at least it seems like it is. let me know how it goes.

Re: Multiple Philips Hue hubs

PostPosted: Sun Jul 09, 2017 3:10 pm
by sumocomputers
DaveL17 wrote:
Within info.plist, there are three keys that need to be edited in addition to renaming the base plugin file name:

CFBundleDisplayName
CFBundleName
CFBundleIdentifier

I only see two in your screenshot. Perhaps XCode is managing the third automatically; not sure as I edit plist files by hand.

Sounds like you may have it working though. Good luck.

Cheers,
Dave


FYI, needed a second Hue hub.

I edited the plist by hand with textedit, and the CFBundleName is not in there. See Screenshot:
https://www.dropbox.com/s/ivgacdiqsba6t ... 5.png?dl=0

However, I renamed the following by just adding a "2" at the end:

Actual File name
CFBundleDisplayName
CFBundleIdentifier

Reloading the plugin did not work. I had to stop the Indigo Server and Restart it, and now it is working great.

Only problem is the frequent updates to this plugin, which is a good thing, but now I have a few extra steps :-)

Chris

Re: Multiple Philips Hue hubs

PostPosted: Sun Jul 09, 2017 4:39 pm
by kw123
Textedit replaces the " with curly ". Then you will get read errors in the plugin. Use textwrangler or something like that.



Sent from my iPhone using Tapatalk

Re: Multiple Philips Hue hubs

PostPosted: Fri Apr 06, 2018 3:28 am
by Busta999
I suspect the issue of going over the 50 device list is becoming more common now.

I have 34 hue light and 9 motion detectors along with Hue switches.

I got a 'free' 2nd Gen Hub and am contemplating using it just in the Lounge the single greatest concentration of hue lights.

Is the only way to support two Hubs to 'hack' the plugin?

Mike

Re: Multiple Philips Hue hubs

PostPosted: Fri Apr 06, 2018 12:28 pm
by nsheldon
Hi Mike.

Yes. The only way to use more than one Hue hub with the plugin is to “hack” a copy so the copied plugin appears as a separate plugin in Indigo. Re-engineering the plugin to support multiple hubs would be a significant undertaking requiring a rewrite of a lot of code, which I don’t have time to tackle myself. The plugin code is freely available on GitHub, however, for any enterprising person interested in taking that on.

Re: Multiple Philips Hue hubs

PostPosted: Fri Apr 06, 2018 3:32 pm
by Busta999
And that is very doable... :D

I’ll do the hack when I get to that point.

That amount of work is not warranted - just wanted to make sure nothing else had developed.

Re: Multiple Philips Hue hubs

PostPosted: Mon May 07, 2018 1:50 pm
by akimball
Busta999 wrote:
And that is very doable... :D

I’ll do the hack when I get to that point.

That amount of work is not warranted - just wanted to make sure nothing else had developed.


I just passed the 40-hue light count and this is a subject I’m interested in.

Was excited that the ikea lights might work as hue’s too. They have specs that are dimmer than the hues. Might buy one just to compare.

Re: Multiple Philips Hue hubs

PostPosted: Wed May 09, 2018 7:20 am
by roussell
Do the IKEA lights turn on after a power outage/restore? That behavior is extremely annoying on the Hue lights and has kept me from buying any Hue gear other than what came in the starter kit.

Terry


Sent from my iPhone using Tapatalk