From cd2cb16a894bd810b95951ae6531bf5f567f0b95 Mon Sep 17 00:00:00 2001 From: Przemek Grondek Date: Tue, 29 Dec 2020 21:45:59 +0100 Subject: [PATCH] Add kitchen button --- automations/files/button-kitchen.yaml | 87 +++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 automations/files/button-kitchen.yaml diff --git a/automations/files/button-kitchen.yaml b/automations/files/button-kitchen.yaml new file mode 100644 index 0000000..91b2835 --- /dev/null +++ b/automations/files/button-kitchen.yaml @@ -0,0 +1,87 @@ +- id: button-kitchen-on + alias: Button On computer cave + trigger: + - device_id: a47c928b108240ed8866f9f7a70bc844 + domain: zha + platform: device + type: remote_button_short_press + subtype: turn_on + condition: [ ] + action: + - service: light.turn_on + data: + entity_id: light.kitchen_sink_lighstrip + mode: single +- id: button-kitchen-off + alias: Button Off computer cave + trigger: + - device_id: a47c928b108240ed8866f9f7a70bc844 + domain: zha + platform: device + type: remote_button_short_press + subtype: turn_off + condition: [ ] + action: + - service: light.turn_off + data: + entity_id: light.kitchen_sink_lighstrip + mode: single +- id: button-kitchen-hold-on + alias: Button Hold On computer cave + trigger: + - platform: event + event_type: zha_event + event_data: + device_id: a47c928b108240ed8866f9f7a70bc844 + command: move_with_on_off + condition: [ ] + action: + - service: light.turn_on + data: + entity_id: + - light.kitchen_01 + - light.kitchen_02 + - light.kitchen_03 + - light.kitchen_04 + - light.kitchen_05 + - light.kitchen_06 + - light.kitchen_07 + - light.kitchen_08 + - light.kitchen_09 + - light.kitchen_10 + - light.kitchen_11 + - light.kitchen_12 + - light.kitchen_13 + - light.kitchen_14 + mode: single +- id: button-kitchen-hold-off + alias: Button Hold Off computer cave + trigger: + - platform: event + event_type: zha_event + event_data: + device_id: a47c928b108240ed8866f9f7a70bc844 + command: move + args: + - 1 + - 83 + condition: [ ] + action: + - service: light.turn_off + data: + entity_id: + - light.kitchen_01 + - light.kitchen_02 + - light.kitchen_03 + - light.kitchen_04 + - light.kitchen_05 + - light.kitchen_06 + - light.kitchen_07 + - light.kitchen_08 + - light.kitchen_09 + - light.kitchen_10 + - light.kitchen_11 + - light.kitchen_12 + - light.kitchen_13 + - light.kitchen_14 + mode: single \ No newline at end of file