ad-hoc networks

130
Ad-Hoc Networks Ad-Hoc Networks Đorđe Trifunović, [email protected] Đorđe Trifunović, [email protected] Nikola Mi Nikola Mi lanović, nikola99 lanović, nikola99 @EUnet.yu @EUnet.yu Prof. Dr. Veljko Milutinović, [email protected] Prof. Dr. Veljko Milutinović, [email protected] Authors Authors : : Establishing node-to-node communication Establishing node-to-node communication with no infrastructure needed with no infrastructure needed

Upload: ifama

Post on 18-Mar-2016

47 views

Category:

Documents


1 download

DESCRIPTION

Ad-Hoc Networks. Establishing node-to-node communication with no infrastructure needed. Đorđe Trifunović, [email protected] Nikola Mi lanović, nikola99 @EUnet.yu Prof. Dr. Veljko Milutinović, [email protected]. Authors:. What will you learn from this tutorial?. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Ad-Hoc Networks

Ad-Hoc NetworksAd-Hoc Networks

Đorđe Trifunović, [email protected]Đorđe Trifunović, [email protected] MiNikola Milanović, nikola99lanović, [email protected]@EUnet.yuProf. Dr. Veljko Milutinović, [email protected]. Dr. Veljko Milutinović, [email protected]

Authors:Authors:

Establishing node-to-node communicationEstablishing node-to-node communicationwith no infrastructure neededwith no infrastructure needed

Page 2: Ad-Hoc Networks

Page Numb

er: 2/130

What will you learn from this tutorial?What will you learn from this tutorial?

IntroductionIntroduction Mobile networksMobile networks Routing in ad-hoc networksRouting in ad-hoc networks Security in ad-hoc networksSecurity in ad-hoc networks BluetoothBluetooth The IEEE/UB ad-hoc multihop sensor network and Bluetooth; The IEEE/UB ad-hoc multihop sensor network and Bluetooth;

lessons lessons learned from the research by:learned from the research by:– Gvozden MarinkoviGvozden Marinković ć ([email protected])([email protected])– Aleksandar Radovanović ([email protected])Aleksandar Radovanović ([email protected])– Aleksandar Berić ([email protected])Aleksandar Berić ([email protected])– Branislav Čukanović ([email protected])Branislav Čukanović ([email protected])– Nikola Milanović ([email protected])Nikola Milanović ([email protected])

This tutorial will guide you through the following sections:This tutorial will guide you through the following sections:

Page 3: Ad-Hoc Networks

Introduction to Introduction to Ad-Hoc NetworksAd-Hoc Networks

Evolution of network communications – A new stage…

Page 4: Ad-Hoc Networks

Page Numb

er: 4/130

IntroductionIntroduction

Two basic groups of ad-hoc networks:Two basic groups of ad-hoc networks:– Networks of mobile computers handled by usersNetworks of mobile computers handled by users– Wireless sensor networksWireless sensor networks

Basic characteristic: Basic characteristic: ability to establish network communication between hosts ability to establish network communication between hosts without any infrastructure needed.without any infrastructure needed.– The most significant advance compared to classic fixed systemsThe most significant advance compared to classic fixed systems– Reveals a very large scale of new possibilitiesReveals a very large scale of new possibilities

Page 5: Ad-Hoc Networks

Page Numb

er: 5/130

IntroductionIntroduction

Ad-hoc networks may be considered Ad-hoc networks may be considered as a new stage in evolution of network communicationsas a new stage in evolution of network communications

Fixed computer networks:Fixed computer networks:– Concepts and mechanisms educed and amended for long time…Concepts and mechanisms educed and amended for long time…– Lot of experiences acquired…Lot of experiences acquired…– A useful base for origin and development of mobile networksA useful base for origin and development of mobile networks......

Page 6: Ad-Hoc Networks

Page Numb

er: 6/130

IntroductionIntroduction

Wireless communication has its peculiarities.Wireless communication has its peculiarities. Taking the already developed solutions is not possibleTaking the already developed solutions is not possible..

– In the beginning: In the beginning: modifications and adaptations of existing mechanismsmodifications and adaptations of existing mechanisms..

– Later: more and more of new ideas, Later: more and more of new ideas, relieved from the ballast of obsolete concepts.relieved from the ballast of obsolete concepts.

Page 7: Ad-Hoc Networks

Mobile NetworksMobile Networks

Meet the family…

Page 8: Ad-Hoc Networks

Page Numb

er: 8/130

Mobile NetworksMobile Networks

Not long time ago, Not long time ago, mobile networks were treatedmobile networks were treated just as extensions of fixed networks.just as extensions of fixed networks.

Actors are:Actors are:– Fixed hosts (FH)Fixed hosts (FH)– Mobile hosts (MH)Mobile hosts (MH)– Base stations (also known as Base stations (also known as mobility support routersmobility support routers – MSR) – MSR)

Page 9: Ad-Hoc Networks

Page Numb

er: 9/130

Mobile NetworksMobile Networks

Mobility Support Router (MSR)Mobility Support Router (MSR)

Every MSR supports the area limited by its range (Every MSR supports the area limited by its range (wireless cellwireless cell).). MSR can communicate with MHs currently located in its cell.MSR can communicate with MHs currently located in its cell.

– MHs directly communicate only with MSRsMHs directly communicate only with MSRs– MHs can freely move from one cell to anotherMHs can freely move from one cell to another

MSR

MHMH

MH

Page 10: Ad-Hoc Networks

Page Number: 10

/130

Mobile NetworksMobile Networks

Sending packets from FH to MHSending packets from FH to MH

MSRs are bridges between the wired network and mobile hosts.MSRs are bridges between the wired network and mobile hosts. When some fixed host (FH) wants to send a packet When some fixed host (FH) wants to send a packet

to a mobile host (MH), communication is divided into two parts:to a mobile host (MH), communication is divided into two parts:– Standard communication inside the fixed network,Standard communication inside the fixed network,

from FH to the proper MSR;from FH to the proper MSR;– Wireless communication between MSR and MH.Wireless communication between MSR and MH.

MH

MSRFH

FHFH

FH

MH

Page 11: Ad-Hoc Networks

Page Number: 11/130

Mobile NetworksMobile Networks

Hiding mobilityHiding mobility

Mediation of MSR is entirely transparent to FH.Mediation of MSR is entirely transparent to FH. For this kind of communication, For this kind of communication,

indirect protocolsindirect protocols were developed, were developed, with the purpose of hiding mobility with the purpose of hiding mobility from immobile hosts.from immobile hosts.

MH

MSRFH

FHFH

FH

MH

Page 12: Ad-Hoc Networks

Page Number: 12

/130

Mobile NetworksMobile Networks

One-hop wireless communicationOne-hop wireless communication

Direct communication between mobile hosts does not existDirect communication between mobile hosts does not exist Mobility is very limited Mobility is very limited

and dependant on the existing wired infrastructure:and dependant on the existing wired infrastructure:– MHs can move only within areas determined by the range of MSR, MHs can move only within areas determined by the range of MSR,

as well as by the range of its own transmitter;as well as by the range of its own transmitter;– Mobility is limited to only one Mobility is limited to only one hophop

between mobile host and fixed networkbetween mobile host and fixed network Anyhow, a step towards real, Anyhow, a step towards real, multihopmultihop wireless networks. wireless networks.

– Nature of wireless communicationsNature of wireless communications had to be considered had to be considered– Later was of great benefit Later was of great benefit for development of for development of ad-hocad-hoc networks networks

Page 13: Ad-Hoc Networks

Page Number: 13

/130

Mobile NetworksMobile Networks

Nature of wireless communicationsNature of wireless communications

Wireless vs wired links:Wireless vs wired links:– SlowerSlower– Less reliableLess reliable– Prone to loss of signal due to noise and fadingProne to loss of signal due to noise and fading– With much more limited bandwidthWith much more limited bandwidth– With much more frequent occurrence With much more frequent occurrence

of asymmetric quality of communicationof asymmetric quality of communication Mobile hosts are often disconnected from the fixed network Mobile hosts are often disconnected from the fixed network

for short or long periods of timefor short or long periods of time::– Moving out of rangeMoving out of range– Exhausted batteryExhausted battery– ……

Page 14: Ad-Hoc Networks

Page Number: 14

/130

Mobile NetworksMobile Networks

Realizations and usage possibilities Realizations and usage possibilities

Wireless Local Area Network (WLAN);Wireless Local Area Network (WLAN); Connecting mobile and portable computers Connecting mobile and portable computers

to existing widely used fixed networks like the Internet;to existing widely used fixed networks like the Internet; ……

Page 15: Ad-Hoc Networks

Page Number: 15

/130

Mobile NetworksMobile Networks

Drawbacks and limitationsDrawbacks and limitations

Infrastructure is needed…Infrastructure is needed…– Requires large investmentsRequires large investments– Time consuming installationTime consuming installation– Communication cannot be always established Communication cannot be always established

where neededwhere needed– Expensive maintenanceExpensive maintenance

Page 16: Ad-Hoc Networks

Page Number: 16

/130

Mobile NetworksMobile Networks

In many cases it is necessary to establish a connection In many cases it is necessary to establish a connection even if infrastructure does not exist, or is damaged.even if infrastructure does not exist, or is damaged.

Typical example: Typical example: alarming rescuers in case of earthquake, flood, alarming rescuers in case of earthquake, flood, war destruction…war destruction…

Communication must be established Communication must be established without any preliminary setup (without any preliminary setup (ad-hocad-hoc).).

Page 17: Ad-Hoc Networks

Page Number: 17

/130

Mobile NetworksMobile Networks

Ad-Hoc NetworksAd-Hoc Networks

Mobile hosts Mobile hosts can communicate can communicate between each other between each other on much greater distances on much greater distances than covered by their ranges.than covered by their ranges. – That is practicable That is practicable

thanks to presence thanks to presence of other mobile hosts of other mobile hosts that can be reached by the source host, that can be reached by the source host, and that are willing to retransmit its packets furtherand that are willing to retransmit its packets further on on

– Thus, propagating from one MH to another, Thus, propagating from one MH to another, packets are conveyed to the destinationpackets are conveyed to the destination

That is how multihop wireless communication That is how multihop wireless communication through a temporally formed ad-hoc networkthrough a temporally formed ad-hoc network is realized. is realized.

Page 18: Ad-Hoc Networks

How to find the right way?

Routing in Ad-Hoc NetworksRouting in Ad-Hoc Networks

Page 19: Ad-Hoc Networks

Page Number: 19

/130

Routing in Ad-Hoc NetworksRouting in Ad-Hoc Networks

Efficient routing of packetsEfficient routing of packets In conventional networks, In conventional networks,

the most widely used routing algorithms are such as the most widely used routing algorithms are such as distant vectordistant vector or or link statelink state

Periodical broadcast, Periodical broadcast, with the purpose of keeping routing tables up-to-datewith the purpose of keeping routing tables up-to-date

In some cases In some cases those algorithms were adapted to be used in ad-hoc networksthose algorithms were adapted to be used in ad-hoc networks

We will just mention two representatives:We will just mention two representatives:– Destination-Sequenced Distance-VectorDestination-Sequenced Distance-Vector (DSDV) (DSDV)– Wireless Routing ProtocolWireless Routing Protocol (WRP) (WRP)

Benefit: RBenefit: Route to every host in the network is always known. oute to every host in the network is always known. But…But…

Page 20: Ad-Hoc Networks

Page Number: 20

/130

Routing in Ad-Hoc NetworksRouting in Ad-Hoc Networks

Drawbacks of adapted conventional routing algorithmsDrawbacks of adapted conventional routing algorithmsseem to be of much more significance than the benefitsseem to be of much more significance than the benefits::– Large bandwidth overheadLarge bandwidth overhead– Batteries quickly become exhaustedBatteries quickly become exhausted– Significantly reduced scalabilitySignificantly reduced scalability– Unneeded cumulation of redundant routesUnneeded cumulation of redundant routes– Often not able to quickly enough respond to dynamics of changes Often not able to quickly enough respond to dynamics of changes

in systems in which the hosts can move in systems in which the hosts can move

Page 21: Ad-Hoc Networks

Page Number: 21

/130

Routing in Ad-Hoc NetworksRouting in Ad-Hoc Networks

On-demand routing protocolsOn-demand routing protocols

Because of Because of specified constraints of said solutionsspecified constraints of said solutions,,we are going to pay more attention on another approachwe are going to pay more attention on another approach,,which is which is fundamental for the so-called fundamental for the so-called on demandon demand routing protocolsrouting protocols..

We will shortly describe three of those protocols, We will shortly describe three of those protocols, which attack the problem from different standpoints,which attack the problem from different standpoints,introducing different assumptions introducing different assumptions and diversely prioritising problems that are to be solved:and diversely prioritising problems that are to be solved:– Dynamic Source Routing (DSR)Dynamic Source Routing (DSR)– Ad-Hoc On-Demand Distance Vector Routing (AODV)Ad-Hoc On-Demand Distance Vector Routing (AODV)– Temporally Oriented Routing Algorithm (TORA) Temporally Oriented Routing Algorithm (TORA)

Page 22: Ad-Hoc Networks

Page Number: 22

/130

Routing in Ad-Hoc NetworksRouting in Ad-Hoc Networks

All the proposed solutions All the proposed solutions contribute to the apparent reclamation of performance, contribute to the apparent reclamation of performance, compared to classic algorithms, compared to classic algorithms, which work much better in the stationary environment which work much better in the stationary environment for which they were designed in the first place.for which they were designed in the first place.

Algorithms that will be presented here are just specimens Algorithms that will be presented here are just specimens of a large number of solutions developed by now (ietf.org). of a large number of solutions developed by now (ietf.org).

New algorithms are still being developed and evolvedNew algorithms are still being developed and evolved..

Page 23: Ad-Hoc Networks

Page Number: 23

/130

Routing Protocols - DSRRouting Protocols - DSR

1. Dynamic Source Routing (DSR)1. Dynamic Source Routing (DSR)

Based on the concept of source routingBased on the concept of source routing::– Sender provides the sequence of nodes Sender provides the sequence of nodes

through which the packets will be sentthrough which the packets will be sent– Sequences are held in Sequences are held in route cacheroute cache

that every host must maintain for itselfthat every host must maintain for itself Route is determined dynamically, when it is neededRoute is determined dynamically, when it is needed::

– There are no periodical advertisements of routersThere are no periodical advertisements of routers– Instead, every host initiates Instead, every host initiates route discoveryroute discovery

when it needs to send a packet to another host when it needs to send a packet to another host for which initiator does not have the associated route in its cachefor which initiator does not have the associated route in its cache

Page 24: Ad-Hoc Networks

Page Number: 24

/130

Routing Protocols - DSRRouting Protocols - DSR

Route Discovery – route requestRoute Discovery – route request

Initiated by sending a Initiated by sending a route requestroute request packet: packet:– Propagates through the network Propagates through the network

until it reaches the destinationuntil it reaches the destination host (if the route exists);host (if the route exists);– On its way, it collects addresses of all visited hosts, On its way, it collects addresses of all visited hosts,

and stores them into its and stores them into its route recordroute record;;

11

22

33

44

55

66

src

dst

1

1

1,3

1,2

1,3,4

1,3,4

1,3,4,5

Page 25: Ad-Hoc Networks

Page Number: 25

/130

Routing Protocols - DSRRouting Protocols - DSR

Route Discovery – route replyRoute Discovery – route reply

The first route request packet that arrives to destination is accepted, The first route request packet that arrives to destination is accepted, its routeits route record is copied and returned to the initiator record is copied and returned to the initiator using the using the route replyroute reply packet. packet.

Destination host returns the route reply Destination host returns the route reply to the initiator of route discovery, using the route from its own cache.to the initiator of route discovery, using the route from its own cache.

11

22

33

44

55

66

(1,3,4,6)

(1,3,4,6)(1,3,4,6)

Page 26: Ad-Hoc Networks

Page Number: 26

/130

Routing Protocols - DSRRouting Protocols - DSR

Route Discovery – route reply (2)Route Discovery – route reply (2)

If destination host does not have If destination host does not have a route to the source host in its cache, a route to the source host in its cache, there are two options:there are two options:

1.1. Route reply is returned using inverse route Route reply is returned using inverse route that was found by the routethat was found by the route request packetrequest packet;;

2.2. DestinationDestination host initiates routehost initiates route discovery discovery to find a route to the original initiator.to find a route to the original initiator.

First option requires symmetric links: First option requires symmetric links: – Transfer quality must be the same Transfer quality must be the same

in both directions;in both directions;– But that is often not the fact But that is often not the fact

in mobile communications.in mobile communications.

Page 27: Ad-Hoc Networks

Page Number: 27

/130

Routing Protocols - DSRRouting Protocols - DSR

Route Discovery – route reply (3)Route Discovery – route reply (3)

Second opportunity Second opportunity (inverse route discovery, (inverse route discovery, from destination to source) from destination to source) is more significant:is more significant:– Providing support for non-symmetric links Providing support for non-symmetric links

(very important merit of this algorithm)(very important merit of this algorithm)..– I that case, the original route reply I that case, the original route reply

must be sent together with new route request, must be sent together with new route request, i.e. attached to iti.e. attached to it (t (that is called hat is called piggybackingpiggybacking))

Page 28: Ad-Hoc Networks

Page Number: 28

/130

Routing Protocols - DSRRouting Protocols - DSR

Route MaintenanceRoute Maintenance

Implemented by acknowledgements Implemented by acknowledgements and and route errorroute error packets. packets.

Acknowledgements may be:Acknowledgements may be:– hop-by-hophop-by-hop – links must be symmetric – links must be symmetric– end-by-endend-by-end – important when links are not symmetric – important when links are not symmetric

Page 29: Ad-Hoc Networks

Page Number: 29

/130

Routing Protocols - DSRRouting Protocols - DSR

Route Maintenance (2)Route Maintenance (2)

When using hop-by-hop When using hop-by-hop acknowledgement:acknowledgement:– Host which did not Host which did not

get acknowledgement get acknowledgement for its retransmissionfor its retransmissionsends route error packet sends route error packet with information about hop that broke down;with information about hop that broke down;

– Upon that error packet, source host truncates Upon that error packet, source host truncates routing treerouting tree being held in its cache, at the point of that hopbeing held in its cache, at the point of that hop::

When using end-by-end acknowledgement:When using end-by-end acknowledgement:– Information about the point of breakage does not exist;Information about the point of breakage does not exist;– SourceSource host may only assume that the last hop is broken.host may only assume that the last hop is broken.

ack ackerrerr

?

Page 30: Ad-Hoc Networks

Page Number: 30

/130

Routing Protocols - DSRRouting Protocols - DSR

Modifications / OptimisationsModifications / Optimisations

Various modifications and amendments Various modifications and amendments of this algorithm are feasibleof this algorithm are feasible..

We’ll mention just one of them – We’ll mention just one of them – capability of working in the so-called capability of working in the so-called promiscuous receive modepromiscuous receive mode::– Host auscultate packets Host auscultate packets

that were sent to other hosts, that were sent to other hosts, and updates its own cache and updates its own cache according to the information thus receivedaccording to the information thus received;;

– This, however, This, however, causes more power to be used causes more power to be used and more rapid battery dischargeand more rapid battery discharge . .

Page 31: Ad-Hoc Networks

Page Number: 31

/130

Routing Protocols - DSRRouting Protocols - DSR

Summary – DSR meritsSummary – DSR merits

Ability to work with asymmetric linksAbility to work with asymmetric links.. No periodical routing advertisement:No periodical routing advertisement:

– Enables bandwidth and energy conservationEnables bandwidth and energy conservation;;– Overhead does not exist Overhead does not exist

when there are no changes in the networkwhen there are no changes in the network.. Can be easily improved to become able Can be easily improved to become able

for providing multiple routesfor providing multiple routes::– That way, it is not always necessary That way, it is not always necessary

to initiate new route discovery when some link breaks.to initiate new route discovery when some link breaks.

Page 32: Ad-Hoc Networks

Page Number: 32

/130

Routing Protocols - DSRRouting Protocols - DSR

Summary – DSR drawbacksSummary – DSR drawbacks

Caused by the nature of source routing.Caused by the nature of source routing. Large bandwidth overhead:Large bandwidth overhead:

– Route request packets rapidly grow Route request packets rapidly grow as they propagate through the networkas they propagate through the network(i(in their route records they store information n their route records they store information about every host over which they passed)about every host over which they passed);;

– That causes potential huge route reply packets;That causes potential huge route reply packets;– Also larger message packets, Also larger message packets,

because addressing demands the whole route to be specified.because addressing demands the whole route to be specified. Scalability problems – acceptableScalability problems – acceptable size of the network size of the network is limited: is limited:

– DiameterDiameter of the network of the network (the largest number of hops (the largest number of hops needed for communication between any two hosts in the network)needed for communication between any two hosts in the network)directly refers to bandwidth overhead.directly refers to bandwidth overhead.

Page 33: Ad-Hoc Networks

Page Number: 33

/130

Routing Protocols - DSRRouting Protocols - DSR

SummarySummary

Dynamic Source Routing protocol Dynamic Source Routing protocol is suitable for appliance in ad-hoc networks: is suitable for appliance in ad-hoc networks: – with moderate numbers of mobile hosts;with moderate numbers of mobile hosts;– which move with moderate velocitieswhich move with moderate velocities..

Page 34: Ad-Hoc Networks

Page Number: 34

/130

Routing Protocols - AODVRouting Protocols - AODV

2. 2. Ad-Hoc On-Demand Ad-Hoc On-Demand Distance Vector RoutingDistance Vector Routing (AODV) (AODV)

New route is discovered in a manner New route is discovered in a manner that looks similar to route discovery by DSR:that looks similar to route discovery by DSR:– Source hostSource host ( (srcsrc) broadcasts ) broadcasts route requestroute request (RREQ) to all of its neighbours (RREQ) to all of its neighbours

when needs to discover route to some when needs to discover route to some destination hostdestination host ( (dstdst); ); – Then, it waits for Then, it waits for route replyroute reply (RREP). (RREP).

But similarity is discontinued at this point.But similarity is discontinued at this point.

src?

Page 35: Ad-Hoc Networks

Page Number: 35

/130

Routing Protocols - AODV Routing Protocols - AODV

Route RequestRoute Request

Sequence numberSequence number– Number that every host generates for itself.Number that every host generates for itself.– It is incremented every time when something It is incremented every time when something

is changed in adjacency (e.g., when some link breaks)is changed in adjacency (e.g., when some link breaks)..– For every route, For every route, destination sequence numberdestination sequence number (DSN) (DSN)

is stored in the is stored in the routing tablerouting table – Last DSN that Last DSN that srcsrc earlier knew for any route to earlier knew for any route to dstdst, is sent in RREQ, , is sent in RREQ,

together with current sequence number of together with current sequence number of srcsrc and other information needed:and other information needed:

RREQ (src, RREQ (src, dst, srcSN, dstDSN, … ) dst, srcSN, dstDSN, … )

Page 36: Ad-Hoc Networks

Page Number: 36

/130

Routing Protocols - AODVRouting Protocols - AODV RREQ does not contain the route record:RREQ does not contain the route record:

– Does not collect information Does not collect information about hosts through which it propagates; about hosts through which it propagates;

– Remembers only the number of hops.Remembers only the number of hops. Instead, the host through which RREQ propagates Instead, the host through which RREQ propagates

adds inverse route (towards adds inverse route (towards srcsrc) to its routing table:) to its routing table:– Stores, together with other relevant information, Stores, together with other relevant information,

the address of the neighbour (the address of the neighbour (nn1) that sent RREQ to it1) that sent RREQ to it;;– If that host later receives relevant RREP, it will automatically know If that host later receives relevant RREP, it will automatically know

that reply should be transferred to the neighbour (that reply should be transferred to the neighbour (nn1)1);;– In that case, it also records the address of the neighbour (In that case, it also records the address of the neighbour (nn2) 2)

that sent RREP, thus establishing route towards that sent RREP, thus establishing route towards dstdst..

RREQRREP

route to src route to dst

n2n1

Page 37: Ad-Hoc Networks

Page Number: 37

/130

Routing Protocols - AODVRouting Protocols - AODV

Instead of recording the whole route, as with DSR applied, Instead of recording the whole route, as with DSR applied, host here keeps only host here keeps only next hop next hop (among other relevant information (among other relevant information about some destination), i.e. address of its neighbour about some destination), i.e. address of its neighbour to which it transfers packets addressed to the destination:to which it transfers packets addressed to the destination:

11

22

33

44

55

66

11

22

33

44

55

66

6: 3,4,6

6: 4,6

6: 6

6: 3

6: 4

6: 6

DSN

AODV

Page 38: Ad-Hoc Networks

Page Number: 38

/130

Routing Protocols - AODVRouting Protocols - AODV

Route ReplyRoute Reply

When RREQ reaches a host that has a route to When RREQ reaches a host that has a route to dstdst, , comparison of DSNs from the packet and from the routing table comparison of DSNs from the packet and from the routing table is made:is made:

– If DSN from RREQ is greater If DSN from RREQ is greater the host’s route to the host’s route to dstdst is not recent enough is not recent enough the host rebroadcasts the request; the host rebroadcasts the request;

– Otherwise, the host returns RREP to Otherwise, the host returns RREP to srcsrc, , with the calculated information about the discovered route with the calculated information about the discovered route (total (total hop counthop count, , lifetimelifetime that remains…), that remains…), among which more recent DSN, among which more recent DSN, copied from the routing table of the host.copied from the routing table of the host.

DSN(dst)=8

DSN(dst)=12

DSN=10 DSN=10

DSN=10DSN=12

Page 39: Ad-Hoc Networks

Page Number: 39

/130

Routing Protocols - AODVRouting Protocols - AODV

RREQ may reach RREQ may reach dstdst itself, and then itself, and then dstdst returns RREP to returns RREP to srcsrc.. Anyway, RREP is returned using inverse route Anyway, RREP is returned using inverse route

formed by intermediate hosts during the propagation of RREQformed by intermediate hosts during the propagation of RREQ..

src

dst

Page 40: Ad-Hoc Networks

Page Number: 40

/130

Routing Protocols - AODVRouting Protocols - AODV

Route MaintenanceRoute Maintenance

For every route For every route that a host is acquainted with, that a host is acquainted with, it maintains the list of neighbours it maintains the list of neighbours that use that route, that use that route, so that it is able to notice them so that it is able to notice them about eventual link breakage about eventual link breakage on the route. on the route.

Link breakage is detected Link breakage is detected by the absence of by the absence of hellohello messagesmessages, , which must be emitted by every host which must be emitted by every host after the specified time interval expires.after the specified time interval expires.

Page 41: Ad-Hoc Networks

Page Number: 41

/130

Routing Protocols - AODVRouting Protocols - AODV

Summary – Advantages of AODV over DSRSummary – Advantages of AODV over DSR

Significantly smaller Significantly smaller network bandwidth overhead:network bandwidth overhead:– Both control and message packets are smaller; Both control and message packets are smaller; – The reason is the requirement of only two addresses when routing The reason is the requirement of only two addresses when routing

((destinationdestination and and next hopnext hop), instead of the whole route ), instead of the whole route as with sequenced routing; as with sequenced routing;

– This is good for scalability, This is good for scalability, because the size of a packet because the size of a packet does not depend on the network diameter.does not depend on the network diameter.

Provides support for multicastingProvides support for multicasting..

Page 42: Ad-Hoc Networks

Page Number: 42

/130

Routing Protocols - Routing Protocols - AODVAODV

Summary – AODV drawbacksSummary – AODV drawbacks

Works only with symmetric linksWorks only with symmetric links.. Hosts must periodically advertise hello messagesHosts must periodically advertise hello messages::

– Increased bandwidth overheadIncreased bandwidth overhead;;– Reduced possibility of energy conservation Reduced possibility of energy conservation

by remaining in the sleep modeby remaining in the sleep mode.. Does not support Does not support multi path multi path routingrouting

(offers only one route per destination):(offers only one route per destination):– Every time when some link Every time when some link

on the route breaks, on the route breaks, new route must be discoverednew route must be discovered;;

– Increased Increased probability of congestionprobability of congestion..

Page 43: Ad-Hoc Networks

Page Number: 43

/130

3. 3. Temporally OrientedTemporally Oriented Routing Algorithm (TORA)Routing Algorithm (TORA)

Offers an interesting approach to problem solution.Offers an interesting approach to problem solution. Conceived as Conceived as link-reversallink-reversal algorithm algorithm.. The idea is to define topology of a network The idea is to define topology of a network

using a directed acyclic graph (DAG):using a directed acyclic graph (DAG):– Hosts represented as nodes Hosts represented as nodes

and with directed linksand with directed links;;– Direction of link is realized Direction of link is realized

by assigning height to every node, by assigning height to every node, so that the link is directed so that the link is directed from the node with greater height from the node with greater height to the node with lower heightto the node with lower height..

Routing Protocols - TORARouting Protocols - TORA

Page 44: Ad-Hoc Networks

Page Number: 44

/130

Routing Protocols - TORARouting Protocols - TORA

General ideaGeneral idea

The destination node should have the minimal height in the graph. The destination node should have the minimal height in the graph. Other nodes get greater and greater height Other nodes get greater and greater height

as the distance from the destination grows. as the distance from the destination grows. Packets may be sent only from “higher” to “lower” nodes, Packets may be sent only from “higher” to “lower” nodes,

i.e., only via downstream linksi.e., only via downstream links..

Page 45: Ad-Hoc Networks

Page Number: 45

/130

Routing Protocols - TORARouting Protocols - TORA

DAG FormingDAG Forming

SStarts when node that does not have downstream links tarts when node that does not have downstream links wants to send a packet to a destination nodewants to send a packet to a destination node..

InitialInitialllyy, , all nodes in the graph have undetermined height (NULL), all nodes in the graph have undetermined height (NULL), except the destination node that has the height of ZERO except the destination node that has the height of ZERO ((which is considered less even from NULLwhich is considered less even from NULL).).

SourceSource node then broadcasts QRY packet to its neighboursnode then broadcasts QRY packet to its neighbours.. QRY QRY packet propagates through the network, packet propagates through the network,

marking every node over which it passes marking every node over which it passes as “interested for route discovery” as “interested for route discovery” by setting its by setting its route request flagroute request flag. .

Page 46: Ad-Hoc Networks

Page Number: 46

/130

Routing Protocols - TORARouting Protocols - TORA

When QRY packet arrives to a node When QRY packet arrives to a node that has at least one downstream link, that has at least one downstream link, the node then emits the UPD packet. the node then emits the UPD packet.

UPD propagates back through the network, UPD propagates back through the network, setting the height to all nodes with the routesetting the height to all nodes with the route requestrequest flag set,flag set,at the same time resetting those flags.at the same time resetting those flags.

Every further node gets greater height Every further node gets greater height then the precedent one on the path of the UPD propagation.then the precedent one on the path of the UPD propagation.

dstsrc

Page 47: Ad-Hoc Networks

Page Number: 47

/130

Routing Protocols - TORARouting Protocols - TORA

Many downstream links can lead to the same destination. Many downstream links can lead to the same destination. Algorithm enables multiple path routing.Algorithm enables multiple path routing.

Page 48: Ad-Hoc Networks

Page Number: 48

/130

Routing Protocols - TORARouting Protocols - TORA

In case of link break:In case of link break:– If the node still has downstream links left, no action is performedIf the node still has downstream links left, no action is performed– Otherwise, the node broadcasts a UPD packet, thus recovering DAG Otherwise, the node broadcasts a UPD packet, thus recovering DAG

Recovering is a one-pass process, Recovering is a one-pass process, except in the case of network partitioningexcept in the case of network partitioning

Page 49: Ad-Hoc Networks

Page Number: 49

/130

Routing Protocols - TORARouting Protocols - TORA

Advantages of TORAAdvantages of TORA::

Fast route discoveryFast route discovery Multiple path routingMultiple path routing Recovering is localisedRecovering is localised Multicast supportMulticast support Lightweight Adaptive Multicast (LAM) algorithmLightweight Adaptive Multicast (LAM) algorithm

Page 50: Ad-Hoc Networks

Page Number: 50

/130

Routing Protocols - TORARouting Protocols - TORA

Downsides of TORADownsides of TORA::

Requires external timing mechanism (GPS…)Requires external timing mechanism (GPS…) DAG becomes less optimal as the time passesDAG becomes less optimal as the time passes

– Can be solved using refresh packetsCan be solved using refresh packets

Page 51: Ad-Hoc Networks

Page Number: 51

/130

Routing Protocols - TORARouting Protocols - TORA

TORA is designed forTORA is designed for:: Large networksLarge networks Many nodes with dense distributionMany nodes with dense distribution

Page 52: Ad-Hoc Networks

Issue of Security Issue of Security in Ad-Hoc Networksin Ad-Hoc Networks

There is no need to see his identification...

Page 53: Ad-Hoc Networks

Page Number: 53

/130

Attributes of securityAttributes of security

The attributes of security areThe attributes of security are:: Availability Availability ConfidentialityConfidentiality IntegrityIntegrity Authentication Authentication Non-repudiation.Non-repudiation.

Page 54: Ad-Hoc Networks

Page Number: 54

/130

Attributes of securityAttributes of security

Availability Availability ensures the survivability of network services ensures the survivability of network services despite denial of service attacks.despite denial of service attacks.

A denial of service attack could be launched A denial of service attack could be launched at any layer of an ad hoc network. at any layer of an ad hoc network.

On the physical and media access control layers, On the physical and media access control layers, an adversary could employ jamming an adversary could employ jamming to interfere with communication on physical channels. to interfere with communication on physical channels.

On the network layer disruption of the routing protocol On the network layer disruption of the routing protocol can cause a break of the network. can cause a break of the network.

Page 55: Ad-Hoc Networks

Page Number: 55

/130

Attributes of securityAttributes of security

ConfidentialityConfidentiality ensures that certain informationensures that certain information is never disclosed to unauthorized entities. is never disclosed to unauthorized entities. Leakage of information could have devastatingLeakage of information could have devastating consequences. consequences. Routing information must also remain confidential in some cases.Routing information must also remain confidential in some cases.

Page 56: Ad-Hoc Networks

Page Number: 56

/130

Attributes of securityAttributes of security

IntegrityIntegrity guarantees that a message being transferred is guarantees that a message being transferred is never corrupted. never corrupted.

A message could be corrupted because of benign failures, A message could be corrupted because of benign failures, such as radio propagation impairment, such as radio propagation impairment, or because of a malicious attacks on the network.or because of a malicious attacks on the network.

Page 57: Ad-Hoc Networks

Page Number: 57

/130

Attributes of securityAttributes of security

AuthenticationAuthentication enables a enables a node to ensure the identity of the node to ensure the identity of the peer node it is communicating with.peer node it is communicating with.

Without authentication, an Without authentication, an adversary could masquerade a adversary could masquerade a node, thus gaining unauthorized node, thus gaining unauthorized access to resource and sensitive access to resource and sensitive information and interfering with the information and interfering with the operation of other nodes.operation of other nodes.

Page 58: Ad-Hoc Networks

Page Number: 58

/130

Attributes of securityAttributes of security

Non-repudiationNon-repudiation ensures that that the origin ensures that that the origin of a message cannot deny having sent the message. of a message cannot deny having sent the message. Non-repudiation is useful for detection and isolation Non-repudiation is useful for detection and isolation

of compromised nodes. of compromised nodes.

Page 59: Ad-Hoc Networks

Page Number: 59

/130

Challenges and opportunities Challenges and opportunities Attacks ranging from passive eavesdropping Attacks ranging from passive eavesdropping

to active impersonation, message replay, and message distortion. to active impersonation, message replay, and message distortion. Eavesdropping might give an adversary access Eavesdropping might give an adversary access

to secret information, violating confidentiality. to secret information, violating confidentiality. Active attack might allow the adversary: Active attack might allow the adversary:

– to delete messages,to delete messages,– to inject erroneous messages, to inject erroneous messages, – to modify messages, and to modify messages, and – to impersonate a node to impersonate a node

Violating availability, integrity, authentication, and non-repudiation.Violating availability, integrity, authentication, and non-repudiation.

Page 60: Ad-Hoc Networks

Page Number: 60

/130

Challenges and opportunitiesChallenges and opportunities We should take into account the attacks We should take into account the attacks

launched from within the network, by compromised nodes.launched from within the network, by compromised nodes. The ad-hoc networks should have a distributed architecture The ad-hoc networks should have a distributed architecture

with no central entities.with no central entities. Introducing any central entity into our security solution Introducing any central entity into our security solution

could lead to significant vulnerability.could lead to significant vulnerability.

Page 61: Ad-Hoc Networks

Page Number: 61

/130

Challenges and opportunitiesChallenges and opportunities There are two sources of threats to routing protocols: There are two sources of threats to routing protocols:

– from external attackersfrom external attackers– from compromised nodesfrom compromised nodes

Page 62: Ad-Hoc Networks

Page Number: 62

/130

Challenges and opportunitiesChallenges and opportunities Detection of incorrect information is difficultDetection of incorrect information is difficult Outdated routing information Outdated routing information False routing information generated by compromised nodes False routing information generated by compromised nodes could be considered as the outdated informationcould be considered as the outdated information If routing protocols can discover multiple routers, If routing protocols can discover multiple routers,

nodes can switch to an alternative routenodes can switch to an alternative route

Page 63: Ad-Hoc Networks

Page Number: 63

/130

Challenges and opportunitiesChallenges and opportunities Another way is to use diversity codingAnother way is to use diversity coding Diversity coding takes advantage of multiple paths Diversity coding takes advantage of multiple paths

in an efficient way, without message retransmissionin an efficient way, without message retransmission Even if certain routes are compromised, Even if certain routes are compromised,

the received node may still be able to validate the received node may still be able to validate and to recover messagesand to recover messages

Page 64: Ad-Hoc Networks

Page Number: 64

/130

Challenges and opportunitiesChallenges and opportunities Cryptographic schemesCryptographic schemes

– digital signaturedigital signature– public and private keyspublic and private keys

Key management serviceKey management service A public key infrastructure is superior in distributing keys A public key infrastructure is superior in distributing keys

and in achieving integrity and non-repudiation.and in achieving integrity and non-repudiation. In a public key infrastructure, In a public key infrastructure,

each node has a public/private key pair. each node has a public/private key pair. Public keys can be distributed to other nodes, Public keys can be distributed to other nodes, while private keys should be kept confidential while private keys should be kept confidential to individual nodes.to individual nodes.

Page 65: Ad-Hoc Networks

Page Number: 65

/130

Challenges and opportunitiesChallenges and opportunities There is a trusted entity called Certification Authority (CA) There is a trusted entity called Certification Authority (CA)

for key management. for key management. The CA has a public/private key pairThe CA has a public/private key pair Public key is known to every nodePublic key is known to every node CA signs certificates binding public keys to nodesCA signs certificates binding public keys to nodes The trusted CA has to stay on-line to reflect the current bindingThe trusted CA has to stay on-line to reflect the current binding Although no single node is trustworthy in an ad hoc network Although no single node is trustworthy in an ad hoc network

we can distribute trust to an aggregation of nodes. we can distribute trust to an aggregation of nodes. Assuming that any t+1Assuming that any t+1 nodes will unlikely be all compromised, nodes will unlikely be all compromised,

consensus of at least t+1 nodes is trustworthy.consensus of at least t+1 nodes is trustworthy.

Page 66: Ad-Hoc Networks

Page Number: 66

/130

Challenges and opportunitiesChallenges and opportunities This is the principle of distributed trust.This is the principle of distributed trust. To accomplish distribution of trust in key management service To accomplish distribution of trust in key management service

one can use threshold cryptography.one can use threshold cryptography. An (n,t+1) threshold cryptography An (n,t+1) threshold cryptography

scheme allows n parties to share scheme allows n parties to share the ability to perform a cryptographic the ability to perform a cryptographic operation (e.g., creating a digital operation (e.g., creating a digital signature), so that any t+1 parties signature), so that any t+1 parties can perform this operation jointly, can perform this operation jointly, whereas it is infeasible for most t whereas it is infeasible for most t parties to do so, even by collusion.parties to do so, even by collusion.

Page 67: Ad-Hoc Networks

Page Number: 67

/130

Challenges and opportunitiesChallenges and opportunities We divide the private key k of the service into n shares (s1,s2,We divide the private key k of the service into n shares (s1,s2,

…,sn), assigning one share to each server.…,sn), assigning one share to each server. Each server generates a partial signature for the certificate using Each server generates a partial signature for the certificate using

its private key share its private key share With t +1 correct partial signature, With t +1 correct partial signature,

the combiner is able to compute the signature for the certificate.the combiner is able to compute the signature for the certificate. Compromised servers cannot generate Compromised servers cannot generate

correctly signed certificates by themselves correctly signed certificates by themselves

Page 68: Ad-Hoc Networks

Page Number: 68

/130

Challenges and opportunitiesChallenges and opportunities A combiner can verify the validity of a computed signature A combiner can verify the validity of a computed signature

using the service public key.using the service public key. In case verification fails In case verification fails

the combiner tries another set of partial signatures. the combiner tries another set of partial signatures. A problem with threshold cryptography is that it assumes A problem with threshold cryptography is that it assumes

synchronous system and an ad hoc network is asynchronous by its naturesynchronous system and an ad hoc network is asynchronous by its nature Any synchrony assumption is a vulnerability in the systemAny synchrony assumption is a vulnerability in the system Fortunately there is an asynchrony prototype of such a key management Fortunately there is an asynchrony prototype of such a key management

service, which has been implemented recently. service, which has been implemented recently.

Page 69: Ad-Hoc Networks

Page Number: 69

/130

SummarySummary

An ad hoc network is very vulnerable to many kinds of attacks.An ad hoc network is very vulnerable to many kinds of attacks. We have to protect not only the data, but also the routing information.We have to protect not only the data, but also the routing information. The best way for that is a cryptography scheme The best way for that is a cryptography scheme

with public/private key management, combined with distribution of trust.with public/private key management, combined with distribution of trust. But it is not cheap and it is complex.But it is not cheap and it is complex. A lot of things still have to be done in this area in the future. A lot of things still have to be done in this area in the future.

Page 70: Ad-Hoc Networks

BluetoothBluetooth

Following the steps of King Harald...

Page 71: Ad-Hoc Networks

Page Number: 71

/130

BluetoothBluetooth

Ericsson Mobile Communications ABEricsson Mobile Communications AB IBM Corp.IBM Corp. Intel Corp.Intel Corp. Nokia Mobile PhonesNokia Mobile Phones Toshiba Corp.Toshiba Corp.

Special Interest Group (SIG):

Page 72: Ad-Hoc Networks

Page Number: 72

/130

BluetoothBluetooth

Open specification for short-range wireless connectivityOpen specification for short-range wireless connectivity Effortless, instant connectionsEffortless, instant connections Wide range of communication devicesWide range of communication devices Based on a radio linkBased on a radio link Facilitates fast and secure transmission of both voice and dataFacilitates fast and secure transmission of both voice and data Operates in a globally available frequency bandOperates in a globally available frequency band

Bluetooth wireless technology:

Page 73: Ad-Hoc Networks

Page Number: 73

/130

BluetoothBluetooth

Bluetooth module:

• ports (USB, UART, PCM)

• baseband

• voltage regulator

• crystal

• radio

• antenna interface

• flash

Page 74: Ad-Hoc Networks

Page Number: 74

/130

BluetoothBluetooth

External interfaces:• USB 1.1 (12 Mbps), full USB slave functionality

• UART (Rx, Tx, RTS and CTS), 460.8 kbs

• PCM (sync 8kHz, clock 200kHz-2MHz)

Antenna Interface:• 50 ohm Bluetooth ISM band antenna (2.4 - 2.5 GHz)

Page 75: Ad-Hoc Networks

Page Number: 75

/130

BluetoothBluetooth

Communication layers:• Base Band (BB)

• Link Manager (LM)

• Host Controller Interface (HCI)

Additional software:• L2CAP

• RFCOMM

Page 76: Ad-Hoc Networks

Page Number: 76

/130

BluetoothBluetooth

Base Band General Description:• Frequency hop transceiver• Shaped, binary FM modulation• Symbol rate is 1 Ms/s• Slotted channel is applied with a nominal slot length of 625 ms.• Time-Division Duplex (TDD) scheme• Information is exchanged through packets• Each packet is transmitted on a different hop frequency• Combination of circuit and packet switching.

Page 77: Ad-Hoc Networks

Page Number: 77

/130

BluetoothBluetooth

Bluetooth can support:• Asynchronous data channel• Up to three simultaneous synchronous voice channels• Channel which simultaneously supports asynchronous data and synchronous voice

Page 78: Ad-Hoc Networks

Page Number: 78

/130

BluetoothBluetooth

Bluetooth system consists of:• Radio unit• Link control unit• Link management and host terminal interface functions

Page 79: Ad-Hoc Networks

Page Number: 79

/130

BluetoothBluetooth

Connection types:• point-to-point

• point-to-multipoint

Master/slave communication:• piconets

• scatternets

Page 80: Ad-Hoc Networks

Page Number: 80

/130

BluetoothBluetooth

Other features:• Link Manager Protocol

• Logical Link Control

• Service Discovery Protocol

• RFCOMM

• IrDA

• Telephony Control Protocol

• ...

Potential platform for ad-hoc network realization!

Page 81: Ad-Hoc Networks

Design of ad-hoc multihop sensor net Design of ad-hoc multihop sensor net with Bluetooth: Lessons learnedwith Bluetooth: Lessons learned

How to make your electronic devices cooperate with each other?

Page 82: Ad-Hoc Networks

Page Number: 82

/130

IntroductionIntroduction

The main goals of this project:The main goals of this project:

Creating hw/sw specification for replacing and/or upgrading the Creating hw/sw specification for replacing and/or upgrading the existing wire systems for data acquisition and process controlexisting wire systems for data acquisition and process control– Development of routing protocolDevelopment of routing protocol– Connecting Bluetooth with a microcontroller (router)Connecting Bluetooth with a microcontroller (router)– Integration of routing protocol on the base Bluetooth chipIntegration of routing protocol on the base Bluetooth chip

Universal platform for wireless integrationUniversal platform for wireless integration::– Stable and universal hardware platformStable and universal hardware platform– Reliable and easy replaceable softwareReliable and easy replaceable software

Page 83: Ad-Hoc Networks

Page Number: 83

/130

System OverwievSystem Overwiev

An open data acquistion system, based on wireless An open data acquistion system, based on wireless ad-hoc multihop sensor network:ad-hoc multihop sensor network:

Routing protocolRouting protocol Interface and routing module (IFRM)Interface and routing module (IFRM) Personal Digital Assistant (PDA)Personal Digital Assistant (PDA) Digital Signal Processing System (DSPS)Digital Signal Processing System (DSPS) Software for data acquisition (Shell)Software for data acquisition (Shell) Internet accessible databaseInternet accessible database

Page 84: Ad-Hoc Networks

Page Number: 84

/130

System OverviewSystem Overview

W eb Serverdatabase

AD-HOC network

W ebclient

PDADSPS

sim ulatedsensors IFRM

Bluetooth

IFRMBluetooth

B luetooth

Page 85: Ad-Hoc Networks

Page Number: 85

/130

System OverviewSystem Overview

Basic advantages:Basic advantages: Universal and open platformUniversal and open platform Can be implemented in any environmentCan be implemented in any environment

Possibilites of use:Possibilites of use: FactoriesFactories Power plantsPower plants Health-care institutionsHealth-care institutions Rescue actionsRescue actions Research of inhospitable terrainResearch of inhospitable terrain

Page 86: Ad-Hoc Networks

Page Number: 86

/130

System OverviewSystem Overview

Main problems:Main problems: Providing critical data transmission rateProviding critical data transmission rate Stable ad-hoc networksStable ad-hoc networks

Proposed solutions:Proposed solutions: Bluetooth technologyBluetooth technology Designed routing protocolDesigned routing protocol

Page 87: Ad-Hoc Networks

Page Number: 87

/130

Implementation - routing protocolImplementation - routing protocol

Designed with the following guidelines:Designed with the following guidelines: speedspeed reliabilityreliability simplicitysimplicity

Existing solutions considered:Existing solutions considered: DSRDSR AODVAODV TORATORA

Page 88: Ad-Hoc Networks

Page Number: 88

/130

Implementation - routing protocolImplementation - routing protocol

The routing algorithm defines three types of messages:The routing algorithm defines three types of messages: Route Request (RREQ)Route Request (RREQ) Route Reply (RREP)Route Reply (RREP) Route Error (RERR)Route Error (RERR)

Page 89: Ad-Hoc Networks

Page Number: 89

/130

Implementation - routing protocolImplementation - routing protocol

Route Request:Route Request:

RREQ:

Hop Count BCID Dest Address DSN Source Address SSNHop Count – number of hops to the ending nodeBCID – unique RREQ identifierDestination Address – address to which the route is requestedDSN – the last known sequence numberSource Address – address of the node that issued RREQSSN – current route sequence number

Page 90: Ad-Hoc Networks

Page Number: 90

/130

Implementation - routing protocolImplementation - routing protocol

Route Reply:Route Reply:

RREP:

Hop Count DestinationAddress DSN Source

Address Lifetime

Hop Count – numer of hops between the source and destinationDestination Address – address of node for which a route is foundDSN – route sequence numberSource Address – address of the node that sent RREQLifetime – time in which the route is considered valid

Page 91: Ad-Hoc Networks

Page Number: 91

/130

Implementation - routing protocolImplementation - routing protocol

Route Error:Route Error:

RERR:

DestCount UnreachableDest Address

UnreachableDSN

DestCount – number of unreachable nodesUnreachable Dest Address – address of the unreachable nodeUnreachable DSN – last knows DSN, incremented by 1

Page 92: Ad-Hoc Networks

Page Number: 92

/130

Implementation - routing protocolImplementation - routing protocol

Functioning of the protocol:Functioning of the protocol:

MasterMaster GatewayGateway SlaveSlave

Page 93: Ad-Hoc Networks

Page Number: 93

/130

Implementation - routing protocolImplementation - routing protocol

Possible network topologyPossible network topology

10

10

146

9

12

M4

M4

M3

M1 M2M5

M011

11

16

4 515

0

8

133

7

2

master

gateway

pla in node

Page 94: Ad-Hoc Networks

Page Number: 94

/130

Implementation - routing protocolImplementation - routing protocol

System initialization:System initialization:

Forming of piconetsForming of piconets Creation of neighboor tablesCreation of neighboor tables Initialization of empty routing tablesInitialization of empty routing tables

Page 95: Ad-Hoc Networks

Page Number: 95

/130

Implementation - routing protocolImplementation - routing protocol

Routing table entryRouting table entry

DestAddress DSN Hop

CountLast

Hop CountNextHop Precursors Lifetime

Dest Address – address of the destination nodeDSN – destination sequence numberHop Count – number of hops to destinationLast Hop Count – hop count before route invalidationPrecursors – list of forwarding nodesLifetime – time for which route is valid

Page 96: Ad-Hoc Networks

Page Number: 96

/130

Implementation - routing protocolImplementation - routing protocol

Sending RERR:Sending RERR:

Link is brokenLink is broken No active route to destinationNo active route to destination RRER is received from a neigboring nodeRRER is received from a neigboring node

Page 97: Ad-Hoc Networks

Page Number: 97

/130

Implementation - routing protocolImplementation - routing protocol

Simulation:Simulation:

Starting topology specified in the configuration fileStarting topology specified in the configuration file Number of nodes is not limitedNumber of nodes is not limited For each node, a separate thread of execution is createdFor each node, a separate thread of execution is created Messages and destinations are being generated in random fashionMessages and destinations are being generated in random fashion Traversing of nodes between piconetsTraversing of nodes between piconets

Page 98: Ad-Hoc Networks

Page Number: 98

/130

Implementation - routing protocolImplementation - routing protocol

Process of route discovery (RREQ forwarding)Process of route discovery (RREQ forwarding)

M 4

M 3

M 1

M 2

M 0

11

16

4

5

0

8

3

2

1RREQ

RREQ

RREQ

RREQM 0 8 0 M 0 1 0

M 0 M 1 0M 0 3,7 0M 1 3,7

M 0 M 1 0

M 0 2 0M 1 2 0

RREQ

RREQ

RREQ

RREQRREP

Page 99: Ad-Hoc Networks

Page Number: 99

/130

Implementation - routing protocolImplementation - routing protocol

Process of route discovery (RREP forwarding)Process of route discovery (RREP forwarding)

M 1

M 0

4

0

3

1 M0 1 06 3,7 0

M0 M 1 0

6 M 1 0

6 1 0

RREP

RREP

RREP

Page 100: Ad-Hoc Networks

Page Numb

er: 100/130

Implementation - routing protocolImplementation - routing protocol

Usability analysis:Usability analysis: Advantages compared to classic broadcast algorithmsAdvantages compared to classic broadcast algorithms

num ber o f nodes

num ber o f connections

Page 101: Ad-Hoc Networks

Page Numb

er: 101/130

Implementation - routing protocolImplementation - routing protocol

Usability analysis:Usability analysis: Elimination of redundant piconetsElimination of redundant piconets

1

1

1

5 55 55 5

5

2

2

2

3

3

34

4

4

master

master

master

host is entering piconet host is entering piconet

master is detec tinga new host

slave hosts break connections

Page 102: Ad-Hoc Networks

Page Numb

er: 102/130

Implementation - IFRMImplementation - IFRM

The routing protocol was implemented The routing protocol was implemented in a separate hardware module:in a separate hardware module:

Serial (UART) connection with BluetoothSerial (UART) connection with Bluetooth HCI levelHCI level

Page 103: Ad-Hoc Networks

Page Numb

er: 103/130

Implementation - IFRMImplementation - IFRM

The main functions of IFRM:The main functions of IFRM: Forming of a wireless multihop ad-hoc networkForming of a wireless multihop ad-hoc network Link maintenanceLink maintenance Packet routingPacket routing Route discoveryRoute discovery Providing a transparent interface Providing a transparent interface

between the ad-hoc network and any serial (RS-232) devicebetween the ad-hoc network and any serial (RS-232) device Providing PDA functionalityProviding PDA functionality

Page 104: Ad-Hoc Networks

Page Numb

er: 104/130

Implementation - IFRMImplementation - IFRM

The architecture of IFRM:The architecture of IFRM:

PIC 17C756Am icrocon to lle r

C O N 4serial po rt 2

E xternal R A M16 K B

(8 K w ords)

E x ternal F L A S HR O M64 K B

(32 K w ords)

C O N 3serial po rt 1

to B luetoo thm odule

to host(senso r, PC , etc.)

signa lingL E D s

C O N 2 & CO N 5I/O ports

to keyboard(optional)

to L C D(optional)

C O N 6IC S P

Page 105: Ad-Hoc Networks

Page Numb

er: 105/130

Implementation - IFRMImplementation - IFRMRouting protocol - host sideRouting protocol - host sideThe modified AODV protocol, with the following restrictions:The modified AODV protocol, with the following restrictions:

– Size of routing tables is limited to 79 entriesSize of routing tables is limited to 79 entries– Communication in the network is server centricCommunication in the network is server centric

M H – m obile host (e .g . sen sor )

M H

SE RV E R

M HM H

M HM H

M H

M H

M H

M H

M H

M H

M H

M H

d ata flow

Page 106: Ad-Hoc Networks

Page Numb

er: 106/130

Implementation - IFRMImplementation - IFRMRouting protocol - host sideRouting protocol - host side

The modified AODV protocol, with the following restrictions:The modified AODV protocol, with the following restrictions:– End-to-end flow control is omittedEnd-to-end flow control is omitted– CRC checking and retransmission are not implementedCRC checking and retransmission are not implemented– Packet sequence is not checkedPacket sequence is not checked– Restrictions due to fact that Bluetooth modules do not conform Restrictions due to fact that Bluetooth modules do not conform

to the Bluetooth V1.0B specificationto the Bluetooth V1.0B specification

Page 107: Ad-Hoc Networks

Page Numb

er: 107/130

Implementation - IFRMImplementation - IFRMRouting protocol - host sideRouting protocol - host side

Assumptions due to uncomformance to V1.0b specification:Assumptions due to uncomformance to V1.0b specification:– In course of full-duplex communicationIn course of full-duplex communication

there is no implicit master-slave switchthere is no implicit master-slave switch– Inquiry and paging are possible Inquiry and paging are possible

without interfering with the current transmissionwithout interfering with the current transmission– Only the master can broadcast on the piconetOnly the master can broadcast on the piconet– A node can transparently be a member in more piconetsA node can transparently be a member in more piconets

(Bluetooth baseband controller is capable of transparent TD multiplexing)(Bluetooth baseband controller is capable of transparent TD multiplexing)– It is possible to have more than 7 nodes in a piconetIt is possible to have more than 7 nodes in a piconet

(parking and unparking is done transparently by the baseband controller)(parking and unparking is done transparently by the baseband controller)

Page 108: Ad-Hoc Networks

Page Numb

er: 108/130

Implementation - IFRMImplementation - IFRMRouting protocol - host sideRouting protocol - host side

Bugs and workarounds:Bugs and workarounds:– Sending two consecutive broadcast packets causes a resetSending two consecutive broadcast packets causes a reset– During maximum full-duplex transfer, During maximum full-duplex transfer,

packets or parts of the packets disappearpackets or parts of the packets disappear

Page 109: Ad-Hoc Networks

Page Numb

er: 109/130

Implementation - IFRMImplementation - IFRM

Connection of IFRM with the mobile hostConnection of IFRM with the mobile host

A d-hocnetw orkH O S T

(e.g. sensor, P C , e tc .)

IF R M

B L U E T O O T HM O D U L ER o uting

Page 110: Ad-Hoc Networks

Page Numb

er: 110/130

Implementation - IFRMImplementation - IFRM

Routing protocol - server sideRouting protocol - server side

No routing moduleNo routing module The software performs routingThe software performs routing Special mechanism for implicit destination address discoverySpecial mechanism for implicit destination address discovery

Page 111: Ad-Hoc Networks

Page Number: 111

/130

Implementation - IFRMImplementation - IFRM

Routing protocol - server side Routing protocol - server side

Communication with BluetoothCommunication with Bluetooth– TCP portsTCP ports– For each mobile host exists a corresponding TCP port on the severFor each mobile host exists a corresponding TCP port on the sever– Port numbers start from 10 000Port numbers start from 10 000– All communication is performed over the TCP/IP connections on these portsAll communication is performed over the TCP/IP connections on these ports– The mapping of ports and hardware addresses of Bluetooth modules is staticThe mapping of ports and hardware addresses of Bluetooth modules is static

SE RV E R (PC )

A d-hocnetw orkB L U E T O O T H

M O D U L EE xp ert sys tem

Page 112: Ad-Hoc Networks

Page Numb

er: 112/130

Implementation - PDAImplementation - PDA

The role of PDA is to provide mobility to the expert.The role of PDA is to provide mobility to the expert.

PDA is capable of receiving two types of messages:PDA is capable of receiving two types of messages:– Sensors have reported irregular data, but expert system managed to stabilize Sensors have reported irregular data, but expert system managed to stabilize

the system. The confirmation is required.the system. The confirmation is required.– Sensors have reported irregular data and expert system did not manage Sensors have reported irregular data and expert system did not manage

to stabilize the system. The remote command and presence is required.to stabilize the system. The remote command and presence is required. PDA is capable of sending two types of messages:PDA is capable of sending two types of messages:

– Confirmation of received warningConfirmation of received warning– Command that initiates some action in the system, based on received dataCommand that initiates some action in the system, based on received data

In this phase, the internal battery supply is not designed.In this phase, the internal battery supply is not designed.

Page 113: Ad-Hoc Networks

Page Numb

er: 113/130

Implementation - DSPSImplementation - DSPS

DSPS is realised as an example of deviceDSPS is realised as an example of devicethat can be connected to this platform.that can be connected to this platform.

Based on TI Digital Signal ProcessorBased on TI Digital Signal Processor Gathering of information from different peripheralsGathering of information from different peripherals Real-time processingReal-time processing Transferring data to server over IFRMTransferring data to server over IFRM

Page 114: Ad-Hoc Networks

Page Numb

er: 114/130

Implementation - DSPSImplementation - DSPS

The DSPS architecture:The DSPS architecture:

TITMS320LF2407

ResistorCapacitorDiodeM atrix

CON8:AnalogInputs

CO N6:EventM anagerA

CON8:Address, Data &Control DSP Bus Signaling

LED

MAX3225 PCA82C250

CON2:RS232

CO N3:CAN BUS

CON 9:SynchronousSerial Link

LCD (optional)

PW M

Capture

Tim er

SPIInterface

SCIInterface

CAN BUSInterface

Page 115: Ad-Hoc Networks

Page Numb

er: 115/130

Implementation - DSPSImplementation - DSPS

DSPS Communication:DSPS Communication:

Standard RS-232 connection (MAX3225cpp)Standard RS-232 connection (MAX3225cpp) CAN driverCAN driver Synchronous Serial Interface (SPI)Synchronous Serial Interface (SPI)

DigitalSignal

ProcessingModule

Analog InputInterfaceModule(IFRM )

Page 116: Ad-Hoc Networks

Page Numb

er: 116/130

Implementation - DSPSImplementation - DSPS

DSPS function:DSPS function:

Finding spectrum of some analog signal using FFTFinding spectrum of some analog signal using FFT Transferring data to server via transparent ad-hoc networkTransferring data to server via transparent ad-hoc network Receiving commands from the system, Receiving commands from the system,

thus creating positive feedback systemthus creating positive feedback system

Page 117: Ad-Hoc Networks

Page Numb

er: 117/130

Implementation - ShellImplementation - ShellMultipurpose software platform:Multipurpose software platform:

Data acquisitionData acquisition Decision makingDecision making Signal processingSignal processing SlarmingSlarming Tracking the current stateTracking the current state

of the systemof the system Database administrationDatabase administration

Page 118: Ad-Hoc Networks

Page Numb

er: 118/130

Implementation - ShellImplementation - Shell

Communication with sensors:Communication with sensors:

TCP/IP portsTCP/IP ports Two-way socket communicationTwo-way socket communication Conformance to IEEE 999-1992. SCADA specificationConformance to IEEE 999-1992. SCADA specification

Page 119: Ad-Hoc Networks

Page Numb

er: 119/130

Implementation - ShellImplementation - ShellSystem configuration:System configuration:

Type of the sensorType of the sensor Name of the sensorName of the sensor Factory address of Factory address of

corresponding Bluetooth modulecorresponding Bluetooth module Range of allowed valuesRange of allowed values

Page 120: Ad-Hoc Networks

Page Numb

er: 120/130

Implementation - ShellImplementation - ShellReadings displayReadings display

Simple viewSimple view Graph viewGraph view Real-time Real-time

monitoringmonitoring HistoryHistory

Page 121: Ad-Hoc Networks

Page Numb

er: 121/130

Implementation - ShellImplementation - Shell

Spectrum analysisSpectrum analysis

Page 122: Ad-Hoc Networks

Page Numb

er: 122/130

Implementation - ShellImplementation - Shell

DatabaseDatabase

Realized with MySQL ServerRealized with MySQL Server ODBCODBC Flexible, DBMS independentFlexible, DBMS independent

Page 123: Ad-Hoc Networks

Page Numb

er: 123/130

Implementation - ShellImplementation - ShellExpert SystemExpert System

Monitoring (controlling)Monitoring (controlling) Knowledge baseKnowledge base Algorithm of direct chainingAlgorithm of direct chaining Based on preconditions (sensor readings) and using the rules, Based on preconditions (sensor readings) and using the rules,

the expert system reaches a decisionthe expert system reaches a decision Depending on the actual application, Depending on the actual application,

any expert system with its knowledge base can be easily integratedany expert system with its knowledge base can be easily integrated

Page 124: Ad-Hoc Networks

Page Numb

er: 124/130

Implementation - Internet connectivityImplementation - Internet connectivity

The system database can be accessed from a Web client, The system database can be accessed from a Web client, with the purpose of shortening the response time.with the purpose of shortening the response time.

MySQL ServerMySQL Server PHP 4.0.4PHP 4.0.4 Apache Web Server 1.3.14Apache Web Server 1.3.14

Page 125: Ad-Hoc Networks

Page Numb

er: 125/130

Implementation - Internet connectivityImplementation - Internet connectivity

Standard three-tier architecture is used:Standard three-tier architecture is used:

web clientserver

PHP script

http request

DBM Ssql query

recordset

http reply

Page 126: Ad-Hoc Networks

Page Numb

er: 126/130

Implementation - Internet connectivityImplementation - Internet connectivity

Web client access:Web client access:

Username and passwordUsername and password Choosing between sensorsChoosing between sensors Formulating search queries:Formulating search queries:

– by timeby time– by valueby value

Extending the system Extending the system towards full Internet automationtowards full Internet automation

Page 127: Ad-Hoc Networks

Page Numb

er: 127/130

Testing and integrationTesting and integrationSeparate component testing:Separate component testing:

Routing protocolRouting protocol IFRMIFRM DSPSDSPS PDAPDA ShellShell DatabaseDatabase Internet connectivityInternet connectivity

Page 128: Ad-Hoc Networks

Page Numb

er: 128/130

Testing and integrationTesting and integration

Component integration:Component integration:

Shell and databaseShell and database Internet accessInternet access Communication between Shell and IFRMCommunication between Shell and IFRM

Page 129: Ad-Hoc Networks

Page Numb

er: 129/130

Testing and integrationTesting and integration

Final integration:Final integration:

Modification of the simulatorModification of the simulator Testing IFRM in the network with more than 100 nodesTesting IFRM in the network with more than 100 nodes Integration of DSPSIntegration of DSPS

Page 130: Ad-Hoc Networks

Page Numb

er: 130/130

SummarySummary Indicating a new course of development of wireless communicationIndicating a new course of development of wireless communication Integration of different electronic devices in a single information networkIntegration of different electronic devices in a single information network Open system: any device capable of serial communication can be connectedOpen system: any device capable of serial communication can be connected Creation of custom ad-hoc networksCreation of custom ad-hoc networks Java-enabled microcontrollersJava-enabled microcontrollers Integration of the routing protocol on the Bluetooth basebandIntegration of the routing protocol on the Bluetooth baseband Possible improvements:Possible improvements:

– Additional research of the routing protocolAdditional research of the routing protocol– Testing IFRM in real-world working conditionsTesting IFRM in real-world working conditions– Making software even more modularMaking software even more modular– Development of several classes of sensorsDevelopment of several classes of sensors– Potential GPS integrationPotential GPS integration– Internet automationInternet automation