IoT Zigbee

Download as pdf or txt
Download as pdf or txt
You are on page 1of 90

IoT Communication

Standards
IEEE 802.15.4 ZigBee
2ECDE65 Internet of Things
IEEE 802.15.4
The IEEE 802.15.4 standard is a specification for low-rate wireless
personal area networks (LR-WPANs).
It defines the physical (PHY) and medium access control (MAC) layers
for wireless communication devices with low power consumption,
short range, and low data rates.
IEEE 802.15.4 serves as the foundation for various wireless
communication protocols, including Zigbee, WirelessHART, and
ISA100.11a etc.
• Physical Layer (PHY): The IEEE 802.15.4 PHY layer specifies the radio
characteristics, modulation schemes, and frequency bands for
communication. It operates in the unlicensed 2.4 GHz ISM (Industrial,
Scientific, and Medical) band, as well as other frequency bands like
868 MHz and 915 MHz in some regions. The PHY layer supports
multiple data rates, ranging from 20 kbps to 250 kbps, depending on
the frequency band and modulation used.

• Medium Access Control (MAC) Layer: The MAC layer of IEEE 802.15.4
defines the rules for accessing the shared wireless medium. It includes
features like channel access mechanisms (based on Carrier Sense
Multiple Access with Collision Avoidance, CSMA-CA), frame structures,
addressing, and acknowledgment mechanisms.
IEEE 802.15.4 Protocol Stack
Features
1.The direct sequence spread spectrum (DSSS) modulation technique is used in
IEEE 802.15.4 for communication purposes, enabling a wider bandwidth of
operation with enhanced security by the modulating pseudo-random noise signal.
This standard exhibits high tolerance to noise and interference and offers better
measures for improving link reliability.
Direct Sequence Spread Spectrum (DSSS) is a modulation technique used in
wireless communication to improve the security, reliability, and resistance to
interference of data transmission.
In DSSS, the data signal is spread over a wider bandwidth than the original signal
by mixing it with a much higher bit rate pseudo-random noise (PN) sequence,
known as a spreading code.
DSSS
In DSSS, the sender and receiver agree on a specific spreading code,
which is a pseudo-random binary sequence. This code is used to
"spread" the original data signal by multiplying it with the code
sequence. The result is a signal that occupies a much larger
frequency band.
The original data signal is multiplied by the spreading code, bit by
bit. If the data bit is '1,' the code is left unchanged, but if the data bit
is '0,' the code is inverted. This process is called chip-level
modulation. As a result, the data signal is "spread out" over the
entire bandwidth.
2. The low-speed versions of the IEEE 802.15.4 standard use binary phase
shift keying (BPSK), whereas the versions with high data rate implement
offset quadrature phase shift keying (O-QPSK) for encoding the message
to be communicated.

In OQPSK, the key difference from standard QPSK is the introduction of a


phase offset of 90° between adjacent symbols. This means that the phase
transitions between symbols occur at points where the phase is either 90°
or 270°. This offset helps reduce the likelihood of abrupt phase changes,
which can lead to spectral spreading and interference.
CSMA -CA
Carrier sense multiple access with collision avoidance (CSMA-CA) is the
channel access method used for maintaining the sequence of transmitted
signals and preventing deadlocks due to multiple sources trying to access
the same channel.
Temporal multiplexing enables access to the same channel by multiple
users or nodes at different times in a maximally interference-free manner.
Carrier Sense Multiple Access with Collision Avoidance (CSMA/CA) is a
network protocol used in wireless communication systems to manage
access to a shared communication channel and avoid collisions between
multiple devices trying to transmit data simultaneously.
Devices using CSMA/CA listen to the communication channel to determine if it is currently in use.
Before attempting to transmit data, a device first checks for the presence of a carrier signal. If it
detects an ongoing transmission, it assumes the channel is busy and defers its transmission.

In CSMA/CA, before transmitting data, a device may send a short Request to Send (RTS) frame to
the intended recipient. If the recipient is ready to receive the data, it responds with a Clear to
Send (CTS) frame. This exchange helps ensure that the channel will be reserved for the upcoming
data transmission and reduces the chances of collision.

After sending a data frame, the sender expects to receive an acknowledgment (ACK) frame from
the recipient. If the sender doesn't receive an ACK within a certain timeframe, it assumes that a
collision occurred or that the data was not successfully received, prompting it to retransmit the
data.

To further reduce the possibility of collisions, CSMA/CA devices may introduce a random backoff
period after sensing that the channel is busy. This means that if a device detects the channel is
busy after attempting to transmit, it will wait for a random amount of time before retrying. This
randomization minimizes the likelihood of multiple devices retrying their transmissions
simultaneously.
Power Consumption
1 Low Duty Cycle Operation : Typically less than 1% . Remaining time
in sleep mode
2 Low Data Rate
3 MAC Layer efficient protocols
4 Sleep mode synchronizations
5 Beacon Mode
6 Energy efficient routing
7 Typical power consumption: 0.5 mW
8 Line of Sight transmission range varying from 10 m to 75 m
RFD and FFD
The IEEE 802.15.4 standard supports two types of devices:
1) reduced function device (RFD) and 2) full function devices (FFD).
FFDs can talk to all types of devices and support full protocol stacks.
However, these devices are costly and energy consuming due to
increased requirements for support of full stacks.
RFDs can only talk to an FFD and have lower power consumption
requirements due to minimal CPU/RAM requirements.
Discuss the following Terms:
1. Direct Sequence Spread Spectrum
2. Offset – QPSK
3. Carrier Sense Multiple Access – Collision Avoidance
4. FFD and RFD
IEEE 802.15.4 supported devices and N/W
IEEE 802.15.4 Network
The IEEE 802.15.4 standard supports two network types: 1) Beacon-
enabled networks and 2) non-beacon-enabled networks.
The periodic transmission of beacon messages characterizes beacon-
enabled networks. Here, the data frames sent via slotted CSMA/CA
with a super frame structure managed by a personal area network
(PAN) coordinator.
These beacons are used for synchronization and association of other
nodes with the coordinator. The scope of operation of this network
type spans the whole network.
Non-Beacon Enabled N/W
In contrast, for non-beacon-enabled networks, unslotted CSMA/CA
(contention based) is used for transmission of data frames, and
beacons are used only for link layer discovery.
This network typically requires both source and destination IDs of
the communicating nodes.
As the IEEE 802.15.4 is primarily a mesh protocol, all protocol
addressing must adhere to mesh configurations such that there is a
decentralized communication amongst nodes.
IEEE 802.15.4 Frame
Beacon frames are used for signaling and
synchronization;
Data transmission is done through the data
frames; and message reception is confirmed
using the acknowledgment frames.
MAC and command frames are used for
association requests/responses, dissociation
requests, data requests, beacon requests,
coordinator realignment, and orphan
notifications.
Explain IEEE 802.15.4 Network components.

What is Beacon Enabled Network?

Explain non-beacon enabled network.


ZigBee Protocol
ZigBee is a wireless communication protocol designed for
low-power, low-data-rate, and short-range applications in
the Internet of Things (IoT) and home automation
industries.
It was developed by the ZigBee Alliance, a consortium of
companies focused on creating open, global standards for
wireless communication.
Features
1.Low Power: ZigBee devices are designed to operate on very low power, making
them suitable for battery-operated devices and applications where energy
efficiency is crucial. Devices can operate for months or even years on a single
battery.
2.Low Data Rate: ZigBee is optimized for applications that require relatively small
amounts of data to be transmitted at low data rates. Typical data rates range
from 20 to 250 kbps, which is sufficient for many IoT and home automation
applications.
3.Short Range: ZigBee operates in the 2.4 GHz frequency band and has a typical
indoor range of about 10 to 250 meters, depending on the environment and
interference. It's well-suited for applications within a single room or a small
building.
Features
4. Mesh Networking: One of ZigBee's notable features is its support for mesh
networking. In a ZigBee mesh network, devices (nodes) can relay data for other
devices, extending the network's range and improving reliability. This self-
healing capability ensures that data can find multiple paths to its destination,
even if some nodes fail or are out of range.
5. Low Complexity: ZigBee is designed to be relatively simple and lightweight,
which is advantageous for resource-constrained devices. This simplicity helps
reduce the cost and power consumption of ZigBee chips.
6. Security: ZigBee provides several security features to protect data and
communication. It includes encryption and authentication mechanisms to ensure
the confidentiality and integrity of data exchanged between devices.
Features
7. Application Profiles: ZigBee supports different application profiles or
standards that define how ZigBee devices should behave in specific use cases.
For example, there are ZigBee profiles for smart home devices, industrial
automation, healthcare applications, and more. These profiles ensure
interoperability between devices from different manufacturers.
8. Standardization: ZigBee is an open standard, and the ZigBee Alliance
oversees its development and certification. This ensures that ZigBee devices from
different manufacturers can work together seamlessly.
9. Interoperability: ZigBee's focus on standardization and defined profiles
promotes interoperability, allowing devices from various manufacturers to
communicate and work together within the same network.
ZIGBEE PROMOTERS
ZigBee and Bluetooth Comparison

Optimized for different applications


◦ ZigBee
◦ Smaller packets over large network
◦ Mostly Static networks with many, infrequently used devices
◦ Home automation, toys, remote controls, etc.
◦ Bluetooth
◦ Larger packets over small network
◦ Ad‐hoc networks
◦ File transfer
◦ Screen graphics, pictures, hands-free audio, Mobile phones,
headsets, PDAs, etc.
ZigBee and Bluetooth Comparison
Feature(s) Bluetooth ZigBee
Power Profile days years
Complexity Complex Simple
Nodes/Master 7 64000
Latency 10 seconds 30 ms – 1s
Range 10m 70m ~ 300m
Extendibility No Yes
Data Rate 1 Mbps 250 Kbps
Security 64bit, 128bit 128bit AES and Application
Layer
Optimizes for Large packets over small Smaller packets over large
network network
ZigBee/IEEE 802.15.4 Stack Architecture

Application Customer

API
Security
32- / 64- / 128-bit encryption ZigBee
Alliance
Network
Star / Mesh / Cluster-Tree

MAC
IEEE
PHY 802.15.4
868MHz / 915MHz / 2.4GHz
802.15.4 PHY
Explain the main features of Zigbee Protocol.

What are the differences between Zigbee and Bluetooth?


IEEE 802.15.4 MAC Layer

Device Classes
Traffic Type
Full function device (FFD)
◦ Periodic data
◦ e.g. sensors Can function in any topology
◦ Intermittent data Capable of being Network coordinator
◦ e.g. light switch Can talk to any other device (FFD/RFD)
◦ Repetitive low latency data Reduced function device (RFD)
◦ e.g. mouse
Limited to star topology
Cannot become network coordinator
Talks only to FFDs
IEEE 802.15.4 MAC Layer

Frame Types Transmission Mode


◦ Data Frame Slotted (Beacon enable mode )
◦ used for all transfers of data Periodic data and Repetitive low latency data
Un-slotted (Non-Beacon enable mode)
◦ Beacon Frame Intermittent data
◦ used by a coordinator to transmit beacons
◦ Acknowledgment Frame
◦ used for confirming successful frame reception
◦ MAC Command Frame
◦ used for handling all MAC peer entity control transfers
802.15.4 – Network Topology
ZigBee Network Topologies
Star Topology
Mesh Topology
Advantage
Advantage
• Easy to synchronize
• Robust multihop communication
• Low latency Mesh
• Network is more flexible
Star • Lower latency
Disadvantage
Disadvantage
• Small scale
• Route discovery is costly
• Needs storage for routing table

Cluster Tree
Advantage
• Low routing cost
• Allow multihop communication
Cluster Tree PAN coordinator
Disadvantage
• Route reconstruction is costly Full Function Device
• Latency may be quite long Reduced Function Device
ZigBee Device Types
Security
•Zigbee provides three security mechanisms:
◦ Access Control Lists (ACL):Set of rules or permissions that determine what actions are
allowed or denied on a network or computer system
◦ 128-bit AES encryption: Advanced Encryption Standard-Same key for Encrypt and Decrypt
◦ Message freshness timers: Messages are up to date and not expired
•Multiple keys:
◦ Master key: The master key may be pre-installed by a manufacturer or entered by a manual
process with the user.
◦ Network key: This key will provide protection at a network level for outside attackers.
◦ Link key: This forms a secure binding between two devices
Zigbee uses 128-bit keys as part of its specification within the MAC and NWK layers.
Zigbee
• ZigBee is a technological standard designed for control and sensor networks
• Based on the IEEE 802.15.4 Standard
• Created by the ZigBee Alliance –
• Organization defining global standards for reliable, cost‐effective, low power
wireless applications

• A consortium of end users and solution providers,

• Developing applications and network capability utilizing the 802.15.4 packet


delivery mechanism
• Zigbee is proprietary and closed standard. It requires a licensing fee and agreement
provided by the Zigbee Alliance
Z- Wave
Z-wave
Z-Wave is a wireless communication protocol designed primarily for home
automation and Internet of Things (IoT) applications. It is a low-power, low-data-
rate, and mesh network technology that allows smart devices to communicate
with each other and with a central controller or hub.
• Zensys a Danish-American company founded in 1999 invented the Z-wave
technology.
• Mesh technology in the 900 MHz band.
• Efficiency of the Z-Wave Network is because of the Routing Protocol
• More than one Z-Wave Network can co-exist.
• A Z-Wave network can consist of 232 nodes to the max
• Approximately 600 companies and 2200 certified devices
Features
•Wireless Communication: Z-Wave operates on radio frequencies,
typically in the sub-1 GHz range (908.42 MHz in North America,
868.42 MHz in Europe). This lower frequency range allows for better
signal penetration through walls and obstacles compared to higher-
frequency protocols like Wi-Fi or Bluetooth.
•Mesh Network Topology: Z-Wave devices create a mesh network,
where each device (node) can act as a repeater for other devices
within the network. This mesh topology enhances the overall
network's range and reliability because data can hop from one node
to another until it reaches its intended destination.
Features
•Low Power Consumption: Z-Wave is designed for battery-operated
devices and devices that need to consume minimal power. This
ensures that battery life is extended, making it suitable for devices
like sensors and door locks that may operate for months on a single
set of batteries.
•Interoperability: Z-Wave Alliance, a consortium of companies,
oversees the development and certification of Z-Wave products. This
ensures that Z-Wave devices from different manufacturers can work
together seamlessly, fostering interoperability and a wide range of
product choices for consumers.
Features
• Security: Z-Wave includes several layers of security to protect the
network and its devices. This includes encryption for data transmitted
between devices, secure pairing of new devices to the network, and the
ability to lock down certain devices or actions through access control.
• Central Controller: A central controller, often referred to as a hub or
gateway, manages the Z-Wave network. The controller communicates
with all the devices in the network, enabling users to control and
automate them through a smartphone app or web interface.
• Device Classes: Z-Wave devices are categorized into classes based on
their primary functions. These classes include sensors, actuators (devices
that perform actions), controllers, and more. This categorization helps
with the proper integration and control of various devices.
Features
• Range: The effective range of Z-Wave devices can vary depending
on the specific product and the environment, but it typically extends
up to 100 meters (around 328 feet) between devices with direct
communication. However, as devices create a mesh network, they
can effectively extend the range.
• Frequent Updates: The Z-Wave Alliance periodically updates the Z-
Wave protocol to improve performance, security, and efficiency.
Newer iterations of the protocol may offer faster data rates and
increased reliability.
What is z-wave?

Discuss the main features of Z-Wave.


Comparison of ZigBee and Z-wave
ZigBee Z-Wave
Founded Union ZigBee Alliance Z-wave Alliance
Use of Band 2.4 GHz Sub 1GHz (900 MHz)
Operating Range Upto 250 meters Upto 100 meters
Data Rate Upto 250 kbps Upto 100 kbps
Encryption 128 bit AES 128 bit AES
Modulation O-QPSK GFSK
Max. Nodes 65000 232
GFSK Concept
GFSK enhances FSK by introducing
Gaussian filtering. Instead of abrupt
frequency transitions, GFSK uses a
Gaussian-shaped pulse to smoothly
transition between frequencies. This
filtering reduces the abrupt changes in
the signal and spreads the energy
across a broader frequency range.
Protocol Stack
Controller device: This top-level device provides the routing
table for the mesh network and is the host/master of the mesh under
Type of Nodes
it.

• Primary controller: The primary controller is the master, and


only a single master can exist in a network.
• It has the ability to maintain the network topology and
hierarchy.
• It can also include or exclude nodes from the topology.
• It allocates node IDs.
• Secondary controller: These nodes assist a primary
controller with routing.

Slave device/node:
• These devices perform actions based on commands they receive.
• These devices cannot communicate with neighbour slave nodes
unless instructed to do so via a command.
• Slaves can store routing information but do not compute or update
routing tables.
• Acts as a repeater in a mesh.
Z-Wave addressing
The addressing scheme is kept simple to minimize traffic
and conserve power.
There are two fundamental addressing identifiers:
• Home ID:
• This is a 32-bit unique identifier that is pre-
programmed in controller devices to assist with
identifying Z-Wave networks from each other.
• During network start, all Z-wave slaves have a
home ID of zero and the controller will
systematically populate the slave nodes with the
correct home ID.
• Node ID:
• This is an 8-bit value that is assigned to each slave
by the controller and provides addressing of slaves
in the Z-wave network.
Compare ZigBee an Z-wave.

How addressing is performed in Z-wave for Master and


Slaves?

What are the main application domains of Z-wave?


IP Based WPAN
IPv6: The Internet Protocol Version 6 or IPv6, as it is commonly known, is a
resultant of the developments on and beyond IPv4 due to fast depleting address
ranges in IPv4.
The IPv4 was not designed to handle the needs of the future Internet systems,
making it cumbersome and wasteful to use for IoT-based applications.
The needs of massive scalability and limited resources gave rise to IPv6, which
was developed by the IETF (Internet Engineering Task Force); it is also termed as
the Internet version 2
IPv6
Similar to IPv4, IPv6 also works on the OSI layer 3 (network layer).
•In contrast to IPv4 (which is 32 bits long and offers around
4,294,967,296 addresses), IPv6 has a massive logical address range
(which is 128 bits long).
•Additional features in IPv6 include auto-configuration features, end-
to-end connectivity, inbuilt security measures (IPSec), provision for
faster routing, support for mobility, and many others.
•IPv6 was designed entirely from scratch, it is partially backward
compatible; it cannot be made to support IPv4 applications directly.
Features
1. Expanded Address Space: The most prominent feature of IPv6 is its significantly
larger address space. IPv4 uses 32-bit addresses, allowing for roughly 4.3 billion unique
addresses. IPv6, on the other hand, uses 128-bit addresses, providing an astronomical
number of possible addresses (approximately 340 undecillion, or 3.4 × 10^38). This
expansion was necessary due to the increasing number of devices and the exhaustion
of available IPv4 addresses.
2. Efficient Addressing: IPv6 uses a simplified and more efficient addressing format
compared to IPv4. IPv6 addresses are expressed as eight groups of four hexadecimal
digits separated by colons (e.g., 2001:0db8:85a3:0000:0000:8a2e:0370:7334). To
improve readability, leading zeros within each group can be omitted, and contiguous
groups of zeros can be replaced with two colons (::) once in an address. This makes IPv6
addresses more concise and easier to manage.
Features
3. Autoconfiguration:IPv6 includes built-in support for stateless address
autoconfiguration. Devices can automatically generate their own IPv6 addresses based
on router advertisements, eliminating the need for manual IP address configuration or
DHCP (Dynamic Host Configuration Protocol) servers in many cases. This simplifies
network management.
4. Improved Security: IPv6 incorporates enhanced security features, including the use
of IPsec (Internet Protocol Security) as a fundamental part of the protocol suite. IPsec
provides authentication, integrity, and confidentiality for data transmitting over IPv6
networks, enhancing network security.
5. Multicast: IPv6 has native support for multicast communication, allowing efficient
one-to-many or many-to-many communication without the need for complex
workarounds or additional protocols.
Features
6. Simplified Header: IPv6 headers are simpler and more efficient than IPv4 headers.
They eliminate certain fields that were used infrequently and are designed to be
processed more quickly by routers, reducing overhead and improving network
performance.
7. Mobility Support: IPv6 includes features for better support of mobile devices and
seamless mobility across networks. Mobile IPv6 enables devices to maintain
connectivity while moving between different networks without losing their IP
addresses.
8. Transition Mechanisms: As IPv6 adoption has grown, various transition mechanisms
have been developed to facilitate coexistence with IPv4. These mechanisms allow IPv6-
only and IPv4-only devices to communicate with each other over mixed IPv4 and IPv6
networks.
What is IPv6 Protocol?

Discuss the main features of IPv6.


6LoWPAN
•6LoWPAN, which stands for "IPv6 over Low-Power Wireless Personal
Area Networks," is a communication protocol that enables the
transmission of IPv6 (Internet Protocol version 6) packets over low-
power wireless networks.
•It was specifically designed to allow low-power, resource-
constrained devices, such as sensors and actuators, to participate in
IPv6-based networks efficiently.
Features of 6LoWPAN
1. Low-Power Devices: 6LoWPAN is optimized for devices with limited
processing power, memory, and energy resources. These devices are
commonly found in applications like industrial automation, home
automation, healthcare, and environmental monitoring.

2. IPv6 Compatibility: 6LoWPAN extends the benefits of IPv6 to low-


power wireless networks, enabling these devices to use the same
addressing and communication protocols as traditional IPv6-enabled
devices on the Internet.
Features of 6LoWPAN
3. Header Compression: To reduce the overhead associated with
IPv6 packets, 6LoWPAN employs header compression techniques.
This allows for more efficient use of available bandwidth, which is
crucial in low-power wireless networks where bandwidth is often
limited.
4. Fragmentation and Reassembly: Due to the smaller packet size
constraints of low-power networks, 6LoWPAN includes mechanisms
for fragmenting and reassembling larger IPv6 packets into smaller
segments.
Features of 6LoWPAN
5. Mesh Networking: 6LoWPAN can be used to create wireless mesh
networks, where devices can relay data for each other, extending the
network's coverage and improving robustness. This is especially useful in
scenarios where direct communication between devices is challenging
due to distance or obstacles.
6. Autoconfiguration: 6LoWPAN devices can leverage IPv6's
autoconfiguration capabilities, allowing them to automatically acquire
IPv6 addresses and other network parameters without manual
configuration.
Features of 6LoWPAN
7. Interoperability: 6LoWPAN is designed to work with various low-
power wireless communication technologies, such as IEEE 802.15.4,
which is commonly used in wireless sensor networks. This enables
interoperability between different types of devices and networks.
8. Security: Security is a critical aspect of 6LoWPAN deployments. It
can be implemented by combining 6LoWPAN with security
mechanisms such as IEEE 802.15.4 security features, IPsec (Internet
Protocol Security), or other encryption and authentication protocols.
Features of 6LoWPAN
9. Application Support: 6LoWPAN can support a wide range of
applications, including environmental monitoring, smart homes, smart
cities, industrial automation, and healthcare. Its flexibility makes it
suitable for various IoT (Internet of Things) and M2M (Machine-to-
Machine) applications.
10. Standards and Working Groups: 6LoWPAN is defined and maintained
by the Internet Engineering Task Force (IETF) through various working
groups and related RFC (Request for Comments) documents, ensuring its
compatibility and interoperability with other internet protocols.
6LowPAN IPV6 over low power WPANs
6LoWPAN-Characteristics
1. Small packet size
2. Support for both 16-bit short or IEEE 64-bit extended media access
control addresses
3. Low bandwidth. Data rates of 250 kbps, 40 kbps, and 20 kbps for 2.4
GHz, 915 MHz, and 868 MHz, respectively
4. Topologies - star and mesh
5. Low power battery operated
6. Low cost
7. Large in numbers
8. Mobility support
9. Device may sleep for longer time
Features
• Efficient header compression - IPv6 base and extension
headers, UDP- User Datagram Protocol header
• Fragmentation - 1280 byte IPv6
• MTU(Max. Transmission Unit) -> 127 byte 802.15.4 frames
• Support for e.g. 64-bit and 16-bit 802.15.4 addressing
• Useful with low-power link layers such as IEEE 802.15.4,
narrowband ISM and power-line communications
• Network auto-configuration using neighbour discovery
• Unicast, multicast and broadcast support
• Support for use of link-layer mesh (e.g. 802.15.5)
What is 6LoWPAN?

Discuss the main features of 6LoWPAN.


• Router nodes (FFD): These nodes pass the data from one 6LoWPAN mesh node to
another and communicate outward to the WAN and internet.
• Host nodes (RFD): Hosts are endpoints in Mesh. They cannot route. Hosts are allowed
to be in sleep states, occasionally waking to produce data or receive data cached by
their parent routers.
• Edge routers: An edge router (also known as border router) has four functions:
1. Handles the communication to the 6LoWPAN devices and relays data to the
internet.
2. Performs compression of IPv6 headers by reducing a 40-byte IPv6 header and 8-
byte UDP headers for efficiency in a sensor network. A typical 40-byte IPv6 header
can compress to 2 to 20-bytes depending on usage.
3. Initiates the 6LoWPAN network.
4. Exchanges data between devices on the 6LoWPAN network.
Neighbor Discovery (ND)
Neighbor Discovery (ND) is a crucial process in networking that
allows devices within a network to identify and communicate with
their neighbors, which are other devices directly connected to the
same network segment.

In the context of 6LoWPAN (IPv6 over Low-Power Wireless Personal


Area Networks), Neighbor Discovery plays a fundamental role in
enabling efficient communication among constrained devices
Why ND?
Neighbor discovery is important for a number of reasons, including:

• Router discovery: Nodes need to be able to discover routers on the


network so that they can send and receive packets.
• Address resolution: Nodes need to be able to resolve the MAC addresses
of other nodes on the network so that they can communicate with them.
• Duplicate address detection: Nodes need to be able to detect and avoid
using duplicate IP addresses on the network.
Steps for ND
Neighbor discovery in 6LoWPAN is based on the following steps:
1. Router solicitation: A node sends a router solicitation (RS) message to the all-routers multicast
address. This message is used to request router advertisements from routers on the network.
2. Router advertisement: Routers respond to RS messages by sending router advertisement (RA)
messages to the all-nodes multicast address. RA messages contain information about the router, such as
its prefix, link MTU, and IPv6 address.
3. Neighbor solicitation: Nodes send neighbor solicitation (NS) messages to the IPv6 addresses of
other nodes on the network that they want to communicate with. NS messages are used to request
neighbor advertisements from the target nodes.
4. Neighbor advertisement: Target nodes respond to NS messages by sending neighbor
advertisement (NA) messages to the source node. NA messages contain information about the target
node, such as its MAC address and IPv6 address.
• Once a node has received an NA message from another node, it can establish a
communication channel with that node. Neighbor discovery is an ongoing process,
and nodes will continue to send and receive NS and NA messages to maintain their
neighbor caches.

• 6LoWPAN neighbor discovery has been optimized to address the constraints of


low-power wireless networks. For example, 6LoWPAN nodes do not send
multicast NS messages. Instead, they send unicast NS messages to the specific
nodes that they want to communicate with. This helps to conserve battery power.

• 6LoWPAN neighbor discovery is an important part of the 6LoWPAN protocol. It


allows nodes on a 6LoWPAN network to learn about each other and to establish
communication channels. This is essential for the successful operation of
6LoWPAN networks.
Neighbour discovery (ND) One hop routing protocol

ND is the process of discovering new neighbours, as a mesh can grow, shrink, and
transform, resulting in new and changing neighbour relations.
There are two basic processes and four basic message types in ND:
• Finding neighbours: Includes Neighbour Registration (NR) and Neighbour
Confirmation (NC) phases
• Finding routers: Includes Router Solicitation (RS) and Router Advertisement (RA)
phases
Explain Neighbour Discovery for 6LoWPAN protocol.
Header Compression
Header compression in 6LoWPAN is a technique that reduces the size of IPv6
headers before they are transmitted over the air. This is necessary because
low-power wireless networks typically have very small MTUs (Maximum
Transmission Units).
Header compression is a critical feature of 6LoWPAN (IPv6 over Low-Power
Wireless Personal Area Networks) that helps reduce the overhead associated
with transmitting IPv6 packets over low-power and low-bandwidth wireless
networks. Given the constrained nature of these networks, header
compression is essential to optimize the utilization of available resources.
6LoWPAN header compression works by exploiting the following properties of
IPv6 headers:

• Many of the fields in the IPv6 header are optional.

• Some of the fields in the IPv6 header can be inferred from other fields or from
the context of the communication.

• The values of some of the fields in the IPv6 header are often predictable.
• Motivation: The standard IPv6 header is 40 bytes in size, which is relatively large for networks with
constrained resources. In contrast, the typical IEEE 802.15.4 frame, commonly used in 6LoWPAN
networks, has a much smaller frame size, often around 127 bytes. Transmitting full-sized IPv6 packets
without compression would result in significant overhead and inefficient use of bandwidth.

• Context-based compression: 6LoWPAN header compression can exploit the context of the
communication to reduce the size of the IPv6 header. For example, if the source and destination
addresses have already been exchanged in previous messages, then the source and destination
addresses can be compressed.
• There are two main header compression formats defined in 6LoWPAN: LOWPAN_HC1 and
LOWPAN_HC2.
1. LOWPAN_HC1: This format is designed for scenarios where the source and destination are part of the
same 6LoWPAN network and share a common prefix. It compresses the IPv6 header down to as few as
two bytes.
2. LOWPAN_HC2: LOWPAN_HC2 is used when the source and destination devices do not share a
common prefix. It provides a more general-purpose compression mechanism and is slightly less efficient
than HC1 but works in a wider range of network topologies.
Fragmentation and Reassembly: When header compression is applied to an IPv6
packet, it is important to note that the size of the compressed packet might still
exceed the maximum frame size supported by the wireless network. In such cases, the
packet is fragmented into smaller fragments that fit within the frame size. Header
compression is applied separately to each fragment. The receiving end reassembles
the fragments and decompresses the headers to reconstruct the original IPv6 packet.

Compression State Management: In header compression, both sender and receiver


maintain compression state information. This state includes context information,
sequence numbers, and compression dictionaries. The sender and receiver use this
state to correctly compress and decompress headers.
Header Compression
• 6LoWPAN = IPv6 on an 802.15.4 link
• IPv6 has a Maximum Transmission Unit
(MTU) size of 1280 bytes, while 802.15.4
has a limit of 127 bytes
• Header compression in IPV6 is a means to
compress and remove redundancy in
• But not suitable for a mesh network such
• as 6LoWPAN
• Packets hop between nodes and would
require compression/decompression
on each hop.
• The routes are dynamic and allowed to
change and transmissions may not be
present for long duration.
• 6LoWPAN adopted stateless and shared-
context compression
Header compression:
• By assuming usage of common values
• From 802.15.4 frame or based on simple assumptions of shared context.
• 40Bytes of IPv6 header are compressed into 2 Bytes of 6LowPAN header.
Fragmentation:
• IPv6 packets are fragmented into multiple link-level frames to accommodate the IPv6
minimum MTU requirement.
• 1280 Bytes of IPv6 frame (minimum IPv6 MTU) have been fragmented to 127Bytes, which is the 802.15.4
MTU.
Explain Header Compression for 6LoWPAN protocol.
WPAN – IP Thread
An industry-wide IPv6 protocol suite for IoT
• The Thread IoT protocol is an IP-
based wireless mesh network
for the home and connected
products.
• Utilising a mesh network means
there’s no single point of failure.
• Uses 6LoWPAN, which in turn
uses the IEEE 802.15.4 wireless
protocol
• Thread is IP-addressable, with
cloud access and AES encryption.
WPAN – IP Thread
•Open standard protocol – Thread is an IP based wireless networking
protocol. It carries IPv6 packets natively through 6LowPAN.
•Simple for consumers to use – The installation of a Thread network is
simple and intuitive for users. Users can add, authorize and remove
devices onto the network using smart phones or computers through a few
simple steps.
•Secure – Thread networks are secure and encrypted. Thread uses
smartphone-era authentication schemes and AES encryption to close
security holes that exist in other wireless protocols. Only authorized
devices can join the network.
WPAN – IP Thread
•Power-efficient – Thread is designed to be battery friendly and requires
very little energy to operate. Devices efficiently communicate to deliver
a great user experience, yet still run for years on the smallest of
batteries.
•No single point of failure - Devices working in a Thread network create
a mesh. This provides resiliency and removes any single point of failure.
•Designed to support a wide variety of products for the home:
appliances, access control, climate control, energy management, safety,
and security
REED WPAN – IP Thread
Border Router: Connects the Thread Router: Responsible for
network to Internet and other adjacent providing joining, routing
networks. May also be responsible for and security services in the
commissioning and router management. network.

Router Enabled End Devices (REED): Non-


routers in the network who behave as end
devices and are hardware-capable of
upgrading to Routers when required by the
network

Leader: The single distinguished device in any


Thread Network Partition that currently acts as a
central arbiter of network configuration state.
Thread Network Architecture

You might also like