FB_BA_SwiHys2P
The function block FB_BA_SwiHys2P is a two-point switch with adjustable hysteresis and hysteresis offset.
A general function block enable can be implemented at input bEn. If the function block is locked, the output bQ is FALSE. The setpoint for the two-point switch is connected at input rSp. The control direction of the function block depends on the input variable bActn.
The active switching points result from the setpoint, the hysteresis and the hysteresis offset. They are output at rSwiHi and rSwiLo.
- The upper switching point results from rSp + rHys/2 + rHysOffs.
- The lower switching point results from rSp + rHys/2 + rHysOffs.
If bActn TRUE, the result is direct/synchronous control direction (cooling mode).
If bActn is FALSE, the result is indirect/reversed control direction (heating mode).
VAR_INPUT
bEn : BOOL;
rIn : REAL;
rSp : REAL;
rHys : REAL;
rHysOffs : REAL;
udiDlyOn_sec : UDINT;
udiDlyOff_sec : UDINT;
bActn : BOOL;
bEn: General enable of the function block.
rIn: Input value.
rSp: Setpoint input.
rHys: Hysteresis.
rHysOffs: Hysteresis offset.
udiDlyOn_sec: Switch-on delay
udiDlyOff_sec: Release delay
bActn: Control direction.
VAR_OUTPUT
bQ : BOOL;
rSwiHi : REAL;
rSwiLo : REAL;
udiRemTiDlyOn_sec : UDINT;
udiRemTiDlyOff_sec : UDINT;
bQ: Output.
rSwiHi: Upper switching point.
rSwiLo: Lower switching point.
udiRemTiDlyOn_sec: Time remaining before switching on.
udiRemTiDlyOff_sec: Time remaining before switching off.
Requirements
Development environment | Required PLC library |
---|---|
TwinCAT from v3.1.4024.7 | Tc3_BA from v1.1.6.0 |