Rename and refine skab lighting automation

This commit is contained in:
2026-04-05 18:15:24 +02:00
parent 61aca67c45
commit 49f42b1f27
2 changed files with 109 additions and 67 deletions
+109
View File
@@ -0,0 +1,109 @@
- id: skab_claus_motion_lys
alias: Lys skab Claus
mode: restart
trigger:
- platform: state
entity_id: binary_sensor.hue_motion_sensor_1_motion
to: "on"
condition:
- condition: numeric_state
entity_id: sensor.hue_motion_sensor_1_illuminance
below: 90
action:
- choose:
- conditions:
- condition: time
after: "06:00:00"
before: "23:59:00"
sequence:
- service: light.turn_on
target:
entity_id: light.skab_1
data:
brightness_pct: 100
rgb_color: [20, 255, 127]
default:
- service: scene.turn_on
target:
entity_id: scene.skab_daempet
- id: skab_claus_motion_sluk
alias: Sluk lys i skab Claus
mode: restart
trigger:
- platform: state
entity_id: binary_sensor.hue_motion_sensor_1_motion
to: "off"
action:
- wait_for_trigger:
- platform: state
entity_id: binary_sensor.hue_motion_sensor_1_motion
to: "on"
timeout: "00:01:00"
continue_on_timeout: true
- condition: state
entity_id: binary_sensor.hue_motion_sensor_1_motion
state: "off"
- service: light.turn_off
target:
entity_id: light.skab_1
- id: skab_anne_motion_lys
alias: Lys skab Anne
mode: restart
trigger:
- platform: state
entity_id: binary_sensor.motion
to: "on"
condition:
- condition: numeric_state
entity_id: sensor.hue_motion_sensor_1_illuminance_2
below: 90
action:
- choose:
- conditions:
- condition: time
after: "06:00:00"
before: "23:59:00"
sequence:
- service: light.turn_on
target:
entity_id: light.skab_1
data:
brightness_pct: 100
rgb_color: [254, 11, 255]
default:
- service: scene.turn_on
target:
entity_id: scene.skab_daempet
- id: skab_anne_motion_sluk
alias: Sluk lys i skab Anne
mode: restart
trigger:
- platform: state
entity_id: binary_sensor.motion
to: "off"
action:
- wait_for_trigger:
- platform: state
entity_id: binary_sensor.motion
to: "on"
timeout: "00:01:00"
continue_on_timeout: true
- condition: state
entity_id: binary_sensor.motion
state: "off"
- service: light.turn_off
target:
entity_id: light.skab_1