Skip to content
Version 6.1.0
Contact Us

BACnetStack_AddNotificationClassObject

bool BACnetStack_AddNotificationClassObject(
const uint32_t deviceInstance,
const uint32_t objectInstance,
const uint8_t toOffNormalPriority,
const uint8_t toFaultPriority,
const uint8_t toNormalPriority,
const bool toOffNormalAckRequired,
const bool toFaultAckRequired,
const bool toNormalAckRequired);

Adds a Notification Class Object.

The device must be added first before this function can be called.

The Notification Class properties that are handled and stored by the CAS BACnet Stack are:

This is the one object type for which the application serves almost nothing. Callbacks are used only for:

--------------------------------------------------------------------------------
Property Datatype Callback
--------------------------------------------------------------------------------
ObjectName CharacterString CallbackGetPropertyCharacterString
Description* CharacterString CallbackGetPropertyCharacterString
(*) Optional; enable it with BACnetStack_SetPropertyEnabled first.
--------------------------------------------------------------------------------

A Notification Class object created with BACnetStack_AddObject() INSTEAD of this function is not usable: every property read other than ObjectIdentifier, ObjectType, PropertyList and StatusFlags returns Error(OBJECT, UNKNOWN_OBJECT), because no stack-side Notification Class exists behind it.

See also: BACnetStack_ObjectExists(), BACnetStack_RemoveObject()

BACnet reference: ANSI/ASHRAE 135-2024 clause 12.21 (Notification Class Object Type).

Parameter Direction Description
deviceInstance in The instance number of the device that owns this Notification Class Object.
objectInstance in The instance number of this Notification Class Object.
toOffNormalPriority in The priority for To_OffNormal events. Values are 0-255. It is element 1 of the Priority property, a BACnetARRAY[3] of Unsigned (cl. 12.21).
toFaultPriority in The priority for To_Fault events. Values are 0-255. It is element 2 of the Priority property.
toNormalPriority in The priority for To_Normal events. Values are 0-255. It is element 3 of the Priority property.
toOffNormalAckRequired in Whether the To_OffNormal events must be acknowledged (true) or not (false); it is the to-offnormal bit of Ack_Required, a BACnetEventTransitionBits BIT STRING (cl. 21).
toFaultAckRequired in Whether the To_Fault events must be acknowledged (true) or not (false); it is the to-fault bit of Ack_Required.
toNormalAckRequired in Whether the To_Normal events must be acknowledged (true) or not (false); it is the to-normal bit of Ack_Required.

True on success; false if the device does not exist, the object could not be added, or Notification Class support was not compiled.

Topic: Alarms and events. Declared in CASBACnetStackDLL.h.