[CMD_AG] Command analog group

Function block CMD_AG distributes, for a specific priority, a present value of data type Real to multiple data points for a specific group data tag.

CMD_AG distributes, for a specific priority, a present value of data type Real to multiple data points for a specific group data tag.

Proprietary objects are necessary for the grouping infrastructure: A group manager object and one or more group member objects. The individual member data points are grouped and referenced via group member objects.

CMD_AG writes the value/priority pairs for a specific group data tag to the property 'Group command' of the group manager object. The data is forwarded by the group manager object to the group member object(s), and distributed from there to the impacted member data points with the appropriate group data tag.

Functioning

Compatible data points:

  • Analog output [AO]
  • Analog configuration value [ACnfVal]
  • Analog process value [APrcVal]
  • Third-party objects with the required properties

Required property of a grouped data point:

  • Present value
  • Status flag

Optional properties:

  • Priority array

Operate with priorities

The function block uses 2 approaches to control if operating with priorities:

1. Exclusive control (planned for priorities 1..5, 9..12, 14..16)

  • Initialized at startup
    • Multiple input sets of a function block cannot command the same priority.

2. Last win control (planned for priorities 7, 8, 13)

  • Not initialized at startup.

 

Exclusive control
Priorities: 1...5, 9...12, and 14...16

Last win control
Priorities: 7, 8, and 13

Behavior at plant startup

[EnIn1] = 0
Release priority

[EnIn1] = 0
No release

[EnIn1] = 1
Command priority

[EnIn1] = 1
No command

Command process

If [EnIn1] changes from 0 to 1.

If [EnIn1] changes from 0 to 1.

If [EnIn1] = 1 and [ValIn1] changes.

If [EnIn1] = 1 and [ValIn1] changes.

If [EnIn1] = 1 and [RptcIn1] = 1.

If [EnIn1] = 1 and [RptcIn1] = 1.

Release

If [EnIn1] changes from 1 to 0.

If [EnIn1] changes from 1 to 0.

If [EnIn1] = 0 and [RptcIn1] = 1.

If [EnIn1] = 0 and [RptcIn1] = 1.

Behavior in the event of commanding from another source

[EnIn1] = 0
Priority is not released by the function block.

[EnIn1] = 0
Priority is not released by the function block.

[EnIn1] = 1
Priority is not commanded by the function block.

[EnIn1] = 1
Priority is not commanded by the function block.

The data point periodically saves the value of priority 8 to controller memory. After a power outage, the value is restored in the property 'Priority array' and evaluated by the data point. All other priorities are not saved to controller memory.

Operation with other input sets of function block ([EnIn2]...[EnIn4], [ValIn2]...[ValIn4], [RptcIn2]...[RptcIn4]) is the same.

Pins

Input

Description

Data type

Default value
Value range

EnIn1EnIn4

Enable input 1Enable input 4

[EnIn1] determines whether [ValIn1] is commanded at the priority from [PrioIn1] or the priority is released.
[EnIn1] belongs to one of four input sets, each including [ValInX], [EnInX], [PrioInX] and [RptcInX]. These input sets are used to command the data point(s) at different priorities as needed.
[EnIn1] can be configured by the developer or linked to the chart and calculated by the control program during runtime.
The functionality of [EnIn2]…[EnIn4] is the same as [EnIn1].

Boolean

0

0 - Priority of [PrioIn1] is released if not active at the moment by setting another [EnInX] to 1.
1 - The priority for [PrioIn1] is commanded.

ValIn1ValIn4

Value input 1Value input 4

The value for commanding at [PrioIn1].
[ValIn1] can be configured by the developer or linked to the chart and calculated by the control program during runtime.
[ValIn1] is commanded at the priority from [PrioIn1] in the following cases:

  • If [EnIn1] is 1 is and [ValIn1] changes by a value, that is greater than or equal to [TshVal].
  • If [EnIn1] is 1 and [ValIn1] includes a limit value such as 0.0 or 100.0 ([TshVal] is ignored).

The functionality from [Valid2]...[Valid4] is the same as [VaIln1].

Real

0.0

PrioIn1PrioIn4

Priority input 1Priority input 4

Integer

17

[PrioIn1] belongs to one of 4 input sets and receives the priority that accompanies [ValIn1].
[PrioIn1] can be configured and cannot be changed during runtime. Value 17 means that the input is not used.
The functionality from [PrioIn2]...[PrioIn4] is the same as for [PrioIn1].

Priority range:
1...16 (see limitations to priorities 6 and 8 later).

Exclusive control:
Priorities 1...5, 9...12, and 14...16

During control program startup, the function block can use exclusive control to initialize the assigned priorities in ranges 1...5, 9...12 and 14...16.

This function block does not support exclusive priority control during runtime. The last valid command controls or releases priority.

Due to exclusive control during startup, two or more input sets on the same function block cannot have a common, exclusive control priority, as this will result in conflicts.

  • Last wins:
    Priorities 7, 8, and 13
  • No initialization of priorities during startup.
  • During runtime, the last valid command controls priority.
  • If 2 or more input sets have the same priority and are commanded concurrently, only the input set with the first numeric order is performed (In1...In4).
  • If 2 or more input sets have the same priority and the same conditions for commanding and releasing are issued concurrently, the command process wins.

Prio 6:
Each BACnet object reserves command priority 6 for min. on/off time functionality. Commands at priority 6 are rejected by the BACnet object.
For min. on/off time functions, the control program must contain a logic and use another priority.

Prio 8:
Command priority 8 is planned for manual operation and is typically unassigned on the function block. Last wins functionality allows the control program to change or enable an operator command.

RptcIn1RptcIn4

Repeat command input 1Repeat command input 4

[RptcIn1] repeats a command or releases a priority.
If [RptcIn1] = 1 and [EnIn1] = 1, the function block repeats a command from [ValIn1] in each programming cycle with the priority from [PrioIn1].
If [RptcIn1] = 1 and [EnIn1] = 0, the function block forces a release of the priority from [PrioIn1] on each programming cycle.
The functionality from [RptcIn2]...[RptcIn4] is the same as for [RptcIn1].
Note
[RptcIn1] may not be permanently forced to 1. This may impact performance or network traffic.
[RptcIn1] can be linked and typically is calculated and set by the control program.

Boolean

0

DscdcIn1DscdcIn4

Discard command input 1Discard command input 4

[DscdcIn1] is used to configure repeat command [ValIn1] on restart or when restoring communications to the automation station of the group member.
[DscdcIn1] can be configured, but cannot be changed during runtime.

Boolean

0

0 - The group manager repeats the last command from [ValIn1] at priority [PrioIn1] during a restart or once communication is restored to the automation station of the group member.
1 - The group manager does not repeat the last command from [ValIn1] at priority [PrioIn1] during a restart or once communication is restored to the automation station of the group member.

[DscdcIn2]...[DscdcIn4] functionality is the same as [DscdcIn1].

TshVal

Threshold value

Configured value to control function block write attempts. An attempt is only permitted if the change of value is greater than or equal to [TshVal].
Exception: [TshVal] is ignored if the new value is a limit value such as 0.0 or 100.0.

Note
Cannot be set to 0.0.

Real

0.1

WIvlMin

Minimum write interval

Minimum interval without writing on the BACnet object based on a change to [ValIn1]...[ValIn4] (limit values are not affected).
Minimum: 0s
Maximum: 1h
Note
[WIvlMin] does not influence the functionality of [EnIn1]...[EnIn4] and [Rptcln1]...[Rptcln4].

Time

0 ms

GrpTag

Grouping tag

Specifies the group data (present value, priority) for central distribution by the function block.
The system provides predefined and customizable tags. Typically, the application engineer sets [GrpTag] in the programming editor and it cannot be changed during runtime. A tag that matches the data type of the function block must be set.

Double Word

0

BaObjRef

BA-Object reference
Link between function block and BACnet object.

Structure

---

BaObjRef
> DeviceID

Device identifier
[DeviceID] includes object type and object instance in one ID.
Identifies the device object: local or remote. A local device object can also be identified by value 16#3FFFFF.

Double Word

16#3FFFFF

BaObjRef
> ObjectID

Object identifier
[ObjectID] includes object type and object instance in one ID.
Identifies the object on a device.

Double Word

16#3FFFFF

BaObjRef
> ItemID

Item identifier
[ItemID] represents an index in a view node object that references the BACnet object.
[ObjectID] and [ItemID] together define an indirect reference to the BACnet object.
Value -1 indicates a direct interface.

Integer

-1

 

Output

Description

Data type

Default value
Value range

Dstb

Disturbed

[Dstb] indicates whether the referenced BACnet object was accessed.
[Dstb] = 0, if:
BACnet object access = Access successful
[Dstb] = 1, if:
BACnet object access = Error during access

Boolean

0

ErrCode

Error code indication

Integer

0: No error

= 0 - No error
> 0 - XFB error codes