IN4316 IN4316 ––Lecture 2Lecture 2 IN4316IN4316 IN4316 ––Lecture 2Lecture 2 Ad-hoc and...

Preview:

Citation preview

IN4316 IN4316 –– Lecture 2Lecture 2AdAd--hoc and Sensor Networkshoc and Sensor Networks

IN4316 IN4316 –– Lecture 2Lecture 2AdAd--hoc and Sensor Networkshoc and Sensor NetworksAdAd hoc and Sensor Networkshoc and Sensor NetworksAdAd hoc and Sensor Networkshoc and Sensor Networks

Koen LangendoenKoen LangendoenPhilipp Philipp GlatzGlatz, , VenkatVenkat IyerIyer

Andreas Andreas LoukasLoukas, , AnreiAnrei PruteanuPruteanu, Matthias , Matthias WoehrleWoehrle

O tli di i t f i lOutline: discuss impact of wireless

• Ad-hoc networks– link layer: medium access control– link layer: medium access control– network layer: routing– transport layer: TCP/IP– transport layer: TCP/IP

• Sensor networks– localization– data processingdata processing– deployments

Ad h t kAd-hoc networks

• Each node is willing to forward data• NO dedicated routing hardware• NO dedicated routing hardware

– resilient to node/link failures

Wi l d h t kWireless ad-hoc networks

• Mobile Ad-Hoc Networks (MANETS)• Mesh Networks (e g MIT roofnet)• Mesh Networks (e.g., MIT roofnet)• Sensor Networks

Wi l i b d t diWireless is a broadcast medium

• Pictures are misleading– communication links are 3D– communication links are 3D– transmissions may interfere

Si l ti Signal propagation ranges

• Transmission range– communication is possiblecommunication is possible– low error rate

• Detection range senderDetection range– detection of the signal– no communication

transmission

• Interference range– signal may not be detected

distancedetection

interferenceg m y– signal adds to the background noise

F bit t k tFrom bits to packets

• Physical layer– coded modulated bitstream– coded, modulated bitstream– BER: Bit-Error-Rate– RSSI: Received Signal Strength Indicator– RSSI: Received Signal Strength Indicator

bl t t l CRCd t l dMAC hdCC1000/TinyOS/B-MAC

• Link layer– packets: header + data payload + CRC

preamble8

start2

len1

CRC2

data payloadup to 29

MAC hdr4

packets header data payload CRC– PER: Packet-Error-Rate

Li k l ti Link-layer propagation ranges

2200

2300

RSSI = 1/distα1

1.2

e

2100

SI

0.8

eptio

n ra

te

EYES node1900

2000

RS

0.4

0.6

acke

t rec

e

EYES node

1700

1800

0

0.2Pa

17000 5 10 15 20 25 30 35 40

Distance (metre)

00 5 10 15 20 25 30 35 40

Distance (metre)

Gray area effect [Zhao:2003]

Li k l & lti th f diLink-layer & multipath fading

CC2420 @ 2.4 GHz, power = -1dBm, 2am

0 50.6

0.70.8

0.9

100

0 0.1 0.2 0 3 0 10.2

0.30.4

0.5

0

50% goody (lambda)

0.3 0.4 0.5 0.6 0.7 0.8 0.90

0.1

x (lambda)

[Robert Poor, Ember corp.]

Medium Access ControlMedium Access ControlMedium Access ControlMedium Access ControlMedium Access ControlMedium Access ControlMedium Access ControlMedium Access Controlbackgroundbackgroundbackgroundbackground

M di A C t lMedium Access Control

Control access to the shared radio channel• avoid interference between transmissions• avoid interference between transmissions• mitigate effects of collisions (retransmit)

History 802.11

ALOHACSMA MACA

MACAW S-MACS MAC1970 1980 1990 2000 2010

M di A C t lMedium Access Control

Control access to the shared radio channel• avoid interference between transmissions• avoid interference between transmissions• mitigate effects of collisions (retransmit)

Approachest ti b d di ti • contention-based: no coordination

• schedule-based: central authority (access pt)

C lli i b d MAC t lCollision-based MAC protocols

ALOHA :• packet radio networks• packet radio networks• send when ready• 18-35% channel utilization

CSMA (C i S M lti l A )CSMA (Carrier Sense Multiple Access):• “listen before talk”• 50-80% channel utilization

Hidd t i l blHidden terminal problem

A B C

Tim

cs

mecs

csCarrier sense at sender may not sender may not prevent collision at receiver

CSMA/CA C lli i A idCSMA/CA: Collision Avoidance

A B C

MACA:• Request To Send

Tim

csRequest To Send• Clear To Send• DATA

mecs

BDATA

MACAW (Wireless)

Blocked( )• additional ACK

E d t i l blExposed terminal problem

A B C D

Parallel CSMA Tim

csParallel CSMA Parallel CSMA transfers

mecsParallel CSMA

transfers are serialized by B

cs

yCSMA/CA

Collision avoidance

Blocked

Collision avoidance can be too restrictive!restrictive!

IEEE 802 11IEEE 802.11

Operation• infrastructure mode (access point)infrastructure mode (access point)• ad-hoc mode

Power save mechanism; not for multi-hop

P t lProtocol• carrier sense• collision avoidance (optional)

IEEE 802 11IEEE 802.11

RTS DATA

Sender

SIFSDIFS

Receiver( )

SIFS SIFS DIFSACKCTS

OthersNAV(RTS)NAV(CTS)

Contention Window

Network Allocation Vector (NAV)• collision avoidance• collision avoidance• overhearing avoidance: other nodes may sleep

S h d l b d MAC t lSchedule-based MAC protocols

Communication is scheduled in advance• no contentionno contention• no overhearing• support for delay-bound traffic (voice)pp y ( )

Time-Division Multiple Accessi i di id d i l d f• time is divided into slotted frames

• access point broadcasts schedulec din ti n b t n c lls qui d• coordination between cells required

TDMATDMAF F 2F 1Frame n Frame n+2Frame n+1

TC CPdownlink uplink

Typical WLAN setup

TC CPdownlink uplink

Typical WLAN setup• no direct communication between nodes• access point broadcast Traffic Control (TC) mapaccess point broadcast Traffic Control (TC) map• (new) nodes signal needs in Contention Period (CP)

R i t f S N t kRequirements for Sensor Networks

Handle scarce resources• CPU: 1 – 10 MHz• CPU: 1 – 10 MHz• memory: 2 – 4 KB RAM• radio: ~100 Kbps• radio: ~100 Kbps• energy: small batteries

Unattended operation• plug & play robustness

throughputlatency energyplug & play, robustness

• long lifetimefairness

WLAN WSN

C i ti ttCommunication patterns

WSN applications:• local collaboration when • local collaboration when

detecting a physical phenomenon• periodic reporting to sink

local gossipperiodic reporting to sink

Characteristics:• low data rates• small messages

<1000 bps

~25 bytesg• fluctuations (in time and space)

convergecast[ lk 200 ]

y

[Kulkarni:2004]

Di ti lit i tDirectionality experiment

350

400

250

300

t m

sg/s

150

200

good

put

CSMA directed

CSMA random

100

150g

0

50

0 100 200 300 400 500 600 700 800 900 1000input msg/s

LocalizationLocalizationLocalizationLocalizationLocalizationLocalizationLocalizationLocalizationintroductionintroductionintroductionintroduction

Th l li ti blThe localization problem

Scenario:• install nodes• install nodes• determine positions

Choices:i f t t d h

(0,0)

• infrastructure vs. ad-hoc• connectivity vs. ranging• centralized vs. distributed GPS

TargetTargetSynchronization channelRanging channel

Ad h l li tiAd-hoc localization

• Many nodes (> 100)• NO infrastructure• NO infrastructure• NO central processing• Sparse anchor nodes

– known position(0,0)

p

• Other nodes determine their position using– anchor locationsanchor locations– distance measurements

R i T h l iRanging Technologies

• Received Signal Strength Indicator (RSSI)– extremely noisy (reflections)extremely noisy (reflections)– calibration– omi-directional (sort of)

range: ~10 maccuracy: ~2-3 m ( )

• Ultrasonic time-of-flight g– (clock synchronization)– time-difference with RF range: ~10-30 m

accuracy: ~2 5 cm– lope-shape beam angle

accuracy: ~2-5 cm

R f l li tiRange-free localization

Algorithms:• Centroid [Bulusu2000]• Centroid [Bulusu2000]• Convex optimization [Doherty2001]• DV hop [Niculescu2001]• DV-hop [Niculescu2001]

Results:Results• many anchors needed • poor accuracy: > 5 Radio rangepoor accuracy: > .5 Radio range

t idcentroid

R b d l li tiRange-based localization

Algorithms:• Multihop lateration [Savvides2001]• Multihop lateration [Savvides2001]• Robust positioning [Savarese2002]• APS [Niculescu2001]• APS [Niculescu2001]

Lateration:Lateration• intersect circles, solve [Ax=b]• redundancy to handle errorsredundancy to handle errors

– range measurements– sparse anchor scenariosparse anchor scenario

L li ti i t kLocalization in sensor networks

Algorithms must limit• processing• processing• communication

but fail to do sol t ti i li N N t i i t• lateration implies NxN matrix invert

• periodic beaconing or flooding overheads

RoutingRoutingRoutingRoutingRoutingRoutingRoutingRoutingbackgroundbackgroundbackgroundbackground

Th ti blThe routing problem

Find path between S and D• ad hoc network• ad-hoc network• unique node IDs

B

EF

S

• [mobile nodes] B

A

C

G D

H

I

Cl ifi ti f ti t lClassification of routing protocols

Table-driven (proactive)• Each node maintains a routing table (to all others)Each node maintains a routing table (to all others)• Topology changes are immediately propagated• DSDV, OSLR, WRP, CGSR, … maintenance vs discovery costDSDV, OSLR, WRP, CGSR, …

Source-initiated (reactive / on-demand)maintenance vs discovery cost

• Nodes maintain only information for active destinations• Explicit route discovery (flooding)• [Route maintenance procedure used to repair routes]• AODV, DSR, TORA, SSR, …

AODVAd Hoc On-Demand Distance Vector Routing

• Now RFC 3561, based on DSDV• Source sends Route Request Packet (RREQ) • Source sends Route Request Packet (RREQ)

when a route has to be foundR t R l P k t (RREP) i t b k b • Route Reply Packet (RREP) is sent back by destination

• Route Error messages update routes

R t R t i AODVRoute Requests in AODV

Broadcast transmission

S

B

S EF

C

AH

C

G D

I

Represents transmission of RREQ

R t R t i AODVRoute Requests in AODV

S

B

S EF

C

AH

C

G D

I

Represents links on Reverse Path

R t R l i AODVRoute Reply in AODV

S

B

S EF

C

AH

DC

G

I

Represents links on path taken by RREP

R ti t bl i AODVRouting tables in AODVNextDistDest

NextDistDest

SC2GE3D

NextDistDest

D1DNextDistDest

F2D

B

S EF

C

D1D

AH

DC

G

I

R t i t i AODVRoute maintenance in AODV

S

S initiates new route discovery

B

S EF

C

AH

DC

G

I

Represents transmission of RERR

R ti i t k ?Routing in sensor networks?

Often not needed!• local gossip: broadcast• local gossip: broadcast• convergecast: spanning tree• sink-to-nodes: floodingRouting table has one entry (to-sink)g y ( )

Application level solutions (in band signaling)Application-level solutions (in-band signaling)

R ti i t k !Routing in sensor networks!

Problem: dynamic environment• link/node failures• link/node failures• multiple/mobile sinks• node mobility

S l tiSolutions:• factor in link quality: ETX (Expected #hops) • factor in location info: geographical routing

Presentation basicsPresentation basicsPresentation basicsPresentation basicsPresentation basicsPresentation basicsPresentation basicsPresentation basicsdos & don’tsdos & don’tsdos & don tsdos & don ts

S k ’ i t tiSpeaker’s instructions

• Preparations– contact your special topic instructor contact your special topic instructor – browse recent literature– propose paper for presentation (-1 week)p p p p p ( )– prepare Powerpoint slides (-2 days)

P f• Performance– bring your own laptop OR a USB memory stick

OR send Koen an e-mail (before 10:30)OR send Koen an e-mail (before 10:30)– present paper + lead discussion

L i Less is more

DO• max 6 bullets per slidemax 6 bullets per slide

DON’T• write full sentences (because that gets your audience

reading instead of paying attention to what you have to say, especially when you have to use a small font size to cramp it especially when you have to use a small font size to cramp it all on a single page!)

• use fancy fonts (sans serif is best)s fancy fonts (sans serif is best)• use animations (for experts only ☺)

A i t i th th d dA picture is worth a thousand words

DO• use illustrations/graphs/tables (1 per slide)• use illustrations/graphs/tables (1 per slide)• use color

DON’Th d li ti• show code listings

• show mathematical proofs

P ti k f tPractice makes perfect

DO• rehearse your talk (and timing)• rehearse your talk (and timing)

DON’Tit t t• recite your text

• run over time

B d lBody language

DO• speak with your hands• speak with your hands• interact with your audience

DON’Tt t h /l t /• stare at your shoes/laptop/me

• turn your back to the audience when pointing at your slides

H kHome work

• Read “classic” MAC papers– S-MAC (contention-based)– S-MAC (contention-based)– LMAC (TDMA)

• Submit summary† via CPM– 300 500 words– 300-500 words– PDF format

deadline: September 21st 10:00 (day of each class)– deadline: September 21st, 10:00 (day of each class)

† it is forbidden to copy&paste complete † it is forbidden to copy&paste complete sentences out of the original articles

Recommended