Detailed Explanation of ZigBee Protocol Network Topology

Hello everyone, I am Xiao Chen, dedicated to sharing knowledge related to smart home technology.

In the last issue, I shared the advantages and disadvantages of the ZigBee protocol. This time, I will continue to share the network topology of the ZigBee protocol. For those who are not familiar with the ZigBee protocol, please refer to:

ZigBee supports three types of network structures:<span><span>Star network, cluster tree network, and mesh network</span></span>

To better understand the network structure of ZigBee, let’s make a rough analogy: the coordinator is like a matchmaker, the endpoints are like children who have not yet started dating, and the routers are like the parents of those children.

Star Network

<span>The star network is the simplest form, consisting of one coordinator (Coordinator) and a series of endpoints (End Devices).</span>

Each endpoint can only communicate with the coordinator, and endpoints cannot directly transmit data to each other. If two endpoint devices, A and B, want to communicate, they must relay information through the coordinator. That is, endpoint A first sends data to coordinator C, and then coordinator C forwards the data to B.

In the structure of the star network, according to our analogy, the matchmaker organizes and establishes a blind date meeting. The son from the Zhang family wants to date the daughter from the Li family. Since they are both shy, they do not communicate face-to-face but instead convey their feelings through the matchmaker.Detailed Explanation of ZigBee Protocol Network Topology

In the star network structure, the only way for data transmission between endpoints is through the coordinator, which may become a bottleneck for the entire network. The star network does not use the ZigBee network layer protocol but instead uses the IEEE 802.15.4 protocol layer.

Cluster Tree Network

<span>The cluster tree network adds routers based on the star network. It consists of one coordinator (Coordinator), a series of routers (Router), and a series of endpoints (End Devices).</span>

The coordinator can connect to a series of routers and a series of endpoints, while routers can connect to a series of routers and a series of endpoints, forming a hierarchical relationship, like a tree with a trunk, branches, and leaves.

Endpoints first forward data to the routers within the same network, and then the routers layer by layer forward the data to the upper-level routers until the data reaches the final coordinator.Detailed Explanation of ZigBee Protocol Network Topology

Each endpoint can only communicate with the coordinator or routers, and endpoints cannot directly transmit data to each other. In the case of multiple routers, routers can communicate with endpoints, coordinators, or other routers at different levels.

In simple terms, each node can only directly communicate with its parent node or child node. If two nodes need to communicate across levels or branches, the data will first be transmitted up to the nearest common ancestor node and then transmitted down to the target node. For example:A32 sends data to B21

  • The parent node of A32 is A21, the parent node of A21 is A1, and the parent node of A1 is coordinator C.
  • The parent node of B21 is B1, and the parent node of B1 is coordinator C.
  • The nearest common ancestor node of both is coordinator C.
  • The transmission path for A32 sending data to B21 is:<span>A32 → A21 → A1 → C → B1 → B21</span>

A31 sends data to A32

  • The common parent node of A31 and A32 is A21.
  • The transmission path for A31 sending data to A32 is:<span>A31 → A21 → A32</span>

A21 and A22 cannot communicate directly

  • The common parent node of A21 and A22 is A21.
  • If A31 sends data to A32, the transmission path is:<span>A21 → A1 → A22</span>

In the structure of the cluster tree network, according to our analogy, the matchmaker organizes and establishes a blind date meeting. The son from the Zhang family wants to date the daughter from the Li family. They are even shyer, so the son from the Zhang family tells his parents, who find the matchmaker, who then contacts the Li family’s parents, and finally, the Li family’s parents convey the son’s feelings to their daughter. If the son from the Zhang family wants to date another girl, the process is the same. At the blind date meeting, if the parents from the Zhang family happen to know the daughter from the Li family, they can directly convey their son’s feelings to her.

In the structure of the cluster tree network, the data transmission between endpoints essentially still has only one way, which is through the common parent node or common ancestor node for relay. Therefore, the router or coordinator serving as the common parent node or common ancestor node may also become a bottleneck for the entire network. Compared to the star network, the addition of routers greatly increases the number of connections for endpoints and enhances the overall coverage of the network.

Mesh Network

<span>The mesh network adds more flexible information routing rules based on the cluster tree network. Like the cluster tree network, it also consists of one coordinator (Coordinator), a series of routers (Router), and a series of endpoints (End Devices).</span>

The more flexible information routing rules mean that routers, which originally could not communicate directly in the cluster tree network, can now communicate directly, achieving a <span>multi-hop</span> communication method. The benefit of this is a significant increase in communication efficiency. Additionally, the network has self-organizing and self-healing capabilities. If a router fails, endpoints can automatically connect to a new router and establish a new transmission path to complete data transmission. The mesh network supports multi-hop methods to extend data transmission distance and wireless coverage.

Detailed Explanation of ZigBee Protocol Network Topology

Each endpoint can only communicate with the coordinator or routers, and endpoints cannot directly transmit data to each other. However, parent nodes can now communicate directly, meaning each parent node can directly communicate with its parent node, same-level nodes, or child nodes. There is no cross-level or cross-branch communication between two parent nodes. Child node data will first be transmitted up to the parent node, and the parent node will then directly or indirectly transmit to the parent node of the target node, finally reaching the target node.

For example:A32 sends data to B21

  • The parent node of A32 is A21, and the parent node of B21 is B1. There are many paths from A21 to B1, such as A21→A1→B1 or A21→A22→A1→B1, and of course, there are other paths.
  • The transmission path for A32 sending data to B21 is:In the cluster tree network:<span>A32 → A21 → A1 → C → B1 → B21</span>In the mesh network:<span>A32 → A21 → A1 → B1 → B21</span>

A31 sends data to A32

  • The common parent node of A31 and A32 is A21.
  • The transmission path for A31 sending data to A32 is:In both the cluster tree network and the mesh network:<span>A31 → A21 → A32</span>

A21 and A22 can communicate directly

  • If A21 sends data to A22, the transmission path is:In the cluster tree network:<span>A21 → A1 → A22</span>In the mesh network:<span>A21 → A22</span>

In the structure of the mesh network, according to our analogy, the matchmaker organizes and establishes a blind date meeting. The son from the Zhang family wants to date the daughter from the Li family. They are also shy, so the son from the Zhang family tells his parents, who can either find the matchmaker or directly contact the Li family’s parents. If they choose the matchmaker, she will find the Li family’s parents, who will then convey their daughter’s feelings. If the son from the Zhang family wants to date another girl, he can either find the matchmaker or directly contact the parents of other families or the daughters of other families.

In the structure of the mesh network, there are multiple paths for data transmission between endpoints, and these paths can automatically repair, change, and select the optimal connection based on the situation. The entire network is stable, flexible, and has a wide coverage.

So can we eliminate the coordinator? The answer is no. First, the startup, establishment, and management of the ZigBee network need to be completed by the coordinator. Secondly, the ZigBee protocol is mainly used in the Internet of Things field, and our mobile phones and devices using other protocols cannot directly communicate with it. Additionally, ZigBee devices cannot directly connect to the external network, so a coordinator is still needed to establish a connection with the external network.

Leave a Comment