From 2712bd2197971df16e176fa3a9b120490a1ac390 Mon Sep 17 00:00:00 2001 From: Dominik Polakovics Date: Sun, 22 Jun 2025 14:25:50 +0200 Subject: [PATCH] feat: add new bed switch and a new scene --- hosts/fw/modules/home-assistant/default.nix | 1 + hosts/fw/modules/home-assistant/enocean.nix | 7 +++++ .../fw/modules/home-assistant/scenes/date.nix | 27 +++++++++++++++++++ .../modules/home-assistant/scenes/default.nix | 6 +++++ hosts/fw/modules/web/default.nix | 2 +- 5 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 hosts/fw/modules/home-assistant/scenes/date.nix create mode 100644 hosts/fw/modules/home-assistant/scenes/default.nix diff --git a/hosts/fw/modules/home-assistant/default.nix b/hosts/fw/modules/home-assistant/default.nix index 8ae9904..c7e1eac 100644 --- a/hosts/fw/modules/home-assistant/default.nix +++ b/hosts/fw/modules/home-assistant/default.nix @@ -96,6 +96,7 @@ in ./presense.nix ./remote.nix ./roborock.nix + ./scenes ./scene-switch.nix ./shelly.nix ./sleep.nix diff --git a/hosts/fw/modules/home-assistant/enocean.nix b/hosts/fw/modules/home-assistant/enocean.nix index 200a5de..c3d22b9 100644 --- a/hosts/fw/modules/home-assistant/enocean.nix +++ b/hosts/fw/modules/home-assistant/enocean.nix @@ -7,6 +7,13 @@ name = "enocean_switch_pc"; } ]; + "binary_sensor bed_1" = [ + { + platform = "enocean"; + id = [ 254 207 162 105 ]; + name = "enocean_switch_bed_1"; + } + ]; sensor = [ { name = "Bathroom HT"; diff --git a/hosts/fw/modules/home-assistant/scenes/date.nix b/hosts/fw/modules/home-assistant/scenes/date.nix new file mode 100644 index 0000000..92d4f31 --- /dev/null +++ b/hosts/fw/modules/home-assistant/scenes/date.nix @@ -0,0 +1,27 @@ +{ pkgs, ... }: +{ + services.home-assistant.config = { + scene = [ + { + name = "Date Night"; + entities = { + "light.livingroom_showcase" = { + state = "on"; + brightness = 255; + rgb_color = [255 110 84]; + }; + "light.bar_led" = { + state = "on"; + brightness = 255; + rgb_color = [255 110 84]; + }; + "light.shapes_1e51" = { + state = "on"; + brightness = 124; + effect = "Date Night"; + }; + }; + } + ]; + }; +} diff --git a/hosts/fw/modules/home-assistant/scenes/default.nix b/hosts/fw/modules/home-assistant/scenes/default.nix new file mode 100644 index 0000000..e310e4a --- /dev/null +++ b/hosts/fw/modules/home-assistant/scenes/default.nix @@ -0,0 +1,6 @@ +{ pkgs, ... }: +{ + imports = [ + ./date.nix + ]; +} diff --git a/hosts/fw/modules/web/default.nix b/hosts/fw/modules/web/default.nix index 4957903..df99ac5 100644 --- a/hosts/fw/modules/web/default.nix +++ b/hosts/fw/modules/web/default.nix @@ -54,7 +54,7 @@ in { ../../utils/modules/lego/lego.nix # ../../utils/modules/borgbackup.nix - ./phpldapadmin.nix + # ./phpldapadmin.nix ./zammad.nix ./proxies.nix ./matrix.nix