From 90c3e1a8531f38eb8a3ccc40a284870d1aaf19ff Mon Sep 17 00:00:00 2001 From: Georgi Gardev Date: Sun, 14 Jun 2020 21:43:08 +0300 Subject: [PATCH] Fix window sensor names --- config/packages/modules/notification.yaml | 2 +- config/packages/modules/presence.yaml | 2 +- config/packages/modules/security.yaml | 2 +- config/packages/modules/system.yaml | 4 ++-- config/templates/partials/window_check.yaml | 4 ++-- config/templates/partials/window_suggestions.yaml | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/config/packages/modules/notification.yaml b/config/packages/modules/notification.yaml index dc493d0..22d1f24 100644 --- a/config/packages/modules/notification.yaml +++ b/config/packages/modules/notification.yaml @@ -42,7 +42,7 @@ automation: - alias: Notification · Door opened trigger: platform: state - entity_id: binary_sensor.front_door_on_off + entity_id: binary_sensor.front_door to: "on" for: minutes: 2 diff --git a/config/packages/modules/presence.yaml b/config/packages/modules/presence.yaml index e73bd80..c62e9c6 100644 --- a/config/packages/modules/presence.yaml +++ b/config/packages/modules/presence.yaml @@ -99,7 +99,7 @@ automation: data: title: "🏠 *Presence Module · Arrival Detection*" message: "Device marked as home. Waiting for door to open!" - - wait_template: "{{ is_state('binary_sensor.front_door_on_off', 'on') }}" + - wait_template: "{{ is_state('binary_sensor.front_door', 'on') }}" continue_on_timeout: false timeout: 00:15:00 - service: input_boolean.turn_on diff --git a/config/packages/modules/security.yaml b/config/packages/modules/security.yaml index c9282ef..b40823a 100644 --- a/config/packages/modules/security.yaml +++ b/config/packages/modules/security.yaml @@ -29,7 +29,7 @@ automation: - alias: Security · Door opened while away trigger: - platform: state - entity_id: binary_sensor.front_door_on_off + entity_id: binary_sensor.front_door to: "on" condition: condition: and diff --git a/config/packages/modules/system.yaml b/config/packages/modules/system.yaml index eaf9a3b..43dab84 100644 --- a/config/packages/modules/system.yaml +++ b/config/packages/modules/system.yaml @@ -74,8 +74,8 @@ automation: Guest mode: {{ states('input_boolean.guest_mode') }} Windows: - Living room: {{ states('binary_sensor.living_room_right_window_on_off') }} - Master bedroom: {{ states('binary_sensor.bedroom_right_window_on_off') }} + Living room: {{ states('binary_sensor.living_room_right_window') }} + Master bedroom: {{ states('binary_sensor.bedroom_right_window') }} Lights: Living room: {{ states('light.living_room') }} diff --git a/config/templates/partials/window_check.yaml b/config/templates/partials/window_check.yaml index 6facbc6..0093c04 100644 --- a/config/templates/partials/window_check.yaml +++ b/config/templates/partials/window_check.yaml @@ -1,8 +1,8 @@ >- {%- if is_state('group.all_windows', 'on') -%} - {%- if is_state('binary_sensor.living_room_right_window_on_off', 'on') -%} The living room window is opened. {% endif %} - {%- if is_state('binary_sensor.bedroom_right_window_on_off', 'on') -%} The master bedroom window is opened. {%- endif -%} + {%- if is_state('binary_sensor.living_room_right_window', 'on') -%} The living room window is opened. {% endif %} + {%- if is_state('binary_sensor.bedroom_right_window', 'on') -%} The master bedroom window is opened. {%- endif -%} {%- else -%} All windows are closed. {%- endif -%} diff --git a/config/templates/partials/window_suggestions.yaml b/config/templates/partials/window_suggestions.yaml index 810a2e9..517cbc6 100644 --- a/config/templates/partials/window_suggestions.yaml +++ b/config/templates/partials/window_suggestions.yaml @@ -16,12 +16,12 @@ {%- if (states('sensor.dark_sky_temperature') | int) < (states('sensor.bedroom_weather_temperature') | int) -%} - {%- if is_state('binary_sensor.bedroom_right_window_on_off', 'off') + {%- if is_state('binary_sensor.bedroom_right_window', 'off') and (states('sensor.bedroom_weather_temperature') | int) > 22 -%} You should probably open the master bedroom window{{ getting_hot | random }} {%- endif -%} - {%- if is_state('binary_sensor.bedroom_right_window_on_off', 'on') + {%- if is_state('binary_sensor.bedroom_right_window', 'on') and (states('sensor.bedroom_weather_temperature') | int) < 18 -%} You should probably close the master bedroom window{{ getting_cold | random }} {%- endif -%}