Zigbee Cluster Library Overview 2

1. Identify

#include "zcl/general/zcl.identify.h"

Functions

ZbZclIdentifyClientAlloc

struct ZbZclClusterT * ZbZclIdentifyClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Identify Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclIdentifyServerAlloc

struct ZbZclClusterT * ZbZclIdentifyServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, const struct zcl_identify_server_callbacks_t *callbacks, void *arg);

Create a new instance of the Identify Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclIdentifyServerGetTime

uint16_t ZbZclIdentifyServerGetTime(struct ZbZclClusterT *cluster);

Get the local Identify Server time

Parameters

Return

  • uint16_t Time remaining in zigbee timer

ZbZclIdentifyServerSetTime

void ZbZclIdentifyServerSetTime(struct ZbZclClusterT *cluster, uint16_t seconds);

Set the local Identify Server time

If BDB_COMMISSION_MODE_FIND_BIND is enabled and seconds > 0, seconds is adjusted to be >= ZB_BDBC_MinCommissioningTime

Parameters

Return

  • Void

zcl_identify_cli_identify_req

enum ZclStatusCodeT zcl_identify_cli_identify_req(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
uint16_t identify_time, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send an Identify command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_identify_cli_query_req

enum ZclStatusCodeT zcl_identify_cli_query_req(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send an Identify Query command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclIdentifySvrAttrT

Identify Server Attribute IDs

2. Illuminance Level Sensing

#include "zcl/general/zcl.illum.level.h"

Functions

ZbZclIllumLevelClientAlloc

struct ZbZclClusterT * ZbZclIllumLevelClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Illuminance Level Sensing Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclIllumLevelServerAlloc

struct ZbZclClusterT * ZbZclIllumLevelServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Illuminance Level Sensing Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclIllumLevelSvrAttrT

Attribute Identifiers

3. Illuminance Measurement

#include "zcl/general/zcl.illum.meas.h"

Functions

ZbZclIllumMeasClientAlloc

struct ZbZclClusterT * ZbZclIllumMeasClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Illuminance Measurement Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclIllumMeasServerAlloc

struct ZbZclClusterT * ZbZclIllumMeasServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, uint16_t min, uint16_t max);

Create a new instance of the Illuminance Measurement Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclIllumMeasSvrAttrT

Illuminance Measurement Server Attribute IDs

4. Level

#include "zcl/general/zcl.level.h"

Functions

ZbZclLevelClientAlloc

struct ZbZclClusterT * ZbZclLevelClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Level Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclLevelClientMoveReq

enum ZclStatusCodeT ZbZclLevelClientMoveReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclLevelClientMoveReqT *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Move command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclLevelClientMoveToFreqReq

enum ZclStatusCodeT ZbZclLevelClientMoveToFreqReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclLevelClientMoveToFreqT *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Move to Frequency command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclLevelClientMoveToLevelReq

enum ZclStatusCodeT ZbZclLevelClientMoveToLevelReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclLevelClientMoveToLevelReqT *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Move to Level command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclLevelClientStepReq

enum ZclStatusCodeT ZbZclLevelClientStepReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclLevelClientStepReqT *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Step command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclLevelClientStopReq

enum ZclStatusCodeT ZbZclLevelClientStopReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclLevelClientStopReqT *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Stop command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclLevelServerAlloc

struct ZbZclClusterT * ZbZclLevelServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, struct ZbZclClusterT *onoff_server,
struct ZbZclLevelServerCallbacksT *callbacks, void *arg);

Create a new instance of the Level Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclLevelSvrAttrT

Level Server Attribute IDs

Structures

ZbZclLevelClientMoveReqT

Move command structure

Parameters

ZbZclLevelClientMoveToFreqT

Move to Closest Frequency command structure

Parameters

ZbZclLevelClientMoveToLevelReqT

Move To Level command structure

Parameters

ZbZclLevelClientStepReqT

Step command structure

Parameters

ZbZclLevelClientStopReqT

Stop command structure

Parameters

ZbZclLevelServerCallbacksT

Level Server callbacks configuration

Parameters

5. Meter Identification

#include "zcl/general/zcl.meter.id.h"

Functions

ZbZclMeterIdClientAlloc

struct ZbZclClusterT * ZbZclMeterIdClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Meter Identification Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclMeterIdServerAlloc

struct ZbZclClusterT * ZbZclMeterIdServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Meter Identification Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclMeterIdSvrAttrT

Attribute Identifiers

6. Nearest Gateway

#include "zcl/general/zcl.nearest.gw.h"

Functions

ZbZclNearestGwClientAlloc

struct ZbZclClusterT * ZbZclNearestGwClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Nearest Gateway client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclNearestGwServerAlloc

struct ZbZclClusterT * ZbZclNearestGwServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Nearest Gateway server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclNearestGwServerAttrT

Nearest Gateway Attribute Ids

7. Occupancy Sensing

#include "zcl/general/zcl.occupancy.h"

Functions

ZbZclOccupancyClientAlloc

struct ZbZclClusterT * ZbZclOccupancyClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Occupancy Sensing Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOccupancyServerAlloc

struct ZbZclClusterT * ZbZclOccupancyServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Occupancy Sensing Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclOccupancySvrAttrT

Occupancy Sensing Server Attribute IDs

8. On/Off Switch Configuration

#include "zcl/general/zcl.onoff.swconfig.h"

Functions

ZbZclOnOffSwConfigClientAlloc

struct ZbZclClusterT * ZbZclOnOffSwConfigClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the OnOff Switch Configuration Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOnOffSwConfigServerAlloc

struct ZbZclClusterT * ZbZclOnOffSwConfigServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, uint8_t switch_type);

Create a new instance of the OnOff Switch Configuration Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclOnOffSwConfigSvrAttrId

Onoff Switch Configuration cluster attribute IDs

9. On/Off

#include "zcl/general/zcl.onoff.h"

Functions

ZbZclOnOffClientAlloc

struct ZbZclClusterT * ZbZclOnOffClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the OnOff Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOnOffClientOffReq

enum ZclStatusCodeT ZbZclOnOffClientOffReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send an Off command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOnOffClientOnReq

enum ZclStatusCodeT ZbZclOnOffClientOnReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send an On command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOnOffClientToggleReq

enum ZclStatusCodeT ZbZclOnOffClientToggleReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Toggle command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOnOffServerAlloc

struct ZbZclClusterT * ZbZclOnOffServerAlloc(struct ZigBeeT *zb, uint8_t endpoint,
struct ZbZclOnOffServerCallbacksT *callbacks, void *arg);

Create a new instance of the OnOff Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOnOffServerSetLevelControlCallback

void ZbZclOnOffServerSetLevelControlCallback(struct ZbZclClusterT *on_off_cluster, struct ZbZclClusterT
*level_cluster, ZbZclLevelControlCallbackT levelControlCallback);

Set the Level control callback

Parameters

Return

  • Void

Enumerations

ZbZclOnOffSvrAttrT

OnOff Server Attribute IDs

Structures

ZbZclOnOffServerCallbacksT

OnOff Server callbacks configuration

Parameters

10. Over-The-Air Upgrade

#include "zcl/general/zcl.ota.h"

Functions

ZbZclOtaClientAlloc

struct ZbZclClusterT * ZbZclOtaClientAlloc(struct ZigBeeT *zb, struct ZbZclOtaClientConfig *config, void *arg);

Create a new instance of the OTA Upgrade Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOtaClientDiscover

enum ZclStatusCodeT ZbZclOtaClientDiscover(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *addr);

Discover OTA Upgrade Server

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOtaClientDiscoverForced

void ZbZclOtaClientDiscoverForced(struct ZbZclClusterT *cluster, uint64_t ieee, uint8_t endpoint);

Set the OTA Upgrade Server directly (without discovery)

Parameters

Return

  • None

ZbZclOtaClientGetDefaultCallbacks

void ZbZclOtaClientGetDefaultCallbacks(struct ZbZclOtaClientCallbacksT *callbacks);

Load the default callbacks for ECDSA Suite 2 support

Parameters

Return

  • None

ZbZclOtaClientImageTransferResume

enum ZclStatusCodeT ZbZclOtaClientImageTransferResume(struct ZbZclClusterT *cluster);

Resume an OTA Upgrade transfer. ZbZclOtaClientImageTransferResume is called if the NHLE (app) returned ZCL_STATUS_WAIT_FOR_DATA for the write_image callback. The OTA Client won’t request the next block of data in this case, until this function is called.

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOtaClientImageTransferStart

enum ZclStatusCodeT ZbZclOtaClientImageTransferStart(struct ZbZclClusterT *cluster);

Initiate an OTA Upgrade transfer.

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOtaClientQueryNextImageReq

enum ZclStatusCodeT ZbZclOtaClientQueryNextImageReq(struct ZbZclClusterT *cluster, struct ZbZclOtaImageDefinition
*image_definition, uint8_t field_control, uint16_t hardware_version);

Send a Query Next Image Request command. If a response is received, or an error occurs, the 'query_next' callback is invoked to the application.

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error.

ZbZclOtaHeaderParse

uint8_t ZbZclOtaHeaderParse(const uint8_t *payload, const uint8_t length, struct ZbZclOtaHeader *header);

Parse an OTA Upgrade payload buffer’s header information

Parameters

Return

  • Number of bytes parsed

ZbZclOtaServerAlloc

struct ZbZclClusterT * ZbZclOtaServerAlloc(struct ZigBeeT *zb, struct ZbZclOtaServerConfig
  • config, void *arg);

Create a new instance of the OTA Upgrade Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclOtaServerImageNotifyReq

enum ZclStatusCodeT ZbZclOtaServerImageNotifyReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
uint8_t payload_type, uint8_t jitter, struct ZbZclOtaImageDefinition *image_definition);

Send an OTA Image Notify Server command Registering an image does not automatically send an Image Notify message, the OTA Server application can use ZbZclOtaServerImageNotifyReq after registering an image to notify clients of the availability of a new image

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclOtaServerUpgradeEndRespUnsolic

enum ZclStatusCodeT ZbZclOtaServerUpgradeEndRespUnsolic(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclOtaImageDefinition *image_definition, struct ZbZclOtaEndResponseTimes *end_response_times);

Send an Unsolicited OTA Upgrade End Response. This command is sent at some point in time after receiving the Upgrade End Request, which was already responsed to by a Default Response. This should be the normal way to handle the Upgrade End commands, rather than the Solicated Upgrade End Response (ZbZclOtaServerUpgradeEndRespSolic).

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclOtaActivationPolicy

OTA Upgrade UpgradeActivationPolicy enumerations

ZbZclOtaHeaderFieldCtrlBitmask

OTA Upgrade Header Field Control Bitmask enumerations

ZbZclOtaImageBlkReqFldCtrl

OTA Upgrade Image Block Request Field Control Bitmask enumerations

ZbZclOtaImageNotifyCmd

OTA Upgrade Image Notify Command Payload enumerations

ZbZclOtaImageType

OTA Upgrade Image Types enumerations

ZbZclOtaQueryFldCtrlHwVer

OTA Upgrade Field Control Hardware Version enumerations

ZbZclOtaSecCredential

OTA Upgrade Security Credential Version enumerations

ZbZclOtaStackVersion

OTA Upgrade Zigbee Stack Version Values

ZbZclOtaStatus

OTA Upgrade Status Attribute Values (ImageUpgradeStatus)

ZbZclOtaSubElementTag

OTA Upgrade Tag Identifiers enumerations

ZbZclOtaSvrAttrId

OTA Upgrade Server Attribute IDs

ZbZclOtaTimeoutPolicy

OTA Upgrade UpgradeTimeoutPolicy enumerations

Structures

ZbZclOtaClientCallbacksT

OTA Upgrade callbacks configuration

Parameters

ZbZclOtaClientConfig

OTA Upgrade Client Configuration structure

Parameters

ZbZclOtaEndResponseTimes

Upgrade End Response command structure

Parameters

ZbZclOtaHeader

OTA Upgrade Header Fields structure

Parameters

ZbZclOtaImageData

OTA Upgrade Image Data structure

Parameters

ZbZclOtaImageDefinition

OTA Header Image Definition structure

Parameters

ZbZclOtaImageWaitForData

Image Block Response Command Payload with WAIT_FOR_DATA status structure

Parameters

ZbZclOtaServerConfig

OTA Upgrade Server Configuration structure

Parameters

11. Poll Control

#include "zcl/general/zcl.poll.control.h"

Description

ZCL 8 section 3.16

A Sleepy End Device (SED) may instantiate the Poll Control server to allow external devices to control its polling behaviour, including a short interval of rapid polling in order to communicate with the SED in a timely fashion. SEDs are usually in their sleep state where they are not able to receive packets, and devices may not know when those SEDs are awake and polling for data. The Poll Control cluster is used to solve this dilemma.

Devices with Poll Control clients can use Finding & Binding to create the bindings necessary to communicate with the Poll Control servers. The Poll Control server will perform periodic check-ins with any bound Poll Control clients, where the check-in response may ask the SED to start fast polling to allow the server device to exchange messages with it.


Functions

zcl_poll_client_alloc

struct ZbZclClusterT * zcl_poll_client_alloc(struct ZigBeeT *zb, uint8_t endpoint, struct ZbZclPollControlClientCallbackT *callbacks, void *arg);

Create a new instance of the Poll Control Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

zcl_poll_client_set_checkin_rsp

enum ZclStatusCodeT zcl_poll_client_set_checkin_rsp(struct ZbZclClusterT *cluster, struct ZbZclPollControlClientCheckinInfo *info);

Set Check-in Response configuration

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_poll_client_set_long_intvl_req

enum ZclStatusCodeT zcl_poll_client_set_long_intvl_req(struct ZbZclClusterT *cluster, struct ZbZclPollControlClientSetLongReq *req,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Set Long Interval command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_poll_client_set_short_intvl_req

enum ZclStatusCodeT zcl_poll_client_set_short_intvl_req(struct ZbZclClusterT *cluster, struct ZbZclPollControlClientSetShortReq *req,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Set Short Interval command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_poll_client_stop_fastpoll_req

enum ZclStatusCodeT zcl_poll_client_stop_fastpoll_req(struct ZbZclClusterT *cluster, struct ZbZclPollControlClientStopReq *req,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Fast Poll Stop command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_poll_server_alloc

struct ZbZclClusterT * zcl_poll_server_alloc(struct ZigBeeT *zb, uint8_t endpoint, struct ZbZclPollControlServerCallbackT *callbacks, void *arg);

Create a new instance of the Poll Control Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

zcl_poll_server_send_checkin

enum ZclStatusCodeT zcl_poll_server_send_checkin(struct ZbZclClusterT *cluster);

Send a Check-in command to any bound Clients.

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclPollControlSvrAttrT

Poll Control Server Attribute IDs

Structures

ZbZclPollControlClientCallbackT

Poll Control Client callbacks configuration

Parameters

ZbZclPollControlClientCheckinInfo

Check-in Info structure

Parameters

ZbZclPollControlClientSetLongReq

Set Long Poll Interval command structure

Parameters

ZbZclPollControlClientSetShortReq

Set Short Poll Interval command structure

Parameters

ZbZclPollControlClientStopReq

Fast Poll Stop command structure

Parameters

ZbZclPollControlServerCallbackT

Poll Control Server callbacks configuration

Parameters

zcl_poll_checkin_rsp_t

Check-in Response command structure

Parameters

12. Power Configuration

#include "zcl/general/zcl.power.config.h"

Functions

ZbZclPowerConfigClientAlloc

struct ZbZclClusterT * ZbZclPowerConfigClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Power Configuration Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclPowerConfigServerAlloc

struct ZbZclClusterT * ZbZclPowerConfigServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Power Configuration Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclPowerConfigSvrAttrT

Power Configuration Server Attributes IDs

13. Power Profile

#include "zcl/general/zcl.power.profile.h"

Functions

ZbZclPowerProfClientAlloc

struct ZbZclClusterT * ZbZclPowerProfClientAlloc(struct ZigBeeT *zb, uint8_t endpoint, struct ZbZclPowerProfClientCallbacks *callbacks, void *arg);

Create a new instance of the Power Profile Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclPowerProfClientPhasesNotify

enum ZclStatusCodeT ZbZclPowerProfClientPhasesNotify(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliPhasesNotify *notify, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send an Energy Phases Schedule Notification command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientPhasesResponse

enum ZclStatusCodeT ZbZclPowerProfClientPhasesResponse(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfCliPhasesNotify *notify, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a EnergyPhasesScheduleResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientPhasesSchedStateReq

enum ZclStatusCodeT ZbZclPowerProfClientPhasesSchedStateReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliProfileReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a EnergyPhasesScheduleStateRequest command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientPriceExtRsp

enum ZclStatusCodeT ZbZclPowerProfClientPriceExtRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfCliPriceRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a GetPowerProfilePriceExtendedResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientPriceRsp

enum ZclStatusCodeT ZbZclPowerProfClientPriceRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfCliPriceRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a GetPowerProfilePriceResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientProfileReq

enum ZclStatusCodeT ZbZclPowerProfClientProfileReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliProfileReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a PowerProfileRequest command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientSchedConsReq

enum ZclStatusCodeT ZbZclPowerProfClientSchedConsReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliProfileReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a PowerProfileScheduleConstraintsRequest command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientSchedPriceRsp

enum ZclStatusCodeT ZbZclPowerProfClientSchedPriceRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfCliSchedPriceRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a GetOverallSchedulePriceResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfClientStateReq

enum ZclStatusCodeT ZbZclPowerProfClientStateReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a PowerProfileStateRequest command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerAlloc

struct ZbZclClusterT * ZbZclPowerProfServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, struct ZbZclPowerProfServerCallbacks *callbacks, void *arg);

Create a new instance of the Power Profile Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclPowerProfServerConstraintsNotify

enum ZclStatusCodeT ZbZclPowerProfServerConstraintsNotify(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfSvrConstraintsNotify *notify, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a PowerProfileScheduleConstraintsNotification Command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerConstraintsRsp

enum ZclStatusCodeT ZbZclPowerProfServerConstraintsRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfSvrConstraintsNotify *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a PowerProfileScheduleConstraintsResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerGetPriceReq

enum ZclStatusCodeT ZbZclPowerProfServerGetPriceReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliProfileReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a GetPowerProfilePrice command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerGetPriceReqExtReq

enum ZclStatusCodeT ZbZclPowerProfServerGetPriceReqExtReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfSvrGetPriceExtReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a GetPowerProfilePriceExtended command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerGetSchedPriceReq

enum ZclStatusCodeT ZbZclPowerProfServerGetSchedPriceReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a GetOverallSchedulePrice command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerPhasesNotify

enum ZclStatusCodeT ZbZclPowerProfServerPhasesNotify(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfSvrPhasesRsp *notify, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a EnergyPhasesScheduleStateNotification Command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerPhasesReq

enum ZclStatusCodeT ZbZclPowerProfServerPhasesReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfCliProfileReq *req, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a EnergyPhasesScheduleRequest command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerPhasesRsp

enum ZclStatusCodeT ZbZclPowerProfServerPhasesRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfSvrPhasesRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a EnergyPhasesScheduleStateResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerProfileNotify

enum ZclStatusCodeT ZbZclPowerProfServerProfileNotify(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfSvrProfileRsp *notify, void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a PowerProfileNotification Command. It is sent as a ZCL request with a unique sequence number, and can receive a Default Response if applicable

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerProfileRsp

enum ZclStatusCodeT ZbZclPowerProfServerProfileRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfSvrProfileRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a PowerProfileResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerStateNotify

enum ZclStatusCodeT ZbZclPowerProfServerStateNotify(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct ZbZclPowerProfSvrStateRsp *notify, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a PowerProfileStateNotification Command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclPowerProfServerStateRsp

enum ZclStatusCodeT ZbZclPowerProfServerStateRsp(struct ZbZclClusterT *cluster, struct ZbZclAddrInfoT *dst,
struct ZbZclPowerProfSvrStateRsp *rsp, void (*callback)(struct ZbApsdeDataConfT *conf, void *arg), void *arg);

Send a PowerProfileStateResponse command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclPowerProfileSvrAttrT

Power Profile Server Attribute IDs

Structures

ZbZclPowerProfCliPhasesNotify

Energy Phases Schedule Notification command structure

Parameters

ZbZclPowerProfCliPriceRsp

GetPowerProfilePriceResponse command structure

Parameters

ZbZclPowerProfCliProfileReq

PowerProfileRequest command structure

Parameters

ZbZclPowerProfCliSchedPriceRsp

GetOverallSchedulePriceResponse command structure

Parameters

ZbZclPowerProfClientCallbacks

Power Profile Client callbacks configuration

Parameters

ZbZclPowerProfPhase

Phase structure

Parameters

ZbZclPowerProfSchedPhase

Schedule Phase structure

Parameters

ZbZclPowerProfServerCallbacks

Power Profile Server callbacks configuration

Parameters

ZbZclPowerProfSvrConstraintsNotify

PowerProfileScheduleConstraintsNotification command structure

Parameters

ZbZclPowerProfSvrGetPriceExtReq

GetPowerProfilePriceExtended command structure

Parameters

ZbZclPowerProfSvrPhasesRsp

Energy Phases Schedule Notification and EnergyPhasesScheduleResponse command structure

Parameters

ZbZclPowerProfSvrProfileRsp

PowerProfileNotification and PowerProfileResponse command structure

Parameters

ZbZclPowerProfSvrStateRsp

PowerProfileStateResponse command structure

Parameters

ZbZclPowerProfileRecord

Record structure

Parameters

14. Pressure Measurement

#include "zcl/general/zcl.press.meas.h"

Functions

ZbZclPressMeasClientAlloc

struct ZbZclClusterT * ZbZclPressMeasClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Pressure Measurement Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclPressMeasServerAlloc

struct ZbZclClusterT * ZbZclPressMeasServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, int16_t min, int16_t max);

Create a new instance of the Pressure Measurement Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclPressMeasSvrAttrT

Pressure Measurement Attribute IDs

15. Pump Configuration and Control

#include "zcl/general/zcl.pump.h"

Functions

ZbZclPumpClientAlloc

struct ZbZclClusterT * ZbZclPumpClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Pump Configuration and Control client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclPumpServerAlloc

struct ZbZclClusterT * ZbZclPumpServerAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Instantiate a new instance of the Pump Configuration and Control server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclPumpServerAttrT

Pump Configuration and Control Attribute Ids

16. RSSI Location

#include "zcl/general/zcl.rssi.loc.h"

Functions

ZbZclRssiLocClientAlloc

struct ZbZclClusterT * ZbZclRssiLocClientAlloc(struct ZigBeeT *zb, uint8_t endpoint, struct zcl_rssi_loc_client_callbacks_t *callbacks, void *arg);

Create a new instance of the RSSI Location Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclRssiLocClientAnchorNodeAnnc

enum ZclStatusCodeT ZbZclRssiLocClientAnchorNodeAnnc(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_anchor_node_annc *anchor_node_annc, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Anchor Node Announce command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientGetDevConfig

enum ZclStatusCodeT ZbZclRssiLocClientGetDevConfig(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_get_dev_config *get_dev_config, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Get Device Configuration command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientGetLocData

enum ZclStatusCodeT ZbZclRssiLocClientGetLocData(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_get_loc_data *get_loc_data, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Get Location Data command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientSendPings

enum ZclStatusCodeT ZbZclRssiLocClientSendPings(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_send_pings *send_pings, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Send Pings command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientSendRssiRsp

enum ZclStatusCodeT ZbZclRssiLocClientSendRssiRsp(struct ZbZclClusterT *clusterPtr, struct ZbZclAddrInfoT *dst_info, struct rssi_loc_rssi_rsp *rsp);

Send a RSSI Response command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientSetAbsLocation

enum ZclStatusCodeT ZbZclRssiLocClientSetAbsLocation(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_set_abs_loc *set_abs_loc, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Set Absolute Location command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocClientSetDevConfig

enum ZclStatusCodeT ZbZclRssiLocClientSetDevConfig(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_set_dev_config *set_dev_config, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Set Device Configuration command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerAlloc

struct ZbZclClusterT * ZbZclRssiLocServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, struct zcl_rssi_loc_server_callbacks_t *callbacks, void *arg);

Create a new instance of the RSSI Location Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclRssiLocServerCompDataNotif

enum ZclStatusCodeT ZbZclRssiLocServerCompDataNotif(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Compact Data Notification command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerLocDataNotif

enum ZclStatusCodeT ZbZclRssiLocServerLocDataNotif(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Location Data Notification command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerReportRssi

enum ZclStatusCodeT ZbZclRssiLocServerReportRssi(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_report_rssi *report_rssi, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Report RSSI command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerReqOwnLoc

enum ZclStatusCodeT ZbZclRssiLocServerReqOwnLoc(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
struct rssi_loc_req_own_loc *req_own_loc, void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a Request Own Location command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerRssiPing

enum ZclStatusCodeT ZbZclRssiLocServerRssiPing(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a RSSI Ping command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerRssiReq

enum ZclStatusCodeT ZbZclRssiLocServerRssiReq(struct ZbZclClusterT *cluster, const struct ZbApsAddrT *dst,
void (*callback)(struct ZbZclCommandRspT *rsp, void *arg), void *arg);

Send a RSSI Request command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerSendDevConfigRsp

enum ZclStatusCodeT ZbZclRssiLocServerSendDevConfigRsp(struct ZbZclClusterT *clusterPtr, struct ZbZclAddrInfoT *dst_info,
struct rssi_loc_dev_config_rsp *rsp);

Send a Device Configuration Response command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

ZbZclRssiLocServerSendLocDataRsp

enum ZclStatusCodeT ZbZclRssiLocServerSendLocDataRsp(struct ZbZclClusterT *clusterPtr, struct ZbZclAddrInfoT *dst_info,
struct rssi_loc_loc_data_rsp *rsp);

Send a Location Data Response command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclRssiLocSvrAttrT

Rssi Location Attribute IDs

Structures

rssi_loc_anchor_node_annc

Anchor Node Announce command structure

Parameters

rssi_loc_comp_data_notif

Compact Data Notification command structure

Parameters

rssi_loc_dev_config_rsp

Device Configuration response structure

Parameters

rssi_loc_get_dev_config

Get Device Configuration command structure

Parameters

rssi_loc_get_loc_data

Get Location Data command structure

Parameters

rssi_loc_loc_data_notif

Location Data Notification command structure

Parameters

rssi_loc_loc_data_rsp

Location Data response structure

Parameters

rssi_loc_neighbour_info

Neighbour Info structure

Parameters

rssi_loc_report_rssi

Report Rssi command structure

Parameters

rssi_loc_req_own_loc

Request Own Location command structure

Parameters

rssi_loc_rssi_ping

Rssi Ping command structure

Parameters

rssi_loc_rssi_req

Rssi Request structure

Parameters

rssi_loc_rssi_rsp

Rssi response structure

Parameters

rssi_loc_send_pings

Send Pings command structure

Parameters

rssi_loc_set_abs_loc

Set Absolute Location command structure

Parameters

rssi_loc_set_dev_config

Set Device Configuration command structure

Parameters

zcl_rssi_loc_client_callbacks_t

Rssi Location Client callbacks configuration

Parameters

zcl_rssi_loc_server_callbacks_t

Rssi Location Server callbacks configuration

Parameters

17. Scenes

#include "zcl/general/zcl.scenes.h"

Description

ZCL 8 section 3.7

A scene is a set of values for attributes from multiple clusters capable of being applied at the same time. The few clusters that support scenes are identified by a section with the title "Scene Table Extensions" in the ZCL 8 Specification (ZCL8) section for those cluster. There is only one scene table (list of attributes) for a cluster that supports scenes, and when a scene is invoked all scene table attributes are set to the values given in the scene table.

To use the scene table for a cluster, the cluster must reside on an endpoint which also hosts an instance of the Scenes cluster. There may be multiple scene table supporting clusters on a given endpoint. A scene is defined in the scenes cluster and contains scene tables for one or more clusters. Through the use of group addressing a scene may be applied to multiple endpoints on a node.

A scene may be created by the scene cluster using the Add Scene command, where the application manually defines the scene table for each cluster included in that scene. All attributes must have values in the scene table, but inclusion of individual clusters is optional. A scene may also be created using the Store Scene command where the current value of all the attributes in the cluster at the time the Store Scene command is issued are recorded in the scene table for later use.

The Scenes cluster Recall Scene command takes the scene table for each cluster in that scene and sets the values of every scene table attribute.

For example, a node could contain three endpoints:

  • 0x01 with the OnOff and Window Covering clusters
  • 0x02 with the OnOff and Door Lock clusters
  • 0x03 with the OnOff and Level.

A scene is defined with a scene tables for the:

  • OnOff cluster: OnOff = On
  • Level cluster: CurrentLevel = 50%
  • DoorLock cluster: LockState = Locked

Additionally:

  • Endpoints 0x01 and 0x02 are in group 0x0001
  • Endpoint 0x03 is not in group 0x0001

If the scenes cluster Recall Scenes command is issued with group address 0x0001 and the scene defined above, then on endpoint

0x01 and 0x02 the OnOff cluster OnOff attribute will be set on and the DoorLock on endpoint 0x02 will be locked.

The Window Covering cluster on endpoint 0x01 will not be affected because this scene does not include a scene table for this cluster and all of endpoint 0x03 will be unaffected because it is not in group 0x0001.

For more information about the Scenes cluster, see Section 3.7 in ZCL8.

Functions

ZbZclScenesClientAlloc

struct ZbZclClusterT * ZbZclScenesClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Scenes Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclScenesServerAlloc

struct ZbZclClusterT * ZbZclScenesServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, uint8_t maxScenes);

Create a new instance of the Scenes Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

zcl_scenes_client_add_req

enum ZclStatusCodeT zcl_scenes_client_add_req(struct ZbZclClusterT *cluster, struct zcl_scenes_add_request_t *add_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send an Add Scene or Enhanced Add Scene command, depending on isEnhanced flag in Add Scene command structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_add_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_add_rsp_parse(struct zcl_scenes_add_response_t *add_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse an Add Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_copy_req

enum ZclStatusCodeT zcl_scenes_client_copy_req(struct ZbZclClusterT *cluster, struct zcl_scenes_copy_request_t *copy_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Copy Scene command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_copy_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_copy_rsp_parse(struct zcl_scenes_copy_response_t *copy_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Copy Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_get_membership_req

enum ZclStatusCodeT zcl_scenes_client_get_membership_req(struct ZbZclClusterT *cluster, struct zcl_scenes_membership_request_t *get_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Get Scene Membership command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_get_membership_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_get_membership_rsp_parse(struct zcl_scenes_membership_response_t *get_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Get Scene Membership Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_recall_req

enum ZclStatusCodeT zcl_scenes_client_recall_req(struct ZbZclClusterT *cluster, struct zcl_scenes_recall_request_t *recall_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Recall Scene command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_recall_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_recall_rsp_parse(struct zcl_scenes_recall_response_t *recall_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Recall Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_remove_all_req

enum ZclStatusCodeT zcl_scenes_client_remove_all_req(struct ZbZclClusterT *cluster, struct zcl_scenes_remove_all_request_t *remove_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Remove All Scenes command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_remove_all_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_remove_all_rsp_parse(struct zcl_scenes_remove_all_response_t *remove_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Remove All Scenes Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_remove_req

enum ZclStatusCodeT zcl_scenes_client_remove_req(struct ZbZclClusterT *cluster, struct zcl_scenes_remove_request_t *remove_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Remove Scene command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_remove_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_remove_rsp_parse(struct zcl_scenes_remove_response_t *remove_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Remove Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_store_req

enum ZclStatusCodeT zcl_scenes_client_store_req(struct ZbZclClusterT *cluster, struct zcl_scenes_store_request_t *store_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send a Store Scene command

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_store_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_store_rsp_parse(struct zcl_scenes_store_response_t *store_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a Store Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_view_req

enum ZclStatusCodeT zcl_scenes_client_view_req(struct ZbZclClusterT *cluster, struct zcl_scenes_view_request_t *view_req,
void (*callback)(struct ZbZclCommandRspT *zcl_rsp, void *arg), void *arg);

Send an View Scene or Enhanced View Scene command, depending on isEnhanced flag in View Scene command structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

zcl_scenes_client_view_rsp_parse

enum ZclStatusCodeT zcl_scenes_client_view_rsp_parse(struct zcl_scenes_view_response_t *view_rsp, struct ZbZclCommandRspT *zcl_rsp);

Parse a View Scene Response command payload into a structure

Parameters

Return

  • ZCL_STATUS_SUCCESS if successful, or other ZclStatusCodeT value on error

Enumerations

ZbZclScenesAttrT

Scenes Attribute IDs

Structures

zcl_scenes_add_request_t

Add Scene command structure

Parameters

zcl_scenes_add_response_t

Add Scene Response command structure

Parameters

zcl_scenes_copy_request_t

Copy Scene command structure

Parameters

zcl_scenes_copy_response_t

Copy Scene Response command structure

Parameters

zcl_scenes_membership_request_t

Get Scene Membership command structure

Parameters

zcl_scenes_membership_response_t

Get Scene Membership Response command structure

Parameters

zcl_scenes_recall_request_t

Recall Scene command structure

Parameters

zcl_scenes_recall_response_t

Recall Scene Response command structure

Parameters

zcl_scenes_remove_all_request_t

Remove All Scenes command structure

Parameters

zcl_scenes_remove_all_response_t

Remove All Scenes Response command structure

Parameters

zcl_scenes_remove_request_t

Remove Scene command structure

Parameters

zcl_scenes_remove_response_t

Remove Scene Response command structure

Parameters

zcl_scenes_store_request_t

Store Scene command structure

Parameters

zcl_scenes_store_response_t

Store Scene Response command structure

Parameters

zcl_scenes_view_request_t

View Scene command structure

Parameters

zcl_scenes_view_response_t

View Scene Response command structure

Parameters

18. Temperature Measurement

#include "zcl/general/zcl.temp.meas.h"

Functions

ZbZclTempMeasClientAlloc

struct ZbZclClusterT * ZbZclTempMeasClientAlloc(struct ZigBeeT *zb, uint8_t endpoint);

Create a new instance of the Temperature Measurement Client cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

ZbZclTempMeasServerAlloc

struct ZbZclClusterT * ZbZclTempMeasServerAlloc(struct ZigBeeT *zb, uint8_t endpoint, int16_t min, int16_t max, uint16_t tolerance);

Create a new instance of the Temperature Measurement Server cluster

Parameters

Return

  • Cluster pointer, or NULL if there is an error

Enumerations

ZbZclTempMeasSvrAttrT

Temperature Measurement Server Attribute IDs