ScratMan / HASmartThermostat

Smart Thermostat with PID controller for HomeAssistant
336 stars 48 forks source link

pid_i is still an active attribute #147

Closed Kolia56 closed 1 year ago

Kolia56 commented 1 year ago

Describe the bug As of 2023.1 it is said that "The pid_p, pid_i, pid_d and pid_e attributes are now removed from the extra state attributes of the thermostat to avoid overloading the HA database" I just upgraded to v2023.2.1 under HASO 2023.3.0

Looking at attributes of one the thermostat, pid_i is still reported. Is it expected?

Running HAOS 2023.3.0

hvac_modes: heat, off min_temp: 2 max_temp: 22 preset_modes: none, away, eco, boost, comfort, home, sleep, activity current_temperature: 18.8 temperature: 18 hvac_action: idle preset_mode: none away_temp: 10 eco_temp: 15 boost_temp: 20 comfort_temp: 19 home_temp: 21 sleep_temp: 17 activity_temp: 20 control_output: 5.7 kp: 4.405673165173575 ki: 0.024274417346673835 kd: 199.90135871366417 ke: 0 pid_mode: auto pid_i: 9.2 friendly_name: Salle de bains amis supported_features: 17

Chupaka commented 1 year ago

Just random notes: The commit that made this change: https://github.com/ScratMan/HASmartThermostat/commit/9ef3a260324da7e9df66f3f050fa3f89c0935100 The commit that introduced pid_i back even in non-debug mode: https://github.com/ScratMan/HASmartThermostat/commit/73d2e5a375aa8f7704055db61073cf2583ec15da

ScratMan commented 1 year ago

Hi, it's an error in the commit message, the pid_i remains always active otherwise the integral would be cleared upon reboot, which is not recommended.