4972 Note IOT Module 2
4972 Note IOT Module 2
Communication module
BLUETOOTH
Uses spread spectrum hopping, full‐duplex signal at a nominal rate of 1600 hops/sec.
Bluetooth supports 1Mbps data rate for version 1.2 and 3Mbps data rate for Version 2.0 combined with
Error Data Rate.
Class 1 radios are used primarily in industrial use cases have a range of 100 meters or 300 feet.
Class 2 radios are most commonly found in mobile devices have a range of 10 meters or 30 feet
Connection Establishment
In terms of connection establishment using Bluetooth there are 3 different phases. The first one is the
discovery or the inquiry phase. The next one is the paging phase, and the third one is the connection
phase.
Inquiry: Inquiry run by one Bluetooth device to try to discover other devices near it.
Paging: Process of forming a connection between two Bluetooth devices. It may involve security
mechanisms like PIN entry or key exchange. After pairing, the devices can bond, meaning they save the
encryption keys for future connections without the need for re-pairing.
Connection: A device either actively participates in the network or enters a low‐power sleep mode.
There are different modes of operation of Bluetooth devices, one is the active mode and this is the
mode where the device basically is fully active fully functional in all different respects it actively
transmits is data it actively receives data and so on and so forth.
The other 3 phases the sniff mode the hold mode and the park mode all these 3 different modes are
basically power saving modes.
In a sniff mode the device basically sleeps and only listens for transmission at a particular predefined
interval.
In the hold mode, a device sleeps for a defined period and then returns back to the active mode and in
the park mode the slave will become inactive until the master tells it to wake back up.
The standard defines a general Bluetooth stack divided into layers and sublayers . Each layer
implements a set of related functions necessary for the layer immediately above and uses the
functions implemented by the directly lower layer. Thus, the lower layers i mplement low-level
functions like hardware interaction, while the higher layers implement functions closer to the user
application, such as managing device discovery, making connections, etc.
The physical layer in a Bluetooth connection is responsible for the actual data transmission
through the communication medium, i.e., the air. This layer defines aspects related to signal
modulation, operating frequencies, and radiofrequency spectrum management. Its main function
is to establish and maintain the physical link between Bluetooth devices, allowing the transfer of
data bits through radio waves.
Baseband Layer: It manages physical channels and links and different services such as error correction
etc.
Logical Link Control and Adaptation Protocol (L2CAP) − L2CAP provides adaption between upper layer
frame and baseband layer frame format. L2CAP provides support for both connection-oriented as well
as connectionless services. It is a layer within the Bluetooth protocol stack that allows multiple logical
channels (connections) to be established between two devices. It manages the segmentation and
reassembly of data packets, and it supports multiplexing, enabling multiple higher-layer protocols to
run concurrently over the same physical Bluetooth link.
Radio frequency communication protocol: RF Comm is basically to replace the serial cables. RF Comm
it works as an emulation of the RS-232 (Recommended Standard 232) which is presently known as EIA 232.
It is a serial port communication protocol. It provides a simple reliable data stream to the user very
similar to TCP and supports up to sixty simultaneous connections between 2 Bluetooth devices.
Service Discovery Protocol (SDP): It is a crucial part of the Bluetooth protocol stack that enables
Bluetooth devices to discover what services are available on nearby devices and to find out the
characteristics of those services. Each service in a Bluetooth device is described by a set of attributes,
such as the service name, service class, and the protocols it supports. These attributes are used by SDP
to describe and identify services.
Bluetooth Classic:
Bluetooth Classic is designed for applications that require continuous, high-bandwidth data transfer.
Wireless Audio Streaming: Bluetooth Classic is widely used in devices like Bluetooth headphones,
speakers, and hands-free car systems for continuous audio streaming using profiles like A2DP
(Advanced Audio Distribution Profile).
File Transfers: Suitable for sending large amounts of data over Bluetooth, such as transferring files
between smartphones, laptops, or tablets. Devices using Bluetooth Classic (e.g., headphones, speakers)
typically need to be recharged after several hours of use because of the constant data flow and power
draw.
➢ Shorter Connection Times: BLE devices establish connections quickly and only transmit when
needed, reducing the time they spend active.
➢ Sleep Mode: BLE devices spend most of their time in low-power sleep modes, only waking up
to transmit small data packets.
Zigbee
ZigBee protocol which is heavily used for IoT applications for establishing connectivity between the
different nodes. Most widely deployed enhancement of IEEE 802.15.4. The ZigBee protocol is defined
by layer 3 and above. It works with the 802.15.4 layers 1 and 2. The standard uses layers 3 and 4 to
define additional communication enhancements.
These enhancements include authentication with valid nodes, encryption for security, and a data
routing and forwarding capability that enables mesh networking. ZigBee solutions are aimed at smart
objects and sensors that have low bandwidth and low power needs.
• Low Data Rate (20- 250 kbps)
• Short-Range (75-100 meters)
• 3 frequency bands with 27 channels.
Operating Frequency Bands (Only one channel will be selected for use in a network):
1. Channel 0: 868 MHz (Europe)
2. Channel 1-10: 915 MHz (the US and Australia)
3. Channel 11-26: 2.4 GHz (Across the World)
• Physical layer: The lowest two layers i.e the physical and the MAC (Medium Access
Control) Layer are defined by the IEEE 802.15.4 specifications. The Physical layer is closest
to the hardware and directly controls and communicates with the Zigbee radio. The
physical layer translates the data packets in the over-the-air bits for transmission and vice-
versa during the reception.
• Medium Access Control layer (MAC layer): The layer is responsible for the interface
between the physical and network layer. The MAC layer is also responsible for providing
PAN ID and also network discovery through beacon requests.
• Network layer: This layer acts as an interface between the MAC layer and the application
layer. It is responsible for mesh networking.
• Application layer: The application layer in the Zigbee stack is the highest protocol layer
and it consists of the application support sub-layer and Zigbee device object. It contains
manufacturer-defined applications.
The ZigBee specification supports star and two kinds of peer-to-peer topologies, mesh and cluster
tree. ZigBee-compliant devices are sometimes specified as supporting point-to-point and point-to-
multipoint topologies. The ZigBee specification supports star and two kinds of peer-to-peer
topologies, mesh and cluster tree. ZigBee-compliant devices are sometimes specified as supporting
point-to-point and point-to-multipoint topologies.
• Zigbee Coordinator Device: The Coordinator creates the Zigbee network by selecting the network
channel and network PAN (Personal Area Network) ID. It starts the network and handles the initial
network setup. It communicates with routers. This device is used for connecting the devices.
The coordinator can handle the initial security setup for the network, including encryption keys.
• Zigbee Router: The Router extends the range and capacity of the Zigbee network by relaying data
between devices and facilitating communication between them. It is used for passing the data
between devices.
• Star Topology (ZigBee Smart Energy): Consists of a coordinator and several end devices,
end devices communicate only with the coordinator.
• Mesh Topology (Self Healing Process): Mesh topology consists of one coordinator, several
routers, and end devices.
• Tree Topology: In this topology, the network consists of a central node which is a
coordinator, several routers, and end devices. the function of the router is to extend the
network coverage.
Zigbee Topologies
2024-25 Prepared by: Faculty of CSE-CSDS Department ( Brainware University, Barasat)
BRAINWARE UNIVERSITY
[ESCD 301] CLASS NOTES [Internet of Things]
Disadvantages of Zigbee:
1. Limited range: Zigbee has a relatively short range compared to other wireless
communications protocols, which can make it less suitable for certain types of applications
or for use in large buildings.
2. Limited data rate: Zigbee is designed for low-data-rate applications, which can make it less
suitable for applications that require high-speed data transfer.
3. Interoperability: Zigbee is not as widely adopted as other IoT protocols, which can make
it difficult to find devices that are compatible with each other.
4. Security: Zigbee’s security features are not as robust as other IoT protocols, making it more
vulnerable to hacking and other security threats.
WiFi
WiFi, or Wireless Fidelity, is a technology that allows devices to connect to the internet
wirelessly. In IoT, WiFi is commonly used for devices that require high data rates and constant
connectivity. Smart home devices like cameras, thermostats, and appliances often use WiFi to
communicate with cloud services, providing users with remote access and control.
One of its main advantages is its high data transfer rate, which supports applications that
require large amounts of data, such as video streaming from security cameras. This high throughput
ensures that IoT devices can transmit and receive data quickly and efficiently, essential for real-time
applications.
Additionally, WiFi’s widespread availability and compatibility with existing network
infrastructure make it easy to deploy and scale. Most homes and businesses already have WiFi
networks in place, allowing new IoT devices to integrate seamlessly without the need for additional
hardware. This reduces deployment costs and simplifies the process of expanding IoT networks as
needed.
Another significant benefit of WiFi is its extensive range, allowing devices to connect over
relatively long distances within a home or office environment. This makes it suitable for various
applications, from home automation, where devices like smart thermostats and security systems
need reliable connectivity, to industrial monitoring, where sensors and actuators spread across a
large area require consistent communication.
It outlines the architecture and defines the MAC and physical layer specifications for wireless LANs
(WLANs). Wi-Fi utilizes the 2.4 gigahertz (120 mm) UHF (Ultra High Frequency) and 5 gigahertz (60 mm)
SHF (Super High Frequency) radio bands. The latest version of Wi-Fi also known as 802.11ax, this version
of Wi-Fi has a theoretical maximum throughput of 9.6 Gbps across multiple channels.
Stations: Stations are components that connect to the network wirelessly. Stations are either access
2024-25 Prepared by: Faculty of CSE-CSDS Department ( Brainware University, Barasat)
BRAINWARE UNIVERSITY
[ESCD 301] CLASS NOTES [Internet of Things]
points or endpoints, and each is identified by a unique network address.
Access point: The access point is the base station that serves as a hub to which other stations connect.
The "access" is that of the stations to the network. But it may also mean internet access, since many
routers double as internet modems.
Endpoint: The endpoint is any end-user station, such as a computer, mobile device, printer, or Internet
of Things (IoT) device.
BSS Architecture
ESS Architecture
The 802.11 Distributed Coordination Function (DCF) is a fundamental mechanism in the IEEE 802.11
wireless networking standard used to manage access to the shared communication medium (the
wireless channel).
The Global Positioning System (GPS) is a navigation system that allows users to determine their exact
location on the earth's surface. The development of GPS began in the 1970s when the United States
Department of Defense recognized the need for a reliable navigation system for military purposes. GPS
was made available to civilians in 1993 and has since become a ubiquitous technology used in many
aspects of daily life.
Basic Principles
GPS works by using a network of satellites orbiting the Earth to determine the location of a GPS receiver
on the ground. The GPS receiver sends a signal to one of the GPS satellites, which then transmits a signal
back to the receiver. By measuring the time it takes for the signal to travel from the satellite to the
receiver, the GPS receiver can calculate the distance between the two.
GPS receivers need to receive signals from at least four GPS satellites to determine their location
accurately.
These are the satellites in space circling the Earth every 12 hours. The space segment mainly does two
things:
• A GPS system consists of a network of 24 orbiting satellites, called NAVSTAR (Navigation System
with Time and Ranging), and placed in space in six different orbital paths with four satellites in
each orbital plane and covering the entire earth under their signal beams.
There are one master control station and 5 monitor stations which form the GPC control segment. The
monitor stations monitor the signals from satellites. Then the qualified signals are sent to the master
station that revises the abnormalities and checks the operational specifications before sending the
revised signals back to the satellites.
This forms all the GPS receivers like mobile phones, PCs, laptops and other devices that receive GPS
signals and determines its distance from each satellite.
The GPS satellite constellation comprises up to 24 satellites orbiting the earth at an altitude of
approximately 20200 km. The satellites are positioned so that they cover the entire planet, ensuring
that GPS signals are available anywhere in the world.
The GPS satellites are powered by solar panels and are equipped with atomic clocks that provide highly
accurate timing information. The satellites continually transmit navigation signals that can be received
by GPS receivers on the ground.
The integration of GPS with IoT can help organizations to optimize their operations and simplify complex
processes, reducing downtime and increasing efficiency. Tracking vehicles in real-time can reduce
transport time, simplify logistical planning, and optimize delivery schedules.
Despite the benefits of GPS-enabled IoT devices, there are also challenges and limitations that need to
Application
GPS technology in wearable devices, such as smartwatches and fitness trackers, can track personal
health and activity data. The accurate location information can enable people to monitor exercise
routines, sleep patterns, and nutrition, leading to better health outcomes.
GPS technology is widely used in many transportation and logistics applications, such as tracking cargo
shipments and optimizing distribution routes in real-time. Fleet managers can monitor and analyze
vehicle performance, fuel consumption, and driver data. This information helps them to increase
operational efficiency, reduce costs, and improve safety.
GPS technology is also useful in precision agriculture and environmental monitoring. GPS receivers on
drones, for instance, allow farmers to collect data on crop growth and soil conditions, improving yields
and reducing costs. The technology can also be used to monitor environmental factors such as water
levels and air or water quality, allowing for informed conservation and sustainability practices.
IPv6
Internet Protocol version 6 (IPv6) is also known as Internet Protocol next generation. It also
accommodates more feature to meet the global requirement of growing Internet.
The explosive growth of IoT has illuminated the inherent constraints of IPv4, the foundational internet
protocol that has underpinned the digital landscape for decades. As billions of devices ranging from
smart appliances and wearable gadgets to industrial sensors and autonomous vehicles seek
connectivity, the available quantity of IPv4 addresses nears depletion. This scarcity not only escalates
the costs associated with acquiring and managing IP addresses but also complicates network
configurations and hampers scalability efforts.
QoS methods help ensure that certain bandwidth, latency, jitter etc. are satisfied, allowing for seamless
and reliable communication.
The most salient feature of IPv6 is its expansive address space, characterized by a 128-bit address
format. It can accommodate an astronomical number of unique IP addresses.
IoT ecosystem security continues to be a top priority in a time of growing cyber threats. Recognizing
this imperative, IPv6 incorporates a suite of advanced security features
These include built-in support for IPsec (Internet Protocol Security), facilitating end-to-end encryption
and authentication, thereby mitigating risks associated with data interception, tampering, and
unauthorized access.
IPv6’s simplified network configuration mechanisms emerge as a pivotal enabler, facilitating seamless
integration and management of heterogeneous IoT ecosystems.
With plug-and-play capabilities, IPv6 simplifies the deployment process, reduces administrative
overheads, and fosters interoperability across disparate IoT platforms and protocols.
To allocate a sufficient number of network address, IPv6 allows 128 bits of IP address separated into 8
sections of 2 bytes each. IPv6 uses hexadecimal numbers and colon (“:”) is used as a delimiter between
the sections.
Version: This field is 4 bits long and it defines the version of the IP packet. The value of it for IPv6 is 6
Traffic Class: The Traffic Class field indicates class or priority of IPv6 packet which is similar to Service
Field in IPv4 packet. It helps routers to handle the traffic based on the priority of the packet. If
congestion occurs on the router, then packets with the least priority will be discarded.
Flow Label: The flow label in IPv6 is a mechanism for identifying a sequence of packets, or flow, that
are sent from a source to a destination. This field is 20 bits long and it is used to allow the source and
destination nodes to set up a pseudo connection with particular properties and requirements.
Payload Length (16-bits)
It is a 16-bit (unsigned integer) field, indicates the total size of the payload which tells routers about
the amount of information a particular packet contains in its payload.
Next Header (8-bits)
Next Header indicates the type of extension header (if present) immediately following the IPv6
header.
Hop Limit (8-bits)
It indicates the maximum number of intermediate nodes IPv6 packet is allowed to travel. Its value gets
decremented by one, by each node that forwards the packet and the packet is discarded if the value
decrements to 0.
Source Address (128-bits)
Source Address is the 128-bit IPv6 address of the original source of the packet.
Destination Address (128-bits)
The destination Address field indicates the IPv6 address of the final destination (in most cases).
Extension Headers
The next Header field of IPv6 fixed header points to the first Extension Header and this first extension
header points to the second extension header and so on. There are be one or more of the six possible
extension headers. Extension headers help network devices like routers and switches process and
direct IPv6 packets. The Authentication and Encapsulating Security Payload Headers are extension
headers that secure IP communication between hosts.
6LoWPAN
6LoWPAN stands for IPv6 over Low-Power Wireless Personal Area Networks. It’s a communication
protocol designed to enable small, low-power devices to connect over wireless networks. This
protocol works on a Wireless Personal Area Network. It has very low cost, short-range, low memory
usage, and low bit rate. It comprises an Edge Router and Sensor Nodes. Even the smallest of the IoT
devices can now be part of the network, and the information can be transmitted to the outside world
as well. For example, LED Streetlights.
RPL
RPL stands for Routing Protocol for Low Power and Lossy Networks (LLN) for heterogeneous traffic
networks. LLNs are networks composed of low-power and lossy links, making it difficult for traditional
routing protocols to operate effectively. RPL allows devices within an LLN to communicate with each
other efficiently while also minimizing power consumption. By using RPL, devices can send messages
across multiple nodes in the network without relying on any one specific device as a central hub. This
function helps balance energy consumption and spread-out processing efforts among all devices in
the network, thereby reducing the risk of system overload or failure due to heavy traffic loads.
Features of RPL
• Multipoint-to-point traffic − RPL provides a mechanism for data transmission from multiple
devices inside the LLN to a single destination point.
• Scalability − The protocol is designed to support large-scale networks with low power and lossy
links, making it suitable for various IoT applications.
• Energy efficiency − RPL minimizes energy consumption by choosing the most optimal path and
effectively managing network resources.
• Quality of Service (QoS) − The protocol ensures QoS by providing congestion control
mechanisms and packet delivery reliability.
• Security − RPL includes authentication, confidentiality, integrity protection, and encryption
mechanisms to ensure secure communication within the LLN.
Working of RPL
RPL organizes the network into a Destination Oriented Directed Acyclic Graph (DODAG), which is a
tree-like structure rooted at one or more sink nodes. RPL uses objective functions to determine the best
paths through the network. These functions can optimize for different metrics such as hop count,
energy consumption, or link reliability. ach node in the network has a "rank" that indicates its position
relative to the root. To minimize control message overhead, RPL employs the Trickle algorithm. If a link
fails or becomes unreliable, the protocol can dynamically reorganize the DODAG by selecting alternate
parents or adjusting ranks, allowing the network to recover without significant disruptions.
CoAP
The Constrained Application Protocol (CoAP) is a special web transfer protocol that operates with
constrained nodes and networks. CoAP or Constrained Application Protocol, as the name suggests, is
an application layer protocol that was introduced by the Internet Engineering Task Force in the year
2014. It is a web-based protocol that resembles HTTP. It is also based on the request-response
model. CoAP supports several methods similar to HTTP:
o GET
o POST
o DELETE
o PUT
2024-25 Prepared by: Faculty of CSE-CSDS Department ( Brainware University, Barasat)
BRAINWARE UNIVERSITY
[ESCD 301] CLASS NOTES [Internet of Things]
The CoAP protocol’s built-in discovery mechanism allows devices to discover resources on other
devices without requiring any prior knowledge of their existence. This is especially useful in IoT
networks, where devices may be constantly joining and leaving the network.
CoAP supports asynchronous message exchanges, which is crucial for IoT networks where devices
may not always be connected or available. With asynchronous message exchanges, a device can send
a request to another device and then continue with other tasks without waiting for a response. The
response can be processed once it arrives, even if delayed.
CoAP offers optional reliability through the use of confirmable messages. When a device sends a
confirmable message, it expects an acknowledgment from the recipient. If no acknowledgment is
received within a certain time, the message is retransmitted.
The CoAP protocol operates over UDP (User Datagram Protocol). In stateless communication, each
request from a client to a server is processed independently, without any knowledge of the previous
requests. CoAP is suitable for real-time applications, as it provides low-latency communication, CoAP
follows a RESTful architecture. CoAP includes support for DTLS (Datagram Transport Layer Security)
which provides security features like encryption, authentication, and integrity protection.
MQTT
MQTT stands for Message Queuing Telemetry Transport. MQTT is a machine-to-machine internet of
things connectivity protocol. It is an extremely lightweight and publish-subscribe messaging transport
protocol.
Wired Communication
The wired communication is divided into two categories:
Internal Communication:
1. I2C
2. SPI
External Communication
1. Ethernet
2. RS-232
3. RS-485
4. UART
5. USART
6. USB
Ethernet Protocol Architecture
Ethernet is a widely used technology for local area networks (LANs) that enables devices to
communicate with each other by transmitting and receiving data over a wired connection. It operates
at the data link layer (Layer 2) and physical layer (Layer 1) of the OSI model and has evolved to support
high-speed data transfer, making it fundamental to modern networking.
Frames: Ethernet transmits data in small units called frames. Each frame contains a source and
destination MAC address, data payload, and error-checking information (Cyclic Redundancy Check -
2024-25 Prepared by: Faculty of CSE-CSDS Department ( Brainware University, Barasat)
BRAINWARE UNIVERSITY
[ESCD 301] CLASS NOTES [Internet of Things]
CRC).
Media Access Control (MAC): • Every device on an Ethernet network is identified by a unique MAC
address, a 48-bit hardware address assigned to network interface cards (NICs) at the time of manufacture.
The MAC address is used for identifying devices and routing data between them within the network.
Ethernet follows the CSMA/CD (Carrier Sense Multiple Access/Collision Detection) protocol to manage
access to the shared medium. Devices listen for a clear network before sending data to avoid collisions.
If a collision occurs, devices wait for a random period before retransmitting.
Ethernet Standards: Ethernet comes in different standards for varying speeds, such as:
o Ethernet (10 Mbps)
o Fast Ethernet (100 Mbps)
o Gigabit Ethernet (1 Gbps)
o 10 Gigabit Ethernet (10 Gbps)
Physical Layer: Ethernet uses different types of cables, including twisted-pair cables (Cat5, Cat6) for
shorter distances and fiber-optic cables for long-distance communication. The physical layer (PHY) in
Ethernet refers to the hardware responsible for transmitting and receiving raw data over the network
medium. It manages the modulation, encoding, and physical signaling.
Switches and Hubs: Ethernet networks use switches and hubs to manage the flow of data. Switches
intelligently route data to the correct device using MAC address, while hubs broadcast the data to all
connected devices, increasing the chances of collisions in older networks.
Modern Ethernet supports full-duplex communication, allowing data to be sent and received
simultaneously.