You are on page 1of 37

Routing Algorithms

for
Wireless Sensor
Networks
Artemis Paradisi
Jacques Tiberghien

- RPL: IPv6 Routing protocol for low power


and lossy networks.

IPv6 on Low Power and Lossy


Networks?
Applications
TCP/UDP
IPv6
MAC&PHY

The Internet

Applications

TCP/UDP
RPL
6LowPan
IEEE 802.15.4

The LowPower network is just one subnet


The sink node plays the role of a router
3

6LowPan Why ?
TCP/UDP
RPL
6LowPan
IEEE 802.15.4

3
001

13
TLA

8
res

IPv6 address :
24
18
NLA

SLA

64
INT

Frame length :
IPv6: <= 1280 bytes; IEEE 802.15.4: <= 81 bytes.
Frame fragmentation & defragmentation
Header length :
IPv6 header >= 40 bytes; TCP header = 20 bytes,
No version field, no flow label,
One subnet : 64 instead 128 bit addresses,
Header compression
Connectivity inside the subnet :
Single broadcast domain vs. multi-hop connectivity
Route-over architecture
4

6LowPan Why ?
IPv6 : One subnet = one broadcast domain
This is not true in LowPans!
Solutions :
- Link level routing
- Routing in the subnet !
A
Route over
uses simplified versions
of IPv6 ND protocols.

The Internet

C
D

Routing Protocol for


Low Power and Lossy Networks
RPL origin: The Internet of things.
IETF working group for IPv6 routing.
None of the existing protocols is adequate!
New design combining interesting ideas of all.
RPL Basic Mechanisms
Routing based upon one or more Destination
Oriented Directed Acyclic Graphs (DODAGs)
Optimal routes between sink and all other nodes
for both the collect and distribute data traffics.
Redundant equivalent routes are kept for
reliability in case of link or node failure.
Multiple DODAGs if different optimisation criteria.
6

RPL:
the DODAG
For node G,
D,H,L are neighbors
D is preferred parent

Floating DAG

1
F

Grounded
1 DODAG
E
1

Each link has a


cost. (distance,
latency, ETX, )
This cost can be
augmented with
node related data
(battery state, )

For node I,
E is a parent
G & H are siblings

The ETX cost function


ETX = Estimated number of transmissions from x to y.
= Number of times a frame needs to be transmitted
over a link before being acknowledged.
= (dxy x dyx) -1
dxy = success rate from x to y.
Each node broadcasts precisely once per second a
short message, each receiver counts during 10
seconds the number of broadcasts it receives from
each neighbor.

dxy = (number of frames received from x by y) / 10


What about RDC ?
8

For node G,
D,H,L are neighbors
D is preferred parent

Floating DAG

Grounded
1 DODAG

Rank = 1.0
Rank = 2.0

RPL:
the RANK of nodes in a DODAG

For node I,
E is a parent
G & H are siblings

RPL:
the RANK of nodes in a DODAG
For node G,
If route via a sibling (H)
is better , then it
should increase its
rank.

A
1

C
1

D
1

5
G
3

Grounded
1 DODAG
E
1
1

H
2

I
2

10

For node I,
E is a parent
G & H are siblings

RPL:
Messages for routing

DIS

11

DAO

Floating DAG

DIO

Grounded
1 DODAG

RPL:
Collect, Distribute and P2P routing
Distribute

Collect
A
1
C

P2P

A
1

12

Routing in sensor networks(1).


For this example,
links have a distance
as in DV and AODV.
The Rank
calculations are
made so that
Rank = hop count
D

The Internet
4

A
0/0

1
1

1
1

4
1

13

1
1

Routing in sensor networks(2).


A sends DIO to B and E.
A becomes their preferred
parent.

The Internet
4

A
0/0

B
1/4

3
3

1
1

E
1/1

4
1

14

1
1

Routing in sensor networks(3).


B sends DIO to A,C,F,G
and K.
A ignores (rank).
B becomes the parent of
all others.

The Internet
4

A
0/0

B
1/4

1
1

E
1/1

F
2/5

1
K
2/8

D
1

G
2/7

1
1

4
1

C
2/5

15

1
1

Routing in sensor networks(4).


E sends DIO to A,F,I and J.
A ignores (rank).
E becomes the parent of F,I
and J.

The Internet
4

A
0/0

B
1/4

1
1

E
1/1

F
2/2

I
2/2

J
2/2

1
K
2/8

D
1

G
2/7

1
1

4
1

C
2/5

16

1
1

Routing in sensor networks(5).


C sends DIO to B,D and G.
B ignores (rank).
C becomes the parent of
D and G.

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

1
K
2/8

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

17

1
1

Routing in sensor networks(6).


F sends DIO to B,E and K.
B and E ignore (rank),
F becomes parent of K.

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

1
K
3/3

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

18

1
1

Routing in sensor networks(7).


I sends DIO to E and J.
E ignores (rank),
J ignores (distance)

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

1
K
3/3

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

19

1
1

Routing in sensor networks(8).


J sends DIO to E,I and K.
E ignores (rank),
I and K ignore (distance)

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

1
K
3/3

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

20

1
1

Routing in sensor networks(9).


D sends DIO to C and H.
C ignores (rank),
D becomes parent of H

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
4/9

1
K
3/3

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

21

1
1

Routing in sensor networks(10).


G sends DIO to B,C,H and K.
B and C ignore (rank),
K ignores (distance)
G becomes parent of H.

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
4/7

1
K
3/3

G
3/6

1
1

4
1

D
3/8

E
1/1

C
2/5

22

1
1

Routing in sensor networks(11).


K sends DIO to B,F,G,J and L.
B,F and J ignore (rank),
K becomes parent of G and L.

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
4/7

1
K
3/3

G
4/4

1
1

4
1

D
3/8

E
1/1

C
2/5

L
4/6

23

1
1

Routing in sensor networks(12).

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
5/5

1
K
3/3

G
4/4

1
1

4
1

D
3/8

E
1/1

C
2/5

G sends DIO to B,C,H and K.


B,C and K ignore (rank),
H adapts its rank and distance
and keeps G as a parent

L
4/6

24

1
1

Routing in sensor networks(13).


L sends DIO to K,H and M.
K ignores (rank),
H ignores (distance)
L becomes parent of M

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
5/5

1
K
3/3

G
4/4

1
1

4
1

D
3/8

E
1/1

C
2/5

L
4/6

25

1
1

M
5/7

Routing in sensor networks(14).


H sends DIO to D,G,L and M.
D,G and L ignore (rank),
H becomes parent of M

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
5/5

1
K
3/3

G
4/4

1
1

4
1

D
3/8

E
1/1

C
2/5

L
4/6

26

1
1

M
6/6

Routing in sensor networks(15).


Finally, the entire DODAG
has been constructed.

The Internet
4

A
0/0

B
1/4

F
2/2

I
2/2

J
2/2

H
5/5

1
K
3/3

G
4/4

1
1

4
1

D
3/8

E
1/1

C
2/5

L
4/6

27

1
1

M
6/6

Routing in sensor networks(1).


For this example, links
have a distance as in
DV and AODV.
The Rank calculations
are made so that
Rank = Distance to sink

The Internet
A
0

1
1

4
1

28

1
1

Routing in sensor networks(2).


A sends DIO to B and E.
A becomes their
preferred parent.

The Internet
A
0

B
4

3
3

E
1

4
1

29

1
1

Routing in sensor networks(3).


E sends DIO to A,F,I and J.
A ignores (rank).
E becomes parent
F,I and J.

The Internet
A
0

B
4

3
3

E
1

F
2

I
2

J
2

4
1

30

1
1

Routing in sensor networks(4).


F sends DIO to B,E and K.
E ignores (rank).
F becomes parent of B
and K.

The Internet
A
0

B
3

3
3

E
1

F
2

I
2

J
2

K
3

4
1

31

1
1

Routing in sensor networks(5).


B sends DIO to A,C,F,G and K.
A and F ignore (rank).
B becomes parent of C and G.
K keeps its previous parent
(distance).

The Internet
A
0

B
3

E
1

F
2

I
2

G
6

J
2

K
3

1
1

3
1

4
1

C
4

32

1
1

Routing in sensor networks(6).


K sends DIO to B,F,G,J and L.
J ignores (rank),
B ignores (distance),
K becomes parent of G and L.

The Internet
A
0

B
3

E
1

F
2

I
2

G
4

J
2

K
3

1
1

3
1

4
1

C
4

L
6

33

1
1

Routing in sensor networks(7).


C sends DIO to B,D and G.
B ignores (rank),
G ignores (distance),
C becomes parent of D.

The Internet
A
0

B
3

E
1

F
2

I
2

G
4

J
2

K
3

D
7

1
1

3
1

4
1

C
4

L
6

34

1
1

Routing in sensor networks(8).


G sends DIO to B,C,H and K.
B and K ignore (rank),
C ignores (distance),
G becomes parent of H.

The Internet
A
0

B
3

E
1

F
2

I
2

G
4

J
2

K
3

D
7

H
5

1
1

3
1

4
1

C
4

L
6

35

1
1

Routing in sensor networks(9).


H sends DIO to D,G,L and M.
G ignores (rank),
L ignores (distance),
H becomes parent of D and M.

The Internet
A
0

B
3

E
1

F
2

I
2

G
4

J
2

K
3

D
6

H
5

1
1

3
1

4
1

C
4

L
6

36

1
1

M
6

RPL
Conclusions
When the network is started up, the DODAG is build.
The DODAG supports optimal routing, both for
collect and distribute protocols.
Protocols for detecting network changes and
subsequent DODAG repairs (local and global) are
part of the RPL proposal (not explained here)
An Objective Function, giving the rank of the nodes
in function of the properties of the links and the
nodes, can freely be chosen to influence the DODAG
topology and prevent loops.

37

You might also like