Add a few things for dangerously hot days, for use in Node-RED

This commit is contained in:
2023-08-22 12:24:34 -04:00
parent a7df870757
commit 18524eec61
2 changed files with 16 additions and 0 deletions

View File

@ -95,6 +95,11 @@ input_boolean:
name: Hot Day
icon: mdi:heat-wave
# Activated (manually) to immediately put all climate devices into their best cooling configurations
meltdown_protocol:
name: Meltdown Protocol
icon: mdi:skull-crossbones
# Activated if the day will be excessively cold. For use with automations for daytime climate control.
cold_day:
name: Cold Day

View File

@ -235,6 +235,17 @@ template:
{% else %}
No Trigger
{% endif %}
danger: >
{% set day = states('sensor.today_corrected_high_temp') | int %}
{% set night = states('sensor.overnight_lowest_temperature') | int %}
{% set dayThreshold = states('input_number.extended_heat_threshold') | int + 10 %}
{% set nightThreshold = states('input_number.hot_overnight_threshold') | int + 10 %}
{% set hotDayThreshold = states('input_number.hot_day_threshold') | int + 5 %}
{% if (day >= dayThreshold and night >= nightThreshold) or day >= hotDayThreshold %}
Extreme
{% else %}
Normal
{% endif %}
- name: "Lightning Warning"
unique_id: edaddfc4-f7f0-4d75-aada-a2c588afe029
state: "{{ states('sensor.blitzortung_lightning_counter') | int > 0 }}"