0% found this document useful (0 votes)
36 views18 pages

WSN Unit 04 Notes

The document discusses the design and application protocols for Wireless Sensor Networks (WSN), emphasizing the importance of various protocols like HTTP, FTP, and SNMP in facilitating communication over the Internet. It highlights the challenges posed by the unique characteristics of WSN, such as limited data rates and memory, which necessitate the adaptation of existing protocols and the development of new ones. Key design issues include link layer constraints, networking challenges, host identification, compression needs, and security considerations in the context of 6LoWPAN.

Uploaded by

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

WSN Unit 04 Notes

The document discusses the design and application protocols for Wireless Sensor Networks (WSN), emphasizing the importance of various protocols like HTTP, FTP, and SNMP in facilitating communication over the Internet. It highlights the challenges posed by the unique characteristics of WSN, such as limited data rates and memory, which necessitate the adaptation of existing protocols and the development of new ones. Key design issues include link layer constraints, networking challenges, host identification, compression needs, and security considerations in the context of 6LoWPAN.

Uploaded by

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

lOMoARcPSD|51489847

WSN UNIT 04 - notes

wireless sensor network design (Misrimal Navajee Munoth Jain Engineering College)

Scan to open on Studocu

Studocu is not sponsored or endorsed by any college or university


Downloaded by ??????? ([email protected])
lOMoARcPSD|51489847

UNIT 4

APPLICATION
4.1. INTRODUCTION

.The internet and especiallythe web has become ubiquitouspartly because of its
ability to represent content in a universal way using a common application
protocol-theHypertextTransferProtocol (HTTP).
&The most widely ùsed applicationprotocol supportingthe web pages and web
services. There are a large number of important applicationprotocols used on
the Internet.

&Example, the File Transfer Protocol (FTP), Real Time Protocol (RTP), Session
Initiation Protocol (SIP), Service Location Protocol (SLP) and the Simple
Network ManagementProtocol (SNMP).
# Applicationprotocol can be defined as all the messages and methods having to
do with inter process communicationvia the Internetprotocol.
4The application layer depends on the transport layer to provide host to host
communicationand port multiplexingallowing multiple access to communicate
between end points simultaneously.
* The Intermet of things makes use of most of the same application
protocols used
in the Internet for communication between machines and services for auto
Configurationand for managingnodes and networks.
* Wireless Embedded Internet with 6LoWPAN, It is a
challengingin this respect
having smallframe sizes, limited data rates, limited memory, sleepingnode
ycle along with the mobiling of devices make the design of new application
protocolsand the adaptationof existing onesdifficult.

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

Application
Wireless Sensor Network Desipy
4.2
processes using well defined
We services enable the communicationbetween
4.3
App
Access Protocol (SOAP) or
message sequences with the Simple Object
(REST) style design.
StatelessResourceswith RepresentationalState Transfer App UDP
UDP
App
specific
Wireless Embedded Intermet svstems are usually designed tor a App
network. App
pupose, for example a facility management
* Currently, large building automation systems are preconfiguredto function in App App
that environment require management, for example, SNMP often make use of
TCP
TCP App
industry specific protocolssuch as BACnet. App
& A home automation system on the other hand requires service discovery App
protocols such as SLP, and may make use of web-service style or proprietary Fig. 4.1.
protocolsfor data and management. Applications process communicationoccurs through Internt
sockets
* Although the Intemet protocol provides basic packet networking over A Although the Internet Protocol provides basic
heterogeneous linkS, it is UDP and TCP that allow for the large range of heterogeneous links, it is UDP and TCP that allowpacket networking over
for the large range of
applicationprotocols by providing best efort (UDP) and reliable connection applicationprotocols by providing best-effort (UDP) and reliable connection
oriented (TCP). oriented(TCP) multiplexedcommunicationsbetween
applicationprocesses.
4 Wireless Embedded Intermet systems are usually designed for a specific 4 IP protocols use a socket-based approach, where
process end-points are
purpose, for example a facility management network or for a simple home identifiedby 16-bit source and destinationport identifiers.These are commonly
automation system. These two examples happen to have widely different called Internet sockets or network sockets. The concept is illustrated in
applicationprotocolrequirements. Figure 4.1.
4 Currently, large building automationsystems are pre-configuredto function in 4 The communicationbetween any twO end-pointsis uniquely identifiedfor cach
that environment,require managementwith e.g. SNMP, and often make use of
transportby a four-tupleconsistingof the local and renotesocket addresses:
industry-specificprotocolssuch as BAChet.
4 Ahome automation system on the other hand requires service discovery {src IP address,sre port, dst IP address,dst port)
protocols such as SLP, and may make use of web-service style or proprietary Applicationprotocols use a socket API to access datagram socket (UDP) and
protocols for data and management. What makes 6LoWPAN very different Stream sSocket(TCP) transport services along with raw socket (IP) services
from vertical communicationsolutions is that the same within a protocol stack. The different types of sockets are completely
network can be used by can be used
a large variety of devices running different applications thanks to the independent of each other (e.g. UDP port 80 and TCP port 80
Internet
model. simultaneously).
& All the compression of UDP ports down to a range of 16
protocols mentioned above can be run over the same IP * OLoWPAN supports the of
network LoWPAN usually has a limited number
infrastructure, simultaneously. IP uses what is often called a horizontal Which is useful because a wireless
is poorlysuited to lossy
networking approach. applications.TCP is not easy to compress,and
congestionavoidancedesign.
mesh networksbecauseof its
Downloaded by ??????? ([email protected])
lOMoARcPSD|51489847

Apylication

4.4 Wireless Sensor Network Design Other widely used


4 For these reasons UDP is mainly used with 6LoWPAN as it is simple,
protocols
toted in Figure 4.2 as such as TCP,
HTTP,
4.5
their FTP,
compressible,and suits most applicationsprotocol needs. Figure 4.2 shows a interesting candidates for
use with importance
on the
Intemet
SIP and SOAP are
as awhole
layered map of all the protocols. This is by no means exhaustive as there are to
needs be done to
adapt orimprove6LoWP
them.
AN, although considerablemakeworkthem
still
hundreds of IP-based protocols.There are however, a limited number which are
4 Examples of such
suitable for use with 6LoWPAN.
TinySIP. When adaptation efforts include eg
are a number of
designing application protocols
embedded web
for use with servicesthereand
oBIX requirements need to be met. These are 6LoWPAN
low-power,lossy nature of
that
mostly due to the
iges. limited memory in wireless mesh technologiesalong with limited frame
RDF sOAP - ocG nodes, low data-ratesand
network simplifications.
SLP MQTT-S
Eurthermore, the nature of the embedded applications and
CAP SNMP RTP NanoWS SIF devices put new requirementson
applicationprotocols. battery-powered
UDP TCP 4.2. DESIGN ISSUES

& Application protocols used over 6LoWPAN need to take a mumber of


6LoWPAN/IPV6
reguirements into account which are typically not an issue over general P
address. These issues includes:
Fig. 4.2. The relationshipof common IP protocols
1) Link layer
* Inthe figure, these protocols are indicated in bold to indicate that they have 2) Networking
either been designed for or are easily adaptable to 6LoWPAN. The MO
3) Host issues
Telemetry Transport (MQTT) was developed by IBM for large-scaleenterprise
telemetrysystems and is also suitable for use in sensor networks with MØTTS. 4) Compression
The ZigBee Compact Application Protocol (CAP) allows for any ZigBee S) Security
profile to be used over UDP, bringing ZigBee and IP closer together. Industry
4 The above issues are illustrated in the Figure 4.3. Mobility node identification
specific protocols such as BACnet and oBIX for building automation are also
covered. The Simple Location Protocol (SLP) allows for service discovery and sleep cycles are caused by node design and node properties.
motivating end-t0-end
while the Simple Network Management Protocol (SNMP) is widely used for. + Intermediate 6Lo WPAN Routers are a security risk,
management. applicationsecurity.
bandwidthand frame size limitations.
4 Finally the real-time protocol allows for The wirelesslink layer introduces
streamed real-time media to be deal with compressionfirewallsand
UDP
transported over UDP which is an important function for audio, video and rinallyat the edge router, we need to
sensor data streams. port space.

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

Ayplication

Wireless Sensor Network Design nature of radio


A The
4.6
receiver propagat i o n het e r o geneous
sensitivity asymmetrical linkstransmi
4.7
result in
directionbut not in the
other.
ssionamplification and
with packet
Radio fading and successful in one
mobility
causes the
IPv6 Internet
Application
vary from
range to
packet to packet. subset of neighbors within symmetrical
4 The lossy nature of links and the use of
UDP motivatesthe use of end to end
applicationreliabilityfeatures.
Router
Compression amulti
a hop network, multicast with a
mappedtoa flood.
scope larger than linklocal,is often
UDP Port space
Lossy line
Frame size bandwidth .The most limiting feature of ISM band radios
limited bandwidth. their small frame size and
R Multicast
Application
, The IEEE 802.15.4 has a physical layer 127 bytes in
security AApplidation length, resulting in
Node identification 12-116 best of availableUDP payload dependingon the MAC &6LoWPAN
Sleep cycdes LoWPAN features in use.
Mobility A Some link layers have even small frame sizes,
where as others may have frames
occur in a LoWPAN as large as hundredsof bytes.
Fig. 4.3. Applicationdesign issues to considerand where they
& The data rate over these radio are typically 20 - 250 kbits/secondshared by all
4.2.1. LINK LAYER nodes on the channel and quickly reducedover multiplehops.
+ Link layer issues include lossy asymmetrical links, typical payload sizes of 4 Existing protocols should be optimized to reduce the size of packet payloads
70-100 bytes limited bandwidthand no native multicastsupport compressed end to end or compressed intemediately in order to maintain
such as
4 6LoWPAN enables the use of low power radio technologies compatibilitywith existingIntemetapplications.
IEEE 802.15.4 and other ISM band radios.
4.2.2. NETWORKING
These radios are very different in nature from IEEE 802.11 WLANs Bluetooth over 6LoWPAN and is
or cellular radios which support the use of standard IP protocols and * UDP has the most favorable characteristicsfor use
justifieduse,
applications. universallysupportedin protocol stacks. Although TCP has some universal
transportor modified TCP to become
t Would require a new reliable
Medium access control, for example, IEEE 802.15.4 is achieved using Carrier
over 6LoWPAN.
Sense Multiple Access (CSMA)with a limited number of retransmissionsfor connection-oriented
rely on TCP for a reliable
link layer unicast frames. Many Internet protocols today protocols mainlymake
compatibleapplication
Dyte stream, Instead.6LoWPAN to deal with reliability
4 In the presenceof radio interferenceor packet collisionthere can be high packet the applicationprotocolneeds streams.
loss ratios. Se of UDP, whichmeans rather than
if needed, out-of-orderpacketsand datagrams

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

pgelieatton
The intermittent
Wireless Sensor Network Design 4 node
4.8
be takeninto availability due to mobility and sleeo
account during
4.9
4 lf the UDP sourre or destinationports are compressed, then thc port space can application schedules
needs
synchronous rolling of design.
For example, the to
be limited down to l6 ports (ports 61616-61631). Alhough 6LoWPAN
communicationshouldLoWPAN
be avoided. Instead nodes from aserver should
supports fragmentation in onder to handle larger payloads coming in from be node
when possible.
outside the LoWPAN, the fragmentation of large payloads inereases delay, initiatedand asynchronous
packet loss probabilityand congestion. 42.4. COMPRESSION
a ltis recommendedto use applicationlayer payload lengths that avoid the nccd
4 The small payload sizes
for 6LoWPAN fragmentation
existing protocols.
available often require compression to be used on
4.2.3. HOST ISSUES
.The minimal payload available
4 The typical Intermet hosts 6LoWPAN hosts & networks are often mobile in combine with fragmentationperformanceissues
requires applicationprotocolsto use very compact
nature during operation. formats.
Some applicationsprotocolsare directly
Battery powered nodes often use sleep periodwith duty cycle often between 1-5 useful with 6LoWPAN such as RTP.
Other existing protocols or have been slightly
percent.
when used with 6LoWPAN, These include MATT. adapted to make them efficient
* A node may be identifiedin many ways, for example, IPv6 address or domain SNMP, SLP, and BACnet.
& It is designed for the web usually based on
name. HTTP/TCP are not well suited for
use over 6LoWPAN.
4 The identificationof a device is especiallyimportant in embedded application.
For example in the monitoringof machines for maintenance & HTTP uses a text based human reliable format which takes space and is
difficult
4 The device can be identified by an application using some unique identifier to parse on simple embeddeddevices.
such as its EUI.64 a serial number IPv6 address of the node or by its domain 4 XML - universallyused for the machine to machine content carried in HTTP
name. such as SOAP.
* The IPv6 address changes each time the LoWPAN node or the whole Lo WPAN * Techniqueto compressXML such as web serviceparadigms.
changes its point of attachmentsis employed.
*When applyingcompressionfor web servicesan impotantdesign consideration
* The unique serial number such as the EUI-64 of the device is a reliable is whether to use compressionend to end or implement it with a proxy.
identifier. But it must still be resolved to the IPv6 address of the device for
communicationby the applications. 42.5. SECURITY
LoWPAN.
4 The most application friendly method is to use a domain name to identify a OLoWPANdepend on link layer encryption for securinglinks in the
device which is updated with the current IPv6 address of the device each time it intermediatehope and understood by all
moves using appropriateDNS technique. * Link layer encryptionis vulnerableat
node using the same encryptionkey.
4 Battery powered nodes are implemented to take advantage of
aggressive sleep applicationlevel informationwhich wouldbe
schedule in order to extend battery life. "t 1S not very useful for securing after being routed
over other IP networks
4 It is even common for a node to be active less Vulnerableat intermediatenodes and
than l percent of the time.
outside the LoWPAN.
Downloaded by ??????? ([email protected])
lOMoARcPSD|51489847

Application

4.10 Wireless Sensor Network Design Appliçation


UDP 4.11
+ If an applicationis working with sensitivedata then it should apply end-to-end
applications. IPv6 LOWPAN Application
* Many embedded enterprise system may also deal with sensitive patient or
customer information.
DLL
PHY
IpveWPAN UUP
IPV6
4 Unlike the personal computerson which people make a large effort to maintain PHY PHY
sophisticated firewalls for internet security-embedded capabilities for PHY
Application
complicatedfirewalls.
Proxy
+ Special attention should be paid to firewall technology on the edge router to IPv6 LOWPAN UDP Application
LoWPANs to prevent unwanted applicationprotocol trafic from entering and IPv6 LOWPAN
existingLoWPANS,also avoidingdenialof service situations. D;L IPN6
DUL
PHY DU
PHY PHY PHY
4.3+ PROTOCOL PARADIGMS 6LOWPANEnd Point
Intermediate IP End-Point
4 There is a basic set of paradigms by which most internet applicationprotocols Fie. 4.4. End-to-End and
function. These includes
Proxied applicationprotocolparadigms
&The above figure shows the difference
1. End-to-Endparadigm between an end to end application
protocol exchange and a proxiedone.
2. Streaming
4 The end to end paradigm is
3. Sessions significant in the realization of protocol
compression.
4. Publish / Subscribe
5. Web services 4 Protocol compression of an existing protocol can be achieved either by
supporting the compressed format natively on the IP application end point
43.1. END-TO- END which is an end to end approach.
4 The internet socket model is based on the use of the underlyingtransportlayer
* Intermediateproxy perform transparentcompressionso that IP applicationsdo
to provide a transparent datagram or byte stream service between application
not need modification.
process or so called applicationend points.
4 Considering,the application layer, this can be called an end-to-end paradigm *A typical place to situate such a proxy would be on the edge router of a
where only the end point participatein the application protocolexchanges. LoWPAN or on some local proxy server.
Some application protocols also include the possibility for intermediatenodes
to aspect cache or modify applicationprotocols.
Example: HTTP proxy that perform web page caching

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

opliation

WirelessSensor Network Desigm SERVICE PARADIGMS


|4.12 |4.13
Webservices
are
4.3.2. REALTME
STREAMING AND SESSIONS 4 defined by the WBC as a
interoperable machine
applicationfor embedded networks
deal with realtime data stream such
to
machine softwareoversystem
a designedto suppor
4 Many
as sensor data, audio or
video.
Whole commonly work
typeofservice. between communicationnetwork.
clients and server over
effort approach without Qualityof Servies HTTP. There are two
The intermet protocolworks on best 1) Service
(QoS).
based (SOAP)
2)
significantjitter. Resource based (REST)
Packet may arriveout of order or with # Service
based web
applicationsas a reliable transportlike
services are XML following the
4 TypicallyUDP is employed for real time remotee procedure calls SOAP format to provide
(RPCS) between clientsand servers
TCP may make jitter worse.
The soap messages and
sequences can be (SOAP).
performing streaming described using the
4 Operationsto be performed by an application protocol
transmission and stream
deseriptionlanguage. web services
include session setup stream encoding, payload Example
control.

It provide good framework for working


with real time streams. http:/sensorio.example.com/soap methods
get sensor state (sensorlD)
streams with appropriate
4 The real time transport protocol encapsulates get sensOr value (sensorlD)
information while the companion RTP control
stonestamp and sequence
get config (parameter,value)
protocol is used to control the stream.
receiver of a stream need to be get config(parameter)
4 If a relationship between the sender or
automaticallysetup and configured. 4 The RepresentationalState Transfer (REST) paradigm instead models objects
4.3:3. PUBLISH/ SUBSCRIBE as HTTP resourceseach with a URL accessibleusing standard HTTP methods.
in which publishers 4 The REST is widely used in the internet between websites.
+ Publish /subscribe is an asynchronousmanaging paradigm
subscribe to data content, although
send data without knowing who the receiver is, and receiver 4 The content of RESTHIT messages can be of any MME
based on the topic or content of the data. XML is common machine to machine application.
publisher and
4 It is implemented using centralized brokers that match http://sensorid.example.com/sensorstemp
subscribers in a store and forward fashion. http://sensorid.example.com/sensors
light
4 For internet of things pub/sub protocol plays an important role as most models objects
applicationsare data centric. REpresentationalState Transfer(REST) paradigm instead accessible
Ine noun), cach with a URL
Example MQTT (MQ Telemetric Transport) which is broker based enterprise (a good analogy is a
a n11 resources
pub/sub protocol for telemetry used widely by IBM. using standardHTTP methods[REST].

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

Aplicalton

Wireless Sensor NetworkDesign WEB SERVICE PROTOCOLS


4.14 Weh 4.15
These interfaces can be described using the Web
Application Description 4
The
service is hugely
enterprisemachineconcept
Language(WADL). With the release of WSDL 2.0,
REST-based interfacescan to
machine Internetsccessful
syst e ms.
on the
internet especially in
alternativelybe defined in a similar way to SOAP interfaces.
4The XML,
use of
HTTP and
4 This REST paradigm is widely used on the Internet
between web sites. The challengingfor| LoWPAN I TCP makes the adaptation of web
although XML nodes and services
content of RESTHTTP messages can be of any MIME content, 4.5
4 Figure shows the typical netofworks.
is common in machine-to-machineapplications. structure web service content which is
built upon HTTP &TCP as used
4 An example of a REST design follows, where objects are accessible
using today on the Internet. always
PUT and DELETE methods. In this example GET
standard HTTP GET,POST,
be used to
would be used on all resourcesto request the value, and POST would
set a new value for a parameter: WSDL
WADL XML
http://sensor10.example.com/sensors/temp Schema
http://sensor10.example.com/sensors/light UR1

http://sensor10.example.com/sensors/acc-X
http://sensor10.example.com/sensors/acc-y
(http:/ www.exatnple.com/soap.usdl)
application/
htp://sensor10.example.com/sensors/acc-z Soap + XML Text /XML Text /XML
http://sensorl0.example.com/config/sleeptime
Header
htp://sensor10.example.com/config/waketime
htp://sensor10.example.com/configlenabled Body
http://sensor10.example.com/config/samplerate
UR1 +method (GET)
4.4.COMMON PROTOcoLS
HTTP
potential for use
4 The common protocols that are commonly used or have good
over 6LoWPAN. IP address TCP Port (80)

TCP
The common protocolsinclude:
1, Web service protocols
servicecontentoverHTTP/TCP
2. MQTT-S Fig. 4.5. Typicalstructure of web
servicesor
URLS availableon an HTTP servers with
3. Zigbee CAP * Web services are simply
4. Servicediscoverprotocols resourcesaccessiblebehind them. responsesthat
ofmethodswith corresponding
5. SNMP
4 This servicessupport any number
6. RTP/RTCP
are describedby a WSDL document. header and a body in whichthe body
7. SIP of a
4 SOAP is an XML format consisting
8. Industry specific protocols
Carries any numberof messages.

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

aplication

Wireless Sensor Network Design


4.16 Thesimpleexample has a
4 Resource based web services can also be
realized using a REST design. are tWo lengthof 424 bytes. 4.17

4 In this model formal message sequcnces are not used,


instcad each resource is
A There
architecture fundamental waysto integrate 6LoWPANinto a
web service
identified by a URL. 1) Gateway approach
4 By using dìfterent HTTP methods on that URL, the resource
can be accessed.
2) Compressionapproach
Example GatewayApproach:
Sending an HTTP GET for (sensors)temp might return a text/sml body with the webservice gateway is
temperature of thesensor. implemented at the edge of the LoWPAN often on a
local server on the edge router.
REST designs make use of well known XML or otherformats to give meaning to
the contentthat can be understoodby all parties. 4 Inside the LoWPAN a proprietaryprotocolis used to request data, perforn
configurationetc.
XML is typically too large for marking up content in the payload space
available.HTTP headers have high overload and are difficultto park. . The gateway then makes the content and control of
the devices available
4 Content for the example above may look like through a web service interface.
Post/sensorservice HTTP/1.1 A Web services accuracyend at the gateway.

Host: sensorid.example.com 4 The gatewayis dependenton the contentof the applicationprotocols.


Content - type: application/soap+xml;charset=utf-&8 &This creates scalabilityand evolvabilityproblemswhere each time a new use of
Content - length:nm the LoWPAN is added or the applicationforrmat is modiied all gateways need
<?xml version = *1.0"?> to be upgraded.
<soap: envelope CompressionApproach:
Xmins: soap = "htp://www.w3.0rg2001/12/soap-envelope" 4 The web service format and protocols are
compressedto size suitable for use
using standards and has two forms
<Soap: encoding style = "http://www.w3.org/2001/12/soap-encoding"> over 6LoWPAN. This can be achieved
<soap:bodyxmlns : m="http://www.example.com/soapusd 1"> end-to-endand proxy.
<m:getsensor> End to End Approach:
<m:sensorlID>oxla</m:sensorlD> supportedby both applicationend points.
* Compressedformatis
m:getsensor>
Proxy Approach: so that the internet
end
</soap:body> performs transparentcompression
&Intermediate node
</soap:envelope> pointcan use standardweb
services.
compression. WAP binary
for performing XML
4 Several technologies exist phone browsers.
XML format waasdevelopedfor mobile

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

Mplication
4.18| Wireless Sensor Network Design
&The protocol was
4 Binary XML from the open geospatial consortium was designed to
compress websphere and desiM2Mgned by IBM and is used in
lotus 4.19

broker applications. commercial products such as


large set of geospatialdata and is currentlya draft proposal.
&MQTT uses a
* The W3C is currently completing standardization of the efficient
XML based| on matching based publsub
interchangeformat. topic names. architecture to which
XML compressionalone only solves part of the problem.
The MØTT
optimized protocol can be used over clients published data
any other simple
HTTP & TCP are still not suitable for use over 6LoWPAN, network providinga zigbee, UDP/6LOWPAN or
& One commercialprotocol solutioncalled NANO web services. 4 MQTT-S is
sizes &simpleoptimized
bi d i r e ct i o nal
devices. low bandidth wirelessdatagram service.
for
4 The ideal long term solution will be the
standardizationof a combination of 4 MQTT-S
networks with Small frame
XML binary encodingbound to a suitable UDP based protocol.
elements.
architecture shown in Figure 4.6. It is made up
4 The namespace and scheme with
6LoWPAN devices must also be carefully of four different
designed. 1. MQTT brokers
2. MQTT-S gateways
4.4.2. MOTELEMETRYTRANSPORTFOR SENSOR 3. MQTT-S forwarders
NETWORKS (MOTT-S)
4 The MQ Telemetry Transport (MQTT) is a light weight publish/subscribe 4. MQTT-Sclients
protocol designed for use in enterprise applicationsover low bandwidth wide A Client connect
themselves to a broker througha gateway using the
area network links such as ISDN or GSM. protocolsthe gateway may be located e.g on the
MQTT-S
may be integratedin the broker itself. LoWPAN Edge Router or it
MQTT 4 Gateway translatebetweenMØTT-S and MQTT.
broker
IS8 3 88S 3 MQTT-S
Incase a gateway is not directly available, forwarders are used to forward
IPv4 /IPV6 messages between clients and brokers.
TCP gateway
|ANA 4 Forwarders may not be needed with 6LoWPAN as UDP datagramscan be sent
UDP
MOTT-S MQTT-S directlyto a gateway.
gateway forwarder
0 12 3 4 5 67 890 123 4567890123 4 56789
UDP UDP

Msg. Type Variable Message Pat


MQTT-S MQTT-S MQTT-S Length
client - +- t-t
client client

Fig. 4.6. The MQTT-S architectureused over Fig. 4.7. The MOTT-S messagestructure
6LoWPAN
structurewhich consist of alength field
*igure 4.7 shows the MOTT-S message
variablelengthmessage part.
a messagetype field and then a
Downloaded by ??????? ([email protected])
lOMoARcPSD|51489847

glieation

Wireless Sensor Network Design


4.29 4.4-3.
GBEECOMPACT 4.21|
4 The basic functionalityof MQTT-S shortly.
+ Readers should consult the MQTT-S specificationfor full protocol detail.
4
The
Application Layer APPLI
Zigbee
(ZAL)CandATItheONZigbee
PROTOCOL (CAP)
specify an
application
devicesat the applicationprotocol enabling Cluster Library (ZCL)
Protocol Operation:
4 MQTT-S includes a gateway discovery procedure, which does not exist in + Typical application for
l a yer. i n t e r o per a bi l i t y between zigbee
MQTT. and similar local area
zigbee
include home automation
wireless control appl i c at i o ns. energy applications
4 Gateways send periodic ADVERTISE messages and clients may send 4 ZZiggbee makes use of a vertical profile
SEARCHGW messages. ZAL and approach over the ZAL and ZCL.
4The ZCL provide the key
applicationprotocol
commands and data, service functionality
4 AGWINFOmessage is sent to a client in response to SEARCHGW with basic enabling the exchange of in zigbee,
informationabout the gateway. discovery bending and
security along with protile support.
4 Client connectto gateway which responds with an ACK. .The zigbee application protocol solution would
4 Disconnectis used to end a connectionor to indicate a sleep period. have benefits used over
ctandard UDP/IP communicationsas well, especially over
igbee profiles has been designed with similar requirements. 6LoWPAN
4 Clients can connect with multiple gateways which are able to perform load as the
balancing. & Asolution for using zigbee applicationprotocols and profiles over UDP/IP has
Gate can function in either transparentmode. When a connectionto the broker
been proposed in which an IETF Internet draft.
is maintained for each client.
4 This specification defines how the ZAL is mapped to standard UDP/P
4 Aggregation mode - the gateway aggregates messages from all clients into a
single broker connection.
primitivesenablingthe use of any zigbee profileover 6LoWPANor standardIP
stacks.
Aggregationmode can considerablyimproves scalability.
4 This adaptation of the ZAL for the use of UDP/TP is called the compact
MQTT-S makes use of two-byte topic IDS and short topic name to optimizethe
long topic name strings normally used in MQTTS. applicationprotocol.
4 This reduces the bandwidth. Smart
Home Private
automation energy profile
4 A client can send a REGISTER message with the topic name which is profile
profile
acknowledgedwith a REGACK indicatingthe assignedtopic ID.
CAP
4 The client then publishes its date with PUBLISH messages including the topic Management Security
Data protocol
ID and possibleQoS information. protocol
protocol

4 Clients subscribe by sending SUBSCRIBE to the gateway including the topic


UDP
name of interest which is acknowledgedwith SUBACK including an assigned
IP/6LOWPAN
topic ID
4 UNSUB-SCRIBEis used to remove a subscriptionfrom the gateway. ProtocolStack
Fig. 4.8.TheCAP

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

pgelicaion
Wireless Sensor Network Design Some
|4.22
4 application
4 The CAP protocolstack is shown in Figure 4.8. The functions of the ZAL and builtin discovery protocols such as zigbee CAP
features. and
4.23
ZCL are implementedby the CAP.
The data protocolcorespondsto the zigbee cluster library.
location protocol is used for MOTT-S have their OWn
4 The service
networks. SLP
needs in ordergeneral
* The management protocol corresponds to the zigbee device profile handling 6LoWPAN because
of theoptsize
i m i z at i o n to beservice discoveryover IP
of
binding and discover.
* The security protocol implementszigbee applicationsublayersecurity.
The SSLP typical
Supports most of the features message.
directoryagents. of
effectively used with

SLP including the


&Any zigee public or private applicationprofile can be implementedover CAP in The SSLP header format consist for a optional use of
the same way it would use the native zigbee ZAL/ZCL.
specificmessage fields. four byte base headers
The main notificationto the ZAL has to do with using IP hosts and IP addresses followed by
instead ofIEEE 802.15.4 hosts and IEEE 802.15.4addresses. carried as strings. String used with a
URLS are

4 In CAP this is replaced by a CAP address record which contain a IPv4 address
kept as short as possible. scheme like SSLP should be
plus UDP port, IPv6 address plus UDP port. IIPNP is a protocol aimed at
&The CAP protocol is simply zigbee application layer APS frames places in and controllableas specifiedinmaking home devices automaticallyrecognizable
UPNPI.
UDP. & UPNP makes use of three
protocols.
4 The APSdelivery modes are mapped to P unicast and broadcastdelivery and 1) Simple service discovery protocol(SSDP)-
groupcast is reduced down to broadcast. 2) Generic event notificationarchitecturefor event
iscovering
devices
4 CAP supports secure transmission and the use of APS acknowledgements noification(GENA)’
Event notificationand SOAP for controllingdevices
which provide limited applicationprotocolreliability. UPNP is not diectly applicable to 6LoWPAN devices because of its
* The zigbee security and key managementfeatures are implementedby the CAP dependance on broadcast along with XML &HITP based descripions and
security protocol. protocols.
4 CAP is aconcept that would need standardizationto become widely used. The
upcoming zigbee/lP smart energy 2.0 profile will not be based on a CAP
* SSDP may be applicabledirectlyover 6LoWPAN.
approach. *The devices profile for webservice (DPWS) describes a basic set of
functionalityto enable embedded IP devices with web service based discovery
4.44. SERVICE DISCOVERY
device descriptionmessagingand events
on XMLHTTP/TCPit
4 Service discovery is an imporant issue in wireless embedded applications DPWSdescriptionsare XML and all messagingis based
where device are autonomic also requiring the auto configuration of binding along with simplification
Would require web service compressionand
applications.
In order to be used over 6Lo WPAN.
system
4 Typical protocolsused for service discoveryon embeddeddevices includedthe popularityfor use in enterpriseand industrial
*DPWS has been gainingin into back end systems
Service Location Protocol (SLP), Universal Plug NPlay (UPNP) and Device can be automaticallyintegrated
Profilefor Web Services (DPWS). nd devicesusing DPWS
based on web services.

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

gelication

Wireless Sensor Network Desipn 4


RTPis designedto be 1P
TCP. version and transDor
|4.24
Over both UDP and 4.25
MANAGEMENT PROTOcoL (SNMP)
4.4-5. SIMPLE NETWORK
4 Network management is an important feature ofany
network deployment and a
The base RTP
header
type identification a provides basic features for
indenendent and can be uS
certain amount of management is neceSsary even for
embedded services.
autonomous wirelese
The RTP sequence
format numberand timestamp.
header
end to end
delivery payload
infrastructure and kind of QoS, but it is shown in Figure 4.9. It
able to help deal does not
4 SNMP is a standard for the management of the network
sequencenumber and with out of order by itself provide any
devices in IP networks.

a It exposes variables to a management system which


can be GET or in some 12 3 4 5 6 timestampfields.
789 01234 567
packets and jiter with
cases SETin order to configureor control a device. 890 1 23 4 5
67890
4 The variable exposed by SNMP are organized in hierarchies called V=2|P|X| cc
Management InformationBases (MIBS). Sequence Number
4 The pollingapproach used by SNMP is the biggest drawback of the approach. Time Stamp
4 Polling approachesdo not work for battery powered LoWPAN nodes which use
sleep schedules and blindly polling for statisticscreates unnecessaryoverhead.
SynchronizationSource (SSRC) dentifier
4 An event based approach would need to be added to SNMP for applicabilityto ContributingSource (CSRC) ldentifier
+

6LoWPAN management.
+ The following optimizationfor SNMPv3 have been identifiedin these drafts. Fig. 4.9. The RTP base header
4 Currently SNMPv3 requires the handling of payload sizes upto 484 bytes, 4RTCP is used during an RTP session to provide
which creates too much overhead for managing large 6LoWPANS. feedback on the QoS of RTP
data delivery to identify the RTP source adjust the RTCP report intervals and
4 The SNMPy3 header is variable in size and need to be optimized for
carry session control information.
6LoWPAN. Only a minimal subset of functionalityshould be supportedand the
header size should be limited. 4 RTP uses the concept of profiles which define possible additional headers
The binary encoding rules of the payload use variable length fields for features and payload formats for aparticularclass of application.
6LoWPAN, fixed length fields or more compactencodingmay be necessary. * The RTP audio video profile specifies the profile for common audio and video
* Payload compressionand aggregationmay be needed for 6LoWPAN. applications.
& Toreduce memory requirementsthe maximum size of SNMP messages should * RTP makes use of UDP is IP version independent and has a fairly compact
be limited. header format, It is directly usable without modification.
data streams. It requires that
*KIP can be used to deliver and monitor real time
4.4.6. REAL TIME TRANPORT AND SESSIONS about and find each other.
ne sender and receiversomehow know
Ao The Real time Transport Protocol (RTP)is used for the end to end delivery of modifying and
was designed for establishing,
real time data. e Session initiation protocol
learing down multimediasession over lP.
Downloaded by ??????? ([email protected])
lOMoARcPSD|51489847

gliution

communication
|4.26
WirelessSensor Network Design 4
As

steadilyevolvedto technoluseogy has evolved,


enable
|4.27

4 SIP can be used over cither UDP or


TCP can be handled by intermediate over IP. Many industry-specific protocols
proxies and provides identifiersfor dealing with mobility. ALoWPAN,
used over
IPv6supportor UDP
industry -specific protocols mayhavebe
whereas others may require the
+ SIP exchanges typicallyperfomed between SIP uses agents
and servers. support for example. addition of compression,
and BYE. BACnet
4 Typical methods include REGISTER, INVITE, ACK
4 The building automation and
control
Example:
INVIIE SIP: [email protected]
by the American Society of Heatingnetworks (BACnet)standard was created
Via:SIP/2.0UDPPC33.attanta.com;branch=z9hGabknashde8
Engineers (ASHRAE) in 1995 to Refrigeration and
bring interoperabilityto Air-Conditioning
automation. BAChet is published as ANSI HVAC building
Max-Forwards: 70
16484-5. standard 135 (BACnet and ISO
To:Bob<sip: [email protected]>
From: Alice<sip: [email protected]>:tag=1928301774 Since its original release has developed into a
standard used by over 350 broad building automation
Call-ID: G8464c76e66710 vendors. The latest version was published in 2008.
Cseq :314159INVITE BAChetis a network and application
protocolformat with support for a wide
Contact: <sip:alice @pc33.atalanta.com> range of communicationtechnologies including Ethernet. RS232, RS-485 and
Content-Type:application/Sdp LonTalk.
Content-Length:142 BACnet includes support for use over UDPIP known as BACnet IP. The
standard BAChet network and application protocol frames are carried over
4 The SIP header and body format is typically too large for efficient use over
6LoWPAN. UDP by encapsulatingthem in a BACnet Vitual Link Layer (BVLL). This
4 One solution for using SIP with sensor networks is tinySIP which defined adaptationbinds BACnet to an underlyingcomnunicationtechnology.
alternate messages for use with tinyOS networking that were then mapped to Currently there is only a BVLL defined for use with lPv4, but an extension of
SIP by a gateway. that for IPv6 is straightforward.IPv6support is current under design in the
BAChet IP working group. BACnet makes use of unicast, broadcast and
44-7. INDUSTRY SPECIFIC PROTOCOLS
optionally multicast IP communications,and is based on an object-oriented
4 The industry-specificapplication protocols that can be used over IP, and are
design.
relevant for Wireless Embedded Internet applications using 6LoWPAN. acted upon using protocol services.
Building automation and energy are good examples of industries that have * BACnet objects have properties that are
Who-Is, I-Am, Who-Has and -Have used for
Ihese protocol services include
traditionallyspecifiedtheir own applicationprotocolsand formats. read-propertyand write-propertyused
4 These are enterprise applications where system integrators make use of device and object discovery along with range of low-bandwidth
was designed for a whole
equipment from multiple vendors together with backend computer systems to 1or data access. As BACnet protocol over
for IPv4, it will be a useful
achieve large deployments. The need for common application protocols and Iinks, and has native support
applications.
formats is obvious in such an environment. 6LoWPAN for buildingautomation

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

plaion

Wireless Sensor Nework Design 4.29


4.28
4 The adaptationof BACnet/lP for use with
6LoWPAN willrequirc IPv6 support. The open Building Information
keeping in mind its overhead on
standardfor access
to EXchange (oBIX) is a
building control
•oBIXI,weTheb-sestandard
rvice-tbasised
and should make careful use of multicast -
wireless multihop mesh networks. The performanceand
possible optimization
wireless mesh networks
meant to provide
high-level access usinginanformatopen,ionuniversal
hack-end systems and
of BACnet service protocol traffic over low-power
wired links.
building
control networks. oBIX is control networks, and to interconnect
format between
should also be studied as BACnet currentlyassumes
Advancement of standardized by the Organization forbuildingthe
Structured Information
KNX
building automation
releasedin 2006. oBIX provides a Standards (OASIS), and v1.0 was
web service
# Konnex (KNX) is an open protocol for home and interact with any building interface, which can be used to
standardized internationally(1SO/IEC 14543-3), in Europe
(CENELEC EN
Modbus, Lontalk or proprietary
automation network including BACnet, KNX,
50090) and in China (GB/Z 20965) [KNX]. It is also published as
ANSI networks using the oBIX XML format.
standard 135. KNX is based on the convergence of three previous European 4 The format provides normalized representation of
standardsin the home and buildingautomationdomain. huilding automation protocols: points (scalar value.constructs common to
status). alarms and
and promoted by the bistories. It has an extensible meta-formatwhich can be used todescribe
It is supported by over a 100 different manufacturers any
Konnex Association. It is estimated that over 80 percent of
the home evstem. oBIX provides a low-level object model for working with these
automationdevices sold in Europe use KNX. constructs. Usually these are accessed by using generic oBIX constructs, for
communicationmedia: twisted example by an enterprisedeveloper.
4 The KNX protocolsupports several different
most common
pair, powerline,radio frequency (RF) and IP. Twisted pair is the 4 OBIX is web service binding agnostic. It can be used over both SOAP and
or house is constructed.
KNX medium and is typicallyinstalledwhen a building directlyover HTTP in aREST style. It representsobjects with URLS and object
Powerlineand RF are often used when retrofittingexisting buildings. state with XML. oBIX may be applicable also for use directly in building
MHz radio at 16 automationnetworks thanks to 6LoWPAN.
4 The KNX RF specificationuses its own framing over an 868
theoreticallysupport up to 64k devices using twisted automationprotocol such
kbit/s. KNX networks can
for IP, also
4 Instead of runninga control network specificbuilding
communications. KNX has some support together with compressionand
pair, power-line or RF as BACnet/IP or KNX over 6LoWPAN, oBIX
known as KNXnet/IP. KNX IP support is part of a framework called ANubis design of the oBLX objects and
UDP/IP binding may be a solution. Careful
(Advanced Network for unified building integrationand services) and among elements used would be importantto keep packet
sizes reasonable.
many other things providesa way to encapsulateKNX frames over IP.
using IP ANSI C12.19
4 The purpose of this is currentlyto interconnect KNX networks infrastructures(AMl) are
networks, to enable remote monitoring and to interconnectwith other systems smart grids and automaticmetering for
wSmart metering, savingsand the demand
the need for energy
such as BACnet. This IP encapsulationtechnique could also be usefully applied developing very rapidly with (ANSI) CI2 family of
over low-power IP and LoWPAN networks to KNX devices themselves. This American National Standards Institute utilityindustry,and
Cnergy. The interfacesand protocolsfor
the
wouldneed a considerableamount of developmentand standardization. sidndardsdefines formats. particular,one set of standards
America [ANSI.In (usually
OWIdelyused in
North end devices
communicationsfor utility
within ANSI C12 specifies

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

eation

DLMS
4.30
WirelessSensor Network Design 4
The
AssOciat62056
standards,IEC ion |DLMS]
is actively promotes the
431

electric. gas and water meters)to communicate together


and with back-end
the
ANSI C12. It makes similar in function to its maintenance and use of
use of local
Systems. These standards enable the configuration, programming and point, serial modems, or IP optical or current loopsAmeri
to
can counterpart,
monitoringof these devices remotelyover both point-to-pointand IP networks. networks for meterS, point-to-
4
The COSEM protocol defines the communication.
application
4 The ANSIC12.18 standard defines a point-to-pointoptical interface along with ANSI C12, an object model is layer in IEC
the ProtocolSpecificationfor Electric Metering (PSEM). The ANSI C12, 19
used to
62056-61. The use of COSEM over acCcess information as defined in IEC
62056-53.
As with
standard defines utility industry end device data tables, which are accessible IPv4 is describedin detail in
47. Thisspecification describes transport using both IEC 62056-
using PSEM. ANSI C12.21specifies a communicationprotocol over modem 6LoWPAN UDP and TCP, which
enables use over
lines.
the
4 Finally anewstandard ANSIC12.22 specified the interfacingof devices to any # Although specificationdescribes the use of Pv4, the changes needed for
Pv6 are minor. It is unclear if any changes would be neededtothe standard to
data communications network including Internet protocols. This furthermore lasy the use of IPv6. Even-hough the data representationformat is not as
specifiesthe extended protocol specificationfor advanced metering (EPSEM),
compact as in ANSI C12, it is still suitable for the frame size and bandwidth
The ANSI C12 PSEM protocol and device data formats (tables) were designed
limitationsof 6LoWPAN.
with simple embedded electric meters and low-bandwidthpoint-to-pointlinks
in mind.
and data
TWOMARKSOUESTIONSAND ANSWERS
4 Therefore PSEM uses a compact birary encoding for all its protocol
fields. The typical frame size expectedby point-to-pointlinks is 64 bytes in the
Part- A
therefore well
ANSI C12.22 specification.The ANSI C12.22 specificationis LDefine Web Service.
suited for use over 6LOWPAN. The specificationincludes a simple example of support interoperablemachine to
communication stack. Web service is a software system designed to
using the applicationlayers with a TCP/IPv4 machine communicationover a network.
includes
4 The standardmay also be used with a UDP/IPv6 stack, as the protocol
2 What is publish/subscribe?
acknowledgment features for reliability along with application-layer messaging paradigm in which publisher
in Publish/subscribeis an asynchronous receiversubscribetodata
segmentationand reassembly.Application layer security features are built knowing who the receiveris
and
elements of the protocol. send data without
data.
based on the topic or contentofthe
issuesin 6LoWPAN?
DLMS/COSEM Whatare the addressed
of
The Device Language Message Specification(DLMS) is a European,model 1. Link layer
communication exchange used to interact with utility end devices for meter
2. Networking
reading, tariffand load control. It uses the COmpanion Specificationfor Energy
Metering (COSEM) as a data exchange format and protocol. Together, they are 3. Hostissues
standardizedby the IEC under the 62056 series [IEC62056]. 4. Compression
5. Security

Downloaded by ??????? ([email protected])


lOMoARcPSD|51489847

Application

4.32 Wireless Sensor Nevork Design List out the layers of BACnet. 4.33
4. Name two commonly used web serviceprotocol. 1. Applicationlayer
1. MQTT-S 9 Network layer
2. ZigBee CAP 3. Data link
5. What is proxying? 4. Physicallayer
Some of the applicationprotocol in 6LoWPAN also include the possibilityfor 10. DefineSIP.
intermediate nodes to inspect cache or modify application protocols.This is
referred to as proxying. Session Initiation
Protocol(SP) is asignaling protocol. It is used to initiate
modify andterminatesession. It
6. What are the disadvantages of SNMP? lies on Applicationlayer.
1. The polling approach used by SNMP is the biggest drawback of the Listoutthe basicsetof
approach. 1.
paradigms.
End to End paradigm
2. It creates unnecessaryoverhead.
2. Streamingsession
7. DifferentiateRTP and RTCP. 3. Publish/Subscribe
RTP 4. Web service
RTCP
1. Used to carry media streams. Used to monitoringtransmission 12. List out thefour MQTT-Selement.
states and QoS.
1. MQTT brokers
2. Even port number Odd port number
2. MQTT-S gateways
3. Interoperability Performancecontrollingthrough 3. MQTT-S forwarders
feedback
4. Payload type, sequence 4. MQTT-S clients
Sender and receiver reports
number, time stamp 13. Zigbee uses horizontalor verticalapproach.Justif.
5. 32 bit identifieris used. ZAL and ZCL with
Textual information Zigbee makes use of a vertical profile approach over the
ZigBee Home automation
8. Mention the two modes of gateway profiles for different industry applications such as
approachfunction. profile or the ZigBee Smart Energy Profile.
1. Transparentnode - where a connectionto the broker is maintainedfor each
client or in. 14. Define methods.
typically designed with a
2. Aggregationnode - where the gateway aggregatesmessages from all clients services (SOAP) interface is
A service based web procedure calls (RPCS) called
into a single broker connection. URL that implements several remote
SIhgle
methods.

Downloaded by ??????? ([email protected])

You might also like