@roschi can you confirm whether Schedy will be affected by any of these breaking changes:
Thanks.
@roschi can you confirm whether Schedy will be affected by any of these breaking changes:
Thanks.
@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,
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
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
Just one question, is it possible to modify the sensor to count every 10 minutes? I think every minute may be a bit agressive.
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
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: SchedyAppactor_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
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?
@roschi
I am not sure how to use HVAC mode on a heating radiator valve (no cooling) with the modes heat, auto and off.
should it switched on or off? If i set it to heat and it is in mode auto i get errors regarding unknown mode auto and vice versa.
hvac_mode_on: auto # or heat?
Absolutely!
I live in an old house, that is difficult to keep warm in certain conditions.
I don’t want the heating to run at full all day, because I can’t afford that, so I have the temperature gradually ramp up during the day and then ramp down again.
But things like the wind coming from the North or East, will chill the house down quickly, more than the wind coming from the south will.
Additionally in order to save a bit of money, I don’t want the heating running at a higher temperature when I am not at home.
I am still tweaking, but I basically have the heating reacting to external conditions as well as internal ones, in order to keep a reasonably comfortable temperature that I can just about afford. It is certainly not what many people would consider to be toasty though.
The official advice in the UK at least is that living areas should be around 21C and bedrooms around 18C. I can’t afford to heat my living areas to 21C, and I doubt it would be possible even if I could. But I can afford to keep the bedroom at a comfortable-ish 18C - but only overnight, it’s pointless to heat the bedroom during the day when I am not in it. The heating system is not zoned like fancy American ones, the one boiler heats all the radiators, and all the radiators have thermostatic valves on them, so I can’t specifically heat a certain room, I can only turn the whole house heating on or off, and leave the thermostatic (not smart) valves to do the rest. Thus the bedroom will heat up if it is cold and the heating comes on because the living room is too cold, but the logic of when to turn the heating off, ignores the temperature of the bedroom during the day, because even if the bedroom gets too hot, I can’t do anything about it, and I don’t really care, I only care that the living room is not freezing.
interesting, thank you, but not my usecase. Have radiator valves / thermostats.
Hi @vajdum
I live in an old house too and save a lot on my gas bill by installing motorized radiator valves with separate temperature sensors per room. Using Scheky I even adjust on the month sinc in April/May there is no need to heat up in the morning when there is a sunny day coming. I would advise you to invest in this.
Long ago I even did a poor mans solution I installed resistors in standard thermostat knobs and by running a current through them it would think it is hot enough and close the valve
Yes, my valves are smart and i have thermometers in some rooms. But no need to do this sort of weather based related calculations. Especially as i can change my valves, but not my heater with HA.
I think i could calculate some pre heating times based on weather.