Created
August 6, 2023 11:33
-
-
Save rock3r/5954b87184c6536bb8f2ea922bc97f02 to your computer and use it in GitHub Desktop.
Home Assistant blueprint to turn a HVAC on or off based on a binary sensor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
blueprint: | |
name: HVAC automation | |
source_url: https://gist.github.com/rock3r/5954b87184c6536bb8f2ea922bc97f02 | |
description: Turn a HVAC on or off based on a binary sensor | |
domain: automation | |
input: | |
opening_sensor: | |
name: Window/Door sensor | |
description: The window or door sensor to use to drive the Tado valve | |
selector: | |
entity: | |
domain: binary_sensor | |
device_class: window | |
target_hvac: | |
name: Target HVAC | |
description: The HVAC climate control to target | |
selector: | |
entity: | |
domain: climate | |
trigger: | |
- platform: state | |
entity_id: !input opening_sensor | |
action: | |
- service: climate.set_hvac_mode | |
data: | |
hvac_mode: > | |
{% if trigger.to_state.state == 'on' %}off{% else %}auto{% endif %} | |
target: | |
entity_id: !input target_hvac | |
- service: notify.mobile_app_pixel_7_pro_seb | |
data_template: | |
message: > | |
{{ trigger.to_state.name }}: {% if trigger.to_state.state == 'on' | |
%}disattivato riscaldamento (finestra aperta){% else %}riattivato | |
riscaldamento (finestra chiusa){% endif %} | |
title: Automazione Tado | |
mode: single |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment