Control2P
Control2P (FB)
Control2P (FB)FUNCTION_BLOCK Control2P
Short description
2-point controller with actual value / setpoint / enable and adjustable switching hysteresis The action (inverted / direct) is also adjustable.
Representation

Interfaces
Inputs
rX
REAL
Analog measured value
rW
REAL
Analog setpoint
xEn
BOOL
* FALSE: Controller locked * TRUE: Controller enabled
Outputs
xY
BOOL
Digital output signal
rDiff
REAL
Control deviation (rX - rW)
rOnAt
REAL
Absolute switch-on point (rW + rSwitchOnPoint)
rOffAt
REAL
Absolute switch-off point (rW + rSwitchOffPoint)
Setpoints / parameters
rSwitchOffPoint
REAL
0.5
Switch-off point relative to the setpoint rW
rSwitchOnPoint
REAL
-0.5
Switch-on point relative to the setpoint rW
xOffCondition
BOOL
FALSE
State of the output xY at xEn = 0
xInitValue
BOOL
FALSE
State of the output xY after a restart
eAction
eControlMode
eControlMode.Inverted
Action of the controller (Inverted = Heating, Direct = Cooling)
eManModeB
eManBin
eManBin.Auto
Operating mode for the digital output signal xY
Function description
Enable input xEn
xEn
Control process
xY
rDiff
rOnAt
rOffAt
Notes
TRUE
TRUE
X
X
x
x
Enable of the control
FALSE
FALSE
xOffCondition (if eManModeB = eManBin.Auto)
X
x
x
Locking of the control
Legend: X = any
Digital output xY
The digital output xY is influenced by the enable input xEn, the control process and the manual override module.
Control process
xEn
eManModeB
xY
Notes
FALSE
TRUE
eManBin.Auto
FALSE
Automatic operation - control process = FALSE
TRUE
TRUE
eManBin.Auto
TRUE
Automatic operation - control process = TRUE
X
FALSE
eManBin.Auto
xOffCondition
Automatic operation without enable
X
X
eManBin.ManOff
FALSE
Manual mode - Off
X
X
eManBin.ManOn
TRUE
Manual mode - On
Legend: X = any
Control process
The controller can be operated in two different operating modes (eAction = eControlMode.Inverted or eAction = eControlMode.Direct). The following rules apply:
eAction
Control
eControlMode.Inverted
rSwitchOnPoint < rSwitchOffPoint
eControlMode.Direct
rSwitchOnPoint > rSwitchOffPoint
If in operating mode eControlMode.Inverted the rSwitchOffPoint the rSwitchOnPoint, then the rSwitchOffPoint is increased by 0.1 relative to the rSwitchOnPoint is decreased by 0.1. The output variables rSwitchOnPoint the rSwitchOffPoint, then the rSwitchOffPoint is increased by 0.1 relative to the rSwitchOnPoint ), absolute switch-on point rDiff (rX - rW) and absolute switch-off point rOnAt (rW + rSwitchOnPoint) are available regardless of the enable input rOffAt (rW + rSwitchOffPointalways available. xEn Automatic operation - Inverted On
xEn
eAction
rDiff
xY
Notes
TRUE
eControlMode.Inverted
< rSwitchOnPoint
TRUE
Automatic operation - Inverted Off
TRUE
eControlMode.Inverted
> rSwitchOffPoint
FALSE
Automatic operation - Direct On
TRUE
eControlMode.Direct
> rSwitchOnPoint
TRUE
Automatic operation - Direct Off
TRUE
eControlMode.Direct
< rSwitchOffPoint
FALSE
Legend: X = arbitrary In summary, the control process can alternatively be described as follows:
Legend: X = arbitrary In summary, the control process can alternatively be described as follows:
xEn
eAction
rX
xY
Notes
TRUE
eControlMode.Inverted
< rOnAt
TRUE
Automatic operation - Inverted Off
TRUE
eControlMode.Inverted
> rOffAt
FALSE
Automatic operation - Direct On
TRUE
eControlMode.Direct
> rOnAt
TRUE
Automatic operation - Direct Off
TRUE
eControlMode.Direct
< rOffAt
FALSE
Legend: X = arbitrary In summary, the control process can alternatively be described as follows:
Legend: X = any
CODESYS
InOut:
Input
rX
REAL
Input
rW
REAL
Input
xEn
BOOL
Input Const
rSwitchOffPoint
REAL
0.5
Input Const
rSwitchOnPoint
REAL
-0.5
Input Const
xOffCondition
BOOL
FALSE
Input Const
xInitValue
BOOL
FALSE
Input Const
eAction
eControlMode
eControlMode.Inverted
Input Const
eManModeB
eManBin
eManBin.Auto
Output
xY
BOOL
Output
rDiff
REAL
Output
rOnAt
REAL
Output
rOffAt
REAL
Last updated

