Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

IOT Unit 1

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

UNIT 1

INTERNET OF THINGS
INTRODUCTION
Definition:-
1. The Internet of Things as simply an interaction
between the physical and digital worlds. The digital
world interacts with the physical world using a
sensors and actuators.
2. The Internet of Things refers to a new kind of
world where almost all the devices and appliances
that we use are connected to a network. We can use
them collaboratively to achieve complex tasks that
require a high degree of intelligence.
Cont.,
• For this intelligence and interconnection, IoT devices are equipped
with embedded sensors, actuators, processors, and transceivers.
• Sensors and actuators are devices, which help in interacting with
the physical environment.
• The data collected by the sensors has to be stored and processed
intelligently in order to derive useful inferences from it.
• sensor → a mobile phone or even a microwave oven can count as
a sensor as long as it provides inputs about its current state
(internal state + environment).
• Example:
• Temperature Sensors. ...
• Humidity Sensors. ...
• Pressure Sensors. ...
• Proximity Sensors. ...
• Level Sensors. .
Cont.,
• An actuator →is a device that is used to effect
a change in the environment such as the
temperature controller of an air conditioner.
Cont.,
• Sensors, actuators, compute servers, and the
communication network form the core
infrastructure of an IoT framework.
• we need a middleware that can be used to
connect and manage all of these heterogeneous
components. We need a lot of standardization to
connect many different devices.
• The Internet of Things finds various applications in
health care, fitness, education, entertainment,
social life, energy conservation, environment
monitoring, home automation, and transport
systems.
UNIT I
Evolution of Internet
Internet
Internet is defined as an Information super Highway, to access
information over the web. However, It can be defined in many ways as
follows:

• Internet is a world-wide global system of interconnected computer


networks.

• Internet uses the standard Internet Protocol (TCP/IP).

• Every computer in internet is identified by a unique IP address.

• IP Address is a unique set of numbers (such as 110.22.33.114) which


identifies a computer location.

• A special computer DNS (Domain Name Server) is used to give name to


the IP Address so that user can locate a computer by a name.

• For example, a DNS server will resolve a


name http://www.tutorialspoint.com to a particular IP address to
uniquely identify the computer on which this website is hosted.

• Internet is accessible to every user all over the world.


Evolution
The concept of Internet was originated in 1969 and has undergone several
technological & Infrastructural changes as discussed below:

• The origin of Internet devised from the concept of Advanced Research


Project Agency Network (ARPANET).

• ARPANET was developed by United States Department of Defense.

• Basic purpose of ARPANET was to provide communication among the


various bodies of government.

• Initially, there were only four nodes, formally called Hosts.

• In 1972, the ARPANET spread over the globe with 23 nodes located at
different countries and thus became known as Internet.
• By the time, with invention of new technologies such as TCP/IP
protocols, DNS, WWW, browsers, scripting languages etc.,Internet
provided a medium to publish and access information over the web.

Advantages
Internet covers almost every aspect of life, one can think of. Here, we will
discuss some of the advantages of Internet:

• Internet allows us to communicate with the people sitting at remote


locations. There are various apps available on the web that uses
Internet as a medium for communication. One can find various social
networking sites such as:

o Facebook

o Twitter

o Yahoo

o Google+
o Flickr

o Orkut

• One can surf for any kind of information over the internet. Information
regarding various topics such as Technology, Health & Science, Social
Studies, Geographical Information, Information Technology, Products
etc can be surfed with help of a search engine.

• Apart from communication and source of information, internet also


serves a medium for entertainment. Following are the various modes
for entertainment over internet.

o Online Television

o Online Games

o Songs

o Videos

o Social Networking Apps

• Internet allows us to use many services like:

o Internet Banking

o Matrimonial Services

o Online Shopping

o Online Ticket Booking

o Online Bill Payment

o Data Sharing
o E-mail

• Internet provides concept of electronic commerce, that allows the


business deals to be conducted on electronic systems

Disadvantages
However, Internet has prooved to be a powerful source of information in
almost every field, yet there exists many disadvanatges discussed below:

• There are always chances to loose personal information such as name,


address, credit card number. Therefore, one should be very careful
while sharing such information. One should use credit cards only
through authenticated sites.
• Another disadvantage is the Spamming.Spamming corresponds to the
unwanted e-mails in bulk. These e-mails serve no purpose and lead to
obstruction of entire system.

• Virus can easily be spread to the computers connected to internet. Such


virus attacks may cause your system to crash or your important data
may get deleted.

• Also a biggest threat on internet is pornography. There are many


pornographic sites that can be found, letting your children to use
internet which indirectly affects the children healthy mental life.

• There are various websites that do not provide the authenticated


information. This leads to misconception among many people.

Intranet
Intranet is defined as private network of computers within an organization
with its own server and firewall. Moreover we can define Intranet as:

• Intranet is system in which multiple PCs are networked to be connected


to each other. PCs in intranet are not available to the world outside of
the intranet.

• Usually each company or organization has their own Intranet network


and members/employees of that company can access the computers in
their intranet.

• Every computer in internet is identified by a unique IP address.

• Each computer in Intranet is also identified by a IP Address, which is


unique among the computers in that Intranet.
BENEFITS
Intranet is very efficient and reliable network system for any organization. It
is beneficial in every aspect such as collaboration, cost-effectiveness, security,
productivity and much more.
Communication
Intranet offers easy and cheap communication within an organization.
Employees can communicate using chat, e-mail or blogs.

Time Saving
Information on Intranet is shared in real time.

Collaboration
Information is distributed among the employees as according to requirement
and it can be accessed by the authorized users, resulting in enhanced
teamwork.

Platform Independency
Intranet can connect computers and other devices with different
architecture.
Cost Effective
Employees can see the data and other documents using browser rather than
printing them and distributing duplicate copies among the employees, which
certainly decreases the cost.

Workforce Productivity
Data is available at every time and can be accessed using company
workstation. This helps the employees work faster.

Business Management
It is also possible to deploy applications that support business operations.

Security
Since information shared on intranet can only be accessed within an
organization, therefore there is almost no chance of being theft.

Specific Users
Intranet targets only specific users within an organization therefore, once can
exactly know whom he is interacting.

Immediate Updates
Any changes made to information are reflected immediately to all the users.

ISSUES
Apart from several benefits of Intranet, there also exist some issues.. These
issues are shown in the following diagram:
Applications
Intranet applications are same as that of Internet applications. Intranet
applications are also accessed through a web browser. The only difference is
that, Intranet applications reside on local server while Internet applications
reside on remote server. Here, we've discussed some of these applications:
Document publication applications
Document publication applications allow publishing documents such as
manuals, software guide, employee profits etc without use of paper.

Electronic resources applications


It offers electronic resources such as software applications, templates and
tools, to be shared across the network.

Interactive Communication applications


Like on internet, we have e-mail and chat like applications for Intranet, hence
offering an interactive communication among employees.

Support for Internet Applications


Intranet offers an environment to deploy and test applications before placing
them on Internet.

Internet vs. Intranet


Apart from similarities there are some differences between the two.
Following are the differences between Internet and Intranet:

Intranet Internet

Localized Network. Worldwide Network

Doesn't have access to Intranet Have access to Internet.

More Expensive Less Expensive

More Safe Less Safe

More Reliability Less Reliability

Extranet
Extranet refers to network within an organization, using internet to
connect to the outsiders in controlled manner. It helps to connect businesses
with their customers and suppliers and therefore allows working in a
collaborative manner.
Implementation
Extranet is implemented as a Virtual Private Networks (VPN) because it uses
internet to connect to corporate organization and there is always a threat to
information security. VPN offers a secure network in public infrastructure
(Internet).
Key Points

• The packet is encapsulated at boundary of networks in IPSEC complaint


routers.

• It uses an encryption key to encapsulate packets and IP addresses as


well.

• The packet is decoded only by the IPSEC complaint routers or servers.

• The message is sent over VPN via VPN Tunnel and this process is
known as tunneling.

VPN uses Internet Protocol Security Architecture (IPSEC) Protocol to


provide secure transactions by adding an additional security layer to TCP/IP
protocol. This layer is created by encapsulating the IP packet to a new IP
packet as shown in the following diagram:

Benefits
Extranet proves to be a successful model for all kind of businesses whether
small or big. Here are some of the advantages of extranet for employees,
suppliers, business partners, and customers:
Issues
Apart for advantages there are also some issues associated with extranet.
These issues are discussed below:

Hosting
Where the extranet pages will be held i.e. who will host the extranet pages. In
this context there are two choices:

• Host it on your own server.

• Host it with an Internet Service Provider (ISP) in the same way as web
pages.

But hosting extranet pages on your own server requires high bandwidth
internet connection which is very costly.
Security
Additional firewall security is required if you host extranet pages on your
own server which result in a complex security mechanism and increase work
load.

Accessing Issues
Information can not be accessed without internet connection. However,
information can be accessed in Intranet without internet connection.

Decreased Interaction
It decreases the face to face interaction in the business which results in lack
of communication among customers, business partners and suppliers.

Extranet vs. Intranet


The following table shows differences between Extranet and Intranet:

Extranet Intranet

Internal network that can be accessed Internal network that can


externally. not be accessed externally.

Extranet is extension of company's Only limited users of a


Intranet. company.

For limited external communication Only for communication


between customers, suppliers and within a company.
business partners.
UNIT 1
IoT Architecture
Three- and Five-Layer Architectures
Three- and Five-Layer Architectures
• It was introduced in the early stages of
research in this area. It has three layers,
namely, the perception, network, and
application layers.
• (i)The perception layer is the physical layer,
which has sensors for sensing and gathering
information about the environment. It senses
some physical parameters or identifies other
smart objects in the environment.
Three- and Five-Layer Architectures

• (ii)The network layer is responsible for


connecting to other smart things, network
devices, and servers. Its features are also used for
transmitting and processing sensor data.
• (iii)The application layer is responsible for
delivering application specific services to the user.
It defines various applications in which the
Internet of Things can be deployed, for example,
smart homes, smart cities, and smart health.
Three- and Five-Layer Architectures

• The five layers are perception, transport,


processing, application, and business layers .The
role of the perception and application layers is
the same as the architecture with three layers.
• We outline the function of the remaining three
layers.
• (i)The transport layer transfers the sensor data
from the perception layer to the processing layer
and vice versa through networks such as wireless,
3G, LAN, Bluetooth, RFID, and NFC.
Three- and Five-Layer Architectures

• (ii)The processing layer is also known as the


middleware layer. It stores, analyzes, and
processes huge amounts of data that comes from
the transport layer. It can manage and provide a
diverse set of services to the lower layers. It
employs many technologies such as databases,
cloud computing, and big data processing
modules.
• (iii)The business layer manages the whole IoT
system, including applications, business and
profit models, and users’ privacy.
• Things. A “thing” is an object equipped
with sensors that gather data which will be transferred
over a network and actuators that allow things to act.
• Gateways:Data goes from things to the cloud and vice
versa through the gateways. A gateway provides
connectivity between things and the cloud part of the
IoT solution, enables data preprocessing and filtering
before moving it to the cloud and transmits control
commands going from the cloud to things. Things then
execute commands using their actuators.
• Cloud gateway facilitates data compression and
secure data transmission between field gateways
and cloud IoT servers. It also ensures
compatibility with various protocols and
communicates with field gateways using different
protocols depending on what protocol is
supported by gateways.
• Streaming data processor ensures effective
transition of input data to a data lake and control
applications. No data can be occasionally lost or
corrupted.
• Data lake. A data lake is used for storing the data generated
by connected devices in its natural format. Big data comes
in "batches" or in “streams”. When the data is needed for
meaningful insights it’s extracted from a data lake and
loaded to a big data warehouse.
• Big data warehouse. Filtered and preprocessed data
needed for meaningful insights is extracted from a data
lake to a big data warehouse. A big data warehouse
contains only cleaned, structured and matched data
(compared to a data lake which contains all sorts of data
generated by sensors). Also, data warehouse stores context
information about things and sensors (for example, where
sensors are installed) and the commands control
applications send to things.
• Data analytics. Data analysts can use data from the big data
warehouse to find trends and gain actionable insights.
When analyzed (and in many cases – visualized in schemes,
diagrams, infographics) big data show, for example, the
performance of devices, help identify inefficiencies and
work out the ways to improve an IoT system (make it more
reliable, more customer-oriented). Also, the correlations
and patterns found manually can further contribute to
creating algorithms for control applications.
• Machine learning and the models ML generates. With
machine learning, there is an opportunity to create more
precise and more efficient models for control applications.
Models are regularly updated (for example, once in a week
or once in a month) based on the historical data
accumulated in a big data warehouse. When the
applicability and efficiency of new models are tested and
approved by data analysts, new models are used by control
applications.
• Control applications send automatic commands
and alerts to actuators, for example:
– Windows of a smart home can receive an automatic
command to open or close depending on the
forecasts taken from the weather service.
– When sensors show that the soil is dry, watering
systems get an automatic command to water plants.
– Sensors help monitor the state of industrial
equipment, and in case of a pre-failure situation, an
IoT system generates and sends automatic
notifications to field engineers.
• User applications are a software component
of an IoT system which enables the
connection of users to an IoT system and gives
the options to monitor and control their smart
things
Device management

• Device identification to establish the identity of the device


to be sure that it’s a genuine device with trusted software
transmitting reliable data.
• Configuration and control to tune devices according to the
purposes of an IoT system. Some parameters need to be
written once a device is installed (for example, unique
device ID). Other settings might need updates (for example,
the time between sending messages with data).
• Monitoring and diagnostics to ensure smooth and secure
performance of every device in a network and reduce the
risk of breakdowns.
• Software updates and maintenance to add functionality,
fix bugs, address security vulnerabilities.
User management
• Alongside with device management, it’s important to
provide control over the users having access to an IoT
system.
• User management involves identifying users, their
roles, access levels and ownership in a system.
• It includes such options as adding and removing users,
managing user settings, controlling access of various
users to certain information, as well as the permission
to perform certain operations within a system,
controlling and recording user activities and more.
Security monitoring

• Security is one of the top concerns in the


internet of things. Connected things produce
huge volumes of data, which need to be
securely transmitted and protected from
cyber-criminals. Another side is that the things
connected to the Internet can be entry points
for villains. What is more, cyber-criminals can
get the access to the “brain” of the whole IoT
system and take control of it.
Components of IOT
• Things equipped with sensors to gather data and actuators to perform
commands received from the cloud.
• Gateways for data filtering, preprocessing and moving it to the cloud and
vice versa, – receiving commands from the cloud.
• Cloud gateways to ensure data transition between field gateways and
central IoT servers.
• Streaming data processors to distribute the data coming from sensors
among relevant IoT solution’s components.
• Data lake for storing all the data of defined and undefined value.
• Big data warehouse for collecting valuable data.
• Control applications to send commands to actuators.
• Machine learning to generate the models which are then used by control
applications.
• User applications to enable users to monitor control their connected
things.
• Data analytics for manual data processing.
IoT architecture example – Intelligent
lighting
WEB 3.0 VIEWS OF IOT
WEB
• WEB, is an information system where
documents and other web resources are
identified by URL, which may be interlinked by
hypertext, and are accessible over the
internet.
WEBSITE
• Is a Collection of related web pages with a
common domain name which can be accessed
using a browser .
• Web Pages→ May Contain Multimedia, files
such as text, images,audia, video,gifts etc.,
WEB 1.0
•The first iteration of the web represents the
web 1.0, is the “read-only web.”
• the early web allowed us to search for
information and read it. There was very little in
the way of user interaction or content
generation.
•static web sites and personal sites.
•Based on HTML
•Example:Shopping carts
WEB 2.0
•“read-write Web”
•It’s the ability to contribute content and interact with other
web users.
• It has dramatically changed the landscape of the web in a
short time.
•Web 2.0 is a welcome response to web users who want to
participate in the information.
•It has much potential
•Broadband access
•Social media
•Don’t need to know HTML
•User created contents interact with sites through social
media
•Example: Social Network, Yahoo, Youtube
Usage of Web 2.0
• The social Web contains a number of online tools and platforms
where people share their perspectives, opinions, thoughts and
experiences. Web 2.0 applications tend to interact much more with
the end user.
8 tools are:
• Podcasting
• Blogging
• Tagging
• Curating with RSS
• Social bookmarking
• Social networking
• Social media
• Web content voting
Features
• Folksonomy
• User Participation
• Long Tail
• Software as a service
• Mass Participation
WEB 3.0
•web 3.0 is “read-write-execute.”
•All Available information is based on real-time
events.
•Users stay connected to the live internet at all times.
•Combining semantic markup and web services can
produce a web 3.0 experience — applications that can
speak to each other directly and interpret information
for humans.
•Semantic markup refers to the communication gap
between humans and computerized applications.
•A web service is a software that supports computer-
to-computer interaction over the internet
FEATURES OF WEB 3.0
•Semantic Web→The semantic web improves web technologies in
order to generate, share and connect content through search and
analysis based on the ability to understand the meaning of words,
rather than on keywords or numbers.
•Artificial Intelligence→in Web 3.0, computers can understand
information like humans in order to provide faster and more relevant
results. They become more intelligent to satisfy the needs of users.
•3D Graphics→The three dimensional design is being used
extensively in websites and services in Web 3.0. Museum guides,
computer games, ecommerce, geospatial contexts, etc. are all examples
that use 3D graphics.
•Connectivity→With Web 3.0, information is more connected thanks
to semantic metadata. As a result, the user experience evolves to
another level of connectivity that leverages all the available
information.
•Ubiquity –Accessible by multiple applications, every device is
connected to the web, the services can be used everywhere.
How web 3.0 can change our lives
•Web 3.0 provides a far more personalised
browsing experience for all of us. Websites can
automatically customise themselves to best fit
our device, location and any accessibility
requirements we may have and web apps will
become far more attuned to our usage habits
Web 3.0 Tools
Advantages of web 3.0
•Increased information linking
•More efficient Searching
•Better Marketing
•Web Browsing
•Increased Communication
Disadvantages of web 3.0
•Less advanced computers wont able to handle it
•Money is a important constraint
•It is very complicated
Difference between Web 1.0, Web 2.0 and Web 3.0
Web 1.0 Web 2.0 Web 3.0

Mostly Read-Only Wildly Read-Write Portable and Personal

Company Focus Community Focus Individual Focus

Home Pages Blogs / Wikis Live-streams / Waves

Owning Content Sharing Content Consolidating Content

Web Forms Web Applications Smart Applications

Directories Tagging User Behaviour

Page Views Cost Per Click User Engagement

Banner Advertising Interactive Advertising Behavioural Advertising

Britannica Online Wikipedia The Semantic Web

HTML/Portals XML / RSS RDF / RDFS / OWL


Bluetooth
History
• Harald Bluetooth : 10th century Danish King,
managed to unite Denmark and Norway
• Bluetooth SIG (Special Interest Group) :
– Founded in 1998 by : Ericsson, Intel, IBM, Toshiba and
Nokia
– Currently more than 2500 adopter companies
– Created in order to promote, shape an define the
specification and position Bluetooth in the market place
Current specification : Bluetooth 2.1
What is Bluetooth?
• A cable-replacement technology that can be
used to connect almost any device to any other
device
• Radio interface enabling electronic devices to
communicate wirelessly via short range (10
meters) ad-hoc radio connections
• a standard for a small , cheap radio chip to be
plugged into computers, printers, mobile
phones, etc
What is Bluetooth?
• Uses the radio range of 2.45 GHz
• Theoretical maximum bandwidth is 1 Mb/s
• Several Bluetooth devices can form an ad hoc
network called a “piconet”
– In a piconet one device acts as a master (sets
frequency hopping behavior) and the others as
slaves
– Example: A conference room with many laptops
wishing to communicate with each other
Bluetooth Architecture
• Piconet
– Each piconet has one master and up to 7 simultaneous
slaves
• Master : device that initiates a data exchange.
• Slave : device that responds to the master
• Scatternet
– Linking of multiple piconets through the master or slave
devices
– Bluetooth devices have point-to-multipoint capability to
engage in Scatternet communication.
Bluetooth
Piconet
• The communication between the primary and
secondary node can be one-to-one or one-to-many.
• All devices in a piconet hop together
– Master gives slaves its clock and device ID
• Non-piconet devices are in standby

P
S

S M SB

M=Master P=Parked
SB S=Slave SB=Standby
S
P
scatternet
Scatternet
• It is formed by using various piconets.
• A slave that is present in one piconet can be act as master or we can
say primary in other piconet.
• This kind of node can receive message from master in one picone
and deliver the message to its slave into the other piconet where it i
acting as a slave. This type of node is refer as bridge node. A
station cannot be master in two piconets.
S S
P
P
SB
S M
M
S
SB
P SB
S
Physical links
• Between master and slave(s), different types of
links can be established. Two link types have
been defined:
– Synchronous Connection-Oriented (SCO) link
– Asynchronous Connection-Less (ACL) link
Physical links
• Synchronous Connection Oriented (SCO)
– Support symmetrical, circuit-switched, point-to-point
connections
– Typically used for voice traffic.
– Data rate is 64 kbit/s.
• Asynchronous Connection-Less (ACL)
– Support symmetrical and asymmetrical, packet-switched,
point-to-multipoint connections.
– Typically used for data transmission .
– Up to 433.9 kbit/s in symmetric or 723.2/57.6 kbit/s in
asymmetric
Connection Establishment States
• Standby
– State in which Bluetooth device is inactive, radio not
switched on, enable low power operation.

• Page
– Master enters page state and starts transmitting paging
messages to Slave using earlier gained access code and
timing information.

• Page Scan
– Device periodically enters page state to allow paging
devices to establish connections.
Connection Establishment States
• Inquiry
– State in which device tries to discover all Bluetooth
enabled devices in the close vicinity.

• Inquiry scan
– Most devices periodically enter the inquiry scan state to
make themselves available to inquiring devices.
Inquiry and Page
Master Slave

(1) ID packet (Broadcast) Inquiry


Standby Inquiry Standby
scan

(2) FHS packet Inquiry


Page response

Page
scan

Master (4) ID packet


response Slave
response

(6) ID packet
Connection Connection
(7) ID packet
Bluetooth Protocol Stack
• Bluetooth standard has many protocols that
are organized into different layers.
• The layer structure of Bluetooth does not
follow OS1 model, TCP/IP model or any
other known model.
• The different layers and Bluetooth protocol
architecture are:
Bluetooth Protocol Stack
1.Radio Layer
• It defines the physical characteristics of
bluetooth transceiver.
• It performs modulation/demodulation of the
data into RF signals. The radio layer moves
data from master to slave or vice versa.
• It is a low power system that uses 2.4 GHz
ISM band in a range of 10 meters.
• This band is divided into 79 channels of
1MHz each.
• It defines two types of physical link:
connection-less and connection-oriented.
Cont.,
• Bluetooth uses the Frequency Hopping Spread
Spectrum (FHSS) method in the physical layer
to avoid interference from other devices or
networks.
• Bluetooth hops 1600 times per second, i.e. each
device changes its modulation frequency 1600
times per second.
• In order to change bits into a signal, it uses a
version of FSK called GFSK i.e. FSK with
Gaussian bandwidth filtering.
2.Baseband Layer
• It performs the connection establishment
within a piconet.
• Baseband layer is equivalent to the MAC
sublayer in LANs.
• Bluetooth uses a form of TDMA called
TDD-TDMA (time division duplex TDMA).
• Master and slave stations communicate
with each other using time slots.
• The master in each piconet defines the
time slot of 625 µsec.
3.Link Manager protocol layer
• It performs the management of the already
established links.

• It also includes authentication and


encryption processes.
4.Logical Link Control and
Adaption protocol layer:
• It is also known as the heart of the bluetooth
protocol stack.
• It allows the communication between upper and
lower layers of the bluetooth protocol stack.
• It packages the data packets received from
upper layers into the form expected by lower
layers.
• It also performs the segmentation and
multiplexing.
5.SDP layer
• It is short for Service Discovery Protocol.
• It allows to discover the services available
on another bluetooth enabled device.
6.RF comm layer:
• It is short for Radio Frontend Component.
It provides serial interface with WAP and
OBEX.
7.OBEX
• It is short for Object Exchange.

• It is a communication protocol to
exchange objects between 2 devices.
8.WAP
• It is short for Wireless Access Protocol. It
is used for internet access.
9.TCS
• It is short for Telephony Control Protocol.
It provides telephony service.
10.Application layer
• It enables the user to interact with the
application.
Bluetooth Frame Format
Advantages:

• Low cost.
• Easy to use.
• It can also penetrate through walls.
• It creates an adhoc connection
immediately without any wires.
• It is used for voice and data transfer.
Disadvantages

• It can be hacked and hence, less secure.


• It has slow data transfer rate: 3 Mbps.
• It has small range: 10 meters.
IEEE 802.15.4
IEEE 802.15.4
• IEEE 802.15.4 is a technical standard which defines
the operation of low-rate wireless personal area
networks (LR-WPANs).
• It specifies the physical layer and media access
control for LR-WPANs, defined the standard in
2003.
• which focuses on low-cost, low-speed ubiquitous
communication between devices.
• IEEE 802.15.4 is a low-data rate wireless personal
area network and is the PHY and MAC layer used by
many IoT protocols, such as ZigBee, and
WirelessHART.
Key 802.15.4 features include
• real-time suitability by reservation of Guaranteed
Time Slots (GTS),
• collision avoidance through CSMA/CA
• integrated support for secure communications.
• power management functions such as link
speed/quality and energy detection.
• Support for time and data rate sensitive applications
because of its ability to operate either as CSMA/CA
or TDMA access modes. The TDMA mode of operation
is supported via the GTS feature of the standard.[4]
• IEEE 802.15.4-conformant devices may use one of
three possible frequency bands for operation
(868/915/2450 MHz).
IEEE 802.15.4 ADVANTAGES
• Simple and flexible protocol stack
• Low cost
• Low energy consumption
• Short-range operation
• Reliable data transfer
• Ease of operation
IEEE 802.15.4
• The standard was first published in 2003, then revised
in 2006.
• The 2.4 GHz ISM band (S-band) worldwide, providing a
data rate of 250 kbps (O-QPSK modulation) and 16
channels (numbered 11–26);
• The 902–928 MHz ISM band (I-band) in the US,
providing a data rate of 40 kbps (BPSK modulation), 250
kbps (BPSK+O-QPSK or ASK modulation) or 250 kbps
(ASK modulation) and ten channels (numbered 1–10)
• The 868–868.6 MHz frequency band in Europe,
providing a data rate of 20 kbps (BPSK modulation),
100 kbps (BPSK+O-QPSK modulation) or 250 kbps
(PSSS: BPSK+ASKmodulation), and a single channel
(numbered 0 for BPSK or O-QPSK modulations, and 1
for ASK modulation).
802.15.4 frequency bands,
modulations and channels.
Cont.,
• 802.15.4 uses a 32-bit encoding when it needs to
refer to a specific frequency band, modulation,
and channel.
• The first 5 bits encode a page number, and the
remaining 27 bits are used as channel number
flags within the page.
2.Interferences with Other Technologies
• This frequency band is used by many wireless
networking standards, among which are WiFi
(802.11, 802.11b, 802.11g, 802.11n), 802.15.4, and
other devices such as cordless phones and
microwave ovens.
• FHSS Wireless Standards
– The 802.11 physical layer uses frequency hopping spread
spectrum (FHSS) and direct spread spectrum
modulation. Bluetooth (802.15.1) uses FHSS in the ISM
band.
• DSSS Wireless Standards
– 802.11b and 802.11g use only direct spread spectrum
(DSSS).
802.15.4 Communication Channel, Energy
Detection, Link Quality Information
• 802.15.4 does not use frequency hopping,
therefore the choice of the communication channel
is important.
• The 802.15.4 physical layer provides an energy
detection (ED) feature that enables applications to
request an assessment of each channel’s energy
level.
• Based on the results, a 802.15.4 network
coordinator can make an optimal decision for the
selection of a channel.
Cont.,
• For each received packet, the 802.15.4 physical
layer also provides link quality information (LQI) to
the network and application layers.
• Based on this indication and the number of
retransmissions and lost packets, transmitters may
decide to use a higher transmission power, and
some applications for example, ZigBee Pro provide
mechanisms to dynamically change the 802.15.4
channel in case the selected one becomes too
jammed, however, such a channel switch should
remain exceptional.
3.Sending a Data Frame
• 802.15.4 uses carrier-sense multiple access with
collision avoidance (CSMA/CA):prior to sending a
data frame, higher layers are first required to ask
the physical layer to performs a clear channel
assessment (CCA).
• The exact meaning of “channel clear” is
configurable: it can correspond to an energy
threshold on the channel regardless of the
modulation (mode 1), or detection of 802.15.4
modulation (mode 2) or a combination of both
(energy above threshold and 802.15.4 modulation:
mode 3).
Cont.,
• After a random back-off period designed to avoid
any synchronization of transmitters, the device
checks that the channel is still free and transmits a
data frame.
• Each frame is transmitted using a 30- to 40-bit
preamble followed by a start frame delimiter
(SFD), and a minimal physical layer header
composed only of a 7 bits frame length.
The Media-Access Control Layer
• 802.15.4 distinguishes the part of the MAC layer
responsible for data transfer and the part
responsible for management of the MAC layer itself.
1. 802.15.4 Reduced Function and Full Function
Devices, Coordinators, and the PAN Coordinator.
2. Association
3. 802.15.4 Addresses
4. 802.15.4 Frame Format
5. Security
1. 802.15.4 Reduced Function and Full
Function Devices, Coordinators, and the
PAN Coordinator.
802.15.4 networks are composed of several device
types:
• 802.15.4 networks are setup by a PAN coordinator
node, sometimes simply called the coordinator.
There is a single PAN coordinator for each network
identified by its PAN ID. The PAN coordinator is
responsible for scanning the network and selecting
the optimal RF channel, and for selecting the 16
bits PAN ID (personal area network identifier) for
the network.
Cont.,
• Full Function Devices (FFD), also called coordinators:
these devices are capable of relaying messages to
other FFDs, including the PAN coordinator. The first
coordinator to send a beacon frame becomes the PAN
coordinator, then devices join the PAN coordinator as
their parent, and among those devices the FFDs also
begin to transmit a periodic beacon or to respond to
beacon requests. At this stage more devices may be
able to join the network, using the PAN coordinator or
any FFD as their parent.
• Reduced Function Devices (RFD) cannot route
messages. Usually their receivers are switched off
except during transmission. They can be attached to
the network only as leaf nodes.
Cont.,
• Each network, identified by its PAN ID, is called a
cluster. A 802.15.4 network can be formed of
multiple clusters (each having its own PAN ID) in a
tree configuration: the root PAN coordinator
instructs one of the FFD to become the coordinator
of an adjacent PAN. Each child PAN coordinator
may also instruct a FFD to become a coordinator
for another PAN, and so on.
Topologies
• The star topology: data transfers are possible only
between the PAN coordinator and the devices.
• The peer to peer topology: data transfers can
occur between any two devices.
Two access control methods
• The beacon-enabled access method
• The nonbeacon-enabled access method
The beacon-enabled access method
• When this mode is selected, the PAN coordinator
periodically broadcasts a superframe, composed of
a starting and ending beacon frame, 15 time slots,
and an optional inactive period during which the
coordinator may enter a low-power mode. The first
time slots define the contention access period
(CAP), during which the other nodes should
attempt to transmit using CSMA/CA.
• When multiple coordinators transmit beacons, the
active periods of the super frames should not
overlap
IEEE 802.15.4 SUPERFRAME
STRUCTURE
The nonbeacon-enabled access
method (unslotted CSMA/CA).
• This is the mode used by ZigBee and 6LoWPAN. All
nodes access the network using CSMA/CA. The
coordinator provides a beacon only when
requested by a node, and sets the beacon order
(BO) parameter to 15 to indicate use of the
nonbeacon-enabled access method. Nodes
(including the coordinator) request a beacon
during the active scan procedure, when trying to
identify whether networks are located in the
vicinity, and what is their PAN ID.
Association
A node joins the network by sending an association request to the
coordinator’s address. The association request specifies the PAN ID
that the node wishes to join, and a set of capability flags encoded
in one octet:
• Alternate PAN: 1 if the device has the capability to become a
coordinator
• Device type: 1 for a full function device (FFD), that is, a device
capable of becoming a full function device (e.g., it can perform
active network scans).
• Power source: 1 if using mains power, 0 when using batteries.
• Receiver on while transceiver is idle: set to 1 if the device is
always listening.
• Security capability: 1 if the device supports sending and
receiving secure MAC frames.
• Allocation address: set to 1 if the device requests a short
address from the coordinator.
802.15.4 Addresses
• EUI-64
– Each 802.15.4 node is required to have a unique 64-bit
address, called the extended unique identifier (EUI-64).
• 16-Bit Short Addresses
– Since longer addresses increase the packet size,
therefore require more transmission time and more
energy, devices can also request a 16-bit short address
from the PAN controller.
802.15.4 Frame Format
• Data frames contain network layer data
directly in the payload part of the MAC frame.
• The Ack frame format is specific: it contains
only a sequence number and frame check
sequence, and omits the address and data
fields.
• The payload for command frames begins with
a command identifier followed by a command
specific payload.
802.15.4 MAC Layer Frame format
Security
• 802.15.4 is designed to facilitate the use of
symmetric key cryptography in order to provide
data confidentiality, data authenticity and replay
protection. It is possible to use a specific key for
each pair of devices (link key), or a common key for
a group of devices. However, the mechanisms used
to synchronize and exchange keys are not defined
in the standard, and left to the applications.
The BACnetTM Protocol
Introduction
• BACnet stands for Data Communication Protocol
for Building Automation and Control Networks.
• its goal was to harmonize data types and formats,
data exchange primitives, and common application
services.
• The scope of BACnet applications is very large,
including HVAC (heating, ventilating, and air
conditioning) applications, lighting control, fire
control and alarm, security, and interfacing to
utility companies.
The BACnetTM Protocol
The BACnetTM Protocol
• BACnet enables the building owner to have an
integrated control of all the various systems
from different manufactures in a single
monitor rather than having separate monitor
for each of the manufactures.
The BACnetTM Protocol
Cont.,
• BACnet is one of the most popular industrial
automation and control protocol, adopted in
products of many leading vendors(Siemens Building
Technologies, Johnson Controls, KMC Controls,
American Auto-Matrix, Reliable Controls).
1.Standardization
• The BACnet standardization effort began in 1987
during a Standard Project Committee meeting of
ASHRAE (American Society of Heating, Refrigerating
and Air-Conditioning Engineers).
• BACnet became an ISO standard in 2003.
• In January 2006, the BACnet Manufacturers
Association and the BACnet Interest Group of North
America combined their operation in a new
organization called BACnet International, provides
conformance testing services (BACnet Testing
Laboratories) and promotes the adoption and
development of the standard.
Cont.,
• United States→BACnet became a standard in 1995 as
ASHRAE/ANSI standard 135 and a conformance testing
method was standardized in 2003 as BSR/ASHRAE
Standard 135.1. The last revision of the standard was
published in 2010.
• Europe→BACnet was adopted in 2003 by CEN (Comit´e
Europ´een de Normalization,Technical Committee 247.
• Interworking→BACnet ability to interwork with other
technologies,its provide enough flexibility to allow
mapping of other common protocols to a BACnet
model.
-BACnet interoperability with Konnex
-BACnet interoperability with ZigBee
2. BACnet Specification
BACnet Objects
• BACnet abstracts the device basic functions as
objects: each device is decomposed into a collection
of standardized objects, where physical inputs and
outputs and other characteristics of the object
(name, type, configuration parameters) are
represented by properties.
• Each object is identified by a unique
Object_Identifier within the device.
BACNET Objects.
Standard BACnet objects
• AnalogInput
• AnalogOutput
• AnalogValue
• BinaryInput
• BinaryOutput
• BinaryValue
• MultistateValue
• MultistateInput
• MultistateOutput
• Schedule
• Calendar
• TrendLog
• Program
• Loop
• Averaging
• EventEnrolment
• NotificationClass
• LifeSafetyPoint
BACnet Object Properties
BACnet Object_Identifier
Object _Identifier = Object _Type+ Instance Number

For Analog Input-1,Object_identifier=Analog Input#1


BACnet Services:
BACnet Services
• BACnet considers that all objects are servers that provide services.
• classes of services are:
– Alarm and event services
• PROBLEMS
• ERRORS
• OUT OF RANGE
• CHANGE OF VALUE
– File access services
• READ FILES
• MANIPULATE FILES
– Object access services
• READ
• WRITE
• CREATE
• DELETE
– Remote device management services
• DISCOVER
• TIME SYNC
• INITIALIZE
• BACKUP & RESTORE
– Virtual terminal services
• HMI INTERFACE
BACnet Services
Who-Is & I-Am Services:
Who-Has & I-Have Services:
BACnet Architecture & LAN
BACnet Application Layer
• Message Processing & Device Addressing
• Interfaces with Application software
• Takes care of Transport & Session Layer
• BACnet Object & Properties are defined
Network Layer
• BACnet is primarily defined as a network layer
protocol, which defines the network addresses
required for the routing of messages.
• BACnet networks consist of one or more segments
consisting of single physical segments or multiple
physical segments connected by repeaters.
• BACnet addresses are hierarchical: the formal
separation of the network identifier and the
address identifier simplifies routing.
Data - Link Layer
• Data to Frames or Packets
• Rules for Addressing
• Error-Checking, Network Access
• Flow Control, Presentation
• Message Format
Physical Layer
– Means of Connecting devices
– Transmitting electronic signals to convey data
– Defines Hardware Specifications
– Data transmission & reception
– Topology & Physical Network Design
• BACnet upper layers are independent from the
underlying physical layer, facilitating the
implementation of BACnet on most popular
networks.
• BACnet physical layers have been defined for
ARCNET(United States ARmy CENTral Command,)
Ethernet, IP tunneling.
BACnet Architecture
BACnet Communication Protocols:
BACnet Communication Protocols:
BACnet Communication Protocols
3.BACnet Security
• In device A supporting security can request a session key
from a key server for a future communication with
device B.
• The key server will generate a session key Skab and
transmit it securely to A and B.
• BACnet uses 56-bit DES encryption.
• Device A may then authenticate a future transaction
with B: A and B authenticate each other by exchanging
challenges.
• the challenge message includes the identifier (InvokeID)
of the future transaction to be authenticated.
• https://www.youtube.com/watch?v=l-oY-ePIdRs
Modbus
ModBus
• ModBus, a very common protocol that is used
in many industrial and HVAC installations.
– ModBus Standardization
– ModBus Message Framing and Transmission
Modes
– ModBus/TCP
ModBus Standardization
• ModBus is an application layer messaging protocol that
provides client/server communication between devices
connected on different types of buses or networks.
• ModBus has become one of the de-facto standards.
• ModBus typically runs on top of RS 232, RS 442 point to
point or RS 485 point to multipoint links.
• The ModBus/TCP specification, published in 1999
defines an IP-based link layer for ModBus frames.
• ModBus devices communicate using a master-slave
model(the master, can initiate transactions (called
queries), which can address individual slaves or be
broadcast to all slaves. The slaves take action as
specified by the query, or return the requested data to
the master.)
ModBus Message Framing and
Transmission Modes
• The transmission mode defines the framing and bit
encoding of the messages to be transmitted on the
ModBus network. In a given ModBus network, all
nodes must use the same mode and serial
parameters:
• In the ASCII Transmission Mode→each byte is
encoded on the serial link as 2 ASCII characters.
• Each ASCII character is sent separately as 1 start bit,
7 data bits, zero or one parity bit, one or two stop
bits. The message is framed by a starting “:” ASCII
byte, and ends with a “CR-LF” byte sequence.
ModBus message framing (ASCII
mode).
ModBus Message Framing and
Transmission Modes
• In the RTU (remote terminal unit) transmission
mode→ the message is transmitted in a continuous
stream.
• Each 8-bit byte is framed by 1 start bit, 8 data bits,
zero or one parity bit, one or two stop bits. The
message itself starts after a silent period of at least
3.5 character times.
ModBus Addresses:
• ModBus messages begin by the target 8-bit address
that can take any decimal value between 1 and 247.
0 is used for broadcasts.
• The address field of the message frame contains
two characters in ASCII mode, or 8 bits in RTU
Mode.
• Each query contains the address of a specific slave.
When it responds, the slave includes its own
address in the message.
ModBus Functions:
• The function code field contains two characters in
ASCII mode, and 8 bits in RTU mode.
• which can take any decimal value between 1 and
255 and are selected based on the device
application profile. Some example functions are
listed:
– 0x02: Read Input Status. Parameters: starting register
address, and number of consecutive addresses to read.
Response data: 1 bit per input read.
– 0x11: Report Slave ID. Parameters: none. Response
data: slave ID, run indicator, device specific data.
ModBus Data Field
• The data field provides the application level
information, as required by the ModBus function.

• When a given ModBus function requires variable


size data, the data field begins with the “byte
count” of the data.
ModBus/TCP
• ModBus/TCP provides TCP/IP access to the ModBus
functionality.
• Each ModBus Request/response is sent over a TCP
connection established between the master and the
slave, using well-known port 502.
• The TCP connection may be reused for several
query/response exchanges.
• The byte content of the ModBus request and
response frames is simply transported over the TCP
connection, in big indian order. The only addition of
ModBusTCP is to add a seven-byte message prefix:
ref ref 00 00 00 len unit
Constrained Application Protocol

COAP
Communication over internet
• HTTP(Hyper Text Transfer Protocol)over REST
(Representational State Transfer)
• CoAP(Constrained Application Protocol) Over
CoRE(Constrained RESTful Environment).
• Each CoAP message has a unique ID, this is useful
to detect message duplicates.
• A CoAP message is built by 3 parts:
– A binary header
– A Compact options
– Payload
CoAP
• Constrained Devices
– Small Embedded Devices
– Runs on Batteries and need be Energy Efficient
– Small ROM and RAM
• Constrained Networks
• Low Power
• Low Bandwidth
• Lossy
• High Latency
MQTT and CoAP:Underlying Protocols
for the IOT
CoAP Architecture
CoAP Message Types
• Confirmable
• Non-Confirmable
• Acknowledgment
• Reset
CoAP
• It is a specialized transfer protocol for use with
constrained nodes and constrained networks in
the Internet of Things.
• The protocol is designed for Machine-to-
Machine(M2M) applications such as smart engery
and building automation.
• Most of the website offer such an API interface .
Features of CoAP
• The main features of CoAP protocols are:
• Web protocol used in M2M with constrained
requirements.
• Asynchronous message exchange.
• Low overhead and very simple to parse.
• URI and content-type support.
• Proxy and caching capabilities.
Why CoAP is used in IoT?
• Constrained Application Protocol (CoAP) is a
specialized web transfer protocol for use with
constrained nodes and constrained networks
in the Internet of Things. CoAP is designed to
enable simple, constrained devices to join
the IoT even through constrained networks
with low bandwidth and low availability.
Cont.,

• Can Transport RESTful calls over “thin” networks


• Is adapted to the small resources of IOT devices
• Uses the more efficient UDP protocol
• Only needs small memories and slow processors
for the nodes

You might also like