Selected Functions
5-4
5.2 PID Algorithms
The
T
urboPlastic module provides two distinct user
-selectable PID
algorithms that give different control responses (see PID, Section 1.3).
Algorithm selection depends on the machine controlled by the user and the
response desired.
5.2.1
The standard PID algorithm is one of several offered in the 505 series of
controllers, except that when a change of set point is requested, this new
setpoint value is immediately output. This provides an instantaneous or
“step” change in the output to the new setpoint value. PID control then
takes place about the setpoint value. In one case, you can select set point
output as an option; see constant 14, bit 8, page 2-19.
The basic equation for the standard PID algorithm is as follows:
k
c
+ gain
t
d
+ rate
t
i
+ reset
t
s
+ scantime
vsf + velocity scaling factor
setpoint + setpoint from table
prevpos + previous position
currpos + current position
input from V memory table
″
″
″
″
″
inputfromańd
″
Calculate integral constant term:
k
i
+
gainscantime
reset
Calculate derivative constant term:
k
d
+
gainrate
scantime
Calculate process variable:
PVnew +
[prev pos - curr pos]
vsf
Calculate new error term:
curr err + setpoint * PVnew
Calculate new bias term:
trialm
x
+ k
i
currerr ) setpoint
trialm
n
+
k
c
currerr
* k
d
PVnew * PVold ) trialm
x
Calculate new output value:
newoutput + trialm
n
Standar
d PID
Algorithm