Description
Original instructions
Function description
The function block represents a simple PI controller.
A system deviation ERR is formed by the difference between the setpoint SP and the controlled variable PV. This deviation ERR causes the manipulated variable Y to change.
NOTE: This function block performs an internal initialization in the first program cycle after a warm start or cold start (e.g. application download or power cycle) of the PLC program.
Due to this, you have to make sure that the function block is invoked in the first program cycle. In case of inkoving the function block in a later program cycle, the internal initialization will not be performed and the ouputs may deliver wrong values.
WARNING
UNEXPECTED OUTPUT BEHAVIOUR
Make sure that the function block is always invoked in the first program cycle.
Failure to follow these instructions can result in death, serious injury, or equipment damage.
EN and ENO can be configured as additional parameters.
Properties
The function block has the following properties:
Representation in FBD
Representation:
Representation in LD
Representation:
Representation in IL
Representation:
CAL PI1_Instance (MAN:=ManualMode, HALT:=HaltMode, 
    SP:=SetpointValueInput, PV:=ProcessVariable,
    GAIN:=ProportionalRate, TI:=ResetTime,   
    YMAX:=UpperControlLimit, YMIN:=LowerControlLimit,
    YMAN:=ManualValue, Y=>ManipulatedVariable,
    ERR=>OutputSystemDeviation, QMAX=>Y_Reached_YMAX, 
    QMIN=>Y_Reached_YMIN)
Representation in ST
Representation:
PI1_Instance (MAN:=ManualMode, HALT:=HaltMode, 
    SP:=SetpointValueInput, PV:=ProcessVariable,
    GAIN:=ProportionalRate, TI:=ResetTime,   
    YMAX:=UpperControlLimit, YMIN:=LowerControlLimit,
    YMAN:=ManualValue, Y=>ManipulatedVariable,
    ERR=>OutputSystemDeviation, QMAX=>Y_Reached_YMAX, 
    QMIN=>Y_Reached_YMIN) ;
Parameter description
Description of input parameters:
Parameter
Data type
Description
MAN
"1": Manual mode
HALT
BOOL
"1": Halt mode
SP
Setpoint input
PV
REAL
Controlled variable (process variable)
GAIN
REAL
Proportional action coefficient (gain)
TI
Integral time
YMAX
REAL
Upper limit
YMIN
REAL
Lower limit
YMAN
REAL
Manual value
Description of output parameters:
Parameter
Data type
Description
Y
REAL
Manipulated variable
ERR
REAL
Output system deviation
QMAX
BOOL
"1" = Output Y has reached upper limit
QMIN
BOOL
"1" = Output Y has reached lower limit
Runtime error
If YMAX < YMIN an error messages appears.
NOTE: For a list of all block error codes and values, see CLC.