Difference between Zigbee and 6LowPAN explained with a simple Arduino + Xbee setup

Xbee is an amazing piece of technology that uses Zigbee protocols to communicate with one another. Let me first tell you what Zigbee is and how is it different from other emerging standards that are making waves in the scientific community.

Currently, there are two standards that are competing for their dominance in the wireless communication market. Zigbee and 6LoWPAN.

BACKGROUND:

Zigbee and 6LoWPAN protocols are widely used for low power wireless sensor networks that are being deployed in factories for monitoring the status of their devices and the environment. Power consumption could be measured using these protocols. According to various journal, Zigbee protocol defines the beacon enabled mode in a way that allow nodes to stay in low power sleep states for most of the time, while miltihop transmission with sleeping nodes is achieved through the use of the tree routing protocol through the cluster-tree hierarchy. The 6LoWPAN protocol, on the other hand, is based on IPv6 and operates in a fully asynchronous way. It adopts a mesh topology and uses a routing algorithm which does not take care of the sleeping node thus requiring approaches such as low-power listening for energy saving purpose (Tascano, 2012).

Some of the most notable difference between ZigBee and 6LoWPan is in its application and how it fits in the current Internet of Things (IoT) revolution. To begin with, ZigBee is the most popular low-cost, low-power wireless mesh networking standard avaible today. It is a networking layer built on top of IEEE standard 802.15.4 Medium Access Control (MAC). It was designed to provide a standards-based protocol for interoperability which means that the applications do not need to know the constraints of the physical links that carry their packets.

The way ZigBee works is by defining new layer that goes upward to the application layer when communicating between 802.15.4 physical layers. Therefore, ZigBees could be used to communicate with one another given these are using the same protocols. 6LoWPAN or IPv6 over Low powered Wireless Personal Area Network offers interoperability with IEEE 802.15.4 physical link devices as well as with devices on another IP network such with bridge devices. That means that people can communicate with devices across the internet without having to go through the ZigBee to IP conversion process. Another aspect of 6LoWPAN is its security. Unlike Zigbee where gateways are required hence in order to connect the device over the internet two security process are required. One security process is required in the network side while the other is required in the internet side. This setup welcomes attack that could destroy the integrity of the end to end link. But IP routing over 6LowPAN links does not necessarily requires additional header giving more space for payload (Tascano & Lo Bello, 2012)

However, according to an article by ECN, there are some disadvantages to these protocols. In the case with ZigBee, bridging between ZigBee and non ZigBee needs more complex gateways unlike 6LowPAN. On the other hand, the greatest challenge to 6LoWPAN is the lack of application that utilizes 6LoWPAN because it require extensive training as it is complicated to work with and requires extensive knowledge of IPv6 protocol. Another challenge with 6LoWPAN is that end users could not deploy this protocol easily as it requires extensive knowledge of stack and the workability of IPv6 (2014).

Moreover, 6LoWPAN has many good things to offer when compares to ZigBee apart from the fact that 6LoWPAN is a new standard which will take some time to catch on. ZigBee on the other hand is well known in the market and a lot of manufacturers are designing products that could utilize the power of ZigBee without much effort put by the end users. All the major players in the semiconductor industry, such as Texas Instruments, Freescale and Atmel, promote and supply 802.15.4 chips which can be used for either ZigBee or 6LoWPAN. These same companies even offer free ZigBee stacks. Support for 6LoWPAN stacks seems to be trailing behind ZigBee (Sarto J.,2014).

EXPERIMENT:

Xbee arduino shields which uses Zigbee protocols are widely available in the market since these are used for industrial scale mesh network for industrial automation and early warning system for industries.

I had the luxury of having two arduino board and two Xbee shield which I will program so that these two arduino could communicate with one another wireless-ly. In my first arduino, I uploaded the sketch which can be found in the arduino’s example folder under the file name PhysicalPixal (File>Example>Communication>PhysicalPixal). Once you open this file, you need to note down the baudrate at which the arduino would be receive the data. In my case, it is 9600 so I will make sure that the in the second arduino I will copy the exact baudrate. The data first arduino would receive would turn on or off the LED at pin 13 when the letter ‘H’ or ‘L’ is received by the arduino.

One the second Arduino, I wrote a simple code that would transmit the letter ‘H’ and ‘L’ through serial communication so that it could send data to the first arduino hence controlling the status of pin 13 of the first Arduino.

Here is the code:

void setup(){

Serial.begin(9600);

}

void loop(){
Serial.print(‘H’);

delay(1000);

Serial.print(‘L’);

delay(1000);

}

Xbee Arduino shields are very straight forward to use. You just need to put the shield on top of the two arduino and sit back and relax. The Xbee shields would do the initialization and configuration on its own and starts transmitting the data

Reference:

  • Toscano, E. & Lo Bello, L. (2012) “Comparative assessments of IEEE 802.15. 4/ZigBee and 6LoWPAN for low-power industrial WSNs in realistic scenarios”, Factory Communication Systems (WFCS), 2012 9th IEEE International Workshop on, IEEE. p115-124.

Leave a Reply