Heaty will die, Schedy be born!

Did you actually install hass-apps though?
You need to add it to the AppDaemon packages list.
Mine looks like this:

init_commands: []
python_packages:
  - https://github.com/efficiosoft/hass-apps/archive/master.zip
system_packages: []

Thanks, I think it was due to the appdeamon.yaml. The field type: ha_url and token was empty for me. Now it’s working! Thanks very much! :slight_smile:

Hi, Hope someone can help. Been using Schedy reliably for the past 12 months but wanted to reconfigure slightly to tidy things up. Is there any way I could combine the days_off and the school_days_off schedule snippet using an ‘or’?

non-working example,

"Next() if house_mode() != 'Away' and state('sensor.brighthr_leave') == 'on' or house_mode() != 'Away' and state('sensor.school_leave') == 'on' and girls() == 'on' else Break()"

Current working full schedy.yaml

schedy_heating:
  module: hass_apps_loader
  class: SchedyApp
  expressions_from_events: true

  actor_type: thermostat
  
  watched_entities:
  - input_select.home
  - input_boolean.family
  - input_select.heating_preset
  - input_number.temp_home
  - input_boolean.girls
  - input_select.heating_preset_girls
  - input_number.temp_girls
  - sensor.brighthr_leave
  - sensor.school_leave
  
  expression_environment: |
    def house_mode():
      return state("input_select.home")
      
    def family():
      return state("input_boolean.family")

    def climate():
      return state("input_select.heating_preset")
      
    def girls():
      return state("input_boolean.girls")
      
    def climate_girls():
      return state("input_select.heating_preset_girls")
  
  schedule_snippets:
    away:
    - x: "Next() if house_mode() == 'Away' else Break()"
    - { v: 12, start: "06:30", end: "07:30", months: "1-3,10-12" }
    - { v: 12, start: "19:30", end: "20:30", months: "1-3,10-12" }
    boost:
    - x: "Next() if climate() == 'Boost' else Break()"
    - { v: 18.5, start: "07:45", end: "17:00" }
    - { start: "17:00", end: "23:15" }
    days_off:
    - x: "Next() if house_mode() != 'Away' and state('sensor.brighthr_leave') == 'on' else Break()"
    - { x: Add(-2) if family() == 'off' else Next(), months: "3,10,11" }
    - { v: 16.5, start: "01:00", end: "06:30", months: "1,2,12" }
    - { start: "06:30", end: "08:30", months: "1-3,10-12" }
    - { start: "16:00", end: "22:00", months: "1-3,10-12" }
    school_days_off:
    - x: "Next() if house_mode() != 'Away' and state('sensor.school_leave') == 'on' and girls() == 'on' else Break()"
    - { x: Add(-2) if family() == 'off' else Next(), months: "3,10,11" }
    - { v: 16.5, start: "01:00", end: "06:30", months: "1,2,12" }
    - { start: "06:30", end: "08:30", months: "1-3,10-12" }
    - { start: "16:00", end: "22:00", months: "1-3,10-12" }
    work_days:
    - x: "Next() if house_mode() != 'Away' and state('sensor.brighthr_leave') == 'off' else Break()"
    - { x: Add(-2) if family() == 'off' else Next(), months: "3,10,11" }
    - { v: 16.5, start: "01:00", end: "06:30", months: "1,2,12" }
    - { start: "06:30", end: "07:45", months: "1-3,10-12" }
    - { start: "17:30", end: "22:00", months: "1-3,10-12" }
    girls:
    - x: "Next() if girls() == 'on' else Break()"
    - { start: "06:30", end: "07:45", months: "1,2,12" }
    - { start: "17:00", end: "22:00", months: "1,2,12" }
  
  schedule_append:
  - v: "OFF"
  
  rooms:
  
    living:
      rescheduling_delay: 30
      actors:
        climate.heating:
      schedule:
      - x: "state('input_number.temp_home')"
        rules:
        - weekdays: 1-7
          rules:
          - rules:
            - x: "IncludeSchedule(schedule_snippets['boost'])"
          - rules:
            - x: "IncludeSchedule(schedule_snippets['away'])"
          - rules:
            - x: "IncludeSchedule(schedule_snippets['days_off'])"
          - rules:
            - x: "IncludeSchedule(schedule_snippets['school_days_off'])"
          - rules:
            - x: "IncludeSchedule(schedule_snippets['work_days'])"
      
    girls:
      rescheduling_delay: 15
      actors:
        climate.heating_girls:
      schedule:
      - x: "state('input_number.temp_girls')"
        rules:
        - weekdays: 1-7
          rules:
          - rules:
            - x: "IncludeSchedule(schedule_snippets['girls'])"

thanks for any help given.

Hi all,

I wanted to do a light change at my config removing time rule:

    bagnoprincipale:
      actors:
        climate.002018a99d2442:
      watched_entities:
      - binary_sensor.001558a99d4e50_state
      schedule:
      - v: 20
        rules:
        - weekdays: 1-5
          rules:
          - rules:
            - x: "Next() if heating_mode() == 'Acceso' else Break()"
            - { start: "05:30", end: "23:30" }
        - weekdays: 6-7
          rules:
          - rules:
            - x: "Next() if heating_mode() == 'Acceso' else Break()"
    #        - { start: "07:00", end: "23:30" }
      - v: 30
        months: 5-9

But if I do this the valve goes to off and doesn’t turn on anymore. Any hint?

Hello,

I’m having an issue with Schedy (I think).

I have a basic setup where in the morning I want a room to be 22° and in the evening it should be 21°. But it seems the temperature isn’t getting changed.
I am able to reproduce this and this is what I get in the logging:

2021-12-09 08:22:36.719000 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 21.0��.
2021-12-09 08:22:38.650882 INFO schedy_heating: <-- [R:bureau] Value set to 20.0��.  [scheduled]
2021-12-09 08:22:38.899680 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.

2021-12-09 08:22:46.293561 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 21.0��.
2021-12-09 08:23:09.015946 WARNING schedy_heating: !!! [R:bureau] [A:climate.f1_bureau_valve_heater] Re-sending value due to missing confirmation.
2021-12-09 08:23:16.609491 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.
2021-12-09 08:23:22.773229 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 21.0��.
2021-12-09 08:23:47.023269 WARNING schedy_heating: !!! [R:bureau] [A:climate.f1_bureau_valve_heater] Re-sending value due to missing confirmation.
2021-12-09 08:23:48.687087 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.
2021-12-09 08:23:55.040361 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 21.0��.
2021-12-09 08:24:19.048870 WARNING schedy_heating: !!! [R:bureau] [A:climate.f1_bureau_valve_heater] Re-sending value due to missing confirmation.
2021-12-09 08:24:20.715912 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.
2021-12-09 08:24:27.083429 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 21.0��.
2021-12-09 08:24:48.120940 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 20.0��.

If I then manually change the value to 20.0, it gets picked up and the retries stop.
It seems to me that the temperature is set too fast while the thermostat is still in OFF mode?

While retrying I constantly see the thermostat card change between off, heat, the wanted temperature and then again the previous temperature.
In the history of the thermostat is says “Turned off by Supervisor”, followed by “Changed to Heat” for every Heaty retry.

If I manually go to the thermostat card and turn on the heater, then change the temperature it gets pushed correctly to the thermostat.

The same happens when I manually override and Schedy tries to re-apply the schedule (here after one minute to simulate)

2021-12-09 08:36:46.482837 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 19.5��.
2021-12-09 08:36:46.499857 INFO schedy_heating: --- [R:bureau] Re-applying the schedule not before 08:37:46 (in 0:01:00).
2021-12-09 08:37:47.788518 INFO schedy_heating: <-- [R:bureau] Value set to 20.0��.  [scheduled]
2021-12-09 08:37:47.891875 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.
2021-12-09 08:37:54.151336 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 19.5��.
2021-12-09 08:38:18.033055 WARNING schedy_heating: !!! [R:bureau] [A:climate.f1_bureau_valve_heater] Re-sending value due to missing confirmation.
2021-12-09 08:38:19.697175 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of OFF.
2021-12-09 08:38:26.046954 INFO schedy_heating: --> [R:bureau] [A:climate.f1_bureau_valve_heater] Received value of 19.5��.

Anything I can try to pinpoint the issue?

thanks,
Stijn

@roschi can you confirm whether Schedy will be affected by any of these breaking changes:

Thanks.

1 Like

@mobile.andrew.jones I can at least confirm updating worked without any problems. I run Appdaemon4 0.4.2 since it was released without issues in 2 installation,

1 Like

Thought it was worth checking as I rely on it for the heating system, and since they specifically mention changes in how the state listeners work, I would assume Schedy uses entity state listeners to re-evaluate the schedule.

If you have a backup you can easily just rol back the app daemon version in case a problem occurs :wink:
I did not get any strange messages in my log.

Hello,

i really thank you for that awesom tool. i just got into HA and schedy and i got some questions.
I set up my rooms and heating times, so far so good.

Q1:

i.e.:

  schedule_snippets:
    grundwaerme_preset1:
      - v: 19
        rules:
          - weekdays: 1-7
            rules:
              - { start: "07:00", end: "07:59" }

i wanted to set something like a heaing season for all rooms and all “-v” and it seems to work like this:

  schedule_snippets:
    grundwaerme_preset1: #Raeume: Bad, WC, Arbeitszimmer, Kueche
      - v: 19
        start_date: { year: 2021, month: 10, day: 1 }
        end_date: { year: 2022, month: 4, day: 1 }
        weekdays: 1-7
        start: "07:00"
        end: "07:59"

but i would need to add the start_date and end_date for each one. is there a way to make is not redundant? also it would be nice to get start and end date from HA so i could change the start and end of heaing season there.

Q2:

i got external temp sensors which i would like to use with my heaters.
so i.e. the thermostate which has got a temp sensor in it says its 20C, but the external sensor says its 18C, and the termperature is set to be 21C, i would like to add those 2C which are diffrent to the set temperature like an offset, so the set temperature would change to 23C

is that possible?

Hi,

I have a problem with Schedy not evaluating my dynamic schedule on a regular basis, only when watched enties are changed. Any idea why, and how to make it work?

schedy_heating:  # This is our app instance name.
  module: hass_apps_loader
  class: SchedyApp

  expression_environment: |
    def time_between(start, end):
        current = time.hour
        if start >= end:
            return current >= start or current < end
        return current >= start and current < end

  actor_type: thermostat
  
  watched_entities:
### Gjeldende
  - switch.bortemodus_switch
  - sensor.pricelevel
  - input_number.st_feriemodus
  - input_number.st_rom_ikke_i_bruk
  - input_number.tk_boost_varme
  - input_number.tk_sp_h
  - input_number.tk_sp_vh

  schedule_snippets:
    modifikator:
    - x: "Add(state('input_number.tk_sp_h')) if state('sensor.pricelevel') == 'EXPENSIVE' else Next()"
    - x: "Add(state('input_number.tk_sp_vh')) if state('sensor.pricelevel') == 'VERY_EXPENSIVE' else Next()"

  rooms:

## Kontor ##
    Kontor:
        rescheduling_delay: 120
        actors:
            climate.socket_kontor:

        watched_entities:
        - input_boolean.rib_r301
        - input_number.tk_bm_r301
        - input_number.tk_sm_r301
        - input_number.tik_fv_r301
        - input_number.st_m_r301
        - input_number.st_d_r301
        - input_number.st_k_r301
        - input_number.st_n_r301

        - input_number.pt_mt_m_r301
        - input_number.pt_mt_d_r301
        - input_number.pt_mt_k_r301
        - input_number.pt_mt_n_r301
        - input_number.pt_f_m_r301
        - input_number.pt_f_d_r301
        - input_number.pt_f_k_r301
        - input_number.pt_f_n_r301
        - input_number.pt_l_m_r301
        - input_number.pt_l_d_r301
        - input_number.pt_l_k_r301
        - input_number.pt_l_n_r301
        - input_number.pt_s_m_r301
        - input_number.pt_s_d_r301
        - input_number.pt_s_k_r301
        - input_number.pt_s_n_r301

        schedule:
        - v: 10
          rules:
            - weekdays: 1-4
              rules:
                - x: "Break() and state('input_number.st_rom_ikke_i_bruk') if is_on('input_boolean.rib_r301') else Next()"
                - x: "IncludeSchedule(schedule_snippets['modifikator'])"
                - x: "Add(state('input_number.tk_bm_r301')) if is_on ('switch.bortemodus_switch') else Next()"
                - x: "state('input_number.st_m_r301') if time_between(float(state('input_number.pt_mt_m_r301')), float(state('input_number.pt_mt_d_r301'))) else Next()"
                - x: "state('input_number.st_d_r301') if time_between(float(state('input_number.pt_mt_d_r301')), float(state('input_number.pt_mt_k_r301'))) else Next()"
                - x: "state('input_number.st_k_r301') if time_between(float(state('input_number.pt_mt_k_r301')), float(state('input_number.pt_mt_n_r301'))) else Next()"
                - x: "state('input_number.st_n_r301') if time_between(float(state('input_number.pt_mt_n_r301')), float(state('input_number.pt_mt_m_r301'))) else Next()"
            - weekdays: 5
              rules:
                - x: "Break() and state('input_number.st_rom_ikke_i_bruk') if is_on('input_boolean.rib_r301') else Next()"
                ...and so on...

Best Regards
Jan-Tore

Hi @TriStone

I love what you’ve done and I have modified your code a little bit to fit my setup.
One problem I have run into is that the dynamic times are not beeing evalutated, so the temperature stays the same until someting triggers an evalutation (may take many hours).
Have you seen this problem? And do you have a solution?

See more details in my post: Heaty will die, Schedy be born! - #1268 by Autoper

Best Regards
Jan-Tore

Hi @Autoper

Sure, this is common problem. You need to triggere re-avaluation somehow.

I see two options.

First is to set an automation every eg. minute to trigger Schedy to re-evaluate.
Check Schedy docs.

Second option is what I did. I created a fake sensor computing number of minutes since midnight. This sensor changes itself every minute, logically. And I set it as watched entity.

Schedy, line 35:

Sensor:

Thanks a lot! That saved the day :smiley:
Just one question, is it possible to modify the sensor to count every 10 minutes? I think every minute may be a bit agressive.

  • Jan-Tore -

In that case I would suggest you the automation to triggere re-evaluation every ten minutes.

Or you can play a bit with the sensor and eg. round the result for tens. That could do the trick :slight_smile:
For me the minutes sensor is important as it is used for comparing time intervals. Comparing hours and minutes in Schedy would be nightmare so all values from GUI sliders are trasnformed to minutes since midnight. And then it is much easier to compare.

hello, i got a question.

i got an input number which i set to be watched:

  watched_entities:
    - input_select.heating_mode
    - input_number.heatingperiodebeginyear

heatingperiodebeginyear has got the float value of “2021.0”

and i want to use it here:


  schedule_snippets:
    preset1:
      - v: 19
        start_date:
          {
            year: int(state("input_number.heatingperiodebeginyear")),
            month: 10,
            day: 1,
          }
        end_date: { year: 2022, month: 4, day: 1 }
        rules:
          - weekdays: 1-7
            rules:
              - { start: "07:00", end: "07:59:59" }

but thats not working. i getting this error:

ERROR schedy_heating: !!! Configuration error: expected int for dictionary value @ data['schedule_snippets']['grundwaerme_preset1'][0]['start_date']['year']. Got 'int(state("input_number.heatingperiodebeginyear"))'

how can i solve that?

Good evening,
I recently started using HA.
Schedy is runnung good so far as I have one “test-room” before completely switching fom OH and from MAX! thermostats to Zigbee.

I have the following problem:
Temperature changes are performed according schedule. Window open detection is not working at all (change temperature to 5°C when window is open).

The log says the following:

INFO schedy_heating: → Attribute ‘state’ of ‘binary_sensor.door_window_sensor_wc’ changed from ‘off’ to ‘on’, reevaluating .

here is my .yaml

schedy_heating: # This is our app instance name.
module: hass_apps_loader
class: SchedyApp

actor_type: thermostat

expression_environment: |
def heating_mode():
return state(“input_select.heating_mode”)

watched_entities:

  • input_select.heating_mode

schedule_prepend:

  • x: “Mark(5, Mark.OVERLAY) if not is_empty(filter_entities(‘binary_sensor’, state=‘on’, window_room=room_name)) else Next()”

schedule_append:

  • v: 5

rooms:

wc:
  allow_manual_changes: false
  actors:
    climate.zb_thermostat_eg_wc:
  watched_entities:
  - binary_sensor.door_window_sensor_wc
  schedule:
    - v: 20
      rules:
        - weekdays: 1-5
          rules:
          - { start: "07:30", end: "17:59" }
        - weekdays: 6-7
          rules:
          - { start: "08:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "18:00", end: "07:29" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "07:59" }

Any suggestions?

BTW: is there any chance to delay the temperature reduction by, let’s say, 5 minutes?

Thanks in advance
Florian

Hello All,
I advanced in using Schedy for my heating schedules. The unsolved problem still is that the thermostats do not react when a window is opened. The used thermostats are Zigbee Tuya thermostats.
After browsing the web I found a configuration that promised being the solution but it is not:

  actor_type: thermostat
  actor_templates:
    default:
      off_temp: 5
      supports_hvac_modes: false

The log still states the following:


2022-03-01 20:15:10.616086 INFO schedy_heating: --> Attribute 'state' of 'binary_sensor.door_window_sensor_wc' changed from 'off' to 'on', reevaluating <Room R:wc>.
2022-03-01 20:15:17.592606 INFO schedy_heating: --> Attribute 'state' of 'binary_sensor.door_window_sensor_wc' changed from 'on' to 'off', reevaluating <Room R:wc>.

Can someone suggest anything to fix this?

Here is my schedy_heating.yaml

schedy_heating:
  module: hass_apps_loader
  class: SchedyApp

  actor_type: thermostat
  actor_templates:
    default:
      off_temp: 5
      supports_hvac_modes: false

  expression_environment: |
    def heating_mode():
        return state("input_select.heating_mode")

  schedule_snippets:
  
    ss_aus: 
    - v: 5

    ss_durchgehend_wohnen:
    - v: 21

    ss_durchgehend_sonstige:
    - v: 19

    ss_durchgehend_kids:
    - v: 20

    ss_abwesend:
    - v: 18
      start: "10:00"
      end: "20:00"

    ss_kz:
    - v: 20
      rules:
      - weekdays: 1-5
        rules:
        - { start: "07:30", end: "17:59" }
      - weekdays: 6-7
        rules:
        - { start: "08:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "18:00", end: "07:29" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "07:59" }

    ss_sz:
    - v: 20
      rules:
      - weekdays: 1-5
        rules:
        - { start: "07:30", end: "17:59" }
      - weekdays: 6-7
        rules:
        - { start: "08:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "18:00", end: "07:29" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "07:59" }

    ss_bz:
    - v: 20
      rules:
      - weekdays: 1-5
        rules:
        - { start: "07:00", end: "16:59" }
      - weekdays: 6-7
        rules:
        - { start: "08:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "17:00", end: "06:59" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "07:59" }

    ss_wz:
    - v: 21
      rules:
      - weekdays: 1-5
        rules:
        - { start: "05:30", end: "21:59" }
      - weekdays: 6-7
        rules:
        - { start: "05:30", end: "22:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "22:00", end: "05:29" }
        - weekdays: 6-7
          rules:
          - { start: "23:00", end: "05:29" }

    ss_wc:
    - v: 19
      rules:
        - weekdays: 1-5
          rules:
          - { start: "07:30", end: "17:59" }
        - weekdays: 6-7
          rules:
          - { start: "08:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "18:00", end: "07:29" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "07:59" }

    ss_ki:
    - v: 20
      rules:
      - weekdays: 1-5
        rules:
        - { start: "08:00", end: "17:59" }
      - weekdays: 6-7
        rules:
        - { start: "09:00", end: "17:59" }
    - v: 18
      rules:
        - weekdays: 1-5
          rules:
          - { start: "18:00", end: "07:59" }
        - weekdays: 6-7
          rules:
          - { start: "18:00", end: "08:59" }

  watched_entities:
  - input_select.heating_mode

  schedule_prepend:
  - x: "Mark(OFF, Mark.OVERLAY) if not (is_empty(filter_entities('sensor', state='open', window_room=room_name))) else Next()"
  - x: "Mark(OFF, Mark.OVERLAY) if not (is_empty(filter_entities('sensor', state='tilted', window_room=room_name))) else Next()"
  - x: "Mark(OFF, Mark.OVERLAY) if not (is_empty(filter_entities('binary_sensor', state='on', window_room=room_name))) else Next()"
  - x: "IncludeSchedule(schedule_snippets['ss_abwesend']) if heating_mode() == 'abwesend/zeitgesteuert' else Next()"
  - x: "IncludeSchedule(schedule_snippets['ss_aus']) if heating_mode() == 'aus' else Next()"

  schedule_append:
  - value: "17"

  rooms:

    wc:
      allow_manual_changes: false
      actors:
        climate.zb_thermostat_eg_wc:
      watched_entities:
      - binary_sensor.door_window_sensor_wc
      schedule:
      - x: "IncludeSchedule(schedule_snippets['ss_wc']) if heating_mode() == 'anwesend/zeitgesteuert' else Next()"
      - x: "IncludeSchedule(schedule_snippets['ss_durchgehend_sonstige']) if heating_mode() == 'durchgehend aktiv' else Next()"
      
      
    sz:
      allow_manual_changes: false
      actors:
        climate.zb_thermostat_eg_kz2:
      watched_entities:
      - binary_sensor.door_window_sensor_kz_21
      - binary_sensor.door_window_sensor_kz_22
      schedule:
      - x: "IncludeSchedule(schedule_snippets['ss_sz']) if heating_mode() == 'anwesend/zeitgesteuert' else Next()"
      - x: "IncludeSchedule(schedule_snippets['ss_durchgehend_sonstige']) if heating_mode() == 'durchgehend aktiv' else Next()"

    kz1:
      allow_manual_changes: false
      actors:
        climate.zb_thermostat_eg_kz1_1:
        climate.zb_thermostat_eg_kz1_2:
      watched_entities:
      - binary_sensor.door_window_sensor_kz_11
      - binary_sensor.door_window_sensor_kz_12
      schedule:
      - x: "IncludeSchedule(schedule_snippets['ss_kz']) if heating_mode() == 'anwesend/zeitgesteuert' else Next()"
      - x: "IncludeSchedule(schedule_snippets['ss_durchgehend_kids']) if heating_mode() == 'durchgehend aktiv' else Next()"
      
    bz:
      allow_manual_changes: true
      rescheduling_delay: 60
      actors:
        climate.zb_thermostat_eg_bz:
      watched_entities:
      - binary_sensor.door_window_sensor_bz
      schedule:
      - x: "IncludeSchedule(schedule_snippets['ss_bz']) if heating_mode() == 'anwesend/zeitgesteuert' else Next()"
      - x: "IncludeSchedule(schedule_snippets['ss_durchgehend_sonstige']) if heating_mode() == 'durchgehend aktiv' else Next()"

Thanks in Advance
Florian

1 Like

Hi my solution is to have a general definition of hvac modes and define the off temperature only for thermostats who do not support a real off hvac (some tuyas dont). and of course prepend some general scheduling rules. hope that helps.

  actor_type: thermostat
  actor_templates:
    default:
##      off_temp: 5
      supports_hvac_modes: true
      hvac_mode_on: 'auto'
      hvac_mode_off: 'off'
  schedule_prepend:
  # don't turn on when it's > 24 degrees outside
  - x: "IncludeSchedule(schedule_snippets['snippet_aus']) if float(state('sensor.vicare_outside_temperature') or 0) > 24 else Next()"
  - x: "Mark(OFF, Mark.OVERLAY) if not (is_empty(filter_entities('binary_sensor', state='on', window_room=room_name))) else Next()"
  - x: "Mark(OFF, Mark.OVERLAY) if not (is_empty(filter_entities('binary_sensor', state='on', window_room2=room_name))) else Next()"
  - x: "IncludeSchedule(schedule_snippets['snippet_abwesend']) if heating_mode() == 'abwesend/zeitgesteuert' else Next()"
  - x: "IncludeSchedule(schedule_snippets['snippet_aus']) if heating_mode() == 'aus' else Next()"
####### #########

    Kinderzimmer:
      rescheduling_delay: 20
      watched_entities:
      - binary_sensor.kinderzimmer_sensor_fenster_links_contact
      - binary_sensor.kinderzimmer_sensor_fenster_rechts_contact
      - sensor.kinderzimmer_sensor_temperature
      actors:
        climate.kinderzimmer_heizung:
          min_temp: 5
          max_temp: 45
          off_temp: 5
          supports_hvac_modes: false
#          delta: 1.0 
      schedule:
      - x: "IncludeSchedule(schedule_snippets['snippet_aus']) if float(state('sensor.kinderzimmer_sensor_temperature') or 0) > 22 else Next()"
      - x: "IncludeSchedule(schedule_snippets['snippet_kinder']) if heating_mode() == 'anwesend/gast' else Next()"
      - x: "IncludeSchedule(schedule_snippets['snippet_kinder']) if heating_mode() == 'anwesend/zeitgesteuert' else Next()"
      - x: "IncludeSchedule(schedule_snippets['snippet_durchgehend_wohnen']) if heating_mode() == 'durchgehend aktiv' else Next()"

####### #########

It would be nice if you could explain some more about your heating situation and what you want to reach and why you change temperatures how you do?