Sub GHz Client#

API and Callbacks for the Sub GHz Cluster Client Component.

The Smart Energy Sub-GHz client suspends the transmission of any ZCL messages for a given period when instructed so by the Sub-GHz server.

Modules#

Sub GHz Client

API#

EmberStatus

Send the 'Get Suspend ZCL Messages Status' command.

EmberStatus
emberAfPluginSubGhzClientSendUnsolicitedEnhancedUpdateNotify(EmberNodeId destination, uint8_t channelPage, uint8_t channel, uint16_t macTxUcastTotal, uint16_t macTxUcastFailures, uint16_t macTxUcastRetries, uint8_t period)

Send a request to change the channel to the server by Mgmt_NWK_Unsolicited_Enhanced_Update_notify command.

bool

Return the current suspend status.

void

Ignore the SuspendZclMessages command.

API Documentation#

emberAfPluginSubGhzClientSendGetSuspendZclMessagesStatusCommand#

EmberStatus emberAfPluginSubGhzClientSendGetSuspendZclMessagesStatusCommand (EmberNodeId nodeId, uint8_t endpoint)

Send the 'Get Suspend ZCL Messages Status' command.

Parameters
N/AnodeId

The server's node ID.

N/Aendpoint

The server's endpoint.

This is a client command. The client sends it to determine the current status of its ZCL communications from the server.


Definition at line 48 of file app/framework/plugin/sub-ghz-client/sub-ghz-client.h

emberAfPluginSubGhzClientSendUnsolicitedEnhancedUpdateNotify#

EmberStatus emberAfPluginSubGhzClientSendUnsolicitedEnhancedUpdateNotify (EmberNodeId destination, uint8_t channelPage, uint8_t channel, uint16_t macTxUcastTotal, uint16_t macTxUcastFailures, uint16_t macTxUcastRetries, uint8_t period)

Send a request to change the channel to the server by Mgmt_NWK_Unsolicited_Enhanced_Update_notify command.

Parameters
N/Adestination

........ the Sub-GHz server's node ID

N/AchannelPage

........ current channel page

N/Achannel

............ current channel

  • the application needs to keep track of these values

N/AmacTxUcastTotal

.... total number of Mac TX transaction attempts

N/AmacTxUcastFailures

. total number of Mac TX transaction failures

N/AmacTxUcastRetries

.. total number of Mac TX transaction retries

N/Aperiod

............. time in minutes over which macTxUcastXxx were measured

Returns

  • An ::EmberStatus value.

    • ::EMBER_SUCCESS

    • ::EMBER_BAD_ARGUMENT if the channel page or channel are not in the valid range

    • ::EMBER_NO_BUFFERS

    • ::EMBER_NETWORK_DOWN

    • ::EMBER_NETWORK_BUSY


Definition at line 70 of file app/framework/plugin/sub-ghz-client/sub-ghz-client.h

emberAfPluginSubGhzClientIsSendingZclMessagesSuspended#

bool emberAfPluginSubGhzClientIsSendingZclMessagesSuspended ()

Return the current suspend status.

Returns

  • True if called within a suspend period, false otherwise.


Definition at line 82 of file app/framework/plugin/sub-ghz-client/sub-ghz-client.h

emberAfPluginSubGhzClientIgnoreSuspendZclMessagesCommand#

void emberAfPluginSubGhzClientIgnoreSuspendZclMessagesCommand (bool ignore)

Ignore the SuspendZclMessages command.

Parameters
N/Aignore

True to ignore, false to switch back to normal behavior.

When the client receives the SuspendZclMessages command, it suspends sending any ZCL messages for a given time. This function allows the client to ignore the command and continue sending messages even when suspended.

NOTE: For testing only. Ignoring the SuspendZclMessages command in production is non-compliant.


Definition at line 95 of file app/framework/plugin/sub-ghz-client/sub-ghz-client.h