rootiest

kitchen-button

Oct 8th, 2021 (edited)
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 1.33 KB | None | 0 0
  1. alias: Kitchen Button
  2. description: Controls for the Kitchen Zigbee Button
  3. trigger:
  4.   - platform: mqtt
  5.     topic: zigbee2mqtt/Kitchen Remote/action
  6.     id: kitchen_button_on
  7.     payload: 'on'
  8.   - platform: mqtt
  9.     topic: zigbee2mqtt/Kitchen Remote/action
  10.     id: kitchen_button_off
  11.     payload: 'off'
  12.   - platform: mqtt
  13.     topic: zigbee2mqtt/Kitchen Remote/action
  14.     id: kitchen_button_hold_up
  15.     payload: brightness_move_up
  16.   - platform: mqtt
  17.     topic: zigbee2mqtt/Kitchen Remote/action
  18.     id: kitchen_button_hold_down
  19.     payload: brightness_move_down
  20. condition: []
  21. action:
  22.   - choose:
  23.       - conditions:
  24.           - condition: or
  25.             conditions:
  26.               - condition: trigger
  27.                 id: kitchen_button_on
  28.               - condition: trigger
  29.                 id: kitchen_button_off
  30.         sequence:
  31.           - service: light.toggle
  32.             target:
  33.               entity_id: light.kitchen_zigbee_lights
  34.       - conditions:
  35.           - condition: or
  36.             conditions:
  37.               - condition: trigger
  38.                 id: kitchen_button_hold_down
  39.               - condition: trigger
  40.                 id: kitchen_button_hold_up
  41.         sequence:
  42.           - service: light.toggle
  43.             target:
  44.               entity_id: light.bathroom_lights
  45.     default: []
  46. mode: single
  47.  
Add Comment
Please, Sign In to add comment