Closed xremix closed 4 years ago
Is this actually required for your devices? The only difference I see between your PR and current set_color
implementation is that it forces brightness to be 100
instead of it being current brightness (scaled to [0..1]) or whatever specified.
Actually, what I see is that if I use set_color(("anything", 0, x))
then if
x =< 100
: the light uses "white mode" and keeps current brightnessx > 100
: the light uses "colour mode" with 0% saturation and keeps current brightness@Faboor the idea was to have a small handy helper function, that helps people understand how to set the color to white mode. Indeed this is just forcing the brightness and color, but this will help people understand how the API works and ease things. If this doesn't make sense as part of the project let me know.
I think it's better to add some comment regarding "white mode" and not creating a new function. Feel free to create a new PR.
Hi,
this function with these little hardcoded values will allow to set a bulb to real white, which is sometimes brighter than just disabling the saturation.
Thanks Toni