Z-Wave Protocol Controller Reference

Utility that deliver frames to Association Group destinations. More...

Collaboration diagram for Association Group transport:

Typedefs

typedef void(* on_group_send_complete_t) (sl_status_t status, void *user)
 Callback function for zwave_association_send_to_group, indicating the result of the operation. More...
 

Functions

sl_status_t zwave_association_send_to_group (association_group_id_t group_id, uint16_t frame_size, const uint8_t *frame, bool supporting, const zwave_tx_options_t *tx_options, zwave_node_id_t excluded_node, on_group_send_complete_t callback, void *user)
 Sends a command to an Association Group. More...
 

Detailed Description

Utility that deliver frames to Association Group destinations.

This module provides an API to send frames to Association Group destinations Destinations can both be NodeID or Endpoint Associations (see Multi Channel Association Command Class and Internal helpers for for details.)

Frames command classes and commands will be verified against what is registered on each group using zwave_command_class_agi_add_group_commands()

Typedef Documentation

◆ on_group_send_complete_t

typedef void(* on_group_send_complete_t) (sl_status_t status, void *user)

Callback function for zwave_association_send_to_group, indicating the result of the operation.

This function is called when all queued elements in the TX Queue have been transmitted (or attempted to be transmitted) and indicates the status of the operation.

Parameters
statusIndicates how the transmission operation was completed. SL_STATUS_OK for all transmissions were successful SL_STATUS_FAIL if 1 or more transmissions failed
userUser pointer provided in zwave_association_send_to_group()

Function Documentation

◆ zwave_association_send_to_group()

sl_status_t zwave_association_send_to_group ( association_group_id_t  group_id,
uint16_t  frame_size,
const uint8_t *  frame,
bool  supporting,
const zwave_tx_options_t tx_options,
zwave_node_id_t  excluded_node,
on_group_send_complete_t  callback,
void *  user 
)

Sends a command to an Association Group.

Parameters
group_idAssociation Group to which the
framePointer to the frame data. The Command Class and Command sent to a group MUST have been registered with zwave_command_class_agi_add_group_commands
frame_sizeSize of the payload carried by the Frame pointer.
supportingSet to true if the frame we send is supported (i.e sent at our highest security level). False for a controlling frame.
tx_optionsPointer to zwave_tx_options for the transmission.
excluded_nodeNodeID to exclude from the group (e.g. if lifeline true status is to be reported to everyone but the NodeID that triggered the change.) Set to 0 for no exclusion.
callbackCallback to invoke when all transmissions for all destinations are completed/failed.
userUser pointer for the callback.

Note that no abort function is provided. Set the discard timeout to a low value in the tx_options if you do not want a transmission to take too long.

Returns
SL_STATUS_OK if the frame(s) were queued and callback will be called when all transmissions are done. SL_STATUS_NOT_FOUND if the association group is empty or no transmission is to be done SL_STATUS_FAIL in case of error.