I would like to share a test I performed with the PID instruction today.
My red line is my SP. Blue line is PV, green line is OP.
The interesting line is the white line, which is the integral accumulation.
It seems the formula this function uses is:
OP = KP*E + KI * SUM(INT) + KD * dE/dt
or more simply
OP = PROP + INT + DERV
you can see at the start of my test, PROP = 1, INT = 100 (White line) and DERV = 0.
This gives an OP of 101, which gets clipped to 100.
I then increase my error to -20, and my output decreases until it hits 0.
OP = -20 + 20 + 0 = 0
I then increase my PV to 200, then 300.
OP = -220 + 20 + 0 = -200, which gets clipped to zero.
I then decrease my PV by 100, which temporarily makes:
OP = -120 + 20 + 100/0.1 = 900, which gets clipped to 100.
The integral is allowed to wind up in the next scan, as it is no longer on a low limit.
OP = -120 - 27 + 0 = -147 which gets clipped to zero.
I then slowly decrease my error towards the SP. When I reach 80,
OP = 0 - 39 + 0 = -39, which is still clipped to zero.
When my PV goes below my SP, the integral starts winding back to zero, and it is 20 seconds before it reaches zero, and my CV can start changing.
In summary, the integral is allowed to wind up when the derivative is high enough, but doesn't then unwind itself when the derivative drops. This is potential for concern. I'd almost raise a bug with Rockwell, but the answer will probably be to use the PIDE.