doest seem to work for me,
I can only get the on button to work.
randomly thought i would try and change the on button to turn off the light and that doesn’t work either. Although i am very new here it could just be my coding lol
doest seem to work for me,
I can only get the on button to work.
randomly thought i would try and change the on button to turn off the light and that doesn’t work either. Although i am very new here it could just be my coding lol
Same for me. Something changed and now I can only use the turn on button, everything else is without function.
by me the same
that worked like a charm, thx!
I have exactly the same behavior. Only the ON button works.
Does anybody know what’s ther problem with it?
I have the same behavior. any fix would be great.
sorry where can I change this. Still a noob to HA…
I am on ZHA Skyconnect only and use a RWL021 probably v1. It is quite old
I spent some time learning how Blueprints work yesterday and came up with this modification of the original. Note this has only been tested with the v1 remote as that’s all I have but it restores functionality to all buttons for me.
blueprint:
name: ZHA - Philips Hue Dimmer Switch (Fixed)
description: 'Control lights with a Philips Hue Dimmer Switch.
The top "on" button will turn the lights on to the last set brightness
(unless the force brightness is toggled on in the blueprint).
Dim up/down buttons will change the brightness smoothly and can be pressed
and hold until the brightness is satisfactory.
The bottom "off" button will turn the lights off.
'
domain: automation
input:
remote:
name: Philips Hue Dimmer Switch
description: Pick either RWL020 (US) or RWL021 (EU)
selector:
device:
filter:
- integration: zha
manufacturer: Philips
entity:
- domain:
- sensor
device_class:
- battery
multiple: false
light:
name: Light(s)
description: The light(s) to control
selector:
target:
entity:
- domain:
- light
force_brightness:
name: Force turn on brightness
description:
'Force the brightness to the set level below, when the "on" button
on the remote is pushed and lights turn on.'
default: false
selector:
boolean: {}
brightness:
name: Brightness
description: Brightness of the light(s) when turning on
default: 100
selector:
number:
min: 0.0
max: 100.0
mode: slider
step: 1.0
unit_of_measurement: "%"
source_url: https://community.home-assistant.io/t/zha-philips-hue-dimmer-switch-rwl020-rwl021/255048
mode: restart
max_exceeded: silent
variables:
force_brightness: !input force_brightness
trigger:
- platform: event
event_type: zha_event
event_data:
device_id: !input remote
action:
- variables:
command: "{{ trigger.event.data.command }}"
cluster_id: "{{ trigger.event.data.cluster_id }}"
endpoint_id: "{{ trigger.event.data.endpoint_id }}"
- choose:
# Light on
- conditions:
- "{{ command == 'on' }}"
- "{{ cluster_id == 6 }}"
- "{{ endpoint_id == 1 }}"
sequence:
- choose:
- conditions: "{{ force_brightness }}"
sequence:
- service: light.turn_on
target: !input light
data:
transition: 1
brightness_pct: !input brightness
default:
- service: light.turn_on
target: !input light
data:
transition: 1
# Light off
- conditions:
- "{{ command == 'off_press' }}"
- "{{ cluster_id == 64512 }}"
- "{{ endpoint_id == 2 }}"
sequence:
- service: light.turn_off
target: !input light
data:
transition: 1
# Brightness up
- conditions:
- "{{ command == 'step' }}"
- "{{ cluster_id == 8 }}"
- "{{ endpoint_id == 1 }}"
- "{{ trigger.event.data.params.step_mode == 0 }}"
sequence:
- service: light.turn_on
target: !input light
data:
brightness_step_pct: 10
transition: 1
# Brightness down
- conditions:
- "{{ command == 'step' }}"
- "{{ cluster_id == 8 }}"
- "{{ endpoint_id == 1 }}"
- "{{ trigger.event.data.params.step_mode == 1 }}"
sequence:
- service: light.turn_on
target: !input light
data:
brightness_step_pct: -10
transition: 1
I did try setting trigger.event.data.params.step_mode
as a step_mode
variable in the actions but I couldn’t get it to work .
Nice this worked for me. Thanks!
I can only use the off button, the other buttons aren’t working for me. I have the
RWL021
by Philips
Firmware: 0x42006f9d
fantastic thank you for mentioning this!
This blueprint solved the problem with the blueprint in the thread start where only the “on” button works.
I had trouble figuring out how to get @Twiglet’s blueprint into my Home Assistant. The only way I managed to figure out to get it to work was to import the original blueprint and then replace the contents of blueprints\automation\vanstinator\zha-philips-hue-dimmer-switch-rwl020-rwl021
with @Twiglet’s code. There is probably some better way to do it.
Thanks anyway @Twiglet!
Thanks, that fixed the issue for my old Hue Dimmer RWL032
Is anybody using this blueprint having issues since the 2024.11 update? I have a light group set for light(s) to control but only one light from the group is being controlled.
Update: It seems I had to alter the mode from restart to single in the YAML but after that everything is back to normal. Very odd and I’m still not sure why it’s fixed.
I have als an issue with the dimmer. Not sure if I have the same issue. I just started to use the dimmer with ZHA instead of hue bridge. And wanted to use this automation. Could not get it to work. Also altering the mode did not work. Also every time I open the automation and don’t do anything it wants to save? So maybe something is broken in homeassistant?
this worked!!
I think something changed with the order commands are coming in.
A single button press generates a command: off_press
and one command: off_short_release
, in that order. The off_short_release
doesn’t trigger any actions in the automation, but when the automation is in mode: restart
, it restarts the automation.
I don’t know if the order was different before though, or if something else changed.
Yeh, not sure what’s changed. Listening to zha_events I can still see the on_press command but not triggering anything (actually I since noticed on some of my dimmers it would work on a second press). My off button press was the only thing still working. Hold for all buttons seemed to be ok too.
For now I just replaced in the blueprint on_press
with on_short_release
etc for on, up, down and off. Can’t have the wife pressing buttons and nothing happen
hmm, same here. Using a couple of hue dimmer switches though. Editing via Studio Code Server → config → blueprints → automation → stefanroelofs (in my case) → hue_dimmer_switchV2.yaml
Lines:
- conditions: '{{ command == ''on_press'' }}'
changed to the on_press
to on_short_release
for the ON condition.
and changed line:
- conditions: '{{ command == ''off_press'' }}'
from off_press
to off_short_release
for the OFF condition, both for single press/tigger.
But somehow the blueprint or remotes don’t pick it up…
Did a bit of looking at the traces, and got my off button to work by changing the light off conditions to have cluster_id: 6
and command: 'off_with_effect'