shack glados: init ampel
This commit is contained in:
parent
9301506249
commit
add6d81efc
23
krebs/2configs/shack/glados/automation/ampel.nix
Normal file
23
krebs/2configs/shack/glados/automation/ampel.nix
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
# needs:
|
||||||
|
# binary_sensor.lounge_ampel_status
|
||||||
|
# light.lounge_ampel_licht_rot
|
||||||
|
|
||||||
|
let
|
||||||
|
glados = import ../lib;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.home-assistant.config.automation =
|
||||||
|
[
|
||||||
|
{
|
||||||
|
alias = "Ampel Rotes Licht";
|
||||||
|
initial_state = true;
|
||||||
|
trigger = {
|
||||||
|
platform = "state";
|
||||||
|
entity_id = "binary_sensor.lounge_ampel_status";
|
||||||
|
};
|
||||||
|
action = { service = "light.turn_on";
|
||||||
|
data.entity_id = "light.lounge_ampel_licht_rot";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
@ -40,6 +40,7 @@ in {
|
|||||||
./automation/shack-startup.nix
|
./automation/shack-startup.nix
|
||||||
./automation/party-time.nix
|
./automation/party-time.nix
|
||||||
./automation/hass-restart.nix
|
./automation/hass-restart.nix
|
||||||
|
./automation/ampel.nix
|
||||||
|
|
||||||
];
|
];
|
||||||
services.home-assistant =
|
services.home-assistant =
|
||||||
|
Loading…
Reference in New Issue
Block a user