many changes
This commit is contained in:
@@ -421,21 +421,62 @@
|
||||
"light.bathroom_bulb_2"
|
||||
];
|
||||
}
|
||||
{
|
||||
platform = "switch";
|
||||
name = "Hallway Switch";
|
||||
entity_id = "switch.hallway";
|
||||
}
|
||||
{
|
||||
platform = "group";
|
||||
name = "Hallway Lights";
|
||||
all = true;
|
||||
entities = [
|
||||
"light.hallway_switch"
|
||||
"light.hallway_light_switch_mini_switch"
|
||||
"light.hallway_bulb_1"
|
||||
"light.hallway_bulb_2"
|
||||
];
|
||||
}
|
||||
{
|
||||
platform = "template";
|
||||
lights = {
|
||||
hallway_group_proxy = {
|
||||
friendly_name = "Hallway Lights (Proxy)";
|
||||
# follow the real group’s on/off state
|
||||
value_template = "{{ is_state('light.hallway_lights','on') }}";
|
||||
turn_on = {
|
||||
service = "light.turn_on";
|
||||
data = { entity_id = "light.hallway_lights"; };
|
||||
};
|
||||
turn_off = {
|
||||
service = "light.turn_off";
|
||||
data = { entity_id = "light.hallway_lights"; };
|
||||
};
|
||||
# brightness support
|
||||
set_level = {
|
||||
service = "light.turn_on";
|
||||
data_template = {
|
||||
entity_id = "light.hallway_lights";
|
||||
brightness = "{{ brightness }}";
|
||||
};
|
||||
};
|
||||
# color temperature support (if you have CT-capable bulbs)
|
||||
set_temperature = {
|
||||
service = "light.turn_on";
|
||||
data_template = {
|
||||
entity_id = "light.hallway_lights";
|
||||
color_temp = "{{ color_temp }}";
|
||||
};
|
||||
};
|
||||
# RGB color support
|
||||
set_color = {
|
||||
service = "light.turn_on";
|
||||
data_template = {
|
||||
entity_id = "light.hallway_lights";
|
||||
rgb_color = [ "{{ red }}" "{{ green }}" "{{ blue }}" ];
|
||||
};
|
||||
};
|
||||
# always report as “available”
|
||||
availability_template = "true";
|
||||
# declare which color modes you need
|
||||
supported_color_modes = [ "brightness" "color_temp" "rgb" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
{
|
||||
platform = "switch";
|
||||
name = "Toilet Switch";
|
||||
|
||||
Reference in New Issue
Block a user