inner_living_room_lights.yaml 1022 B

1234567891011121314151617181920
  1. # Require: https://github.com/jmgiaever/home-assistant-blueprints/blob/master/automation/motion_detected_lights.yaml
  2. automation:
  3. - id: 'inner_living_room_motion_active_lights'
  4. alias: 'Inner living room: Motion active lights'
  5. use_blueprint:
  6. path: motion_detected_lights.yaml
  7. input:
  8. trigger_sensors:
  9. - binary_sensor.inner_living_room_motion_sensor_home_security_motion_detection
  10. synced_lights:
  11. - light.inner_living_room_chandelier_light
  12. illuminance_sensors:
  13. - sensor.inner_living_room_motion_sensor_illuminance
  14. illuminance_threshold: 10
  15. after_wait_actions:
  16. - wait_template: "{{ is_state('input_boolean.housekeeping_mode', 'off') }}"
  17. # Our living rooms are «open» between. Wait until motion in both are off to turn off the lights
  18. - wait_template: "{{ is_state('binary_sensor.living_room_motion_sensor_home_security_motion_detection', 'off') }}"
  19. wait_actions_before_dim: false
  20. delay: 15