Rename house mode to bedroom mode

This commit is contained in:
2021-10-13 22:16:23 +03:00
parent 8808202ea2
commit c0c6263e2c
16 changed files with 60 additions and 61 deletions
@@ -17,7 +17,7 @@ trigger:
condition:
condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "day"
action:
@@ -129,13 +129,13 @@ cards:
- automation.notification_door_opened
- type: entities
title: House Mode
title: Bedroom Mode
show_header_toggle: false
entities:
- automation.house_mode_set_to_day
- automation.house_mode_set_to_bed
- automation.house_mode_set_to_night
- automation.house_mode_set_to_day_if_bedroom_door_was_opened
- automation.bedroom_mode_set_to_day
- automation.bedroom_mode_set_to_bed
- automation.bedroom_mode_set_to_night
- automation.bedroom_mode_set_to_day_if_bedroom_door_was_opened
- type: entities
title: Guest mode
@@ -47,13 +47,13 @@
name: Speech
- type: custom:button-card
template: v3_button
entity: input_select.house_mode
name: House
entity: input_select.bedroom_mode
name: Bedroom
tap_action:
action: call-service
service: input_select.select_next
service_data:
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
- type: horizontal-stack
cards:
+3 -3
View File
@@ -1,9 +1,9 @@
binary_sensor.house_mode:
title: House mode
binary_sensor.bedroom_mode:
title: Bedroom mode
card:
type: entities
entities:
- input_select.house_mode
- input_select.bedroom_mode
binary_sensor.kitchen_motion_occupancy:
title: Kitchen motion
@@ -37,11 +37,11 @@ automation:
data_template:
entity_id: light.master_bedroom
brightness_pct: >-
{% if not is_state('input_select.house_mode', 'day') %} 40 {% else %} 100 {% endif %}
{% if not is_state('input_select.bedroom_mode', 'day') %} 40 {% else %} 100 {% endif %}
- service: script.bed_led_on
data_template:
brightness_pct: >-
{% if not is_state('input_select.house_mode', 'day') %} 40 {% else %} 100 {% endif %}
{% if not is_state('input_select.bedroom_mode', 'day') %} 40 {% else %} 100 {% endif %}
button_1_double:
- service: light.turn_off
@@ -53,7 +53,7 @@ automation:
entity_id: light.master_bedroom_main
brightness_pct: >-
{% if not is_state('input_select.house_mode', 'day') %}
{% if not is_state('input_select.bedroom_mode', 'day') %}
40
{% else %}
100
@@ -72,7 +72,7 @@ automation:
- light.bedside
brightness_pct: >-
{% if not is_state('input_select.house_mode', 'day') %}
{% if not is_state('input_select.bedroom_mode', 'day') %}
40
{% else %}
100
@@ -24,19 +24,19 @@ automation:
- service: script.bed_led_toggle
data_template:
brightness_pct: >-
{% if is_state('input_select.house_mode', 'night') %} 40 {% else %} 100 {% endif %}
{% if is_state('input_select.bedroom_mode', 'night') %} 40 {% else %} 100 {% endif %}
- service: light.toggle
data_template:
entity_id: >-
{% if is_state('input_select.house_mode', 'day') %}
{% if is_state('input_select.bedroom_mode', 'day') %}
light.master_bedroom_main
{% elif is_state('input_select.house_mode', 'bed') %}
{% elif is_state('input_select.bedroom_mode', 'bed') %}
light.bedside
{% endif %}
brightness_pct: >-
{% if is_state('input_select.house_mode', 'night') %} 40 {% else %} 100 {% endif %}
{% if is_state('input_select.bedroom_mode', 'night') %} 40 {% else %} 100 {% endif %}
double_click:
- service: light.toggle
@@ -46,8 +46,8 @@ automation:
- service: script.bed_led_toggle
data_template:
brightness_pct: >-
{% if is_state('input_select.house_mode', 'night') %} 40 {% else %} 100 {% endif %}
{% if is_state('input_select.bedroom_mode', 'night') %} 40 {% else %} 100 {% endif %}
hold:
- service: input_select.select_next
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
@@ -27,7 +27,7 @@ automation:
entity_id: light.living_room_main
brightness_pct: >-
{% if is_state('input_select.house_mode', 'night') %}
{% if is_state('input_select.bedroom_mode', 'night') %}
40
{% else %}
100
@@ -39,7 +39,7 @@ automation:
entity_id: light.living_room_ambient
brightness_pct: >-
{% if is_state('input_select.house_mode', 'night') %}
{% if is_state('input_select.bedroom_mode', 'night') %}
40
{% else %}
100
+1 -1
View File
@@ -98,7 +98,7 @@ automation:
to: "off"
condition:
condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "day"
action:
- service: script.sonos_join_bedroom
@@ -1,7 +1,7 @@
# Mode config
input_select:
house_mode:
name: House mode
bedroom_mode:
name: Bedroom mode
icon: mdi:home-analytics
options:
- day
@@ -11,14 +11,14 @@ input_select:
binary_sensor:
- platform: template
sensors:
house_mode:
friendly_name: House mode
value_template: "{{ states('input_select.house_mode') }}"
bedroom_mode:
friendly_name: Bedroom mode
value_template: "{{ states('input_select.bedroom_mode') }}"
icon_template: >-
{% if is_state('input_select.house_mode', 'day') %}
{% if is_state('input_select.bedroom_mode', 'day') %}
mdi:weather-sunny
{% elif is_state('input_select.house_mode', 'bed') %}
{% elif is_state('input_select.bedroom_mode', 'bed') %}
mdi:bed-king-outline
{% else %}
mdi:weather-night
@@ -26,31 +26,31 @@ binary_sensor:
automation:
- alias: House mode · Set to day
- alias: Bedroom mode · Set to day
trigger:
platform: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
to: "day"
action:
- service: script.routine_waking_up
- alias: House mode · Set to bed
- alias: Bedroom mode · Set to bed
trigger:
platform: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
to: "bed"
action:
- service: script.routine_bedtime
- alias: House mode · Set to night
- alias: Bedroom mode · Set to night
trigger:
platform: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
to: "night"
action:
- service: script.routine_good_night
- alias: House mode · Set to day if bedroom door was opened
- alias: Bedroom mode · Set to day if bedroom door was opened
trigger:
- platform: state
entity_id: binary_sensor.bedroom_door
@@ -63,13 +63,13 @@ automation:
- condition: not
conditions:
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "day"
- condition: state
entity_id: input_boolean.georgi_home
state: "on"
action:
- service: input_select.select_option
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
data:
option: "day"
+4 -4
View File
@@ -17,10 +17,10 @@ group:
- automation.music_living_room_play_pause_on_desk_switch_hold
- automation.music_master_bedroom_play_pause_on_switch_hold
- automation.notification_door_opened
- automation.house_mode_set_to_night
- automation.house_mode_set_to_bed
- automation.house_mode_set_to_day
- automation.house_mode_toggle_on_bedside_switch_hold
- automation.bedroom_mode_set_to_night
- automation.bedroom_mode_set_to_bed
- automation.bedroom_mode_set_to_day
- automation.bedroom_mode_toggle_on_bedside_switch_hold
- automation.security_door_opened_while_away
- automation.purifier_turn_on_low_humidity
- automation.purifier_turn_on_low_air_quality
+5 -5
View File
@@ -22,7 +22,7 @@ automation:
entity_id: input_boolean.alarm_enabled
state: "on"
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "night"
action:
- service: script.music_play
@@ -31,7 +31,7 @@ automation:
- delay: 00:01:00
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "night"
- service: script.sonos_say
data:
@@ -45,7 +45,7 @@ automation:
- delay: 00:02:00
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "night"
- service: script.sonos_say
data:
@@ -59,7 +59,7 @@ automation:
- delay: 00:05:00
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: "night"
- service: script.sonos_say
data:
@@ -74,7 +74,7 @@ automation:
- alias: Alarm · Set time
trigger:
platform: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
to: "day"
action:
- service: input_datetime.set_datetime
+3 -4
View File
@@ -14,7 +14,7 @@ automation:
title: "📱 *iOS Module*"
message: "iOS alarm is off. Switching to Day Mode!"
- service: input_select.select_option
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
data:
option: "day"
@@ -27,7 +27,7 @@ automation:
title: "📱 *iOS Module*"
message: "iOS wind_down is on. Switching to Bed Mode!"
- service: input_select.select_option
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
data:
option: "bed"
@@ -40,7 +40,6 @@ automation:
title: "📱 *iOS Module*"
message: "iOS bedtime is on. Switching to Night Mode!"
- service: input_select.select_option
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
data:
option: "night"
@@ -135,7 +135,7 @@ automation:
after: sunset
after_offset: "-02:00:00"
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
action:
- service: light.turn_on
@@ -13,7 +13,7 @@ automation:
# Turn on in Day Mode
- conditions:
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
sequence:
- service: light.turn_on
@@ -42,7 +42,7 @@ automation:
# Turn off in Day Mode
- conditions:
condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
sequence:
- service: light.turn_off
@@ -13,7 +13,7 @@ automation:
# Turn on in Day Mode
- conditions:
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
sequence:
- service: light.turn_on
@@ -57,7 +57,7 @@ automation:
condition: not
conditions:
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
action:
# Turn off in Night Mode
@@ -85,7 +85,7 @@ automation:
minutes: 15
condition:
condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'day'
action:
# Turn off in Day Mode
+1 -1
View File
@@ -33,7 +33,7 @@ script:
- condition: not
conditions:
- condition: state
entity_id: input_select.house_mode
entity_id: input_select.bedroom_mode
state: 'night'
# Combine partials for speech message.
- service: script.say_discretely