Include Guest Bedroom in house mode

This commit is contained in:
2021-10-18 23:28:42 +03:00
parent af5e969c2b
commit c4e977b345
25 changed files with 241 additions and 119 deletions
@@ -0,0 +1,20 @@
script:
guest_bedroom_bedside_confirm:
sequence:
- service: scene.create
data:
scene_id: guest_bedroom_before_confirm
snapshot_entities:
- light.light_lohas_6
- service: light.turn_on
entity_id: light.light_lohas_6
data:
rgb_color: [110, 255, 0]
- delay: 00:00:02
- service: light.turn_on
entity_id: light.light_lohas_6
data:
color_temp: "{{ 400 if is_state('sun.sun', 'above_horizon') else 500 }}"
- service: scene.turn_on
entity_id: scene.guest_bedroom_before_confirm
- delay: 00:00:01
@@ -13,8 +13,8 @@ automation:
# Turn on in Day Mode
- conditions:
- condition: state
entity_id: input_select.bedroom_mode
state: 'day'
entity_id: binary_sensor.someone_sleeping
state: "off"
sequence:
- service: light.turn_on
entity_id:
@@ -41,9 +41,9 @@ automation:
- choose:
# Turn off in Day Mode
- conditions:
condition: state
entity_id: input_select.bedroom_mode
state: 'day'
- condition: state
entity_id: binary_sensor.someone_sleeping
state: 'off'
sequence:
- service: light.turn_off
entity_id: light.hallway
@@ -13,7 +13,7 @@ automation:
# Turn on in Day Mode
- conditions:
- condition: state
entity_id: input_select.bedroom_mode
entity_id: sensor.house_mode
state: 'day'
sequence:
- service: light.turn_on
@@ -57,7 +57,7 @@ automation:
condition: not
conditions:
- condition: state
entity_id: input_select.bedroom_mode
entity_id: sensor.house_mode
state: 'day'
action:
# Turn off in Night Mode
@@ -85,7 +85,7 @@ automation:
minutes: 15
condition:
condition: state
entity_id: input_select.bedroom_mode
entity_id: sensor.house_mode
state: 'day'
action:
# Turn off in Day Mode
@@ -151,6 +151,7 @@ light:
- light.living_room
- light.master_bedroom
- light.hallway
- light.light_lohas_6
- platform: group
name: Ceiling
@@ -135,6 +135,10 @@ light:
# rgb_value_template: "{{ (value_json.Color[0:2]|int(base=16),value_json.Color[2:4]|int(base=16),value_json.Color[4:6]|int(base=16)) | join(',')}}"
qos: 1
retain: false
effect_command_topic: "cmnd/light_lohas_2/Scheme"
effect_state_topic: "tele/light_lohas_2/STATE"
effect_value_template: "{{value_json.Scheme}}"
effect_list: [0, 1, 2, 3, 4]
# - platform: mqtt
# name: "light_lohas_3"
@@ -246,6 +250,10 @@ light:
# rgb_value_template: "{{ (value_json.Color[0:2]|int(base=16),value_json.Color[2:4]|int(base=16),value_json.Color[4:6]|int(base=16)) | join(',')}}"
qos: 1
retain: false
effect_command_topic: "cmnd/light_lohas_6/Scheme"
effect_state_topic: "tele/light_lohas_6/STATE"
effect_value_template: "{{value_json.Scheme}}"
effect_list: [0, 1, 2, 3, 4]
- platform: "mqtt"
name: "ledvance_1"