Fix presence simulation activation flow

This commit is contained in:
2026-04-05 19:23:09 +02:00
parent bc706543b3
commit b68c4a3382
3 changed files with 190 additions and 198 deletions
+9 -15
View File
@@ -1,7 +1,7 @@
alias: Presence Simulation - Tidsblokke (realistisk)
mode: restart
- alias: Presence Simulation - Tidsblokke (realistisk)
mode: restart
trigger:
trigger:
- platform: time
at: "07:00:00"
- platform: time
@@ -9,28 +9,28 @@ trigger:
- platform: time
at: "18:00:00"
condition:
condition:
- condition: state
entity_id: input_boolean.presence_simulation
state: "on"
action:
action:
- variables:
lights_morning:
- light.livingroom
- light.indkoersel_2
- light.indkorsel_2
- light.andreas_vaerelse
- light.bedroom
- light.daniels_vaerelse
- light.forgang
lights_midday:
- light.kokken
- light.indkoersel
- light.livingroom
lights_evening:
- light.livingroom
- light.indkoersel_2
- light.indkorsel_2
- light.andreas_vaerelse
- light.bedroom
- light.daniels_vaerelse
@@ -39,14 +39,12 @@ action:
rand_music: "{{ range(0,100) | random }}"
- choose:
# 🌅 MORGEN
- conditions:
- condition: time
after: "06:59:00"
before: "12:00:00"
sequence:
- repeat:
for_each: "{{ lights_morning }}"
sequence:
@@ -87,14 +85,12 @@ action:
target:
entity_id: media_player.kokken
# 🌤️ MIDDAG
- conditions:
- condition: time
after: "11:59:00"
before: "18:00:00"
sequence:
- repeat:
for_each: "{{ lights_midday }}"
sequence:
@@ -135,14 +131,12 @@ action:
target:
entity_id: media_player.kokken
# 🌙 AFTEN
- conditions:
- condition: time
after: "17:59:00"
before: "22:30:00"
sequence:
- repeat:
for_each: "{{ lights_evening }}"
sequence:
+8 -12
View File
@@ -1,15 +1,11 @@
alias: Start Vacation Mode
description: Aktiverer presence simulation ved feriestart og planlægger slutdato
trigger:
- platform: time
at: "2026-03-28 14:00:00" # Ferie start
action:
- alias: Vacation Mode - Start via dashboard
description: Aktiverer presence simulation, når Vacation Mode tændes fra dashboardet
trigger:
- platform: state
entity_id: input_boolean.vacation_mode
to: "on"
action:
- service: input_boolean.turn_on
target:
entity_id: input_boolean.presence_simulation
# Planlæg slutdato automatisk
- delay:
days: 7
- service: input_boolean.turn_off
target:
entity_id: input_boolean.presence_simulation
+8 -6
View File
@@ -1,17 +1,15 @@
alias: Vacation Mode - Recovery efter restart
trigger:
- alias: Vacation Mode - Recovery efter restart
trigger:
- platform: homeassistant
event: start
condition:
condition:
- condition: state
entity_id: input_boolean.vacation_mode
state: "on"
action:
action:
- choose:
- conditions:
- condition: template
value_template: >
@@ -24,3 +22,7 @@ action:
entity_id:
- input_boolean.vacation_mode
- input_boolean.presence_simulation
default:
- service: input_boolean.turn_on
target:
entity_id: input_boolean.presence_simulation