Specifications

XBee®/XBeePRO®SERFModules
©2009DigiInternational,Inc. 42
Simple Descriptor Example
One can obtain the simple descriptor for an endpoint on a node by uncasting a Simple_Desc_req
command. It is addressed to cluster 0x0004, and carries a 16-bit NWK address and endpoint value
as payload.
In response one would receive a Simple_Desc_rsp response. It is addressed as cluster 0x8004,
and carries as payload: Status (1), 16-bit NWK address (2), Length (1) of the simple descriptor
which follows, and a Simple Descriptor.
The simple descriptor will tell you the endpoint value, Application profile Id, Application device Id,
input cluster list, and output cluster list which are associated with the endpoint.
As a reminder, the Smart Energy Application Profile Id is 0x0109. The mapping of Smart Energy
Device IDs to Device Types is listed in a subsequent section in this document. The input and
output cluster lists will tell you whether this endpoint is acting as the server or client side of a
particular cluster ID. Input clusters are associated with the server side, and output clusters with
the client side.
Match Descriptor Example
Rather than interrogate each node in the network to determine its functions and capabilities, one
can use the Match_Desc_req to find a node (or nodes) which host endpoints which support a
particular profile id and cluster combination.
The Match_Desc_req command may be broadcast to the network as a whole, or directed by
unicast to a specific node.
It is addressed to cluster 0x0006, and carries as payload: 16-bit NWK address(2), ProfileId(2),
#InputClusters(1), Input Cluster list(2 bytes per clusterId), #OutputClusters(1), and Output
Cluster List (2 bytes per clusterId).
In response one receives a Match_Desc_rsp response from each matching device on the node (if
the request was unicast) or nodes (if the request was broadcast). A match occurs if the profile id
and at least one of the input or output cluster IDs given in the request can be found. It is
addressed as cluster 0x8006, and carries as payload: Status(1), 16-bit NWK address(2),
matchLength(1), and matchList.
The matchList is a list of endpoints which match the request.
Attribute Discovery Example
Once you have a desired node/endpoint/cluster address combination, you will want to manage the
attributes. For example, to discover the attributes of the basic cluster on a node, one would use an
Explicit Addressing ZigBee Command Frame as follows:
Address the node with its 64-bit address, use 0xFFFE for the 16-bit address, set the source
endpoint to the return address to which you would like the response delivered, use a destination
endpoint of 0x00 (ZDO endpoint), destination cluster Id of 0x00 (Basic cluster), ZDP profile id of
0x0000, 0x00 for broadcast radius (or whatever maximum hop count you'd like), and 0x20 for
enabling APS end-to-end security (or 0x00 if not - some clusters require the higher security). The
second byte of the ZCL payload sets an upper limit on how many attributes you would like
returned at a time. The first byte is the starting index of attributes in which you are interested.