XBee®/XBee‐PRO® ZB SMT RF Modules
Sending ZigBee Cluster Library (ZCL) Commands with the API
The ZigBee Cluster Library defines a set of attributes and commands (clusters) that can be supported in multiple
ZigBee profiles. The ZCL commands are typically required when developing a ZigBee product that will interoperate in
a public profile such as home automation or smart energy, or when communicating with ZigBee devices from other
vendors. Applications that are not designed for a public profile or for interoperability applications can skip this
section.
The following table shows some prominent clusters with their respective attributes and commands.
Cluster (Cluster ID)
Basic (0x0000)
Attributes (Attribute ID)
Cluster ID
Application Version (0x0001)
Hardware Version (0x0003)
Model Identifier (0x0005)
-Reset to defaults
(0x00)
Identify (0x00)
Identify Query (0x01)
Identify (0x0003)
Time (0x000A)
Identify Time (0x0000)
Time (0x0000)
Time Status (0x0001)
Time Zone (0x0002)
Local Temperature (0x0000)
Occupancy (0x0002)
-Setpoint raise / lower
(0x00)
Thermostat (0x0201)
The ZCL defines a number of profile-wide commands that can be supported on any profile, also known as general
commands. These commands include the following.
Command (Command ID)
Description
Used to read one or
more attributes on a
remote device.
Read Attributes (0x00)
Generated in
response to a read
attributes command.
Read Attributes Response (0x01)
Write Attributes (0x02)
Used to change one
or more attributes on
a remote device.
Sent in response to a
write attributes
command.
Write Attributes Response (0x04)
Used to configure a
device to
automatically report
on the values of one
or more of its
Configure Reporting (0x06)
Report Attributes (0x0A)
attributes.
Used to report
attributes when report
conditions have been
satisfied.
Used to discover the
attribute identifiers on
a remote device.
Discover Attributes (0x0C)
Sent in response to a
discover attributes
command.
Discover Attributes Response (0x0D)
The Explicit Transmit API frame (0x11) is used to send ZCL commands to devices in the network. Sending ZCL
commands with the Explicit Transmit API frame requires some formatting of the data payload field.
When sending a ZCL command with the API, all multiple byte values in the ZCL command (API Payload) (e.g. u16,
u32, 64-bit addresses) must be sent in little endian byte order for the command to be executed correctly on a
remote device.
Note: When sending ZCL commands, the AO command should be set to 1 to enable the explicit receive API frame.
This will provide indication of the source 64- and 16-bit addresses, cluster ID, profile ID, and endpoint information
for each received packet. This information is required to properly decode received data.
© 2010 Digi International, Inc.
121