- alias: 'Lys sauna dag - arbejdsdag' trigger: platform: state entity_id: binary_sensor.sauna_motion_motion to: 'on' condition: - condition: numeric_state entity_id: sensor.sauna_motion_illuminance below: 90 - condition: state entity_id: binary_sensor.arbejdsdag state: 'on' - condition: time before: '22:30:00' - condition: time after: '06:00:00' action: - service: scene.turn_on data: entity_id: scene.sauna_klar - alias: 'Lys sauna dag - ikke arbejdsdag' trigger: platform: state entity_id: binary_sensor.sauna_motion_motion to: 'on' condition: - condition: numeric_state entity_id: sensor.sauna_motion_illuminance below: 90 - condition: state entity_id: binary_sensor.arbejdsdag state: 'off' - condition: time before: '22:30:00' - condition: time after: '06:00:00' action: - service: scene.turn_on data: entity_id: scene.sauna_klar - alias: 'Lys i sauna - nat' trigger: platform: state entity_id: binary_sensor.sauna_motion_motion to: 'on' condition: - condition: numeric_state entity_id: sensor.sauna_motion_illuminance below: '70' - condition: time after: '22:30:00' - condition: time before: '06:00:00' action: - service: scene.turn_on data: entity_id: scene.sauna_daempet - alias: 'Sluk lys i sauna' trigger: platform: state entity_id: binary_sensor.sauna_motion_motion to: 'off' for: minutes: 2 action: - service: homeassistant.turn_off data: entity_id: - light.sauna