How? Generic Thermostat, tolerances, and hysteresis

So, I want to use hysteresis as follows:-

  • When the system is heating up, turn off the heater when the actual temp read by the thermostat is 0.5C below the desired temperature.

  • When the system is cooling down, turn on the heater when the actual temp is 1.0C above the desired temp.

This will adjust the system for my particular heating setup, radiators, slow smart TRV response times, and the way the hub works. 0.5 and 1.0C were the values used by the engineer when the ‘smart home’ was installed - it all worked perfectly. Now I am using HA I want to emulate this.

So, I am using generic_thermostat; my impression is that the actual on/off heating can be adjusted using tolerances. Can you confirm my understanding please. As I understand things…

  • cold_tolerance is deducted from the target_temperature and this is the temp that the thermostat input variable actual_temperature must fall to before the thermostat transitions from idle to heating mode.

  • hot_tolerance is added to the target_temperature and this is the temp that actual_temperature must rise to before the thermostat transitions to from heating to idle mode.

but this isn’t what I want I think. what I need then is:-

  • when in heating mode I need to switch OFF the heating system when the actual_temperature (input to generic_thermostat) is 0.5C below the target_temperature.

  • when in idle mode AND when cooling down (so actual_temperature is on the down curve and is less than the previous value of actual_temperature) I need to switch ON the heating system when the actual_temperature is 1.0C above the target_temperature.

that should flatten out the curve. But how would I code this up??

I guess it is something like:

IF mode=heating THEN calibrated_temp = actual_temp + 0.5
IF mode=idle AND previous_actual_temp > actual_temp THEN calibrated_temp = actual_temp - 1.0

2 Likes

this thermostat platform was never worked properly :frowning:
hysteresis just doesn’t work as it should.