Using PID_Compact
4.2 PID_Compact V2
Requirements
● PIDCtrl.PIDInit is only effective if the integral action is activated (Retain.CtrlParams.Ti tag
> 0.0).
● You must assign PIDCtrl.PIDInit and OverwriteInitialOutputValue in your user program
yourself (see example below). PID_Compact does not automatically change these tags.
● PIDCtrl.PIDInit is only effective when PID_Compact is in automatic mode (parameter
State = 3)
● If possible, select the sampling time of the PID algorithm (Retain.CtrlParams.Cycle tag) in
such a way that it is identical for all controllers, and call all controllers in the same cyclic
interrupt OB. In this way, you ensure that the switchover does not take place within a
controller cycle or a PWM period.
Note
Constant adaptation of the output value limits
Instead of the active updating of the controllers without access to the actuator described
here, this is implemented alternatively by constant adaptation of the output value limits in
other controller systems.
This is not possible with PID_Compact, because a change of the output value limits is not
supported in automatic mode.
92
Function Manual, 03/2017, A5E35300227-AC
PID control