Closed mortenmoulder closed 3 years ago
Sounds like a good feature. I think the easiest way for me to handle that is to have a separate selector for brightness type, where someone can select brightness or brightness_pct.
I just pushed this feature to flows.nodered.org It should be version 1.3 if you want to check it out.
You should be able to get rid of your helper function and set:
"brightnessType": "Integer"
Awesome node. I've just used it to dim some IKEA bulbs and it works great. However, I had to use a function, because I grab my bulb's brightness first, and then pass that into the change node. When I grab my bulb's brightness, I do not get a percentage back, but instead get a 0-255 value.
It would be great if transitioning between 0 and 255 is possible with 2 more attributes (optional of course). Here is my workaround:
Create a new function node:
That converts 255 to 100%, 127 to 50%, and so on.
Then pass that node to the change node (look at startBright):
Thanks