ryanjohnsontv / node-red-contrib-ha-inovelli-manager

Nodes for easily managing scenes, parameters, and notifications of Inovelli switches paired through various Home Assistant integrations
MIT License
15 stars 3 forks source link

FR - Multicast for LED manager and support for WHITE #19

Closed MRobi1 closed 2 years ago

MRobi1 commented 3 years ago

I know I already made an FR for multicast on the notification node, could this also be added to the LED manager node? Back on Hubitat, instead of using notifications I would change the default LED color to avoid the momentary change back to the default LED when interacting with the switch. I think this could be accomplished here as well on zwavejs.

Also, is there support for setting the LED to white on the slider? I'm not seeing it there. It could make a nice little night light :)

Thanks again!

ryanjohnsontv commented 3 years ago

Great timing, I’m almost done with a complete revamp of the LED manager mode, multicast included. I’m a bit confused on setting the LEDs to white, because it should be possible, and they even mention setting it to white in the SmartThings documentation, but I haven’t been able to set it to white with any of the parameters in the three HA Z-Wave integrations.

ryanjohnsontv commented 3 years ago

New LED manager incoming: https://github.com/ryanjohnsontv/node-red-contrib-ha-inovelli-manager/releases/tag/v0.2.0

MRobi1 commented 3 years ago

Had forgotten about this change. I just changed my automations from using notifications to changing the default LED colour instead, and the multicast on the LED Manager node works great! Now my OCD is satisfied and I don't get that half second blip back to blue LOL

White does work in ZWaveJS. The LED Indicator colour parameter must be set to 255. I think in order to achieve it you'd have to make a toggle switch to set it to white and when the toggle is selected, override the calculation and set the paremeter straight to 255.

In theory it should work by setting the slider all the way to the right at 360 since the calculation would be 360 / 360 * 255 = 255 but for some reason that doesn't work.

ryanjohnsontv commented 3 years ago

Great news, this ended up being a relatively easy fix. It works as expected with the LED manager and notification nodes. Originally the RGB array would be converted to a hue value, which will never be able to output white because it throws away the brightness and saturation values. Now, if the RGB value is detected as white ([0] == [1] && [1] == [2]) it bypasses the hue conversion and retains its value. I expanded the color slider in the UI to go to 361, so that way if anyone is passing 360 as red this wont be a breaking change.

Anything else you think needs fixing/adding? If not I can get this pushed up ASAP!

MRobi1 commented 3 years ago

That's awesome!!! Nothing that I can think of. Although I'm sure once you push it something else will come to mind! LOL