From d219a6511039f92c5aea45890c8c2b680eeacb66 Mon Sep 17 00:00:00 2001 From: Ingolf Wagner Date: Fri, 5 Jun 2020 00:15:46 +0200 Subject: [PATCH] light-control: update --- configs/pepe/home-assistant/light-control.nix | 26 +++++++++---------- pkgs/light-control/default.nix | 4 +-- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/configs/pepe/home-assistant/light-control.nix b/configs/pepe/home-assistant/light-control.nix index 9e691ed..776112d 100644 --- a/configs/pepe/home-assistant/light-control.nix +++ b/configs/pepe/home-assistant/light-control.nix @@ -29,55 +29,55 @@ } ]; sensors = let - door = { topic, rooms }: { + door = { topic, room }: { topic = topic; key = "contact"; - rooms = rooms; + room = room; invert_state = true; delay = 90; }; - motion = { topic, rooms }: { + motion = { topic, room }: { topic = topic; key = "occupancy"; - rooms = rooms; + room = room; delay = 60; }; in [ (motion { topic = "zigbee2mqtt/motion_sensor_2"; - rooms = [ "bed_room" ]; + room = "bed_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_7"; - rooms = [ "bed_room" ]; + room = "bed_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_1"; - rooms = [ "kitchen_room" ]; + room = "kitchen_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_3"; - rooms = [ "living_room" ]; + room = "living_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_4"; - rooms = [ "living_room" ]; + room = "living_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_5"; - rooms = [ "bath_room" ]; + room = "bath_room"; }) (motion { topic = "zigbee2mqtt/motion_sensor_8"; - rooms = [ "bath_room" ]; + room = "bath_room"; }) (door { topic = "zigbee2mqtt/door_sensor_2"; - rooms = [ "floor_room" ]; + room = "floor_room"; }) (door { topic = "zigbee2mqtt/door_sensor_4"; - rooms = [ "floor_room" ]; + room = "floor_room"; }) ]; switches = let diff --git a/pkgs/light-control/default.nix b/pkgs/light-control/default.nix index 48b01c5..d2782c6 100644 --- a/pkgs/light-control/default.nix +++ b/pkgs/light-control/default.nix @@ -5,8 +5,8 @@ rustPlatform.buildRustPackage rec { version = "0.1.0"; src = fetchgit { url = "https://git.ingolf-wagner.de/palo/light-control.git"; - rev = "af6f9f78180af24f329736f04bda07cf90ab98c9"; - sha256 = "0yc5chl3pfx91rr59ngjfj0dahipjc0jkclxs2w0fg1j5aknxinc"; + rev = "2009a829681c32127cc8b74dac759db566fe9599"; + sha256 = "0hqrnqbzwpvgpx8sb13m89kz60pv6xgym3dhp3q56383hafijb4c"; }; cargoSha256 = "1yzkbj36sx4vc8dsgcxahrvn33ci2ad1cpd1shcismw33k63rimh";