summaryrefslogtreecommitdiffstats
path: root/krebs/2configs/shack/glados/multi
diff options
context:
space:
mode:
Diffstat (limited to 'krebs/2configs/shack/glados/multi')
-rw-r--r--krebs/2configs/shack/glados/multi/schlechte_luft.nix19
-rw-r--r--krebs/2configs/shack/glados/multi/wasser.nix17
2 files changed, 22 insertions, 14 deletions
diff --git a/krebs/2configs/shack/glados/multi/schlechte_luft.nix b/krebs/2configs/shack/glados/multi/schlechte_luft.nix
new file mode 100644
index 000000000..94cb768b9
--- /dev/null
+++ b/krebs/2configs/shack/glados/multi/schlechte_luft.nix
@@ -0,0 +1,19 @@
+let
+ airlevel = name: threshold: color:
+ { alias = "${name} Air trigger ${color}";
+ trigger = [
+ ];
+ action =
+ [
+ # create spark effect with color
+ ];
+ };
+in
+{
+ # LED
+ switch = [
+ ];
+ automation =
+ [
+ ];
+}
diff --git a/krebs/2configs/shack/glados/multi/wasser.nix b/krebs/2configs/shack/glados/multi/wasser.nix
index 578bb0750..e3e7eb2a0 100644
--- a/krebs/2configs/shack/glados/multi/wasser.nix
+++ b/krebs/2configs/shack/glados/multi/wasser.nix
@@ -1,23 +1,12 @@
let
- tasmota_plug = name: topic:
- { platform = "mqtt";
- inherit name;
- state_topic = "sonoff/stat/${topic}/POWER1";
- command_topic = "sonoff/cmnd/${topic}/POWER1";
- availability_topic = "sonoff/tele/${topic}/LWT";
- payload_on= "ON";
- payload_off= "OFF";
- payload_available= "Online";
- payload_not_available= "Offline";
- retain = false;
- qos = 1;
- };
+ glados = import ../lib;
seconds = 20;
in
{
switch = [
- (tasmota_plug "Wasser" "plug")
+ (glados.tasmota.plug "Wasser" "plug")
];
+
automation =
[
{ alias = "Water the plant for ${toString seconds} seconds";