Open fjulian79 opened 1 year ago
Awesome! Thank you for doing this. Now how do we get @Foddy to merge it so we can get this in the easy Node Red installer?
@fjulian79 Could you implement decrementBrightness too?
@peterbaker maybe the name is misleading but you can use negative values too: incrementBrightness +10 --> 10% brighter incrementBrightness -10 --> 10% darker
So what you request is already there, it would be just another name and inverse logic: decrementBrightness -10 --> 10% brighter decrementBrightness +10 --> 10% darker
So I think this would not add a lot but would bloat the code.
Finally .. there is a fork of this repo which is way more agile, see https://github.com/mauricedominic/node-red-contrib-huemagic.git I have filed my pull request over there as well and it has been accepted. So maybe switching to mauricedominic is a valid option.
I did notice that increment works both ways after I wrote that, but also I still think it'd be useful (maybe just to me) to have decrementBrightness as that was how HueMagic 3 worked and including it would maintain existing flows.
Either way, just glad to see a path towards actually being able to use HueMagic 4. Thank you!
Also, it would then mirror the commands for individual lights (which have both incrementBrightness and decrementBrightness).
@peterbaker Ack, I agree! I have not had those background info's ;-) I will try to get it done in the next days.
@peterbaker I'm done .. I have tested decrementBrightness with my lamps, works fine from my point of view.
Hi folks ..
I have added the missing incrementBrightness support for groups which is reported in issue #380. In my opinion it is mandatory when huemagic shall be used to connect KNX switches to Philips Hue. I have done it in the following way:
This is the best way to get this done because:
But for this approach incrementBrightness support is mandatory .. see also the official v1 api docs on the bri_inc argument. I have found it while searching for a proper way to get the task done as my other attempts have been suboptimal.
If there is a good reason to get the task done in a different way, let me know ;-)
br J.