Skip to content
Version 6.1.0
Contact Us

BACnetStack_AddGroupMember

bool BACnetStack_AddGroupMember(
const uint32_t deviceInstance,
const uint32_t groupObjectInstance,
const uint16_t memberObjectType,
const uint32_t memberObjectInstance,
const uint32_t propertyIdentifier,
const bool useArrayIndex,
const uint32_t arrayIndex);

Appends a property reference to a member of a Group object’s List_Of_Group_Members, adding the member if it is not there yet.

Appends one property reference to a member (a member object identifier plus a property reference) of a Group object’s stack-held List_Of_Group_Members, per 135-2024 cl. 12.14.5 (each member is an object identifier with its list of property references). In BACnet terms each member is a ReadAccessSpecification and List_Of_Group_Members is a BACnetLIST of them; each call adds one BACnetPropertyReference (property identifier plus optional array index) to a member (cl. 12.14, cl. 21).

Calling this again for a (memberObjectType, memberObjectInstance) pair already in the list APPENDS propertyIdentifier to that EXISTING member instead of creating a duplicate member - so to build the cl. 12.14.5 worked example (a member reading Present_Value and Reliability), call this twice with the same member identifier and a different propertyIdentifier each time.

BACnet reference: ANSI/ASHRAE 135-2024 clause 12.14 (Group Object Type).

Parameter Direction Description
deviceInstance in The device instance that owns this Group object.
groupObjectInstance in The Group object to add the member to.
memberObjectType in The member object type. See CASBACnetStack::BACnetObjectType. With memberObjectInstance, this is one BACnet Object Identifier carried as two parameters.
memberObjectInstance in The member object instance.
propertyIdentifier in The property to reference. See BACnetPropertyIdentifier. The special ALL (8), REQUIRED (105) and OPTIONAL (80) identifiers (cl. 12.14.5) are accepted and stored like any other identifier, except that a reference to the Present_Value, ALL or REQUIRED of a Group or Global Group member is refused: a group may not nest a group (cl. 12.14.5).
useArrayIndex, arrayIndex in If useArrayIndex is true, the reference targets one array element (1-based) of propertyIdentifier rather than the whole property.

True on success; false if the device does not exist, Group support is not compiled, or the reference would nest a Group or Global Group (see propertyIdentifier).

Topic: Schedules, calendars, trend logs and other object configuration. Declared in CASBACnetStackDLL.h.