BACnet. Protocol. Services. ConfirmedEventNotification
(bacstack v0.1.0-dev.1)
Copy Markdown
View Source
This module represents the BACnet Confirmed Event Notification service.
The Confirmed Event Notification service is used to notify a subscriber of an event that has occurred and requires an acknowledge by the subscriber of reception of this event notification.
Service Description (ASHRAE 135)
The ConfirmedEventNotification service is used by a notification-server to notify a remote device that an event has occurred and that the notification-server needs a confirmation that the notification has been received. This confirmation means only that the device received the message. It does not imply that a human operator has been notified. A separate AcknowledgeAlarm service is used to indicate that an operator has acknowledged the receipt of the notification if the notification specifies that acknowledgment is required. If multiple recipients must be notified, a separate invocation of this service shall be used to notify each intended recipient. If a confirmation that a notification was received is not needed, then the UnconfirmedEventNotification may be used.
Service Procedure (ASHRAE 135)
After verifying the validity of the request, the responding BACnet-user shall take whatever local actions have been assigned to the indicated event occurrence and issue a 'Result(+)' service primitive. If the service request cannot be executed, a 'Result(-)' service primitive shall be issued indicating the encountered error. A device shall not fail to process, or issue a Result(-), upon receiving a ConfirmedEventNotification service request containing a 'Message Text' parameter in an unsupported character set.
Result(-) Errors (ASHRAE 135)
The 'Result(-)' parameter shall indicate that the service request has failed. The reason for failure shall be specified by the 'Error Type' parameter.
The 'Error Class' and 'Error Code' are per Clause 18 (no service-specific situations are defined beyond the general cases).
Summary
Functions
Whether the service is of type confirmed or unconfirmed.
Converts the given Confirmed Service Request into a Confirmed Event Notification Service.
Get the service name atom.
Get the Confirmed Service request for the given Confirmed Event Notification Service.
Types
@type t() :: %BACnet.Protocol.Services.ConfirmedEventNotification{ ack_required: boolean() | nil, event_object: BACnet.Protocol.ObjectIdentifier.t(), event_type: BACnet.Protocol.Constants.event_type(), event_values: BACnet.Protocol.NotificationParameters.notification_parameter() | nil, from_state: BACnet.Protocol.Constants.event_state() | nil, initiating_device: BACnet.Protocol.ObjectIdentifier.t(), message_text: String.t() | nil, notification_class: non_neg_integer(), notify_type: BACnet.Protocol.Constants.notify_type(), priority: BACnet.Protocol.ApplicationTags.unsigned8(), process_identifier: BACnet.Protocol.ApplicationTags.unsigned32(), timestamp: BACnet.Protocol.BACnetTimestamp.t(), to_state: BACnet.Protocol.Constants.event_state() | nil }
Parameters for the Confirmed Event Notification service.
Notifies recipients that an event (alarm, change-of-state, etc.) has occurred. Includes priority, type, notify type, optional ack requirement, state transition info, and notification-specific parameters.
The fields ack_required, froM_state and to_state are nil,
if notify_type is :ack_notification.
Functions
@spec confirmed?() :: true
Whether the service is of type confirmed or unconfirmed.
@spec from_apdu(BACnet.Protocol.APDU.ConfirmedServiceRequest.t()) :: {:ok, t()} | {:error, term()}
Converts the given Confirmed Service Request into a Confirmed Event Notification Service.
@spec get_name() :: atom()
Get the service name atom.
@spec to_apdu(t(), Keyword.t()) :: {:ok, BACnet.Protocol.APDU.ConfirmedServiceRequest.t()} | {:error, term()}
Get the Confirmed Service request for the given Confirmed Event Notification Service.
See the BACnet.Protocol.Services.Protocol function documentation for more information.