T33_MIN_MAX_CONTROLLER
PROGRAM TEST_T33 VAR REAL1,REAL2,REAL3,REAL4,REAL5,REAL6,REAL7,REAL8: REAL; BOOL1,BOOL2,BOOL3,BOOL4,BOOL5,BOOL6,BOOL7,BOOL8: BOOL; FB: LIB.HVAC.V1_0.T33_MIN_MAX_CONTROLLER; END_VAR FB(IN:= REAL1, WALARMAX:= REAL1, WALARMIN:= REAL2, WMAX:= REAL3, WMIN:= REAL4, XPALARMAX:= REAL5, XPALARMIN:= REAL6, XPMAX:= REAL7, XPMIN:= REAL8, BALARMAX=> BOOL1, BALARMAXN=> BOOL2, BALARMIN=> BOOL3, BALARMINN=> BOOL4, BMAX=> BOOL5, BMAXN=>BOOL6, BMIN=> BOOL7, BMINN=>BOOL8); END_PROGRAM
LIB\HVAC
V1.0
The block monitors the measured value and announces exceeding of alarm limits.
Input | Type | Description | Default value |
IN | REAL | Measured value | 0 |
WALARMAX | REAL | Max alarm setpoint | 220 |
WALARMIN | REAL | Min alarm setpoint | 80 |
WMAX | REAL | Max setpoint | 180 |
WMIN | REAL | Min setpoint | 120 |
XPALARMAX | REAL | Max alarm hysteresis | 20 |
XPALARMIN | REAL | Min alarm hysteresis | 20 |
XPMAX | REAL | Max hysteresis | 20 |
XPMIN | REAL | Min hysteresis | 20 |
Output | Type | Description |
BALARMAX | BOOL | Max alarm output |
BALARMAXN | BOOL | Max alarm output, negated |
BALARMIN | BOOL | Min alarm output |
BALARMINN | BOOL | Min alarm output, negated |
BMAX | BOOL | Max output |
BMAXN | BOOL | Max output, negated |
BMIN | BOOL | Min output |
BMINN | BOOL | Min output, negated |
The block contains two pairs of comparators. When controlling water pressure in a heating system, the min signal is used to control the supply water valve, max signal to control the water drainage valve, min min signal to disable all aggregates, and max max signal to indicate the maximum system pressure level. Other values can be monitored and controlled as well, like temperature, humidity, etc. Hysteresis prevents hunting at the setpoint value.
The hysteresis, or Xp band, is used to prevent flickering of the output signal.
Similar applies for the alarm signals:
The block can be used to control pressure, water level, but also 2-point heating and cooling systems. It is useful thank to four comparators in one block which save schema space and improve legibility.
The block compares the measured water pressure PWATER with the pressure setpoint PWATERSETPT. As soon as the pressure drops below the min value, the water valve SOLENOIDVALVE opens, when the pressure rises above WMIN + HYSTERESE the valve closes. When the WALARMAX or WALARMIN are teached, the alarms are invoked. The min min pressure disables the boiler and pump operation. The operation is restored only after the alarm has been acknowledged and reset (the MEMORY output must be FALSE).