šŸŽ® ZHA, deCONZ, Zigbee2MQTT - Philips 324131092621 Hue dimmer switch Universal blueprint - all actions + double click events - control lights, media players and more with Hooks

Hi Matteo, thank you for your Awesome Blueprints. I am using one with an IKEA Styrbar, using both the hook and some custom actions for double presses.
I also implemented an automation for a Philips Hue Dimmer (I have both the older RWL021 and the newer RWL022 models, and tried both). I found that the double press actions do not work for these controllers. After some tinkering, I found out that these controllers natively support multiple presses, and send specific commands for double, triple, quadruple and quintuple presses, so the double presses are not caught by your automation. Is there any chance to incorporate the multiple press commands into the controller blueprints? That would be awesome. I found this blueprint: GitHub - Jessendelft/Hue-Dimmer-Switch-V3: Home Assistant Blueprint for the Hue Dimmer Switch. , which assigns specific actions to multiple presses up to triple. It was easily edited to include quadruple and quintuple, the command names are obvious.

Thank you, but no, itā€™s not working either way unfortunately.

I looked a bit into the commands that the controlller sends, and besides the double clicks I mentioned in my previous post, there is a problem with this blueprint and long presses too. When you do a short press, it sends a ā€˜short_releasedā€™ and a ā€˜short_pressedā€™ command (in that order!). When you do a long press, it first sends a ā€˜short_pressedā€™, then a series of ā€˜long_pressedā€™ (about 1 per second) , and finally a ā€˜long_releasedā€™. So if you want to use both long and short presses of the same button, and the long press is not just a repeat of the short press action, the event you should listen too for the short press action, is the short release.

So, in short, this blueprint collection is very nice for the IKEA buttons, but to work for the Philips dimmers it needs some adaptation.

Hello everybody,

so i got this BP working with the following setup:

LP- On Button - Light 1 on
LP- Off Button - Light 1 off

SP- On Button - Light 2 on
SP- Off Button - Light 2 off

When i press the on button long Light 1 and 2 are on.

Is there a solution to exclusively turn on/off the lights like mentioned in my setup?

Thanks in advance

Hi,

thanks for your code. Appreciate it. Its working so far :+1:

How could I integrate also color change of the lamp (white tones) ?

This blueprint stopped working for me last night. Possibly after a HACS update of something (maybe the zha toolkit?) I can see the remote is still firing events. Any suggestions on how I should debug? Iā€™m still on 2023.1.6 since 2023.2.x has screwed up ZHA Sonoff integration and I havenā€™t been brave enough to try 2023.3.1 yet

So I think I did what youā€™re describe, moving the short press action over to release, but Iā€™m still not able to trigger thing with short press when I have double press turned on. Any other hints you can give as to how you fixed this? Thanks!

For those using Z2M, I found that by changing the ā€œSettings (specific)ā€ ā†’ legacy = true, the controller works.

3 Likes

thank you for the blueprint. Is there any fix for the double press issue?

for my part is not working. really weird because I can see the integration in the device. The commands are ok in the log of z2mqtt and even the scripts is with the same commands. Any idea?Screenshot 2023-05-03 at 13.22.54




Screenshot 2023-05-03 at 13.00.42
Screenshot 2023-05-03 at 13.00.40

Yeah Iā€™m having issues with double press recently. Is there an issue log for this?

1 Like

I love this blueprint.
Actually, one thing is missing for me.
It would be great to have a time or sun based condition in there.
For example, in my bath, when I press ā€œonā€ I would like to have the light at 100% when the sun is up, but only 20% when the sun is down.
In the room of my childs, the light should be at 100% between 7 am and 7 pm, and 20% between 7 pm and 7 am.
I would have one automation for each time slot.
Do you think it would be possible to add this?

Maybe you should not be using this blueprint, and instead crafting your own automation. Just a thought. Looks like you have defined your scenarios and parameters already.

This blueprint is for using a switch as a switch, not for creating routines.or automations based on other events. You press a button on the switch to perform a set function, like a light switch would do.
Youā€™d need to create your own spearate automations for conditions like that, or look for a different blueprint to do what you need to do. A light switch doesnā€™t create routines like that. Itā€™s a switch.
You can use the Events generated by the switch integrated to your own automation to achieve what you want to achieve.

I suggest everyone move over to GitHub - Sian-Lee-SA/Home-Assistant-Switch-Manager: Switch manager is a centralised component to handle button pushes for your wireless switches. This includes anything passed through the event bus. The component relies on switch blueprints which is easily made to allow GUI configuration of your switches and their button pushes. This helps remove clutter from the automations. since that is being actively worked on and is a much more enjoyable experience. The only thing itā€™s lacking right now is double presses :frowning:

1 Like

does this blueprint still work?
iā€™m trying to use it with my 324131092621 switch (just as a basic on/off switch), but when i press a button nothing happens.

Did you activate the legacy mode in Zigbee2MQTT for the Dimmer Switch?

Thank you! I have been trying to get this to work for ages. Changing the switch to legacy=true using the blueprint now works.

1 Like

yes.

however iā€™m not using ā€œswitch managerā€ which is working nicely