Automations
Every standalone Home Assistant automation, generated at build time from the per-file sources in home_assistant/automations/. This table is the config — it cannot drift, because a build hook reads the YAML and rebuilds the list on every mkdocs build. Add or remove an automation file and the table updates itself.
15 automations — generated at build time from home_assistant/automations/*.yaml.
| Automation | Description | Triggers | Mode |
|---|---|---|---|
| Badeværelse spots: motion triggered, off after configurable delay, night-dimmed | Motion (either MYGGSPRAY sensor via the badevaerelse_occupancy group) turns the bathroom KAJPLATS GU10 spots on — extra dim (10%) while binary_sensor.night_hours is on (23:00-06:00), otherwise at light_intensity (the daylight envelope owns daytime brightness from there; at night night_hours guards the room so the envelope leaves the dim alone). If occupancy spans midnight, the night_hours trigger re-dims the lit room. Off after the room has been unoccupied for input_number.badevaerelse_off_delay minutes (dashboard- adjustable, default 5; the templated for renders when the countdown starts, so a changed value applies from the next exit) — or after the occupancy group has been unavailable that long (both sensors dead; a single dead sensor just drops out of the group, whose off-state then runs the normal motion_clear path), so dead sensor batteries cannot leave the spots burning. True occupancy behaviour: while anyone is in the room the sensor stays on so the off-timer never runs; leaving starts the countdown and re-entering cancels it. light.turn_off keeps the bulbs powered, so they stay Thread routers. | 4 | restart |
| Badeværelse spots: preset power-on brightness to night dim | The bathroom KAJPLATS spots (Matter-over-Thread, not Zigbee) sit behind a wall switch, so a mains cut re-powers them at their stored Matter On level rather than at whatever the motion automation last commanded. Pin that On level to the night-dim value (5 ~= 2%, matching the motion automation's brightness_pct: 2) so a power cut and restore returns the spots dimmed instead of at full. The value lives in each bulb's NVRAM, so it survives the cut. Each daytime light.turn_on resets On level to 255 (use previous level), which would drop the dim-on-restore guarantee for the rest of the day; a trigger on the spots turning off re-pins On level to 13 when the room empties, so it holds around the clock without adding Matter writes while anyone is in the room. Also pins Power-on behavior to "on" (already the live setting) so the preset takes effect on restore, and re-asserts at night start and on HA start. IKEA bulbs expose "On level" but not StartUpCurrentLevel; On level is the IKEA lever for power-on brightness. | 3 | queued |
| Basement: Lights: Activate | — | 3 | single |
| Basement: Lights: Deactivate | — | 2 | single |
| Heatpump: Steering Scheduler | Runs economic logic every 15 mins or on setting changes | 4 | restart |
| Johan: Button Short Press: Toggle Lights | — | 1 | single |
| Johan: Lights: Activate | — | 2 | single |
| Johan: Lights: Deactivate | — | 3 | single |
| Living Room: Button Pressed: Toggle Lights | — | 1 | single |
| Living Room: Lights: Activate | — | 5 | single |
| Living Room: No Motion Detected: Turn Off Lights | — | 1 | single |
| Living room: sleep Apple TV when no motion | No motion in the living room for 25 minutes -> put the Apple TV to sleep (also powers off the TV via HDMI-CEC), with two warnings so a still viewer can cancel: at 22 minutes the bulbs blink five times via their Zigbee identify buttons, spaced 6 s so the ~5 s breathe effects stay distinct (pure blinks, no light state change - an off bulb stays off, so the daylight envelope and the mode guards never get involved; the ~30 s show pushes actual sleep to ~25.5 min); at 24 minutes playback is paused as the final warning. Motion after a warning aborts the shutdown, resuming playback after the pause also aborts, and a motion-abort auto-resumes the playback we paused. The cancel checks read the sensor state as well as the wait trigger, so a wave DURING a warning (sensor already on when the wait starts) still cancels. The Apple TV is only slept when the motion sensor positively reads off - an unavailable sensor aborts rather than sleeping the TV blind. | 1 | single |
| Office: Motion Detected: Turn On Lights | — | 3 | single |
| Office: No Motion: Turn Off Lights | Turn off the office light when no motion has been detected and Anders is not active on his Macbook Air | 1 | single |
| Viktualie spots: door + motion triggered, off 10 min after room clears | Door open OR motion (MYGGSPRAY occupancy) turns the Viktualie KAJPLATS GU10 spots (Matter nodes 9-12) on. They turn off when the door is closed, or 10 minutes after the room goes unoccupied (occupancy -> off, held for 10 min). True occupancy behaviour: while anyone is in the room the sensor stays on so the off-timer never runs; leaving starts the 10-min countdown and re-entering cancels it, so the timer effectively resets on every motion. light.turn_off keeps the bulbs powered (Matter OnOff), so they stay Thread routers. | 4 | restart |
The lighting automations (daylight envelope, manual override, empty-room watchdog) live inside
packages/lighting.yamlrather than as standalone files, so they are documented on the Home Assistant page and do not appear in the table above.