Unit 2
Unit 2
IOT PROTOCOLS
How IoT Protocols and Standards Support Secure Data Exchange in the
IoT Ecosystem?
At a time, when the number of Internet of Things (IoT) devices is continuously increasing,
cases of DDoS (Distributed Denial of Service) attacks are also being witnessed at frequent
intervals. Gartner reports that by 2020, the number of IoT devices will approximately reach
25 billion. It means that it is time when businesses, customers, and other stakeholders should
know about the IoT protocols and standards, which can potentially keep the possibilities of
security breaches at bay.
IoT protocols and standards can be broadly classified into two separate categories.
1. IoT Network Protocols
IoT network protocols are used to connect devices over the network. These are the set of
communication protocols typically used over the Internet. Using IoT network protocols, end-
to-end data communication within the scope of the network is allowed. Following are the
various IoT Network protocols:
• HTTP (HyperText Transfer Protocol)
HyperText Transfer Protocol is the best example of IoT network protocol. This
protocol has formed the foundation of data communication over the web. It is the most
common protocol that is used for IoT devices when there is a lot of data to be published.
However, the HTTP protocol is not preferred because of its cost, battery-life, energy saving,
and more constraints.
Additive manufacturing/3D printing is one of the use cases of the HTTP protocol. It enables
computers to connect 3D printers in the network and print three-dimensional objects and pre-
determined process prototypes.
• LoRaWan (Long Range Wide Area Network)
It is a long-range low power protocol that provides signal detection below the noise
level. LoRaWan connects battery operated things wirelessly to the Internet in either private or
global networks. This communication protocol is mainly used by smart cities, where there are
millions of devices that function with less power and memory.
Smart street lighting is the practical use case of LoRaWan IoT protocol. The street lights can
be connected to a LoRa gateway using this protocol. The gateway, in turn, connects to the
cloud application that controls the intensity of light bulbs automatically based on the ambient
lighting, which helps in reducing the power consumption during day-times.
• Bluetooth
Bluetooth is one of the most widely used protocols for short-range communication. It is a
standard IoT protocol for wireless data transmission. This communication protocol is secure
and perfect for short-range, low-power, low-cost, and wireless transmission between
electronic devices. BLE (Bluetooth Low Energy) is a low-energy version of Bluetooth
protocol that reduces the power consumption and plays an important role in connecting IoT
devices.
Bluetooth protocol is mostly used in smart wearables, smartphones, and other mobile devices,
where small fragments of data can be exchanged without high power and memory. Offering
ease of usage, Bluetooth tops the list of IoT device connectivity protocols.
• ZigBee
ZigBee is an IoT protocol that allows smart objects to work together. It is commonly used in
home automation. More famous for industrial settings, ZigBee is used with apps that support
low-rate data transfer between short distances.
Street lighting and electric meters in urban areas, which provides low power consumption,
use the ZigBee communication protocol. It is also used with security systems and in smart
homes.
2. IoT Data Protocols
IoT data protocols are used to connect low power IoT devices. These protocols provide point-
to-point communication with the hardware at the user side without any Internet connection.
Connectivity in IoT data protocols is through a wired or a cellular network. Some of the IoT
data protocols are:
• Message Queue Telemetry Transport (MQTT)
One of the most preferred protocols for IoT devices, MQTT collects data from various
electronic devices and supports remote device monitoring. It is a subscribe/publish protocol
that runs over Transmission Control Protocol (TCP), which means it supports event-driven
message exchange through wireless networks.
MQTT is mainly used in devices which are economical and requires less power and memory.
For instance, fire detectors, car sensors, smart watches, and apps for text-based messaging.
• Constrained Application Protocol (CoAP)
CoAP is an internet-utility protocol for restricted gadgets. Using this protocol, the client can
send a request to the server and the server can send back the response to the client in HTTP.
For light-weight implementation, it makes use of UDP (User Datagram Protocol) and reduces
space usage. The protocol uses binary data format EXL (Efficient XML Interchanges).
CoAP protocol is used mainly in automation, mobiles, and microcontrollers. The protocol
sends a request to the application endpoints such as appliances at homes and sends back the
response of services and resources in the application.
• Advanced Message Queuing Protocol (AMQP)
AMQP is a software layer protocol for message-oriented middleware environment that
provides routing and queuing. It is used for reliable point-to-point connection and supports
the seamless and secure exchange of data between the connected devices and the cloud.
AMQP consists of three separate components namely Exchange, Message Queue, and
Binding. All these three components ensure a secure and successful exchange and storage of
messages. It also helps in establishing the relationship of one message with the other.
AMQP protocol is mainly used in the banking industry. Whenever a message is sent by a
server, the protocol tracks the message until each message is delivered to the intended
users/destinations without failure.
• Machine-to-Machine (M2M) Communication Protocol
It is an open industry protocol built to provide remote application management of IoT
devices. M2M communication protocols are cost-effective and use public networks. It creates
an environment where two machines communicate and exchange data. This protocol supports
the self-monitoring of machines and allows the systems to adapt according to the changing
environment.
M2M communication protocols are used for smart homes, automated vehicle authentication,
vending machines, and ATM machines.
• Extensible Messaging and Presence Protocol (XMPP)
The XMPP is uniquely designed. It uses a push mechanism to exchange messages in real-
time. XMPP is flexible and can integrate with the changes seamlessly. Developed using open
XML (Extensible Markup Language), XMPP works as a presence indicator showing the
availability status of the servers or devices transmitting or receiving messages.
Other than the instant messaging apps such as Google Talk and WhatsApp, XMPP is also
used in online gaming, news websites, and Voice over Internet Protocol (VoIP).
Machine-to-Machine (M2M)
Machine-to-machine, or M2M, is a broad label that can be used to describe any technology
that enables networked devices to exchange information and perform actions without the
manual assistance of humans. Artificial intelligence (AI) and machine learning (ML)
facilitate the communication between systems, allowing them to make their own autonomous
choices.
M2M technology was first adopted in manufacturing and industrial settings, where other
technologies, such as SCADA and remote monitoring, helped remotely manage and control
data from equipment. M2M has since found applications in other sectors, such as healthcare,
business and insurance. M2M is also the foundation for the internet of things (IoT).
How M2M works
The main purpose of machine-to-machine technology is to tap into sensor data and transmit it
to a network. Unlike SCADA or other remote monitoring tools, M2M systems often use
public networks and access methods -- for example, cellular or Ethernet -- to make it more
cost-effective.
The main components of an M2M system include sensors, RFID, a Wi-Fi or cellular
communications link, and autonomic computing software programmed to help a network
device interpret data and make decisions. These M2M applications translate the data, which
can trigger preprogrammed, automated actions.
The Internet and improved standards for wireless technology have expanded the role of
telemetry from pure science, engineering and manufacturing to everyday use in products such
as heating units, electric meters and internet-connected devices, such as appliances.
Beyond being able to remotely monitor equipment and systems, the top benefits of M2M
include:
boosted revenue by revealing new business opportunities for servicing products in the
field; and
Utilities companies often rely on M2M devices and applications to not only harvest energy,
such as oil and gas, but also to bill customers -- through the use of Smart meters -- and to
detect worksite factors, such as pressure, temperature and equipment status.
In telemedicine, M2M devices can enable the real time monitoring of patients' vital statistics,
dispensing medicine when required or tracking healthcare assets.
Time control, meaning data can only be sent or received at specific predetermined
periods.
Location specific triggers that alert or wake up devices when they enter particular areas.
Scalability - The M2M system should be able to continue to function efficiently as more
connected objects are added.
Anonymity - The M2M system must be able to hide the identity of an M2M device when
requested, subject to regulatory requirements.
Logging - M2M systems must support the recording of important events, such as failed
installation attempts, service not operating or the occurrence of faulty information.
The logs should be available by request.
Message transmission scheduling - M2M systems must be able to control network access
and messaging schedules and should be conscious of M2M applications' scheduling delay
tolerance.
While many use the terms interchangeably, M2M and IoT are not the same. IoT needs M2M,
but M2M does not need IoT.
Both terms relate to the communication of connected devices, but M2M systems are often
isolated, stand-alone networked equipment. IoT systems take M2M to the next level, bringing
together disparate systems into one large, connected ecosystem.
M2M systems use point-to-point communications between machines, sensors and hardware
over cellular or wired networks, while IoT systems rely on IP-based networks to send data
collected from IoT-connected devices to gateways, the cloud or middleware platforms.
Data collected from M2M devices is used by service management applications, whereas IoT
data is often integrated with enterprise systems to improve business performance across
multiple groups. Another way to look at it is that M2M affects how businesses operate, while
IoT does this and affects end users.
For example, in the product restocking example above, M2M involves the vending machine
communicating to the distributor's machines that a refill is needed. Incorporate IoT and an
additional layer of analytics is performed; the vending machine can predict when particular
products will need refilling based on purchase behaviors, offering users a more personalized
experience.
M2M security
M2M standards
Machine-to-machine technology does not have a standardized device platform, and many
M2M systems are built to be task- or device-specific. Several key M2M standards, many of
which are also used in IoT settings, have emerged over the years, including:
Sensor Nodes- Sensors play the vital role of capturing environmental variables.
Radio Nodes- Radio nodes or master nodes in a Wireless sensor network receive data
from the sensors and forward it to the gateway.
Access Point or Gateway-It is used to receive the data sent by the radio nodes
wirelessly typically through the internet and send it over the cloud.
Edge Computing and Data Analysis-The data received by the gateway is analyzed .
This data is further analyzed on the cloud and displayed on IoT mobile
application or IoT dashboard.
Features of RFID :
An RFID tag consists of two-part which is an microcircuit and an antenna.
This tag is covered by protective material which acts as a shield against the outer
environment effect.
This tag may active or passive in which we mainly and widely used passive RFID.
Application of RFID :
It utilized in tracking shipping containers, trucks and railroad, cars.
It uses in Asset tracking.
It utilized in credit-card shaped for access application.
It uses in Personnel tracking.
Controlling access to restricted areas.
It uses ID badging.
Supply chain management.
Counterfeit prevention (e.g., in the pharmaceutical industry).
Advantages of RFID :
It provides data access and real-time information without taking to much time.
RFID tags follow the instruction and store a large amount of information.
The RFID system is non-line of sight nature of the technology.
It improves the Efficiency, traceability of production.
In RFID hundred of tags read in a short time.
Disadvantages of RFID :
It takes longer to program RFID Devices.
RFID intercepted easily even it is Encrypted.
In an RFID system, there are two or three layers of ordinary household foil to dam the
radio wave.
There is privacy concern about RFID devices anybody can access information about
anything.
Active RFID can costlier due to battery.
SCADA
What is SCADA (supervisory control and data acquisition) and how does it work?
SCADA (supervisory control and data acquisition) is a category of software applications for
controlling industrial processes, which is the gathering of data in real time from remote
locations in order to control equipment and conditions. SCADA provides organizations with
the tools needed to make and deploy data-driven decisions regarding their industrial
processes.
One of the most commonly used types of industrial control system, SCADA can be used to
manage almost any type of industrial process.
SCADA systems include hardware and software components. The hardware gathers and
feeds data into field controller systems, which forward the data to other systems that process
and present it to a human-machine interface (HMI) in a timely manner. SCADA systems also
record and log all events for reporting process status and issues. SCADA applications warn
when conditions become hazardous by sounding alarms.
SCADA is sometimes compared with the industrial internet of things (IIoT), and while there
is considerable overlap, the two terms are different. SCADA vendors tend to provide more
complete, monolithic systems with tight integration across levels and devices, while IIoT
vendors are likely to provide greater interoperability and more options for deploying systems
and devices across an organization.
SCADA vs. IIoTWhile SCADA and IIoT have significant overlap, there are differences.
Features of SCADA systems
Although SCADA systems may include special features for specific industries or
applications, most systems support the following features:
Data acquisition is a foundation of SCADA systems; sensors collect data and deliver it to
field controllers, which, in turn, feed data to the SCADA computers.
Remote control is achieved through the control of field actuators, based on the data acquired
from field sensors.
Networked data communication enables all SCADA functions. Data collected from sensors
must be transmitted to SCADA field controllers, which, in turn, communicate with the
SCADA supervisory computers; remote control commands are transmitted back to actuators
from the SCADA supervisory computers.
Data presentation is achieved through HMIs, which represent current and historical data to
the operators running the SCADA system.
Real-time and historical data are both important parts of the SCADA system, as they enable
users to track current performance against historical trends.
Alarms alert SCADA operators to potentially significant conditions in the system. Alerts can
be configured to notify operators when processes are blocked, when systems are failing, or
when other aspects of SCADA processes need to be stopped, started or adjusted.
Reporting on SCADA system operations can include reports on system status, process
performance and reports customized to specific uses.
SCADA architecture
SCADA systems operate at five of the six levels defined in the Purdue Enterprise Reference
Architecture for enterprise integration:
Level 0. The field level includes field devices, such as sensors, used to forward data relating
to field processes and actuators used to control processes.
Level 1. The direct control level includes local controllers, such as PLCs and RTUs, that
interface directly with field devices, including accepting data inputs from sensors and sending
commands to field device actuators.
Level 2. The plant supervisory level includes local supervisory systems that aggregate data
from level controllers and issue commands for those controllers to carry out.
Level 3. The production control level includes systemwide supervisory systems that
aggregate data from Level 2 systems to produce ongoing reporting to the production
scheduling level, as well as other site or regionwide functions, like alerts and reporting.
Level 4. The production scheduling level includes business systems used to manage ongoing
processes.
SCADA system architectureSCADA system architecture spans from the shop floor to the
enterprise network.
SCADA use cases and industry examples
SCADA is used to assist in automating and managing industrial processes that have become
too complex or cumbersome for human monitoring and control. SCADA is particularly
useful for processes that can be monitored and controlled remotely, especially in cases where
it is possible to reduce waste and improve efficiency.
Some common industry examples of SCADA industrial automation are the following:
electricity generation and distribution;
oil and gas refining operations;
telecommunications infrastructure;
transportation and shipping infrastructure;
fabrication and other industrial processing;
food and beverage processing;
chemical manufacturing; and
utilities infrastructure, including water and waste control.
With SCADA, these processes can be monitored closely and tweaked to improve
performance over time.
As computing, networking, and process monitoring and control systems have improved,
SCADA evolved through the following four stages:
First generation: Monolithic systems. SCADA systems implemented in the 1960s and 1970s
usually incorporated RTUs at industrial sites connected directly to mainframe or
minicomputer systems, usually also on-site or connected over wide area network
Second generation: Distributed systems. SCADA systems took advantage of wide availability
of proprietary local area networks and smaller, more powerful computers during the 1980s to
enable greater sharing of operational data at the plant level and beyond. However, the lack of
open networking standards prevented interoperability across SCADA product vendors.
Third generation: Networked systems. SCADA systems depended on greater interoperability
provided by industry acceptance and incorporation of standard network protocols during the
1990s. SCADA systems could be scaled more easily, as enterprises were able to integrate
systems across their own industrial infrastructure, while using a wider variety of devices and
systems.
Fourth generation: Web- or IIoT-based systems. SCADA systems began appearing in the
early 2000s as SCADA vendors embraced web software development tools to enable
transparent interoperability and access via universally available interfaces, like web browsers
running on handheld devices, laptops and desktop computers.
As cloud computing increasingly dominates the enterprise computing world, it is also
changing SCADA systems. SCADA systems can be scaled faster and more easily by
allocating cloud computing resources as needed for surges and reducing those resources when
demand drops.
Modern SCADA systems that rely on network interoperability, distributed computing and
modern communication infrastructures offer better returns on investment of time and
resources.
Scalability. Modern SCADA systems are more scalable than legacy systems for several
reasons, including better availability of supported hardware and software and use of cloud
computing to meet workload demand.
Interoperability. Legacy SCADA systems rely on proprietary hardware and software,
resulting in vendor lock-in.
Communications. Modern SCADA systems support more widely supported and modern
communications protocols, which enable greater accessibility to SCADA data and controls.
Support. Legacy SCADA systems may have limited options for support, while modern
systems are more likely to be well supported by vendors. Use of commercial off-the-shelf
hardware, open networking standards and modern software development platforms makes
third-party support more accessible as well.
Improvements to computing are reflected in successive generations of SCADA systems, as
well as with security issues in general. Learn how SCADA and IIoT systems can expose the
enterprise to security threats and how to defend against them.
PROTOCOLS
Introduction of IEEE 802.15.4 Technology
IEEE 802.15.4 is a low-cost, low-data-rate wireless access technology for devices that are
operated or work on batteries. This describes how low-rate wireless personal area networks
(LR-WPANs) function.
Properties:
1. Standardization and alliances: It specifies low-data-rate PHY and MAC layer requirements
for wireless personal area networks (WPAN).
IEEE 802.15. Protocol Stacks include:
ZigBee: ZigBee is a Personal Area Network task group with a low rate task group 4. It is a
technology of home networking. ZigBee is a technological standard created for controlling
and sensing the network. As we know that ZigBee is the Personal Area network of task group
4 so it is based on IEEE 802.15.4 and is created by Zigbee Alliance.
6LoWPAN: The 6LoWPAN system is used for a variety of applications including wireless
sensor networks. This form of wireless sensor network sends data as packets and uses IPv6 –
providing the basis for the name – IPv6 over Low power Wireless Personal Area Networks.
ZigBee IP: Zigbee is a standards-based wireless technology that was developed for low-cost
and low-power wireless machine-to-machine (M2M) and internet of things (IoT) networks.
ISA100.11a: It is a mesh network that provides secure wireless communication to process
control.
Wireless HART: It is also a wireless sensor network technology, that makes use of time-
synchronized and self-organizing architecture.
Thread: Thread is an IPv6-based networking protocol for low-power Internet of Things
devices in IEEE 802.15. 4-2006 wireless mesh network. Thread is independent.
2. Physical Layer: This standard enables a wide range of PHY options in ISM bands, ranging
from 2.4 GHz to sub-GHz frequencies. IEEE 802.15.4 enables data transmission speeds of 20
kilobits per second, 40 kilobits per second, 100 kilobits per second, and 250 kilobits per
second. The fundamental structure assumes a 10-meter range and a data rate of 250 kilobits
per second. To further reduce power usage, even lower data rates are possible. IEEE 802.15.4
regulates the RF transceiver and channel selection, and even some energy and signal
management features, at the physical layer. Based on the frequency range and data
performance needed, there are now six PHYs specified. Four of them employ frequency
hopping techniques known as Direct Sequence Spread Spectrum (DSSS). Both PHY data
service and management service share a single packet structure so that they can maintain a
common simple interface with MAC.
3. MAC layer: The MAC layer provides links to the PHY channel by determining that
devices in the same region will share the assigned frequencies. The scheduling and routing of
data packets are also managed at this layer. The 802.15.4 MAC layer is responsible for a
number of functions like:
Beaconing for devices that operate as controllers in a network.
used to associate and dissociate PANs with the help of devices.
The safety of the device.
Consistent communication between two MAC devices that are in a peer-to-peer relationship.
Several established frame types are used by the MAC layer to accomplish these functions. In
802.15.4, there are four different types of MAC frames:
frame of data
Frame for a beacon
Frame of acknowledgement
Frame for MAC commands
4. Topology: Networks based on IEEE 802.15.4 can be developed in a star, peer-to-peer, or
mesh topology. Mesh networks connect a large number of nodes. This enables nodes that
would otherwise be out of range to interact with each other to use intermediate nodes to relay
data.
5. Security: For data security, the IEEE 802.15.4 standard employs the Advanced Encryption
Standard (AES) with a 128-bit key length as the basic encryption technique. Activating such
security measures for 802.15.4 significantly alters the frame format and uses a few of the
payloads. The very first phase in activating AES encryption is to use the Security Enabled
field in the Frame Control part of the 802.15.4 header. For safety, this field is a single bit
which is assigned to 1. When this bit is set, by taking certain bytes from its Payload field, a
field known as the Auxiliary Security Header is formed following the Source Address field.
6. Competitive Technologies: The IEEE 802.15.4 PHY and MAC layers serve as a basis for a
variety of networking profiles that operate in different IoT access scenarios. DASH7 is a
competing radio technology with distinct PHY and MAC layers.
IEEE 802.15.4
Advantages of IEEE 802.15.4:
IEEE 802.15.4 has the following advantages:
cheap cost
long battery life,
Quick installation
simple
extensible protocol stack
Disadvantages of IEEE 802.15.4:
IEEE 802.15.4’s drawbacks include:
IEEE 802.15.4 causes interference and multipath fading.
doesn’t employ a frequency-hopping approach.
unbounded latency
interference susceptibility
Applications of IEEE 802.15.4:
IEEE 802.15.4 Applications:
Wireless sensor networks in the industry
Building and home automation
Remote controllers and interacting toys
Automotive networks
It is used in different markets like Industrial, It is used in different markets like Lighting, Life
Energy Management, Transportation, Building Safety, Access Controls, HVAC, transportation
Automation, Regulatory, health & security. & maintenance.
Network Interfaces: Existing LANs &LANs Network Interfaces: Traditional serial & Ethernet
infrastructure. protocols.
Examples: Measurements of Tank Level. Boiler Examples: Tasks like fan schedule, sending a
Control. status alarm, and requesting temperature reading.
Advantages
The advantages of the Bacnet Protocol include the following.
BACnet protocol is particularly designed for building automation as well as control
networks.
It doesn’t depend on present LAN or WAN technologies.
It is an American National Standard & a European pre-standard.
It is scalable completely from small single building applications to universal networks of
devices.
The implementers of BACnet can securely include non-standard extensions as well as
enhancements without influencing existing interoperability.
It is adopted by the most famous fire protection companies in both the USA & Europe.
It is supported by different chiller manufacturers like Dunham-Bush, Carrier, McQuay,
York & Trane.
In real building control applications, this protocol has a proven track record.
Disadvantages
The disadvantages of the Bacnet Protocol include the following.
The main drawback of the BACnet protocol was a compliant problem. So because of this
issue, the BTL (BACnet Testing Laboratories) was introduced in the year 2000. BTL is
compliance & and independent testing organization. The main intention of this is to test the
products of BACnet to verify compliance with the standard. Once approved; the product will
get the logo of BTL.
The problems or net-worthy attacks which are widely found in this protocol are; Lack of
spoofing & authentication, DoS attacks, immobilized network connections, and lack of
encryption & write access over devices.
Applications
The use of Bacnet Protocol includes the following.
The BACnet is used in HVAC applications, fire control lighting control, security, alarm &
interfacing to utility companies.
This protocol was particularly designed for building automation as well as control
applications.
This protocol is used to provide mechanisms, especially for automation devices for
exchanging data irrespective of the specific building service they perform.
This protocol can be used by digital controllers, computers & application-specific
otherwise unitary controllers with equivalent effect.
BACnet protocol was initially developed to develop interoperability between building
automation devices; however, its data descriptions, as well as flexible architecture, will
make it work within a broad range of control applications.
This is an object-oriented protocol, so used to signify network-accessible control
equipment.
Thus, this is an overview of Bacnet protocol – working with applications.
What is Modbus?
Modbus is a serial communication protocol for use with programmable logic controllers. It is
typically used to transmit signals from instrumentation and control devices back to a main
controller; or data gathering system, for example a system that measures temperature and
humidity and communicates the results to a computer, according to Simply Modbus.
How does it work, and why use it for IoT?
The method is used for transmitting information over serial lines between electronic devices.
The device requesting information is called “master” and “slaves” are the devices supplying
information. In a standard Modbus network, there is one master and up to 247 slaves, each
with a unique slave address from 1 to 247.
According to Intel, communication between a master and a slave occurs in a frame that
indicates a function code. The function code identifies the action to perform, such as read a
discrete input; read a first-in, first-out queue; or perform a diagnostic function. The slave then
responds, based on the function code received, with a response indicated by a set of bytes.
Slaves can therefore be intelligent devices or simple devices that represent a single sensor.
Because of this operation, systems based on the protocol are critical parts of the industrial
“internet of things” for automation and control, housing valuable information that can be
unlocked and used by analytics and enterprise systems.
The protocol is commonly used in IoT as a local interface to manage devices. It is an open
protocol that is free for manufacturers to build their equipment into, and is now the most
commonly available means of connecting industrial electronic devices, according to Simply
Modbus.
Benefits of using Modbus
These are some advantages of using Modbus, as outlined by the Modbus Organization:
If a Modbus driver is already installed and the user is familiar with Ethernet and TCP/IP
sockets, a driver can be up and running and talking to a PC in a few hours. Development
costs are said to be low; minimum hardware is required; and development is said to be
easy under any operating system.
There are no “exotic” chipsets required and the system can use standard PC Ethernet cards
to talk to newly implemented device; as the cost of Ethernet falls, there should be a cost
reduction in hardware; and users are not tied to one vendor for support, but can benefit
from current developers.
The specification is available free of charge for download, and there are no subsequent
licensing fees required for using Modbus protocols.
Interoperability among different vendors’ devices and compatibility with an installed base
of compatible devices.
KNX Technology
The Preferred International Standard for Building Automation
KNX is a communication protocol developed for — and widely used in —home and building
automation. It is a standardized (EN 50090, ISO/IEC 14543), OSI-
based network communications protocol that is administered by the KNX Association.
The standard is based on the communication stack of the European Installation Bus (EIB) but
enlarged with the physical layers, configuration modes, and application experience of
BatiBUS and EHS.
KNX defines several physical communication media:
Twisted pair wiring (inherited from the BatiBUS and EIB Instabus standards)
Powerline networking (inherited from EIB and EHS– similar to that used by X10)
Radio Frequency (KNX-RF)
Infrared
Ethernet (also known as EIBnet/IP or KNXnet/IP)
The Radio Frequency Versions: KNX RF, RF Ready, and RF Multi
Radio Frequency KNX is the wireless version of the KNX physical layers. KNX RF can
share the application layers with the other media versions of KNX, so it’s completely
compatible on the application level, making KNX RF an ideal complement to wired or IP
KNX.
Currently there are three variants of the KNX RF specification:
1. The original KNX RF.
2. KNX RF Ready, which added some features to be forward compatible with KNX RF
Multi.
3. And KNX RF Multi, designed to meet some of the shortcomings of the previous
protocol while improving reliability by using more than one RF channel.
The original KNX RF was specified in Supplement 22 of the KNX Specification 1.1 [KNX].
KNX RF operates at 868.3 MHz using FSK modulation at a data rate of 16.4 kbit/s. The PHY
and MAC layers of KNX RF were defined jointly by the EN 13757-4:2005 (Wireless M-Bus)
standard for wireless meter reading, allowing some degree of interoperability between the
two protocols.
KNX RF allows unidirectional (transmit-only) devices, in addition to conventional
bidirectional ones. By eliminating the receiver function, the device designer can extend the
battery lifetime of building automation sensors.
KNX RF Device Addressing Scheme
Due to the nature of wireless communication and the support of transmit-only devices, KNX
RF uses its own addressing scheme which is different from (although similar to) the standard
KNX addressing scheme. Since RF is an open medium, the address spaces of neighboring
installations would interfere with each other. Therefore, it has to be guaranteed that each
KNX RF installation has its own address space. Extended addresses are used for this purpose.
An extended address is defined as the combination of the traditional KNX address and the
serial number (SN) of the device.
KNX RF Multi: Expanding to Multiple Frequencies
Two new versions were added to the standard KNX RF Ready as an intermediate forward
compatible version, and then finally the KNX RF Multi was released. The main difference
between KNX RF Ready and KNX RF Multi is in the use of frequencies. KNX RF Ready can
only communicate at a center frequency of 868.3 MHz, but it can co-operate with KNX RF
Multi.
Switching Between Fast & Slow Channels in KNX RF Multi
With KNX RF Multi it is possible to switch between three “fast” and two “slow” channels. If
there is interference, the KNX RF Mulit device will automatically change channel.
The fast channels are intended for human activities, such as switching on or dimming lights,
that require fast response times. The slow channels are for applications which do not need
low latency, such as heating, ventilation and air-conditioning (HVAC).
On the fast channels the data rate is 16.384 kbit/s and on the slow channels it’s 8.192 kbit/s.
KNX RF Multi offers the further benefit of immediate acknowledgement of the telegrams
sent. These are called »Fast Immediate Acknowledge« (IACK).
Wireless Range of KNX RF
The typical line-of-sight range of KNX RF at 868 MHz is 150 meters. Within a building the
range very much depends on the actual environment, building materials, etc. Under good
circumstances ranges of 30 meters are possible within a building. That said, device designers
should conservatively plan on a range of 20 meters so that a “range reserve” is available.
KNX RF also support multi-hop repeaters to extend the range.
Benefits of Using KNX RF
Fully compatible on an
Intermediate Standard designed application level with Supports long-life
for Building Automation other KNX media: battery operation
Twisted pair, PLC and
Ethernet
Zigbee PRO aims to provide the foundation for IoT with features to support low-cost, highly
reliable networks for device-to-device communication. Zigbee PRO also offers Green Power,
a new feature that supports energy harvesting or self-powered devices that don't require
batteries or AC power supply.
Zigbee RF4CE is designed for simple, two-way device-to-device control applications that
don't need the full-featured mesh networking functionalities offered by the Zigbee
specification.
Zigbee IP optimizes the standard for IPv6-based full wireless mesh networks, offering
internet connections to control low-power, low-cost devices.
Mesh networking
A key piece of the Zigbee protocol is its ability to support mesh networking. Zigbee uses a
mesh network architecture for communication.
A mesh network is a local area network (LAN), wireless LAN (WLAN) or virtual LAN
(VLAN) that employs one of two decentralized connection arrangements: full mesh topology
or partial mesh topology.
Zigbee layers
In a full mesh topology, each network node is connected directly to other nodes. In a partial
mesh topology, some nodes are connected to all the others, but some are only connected to
nodes they exchange the most data with.
The Zigbee protocol defines three types of nodes: coordinators, routers and end devices.
Although all nodes can send and receive data, they each play a different role.
There is one coordinator in each network whose job is to store information about the network,
including security keys. Routers are intermediate nodes, relaying data from other devices.
End devices can be low-power or battery-powered devices, which can talk to the coordinator
or a router, but can't relay data from other devices.
Zigbee Alliance
The Zigbee Alliance works to simplify wireless product integration to help product
manufacturers introduce energy-efficient wireless control into their products faster and more
cost-effectively. Alliance members create standards that offer reliable, secure, low-power and
easy-to-use wireless communication, using an open standards development process to guide
their work. The alliance is organized by committees, work groups, study groups, task forces
and special interest groups.
Zigbee Alliance
There are three types of membership with different rights and benefits:
Zigbee is also used by vendors that provide connected lighting products for homes and
businesses. With Zigbee-based smart home products, consumers can control LED figures,
lightbulbs, remotes and switches in home and remotely to improve energy management.
Utility companies can use Zigbee in their smart meters to monitor, control, inform, and
automate the delivery and use of energy and water. Smart meters give the consumers the
information -- and automation -- needed to reduce energy use and save money.
Zigbee-based products also enhance the shopping experience for consumers by enabling
faster checkouts, in-store assistance and in-store item location. Zigbee helps retailers operate
more efficiently by ensuring items don't run out of stock and supporting just-in-time
inventory practices, as well as monitoring temperatures, humidity, spills and so on.
Zigbee supports a number of devices, including intelligent shopping carts, personal shopping
assistants, electronic shelf labels and asset tracking tags.
Network Layer
o The Network Layer is the third layer of the OSI model.
o It handles the service requests from the transport layer and further forwards the
service request to the data link layer.
o The network layer translates the logical addresses into physical addresses
o It determines the route from the source to the destination and also manages the traffic
problems such as switching, routing and controls the congestion of data packets.
o The main role of the network layer is to move the packets from sending host to the
receiving host.
The main functions performed by the network layer are:
o Routing: When a packet reaches the router's input link, the router will move the
packets to the router's output link. For example, a packet from S1 to R1 must be
forwarded to the next router on the path to S2.
o Logical Addressing: The data link layer implements the physical addressing and
network layer implements the logical addressing. Logical addressing is also used to
distinguish between source and destination system. The network layer adds a header
to the packet which includes the logical addresses of both the sender and the receiver.
o Internetworking: This is the main role of the network layer that it provides the
logical connection between different types of networks.
o Fragmentation: The fragmentation is a process of breaking the packets into the
smallest individual data units that travel through different networks.
Services Provided by the Network Layer
o Guaranteed delivery: This layer provides the service which guarantees that the
packet will arrive at its destination.
o Guaranteed delivery with bounded delay: This service guarantees that the packet
will be delivered within a specified host-to-host delay bound.
o In-Order packets: This service ensures that the packet arrives at the destination in
the order in which they are sent.
o Guaranteed max jitter: This service ensures that the amount of time taken between
two successive transmissions at the sender is equal to the time between their receipt at
the destination.
o Security services: The network layer provides security by using a session key
between the source and destination host. The network layer in the source host
encrypts the payloads of datagrams being sent to the destination host. The network
layer in the destination host would then decrypt the payload. In such a way, the
network layer maintains the data integrity and source authentication services.
The network layer is divided into two sublayers: routing layer which handles the transfer of
packets from source to destination, and an encapsulation layer that forms the packets.
RPL Protocol
RPL stands for Routing Protocol for Low-Power and Lossy Network. It is a distance-vector
protocol that supports a varity of Data Link Protocols. RPL builds a Destination Oriented
Directed Acyclic Graph (DODAG) which has only one route from each leaf node to the
root. All the traffic in this DODAG is routed through the root. Initially, each node sends a
DODAG Information Object (DIO) announcing them self as a root. This information travels
in the network, and complete DODAG is gradually built. When a new node wants to join the
network, it sends a DODAG Information Solicitation (DIS) request and root responds back
with a DAO Acknowledgment (DAO-ACK) confirming the join.
CORPL Protocol
CORPL protocol is the extension of the RPL protocol, which is termed as cognitive RPL.
This network protocol is designed for cognitive networks and uses DODAG topology.
CORPL protocol makes two new modifications in the RPL protocol. It uses opportunistic
forwarding to forward a packet between the nodes. Each node of CORPL protocol keeps the
information of forwarding set rather than parents only maintaining it. Each node updates its
changes to its neighbor using DIO messages. On the basis of this updated message, each node
frequently updates its neighbor for constant forwarder set.
CARP Protocol
The 6LoWPAN protocol refers to IPv6 Low Power Personal Area Network which uses a
lightweight IP-based communication to travel over low data rate networks. It has limited
processing ability to transfer information wirelessly using an internet protocol. So, it is
mainly used for home and building automation. The 6LoWPAN protocol operates only
within the 2.4 GHz frequency range with 250 kbps transfer rate. It has a maximum length of
128-bit header packets.
6LowPAN Security Measure
Security is a major issue for 6LowPAN communication Protocol. There are several attacks
issues at the security level of 6LoWPAN which aim is to direct destruction of the network.
Since it is the combination of two systems, so, there is a possibility of attack from two sides
that targets all the layer of the 6LoWPAN stack (Physical layer, Data link layer, Adaptation
layer, Network layer, Transport layer, Application layer).
Properties of 6LowPAN protocol
o Standard: RFC6282
o Data Rates: NA
Okay. Don't ask me why the Application Support Sublayer uses the three-letter acronym
APS. It's obvious, but don't ask me.
The Application Support Sublayer, or APS, sits above the NWK layer, and is the layer in
ZigBee which understands applications. The APS frame over-the-air includes endpoints,
clusters, profile IDs, and even groups.
APS is responsible for the following activities:
Filtering out packets for non-registered endpoints, or profiles that don't match
Generating end-to-end acknowledgment with retries
Maintaining the local binding table
Maintaining the local groups table
Maintaining the local address map
APS has the job of filtering out packets for endpoints that don't exist in the node. APS filters
packets that don't match profile IDs. APS also filters duplicate packets, which can happen in
a network that supports automatic retries.
It's the job of APS to perform automatic retries, if acknowledgment is requested by the
sender, to maximum the chance of successful transmission and to inform the sender whether
or not the packet was delivered.
APS also maintains a variety of application-level tables. Binding is all about connecting an
endpoint on this node to one or more endpoints on other nodes. Groups are all about an
arbitrary collection of applications residing on an arbitrary set of nodes throughout the
network. The address map associates a 64-bit MAC address with a ZigBee 16-bit NwkAddr.
APS and the Application Framework (AF) together form the ZigBee interface used by
applications (see Figure 4.26). Lower layers are not called upon directly, but are used by APS
and ZDO.
Figure : Application Support Sublayer (APS)
The Application Framework does not have an over-the-airframe of its own, but instead is the
set of routines, or API, that the ZigBee stack vendor has chosen for applications to interact
with ZigBee. This includes how endpoints are implemented, and how data requests, confirms,
and indications are implemented for that particular vendor. In the Freescale solution, you've
already seen the Application Framework at work with the functions:
AF_DataRequest()
BeeAppDataConfirm()
BeeAppDataIndication()
To illustrate, take a look at Figure 4.27. Suppose a switch (the ZED) wants to turn on a light
(the ZR), and it wants to verify that the light received the command. The switch uses the
optional ACK feature in the AF_DataRequest() txOptions field.
The distance between the nodes is irrelevant. They could be neighbors, or 10 hops away. The
effect is the same.
Suppose the initial data request got through to the ZR. It then processes that command
immediately, perhaps toggling the light. But the APS ACK did not make it back, for some
reason. So APS will automatically retry after the time-out period (which defaults to 1.5
seconds). But this retry, labeled (2), doesn't make it through. APS tries again, and this time it
succeeds. Only then does APS inform the sender that the results were successful.
By the way, this scenario is extremely unlikely. It is used merely as an illustration. ZigBee
uses up to three MAC ACKs per hop, so unless the channel is so noisy that communication is
impossible, or the path is broken because one node has dropped off the network, or the
physical environment has changed (one of the routers along the route can no longer hear its
neighbors), APS ACKs are rarely called into play.
APS is smart enough not to send the packet up to the application twice. In Figure 4.27, both
(1) and (3) make it through, but because the data request was already heard at (1), the copy at
(3) will be dropped by the APS layer after it sends the ACK to the sender. Your application
doesn't have to have any special logic to handle duplicates. ZigBee does it for you.