light-control: wip
This commit is contained in:
parent
60d9482999
commit
bc1f5ae7ac
1 changed files with 58 additions and 57 deletions
|
@ -45,20 +45,20 @@ in {
|
|||
};
|
||||
}) allDevices;
|
||||
|
||||
#services.homeAssistantConfig = {
|
||||
services.homeAssistantConfig = {
|
||||
|
||||
# light = lib.mapAttrsToList (name:
|
||||
# { ... }: {
|
||||
# platform = "mqtt";
|
||||
# name = name;
|
||||
# state_topic = "zigbee2mqtt/${name}";
|
||||
# availability_topic = "zigbee2mqtt/bridge/state";
|
||||
# command_topic = "zigbee2mqtt/${name}/set";
|
||||
# value_template = "{{ value_json.click }}";
|
||||
# brightness = true;
|
||||
# color_temp = true;
|
||||
# schema = "json";
|
||||
# }) allDevices;
|
||||
light = lib.mapAttrsToList (name:
|
||||
{ ... }: {
|
||||
platform = "mqtt";
|
||||
name = name;
|
||||
state_topic = "zigbee2mqtt/${name}";
|
||||
availability_topic = "zigbee2mqtt/bridge/state";
|
||||
command_topic = "zigbee2mqtt/${name}/set";
|
||||
value_template = "{{ value_json.click }}";
|
||||
brightness = true;
|
||||
color_temp = true;
|
||||
schema = "json";
|
||||
}) allDevices;
|
||||
|
||||
# sensor = with lib;
|
||||
# mapAttrsToList (name:
|
||||
|
@ -108,6 +108,7 @@ in {
|
|||
# all_lights.entities =
|
||||
# lib.mapAttrsToList (name: { ... }: "light.${name}") allDevices;
|
||||
# };
|
||||
#};
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue