Z-stack protocol Stack Learning notes---Modifying Panid and channel selection

Source: Internet
Author: User
Panid Settings

The sign of a ZigBee network is that Panid,panid is a 16-bit variable that can define 65,535 different networks of Panid numbers. We can use Panid to differentiate different ZigBee networks within the same channel. Panid is generally determined by coordinator, router and Enddevice access will be coordinator from Panid. You can also fix the Panid of router and enddevice to join a specific coordinator. This value is defined in the tools/f8wconfig.cfg of the Zstack protocol stack:


Modify this macro to set Panid, if the value is set to 0xFFFF for random, coordinator will randomly select a number as Panid in the 0~0x3fff range.
Channel Settings In addition to Panid, we can also use the channel to differentiate, after all, the different channels of the device cannot communicate. Coordinator and router and Enddevice must be set to the same channel to connect to the same network. The modified location is also in Tools/f8wconfig.cfg:


Set the channel by opening the macro for the corresponding channel, for example, set channel 26. ZigBee protocol defines 26 channels, respectively, 868MHZ1, 915mhz10, 2.4ghz11. However, since the CC2530 chip supports only 2.4G, the 2.4G band can only be set here, i.e. 11 channels to 26 channels.
Channel selection ZigBee cloth Network The biggest obstacle is interference, that is, from the WiFi interference. WiFi and ZigBee are in the 2.4G band, the channel is highly coincident. and whether it is power or anti-jamming ability ZigBee is not the enemy of WiFi. Therefore, when deploying the ZigBee network, consider the interference bands of the WiFi signal in the current environment and avoid these bands as much as possible.


As shown above, WiFi has 14 channels in the 2.4g band, and the channels overlap each other. But in China, the most common channel for wireless APs is 1, 6, 11, and almost all of the civilian wireless APs are the three channels by default. Self-observation can be found that the three channels before and after the small gap between, respectively, f<2.401, 2.423<f<2.426, 2.448<f<2.451, f>2.473. Let's take a look at the channel distribution of ZigBee:


The comparison shows that 15, 20, 25, 26 of these four ZigBee channels completely avoid the usual WiFi channel 1, 6, 11. is the best choice for ZigBee cloth network.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.