FB_BA_SwiMonit
This function block is used for monitoring limit switches, e.g. for a two-point damper
Functional description
The function block monitors a limit switch in two steps.
Step 1 includes monitoring while the actuator is moving.
Step 2 includes monitoring of the opened state of the actuator.
The function is activated via the input bEn. If bEn is FALSE, the outputs bErrOpn/bErrSwi are also FALSE.
Step 1: If the input bIn is TRUE, the move time for the actuator udiTiAct/udiRT_TiAct is started. If the input bSwi does not become TRUE within this time, a fault is displayed via output bErrOpn. If bSwi becomes TRUE within the time udiTiAct, step 1 is complete, and step 2 becomes active.
Step 2: bIn and bSwi are TRUE. If bIn becomes FALSE, step 1 becomes active again. If bSwi becomes FALSE and does not become TRUE again within the time udiTiDlyMonitSwi/udiRT_TiDlyMonitSwi, a fault is displayed via output bErrSwi.
The faults bErrOpn/bErrSwi are reset, if either bEn or bIn are FALSE.
Inputs/outputs
VAR_INPUT
bEn : BOOL;
bIn : BOOL;
bSwi : BOOL;
udiTiAct : UDINT;
udiTiDlyMonitSwi : UDINT;
bEn: a TRUE signal at this input activates the function block. The value at input udiVall is only output with a delay at udiValQ. If bEn is FALSE, the input value udiValI is output without delay.
bIn: the actuator control must be applied at this input.
bSwi: limit switch actuator
udiTiAct: actuator stroke time [s]
udiTiDlyMonitSwi: delay time of a limit switch in open state [s]. The time becomes active, if bIn is TRUE and the limit switch bSwi changes its state from TRUE to FALSE.
VAR_OUTPUT
bErrOpn : BOOL;
bErrSwi : BOOL;
udiRT_TiAct : UDINT;
udiRT_TiDlyMonitSwi : UDINT;
bErrOpn: fault step 1; limit switch has not reached its end position during the procedure
bErrSwi: fault step 2; limit switch or actuator has left its end position in opened state
udiRT_TiAct: countdown for setting the output bErrOpn [s]. The preset originates from udiTiAct.
udiRT_TiDlyMonitSwi: countdown for setting the output bErrSwi [s]. The preset originates from udiTiDlyMonitSwi.
Requirements
Development environment | Target system | required library | required supplement |
---|---|---|---|
TwinCAT 2.11 R3/x64 | PC/CX | TcBA library from V1.0.0 | TS8040 | TwinCAT Building Automation from V1.0.0 |