[R_AG] Read analog group
Function block R_AG links a group manager object that controls the continuous acquisition of group data (present value/status flag pairs) from multiple data points for a specific group data tag.
R_AG links a group manager object that controls the continuous acquisition of group data (present value/status flag pairs) from multiple data points for a specific group data tag. In addition, the group manager object triggers a configured evaluation function that calculated the resulting value. R_AG periodically reads the evaluated results at a preconfigured interval. A read can also be triggered by an external source.
R_AG can be configured to supply multiple (up to five) evaluated, resulting values based on the selectable evaluation functions. At least one evaluation function must be configured.
Proprietary objects are necessary for the grouping infrastructure: A group manager object and one or more group member objects. Individual data points are grouped and referenced via the group member objects and the data is acquired and forwarded by the group member object to the group manager object.
Compatible data points:
- Analog inputs [AI]
- Analog output [AO]
- Analog calculated value [ACalcVal]
- Analog configuration value [ACnfVal]
- Analog process value [APrcVal]
Required property from grouped data points:
- Present value
- Status flag
Input | Description | Data type | Default value |
|---|---|---|---|
Interval | Read interval Configurable polling time that specifies how often the calculated results are read. | Time | 15s_0ms |
ImpRead | Impulse for read Linkable pin that allows an external source to provide a digital pulse to initiate reading. | Boolean | 0 |
EvlFnct1…EvlFnct5 | Evaluation function 1…Evaluation function 5 [EvlFnct1] determines the type of procedure performed on the valid, present values from the acquired group data with a common [GrpTag]. The functionality of [EvlFnct2]...[EvlFnct5] is the same as [EvlFnct1]. | Integer | 32767 |
1: Sum | |||
ValMax1…ValMax5 | Maximum value 1…Maximum value 5 Optional, configurable parameter for the evaluation function that sets a high limit for the acquired group data values with a common [GrpTag].
The functionality of [ValMax2]...[ValMax5] is the same as [VaIMax1]. | Real | 3.402822E38 |
ValMin1…ValMin5 | Minimum value 1 …Minimum value 5 Optional, configurable parameter for the evaluation function that sets a low limit for the acquired group data values with a common [GrpTag].
The functionality of [ValMin2]...[ValMin5] is the same as [VaIMin1]. | Real | -3.402822E38 |
ValNum1…ValNum5 | Number of values 1…Number of values 5 Configurable parameter used together with options 8 and 9 (AVERAGEMIN and AVERAGEMAX) of the evaluation function pin [EvlFnct1]. | Integer | 4 |
GrpTag | Grouping tag Specifies the specific group data (present value, status flags) that the function block acquires and evaluates. | Double Word | 0 |
|
BaObjRef | BA-Object reference | Structure | --- |
BaObjRef | Device identifier | Double Word | 16#3FFFFF |
BaObjRef | Object identifier | Double Word | 16#3FFFFF |
BaObjRef | Item identifier | Integer | -1 |
Output | Description | Data type | Default value |
|---|---|---|---|
Val1...Val5 | Value 1...Value 5 | Real | 0.0 |
The evaluated, resulting value based on the evaluation function selected in [EvlFnct1]. [Val1] is the processed result from [ValNum1] and the range based on [ValMin1] and [ValMax1]. [Val1] belongs to one of five output sets where each contains [ValX], [DstbX], [CntX] and [UpdIndX]. [Val1] displays:
The functionality of [Val2]...[Val5] is same as [VaI1]. | |||
Cnt1…Cnt5 | Count 1…Count 5 | Integer | 0 |
The evaluated, resulting value based on the CountOfVal evaluation function selected in [EvlFnct1]. [Cnt1] belongs to one of five output sets where each contains [ValX], [DstbX], [CntX] and [UpdIndX].
The functionality of [Cnt2]...[Cnt5] is same as [Cnt1]. | |||
Dstb1...Dstb5 | Disturbance 1...Disturbance 5 [Dstb1] indicates whether the result of the evaluation selected on [EvlFnct1] is valid. | Boolean | 0 |
UpdInd1...UpdInd5 | Update indication 1...Update indication 5 | Boolean | 0 |
[UpdInd] Indicates that at least one of the present values in the evaluation was updated with a new or the same value. [UpdInd] is only set to 1, if the updated value is located within the configured ValMin/ValMax range. [UpdInd1] is set to 1 only if [Dstb1] = 0. The functionality of [UpdInd1]...[UpdInd5] is the same as [UpdInd1]. Note | |||
NumVals | Number of valid values Number of valid, present values acquired for a specific [GrpTag]. | Integer | 0 |
NumMbrs | Number of aggregated members Number of present values acquired for a specific [GrpTag], typically equal to the number of group member objects addressed by the group manager for a specific group. | Integer | 0 |
ErrCode | Error code indication | Integer | 0: No error |
= 0 - No error | |||