Last active
December 30, 2022 20:30
-
-
Save adamawolf/e1363ed27f16dc989831086e8e7fcde4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
blueprint: | |
name: zigbee2mqtt Hue Dimmer Switch control v4 | |
description: '' | |
domain: automation | |
input: | |
dimmer_action: | |
name: Dimmer MQTT topic | |
description: 'Dimmer MQTT topic (i.e. zigbee2mqtt/Your Dimmer Switch/action)' | |
selector: | |
text: | |
action_on_press: | |
name: on_press | |
description: Action to run when you press ON | |
default: [] | |
selector: | |
action: | |
action_off_press: | |
name: off_press | |
description: Action to run when you press OFF | |
default: [] | |
selector: | |
action: | |
action_up_press: | |
name: up_press | |
description: Action to run when you press UP | |
default: [] | |
selector: | |
action: | |
action_down_press: | |
name: down_press | |
description: Action to run when you press DOWN | |
default: [] | |
selector: | |
action: | |
action_on_hold: | |
name: on_hold | |
description: Action to run when you hold ON | |
default: [] | |
selector: | |
action: | |
action_off_hold: | |
name: off_hold | |
description: Action to run when you hold OFF | |
default: [] | |
selector: | |
action: | |
action_up_hold: | |
name: up_hold | |
description: Action to run when you hold UP | |
default: [] | |
selector: | |
action: | |
action_down_hold: | |
name: down_hold | |
description: Action to run when you hold DOWN | |
default: [] | |
selector: | |
action: | |
trigger: | |
- platform: mqtt | |
topic: !input dimmer_action | |
payload: on_press_release | |
id: dimmer_on | |
- platform: mqtt | |
topic: !input dimmer_action | |
id: dimmer_off | |
payload: off_press_release | |
- platform: mqtt | |
topic: !input dimmer_action | |
id: dimmer_up | |
payload: up_press_release | |
- platform: mqtt | |
topic: !input dimmer_action | |
id: dimmer_down | |
payload: down_press_release | |
- platform: mqtt | |
topic: !input dimmer_action | |
id: dimmer_on_hold | |
payload: on_hold_release | |
- platform: mqtt | |
topic: !input dimmer_action | |
payload: off_hold_release | |
id: dimmer_off_hold | |
- platform: mqtt | |
topic: !input dimmer_action | |
id: dimmer_up_hold | |
payload: up_hold_release | |
- platform: mqtt | |
topic: !input dimmer_action | |
payload: down_hold_release | |
id: dimmer_down_hold | |
action: | |
- choose: | |
- conditions: | |
- condition: trigger | |
id: dimmer_on | |
sequence: | |
!input action_on_press | |
- conditions: | |
- condition: trigger | |
id: dimmer_off | |
sequence: | |
!input action_off_press | |
- conditions: | |
- condition: trigger | |
id: dimmer_up | |
sequence: | |
!input action_up_press | |
- conditions: | |
- condition: trigger | |
id: dimmer_down | |
sequence: | |
!input action_down_press | |
- conditions: | |
- condition: trigger | |
id: dimmer_on_hold | |
sequence: | |
!input action_on_hold | |
- conditions: | |
- condition: trigger | |
id: dimmer_off_hold | |
sequence: | |
!input action_off_hold | |
- conditions: | |
- condition: trigger | |
id: dimmer_up_hold | |
sequence: | |
!input action_up_hold | |
- conditions: | |
- condition: trigger | |
id: dimmer_down_hold | |
sequence: | |
!input action_down_hold | |
default: [] | |
mode: restart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment