Closed martenjacobs closed 3 years ago
Hi and thanks for the comments. That is an interesting way of achieving the result you want. The definition of integral_default, from the readme is: It should be set to an estimate of what the power requirement might be in order to maintain the process at the setpoint. So the way I have handled this in the past is not to persist the integral value but the power output, which should give a similar result when fed back into integral_default on startup. Your suggestion is actually rather better though I think. If you would like to submit a PR with suggested improvements to the readme that would be great.
@colinl see #18
Closed by PR #18
I'm using this node to control underfloor heating in my house. This works pretty well, but I've been struggling with persisting the integral value between restarts. My set-up caches the output integral in persistent storage, so it can feed the value back into the PID after flows are restarted, causing as little disruption to the heating system as possible. I thought this would be as simple as feeding back the cached integral in the
integral_default
key on startup, but this didn't work. It actually caused the integral to completely shift each time. Finally, I had to check the source code to find out that the initial value for the integral is calculated this way:So that means I have to supply my
integral_default
like this:This is fine, but I think it should at least be in the documentation.