Common Structure Data Type Definitions
Common Structure Data Type Definitions
Structure data types serve as the major input and output data carriers between different function blocks, conveying input, configuration, and parameterization data.
The following sections list the names of the structure data types that are used in several function blocks of this library, followed by a table that describes the internal parameters that populate the structure.
The alarm control structure data type is used to indicate a detected alarm within the pump group and to reset detected alarms.
Element of stAlrmCtrl |
Data Type |
Description |
---|---|---|
xAlrmRele |
BOOL |
When FALSE, an alarm has been detected. The functions set the outputs to the default state. If a function detects a system level alarm, then the function sets this bit to FALSE. The pump group is stopped. |
xRstAlrm |
BOOL |
Resets the detected alarms. When set to TRUE, the alarm values are set to zero, when the cause has been corrected. |
NOTE: This alarm control structure data type needs to be defined only once per pump in the system.
The stOpMode structure data type controls / switches the operating mode of the pumping application.
If a function block detects an alarm state in the pump group, this function block automatically sets the operating mode to manual mode. This is achieved by setting the structure data type stOpMode to xAuto = FALSE and xMan = TRUE. At the same time, the function block indicates that an alarm has been detected by setting xAlrm to TRUE. Operator intervention is required to change from manual mode to another operating mode and to acknowledge the detected alarm.
Element of stOpMode |
Data Type |
Description |
---|---|---|
xAlrm |
BOOL |
alarm mode When TRUE, indicates that an alarm has been detected in the pump group during data processing. |
xAuto |
BOOL |
automatic mode When TRUE, the pumping application is working in automatic mode without user intervention. |
xMan |
BOOL |
manual mode When TRUE, the pumping application is working in manual mode, which means it is controlled by user inputs. |
xFill |
BOOL |
pipe fill mode When TRUE, the pumping application is working in pipe fill mode. After start or restart of the pumping application the pipe fill function starts specific processes (as defined with the PipeFill function block) to reach the pressure working range as quickly as possible. |
xCavtMarg |
BOOL |
cavitation margin mode When TRUE, the suction pressure is below the cavitation margin and the pumping application is running in cavitation margin mode as defined with the CavtProt function block. |
xCaviFlow |
BOOL |
Reserved. |
xPidMan |
BOOL |
PID manual mode When TRUE, the pumping application is running with a PID (proportional integral derivative) manual setpoint. This mode is set by the operator using the operator interface. In this mode, the PumpPidStag function block uses an alternative pressure setpoint manually entered by the operator. |
xPIDStop |
BOOL |
PID stopped mode When TRUE, the PID has been stopped. |
xPIDAuto |
BOOL |
PID automatic mode When TRUE, the PID is running in automatic mode. |
xPrim |
BOOL |
Reserved. |
xSle |
BOOL |
sleep mode When TRUE, the pumping application is working in sleep mode in times of low water demand in order to avoid using the main pumps (VS pumps or FS pumps). The sleep mode is started by the PumpPidStag function block. It is stopped either by the PumpPidStag function block or by the AuxPumpCtrl function block. |
xRem |
BOOL |
remote mode When TRUE, disables the local HMI and enables the remote HMI to control the application. |
xLoc |
BOOL |
local mode When TRUE, disables the remote HMI and enables the local HMI to control the application. |
NOTE: This alarm control structure data type needs to be defined only once per pump in the system.
The stAna structure data type is used for the analog input value from the pressure sensor (measuring the pressure) or the flow meter (measuring the flow).
Element of stAna |
Data Type |
Description |
---|---|---|
rAnaVal |
REAL |
Scaled (physical units) analog value. The pressure / suction pressure value used as an input by the PipeFill function block and CavtProt) function block. |
xStat |
BOOL |
When TRUE, indicates that the value of rAnaVal is valid. |
The stAvai structure data type is used to indicate the availability of 8 devices. This variable is used for VSDs, VS pumps, and FS pumps.
Element of stAvai |
Data Type |
Description |
---|---|---|
xAvai1 |
BOOL |
When TRUE, indicates that device 1 is available. |
... |
... |
... |
xAvai8 |
BOOL |
When TRUE, indicates that device 8 is available. |
The stStagVal structure data type contains the stage value and its state. The stage value represents the demand for the number of pumps which are needed to maintain the required pressure level.
Element of stStagVal |
Data Type |
Description |
---|---|---|
siStag |
SINT |
Indicates the number of pumps which are needed to maintain the required pressure level. |
xSta |
BOOL |
When TRUE, indicates that no error has been detected in the pump. |
The stCmd structure data type is used to switch the 8 devices (VSDs or FS pumps) into run or stop state.
Element of stCmd |
Data Type |
Description |
---|---|---|
xDev1 |
BOOL |
When TRUE, switches device 1 into run state. |
... |
... |
... |
xDev8 |
BOOL |
When TRUE, switches device 8 into run state. |
The stMode structure data type controls / switches the modes of the individual pumps and VSDs.
Element of stMode |
Data Type |
Description |
---|---|---|
xRem |
BOOL |
remote mode When TRUE, the pump is locked for control by an HMI at a remote station. |
xLoc |
BOOL |
local mode When TRUE, the pump is locked for control by the local HMI. |
xHand |
BOOL |
hand mode When TRUE, the pump is locked for inputs that are made directly at the pump. Any commands from HMIs are blocked. |
xMain |
BOOL |
maintenance mode When TRUE, the pump is in maintenance mode and is not available for the application. |
xAuto |
BOOL |
automatic mode When TRUE, the pump is operated in automatic mode without user intervention. |
xManu |
BOOL |
manual mode When TRUE, the pump is controlled by user inputs. |
xVsd |
BOOL |
VSD mode When TRUE, the VS pump is fixed linked to a VSD. |
xByps |
BOOL |
When TRUE, the VS pump bypasses the VSD because the VSD, to which the VS pump had been linked, is not available. |
xAlrm |
BOOL |
alarm mode When TRUE, an alarm has been detected in the pump. |
xAlrt |
BOOL |
Reserved. |
The stSta structure data type indicates the status of the individual pumps as indicated by external devices (key switches, sensors, contactors).
Element of stSta |
Data Type |
Description |
---|---|---|
xHandMod |
BOOL |
hand mode When TRUE, the pump has been locked for operation in hand mode by a key switch. It is not available for the pumping application. |
xMain |
BOOL |
maintenance mode When TRUE, the pump has been locked for operation in maintenance mode by a key switch. It is not available for the pumping application. |
xDryRun |
BOOL |
dry run When TRUE, a sensor has indicated that the pump is running dry. It is not available for the pumping application. |
xTempAlrm |
BOOL |
high temperature When TRUE, a sensor has indicated that the temperature in the pump is too high. It is not available for the pumping application. |
xErr |
BOOL |
hardware error detected When TRUE, a hardware error has been detected in the pump. It is not available for the pumping application. |
xLinkOk |
BOOL |
bus link OK When TRUE, the data connection to the distributed I/O hardware module which provides status information on the pump is available. In contrast to the other parameters, this parameter is by default set to TRUE. No error is detected if no distributed I/O hardware module is used in the application. |
xRun |
BOOL |
pump run When TRUE, a contactor has indicated that the pump has been switched in run status. |
xStop |
BOOL |
pump stop When TRUE, a contactor has indicated that the pump has been switched in stop status. |
The stVsdSta structure data type indicates the status of the individual VSDs as indicated by the VSD and/or external devices (key switches, sensors, contactors).
Element of stVsdSta |
Data Type |
Description |
---|---|---|
xPowerOk |
BOOL |
VSD power OK When TRUE, the power supply for the VSD is available. In contrast to the other parameters, this parameter is by default set to TRUE. No error is detected if no power supply detection is used in the application. |
xLinkOk |
BOOL |
bus link OK When TRUE, the data connection to the distributed I/O hardware module which provides status information on the VSD is available. In contrast to the other parameters, this parameter is by default set to TRUE. No error is detected if no distributed I/O hardware module is used in the application. |
xAlarm |
BOOL |
detected alarm state When TRUE, an alarm has been detected for the VSD. It is not available for the pumping application. |
xRun |
BOOL |
VSD run When TRUE, indicates that the VSD is in run state. |
The stLink structure data type is used to link one VS pump dynamically to one of the up to 8 possible VSDs or constantly to one of the 4 VSDs or directly to the power source (direct online) by switching the respective contactors (see examples below).
Element of stLink |
Data Type |
Description |
---|---|---|
xVsd1 |
BOOL |
When TRUE, the VS pump is linked to VSD 1. |
xVsd2 |
BOOL |
When TRUE, the VS pump is linked to VSD 2. |
xVsd3 |
BOOL |
When TRUE, the VS pump is linked to VSD 3. |
xVsd4 |
BOOL |
When TRUE, the VS pump is linked to VSD 4. |
xByp5 |
BOOL |
When TRUE, the VS pump bypasses the VSD. In this mode, the VS pump is directly linked to the power source (direct online). |
xRun |
BOOL |
When TRUE, the VS pump is constantly linked to a VSD. This is only used in fixed link operational mode. |
Example of using the stLink structure data type with variable links (fixed link operational mode disabled):
Example of using the stLink structure data type with fixed links (fixed link operational mode enabled):
The stAuxPumpCom structure data type is used to switch the auxiliary pump. The structure contains a binary element to switch the auxiliary pump into run state and a binary element to indicate the status of this procedure.
Element of stAuxPumpCom |
Data Type |
Description |
---|---|---|
xAuxPumpRunCom |
BOOL |
When TRUE, the auxiliary pump is switched into run state. |
xSta |
BOOL |
When TRUE, the xAuxPumpRunCom command is valid. |
The stFillStat structure data type is used to indicate the state of the pipe fill function.
Element of stFillStat |
Data Type |
Description |
---|---|---|
xFill |
BOOL |
When TRUE, indicates that the pipe fill function is in progress. |
xFillOk |
BOOL |
When TRUE, indicates that the pressure value has reached the defined working range. NOTE: If the pipe fill function is not used, the parameter stFillStat.xFillOk has to be set to TRUE to enable the PID and stage functions of the PumpPidStag function block. |
xSequ1 |
BOOL |
When TRUE, the pipe fill function is running in sequence 1. |
xSequ2 |
BOOL |
When TRUE, the pipe fill function is running in sequence 2. |
xAlrm |
BOOL |
alarm mode When TRUE, indicates that an alarm has been detected in the pipe fill function. |
The stCavtSta structure data type is used to indicate the state of the cavitation protection function.
Element of stCavtSta |
Data Type |
Description |
---|---|---|
xProtActv |
BOOL |
When TRUE, indicates that the cavitation protection function is in progress. |
xSpRedu |
BOOL |
When TRUE, indicates that the setpoint of the control pressure has been reduced because the suction pressure is dropping. |
xRstPos |
BOOL |
When TRUE, indicates that a reset of the cavitation alarm can be executed because the suction pressure is above the minimal setpoint value (legend item 5 in the diagram representing the working principle of the cavitation protection procedure). |
xGdntPlus |
BOOL |
When TRUE, indicates that the suction pressure is rising (suction pressure gradient is positive). |
xGdntMnus |
BOOL |
When TRUE, indicates that the suction pressure is dropping (suction pressure gradient is negative). |
The stSp structure data type is used to indicate a setpoint value.
Element of stSp |
Data Type |
Description |
---|---|---|
rVal |
REAL |
Indicates a reference value. |
xsta |
BOOL |
When TRUE, indicates that the value of rVal is valid. |
The stDeviceAlrm structure data type is used to indicate detected errors of the (maximum 8) FS or VS pumps or VSDs.
Element of stDeviceAlrm |
Data Type |
Description |
---|---|---|
xDev1Alrm |
BOOL |
When TRUE, an error has been detected for pump 1 / VSD 1. |
... |
... |
... |
xDev8Alrm |
BOOL |
When TRUE, an error has been detected for pump 8 / VSD 8. |
The stRespErr structure data type is used to indicate a detected error in the FS or VS pumps or VSDs (maximum of 8) because the time defined with the parameter i_tDelFbck has expired without receiving a response from the pump / VSD.
Element of stRespErr |
Data Type |
Description |
---|---|---|
xDev1 |
BOOL |
When TRUE, an error has been detected for pump 1 / VSD 1 because no response has been received within the defined time. |
... |
... |
... |
xDev8 |
BOOL |
When TRUE, an error has been detected for pump 8 / VSD 8 because no response has been received within the defined time. |
The array of BYTE abyVsdNu is used to contain the number of the VSD associated with a given pump. The index to the array indicates the VS pump number.
Element of abyVsdNu |
Data Type |
Description |
---|---|---|
abyVsdNu |
ARRAY [0..7] of BYTE |
Defines the VSD numbers. Range: o0 = unused o1...4 = VSD numbers o5 = bypass o6 = run (fixed link operational mode) |
The asiPrty is used to contain the priority assignment:
Element of asiPrty |
Data Type |
Description |
---|---|---|
asiPrty |
ARRAY [0..7] of SINT |
The array of short integer is used to list in sequence the priority of the VSDs or pumps as defined by the operating hours or by operator inputs: The VSD / pump that is the first in the list is assigned the highest priority. |
The stDiscPres contains 2 elements, one of which is a structure. stAna described below, contains the primary analog value. The second element is the value of the optional secondary pressure sensor. The secondary analog value is used, assuming it is available in your system, only in the case that the primary analog value is not valid.
Element of stDiscPres |
Data Type |
Description |
---|---|---|
stAna |
stAna |
Refer to the stAna structure. |
rSurr |
REAL |
Analog input value provided by a second pressure sensor via the AnaIput function block. |
The stRef structure data type is used to indicate a reference value. This user-defined data type has been used by compensation functions (CompSp: Setpoint Adaptation, and CompSpFlow: Setpoint Adaptation by Using Flow Value), by the pipe fill function and/or the cavitation protection function.
Element of stRef |
Data Type |
Description |
---|---|---|
rVal |
REAL |
Indicates a reference value. |
xsta |
BOOL |
When TRUE, indicates that the value of rVal is valid. |