Page 4 of 9

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 0:23
by simonrg
Blueone wrote:Also the living color shows as normal switch instead of a dimmer like the e27 hue lights.
Is the living colour lamp recognised first, i.e. has the lowest id? If so I don't think it is a lamp type issue, but is the same as my issue where the first lamp does not appear to be recognised correctly.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 2:43
by sdh
simonrg wrote:Deleted Hue Lamp devices and Hue Bridge hardware, reinstalled hardware - still 2 lamps recognised correctly and 1 not.
Screen shot 2014-10-25 at 18.41.16.png
All 3 lamps are original with no differences showing up in any other context.
So I guess this must be a bug?
Exact same behaviour for me. I have 5 lamps, 2 to 5 recognised correctly, 1 is not recognised correctly.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 8:58
by simonrg
I don't know if this may to show what's wrong, every 10 seconds, my first lamp is spotted and logged as below:

Code: Select all

Sun Oct 26 07:47:40 2014 LUA: Hue Lamp 1 spotted
Sun Oct 26 07:47:40 2014 LUA: http://192.168.9.18/api/newdeveloper/lights/ /state
Sun Oct 26 07:47:40 2014 LUA: {"on":false}
Sun Oct 26 07:47:40 2014 LUA: HTTP/1.1 200 OK
Sun Oct 26 07:47:40 2014 (Hue Bridge) Lighting Limitless/Applamp (Hue Lamp 1)
The other two lamps are not seen in the log.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 9:45
by gizmocuz
There is a new beta #2081, maybe this solves some problems.

There are different types of lamps, and currently i only have two types:

- 1. "Dimmable plug-in unit"
- 2. "Extended color light"

the first (1) i handle as a normal on/off dimmer
the second (2) one as a RGBW

you can see your lights/types when issuing:

[url]http://<ipaddress%20of%20bridge>/api/username[/url]

(maybe someone can post theirs ?)

now i found 2 more lamp types:

- 3. "Dimmable light"
- 4. "Color light"

the 3rd i handle as a normal on/off+dimmer
the 4rd as RGBW

Maybe this is incorrect, and maybe there are more types ?

If after the update some lamps are not recognized (or to many) please post the output of the above url

Unfortunately the Philips Hue bridge does not report back a unique ID (serial number for example) for each lamp,
so when deleting lamps, you are better to delete all devices associated with the hardware in domoticz, and restart the hardware

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 10:00
by simonrg
gizmocuz wrote:If after the update some lamps are not recognized (or to many) please post the output of the above url
@gizmocuz thanks very much still seems to be doing the same things, all 3 lamps are Extended Colour Lights, but the first 1 seems to be identified incorrectly. This lamp is no longer showing up in the log every 10 seconds. Hopefully attached information will help, thanks.

Code: Select all

Sun Oct 26 08:50:20 2014 Philips Hue: Worker started...
Sun Oct 26 08:50:20 2014 EventSystem stopped...
Sun Oct 26 08:50:20 2014 (Hue Bridge) Lighting Limitless/Applamp (Unknown)
Sun Oct 26 08:50:21 2014 (Hue Bridge) Lighting Limitless/Applamp (Unknown)
Sun Oct 26 08:50:22 2014 (Hue Bridge) Lighting Limitless/Applamp (Unknown)
Screen shot 2014-10-26 at 08.52.19.png
Screen shot 2014-10-26 at 08.52.19.png (29.08 KiB) Viewed 6428 times
/api/newdeveloper/lights/

Code: Select all

{"1":{"state": {"on":true,"bri":254,"hue":64882,"sat":183,"xy":[0.5797,0.3301],"ct":500,"alert":"none","effect":"none","colormode":"xy","reachable":false}, "type": "Extended color light", "name": "Hue Lamp 1", "modelid": "LCT001", "swversion": "65003148", "pointsymbol": { "1":"none", "2":"none", "3":"none", "4":"none", "5":"none", "6":"none", "7":"none", "8":"none" }},"2":{"state": {"on":true,"bri":250,"hue":23387,"sat":254,"xy":[0.4320,0.5011],"ct":325,"alert":"none","effect":"none","colormode":"hs","reachable":false}, "type": "Extended color light", "name": "Hue Lamp 2", "modelid": "LCT001", "swversion": "65003148", "pointsymbol": { "1":"none", "2":"none", "3":"none", "4":"none", "5":"none", "6":"none", "7":"none", "8":"none" }},"3":{"state": {"on":true,"bri":254,"hue":39835,"sat":254,"xy":[0.4584,0.4101],"ct":365,"alert":"none","effect":"none","colormode":"hs","reachable":false}, "type": "Extended color light", "name": "Hue Lamp 3", "modelid": "LCT001", "swversion": "65003148", "pointsymbol": { "1":"none", "2":"none", "3":"none", "4":"none", "5":"none", "6":"none", "7":"none", "8":"none" }}}

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 10:30
by gizmocuz
@simon:

New beta version, this should solve the naming problem.
But i suspect the inner working was correct ? (like you could control the lamps)

Ps. to see the correct names, remove the hue devices from the devices tab, and restart the philips hue hardware (in domoticz)

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 10:50
by Blueone
The livingcolor light with id 1 is working properly now in the latest version (2084) :D

Maybe a feature request when everything is working correct, the Hue tap support so it is also possible to use the switches in combination with domoticz.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 11:07
by simonrg
@gizmocuz great :D , thanks very much, all 3 lights now perform the same way, before all was functioning just lamp 1 was shown as off when on, now all seems to be perfect.

Just going to understand whether the Edit display in Domoticz reflects the current state of the light or just that last state set by Domoticz, then I can simplify my complicated Hue scripts to capture colours - http://www.domoticz.com/wiki/Philips_Hu ... Hue_Scenes.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 11:20
by gizmocuz
simonrg wrote:@gizmocuz great :D , thanks very much, all 3 lights now perform the same way, before all was functioning just lamp 1 was shown as off when on, now all seems to be perfect.

Just going to understand whether the Edit display in Domoticz reflects the current state of the light or just that last state set by Domoticz, then I can simplify my complicated Hue scripts to capture colours - http://www.domoticz.com/wiki/Philips_Hu ... Hue_Scenes.
The Edit/Timer color state does not reflect the actual state at all.

Thanks for your hard work on the scripts, but i think maybe this page is kinda obsolete now ?
You can now use the normal ways to make timers/scenes/control ?

You should also be able to create a scene/group for directly setting specific colors

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 11:50
by simonrg
@gizmocuz absolutely agreed the page is now largely obsolete thanks to all your work of integrating this into Domoticz.

The only thing that is lacking is the ability to capture the current state of the Philips Hue lights.

There are many apps which set the Philips Hue lights, which with multiple lights are controlling a lot of parameters, and the ability to capture an ideal setting directly into Domoticz makes it practical to use Domoticz as an integrated control system.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 11:52
by gizmocuz
simonrg wrote:@gizmocuz absolutely agreed the page is now largely obsolete thanks to all your work of integrating this into Domoticz.

The only thing that is lacking is the ability to capture the current state of the Philips Hue lights.

There are many apps which set the Philips Hue lights, which with multiple lights are controlling a lot of parameters, and the ability to capture an ideal setting directly into Domoticz makes it practical to use Domoticz as an integrated control system.
Not sure i understand....

Every 10 seconds, the current states are polled, and if needed, updated
(That is on/off state and brightness)

For instance when you change the dimmer slider on an iOS device, in the web gui (within 10 seconds) this is also updated

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 12:31
by Brutus
This morning I see the great news that the Philips Hue is implemented in Domoticz.

But I can't get it to work.

When I fill in my IP Adress and username in domoticz, then push the link button on the bridge, and then click on "register on bridge" i get a little red bod with "undifined"

What am I doing wrong?

Thanks for the help.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 12:42
by gizmocuz
Brutus wrote:This morning I see the great news that the Philips Hue is implemented in Domoticz.

But I can't get it to work.

When I fill in my IP Adress and username in domoticz, then push the link button on the bridge, and then click on "register on bridge" i get a little red bod with "undifined"

What am I doing wrong?

Thanks for the help.
Maybe sure to fill in the IP Address of the Hue bridge , port 80
if you leave the username empty, press the hue link button, then press register,
then when it succeeds a unique username is filled in the gui
then press ADD

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 13:04
by simonrg
gizmocuz wrote:Not sure i understand....

Every 10 seconds, the current states are polled, and if needed, updated
(That is on/off state and brightness)

For instance when you change the dimmer slider on an iOS device, in the web gui (within 10 seconds) this is also updated
As per your previous post the colour from the hue lamp is not captured by Domoticz. When I go to edit, the display always shows a grey green (Hue 128 Brightness 100). One of my scripts retrieved all the lamp settings from the Hue bridge and saved these, so that a scene I can recreate a scene by sending all these parameters back to the Hue bridge. So no matter how I have set the lamps, I am able to capture that state in Domoticz via json from the Hue bridge and then save that to be recreated by Domoticz.
http://www.domoticz.com/wiki/Philips_Hue_Lights#Capturing.2C_Storing_and_Displaying_Hue_Scenes wrote:Trying to set the colours of lights is rather complicated in the Domoticz web UI as made possible from the script above, however there are a large number of apps which allow Hue lights colours to be set with ease on clever interfaces.

So the idea of these two scripts is to capture the current scene of your Hue lights, store them and then allow the scenes to be recalled in order.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 13:09
by gizmocuz
not sure why you want to capture the color state

- with using scenes you can create scenes for red/green/blue/... lights if you want
- you can create timers with specific colors

and most times you create the above one time, so maybe it is (not) very complicated todo this with domoticz

But thats my 2 cents... native supports is better/faster and you have more (direct) control

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 14:12
by simonrg
@gizmocuz naitve support is infinitely better than indirect support no questions, many thanks for integrating this so seemlessly. The final piece would be having the state of lights being confirmed by Domoticz. Being a user of LightwaveRF I am used to not having any feedback and its disadvantages, hence I doubly appreciate the ability with the Philips Hue lights of being able to retrieve the true state of the lights.

With the Philips Hue lights I am used to having 10s of scenes with each light having unique settings which it is now great to be able to control directly from Domoticz, but I am not keen on the thought of recreating these manually in Domoticz, hence the original script to close the loop.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 14:23
by gizmocuz
The light status (and brightness) is updated by domoticz in realtime, only not the color (which is, i think, of non importance)
Hence a user wants to change a color, he does it, no need to know the previous/actual color, he can see this

Yes you need to create native scenes (with colors if you want) and timers, and blockly actions or notifications etc... it's a new hardware type

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 15:52
by Blueone
The update of colors could be handy if you use the lights with different programs what's often happens with the hue lights. It's easy to create scenes which are the same as the other programs if you know the colors.

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 16:10
by simonrg
gizmocuz wrote:The light status (and brightness) is updated by domoticz in realtime, only not the color (which is, i think, of non importance)
Hence a user wants to change a color, he does it, no need to know the previous/actual color, he can see this
I think the colour is important, otherwise surely you could make the same arguement for status and brightness, both of which I can see, ;) but do appreciate realtime feedback.
Blueone wrote:The update of colors could be handy if you use the lights with different programs what's often happens with the hue lights. It's easy to create scenes which are the same as the other programs if you know the colors.
Agreed to integrate in capture of the colours would be a very sophisticated feature for Domoticz to have 8-) , it would add the icing to the cake that you(@gizmocuz) have already made with the hardware Philips Hue device :D , thanks.
I think I can automate the capute by altering my previous scripts, which may be a more sensible approach than the work needed to alter the C++ code for something unique to the Philips Hue lights.
With no experience of C++ I have had a look at the code, but really can't even see where to start :oops: . :cry:

Re: [122] Philips Hue support

Posted: Sunday 26 October 2014 16:13
by gizmocuz
simonrg wrote:
gizmocuz wrote:The light status (and brightness) is updated by domoticz in realtime, only not the color (which is, i think, of non importance)
Hence a user wants to change a color, he does it, no need to know the previous/actual color, he can see this
I think the colour is important, otherwise surely you could make the same arguement for status and brightness, both of which I can see, ;) but do appreciate realtime feedback.
Thats not true, and you want to know the brightness so when you turn it on you know what it is.

And with scripts you do not see any colors in domoticz, so thats not the reason to use scripts.

Its also not that i dont know how to read the current color, its how/where i should present this