peter-murray / node-hue-api

Node.js Library for interacting with the Philips Hue Bridge and Lights
Apache License 2.0
1.19k stars 145 forks source link

Lights return to max brightness with color change #15

Closed hootsuitesteven closed 10 years ago

hootsuitesteven commented 10 years ago

I noticed the following: krtek:~ steven$ hue lights 1,2,3,4 -99 light 1 brightness 104 -> 5 light 2 brightness 104 -> 5 light 3 brightness 104 -> 5 light 4 brightness 104 -> 5

krtek:~ steven$ hue lights 1,2,3,4 00FF99 light 1 success light 2 success light 3 success light 4 success

krtek:~ steven$ hue lights 1,2,3,4 -99 light 1 brightness 254 -> 155 light 2 brightness 254 -> 155 light 3 brightness 254 -> 155 light 4 brightness 254 -> 155

Notice how after changing the color then the brightness they we're back at 254.

peter-murray commented 10 years ago

What are you using to set the light values, your own code, or some command line utility?

I will take a look at the code tonight to see if I can reproduce it on my hue bridge.

peter-murray commented 10 years ago

I suspect that it may be coming from a call to hsl value in the light state, but without knowing, exactly what your command hue lights 1,2,3,4 00FF99 does I cannot be sure.

Can you please provide me more details on what that code is calling, or where I can view that code, as that is not part of this library.

Thanks

hootsuitesteven commented 10 years ago

Hey, it actually comes from this project https://github.com/bahamas10/hue-cli not sure if they're related, perhaps user error on my part. Sorry!

peter-murray commented 10 years ago

That cli client uses another library called hue.js to interact with the hue bridge, not this one.