0% found this document useful (0 votes)
178 views37 pages

Ch-2 Hardware For IoT

Very help full doc

Uploaded by

Patil Mangesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
178 views37 pages

Ch-2 Hardware For IoT

Very help full doc

Uploaded by

Patil Mangesh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 37

CS-603-MJ :Internet of Things

M.Sc. Computer Science-II (From 2024-25, NEP) Semester-III

Dr. Jagdish Sangvikar


PG Co-ordinator
Department of Computer Science
VPASC College, Baramati
Chapter – 2 Hardware for IoT

Syllabus

2.1 Sensors, Digital sensors, actuators, wireless sensor networks, participatory


sensing technology.

2.2 IOT Protocol: MQTT, CoAP, XMPP.

2.3 Embedded Platforms for IoT: Embedded computing basics(block diagram),


Overview of IOT supported Hardware platforms such as Arduino, Raspberry pi.
Sensor
Sensor is a device used for the conversion of physical events or characteristics into the
electrical signals. This is a hardware device that takes the input from environment and
gives to the system by converting it. For example, a thermometer takes the temperature
as physical characteristic and then converts it into electrical signals for the system.

Types of Sensors
•Temperature Sensors: Take temperatures.
•Light Sensors: Light intensity sensors: It has the function of detecting the intensity of
the light.
•Pressure Sensors: To use it to measure pressure in gases or liquids.
•Motion Sensors: Recognize motion in an established region.

Light Sensor
A digital sensor
A digital sensor is a device that measures a physical quantity (such as temperature,
pressure, light, or humidity) and then quantizes that measurement into a digital form.
In other words, it takes analog physical data and converts it into discrete digital values,
often in the form of binary code (0s and 1s).

Figure showing the Digital


Sensor Design and Assembly.
Actuator

Actuator is a device that converts the electrical signals into the physical events or
characteristics. It takes the input from the system and gives output to the environment.
For example, motors and heaters are some of the commonly used actuators.

Types of Actuators
•Linear Actuators: Utilize a linear motion to convert energy, Kinetic/pendulum.
•Rotary Actuators: This will affect the creation of rotational motion.
•Hydraulic Actuators: How does fluid power gives motion.
•Pneumatic Actuators: Function with use of compressed air.
Fig. Function of Actuator

Figure of Actuator
Wireless Sensor Network (WSN), is an infrastructure-less wireless network that is
deployed in a large number of wireless sensors in an ad-hoc manner that is used to
monitor the system, physical, or environmental conditions.

Sensor nodes are used in WSN with the onboard processor that manages and monitors
the environment in a particular area. They are connected to the Base Station which acts
as a processing unit in the WSN System. The base Station in a WSN System is connected
through the Internet to share data. WSN can be used for processing, analysis, storage,
and mining of the data.

Fig. Wireless Sensor


Network
Wireless Sensor Network Architecture

A Wireless Sensor Network (WSN) architecture is structured into three main layers:
•Physical Layer: This layer connects sensor nodes to the base station using technologies
like radio waves, infrared, or Bluetooth. It ensures the physical communication between
nodes and the base station.

•Data Link Layer: Responsible for establishing a reliable connection between sensor
nodes and the base station. It uses protocols such as IEEE 802.15.4 to manage data
transmission and ensure efficient communication within the network.

•Application Layer: Enables sensor nodes to communicate specific data to the base
station. It uses protocols like ZigBee to define how data is formatted, transmitted, and
received, supporting various applications such as environmental monitoring or
industrial control.
WSN Network Topologies
Wireless Sensor Networks (WSNs) can be organized into different network topologies
based on their application and network type. Here are the most common types:
•Bus Topology: In a Bus Topology, multiple nodes are connected to a single line or bus.
Data travels along this bus from one node to the next. It’s a simple layout often used in
smaller networks.
•StarTopology: Star Topology have a central node, called the master node, which
connects directly to multiple other nodes. Data flows from the master node to the
connected nodes. This topology is efficient for centralized control.
•Tree Topology: Tree Topology arrange nodes in a hierarchical structure resembling a
tree. Data is transmitted from one node to another along the branches of the tree.
•Mesh Topology: Mesh Topology feature nodes interconnected with one another,
forming a mesh-like structure. Data can travel through multiple paths from one node to
another until it reaches its destination.
Types of Wireless Sensor Networks (WSN)

Terrestrial Wireless Sensor Networks


•Used for efficient communication between base stations.
•Consist of thousands of nodes placed in an ad hoc (random) or structured (planned)
manner.
•Nodes may use solar cells for energy efficiency.
•Focus on low energy use and optimal routing for efficiency.

Underground Wireless Sensor Networks


•Nodes are buried underground to monitor underground conditions.
•Require additional sink nodes above ground for data transmission.
•Face challenges like high installation and maintenance costs.
•Limited battery life and difficulty in recharging due to underground setup.
Underwater Wireless Sensor Networks
•Deployed in water environments using sensor nodes
•Face challenges like slow data transmission, bandwidth limitations, signal attenuation.
•Nodes have restricted and non-rechargeable power sources.

Multimedia Wireless Sensor Networks


•Used to monitor multimedia events such as video, audio, and images.
•Nodes equipped with microphones and cameras for data capture.
•Challenges include high power consumption, large bandwidth requirements, and
complex data processing.
•Designed for efficient wireless data compression and transmission.

Mobile Wireless Sensor Networks (MWSNs)


•Composed of mobile sensor nodes capable of independent movement.
•Offer advantages like increased coverage area, energy efficiency, and channel capacity
compared to static networks.
•Nodes can sense, compute, and communicate while moving in the environment.
Participatory Sensing Technology

A web source defines Participatory Sensing (PS) as “sensing by the individuals and
groups of people contributing sensory information to form a body of knowledge”.

“Participatory sensing is the process whereby individuals and communities use


evermore-capable mobile phones and cloud services to collect and analyze systematic
data for use in discovery.”

A participant of a PS process can be sensors used in mobile phones.


Mobile phones have camera, temperature and humidity sensors, an accelerometer, a
gyroscope, a compass, infrared sensors, NFC sensors, bar or QR code readers,
microphone and GPS.
Mobiles communicate on the Internet the sensed information with time, date and
location stamps.
Applications of PS include retrieving information about weather, environment
information, pollution, waste management, road faults, health of individuals and group of
people, traffic congestion, urban mobility, or disaster management, such as flood, fire, etc.
Participatory sensing has many challenges such as—security, privacy, reputation and
ineffective incentives to participating entities.

How It Works
1.Data Collection: Users employ their devices to gather various types of data. This can
include environmental data (e.g., air quality, temperature), behavioral data (e.g., location,
activity levels), or subjective data (e.g., user surveys, photos).
2.Data Sharing: The collected data is often shared with a central server or platform
where it can be aggregated and analyzed. This can be done voluntarily by users who opt
into the sensing application.
3.Data Analysis: Researchers, developers, or organizations analyze the aggregated data
to gain insights, identify patterns, or address specific questions or problems.
2.2 IoT Protocol

MQTT (Message Queuing Telemetry Transport) is a lightweight messaging protocol


designed for efficient and reliable communication, particularly in scenarios with limited
bandwidth or resources. It’s widely used in the Internet of Things (IoT) and other
applications where devices need to exchange data in real-time. Here's an overview of
MQTT:
Publish/Subscribe Model:

•Publisher: Sends messages to a topic.


•Subscriber: Receives messages from a topic. Subscribers express interest in certain
topics and receive messages when those topics are updated.
•Broker: Acts as an intermediary that manages the communication between publishers
and subscribers. It routes messages from publishers to the appropriate subscribers
based on the topic.
Topics: Topics are hierarchical and are used to categorize messages. For example, a topic
might be home/livingroom/temperature. Devices can subscribe to specific topics to
receive relevant updates.
Messages: Messages are published to topics and can carry any kind of data, typically in
the form of strings or JSON.
CoAP
The Constrained Application Protocol (CoAP) is a special web transfer protocol that
operates with constrained nodes and networks. These networks are commonly used for
applications such as the Internet of Things (IoT), where devices may have limited
processor, memory, and power resources.
CoAP is intended to be simple, low-overhead, and efficient, making it ideal for machine-
to-machine communication.

Here’s a quick overview of why CoAP is significant in IoT:


1.Lightweight and Efficient: CoAP is designed to be simple and efficient, making it
suitable for devices with limited processing power and memory. It has a smaller header
size compared to HTTP, which reduces overhead and improves performance.

2.UDP-Based: Unlike HTTP, which operates over TCP, CoAP runs over UDP (User
Datagram Protocol). This choice supports low overhead and faster message exchanges,
although it also means CoAP has to handle reliability and ordering on its own, which it
does using built-in mechanisms.
3. Resource-Oriented: Similar to HTTP, CoAP is resource-oriented, meaning it allows
clients to interact with resources on a server using methods like GET, POST, PUT, and
DELETE. This makes it intuitive for developers familiar with RESTful principles.
4. Multicast Support: CoAP supports multicast communication, which allows a single
message to be sent to multiple devices at once. This can be very useful in scenarios like
network-wide updates or queries.
5. Built-in Security: CoAP includes options for securing communications through DTLS
(Datagram Transport Layer Security), which provides encryption and integrity similar to
TLS used in HTTP but suited for UDP.
6. Interoperability: CoAP is designed to work well with HTTP, facilitating easier
integration with web services. For example, CoAP servers can be accessed through HTTP
proxies and vice versa.

7. Simple Management: CoAP supports a lightweight management framework, making


it easier to handle and monitor resources in an IoT environment.
XMPP
Extensible Messaging and Presence Protocol is created for instant messaging (Google
Talk, Jabber, iChat) and the exchange of messages.

• It has been standardized by the IETF, over time XMPP has become an old protocol
because it cannot provide services required for certain new data applications that
arise.

• Due to insufficient support, Google has ceased to maintain support for the standards
of XMPP. Nevertheless, XMPP recently considered as a good protocol of
communication in accordance with the internet of things, as it works with short
messages and low response time. For this reason, XMPP is among the protocols used
for IoT communication and messaging.

• As its name suggests, XMPP is extensible, offering the possibility of adding number of
extensions to realize various applications (VOIP, file transfer …). These extensions
allow it to support the request/response architecture as well as publish/subscribe.
• XMPP is a short form for Extensible Messaging Presence Protocol. Its protocol for
streaming XML elements over a network in order to exchange messages and presence
information in close to real time. This protocol is mostly used by instance messaging
application like WhatsApp.

Lets explain each character of word XMPP:

X: Means eXtensible. XMPP is an open source project which can be changed or extended
according to the need.
M: Means XMPP is designed for sending messages in real time.
P: It determines whether you are online/offline/busy . It indicates the state.
P: XMPP is a protocol, i.e a set of standards that allow systems to communicate with each
other.
Embedded Platforms for IoT
Embedded computing Basics (Block Diagram)

Embedded systems are specialized computing systems designed to perform dedicated


functions or tasks within larger systems. They are characterized by their integration into
hardware with specific software applications.
ts. Basi
n en c Cir
om po 1. P cu
wa re C rinte it Comp
r d ply 2. R d o
Ha
w er s u p esist Circuit B nents.
P o 3. C o oard
1.
oc e s s or apac rs s
2. Pr ory 4. T i t
e m e r s rans ors
M ou n t 5. D istor
3. e r s/ C P o rt iode s
m o n s
4. Ti municati ut 6. I
n
m
5. Co ut and Out applicatio
p n 7. L tegrated
E circu
p
6. In uits used
in 8. I Ds it
nduc
C i rc tor
7. ts .
on en
C o m p
w a r e
Soft
E d i tor
1. p i ler
m
2. Co embler
. A s s
3 l a tor
u
4. Em er
. L i nk
5
b u g g er
6. De
Embedding means embedding function software into a computing hardware to enable a
system function for the specific dedicated applications. A device embeds software into
the computing and communication hardware, and the device functions for the
applications.

• Embedded Software : Software consists of instructions, commands and data. A


computing and communicating device needs software. Software does the boot loading
and enables the applications and services. The software includes an OS. A device
embeds software which also includes the device APIs and middleware which enable
the device to perform computing and communication functions.
• Bootloader
• Operating system
• Real time operating system
• Integrated Development Environment
From the book by Raj Kamal “ Internet of Things”
Integrated Development Environment (IDE) is a set of software components and
modules which provide the software and hardware environment for developing and
prototyping. An IDE enables the codes development on a computer, and later on enables
download of the codes on the hardware platform. IDE enables software that
communicates with the Internet web server or cloud service.

IDE consists of the device APIs, libraries, compilers, RTOS, simulator, editor, assembler,
debugger, emulators, logic analyzer, application codes’ burner for flash, EPROM and
EEPROM and other software components for integrated development of a system. IDE
may be open source. For example, Arduino has open source IDE from the Arduino
website.

Simulator : Simulator is software that enables development on the computer without any
hardware, and then prototyping hardware can be connected for embedding the software
and further tests

From the book by Raj Kamal “ Internet of Things”


Embedded Processor

Fig : A simple block diagram of a microprocessor


An embedded processor is a microprocessor designed especially for handling the needs
of an embedded system. Embedded systems require less power, so these processors are
very small and draw less power from the source. An ordinary microprocessor only comes
with the processor in the chip. The peripherals are separate from the main chip, resulting
in more power consumption.

There are two main types of embedded processors: Ordinary microprocessors and
Microcontrollers. Embedded processors are used for those systems which do not require
the processing power of standard devices such as desktops, laptops or workstations.

Processor is the heart of an embedded system. It is the basic unit that takes inputs and
produces an output after processing the data. For an embedded system designer, it is
necessary to have the knowledge of both microprocessors and microcontrollers
A processor has two essential units:
1. Program Flow Control Unit (C): The CU includes a fetch unit for fetching
instructions from the memory. The EU has circuits that implement the instructions
pertaining to data transfer operation and data conversion from one form to another.
2. Execution Unit (EU): The EU includes the Arithmetic Logical Unit (ALU) and also
the circuits that execute instructions for a program control task such as interrupt, or
jump to another set of instructions.

Types of Processors
1. General Purpose Processor (GPP): 2. Application Specific System Processor
Microprocessor (ASSP)
Microcontroller 3. Application Specific Instruction
A Embedded Processor Processors (ASIPs)
Digital Signal Processor 4. GPP core(s) or ASIP core(s) on either an
Media Processor Application Specific Integrated Circuit
(ASIC) or a Very Large Scale Integration
(VLSI) circuit
Microprocessor: A microprocessor is a single VLSI chip having a CPU. In addition, it
may also have other units such as coaches, floating point processing arithmetic units and
pipelining units that help in faster processing of instructions. Earlier generation
microprocessors' fetch-and-execute cycle was guided by a clock frequency of order of ~1
MHz. Processors now operate at a clock frequency of 2GHz.

Microcontroller: A microcontroller is a single-chip VLSI unit (also called


microcomputer) which although having limited computational capabilities, possesses
enhanced input/output capability and a number of on-chip functional units.

CPU RAM ROM


I/O Port Timer Serial COM Port

Microcontrollers are particularly used in embedded systems for real-time control


applications with on-chip program memory and devices
IoT Supported Platforms
Arduino UNO

Arduino is a popular open-source electronics platform based on easy-to-use hardware


and software. It consists of a microcontroller board (such as the Arduino Uno, Mega, or
Nano) and an integrated development environment (IDE) that lets you write and
upload code to the board.

Key Features:
1. Microcontroller: ATmega328P, 16 MHz clock speed
2. Digital I/O Pins: 14 digital pins (numbered 0 to 13), 6 of these can be used as PWM
outputs
3. Analog Input Pins: 6 analog input pins (numbered A0 to A5)
4. Power: USB connection (for power and programming), DC power jack (7-12V),
Regulated 5V and 3.3V outputs
5. Communication:
1 UART (hardware serial port) for serial communication
1 I2C and 1 SPI bus for communication with other devices
6. Memory:
32 KB of flash memory for storing code (of which 0.5 KB is used by the bootloader)
2 KB of SRAM (static RAM)
1 KB of EEPROM (electrically erasable programmable read-only memory)
7. USB Interface: Used for programming the board and for serial communication
between the board and a computer.
8. LED Indicators: A built-in LED on pin 13 that can be used for testing and debugging.

Physical Layout:

Headers: The board has rows of headers where you can connect wires, sensors,
actuators, and other components.
Reset Button: Allows you to manually reset the microcontroller.
Common Uses:
Prototyping: The Arduino Uno is often used for rapid prototyping of electronic
projects.
Learning: It's a great tool for beginners to learn about microcontrollers,
programming, and electronics.
Projects: It can be used in a variety of projects, from simple LED blinkers to
more complex applications like robotics, home automation, and data logging.

Programming:
•IDE: Code is written in the Arduino IDE, which is a user-friendly development
environment.
•Sketches: The code is referred to as a "sketch" and is typically written in C/C++.
The Arduino Uno is valued for its simplicity, ease of use, and robust community support,
making it an excellent starting point for both beginners and experienced makers.
Arduino UNO Boards
Arduino Hardware
Arduino UNO connection to PC: USB cable having Type-A on one side and Type-B on
other side is used for connecting Arduino board with PC/Laptop.
Raspberry Pi

Raspberry Pi is defined as a minicomputer of a credit card size that is interoperable


with any input and output hardware device like a monitor, a television, a mouse, or a
keyboard – effectively converting the set-up into a full-fledged PC at a low cost.

• Raspberry Pi is developed by Raspberry Pi Foundation in the United Kingdom.


Raspberry Pi is a series of powerful, small single-boardcomputers.
• Raspberry Pi is launched in 2012 and there have been several iterations and
variations released since then.
• Various versions of Raspberry Pi have been out till date. All versions consist of a
graphics processing unit (GPU). Broadcom system on a chip (SoC) with an integrated
ARM-compatible CPU and on-chip graphics processing unit (GPU)

The original device had a single-core Processor speed of device ranges from 700 MHz to
1.2 GHz and a memory range from 256 MB to 1 GBRAM.
To store the operating system and program memory Secure Digital (SD) cards are used.
Raspbian OS which is a Linux operating system is recommended OS by Raspberry Pi
Foundation. Some other third party operating systems like RISC OS Pi. Diet Pi, Kali,
Linux can also be run on Raspberry Pi.
Uses: It also provides a set of general purpose input/output pins allowing you to
control electronic components for physical computing and explore the internet of things
(IoT).
Features of Raspberry Pi
1. Affordability – Low cost
2. Versatility – Can run can run on Windows, Ubuntu
3. Computing Power –Quad core CPU up to 8 gb RAM.
4. Connectivity- Built in Ethernet and WiFi
5. Security – Security features are continuously improved.
6. Compatibility -Raspberry Piboards are compatible with a wide range of IoT sensors,
actuators, and accessories.
Thank you

You might also like