Help with my Central Heating Timers and automation

Hi There,

I searched the forum for a central heating timer control that I could use for my particular set up at home. While i found some interesting topics, nothing seemed easy to adapt for my situation. So I started from scratch and have got almost there but the last part is causing me some challenges. Im not very coding savvy so my approach using mostly the UI in the Automation section is probably a bit retarded, but it the best that I can do.

Here is my hardware set up, quite simple really. I have 3 heating zones and each is controlled by a Tuya based Thermostat controllers. I have those integrated using the Tuya Local integration. all working well with a simple time automation. But then there is the wife…she want to change the times for different days and different zones and she cant do that when they are hard coded in to an automation.

So I created helpers for each day of the week such as: T1_mon, T2_mon, T3_mon, T4_mon etct, etc for each day. T1 being start, T2 being end, T3 being start and T4 being end for each day. Then I created 3 zone selectors for each day of the week as well calling them; "downstairs heating_mon, upstairs heating_mon, kitchenUFH_mon etc, etc.

Here is my control panel:

Next I used the Automations UI to start creating my control logic. Below is the yaml. I found that it got quite complex, very quickly :slight_smile: and with many hours of trial and error using the “Choose” options I finally got what I though was a working automation. Indeed it does turn on and off the heating at the required times, however I can NOT get the conditions or choices to filter out the T1_mon from the T3_fri for example. So if I have a later timer for the weekends say on at 07:00 but during the weekdays I have a timer for 05:00 and off at 06:30, then at 07:00 on the which ever weekday it is, the 07:00 weekend timer will also fire and turn on again the heating. Hopefully that is clear…

I looked at the triggers which are the T1_mon (for example) and wanted to try to add a filter for the actual day of the week, so a ‘T1_tue’ can not fire on any other day except for a Tuesday, or a ‘T1_sun’ can only fire on a Sunday, this would solve my problem but I couldn’t get it to work. Here is the standard trigger that fires every day at the given platform time:

platform: time
at: input_datetime.mon_t1
enabled: true

And here is my attempt at coding it manually with a mon filter:

platform: time
at: input_datetime.mon_t1
weekday: mon

As I said earlier Im not any good at coding. If i put a day of the week filter in the conditions directly after the Trigger, then it would stop all other timers from getting trough so I dont think that can work unless coded…

Here is my automation.yaml its pretty big so this one just turns on all the T1 & T3’s and a duplicate turns off all the T2 & T4’s. Below the yaml is a screen shot of the Trace which helps to see what happens:

alias: Central Heating Manual Timers - ON
description: ""
trigger:
  - platform: time
    at: input_datetime.mon_t1
    enabled: true
  - platform: time
    at: input_datetime.mon_t3
  - platform: time
    at: input_datetime.tue_t1
  - platform: time
    at: input_datetime.tue_t3
  - platform: time
    at: input_datetime.wed_t1
  - platform: time
    at: input_datetime.wed_t3
  - platform: time
    at: input_datetime.thur_t1
  - platform: time
    at: input_datetime.thur_t3
  - platform: time
    at: input_datetime.fri_t1
  - platform: time
    at: input_datetime.fri_t3
  - platform: time
    at: input_datetime.sat_t1
  - platform: time
    at: input_datetime.sat_t3
  - platform: time
    at: input_datetime.sun_t1
  - platform: time
    at: input_datetime.sun_t3
condition: []
action:
  - choose:
      - conditions:
          - condition: time
            after: input_datetime.mon_t1
            weekday:
              - mon
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_mon
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_mon
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_mon
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.mon_t3
            weekday:
              - mon
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_mon
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_mon
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_mon
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.tue_t1
            weekday:
              - tue
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_tues
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_tues
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_tues
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.tue_t3
            weekday:
              - tue
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_tues
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_tues
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_tues
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.wed_t1
            weekday:
              - wed
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_wed
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_wed
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_wed
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.wed_t3
            weekday:
              - wed
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_wed
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_wed
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_wed
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.thur_t1
            weekday:
              - thu
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_thurs
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_thurs
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_thurs
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.thur_t3
            weekday:
              - thu
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_thurs
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_thurs
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_thurs
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.fri_t1
            weekday:
              - fri
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_fri
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_fri
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_fri
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.fri_t3
            weekday:
              - fri
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_fri
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_fri
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_fri
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.sat_t1
            weekday:
              - sat
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_sat
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_sat
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_sat
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.sat_t3
            weekday:
              - sat
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_sat
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_sat
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_sat
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.sun_t1
            weekday:
              - sun
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_sun
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_sun
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_sun
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
      - conditions:
          - condition: time
            after: input_datetime.sun_t3
            weekday:
              - sun
        sequence:
          - choose:
              - conditions: []
                sequence:
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.downstairs_heating_sun
                            state: "on"
                        sequence:
                          - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                            domain: climate
                            entity_id: climate.downstairs_heating_local
                            type: set_hvac_mode
                            hvac_mode: heat
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.upstairs_heating_sun
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              entity_id: climate.upstairs_heating_local
                  - choose:
                      - conditions:
                          - condition: state
                            entity_id: input_boolean.kitchen_ufh_sun
                            state: "on"
                        sequence:
                          - service: climate.set_hvac_mode
                            data:
                              hvac_mode: heat
                            target:
                              device_id:
                                - cbf47d57c0cc6ef49d19936c65d0e240
trace:
  stored_traces: 24
mode: single


Above the T3_mon timer has fired and on the left leg of the trace you see zones 1 is off and zones 2 & 3 are set to come on.

This helper would considerably simplify your automation:

1 Like

thanx Tom_I,

But wouldn’t that require the wife to go in to the scheduler from settings to make the changes? I was trying to get a more visual way for her to change the settings that she will do often…?

You don’t have to add it via yaml. You can use the Ui. When you click on the name in an entities or glance card this pops up and can be edited using point and click:

IMG_0788

1 Like

Thanx again Tom_I,
OK let me install and take a look at that.

On my attempt, I guess you know how it is after investing hours of time in something, I still don’t know why the automation doesn’t filter out the timers from other days. Each timer has the conditional day of the week that it should be actioned, and testing each timers condition in the UI displays the correct (expected) action. No timer from any other day passes the test for that day. But somehow the other day timers get through.

How would I write a yaml condition that takes the (now) day and then filters out any Timer that does not have that day of the week as part of its name?

input_datetime.mon_t1
input_datetime.mon_t2
input_datetime.mon_t3
input_datetime.mon_4

input_datetime.tue_t1
input_datetime.tue_t2
input_datetime.tue_t3
input_datetime.tue_t4

In the actual helper i did set the applicable day that is should work on but that is part of the Chooses in the Automation:

Hi again,

I have started to use the Schedule function and ended up trying to use a .yml based schedule so that I could input the times from my timers on the UI. I tried the below but it can not pass the config checks. Please could you help me to correct the yaml to allow the UI timers to be input in to the Schedule.

Thank you for any assistance.

# Home Heating Schedule with time inputs from UI
schedule:
  central_heating_schedule:
    name: "Central Heating Schedule"
    monday:
      - from: "input_datetime.mon_t1"
        to: "input_datetime.mon_t2"
      - from: "input_datetime.mon_t3"
        to: "input_datetime.mon_t4"
    tuesday:
      - from: "input_datetime.tue_t1"
        to: "input_datetime.tue_t2"
      - from: "input_datetime.tue_t3"
        to: "input_datetime.tue_t4"
    wednesday:
      - from: "input_datetime.wed_t1"
        to: "input_datetime.wed_t2"
      - from: "input_datetime.wed_t3"
        to: "input_datetime.wed_t4"
    thursday:
      - from: "input_datetime.thur_t1"
        to: "input_datetime.thur_t2"
      - from: "input_datetime.thur_t3"
        to: "input_datetime.thur_t4"
    friday:
      - from: "input_datetime.fri_t1"
        to: "input_datetime.fri_t1"
      - from: "input_datetime.fri_t1"
        to: "input_datetime.fri_t1"
    saturday:
      - from: "input_datetime.sat_t1"
        to: "input_datetime.sat_t2"
      - from: "input_datetime.sat_t3"
        to: "input_datetime.sat_t4"
    sunday:
      - from: "input_datetime.sun_t1"
        to: "input_datetime.sun_t2"
      - from: "input_datetime.sun_t3"
        to: "input_datetime.sun_t4"
        

That is the opposite of what happens. If you use YAML then you can’t use the UI.

You also cant use entities in the from and to options. Just times.

https://www.home-assistant.io/integrations/schedule/#configuration-variables
Screenshot 2023-01-12 at 17-02-10 Schedule

Thanx Tom_I,

Yes I removed the schedule integration once I saw that the .yaml set up does its own thing.
So I cant use the input_datetime timers from the UI? That was my main purpose to have an easy to edit process for the wife to change the daily timers as she wanted without getting in to the backend of the helpers page. Any other way around this? I like the ease of the scheduller approach and my automation handles which zone is switched on…its just the UI for my wife that I’m struggling with…

For my Eddi water heater I did this:

service: input_number.set_value
data:
  value: 60
target:
  entity_id: input_number.eddi_boost_minutes

I was hoping the Scheduler times could have been entered in a similar way.

That was why I suggested the Shedule. To simplify this. There is no need to make changes to the backend to edit a schedule.

Untitled0

Yes it would be easier with a schedule card so you did not have to use the pop-up but we don’t have one (yet).

1 Like

OK thanx Tom_I yes I tried to add the schedule to the UI but couldn’t find either a dedicated scheduler card or how to add something that would display the schedule…now seeing your example I think i know how you did that with a separate entities card. Then when you click that entity it opens the pop up.

I really don’t know why the timer and scheduling are more user friendly. As I previously said Im an amature enthusiast and have not coding or IT experience so these things are much harder to achieve without the great help and support from people like yourself. Thank you.

I would like to suggest that Frenk who created the Scheduler could consider to add the ability to use “input_values” in the scheduler template and the problem/complexity would be greatly reduced. Of course its his free time and I would not even know where to start on something like that…so I appreciate the hard work of others and try my best to learn from you guys.

Needed a restart after changing back to the schedule integration.

Yep, that’s what I said way back up there :point_up_2:

That negates the whole simplicity of setting the schedule through the UI.

Easier access to the schedule in a card is all that is required.

I respectfully disagree. My UI card that I made allows times to be easily set from either a computer with keyboard or a mobile device using fingers and give a much more granular time settings. On my mobile device it is really hard to set the scheduler times as the whole table moves while trying to click and crag using my finger.

But I also appreciate that it is peoples own time that they invest in this project so anything is greatly welcomed and appreciated always.

Once again thank you for your great support and advise on what is actually possible now…still wish I could understand why my original choose options that have a filter for the actual day of the week kept passing another days information.

Thanx again Tom_I,

This is my current best case set up thanx to your help:

And if its worth anything here is my Automation, I duplicated the same automation 7x for each day of the week just to keep the automation coding to a reasonable length:

alias: Central Heating Schedule - Mondays
description: Central Heating Schedule
trigger:
  - platform: state
    entity_id:
      - schedule.central_heating_2
    attribute: next_event
condition: []
action:
  - choose:
      - conditions: []
        sequence:
          - choose:
              - conditions:
                  - condition: state
                    entity_id: input_boolean.downstairs_heating_mon
                    state: "on"
                  - condition: state
                    entity_id: schedule.central_heating_2
                    state: "on"
                sequence:
                  - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                    domain: climate
                    entity_id: climate.downstairs_heating_local
                    type: set_hvac_mode
                    hvac_mode: heat
          - choose:
              - conditions:
                  - condition: state
                    entity_id: input_boolean.kitchen_ufh_mon
                    state: "on"
                  - condition: state
                    entity_id: schedule.central_heating_2
                    state: "on"
                sequence:
                  - device_id: cbf47d57c0cc6ef49d19936c65d0e240
                    domain: climate
                    entity_id: climate.kitchen_ufh_local
                    type: set_hvac_mode
                    hvac_mode: heat
          - choose:
              - conditions:
                  - condition: state
                    entity_id: input_boolean.upstairs_heating_mon
                    state: "on"
                  - condition: state
                    entity_id: schedule.central_heating_2
                    state: "on"
                sequence:
                  - device_id: a99bcd187d587a5d620276ccecb27823
                    domain: climate
                    entity_id: climate.upstairs_heating_local
                    type: set_hvac_mode
                    hvac_mode: heat
                  - wait_for_trigger:
                      - platform: state
                        entity_id:
                          - schedule.central_heating_2
                        to: "off"
                  - condition: time
                    weekday:
                      - mon
                  - device_id: 318e6c3855b310c8162ca1c1e7625cb0
                    domain: climate
                    entity_id: climate.downstairs_heating_local
                    type: set_hvac_mode
                    hvac_mode: "off"
                  - device_id: cbf47d57c0cc6ef49d19936c65d0e240
                    domain: climate
                    entity_id: climate.kitchen_ufh_local
                    type: set_hvac_mode
                    hvac_mode: "off"
                  - device_id: a99bcd187d587a5d620276ccecb27823
                    domain: climate
                    entity_id: climate.upstairs_heating_local
                    type: set_hvac_mode
                    hvac_mode: "off"
trace:
  stored_traces: 10
mode: single

For me it would be fantastic if someone in the know-how made a proper scheduling UI card and if there was a way to disply the current day timer setings on the above UI that I made. All of that could be achived if the schedule integratino would accept “input_datetime” from a helper.

How would I be able to pull the schedules next event and display in a UI card? I see that the schedule has attributes of next event:

EDIT: found this: state: {{ state_attr('schedule.central_heating_2','next_event') }}
Just need to research time formatting…

Use an entities card. It supports displaying attributes.

There are examples at the bottom of the page.

1 Like

Thanx once again Tom_I,

I got to this stage. now trying to find if I can format the time to a shorter version so it can be seen on the Entities card on mobile and tablets:


I tried the format command but doesnt seem to work:

tried this:

Entities card. Not entity card.

1 Like

aaahhhh the little things in life! Thank you for spotting my mistake.

type: entities
title: Heating Schedule & Next
entities:
  - type: divider
  - type: attribute
    entity: schedule.central_heating_2
    attribute: next_event
    format: time
state_color: true

1 Like

Tom_l, thank you for all the insight!! I have a couple questions about your card setup. Do you have buttons in the header and footer to create the setup shown in the screenshot? How did you get the buttons you have to look that way (ie. The temp bar instead of a number)? Did your thermostat come with the entities of “heat set” and “cool set” as part of its integration or did you manually add those entities?

Background: I have a Honeywell T9 thermostat that I just purchased and am trying to automate night vs day temperatures.