# HG changeset patch # User Michiel Broek # Date 1424020724 -3600 # Node ID 876a8420c75ac29394da95b449da5e9f71383540 # Parent 249e7d506069a184d5adadaf7b9dcb24ff9cab1d Fixed logging of old pid error diff -r 249e7d506069 -r 876a8420c75a thermferm/thermferm.c --- a/thermferm/thermferm.c Sun Feb 15 18:06:21 2015 +0100 +++ b/thermferm/thermferm.c Sun Feb 15 18:18:44 2015 +0100 @@ -1349,6 +1349,8 @@ syslog(LOG_NOTICE, "sp=%.2f pv=%.2f err_old=%.2f err=%.2f P_err=%.2f I_err=%.2f D_err=%.2f Out=%.2f", sp, pv, unit->PID_err_old, err, P_err, unit->PID_I_err, D_err, Out); } + unit->PID_err_old = err; + if (unit->heater_address) { if (Out >= 2) { if (unit->heater_wait < unit->heater_delay) {