《ZigBee Wireless Networking》學習筆記【2】
阿新 • • 發佈:2019-02-08
Between the layers are Service Access Points (SAPs). SAPs provide an API that isolates
the inner workings of that layer from the layers above and below. Like the IEEE 802.15.4
specification, ZigBee uses a two-SAP approach per layer, one for data and one for
management. For example, all data communications to and from the network layer go
through the Network Layer Data Entity Service Access Point (NLDE-SAP). Why the data
SAP for the MAC layer is called MAC Common Part Service SAP (MCPS-SAP) instead
of the MLDE-SAP is confusing to me, but it is. You’ll see commands in the ZigBee
specification that look like APSDE-DATA.request. Now you know that is a request to
send data out the radio, but initiated just above APS layer.
The two lowest layers, the MAC and PHY, are defined by the IEEE 802.15.4
specification. The PHY layer simply translates packets into over-the-air bits and back
again. The MAC layer provides the concept of a network, including a PAN ID, and
networking discovery through beacon requests and responses. It also provides per-hop
acknowledgments and some of the commands for joining and forming a network. The
MAC does not multi-hop or mesh.
The NWK layer is responsible for mesh networking, which includes broadcasting packets
across the network, determining routes for unicasting packets, and generally making sure
packets are sent reliably from one node to another. The network layer also has a set of
commands for security purposes, including secure joining and rejoining. ZigBee networks
are all secured at the NWK layer, and the entire payload of the NWK frame is encrypted.
The APS layer is responsible for application meaning. It acts as a filter for the
applications running above it on endpoints to simplify the logic in those applications.
It understands what clusters and endpoints mean, and checks to see if the endpoint is a
member of the Application Profile and (if present) group before sending the message on
up. The APS layer also filters out duplicate messages that may have been sent up by the
NWK layer. The APS layer keeps a local binding table, a table which indicates the nodes
or groups in the network that this node wishes to speak to.
The ZDO layer (which includes the ZigBee Device Profile, ZDP), is responsible for local
and over-the-air management of the network. It provides services to discover other nodes
and services in the network, and is directly responsible for the current state of this node
on the network.
The Application Framework contains the ZigBee Cluster Library and provides a
framework within which applications run. Endpoints are the mechanism used to
distinguish one application from another.
the inner workings of that layer from the layers above and below. Like the IEEE 802.15.4
specification, ZigBee uses a two-SAP approach per layer, one for data and one for
management. For example, all data communications to and from the network layer go
through the Network Layer Data Entity Service Access Point (NLDE-SAP). Why the data
SAP for the MAC layer is called MAC Common Part Service SAP (MCPS-SAP) instead
of the MLDE-SAP is confusing to me, but it is. You’ll see commands in the ZigBee
specification that look like APSDE-DATA.request. Now you know that is a request to
send data out the radio, but initiated just above APS layer.
The two lowest layers, the MAC and PHY, are defined by the IEEE 802.15.4
specification. The PHY layer simply translates packets into over-the-air bits and back
again. The MAC layer provides the concept of a network, including a PAN ID, and
networking discovery through beacon requests and responses. It also provides per-hop
acknowledgments and some of the commands for joining and forming a network. The
MAC does not multi-hop or mesh.
The NWK layer is responsible for mesh networking, which includes broadcasting packets
across the network, determining routes for unicasting packets, and generally making sure
packets are sent reliably from one node to another. The network layer also has a set of
commands for security purposes, including secure joining and rejoining. ZigBee networks
are all secured at the NWK layer, and the entire payload of the NWK frame is encrypted.
The APS layer is responsible for application meaning. It acts as a filter for the
applications running above it on endpoints to simplify the logic in those applications.
It understands what clusters and endpoints mean, and checks to see if the endpoint is a
member of the Application Profile and (if present) group before sending the message on
up. The APS layer also filters out duplicate messages that may have been sent up by the
NWK layer. The APS layer keeps a local binding table, a table which indicates the nodes
or groups in the network that this node wishes to speak to.
The ZDO layer (which includes the ZigBee Device Profile, ZDP), is responsible for local
and over-the-air management of the network. It provides services to discover other nodes
and services in the network, and is directly responsible for the current state of this node
on the network.
The Application Framework contains the ZigBee Cluster Library and provides a
framework within which applications run. Endpoints are the mechanism used to
distinguish one application from another.