diff options
author | makefu <github@syntax-fehler.de> | 2021-10-01 18:50:13 +0200 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2021-10-01 18:50:13 +0200 |
commit | cdf4dfc446369386f0e0e44740cf16e9392adc4a (patch) | |
tree | c418dbd4191fb775b8e83927ab083d6ced7b7a74 /2configs/home/ham/automation/flurlicht.nix | |
parent | 5a74839ffc2179dd168013d8e598b8a8268c127a (diff) |
ma ham: add flurlicht
Diffstat (limited to '2configs/home/ham/automation/flurlicht.nix')
-rw-r--r-- | 2configs/home/ham/automation/flurlicht.nix | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/2configs/home/ham/automation/flurlicht.nix b/2configs/home/ham/automation/flurlicht.nix new file mode 100644 index 000000000..d40022540 --- /dev/null +++ b/2configs/home/ham/automation/flurlicht.nix @@ -0,0 +1,39 @@ +let + licht = "light.flur_statuslight"; +in +{ + services.home-assistant.config.automation = + [ + { alias = "Nachtlicht im Flur an"; + trigger = { + platform = "sun"; + event = "sunset"; + }; + action = + [ + { + service = "light.turn_on"; + target.entity_id = licht; + data = { + brightness = 87; + rgbw_color = [ 255 190 0 0 ]; # ein dunkles rot + #effect = "None"; + }; + } + ]; + } + { alias = "Nachtlicht in Flur aus"; + trigger = { + platform = "sun"; + event = "sunrise"; + }; + action = + [ + { + service = "light.turn_off"; + entity_id = licht; + } + ]; + } + ]; +} |