🔥 Advanced Heating Control

:fire: ADVANCED HEATING CONTROL :fire:

Features

🔥 heating / ❄️ cooling based on
    👥 people presence
    🗓️ multiple schedulers
    🚶 presence sensor
    ↔️ proximity aka geo fencing
🏃 away temperature offset
🥶 frost protection
😡 adjustable aggressive mode
🌤️ activation based on weather, temperature or boolean entities
🎛️ granular schedule adjustments 
🪟 multiple window open detection
🎈 party mode
🤝 guest mode
🧭 thermostat calibration for the most common devices (Tado, Aqara, Popp / Danfoss / Hive, Tuya)
⚙️ several tweaks for fixing your thermostat issues
🎬 custom action
🤫 calm & 💪 reliable

Latest Version: 4.2.6
Documentation: work in progress

Major Changelogs: 4.0 | 4.1 | 4.2

Known issues

  • nothing atm

Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.

ko-fi

Thanks for testing, reporting and debugging to everyone especially: sben, sourdistorne, dario2 , coldspark29 , technikhaus, tirol3, stephanschleichstr13, bandit79, Mar1us, vajdum. Ziegelsandundspucke, mukrop, k-dani, allard77, hainfelder, Appox, NikB, kitus, David883, p6Dave, fir3dragon

:fire: AHCdev :fire:

Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.

Changes in current developer version

PLANNED FEATURES

  • window detection / calibration only
  • calendar support
  • scene based reset (last known temperature will be taken not the static one)
  • more adjustable limits for aggressive mode
  • firing events with calibration and heating data
  • away temperature - lower temperature when scheduler is on but nobody is home
0 voters
  • logbook entries (temperature,mode,calibration)

You encounter a problem?

  1. Check if you’re running the latest version.
  2. If it’s the case, describe your problem.
    1. What do you want to achieve?
    2. What doesn’t work?
  3. Set debug level to warning
  4. Trigger you automation
  5. Share your tace log for example here
  6. Give me some time to check :wink:

How do I get a trace log?

  1. Navigate to your automations
  2. Find your automation and click on three-dots-menu
  3. Click on traces
  4. Select a trace with the upper arrows
  5. Click on three-dots-menu again
  6. Click on download trace

Also you can create issues on my github repo.

FAQ

Hints

To make long entering / leaving durations for persons and open / closing durations for windows work properly I recommend to setup the uptime integration.

Open your Home Assistant instance and start setting up a new integration.

Calendar Based Scheduler Selector Sensor

Here is an example for my template based binary sensor for holidays. There are two calendars. One holds the national holidays for my region and the other one is my personal calendar. The sensor scans for national holidays and a catchphrase for my personal one.

template:
- trigger:
    - platform: time_pattern
      minutes: /10
  action:
  - service: calendar.get_events
    data:
      start_date_time: "{{ now().replace(hour=0,minute=0,second=0,microsecond=0) }}"
      end_date_time: "{{ now().replace(hour=23,minute=59,second=59,microsecond=999999) }}"
    target:
      entity_id: 
        - calendar.family
        - calendar.holidays
    response_variable: calendar_events
  binary_sensor:
  - name: Holiday
    icon: mdi:palm-tree
    unique_id: holiday
    state: >
      {{  
        ( calendar_events['calendar.family'].events | regex_search('holiday', ignorecase=True) ) or 
        ( calendar_events['calendar.holidays'].events | count > 0 ) 
      }}

AHC Template Sensor

If you want to create your own AHC-Sensor with all the evaluated data just add this to your template section of your configuration. You need one sensor for each of your automations so just copy the code and edit the fields next to the comments.

template:
  - trigger:
      - platform: event
        event_type: ahc_event
        event_data:
          automation: automation.ahc_v4 #CHANGE YOUR AUTOMATION ENTITY-ID HERE
    binary_sensor:
      - name: "AHC Test Room Data" #SET A NAME FOR YOUR SENSOR
        unique_id: AHC Test Room #SET A UNIQUE ID
        state: "{{ trigger.event.data.is_comfort }}"
        attributes:
          automation: "{{ trigger.event.data.automation }}"
          target_temperature: "{{ trigger.event.data.target_temperature }}"
          comfort_temperature: "{{ trigger.event.data.comfort_temperature }}"
          eco_temperature: "{{ trigger.event.data.eco_temperature }}"
          mode: "{{ trigger.event.data.mode }}"
          is_comfort: "{{ trigger.event.data.is_comfort }}"
          is_away_temperature: "{{ trigger.event.data.is_away_temperature }}"
          is_somebody_on_way_home_state: "{{ trigger.event.data.is_somebody_on_way_home_state }}"
          is_party: "{{ trigger.event.data.is_party }}"
          is_guest: "{{ trigger.event.data.is_guest }}"
          is_window_open: "{{ trigger.event.data.is_window_open }}"
          active_scheduler: "{{ trigger.event.data.active_scheduler }}"
          state_scheduler: "{{ trigger.event.data.state_scheduler }}"
          is_person_based: "{{ trigger.event.data.is_person_based }}"
          is_anybody_home: "{{ trigger.event.data.is_anybody_home }}"
          state_presence_sensor: "{{ trigger.event.data.state_presence_sensor }}"
          state_presence_scheduler: "{{ trigger.event.data.state_presence_scheduler }}"
          is_presence_on: "{{ trigger.event.data.is_presence_on }}"
          is_frost_protection: "{{ trigger.event.data.is_frost_protection }}"
          last_temperature_change: "{{ iif(trigger.event.data.is_change,now(),this.attributes.last_calibration) }}"
          last_calibration: "{{ iif(trigger.event.data.is_calibration,now(),this.attributes.last_calibration) }}"
          state_presence_sensor_presence_scheduler_combined: "{{ trigger.event.data.state_presence_sensor_presence_scheduler_combined }}"
          is_presence_based: "{{ trigger.event.data.is_presence_based }}"
          is_force_max_temperature: "{{ trigger.event.data.is_force_max_temperature }}"

If you have questions or feature request, feel free to comment this thread.

Greets!

References

UI inspired: ☀️ Cover Control Automation (CCA) - a comprehensive and highly configurable roller blind blueprint

My blueprints

Simple scene toggle
Yet not another door/window/sensor open warning notification with auto close
Zone notification extended
Advanced Heating Control

39 Likes

very nice. Is it possible to switch back to the previous temperature after x hours of manual intervention?

Maybe you can trigger the heating automation using another like this:

description: ""
mode: restart
trigger:
  - platform: state
    entity_id:
      - climate.your_trv
    attribute: temperature
condition: []
action:
  - delay:
      hours: 2
      minutes: 0
      seconds: 0
      milliseconds: 0
  - service: automation.trigger
    data: {}
    target:
      entity_id: automation.your_heating_automation
3 Likes

Hi panhans!

Thanks for providing this! I tried implementing it today, but I failed. First one obvious thing:
The window entity is not optional and I am not able to save the automation if I have no window sensor.
I fixed that by creating a new sensor, which extracts the window detection of my thermostat (Fritz! Thermo)

binary_sensor:
  - platform: template
    sensors:
      windowhelper:
        unique_id: d62d73da-7839-4cb4-8dd4-5a83b1f52923
        friendly_name: "Heizung-Helfer-Fenster-Proxy"
        device_class: window
        value_template: "{{ state_attr('climate.wohnbereich_linkes_fenster', 'window_open') }}"

But it didn’t help:
No matter what I try, the automation always sends an off state to the thermostat.
Do you have any idea, what I am doing wrong?

My config:

(both winter_mode and party_mode entities are helpers and set to off, at least one person is present, window state is closed, schedule is marked 9-22)

1 Like

Hmm, I have one automation without window running atm. I’ll try to set up a new one.
If winter mode is off heating is always off. Try to set it to on.

1 Like

That works, thank you! I am used to something like “Summer-Mode”, so my thinking got mixed up.

Great work! Super easy to set up and works as intended!
Nevertheless, the party mode doesn’t override my schedule. Is it a known issue or do you need further details?

I’d faced that issue a few days ago and fixed it this week. Maybe you try to update the blueprint.

1 Like

Works like a charm! Thank you!

1 Like

thx you very much, it works great,
would it be possible to make this work with a separate temperature sensor?

What should the external sensor do? Do you want the outside temperature to turn on/off heating?

2 Likes

thx for your answer,

i hoped to use a different temp sensor for the room,
my thermostats temperature is reporting way to high degrees. (i tried to offset the temperature, but its a total mess)
with an option for a different room temp sensor, one could just simply choose a sensor of choice.

hope that makes sense

This blueprint only controls temperature. There are other blueprints/automations for your issue. It also depends by your valves, integration and calibration attribute.

The most calibration automation can be used parallel to this blueprint. If you’re using tuya and z2m this thread could help you:

@panhans: I am just trying your blueprint as well. Why don’t you have multiple window entities? Like this you have to create a template and combine all window contacts if your room has more than one. I just made a new one and changed it to multiple. I would also like to add thermometers to the blueprint, that are used as current temperature, because the ones at the valves are not a good choice in some cases. Will see how I can do that

  1. Home assistant blueprints cant handle multiple optional entities used as trigger entities. There is an issue opend for that and also some threads here in the community but for most people not a big thing. Dont know if its ever be possible. So I must decide if I go with one optional window entity or multiple window support. Since some people use the build in window open mechanism I decide to chose the first option. Other blueprints are using time based periodical checks but I am not a friend of this kind of polling.

  2. For using an external temperatur entity for calibration I wrote something one post above. Since this is much wanted I will dive into to see what I can do for this blueprint.

2 Likes

Ah yes, just setting the windows to multiple breaks the automation. Pity that this isn’t supported.

Haven’t read your post above. Will have a look into it. Thx

And you dont need a template. Simply create a helper and group your windows and select this group as your window entity. :wink:

2 Likes

Yes, thank you. Works like a charm

The blueprint is great apart from that. I could get rid of my complicated automations. I had one automation for turning the heaters on and one for turning them off. Horrible…

When the external temperature sensors are implemented, the blueprint will be perfect! :wink:

1 Like

Hey!

Thanks for this amazing blueprint, I got one question.
My EvoHome Systems requires the preset mode to Permanent otherwise it will follow a strange inside build schedule…

How can I add the preset mode to the Blueprint?
For Example, HVAC Mode Heat + Preset Mode: Permanent

Second question is, I can’t set the temperature to 19.5 in the Blueprint, am I doing something wrong?

Hope you can help me out with this!

1 Like

I found something like this that works for me but I am not sure where I can leave this code in the blueprint:

service: climate.set_preset_mode
data:
preset_mode: permanent
target:
entity_id: climate.living_room