Lecture Notes: Zigbee Network Layer (NWK)
Introduction
The Zigbee Network Layer (NWK) is a core component of the Zigbee protocol stack, distinct from the IEEE 802.15.4 standard. It is specifically designed to support mesh networking features, with key responsibilities including addressing and routing of data within the network.
Zigbee supports three modes of communication: unicast (one-to-one), broadcast (one-to-all), and multicast (one-to-group).
Within the network, routing functionality is handled by Zigbee Coordinators (ZC) and Zigbee Routers (ZR). In contrast, Zigbee End Devices (ED) are designed to be resource-efficient and do not participate in routing.
Zigbee Stack and NWK Layer
Figure 1. Zigbee Stack and Network Layer [1].
Network Layer Data Entity (NLDE): Handles data transmission.
Network Layer Management Entity (NLME): Manages network functions like formation, joining, and routing.
Services are accessed via NLDE-SAP (data) and NLME-SAP (management).
Communication Mechanisms
1. Unicast: One-to-one communication.
Figure 2. Unicast [1].
2. Broadcast: One-to-all communication (forwarded by receivers).
Uses Broadcast Transaction Table (BTT) to avoid duplicate transmissions.
Passive Acknowledgement: Sender listens for rebroadcasts as confirmation.
Figure 3. Broadcast [1].
3. Multicast: One-to-subset communication.
Uses multicast groups (16-bit IDs).
Modes:
- Member Mode: Sender is part of the group.
- Non-Member Mode: Sender is not part of the group (uses routing tables).
Figure 4. Multicast [1].
Network Management
Functions include:
Network discovery and formation.
Figure 5. Establishing [1].
Figure 5. Discovery [1].
Joining/leaving a network.
Figure 6. Joining [1].
Address allocation.
ZC initiates network formation; other nodes join via discovery.
Network Topologies (Important)
1. Star: Simple, with ZC at the center.
Figure 7. Star Topology [1].
2. Tree: Hierarchical, with ZC as root and ZRs/EDs as children.
Figure 8. Tree Topology [1].
Addressing uses Cskip(d) formula:
where:
-
:在深度 ddd 的节点,每个路由器子节点之间的地址跨度
-
– maximum number of children each parent can have (nwkMaxChildren). 每个节点可分配的总子节点数(包括终端和路由器)
-
– maximum number of ZR children a parent can have. 每个节点可分配的路由器数目
-
– Depth of a node n whose sub-tree addresses are being calculated. Defined as the number of parent/child links that a frame must travel through from to ZC. 当前节点的深度
-
– the maximum network depth (nwkMaxDepth). 网络允许的最大深度
3. Mesh: Scalable and resilient, uses AODV-based routing.
Figure 9. Mesh Topology [1].
Adress Allocation (Important)
Theory:
The method involved with adress allocation is shown as Figure 10.
Figure 10. The Theory for Calculation [1].
Examples:
Figure 10. Two Examples with Different Rm [1]. Attention to distinguish between Router node and End Divice node.
Draft and Answer:
Figure 1. This is the Draft Showing the Right Result and Calculation Process. Do attention to the block operation in the first example. That is an easier way to get the right answer when Rm = 1.
Routing in Trees
Address-based routing:
- If destination is a descendant, next hop is calculated using:
where = current node address,
= destination address.
Routing in Meshes
Based on AODV with modifications:
- Route Discovery: Floods RREQ, replies with RREP.
- Link Costs: Can be constant or based on packet delivery probability (\(p_l\)):
Tables:
- Routing Table (RT): Stores next-hop info.
- Route Discovery Table (RDT): Tracks RREQ paths.
- Neighbor Table (NT): Lists 1-hop neighbors.
Route Maintenance: Uses RERR to notify broken links.
Differences from AODV
1. EDs do not participate in routing.
2. Uses Broadcast ID (Bid) instead of sequence numbers.
3. Supports symmetric/non-symmetric routing.
4. Multicast RREQ includes group ID.
Key Primitives
Data Primitive: `NLDE-DATA` (request, confirm, indication).
Management Primitives: Include:
- `NLME-NETWORK-FORMATION`
- `NLME-JOIN`
- `NLME-ROUTE-DISCOVERY`
- (Not applicable to EDs: `NLME-START-ROUTER`, `NLME-PERMIT-JOINING`).
Summary
NWK provides data transmission and network management.
Supports unicast, broadcast, multicast.
Routing:
- Tree: Address-based.
- Mesh: Modified AODV.
Tables (RT, RDT, NT) and link costs optimize routing.
Disclaimer
This material is provided exclusively for academic learning and instructional purposes. All other uses, including reproduction, distribution, commercial exploitation, or derivative work, are expressly forbidden.
References
[1] Ding, Z. (2025) Zigbee Network Layer (Lecture 15). EEEN60184 Internet and Communications Networks. University of Manchester, School of Electrical and Electronic Engineering.
[2] Zigbee Alliance (2015) Zigbee Specification. Zigbee Document 053474r20, Zigbee Alliance.
[3] Farahani, S. (2008) Zigbee Networks and Transceivers. Oxford: Newnes.