HVAC Automation scheduling

I’m trying to figure out if I’m doing things a hard way when there is actually an easy one… It has to do with how I configure automation conditions for HVAC (in my case only heating), and whether we are home or not.

Our house is heated with floor heating, which means it’s usually not turned off at all. At most it’s reduced by 1 degree, and it takes more than an hour to heat up again. So what I do is turn the heating 1 degree lower at night or when we are not home (for longer than 4 hours at least). This means I have to schedule my automations and can’t rely on a presence sensor. This is how I have it currently running:

Sleep or at work Schedule
I have a schedule entity with the times when we are usually sleeping or away at work. We rarely deviate from this, and I can use a button or notification to override it for the sleeping part, so that’s easy.
Typically: High in evening when we are back from work, high on the weekend, low all other times.

Working Home Toggle
I have two toggles that we manually turn on if we are planning on working from home the next day. This resets every day unless I manually changed it that day.
The idea of this toggle is to override the “low” schedule from above.

’Away for longer’ Schedule
I have a schedule that I change every time when I know we’re going to be away for the weekend or something similar. This can then override the setting for when we are ‘normally’ home.
The idea of this schedule is to override the “high” schedule from above.

So currently, for each automation I run, I do the same checks to see what setting the floor heating, the floor heating pump, etc. need. So for each automation it gets quite complicated with ANDs and ORs in conditions.

I’m wondering if there’s a way to have a sort of ‘generic’ helper that can simply say “heating should be high now” or “heating should be low now”, that I can reuse in automations. Is that possible, and would that be a more logical route to go?

Any other thoughts on how I can simplify this?

It’s kind of hard to offer “improvements” when we can’t see the actual automation(s) you are using and how entities relate to one another.

If you do not have a thermostat entity, you might want to look into the Generic Thermostat integration which will let you create some presets like away, sleep, and home that can be called by automations or scripts.

Here’s an example of an automation. The reason I didn’t post them is because I think it’s the underlying thinking that is flawed, not the automations themselves. I have a few.

  • The one below automates the floor heating pump, so it doesn’t pump when no heat is needed.
  • I have another that changes the temperature to high or low depending on what I mentioned in my OP
  • I have another that turns the heating higher so my TRVs get warm water (the pump will ensure the living room doesn’t warm up)
  • and then a few more that are related
alias: HVAC - Living Room Floor Pump Automation
description: ""
trigger:
  - platform: state
    entity_id:
      - climate.livingroom_thermostat
    attribute: current_temperature
  - platform: state
    entity_id:
      - climate.livingroom_thermostat
    attribute: temperature
condition: []
action:
  - choose:
      - conditions:
          - condition: and
            conditions:
              - condition: or
                conditions:
                  - condition: state
                    entity_id: schedule.home
                    state: "on"
                  - condition: state
                    entity_id: input_boolean.working_home_inga
                    state: "on"
                  - condition: state
                    entity_id: input_boolean.working_home_reinhardt
                    state: "on"
              - condition: state
                entity_id: schedule.away_no_heating
                state: "off"
              - condition: template
                value_template: >-
                  {% set therm = 'climate.livingroom_thermostat' %}

                  {% if state_attr(therm,'temperature') is not none %}

                  {{ state_attr(therm, 'current_temperature')|float(0) <
                  states('input_number.living_room_home_temperature')|float(0)
                  }}

                  {% endif %}
                alias: If temperature is lower than home temperature
              - condition: state
                entity_id: timer.floor_pump_timer
                state: idle
              - condition: device
                type: is_off
                device_id: XXX
                entity_id: switch.floor_heating_socket
                domain: switch
        sequence:
          - type: turn_on
            device_id: XXX
            entity_id: switch.floor_heating_socket
            domain: switch
          - device_id: XXX
            domain: mobile_app
            type: notify
            message: Living Room Pump ON
          - service: timer.start
            data:
              duration: 0
            target:
              entity_id: timer.floor_pump_timer
      - conditions:
          - condition: and
            conditions:
              - condition: state
                entity_id: schedule.home
                state: "off"
              - condition: template
                value_template: >-
                  {% set therm = 'climate.livingroom_thermostat' %}

                  {% if state_attr(therm,'temperature') is not none %}

                  {{ state_attr(therm, 'current_temperature')|float(0) <
                  states('input_number.living_room_low_temperature')|float(0) }}

                  {% endif %}
                alias: Living Room Temperature is lower than LOW setting
              - condition: state
                entity_id: timer.floor_pump_timer
                state: idle
              - condition: device
                type: is_off
                device_id: XXX
                entity_id: switch.floor_heating_socket
                domain: switch
              - condition: and
                conditions:
                  - condition: state
                    entity_id: input_boolean.working_home_inga
                    state: "off"
                  - condition: state
                    entity_id: input_boolean.working_home_reinhardt
                    state: "off"
                alias: Nobody is working home
        sequence:
          - type: turn_on
            device_id: XXX
            entity_id: switch.floor_heating_socket
            domain: switch
          - device_id: XXX
            domain: mobile_app
            type: notify
            message: Floor Heating Low ON
          - service: timer.start
            data:
              duration: 0
            target:
              entity_id: timer.floor_pump_timer
      - conditions:
          - condition: and
            conditions:
              - condition: or
                conditions:
                  - condition: state
                    entity_id: schedule.home
                    state: "on"
                  - condition: state
                    entity_id: input_boolean.working_home_inga
                    state: "on"
                  - condition: state
                    entity_id: input_boolean.working_home_reinhardt
                    state: "on"
              - condition: template
                value_template: >-
                  {% set therm = 'climate.livingroom_thermostat' %}

                  {% if state_attr(therm,'temperature') is not none %}

                  {{ state_attr(therm, 'current_temperature')|float(0) >=
                  states('input_number.living_room_home_temperature')|float(0)
                  }}

                  {% endif %}
                alias: Living Room Temperature is warm enough for HOME
              - condition: state
                entity_id: timer.floor_pump_timer
                state: idle
              - condition: device
                type: is_on
                device_id: XXX
                entity_id: switch.floor_heating_socket
                domain: switch
        sequence:
          - type: turn_off
            device_id: 942eacc9f0997aa64b943c8143545811
            entity_id: switch.floor_heating_socket
            domain: switch
          - device_id: XXX
            domain: mobile_app
            type: notify
            message: Floor Heating Home OFF
      - conditions:
          - condition: and
            conditions:
              - condition: or
                conditions:
                  - condition: state
                    entity_id: schedule.home
                    state: "off"
                  - condition: state
                    entity_id: schedule.away_no_heating
                    state: "on"
                alias: Either low setting or not home
              - condition: template
                value_template: >-
                  {% set therm = 'climate.livingroom_thermostat' %}

                  {% if state_attr(therm,'temperature') is not none %}

                  {{ state_attr(therm, 'current_temperature')|float(0) >=
                  states('input_number.living_room_low_temperature')|float(0) }}

                  {% endif %}
                alias: Living Room warm enough AWAY
              - condition: state
                entity_id: timer.floor_pump_timer
                state: idle
              - condition: device
                type: is_on
                device_id: XXX
                entity_id: switch.floor_heating_socket
                domain: switch
              - condition: and
                conditions:
                  - condition: state
                    entity_id: input_boolean.working_home_inga
                    state: "off"
                  - condition: state
                    entity_id: input_boolean.working_home_reinhardt
                    state: "off"
                alias: Nobody working home
        sequence:
          - type: turn_off
            device_id: XXX
            entity_id: switch.floor_heating_socket
            domain: switch
          - device_id: XXX
            domain: mobile_app
            type: notify
            message: Floor Heating Low OFF
mode: single
1 Like