Advertisement
Hoekeren75

HA-automation - motionsensor styret lys.

Dec 15th, 2022
325
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 0.84 KB | None | 0 0
  1. alias: Lys_Gangen
  2. description: Tænder lys ved bevægelse i gangen indenfor fastsatte tidspunkter
  3. trigger:
  4.   - type: motion
  5.     platform: device
  6.     device_id: 9717781fb84a70a5e287b35990e76180
  7.     entity_id: binary_sensor.motion_gangen_occupancy
  8.     domain: binary_sensor
  9. condition:
  10.   - condition: time
  11.     before: "21:30:00"
  12.     after: "07:00:00"
  13.     weekday:
  14.      - mon
  15.       - tue
  16.       - wed
  17.       - thu
  18.       - fri
  19.       - sat
  20.       - sun
  21. action:
  22.   - service: light.turn_on
  23.     data: {}
  24.     target:
  25.       entity_id: light.gangen
  26.   - wait_for_trigger:
  27.       - type: no_motion
  28.         platform: device
  29.         device_id: 9717781fb84a70a5e287b35990e76180
  30.         entity_id: binary_sensor.motion_gangen_occupancy
  31.         domain: binary_sensor
  32.   - service: light.turn_off
  33.     data: {}
  34.     entity_id: light.gangen
  35. mode: single
  36.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement