BACnet.Protocol.Services.UnconfirmedTextMessage (bacstack v0.1.0-dev.1)

Copy Markdown View Source

This module represents the BACnet Unconfirmed Text Message service.

The Unconfirmed Text Message service is used to send a text message to one or more devices. What devices do with the text message is a local matter of the recipient.

Service Description (ASHRAE 135)

The UnconfirmedTextMessage service is used by a client BACnet-user to send a text message to one or more BACnet devices. This service may be broadcast, multicast, or addressed to a single recipient. This service may be used in cases where confirmation that the text message was received is not required. Messages may be prioritized into normal or urgent categories. In addition, a given text message may optionally be classified by a numeric class code or class identification string. This classification may be used by receiving BACnet devices to determine how to handle the text message. For example, the message class might indicate a particular output device on which to print text or a set of actions to take when the text message is received. In any case, the interpretation of the class is a local matter.

Service Procedure (ASHRAE 135)

Since this is an unconfirmed service, no response primitives are expected. Actions taken in response to this service request are a local matter. However, typically the receiving device(s) would take the text block specified by the 'Message' parameter and display or print or file them according to the classification specified by the 'Message Class' parameter. If the 'Message Class' parameter is omitted, then some general class might be assumed. If 'Message Priority' is URGENT, then clearly the messages should be considered as more important than existing NORMAL messages, which may be awaiting printing or some other action.

Summary

Types

t()

Parameters for the Unconfirmed Text Message service.

Functions

Whether the service is of type confirmed or unconfirmed.

Converts the given Unconfirmed Service Request into an Unconfirmed Text Message Service.

Get the service name atom.

Get the Unconfirmed Service request for the given Unconfirmed Text Message Service.

Types

t()

@type t() :: %BACnet.Protocol.Services.UnconfirmedTextMessage{
  class: non_neg_integer() | String.t() | nil,
  message: String.t(),
  priority: :normal | :urgent,
  source_device: BACnet.Protocol.ObjectIdentifier.t()
}

Parameters for the Unconfirmed Text Message service.

Same structure as ConfirmedTextMessage but delivered without acknowledgment. Suitable for informational or logging messages where delivery confirmation is not required.

Functions

confirmed?()

@spec confirmed?() :: false

Whether the service is of type confirmed or unconfirmed.

from_apdu(request)

@spec from_apdu(BACnet.Protocol.APDU.UnconfirmedServiceRequest.t()) ::
  {:ok, t()} | {:error, term()}

Converts the given Unconfirmed Service Request into an Unconfirmed Text Message Service.

get_name()

@spec get_name() :: atom()

Get the service name atom.

to_apdu(service, request_data)

@spec to_apdu(t(), Keyword.t()) ::
  {:ok, BACnet.Protocol.APDU.UnconfirmedServiceRequest.t()} | {:error, term()}

Get the Unconfirmed Service request for the given Unconfirmed Text Message Service.

See the BACnet.Protocol.Services.Protocol function documentation for more information.