Guest User

Untitled

a guest
Dec 18th, 2025
29
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 3.22 KB | None | 0 0
  1. alias: Living Room Hue Switch Dimmer control
  2. description: Turn the dimmer up/down
  3. triggers:
  4.   - device_id: 57c59179387a3a1b1302d549a9d55448
  5.     domain: zha
  6.     type: remote_button_short_press
  7.     subtype: dim_up
  8.     trigger: device
  9.     id: dim_up_short_press
  10.   - device_id: 57c59179387a3a1b1302d549a9d55448
  11.     domain: zha
  12.     type: remote_button_long_press
  13.     subtype: dim_up
  14.     trigger: device
  15.     id: dim_up_long_press
  16.   - device_id: 57c59179387a3a1b1302d549a9d55448
  17.     domain: zha
  18.     type: remote_button_short_press
  19.     subtype: dim_down
  20.     trigger: device
  21.     id: dim_down_short_press
  22.   - device_id: 57c59179387a3a1b1302d549a9d55448
  23.     domain: zha
  24.     type: remote_button_long_press
  25.     subtype: dim_down
  26.     trigger: device
  27.     id: dim_down_long_press
  28. conditions: []
  29. actions:
  30.   - choose:
  31.       - conditions:
  32.           - condition: trigger
  33.             id:
  34.              - dim_up_short_press
  35.         sequence:
  36.           - condition: numeric_state
  37.             entity_id: light.living_room_ambient_lights
  38.             attribute: brightness
  39.             below: 255
  40.           - target:
  41.               entity_id: light.living_room_ambient_lights
  42.             data:
  43.               brightness_step_pct: 10
  44.             action: light.turn_on
  45.       - conditions:
  46.           - condition: trigger
  47.             id:
  48.              - dim_up_long_press
  49.         sequence:
  50.           - repeat:
  51.               while:
  52.                 - condition: numeric_state
  53.                   entity_id: light.living_room_ambient_lights
  54.                   attribute: brightness
  55.                   below: 255
  56.               sequence:
  57.                 - target:
  58.                     entity_id: light.living_room_ambient_lights
  59.                   data:
  60.                     brightness_step_pct: 10
  61.                     transition: 0.3
  62.                   action: light.turn_on
  63.                 - delay:
  64.                     hours: 0
  65.                     minutes: 0
  66.                     seconds: 0
  67.                     milliseconds: 300
  68.       - conditions:
  69.           - condition: trigger
  70.             id:
  71.              - dim_down_short_press
  72.         sequence:
  73.           - condition: numeric_state
  74.             entity_id: light.living_room_ambient_lights
  75.             attribute: brightness
  76.             above: 38
  77.           - target:
  78.               entity_id: light.living_room_ambient_lights
  79.             data:
  80.               brightness_step_pct: -10
  81.             action: light.turn_on
  82.       - conditions:
  83.           - condition: trigger
  84.             id:
  85.              - dim_down_long_press
  86.         sequence:
  87.           - repeat:
  88.               while:
  89.                 - condition: numeric_state
  90.                   entity_id: light.living_room_ambient_lights
  91.                   attribute: brightness
  92.                   above: 38
  93.               sequence:
  94.                 - target:
  95.                     entity_id: light.living_room_ambient_lights
  96.                   data:
  97.                     brightness_step_pct: -10
  98.                     transition: 0.3
  99.                   action: light.turn_on
  100.                 - delay:
  101.                     hours: 0
  102.                     minutes: 0
  103.                     seconds: 0
  104.                     milliseconds: 300
  105. mode: queued
  106. max: 10
  107.  
Advertisement
Add Comment
Please, Sign In to add comment