Introduction to Internet of Things (IoT)
Introduction to Internet of Things (IoT)
(AUTONOMOUS)
Unit -1
Definition- The Internet is a vast global network of connected servers, computers, tablets
and mobiles that is governed by standard protocols for connected systems. It enables sending,
receiving, or communication of information, connectivity with remote servers, cloud and
analytics platforms.
Hardware (Arduino Raspberry Pi, Intel Galileo, Intel Edison, ARM mBed, Bosch
XDK110, Beagle Bone Black and Wireless SoC)
Integrated Development Environment (IDE) for developing device software, firmware
and APIs
Protocols [RPL, CoAP, RESTful HTTP, MQTT, XMPP (Extensible Messaging and
Presence Protocol)].
Communication ( Powerline Ethernet, RFID, NFC, 6LowPAN, UWB, ZigBee, Bluetooth,
WiFi, WiMax, 2G/3G/4G).
Network backbone (IPv4, IPv6, UDP and 6LowPAN) ● Software (RIOT OS, Contiki OS,
Thingsquare Mist firmware, Eclipse IoT).
Internetwork Cloud Platforms/Data Centre (Sense, ThingWorx, Nimbits, Xively,
openHAB, AWS IoT, IBM BlueMix, CISCO IoT, IOx and Fog, EvryThng, Azure, TCS
CUP).
Machine learning algorithms and software. An example of machine-learning software is
GROK from Numenta Inc. that uses machine intelligence to analyse the streaming data
from clouds and uncover anomalies, has the ability to learn continuously from data and
ability to drive action from the output of GROK’s data models and perform high level of
automation for analysing streaming data.
Device platform consisting of device hardware and software using a microcontroller (or
SoC or custom chip), and software for the device APIs and web applications.
Connecting and networking (connectivity protocols and circuits) enabling
internetworking of devices and physical objects called things and enabling the internet
connectivity to remote servers.
Server and web programming enabling web applications and web services.
Cloud platform enabling storage, computing prototype and product development
platforms.
Online transactions processing, online analytics processing, data analytics, predictive
analytics and knowledge discovery enabling wider applications of an IoT system.
Sources of IOT:
Examples of hardware sources for IoT prototype development are Arduino Yún,
Microduino, Beagle Board and RasWIK. Hardware prototype needs an IDE for developing
device software, firmware and APIs.
Arduino Yún- Arduino Yún board uses microcontroller ATmega32u4 that supports
Arduino and includes Wi-Fi, Ethernet, USB port, micro-SD card slot and three reset buttons. The
board also combines with Atheros AR9331 that runs Linux.
Microduino- Microduino is a small board compatible with Arduino that can be stacked
with the other boards. All the hardware designs are open source.
Galileo is pin-compatible with Arduino. It has 20 digital I/O (12 GPIOs fully native), 12-
bit PWM for more precise control, six analog inputs and supports power over Ethernet (PoE).
Intel Edison- Intel Edison19 is a compute module. It enables creation of prototypes and
fast development of prototyping projects and rapidly produces IoT and wearable computing
devices. It enables seamless device internetworking and device-to-cloud communication. It
includes foundational tools. The tools collect, store and process data in the cloud, and process
rules on the data stream. It generates triggers and alerts based on advanced analytics.
Beagle Board- Beagle Bone based board has very low power requirement. It is a card-
like computer which can run Android and Linux. Both the hardware designs and the software for
the IoT devices are open source.
Examples of IOT:
Examples of IoT usages are wearable devices such as watches, fitness trackers, sleep
monitors and heart monitors etc. Fitbit (for example, Fitbit Alta fitness tracker), Garmin and
other companies manufacture many such devices. Microsoft (Microsoft band might soon be
discontinued), Xiaomi and other manufacturers make tracking bands. A fitness tracker wearable
band has the following functions:
Smart Home:
Smart Cities:
The IoT concept extends to Internet of Everything (IoE) for developing smart cities. A four-layer
architectural framework developed at CISCO for a city is as follows:
Layer 1 consists of sensors, sensor networks and devices network in parking spaces,
hospitals, streets, vehicles, banks, water supply, roads, bridges and railroads. Bluetooth,
ZigBee, NFC, WiFi are the protocols used at this layer.
Layer 2 captures data at distributed computing points where data is processed, stored and
analysed.
Layer 3 is meant for central collection services, connected data centres, cloud and
enterprise servers for data analytics applications.
Layer 4 consists of new innovative applications, such as waste containers’ monitoring,
WSNs for power loss monitoring, bike sharing management and smart parking. Smart
parking refers to services for motorists that informs them about the nearby parking
services with vacant spaces in advance.
IoT or M2M device data refers to the data meant for communication to an application,
service or process. Data also refers to data received by a device for its monitoring or for
actions at actuator in it.
Data stack - denotes the data received after the actions at various in-between layers (or
levels or domains). Layers in Open Systems Interconnection (OSI) model are Application,
Presentation, Session, Transport, Network, Data-link and Physical.
Actions at the data-adaptation or other layers can be related to data privacy, data security,
data consolidation, aggregation, compaction and fusion. An action can be a
gateway action—using one protocol for reception and another one for transmission.
Following are the key terms which need to be understood to learn the design principles of
connected devices for IoTs:
Layer- refers to a stage during a set of actions at which the action is taken as per a specific
protocol or method, and then the result passes to the next layer until the set of actions
complete. A layer may consist of various sublayers.
Application layer - refers to a layer for transmitting or receiving the data bits of an
application. Data bits route across the network and transfer takes place as follows:
application data from the application layer transfers after passing through several in-between
layers to the physical layer, and from there it transmits to the receiving-end physical layer.
Then, the data at the receiving node transfers from the physical layer to the application layer
after passing through several in-between layers.
Level- refers to a stage from the lowest to the highest. For example, acquiring device data
and actions that may be considered at the lowest level and actions in business processes at the
highest level.
Domain- refers to a set of software, layers or levels having specific applications and
capabilities. For example, CoRE network, access network, service capabilities and
applications can be considered as one domain, say, network domain. A domain generally has
limited interactions with other domains or outside the domain.
Gateway- refers to software for connecting two application layers, one at the sender and the
other at the receiver [application layer gateway (ALG)]. A gateway may be of different types.
A communication gateway at device and gateway domain has capabilities as protocol-
conversion during communication between two ends when each end uses distinct protocols.
An Internet gateway may have capabilities besides protocol conversion, transcoding data,
device management and data-enrichment before the data communicate over the Internet.
IP stands for Internet Protocol version 6 (IPv6) or Internet Protocol version 4 (IPv4) for the
network layer (v6 means version 6, v4 version 4).
Header- means a set of octets containing information about the data being sent. Header
packs the data of a layer before transmission to the next layer during communication between
two end-points. The size of a header and its fields are according to the protocol used for
creating data stack at a layer. For example, IPv4 header has fields as per IP network layer,
Universal Datagram Protocol (UDP) header as per UDP at the transport layer and so on. Each
header field has distinct meanings. The field size can be between 1 and 32-bit in a packet. A
field helps in processing the packet when transferring it from one layer to the next one.
Internet Connectivity:
Internet connectivity is through a set of routers in a global network of routers which carry
data packets as per IP protocol from a source end to another and vice versa. A source sends
data packets to a destination using IETF standardised formats.
TCP/IP suite consists of a number application layer protocols. For example, HTTP, HTTPS,
FTP, Telnet and others. A port uses a protocol for sending and receiving messages. A TCP/IP
message must be sent from the right port at the transmission end and to the right port at the
receiver end, else the receiver port does not listen.
Hyper Text Transfer Protocol (HTTP) port number is 80. A web HTTP server listens
to port 80 only and responds to port 80 only. An HTTP port sends application data
stack at the output to the lower layer using the HTTP protocol.
An HTTP port uses a URL like [Link] [Link]/. The default port is
taken as 80. The port number can be specified after the TLD. For example, after
‘.com’ in URL [Link] [Link]/.
HTTPS (HTTP over Secure Socket Layer or TLS) port number is 443. An HTTPS
port sends a URL; for example,
[Link] numbers. Here, TLD
is .org, domain name is [Link] and Subdomain name is en. Resource URL is at
/wiki/List_of_TCP_and_UDP_port_numbers.
The port receives the data stack at the input at the receiver end. Each port at the
application layer uses a distinct protocol. A port is assigned a number according to
protocol used for transmission and reception.
Features of HTTP:
HTTP, HTTPS, FTP, Telnet, SMTP, DNS, DHCP, PoP3, SNMP, LDAP, XMPP, XMPP-
SSL, CoAP, LWM2M and IPSec are protocols for the application layer/application-
support layer ports.
A URL specifies the protocol when sending a request for a resource. For example, [Link]
coap://, https:// and ws:// before a domain name.
HTTP is stateless communication. A method is used to save states during communication
in web applications.
An HTTP client is used for a web server for requesting a webpage as response from an
HTTP server.
An HTTPS port is for an HTTP message over a secure socket layer or TLS.
UNIT-II
Business is driving force for growth of industry and technologies. This chapter focuses on
design of business models, need of innovation in a model, value propositions in a model and
value creation using a model with reference to IoT and IIoT.
Following are the lessons learnt earlier and new key terms, which require understanding
for learning business model design, innovation and value creation in business processes.
Application or App -means software for application, such as software for creating
and sending an SMS, measuring and sending the measured data, or receiving message
from a specified sender. Application means application software. App is the
abbreviation popular for application in the device whenever only one specific task is
executed following user interaction(s).
Service -means a mechanism, which enables the provisioning of access to one or
more capabilities. An interface for a service provides the access to the capabilities.
The access to each capability is consistent with the constraints and policies, specified
by a service description.
Business intelligence -(BI) is a process that enables a business service to extract new
facts and knowledge, and then undertake better decisions. The new facts and
knowledge follow from the earlier results of data processing, aggregation and then
analysing those results.
Business process -(BP) is an activity or series of activities or a collection of inter-
related structured activities, tasks or processes. A BP serves a particular goal or
specific result or service or product. The BP is a representation or process matrix or
flowchart of a sequence of activities with interleaving decision points.
Distributed BP- (DBP) is a collection of logically interrelated business processes.
DBP reduces the complexity and communication costs, and enables faster responses
and smaller processing load at the central BP system. DBP is similar to the
A number of international organisations have taken action for IoT design standardisation.
Following are the examples:
Internet Engineering Task Force (IETF), an international body initiated actions for
addressing and working on the recommendations for the engineering specifications for the
Internet of Things. IETF suggests the specifications for the layers, and the engineering aspects
for the IoT communication, networks and applications.
OSI protocols mean a family of information exchange standards developed jointly by the
ISO and the ITU-T. The seven-layer OSI model is a standard model. It gives the basic outline for
designing a communication network. Various models for data interchanges consider the layers
specified by the OSI model, and modify it for simplicity according to the requirement. Similarly,
IETF suggests modifications in the OSI model for the IoT/M2M.
Classical seven-layer OSI model has shown in below and the modifications in that model
proposed by IETF (in the middle). Data communicates from device end to application end. Each
layer processes the received data and creates a new data stack which transfers it to the next layer.
The processing takes place at the in-between layers, i.e. between the bottom functional-layer to
the top layer. Device end also receives data from an application/service after processing at the in-
between layers.
New applications and services are present at the application layer 6. A modification to
this is that the application-support layer 5 uses protocols, such as CoAP. IoT applications and
services commonly use them for network communication. The CoAP protocol at the layer is
used for the request/response interactions between the client and server at the network. Similarly,
the application-support layer may include processes for data managing, acquiring, organising and
analysing which are mostly used by applications and services.
Modifications are also at the data-link layer 2 (L2) and physical layer 1 (L1). The new
layers are data-adaptation (new L2) and physical cum data-link (new L1). The dataadaptation
layer includes a gateway. The gateway enables communication between the devices network and
the web. A physical IoT/M2M device hardware may integrate a wireless transceiver using a
communication protocol as well as a data-link protocol for linking the data stacks of L1 and L2.
A domain specifies the functional areas. High-level architecture means architecture for
functional and structural views. Figure 2.3 shows ETSI M2M domains and architecture, and the
high-level capabilities of each domain. It also shows that the architecture correspondences with
the six-layer modified OSI model as well as the four layers of the ITU-T reference model.
M2M applications
M2M service capabilities
M2M management functions
Network management functions
CoRE network (for example, 3G and IP networks, network control functions,
interconnections among networks)
Access network (for example, LPWAN (low power wide area network), WLAN (Wi-Fi)
and WiMax networks)
The ETSI device and gateway domain has the following functional units:
Gateway between M2M area network, and CoRE and access network, possessing M2M
service capabilities and applications
M2M area network (for example, Bluetooth, ZigBee NFC, PAN, LAN)
M2M devices
Example of M2M ETSI domains and high level architecture for applications and services
ATMs-to-bank servers:
Communication Technologies:
Physical cum data-link layer in the model consists of a local area network/personal area
network. A local network of IoT or M2M device deploys one of the two types of technologies—
wireless or wired communication technologies. Figure 2.4 shows connected devices (1st to ith)
connectivity using different technologies for communication of data from and to devices to the
local network connectivity to a gateway.
NFC is a short distance (20 cm) wireless communication technology. It enables data
exchange between cards in proximity and other devices. Examples of applications of NFC are
proximity-card reader/RFID/IoT/M2M/mobile device, mobile payment wallet, electronic keys
for car, house, office entry keys and biometric passport readers.
NFC devices transmit and receive data at the same instance and the setup time (time
taken to start the communication) is 0.1 s. The device or its reader can generate RF fields for the
nearby passive devices such as passive RFID. An NFC device can check RF field and detect
collision of transmitted signals. The device can check collision when the received signal bits do
not match with the transmitted signal bits. Features of an NFC device are:
Range of functioning is within 10 to 20 cm. The device can also communicate with
Bluetooth and Wi-Fi devices in order to extend the distance from 10 cm to 30 m or higher. The
device is able to receive and pass the data to a Bluetooth connection or standardized LAN or Wi-
Fi using information handover functions. Device data transfer rates are 106 kbps, 212 kbps, 424
kbps and 848 kbps (bps stands for bit per second, kbps for kilo bit per second). Three modes of
communication are:
Point-to-point (P2P) mode: Both devices use the active devices in which RF
fields alternately generate when communicating.
Card-emulation mode: Communication without interruption for the read and
write as required in a smart card and smart card reader. FeliCa™ and Mifare™
standards are protocols for reading and writing data on the card device and reader,
and then the reader can transfer information to Bluetooth or LAN.
Reader mode: Using NFC the device reads passive RFID device. The RF field is
generated by an active NFC device. This enables the passive device to
communicate.
RFID:
Bluetooth devices follow IEEE 802.15.1 standard protocol for L1 (physical cum data-link
layer). BT devices form a WPAN devices network. Two types of modes for the devices are
Bluetooth BR/EDR (Basic Rate 1 Mbps/Enhanced Data Rate 2 Mbps and 3 Mbps) and Bluetooth
low energy (BT LE 1Mbps). A latest version is Bluetooth v4.2. BT LE is also called Bluetooth
Smart. Bluetooth v4.2 (December 2014) provides the LE data packet length extension, link layer
privacy and secure connections, extended scanner and filter link layer policies and IPSP. BT LE
range is 150 m at 10 mW power output, data transfer rate is 1 Mbps and setup time is less than 6
s.
Bluetooth v5, released in June 2016, has increased the broadcast capacity by 800%,
quadrupled the range and doubled the speed.
ZigBee devices follow the IEEE 802.15.4 standard protocol L1 (physical cum data-link layer).
ZigBee devices form a WPAN devices network.
ZigBee end-point devices form a WPAN of embedded sensors, actuators, appliances, controllers
or medical data systems which connect to the Internet for IoT applications, services and
business processes.
ZigBee Neighbourhood Area Network (NAN) is a version for a smart grid. ZigBee smart energy
version 2.0 has energy management and energy efficiency capabilities using an IP network.
IoT/M2M devices, RFIDs, sensors, actuators and controllers send mostly 10s of bytes
of data.
NFC, BT low energy, ZigBee IP, ZigBee NAN, RF transceivers and modules and
mobile GPRS/GSM are protocols which can be used for physical transmission of bits
from the devices (sensors/actuators/RF devices/IEEE 802.15.4
devices/controllers/nodes) or reception at them. The devices communicate mostly
100s of bytes of data at an instance.
NFC device range is 10 to 20 cm with data transfer rates as 106 kbps, 212 kbps, 424
kbps and 848 kbps
NFC device is able to receive and pass data to Bluetooth connection and WLAN
802.11 for information handover functions
RFID is a device which an access point identifies by charging the RFID circuit
BT LE communicates using 802.15.1 protocol with low power dissipation and short
frames in peerto-peer star topology network and data transfer rates is 1 Mbps.
ZigBee IP communicates using 802.15.4 protocol in low power dissipation and 127 B
data frames, and communicates on Internet using 6LoWPAN, IPv6, RPL/ND and
TLSv1.2. ZigBee data transfer rates are 250 kbps, 40 kbps and 20 kbps.
Wi-Fi network uses WLAN IEEE 802.11 protocol. 802.11 a, b, g and n are popularly
used.
Wi-Fi network functions with high data transfer rates, mobility, flexible, reliability
and scalable network. Interoperability with wireless as well as wired infrastructure
ensures compatibility, enables easier access and hides complexity when enabling the
wireless access to data, media and streams, applications and services.
Wireless USB uses UWB (ultra wide band) 5.1 GHz to 10.6 GHz frequencies for
short-range personal area network (high speed 480 Mbps 3 m or 110 Mbps 10 m
channel USB protocol for wireless communication).
UART, SPI, I2C, Ethernet and USB are bus-topology-based serial communication
protocols and use wired communication.
A gateway at a data-adaptation layer has several functions. These are data privacy, data
security, data enrichment, data consolidation, transformation and device management. Below
figure shows IoT or M2M gateway consisting of data enrichment, consolidation and device
management, and communication frameworks.
Recall ITU-T reference model. The model’s lowest layer is the device layer. This layer
has device and gateway capabilities. Also, recall device and gateway domain in ETSI IoT
Gateway includes the provisions for one or more of the following functions: transcoding
and data management. Following are data management and consolidation functions:
Transcoding
Privacy, security
Integration
Compaction and fusion
Transcoding:
Transcoding means data adaptation, conversion and change of protocol, format or code
using software. The gateway renders the web response and messages in formats and
representations required and acceptable at an IoT device. Similarly, the IoT device requests are
adapted, converted and changed into required formats acceptable at the server by the transcoding
software.
A transcoding proxy can execute itself on the client system or the application server. A
transcoding proxy has conversion, computational and analysing capabilities, while a gateway has
conversion and computational capabilities only.
Privacy:
Data such as patient medical data, data for supplying goods in a company from and to
different locations, and changes in inventories, may need privacy and protection from conscious
or unconscious transfer to untrustworthy destinations using the Internet.
Access to data needs to be secure. The design ensures the authentication of a request for
data and authorisation for accessing a response or service. It may also include auditing of
requests and accesses of the responses for accountability in future.
Example described how a layer provides the confidentiality and authorisation using
AES-128 and CCM. End-to-end security is another aspect while implies using a security protocol
at each layer, physical, logical link and transport layers during communication at both ends in a
network.
Data Dissemination:
Consider the following three steps for data enrichment before the data disseminates to the
network as aggregation, compaction and fusion.
Aggregation refers to the process of joining together present and previously received data
frames after removing redundant or duplicate data.
Compaction means making information short without changing the meaning or context;
for example, transmitting only the incremental data so that the information sent is short.
Fusion means formatting the information received in parts through various data frames
and several types of data (or data from several sources), removing redundancy in the received
data and presenting the formatted information created from the information parts. Data fusion is
used in cases when the individual records are not required and/or are not retrievable later.
Device Management (DM) means provisioning for the device ID or address which is
distinct from other resources, device activating, configuring (managing device parameters and
settings), registering, deregistering, attaching and detaching.
Device management also means accepting subscription for its resources. Device fault
management means course of actions and guidelines to be followed in case if a fault develops in
the device.
Open Mobile Alliance (OMA)-DM and several standards are used for device
management. OMA-DM model suggests the use of a DM server which interacts with devices
through a gateway in case of IoT/M2M applications. A DM server is a server for assigning the
device ID or address, activating, configuring (managing device parameters and settings),
subscribing to device services or opting out of device services and configuring device modes. A
device instead of a DM server, communicates to a gateway in case of low-power loss
environment.
Does forwarding function when the DM server and device can interact without
reformatting or structuring
Does protocol conversion when the device and DM server use distinct protocols
Does proxy function in case an intermediate pre-fetch is required in a lossy
environment or network environment needs.
Data communication between personal/local area network of devices and a gateway for
communicating via Internet.
Gateway enables data enrichment and consolidation and device management.
Data management functions at the gateway are transcoding, data privacy, data security,
data enrichment, data consolidation, transformation and device management.
Transcoding means adaptations, conversions, changes of protocol or format using
software which renders the web response/messages in formats/representations as required
and acceptable at the IoT device and rendering requests for messages in
formats/representations as required and acceptable at the server.
Data acquires and transfers to other end at scheduled intervals, on an event, or on polling.
Data aggregation, compaction and fusion save energy during data dissemination.
Data destinations may use the 48-bit MAC address, 32-bit IPv4 address, 48-bit IPv6
address or port number during communication at the data-link or network layers.
Each device and application has an ID or address of communication source and each
destination has an ID or address. Communication between the end points and between the
layers is secure when using the authentication and authorization processes.
Device management functions are the device ID or address, activation, configuring
(managing device parameters and settings), registering, deregistering, attaching,
detaching and fault management.
Gateway functions for device management are—forwarding function between DM server
and device; protocol conversion when device and DM server use distinct protocols and
proxy function.
Communication gateway enables protocol conversion between two ends.
Design for connected devices for IoT applications, services and business processes
considers the ease in designing the devices’ physical, data-link, adaption and gateway layer.
A wireless sensor uses, for example, a mobile terminal (Mote) which is a low cost device
with an open-source OS (tiny OS) and software components. Usages of Motes provide ease and
affordance in a WSN network.
Devices of smart homes and cities use ZigBee IP or BT LE 4.2 (dual mode or single
mode) due to their affordability, ease of designing, usage and low cost.
A design may add to the complexity. For example, consider the umbrella, How will the
umbrella be programmed to schedule the SMSes for a user? The need to use an instruction
manual adds to the complexity of designing Internet of umbrellas. Connected devices may add
complexity in the form ensuring data transfer to trusted destinations using encryption tools.
UNIT-III
Application or App -refers to a software for applications such as creating and sending an SMS,
measuring and sending the measured data, receiving a message from a specific sender etc.
Application Programming Interface (API)- refers to a software component, which receives messages
from one end; for example, from an application or client or input. An API may consist of GUIs (button,
check box, text box, dialog box). An API may get input to or from a server or a user. It then initiates
actions and may send the messages, for example, to application software, server or a client at the other
end etc.
Web service -refers to a servicing software which uses web protocols, web objects or Web Sockets; for
example, weather reports service, traffic density reports, streetlights monitoring and controlling service.
Object -refers to a collection of resources; for example, collection of data and methods (or functions or
procedures) to operate on that data. Take for instance, Time_Date object with second, minutes, hour,
day, month and year fields and update methods.
An object instance can be just one or more than one for an object. An example of an object
instance is birth_date. Multiple object instances, abc_birth_date, pqr_birth_date, xyz_birth_date and
many instances can be created from birth_date object in JavaScript. An example of object instance is
weather report object for reporting the rains.
Object model -is defined as the usage of objects for values, messages, data or resource transfer, and
creation of one or more object-instances.
Class: Java uses concept of class, which creates one or more object instances.
Communication gateway is one that functions as communication protocol translator (convertor) for
provisioning communication capabilities. For example, the gateway for communication between ZigBee
and IP networks.
Client- refers to a software object which makes request (or an API associated with it makes request) for
data, messages, resources or objects. A client can have one or more object instances. A client may also
have an API or many APIs for enabling the communication to the server. A client can be at a device or
application on a network or Internet connected web, enterprise server or cloud.
Server- is defined as a software which sends a response on a request. The server also sends messages,
alerts or notifications. The server has access to resources, databases and objects. A server can be on a
device or can be on a separate computer system, not necessarily on Internet connected web.
Web object- is the one that retrieves a resource from the web object at other end using a web protocol.
Broker- denotes an object, which arranges the communication between two ends; for example,
between the message publisher and subscriber or for example taking the request from a source and
Proxy- refers to an application which receives a response from the server for usage of a client or
application and which also receives requests from the client for the responses retrieved or saved at
proxy.
Communication protocol- defines the rules and conventions for communication between networked
devices and between systems. The protocol includes mechanisms for devices or systems to identify and
make connections with each other. The protocol also includes formatting rules that specify how data is
packaged into sent and received messages,1 and header, its field and their meanings.
Web protocol- is a protocol that defines the rules and conventions for communication between the web
server and web clients. It is a protocol for web connectivity of web objects, clients, servers and
intermediate servers or firewalls. It includes mechanisms for a web object to identify and make
connections with other objects. The protocol also includes web object formatting rules that specify how
that object packs into it the sent and received messages.
Universal Resource Identifier- is generally used for saved resources, such as contacts or address book.
Example of a URI is /Contacts/First_Character_R/ for a set of resource directory contacts having
resource repository First_Character_R for contacts with first character R and resources giving
information about a contact. Another example is URI sensorNetwork_J/sensorID_N/temperature for a
temperature value. The value is at a resource directory sensorNetwork_J for a sensor network, which
stores sensor data for a sensor of id sensorID_N.
Universal Resource Locator- is generally used for retrieving a resource(s) by a client. The saved
resources may be at a document or at a remote server accessed using Internet protocols. An example of
a URL is [Link] for a set of resource directories, resource repositories and resources on
the McGraw Hill Higher Education server.
Datagram -refers to a limited size data (216 byte). It is used for stateless connectionless transfer from a
web object. Stateless means each single datagram transfer is independent of previous data interchanges
and connectionless means there is no need of pre-establishing the connection for resource exchanges
between the web objects and no connection closing after finishing the resource exchanges.
Representational State Transfer (REST)- is a software architecture referring to ways of defining the
identifiers for the resources, methods, access methods and data transfer during interactions. REST is a
software architecture which also specifies the practices, constraints, characteristics and guidelines for
creating scalable web services. Scalable means can be used as per the size. The architecture is used
during the design of web software components, clients and web APIs .
Data of connected devices routes over the web in two types of communication
environments. The environments are:
Assume that a web object refers to a web client or web server. The web object
communicates a request of the client or a response of the server. Communication is over the
ROLL network or Internet.
Assume i-devices (1, 2, … i th) connected devices network, and local network having
connectivity between the devices at physical/data-link and adaptation layer (left-hand
side).
Communication between web objects (right-hand side)
IETF CoRE specifications, which include CoAP and UDP
Web objects’ protocols for sending a request or response; for example, RESTful CoAP,
CoAP client and CoAP server communication over the network and transport layers to
other end CoAP client and server. Client/server use the URIs coap://… in place of
[Link] .
Transport layer protocols used are Datagram Transport Layer Security (DTLS) and UDP.
Data between web objects route using ROLL network specifications of IETF.
100s of bytes communicate between the IoT web objects
Web objects HTTP client and HTTP server communication over the Internet using the IP
and client/server use the URLs [Link] .
1000s of bytes communicate between HTTP web objects using certain protocols for
sending a request or response; for example, RESTful HTTP. IPv6 or IP is the network
layer protocol used. The transport layer protocols used are TLS and TCP.
IETF recommends Constrained Application Protocol (CoAP) which is for CoRE using
ROLL data network. Features of CoAP are:
A proxy is an intermediate server, which accepts a request from a client and sends the
response to the client using a protocol. It also passes the request to the server and accepts a
response from the server using the same or another protocol. HTTP-CoAP proxy accepts
requests from HTTP client using HTTP protocol and sends the request to the server using CoAP
protocol. CoAP-HTTP proxy accepts requests from CoAP client using CoAP protocol and sends
the request to the server using HTTP protocol.
The above figure shows CoAP client and server access using proxies. Transport Layer Security
(TLS), earlier known as Secure Socket Layer (SSL) is the protocol used for securing the TCP-based
Internet data interchanges. DTLS is the TLS for datagram. The features of DTLS are:
The protocol enables communication between LWM2M client at IoT device and an
LWM2M server at the M2M application and service capability layer. The protocol is a compact
one, meaning small header. It has an efficient data model. It is generally used in conjunction with
CoAP.
The below figure shows M2M devices LAN connectivity. It shows constrained devices
network connectivity with M2M applications and services using LWM2M OMA standard
specifications of LWM2M.
Local M2M constrained devices use, for example, the Bluetooth low energy, 6LowPAN
(IPv6 over low power WPAN), CoRE, ROLL, NFC, ZigBee PAN, cellular, Wi-Fi or
ZigBee IP (left-hand side) network technologies. M2M area network functions as PAN
for connectivity between devices and the M2M gateway.
10s of bytes communicate between a device and the PAN.
Communication between LWM2M objects (right-hand side). LWM2M client refers to
object instances as per the OMA standard LWM2M protocol. A client object sends a
request or receives a response of the LWM2M server over the access and CoRE
networks.
CoRE network, for example, 3GPP or other networks for the IP connectivity
Communication from an object instance using interface functions. The functions are
bootstrapping; registration, deregister or update a client and its objects; reporting the
notifications with new resource values; and service and management access through the
server.
Use of the CoAP, DTLS, and UDP protocols by the object or resource.
100s of bytes communicate between objects at the client or server for plain text or JSON
or binary TLV format data transfer. LWM2M specifications and features are as follows:
An object or resource use CoAP, DTLS, and UDP or SMS protocols for sending a
request or response.
Use of plain text for a resource or use of JSON during a single data transfer or binary
TLV format data transfer for a package for a batch of resource representations in a single
data transfer.
An object or its resource access using an URI.
Interface functions are for—bootstrapping; registration, deregister or updating a client
and its objects; reporting the notifications with new resource values; and service and
management access through the server.
Use of object model for resources and each object can have single or multiple instances.
Each resource can have single or multiple instances.
OMA or other standard specifying organisation defines the LWM2M objects for usages
in M2M communication. An LWM2M client has object instances as per OMA standards.
LWM2M client-server interactions are over the access and CoRE networks which
generally use CoAP over ROLL. LWM2M device client and server, generally use CoAP
client server interactions for data interchanges. Wi-Fi and WiMax are examples of access
networks. Examples of CoRE network are GSM, GPRS, 3GPP and 4G LTE or other
networks for IP connectivity as well as roaming.
Organisations can register the other LWM2M objects and resources with OMA or other
standards organisations.
Request/Response (Client/Server):
Publish/Subscribe (pubsub):
A service can be availed by one or more clients or brokers. When a client subscribes to
the service, it receives messages from that service. A publish/subscribe messaging protocol
provisions for publication of messages and reception on subscription (PUT and GET
methods) by the registered or authenticated devices.
Publication may be for measured values, for state information or resources of one or
more types. Subscription is for a resource-type (or for a topic). A separate subscription is
required for each resource-type or topic.
An example of resource type is measured values of ambient light condition in the smart
streetlights example. Another resource type is traffic presence or absence on the street.
Another resource type is lighting function report; functioning is proper or fault exists in the
light.
Resource directory (RD) maintains information and values for each resource type. A resource of
a resource type accesses from the RD using URI for the resource.
Resource Discovery:
Resource discovery service may advertise (publish) at regular intervals, the availability of the
resources or types of the resources available and their states. A client discovers the resource type and
registers for the RD service.
Registration/Registration Update:
Registration means a receiver registers with a service, such as an a RD service. When one
or more endpoints or devices or nodes registers, then that device gets the access to the resources
and receives published messages. Security considerations may require authentication of both
ends (service provider and receiver) before registration. A separate registration is required for
each endpoint (client or server).
Registration updates means updating for one or more endpoints or devices or nodes. It
also includes unregistering for one or more endpoints.
Polling or Observing:
Polling means finding from where new messages would be available or whether new
messages are available or updates are available or whether the information needs to be refreshed
or finding the status if the state information has changed or not. When messages store at a
database-server, then polling can be done by a client who uses the REST architecture GET
method and server uses the POST.
A state may refer to a connection or disconnection, sleep, awake, created, alive (not
deleted), old values persisting or updated with new values (GET + OBSERVE). Observing
means looking for change, if any, of a state at periodic intervals (OBSERVE).
Push (Publish/Subscribe) Data: Push means a service that pushes the messages or information
regularly. Interested device or endpoint or potential receiver receives these pushes. For example,
a mobile service provider pushes the temperature and location information regularly for the
potential receivers (registered mobile services subscribers) (PUT).
Message Cache:
Cache means storing when available and can be used later on when required. Messages
cache is useful in an environment of short or prolonged disconnections of a service. A message
can be accessed once or more times from a cache.
Message Queue :
Message queuing means storing the messages (data) in sequence from devices or endpoints so
that when connection state changes then messages can be forwarded. Forwarding is done using the
first-in first-out method for a resource type. A message forwards only once from a queue.
Separate queues are formed for each resource type. The messages are forwarded to the
registered devices or endpoints and to the subscribed devices or endpoints. A separate registered device
or endpoint list and a separate subscription list is maintained and used for each resource type.
Forwarding takes place only after matching the subscription from a list.
Information/Query:
The method is that an object (client) requests information using a query while another end-
object (server) responds by replying to the query. The responding application processes the query using
the query optimiser and retrieval plan. The query processing uses a database or resource directory
resources.
CoAP-SMS :
CoAP-SMS is a protocol when CoAP object uses IP as well as cellular networks
and uses SMS. It is an alternative to UDP-DTLS over ROLL for CoAP object messages
and when using cellular communication.
SMS is used instead of UDP + DTLS by a CoAP client or server. A CoAP client
communicates to a mobile terminal (MT) endpoint over the General Packet Radio Service
(GPRS), High Speed Packet Access (HSPA) or Long Term Evolution (LTE) networks
using CoAP-SMS protocol.
CoAP-MQ:
CoAP-MQ is a message queue protocol using a broker and RD. Roles of CoAP endpoints have
roles as a client and server. Below figure shows data interchanges between CoAP-MQ endpoints, CoAP-
MQ clients, CoAP-MQ servers through CoAP-MQ broker and its services.
The below figure shows CoAP-MQ server provisioning for the resource-subscription, store from
the publisher. The server also provisions for forwarding to the subscriber and proxy services. The figure
also shows that RD services are resource discovery, directory and object registration services. The device
objects communicate using the CoAP client and server protocols and CoAP web objects using DTLS as
security protocol and UDP for CoAP APIs.
MQTT Protocol:
IBM first created it and then donated it to M2M ‘Paho’ project of Eclipse. A version is
MQTT v3.1.1. MQTT has been accepted (2014) as OASIS (Organization for the Advancement
of Structured Information Standards) standard6 MQTT protocol is used for connectivity in
M2M/IoT communication.
A version is MQTT-SN v1.2. Sensor networks and non-TCP/IP networks, such as ZigBee
can use the MQTT-SN. MQTT-SN is also a publish/subscribe messaging protocol. It enables
extension of the MQTT protocol for WSNs, the sensor and actuator devices and their networks.
IBM conceptual framework for the IoT, which showed MQTT applications for one of the
communication management functions. Figure 3.6 shows messages interchange between
Figure shows MQTT-broker subscription, subscription match, store and forward, last
good message retention and keep message alive services. The figure also shows that device
objects use MQTT Java, C or JavaScript library functions. The objects communicate using the
connected devices network protocols such as ZigBee. Web objects also use MQTT library
functions and communicate using IP network and SSL and TLS security protocols for
subscribing and publishing web APIs.
Functions as a server node capable of storing messages from publishers and forwarding
them to the subscribing clients.
Receives topics from the publishers. Examples of topics are measured information of
ambient light conditions, traffic density, nearby parking space availability and waste
container status.
XMPP is an XML-based specification for messaging and presence protocols. XMPP is also an
open-source protocol recommended specification which is accepted by IETF. RFC is an international
organisation and stands for ’Recommended for Comments’. RFC 6120 document specifies the XMPP for
CoRE. Another recommendation, RFC 6121 XMPP specifies the instant messaging (IM) and presence, and
RFC 6122 XMPP specifies the (message) address format.
Messages notify presence for the IMs to one or many at the same time. It enables chatting and
Multi-User Chat (MUC) after creation of a chat room, where different users can do the IMs. XMPP
enables interoperable communication: for example, Google Talk. XMPP enables IMs between many
users as it uses presence-notifications and chat features.
Chat room is an application, in which all those who have subscribed (meaning persons and
objects initiating chatting and messaging to one another at the same time) are provided a room-like
view and use the IMs among themselves.
XMPP is extensible—XSF (XMPP standards foundation) develops and publishes the xeps (XMPP
extension protocols). The xeps enable the addition of features and new applications. List of XMPP xeps
for web objects is quite long.
Communication gateway connects two application layers, one at sender and the
other at receiver. The gateway also enables use of two different protocols, one at sender and the
other at receiver ends. The gateway facilitates the communication between web server using the
TCP/IP protocol conversion gateway and IoT devices. It also facilitates communication between
the devices using CoAP client and server using HTTP.
Connects the sender and receiver ends using two different protocols. For example, IoT
devices network maybe ZigBee network for connecting the devices. The network then connects
to the web server through a gateway. The server posts and gets the data using HTTP. A gateway
facilitates the communication between IoT devices and web server. For example, (i) ZigBee to
SOAP and IP or (ii) CoAP protocol conversion gateway for RESTful HTTP.
When all interactions used in the applications conform fully to the REST
constraints then these are called RESTful. RESTful APIs comply with these constraints and thus
conform to the REST architectural style. Web services with RESTful APIs adhere to the REST
architectural constraints. REST architectural style can be used for HTTP access by GET, POST,
PUT and DELETE methods for resources and building web services.
Standard HTTP methods are GET, PUT, POST and DELETE. HTTP based
RESTful APIs use the following:
A communication gateway connects the sender and receiver ends using two different
protocols. The gateway can function as a proxy between two ends, such as HTTP-CoAP
proxy.
Web objects communicate using HTTP methods, such as POST, GET, PUT, DELETE,
SOAP and WebSockets.
REST is a software architecture specifying practices and constraints which are used
during design of software components in a distributed hypermedia. Designing based on
REST depends on the characteristics of stateless, client-server, cacheable communication
using a protocol.
RESTful means components designed with constraints specified in REST. For example,
separation of concerns, use of layered system, defining cache ability or not between
client, server and intermediate.
UNIT-IV
Data Generation:
Data generates at devices that later on, transfers to the Internet through a gateway.
Data generates as follows:
Passive devices data: Data generate at the device or system, following the result
of interactions. A passive device does not have its own power source. An external
source helps such a device to generate and send data. Examples are an RFID
(Example) or an ATM debit card. The device may or may not have an associated
microcontroller, memory and transceiver. A contactless card is an example of the
former and a label or barcode is the example of the latter.
Active devices data: Data generates at the device or system or following the
result of interactions. An active device has its own power source. Examples are
active RFID, streetlight sensor (Example ) or wireless sensor node. An active
device also has an associated microcontroller, memory and transceiver.
Event data: A device can generate data on an event only once. For example, on
detection of the traffic or on dark ambient conditions, which signals the event?
The event on darkness communicates a need for lighting up a group of street
lights. A system consisting of security cameras can generate data on an event of
security breach or on detection of an intrusion. A waste container with associate
circuit can generate data in the event of getting it filled up 90% or above. The
components and devices in an automobile generate data of their performance and
functioning. For example, on wearing out of a brake lining, a play in steering
wheel and reduced air-conditioning is felt. The data communicates to the Internet.
The communication takes place as and when the automobile reaches near a Wi-Fi
access point.
Device real-time data: An ATM generates data and communicates it to the
server instantaneously through the Internet. This initiates and enables Online
Transactions Processing (OLTP) in real time.
Event-driven device data: A device data can generate on an event only once.
Examples are: (i) a device receives command from Controller or Monitor, and
then performs action(s) using an actuator. When the action completes, then the
Data Acquisition:
Data acquisition means acquiring data from IoT or M2M devices. The data
communicates after the interactions with a data acquisition system (application). The application
interacts and communicates with a number of devices for acquiring the needed data. The devices
send data on demand or at programmed intervals. Data of devices communicate using the
network, transport and security layers.
An application can configure the devices for the data when devices have configuration
capability. For example, the system can configure devices to send data at defined periodic
intervals. Each device configuration controls the frequency of data generation. For example,
system can configure an umbrella device to acquire weather data from the Internet weather
service, once each working day in a week (Example 1.1). An ACVM can be configured to
communicate the sales data of machine and other information, every hour. The ACVM system
can be configured to communicate instantaneously in event of fault or in case requirement of a
specific chocolate flavour needs the Fill service.
Application can configure sending of data after filtering or enriching at the gateway at the
data-adaptation layer. The gateway in-between application and the devices can provision for one
or more of the following functions—transcoding, data management and device management.
Data management may be provisioning of the privacy and security, and data integration,
compaction and fusion.
Data Validation:
Data acquired from the devices does not mean that data are correct, meaningful or
consistent. Data consistency means within expected range data or as per pattern or data not
corrupted during transmission. Therefore, data needs validation checks. Data validation software
do the validation checks on the acquired data. Validation software applies logic, rules and
semantic annotations. The applications or services depend on valid data. Then only the analytics,
predictions, prescriptions, diagnosis and decisions can be acceptable.
Large magnitude of data is acquired from a large number of devices, especially, from
machines in industrial plants or embedded components data from large number of automobiles or
health devices in ICUs or wireless sensor networks, and so on. Validation software, therefore,
consumes significant resources. An appropriate strategy needs to be adopted. For example, the
Services, business processes and business intelligence use data. Valid, useful and relevant
data can be categorised into three categories for storage—data alone, data as well as results of
processing, only the results of data analytics are stored. Following are three cases for storage:
Data Store
A data store is a data repository of a set of objects which integrate into the store. Features
of data store are:
Objects in a data-store are modeled using Classes which are defined by the database
schemas.
A data store is a general concept. It includes data repositories such as database, relational
database, flat file, spreadsheet, mail server, web server, directory services and VMware
A data store may be distributed over multiple nodes. Apache Cassandra is an example of
distributed data store.
A data store may consist of multiple schemas or may consist of data in only one scheme.
Example of only one scheme data store is a relational database. Repository in English
means a group, which can be related upon to look for required things, for special
information or knowledge. For example, a repository of paintings of artists. A database is
a repository of data which can be relied upon for reporting, analytics, process, knowledge
discovery and intelligence. A flat file is another repository. Flat file means a file in which
the records have no structural interrelationship (Section 5.3). Section 5.5.1 explains the
Data can be organised in a number of ways. For example, objects, files, data store,
database, relational database and object oriented database. Following subsections describe
these ways of organising and querying methods.
Database:
One popular method of organising data is a database, which is a collection of data. This
collection is organised into tables. A table provides a systematic way for access, management
and update. A single table file is called flat file database. Each record is listed in separate
row, unrelated to each other.
Relational Database:
A relational database is a collection of data into multiple tables which relate to each other
through special fields, called keys (primary key, foreign key and unique key). Relational
databases provide flexibility. Examples of relational database are MySQL, PostGreSQL,
Oracle database created using PL/SQL and Microsoft SQL server using T-SQL.
Object Oriented Database (OODB) is a collection of objects, which save the objects in
objected oriented design. Examples are ConceptBase or Cache. Example 5.3 shows the
advantages of using relational databases.
Problem: (Example)
Show the advantages of relational databases taking the example of Internet of ACVMs.
A Manager application receives ACVMs information. It send requests to ACVMs for the
chocolates sold, and number required. The request is sent each hour from Manager to Fill
service. A Fill service executes on receipt of the requests from ACVMs for chocolate
requirement every hour. Application, service and process use the common relational database
RDBACVM tables. Table 5.1 is for ACVMs information, and pending service requests Num1,
Num 2, Num2, Num 3 and Num 4 for the five flavours available at an ACVM. Table 5.2 is for
ACVMs Fill Request Information, and Table 5.3 for chocolates Fill service actions Common key
fields between A, B and C are machine id or service request number. The relationships between
fields of A, B and C are maintained by RDBMS. For example, when number of each flavour
requested equals the number sent to a machine after processing a service request, then
corresponding Num in A becomes 0. Assume three flat-file databases maintained separately—A’
for ACVMs information, B’ for ACVMs Fill Service Request Information and database and C’
for Fill Service Process. Then every time a service request raises or service request processes,
The database transactions must maintain the atomicity, data consistency, data isolation
and durability during transactions. Let us explain these rules using Example 5.3 as follows:
Consistency- means that data after the transactions should remain consistent. For
example, sum of chocolates sent should equal the sums of sold and unsold chocolates for each
flavour after the transactions on the database.
Distributed Database:
Consistency -means ‘Every read receives the most recent write or an error’. When a
message or data is sought the network generally issues notification of time-out or read error.
During an interval of a network failure, the notification may not reach the requesting node(s).
Partition tolerance- means ‘The system continues to operate despite an arbitrary number
of messages being dropped by the network between the nodes’. During the interval of a network
failure, the network will have two separate set of networked nodes. Since failure can always
occur therefore, the partitioning needs to be tolerated.
Query Processing:
Parsing and translation: This step translates the query into an internal form, into a
relational algebraic expression and then a Parser, which checks the syntax and verifies the
relations.
Decomposition to complete the query process into micro-operations using the analysis
(for the number of micro-operations required for the operations), conjunctive and
disjunctive normalisation and semantic analysis.
Optimisation which means optimising the cost of processing. The cost means number of
micro-operations generated in processing which is evaluated by calculating the costs of
the sets of equivalent expressions.
Evaluation plan: A query-execution engine (software) takes a query-evaluation plan and
executes that plan.
Returning the results of the query.
The process can also be based on a heuristic approach, by performing the selection and
projection steps as early as possible and eliminating duplicate operations.
Sensors, M2M, sensor networks data and the data using web APIs for multiple
information sources data, open data, mobile services network information data, corporate
database and knowledge database are at the input stages. The data from multiple sources and
services are part of the key resources in business model scenarios for IoT.
IIoT deploys connectivity to all parts of the production process: machines, products,
systems, and people using the cloud and big data technology. The machines and products
communicate, and thus manage themselves and each other. Software-based systems and service
Transactions:
A transaction is a collection of operations that form a single logical unit. For example, a
database connect, insertion, append, deletion or modification transactions. Business transactions
are transactions related in some way to a business activity.
OLTP means process as soon as data or events generate in real time. OLTP is used when
requirements are availability, speed, concurrency and recoverability in databases for real-time
data or events. Example 5.4 gives the uses of OLTP in the application and network domain in
Internet of ATMs (ATM of a bank) connected to a bank server.
Batch transactions processing means the execution of a series of transactions without user
interactions. Transaction jobs are set up so they can be run to completion. Scripts, command-line
arguments, control files, or job control language predefine all input parameters.
Examples of the streams are log streams, event streams and twitter streams. Query and
transactions processing on streaming data need specialised frameworks. Storm from Twitter, S4
from Yahoo, SPARK streaming, HStreaming and flume are examples of frameworks for real-
time streaming computation frameworks.
Interactive transactions processing means the transactions which involve continual exchange
of information between the computer and a user. For example, user interactions during e-
shopping and e-banking. The processing is just the opposite of batch processing.
Real-time transaction processing means that transactions process at the same time as the data
arrives from the data sources and data store. An example is ATM machine transactions. In-
memory, row-format records enable real-time transaction processing. Row format means few
rows and more columns. The CPU accesses all columns in single accesses in SIMD (single
instruction multiple data) streams processing.
CEP has many applications. For example, IoT event processing applications, stocks
algorithmic-based trading and location-based services. A CEP application in Eclipse are used for
capturing a combination of data, timing conditions and efficiently recognise the corresponding
events over data streams.
Internet of RFIDs enables a business process called tracking of RFID labelled goods
(Example 2.2) which also enables inventory control process.
IoT/M2M enables the devices’ data in databases for business processes. The data
supports the process. For example, consider a process, streetlights control and management. Each
group of streetlights sends data in real time through the gateways. The gateways connect to the
Internet. The control and management processes streetlights real time databases and group
databases.
DBPS is a collection of logically related BPs like DDBS. DBPS exists as cooperation
between the BPs in a transparent manner. Transparent means that each user within the system
may access all of the process decisions within all of the processes as if they were a single
business process.
DBPS should possess ‘location independence’ which means the enterprise BI is unaware
of where the BPs are located. It is possible to move the results of analytics and knowledge from
one physical location to another without affecting the user.
Below figure shows complex applications integration architecture and SOA of cloud-
based IoT services, web services, cloud services and services.
The service discovery and selection software components select the services for
application integration. Service orchestration software coordinates the execution of the number
of services, cloud services, cloud IoT services and web services. Services run in parallel and a
number of processes in sequences.