1 Types of Power-Saving MACs The Sensor MAC (S-MAC) Three - - PDF document

1
SMART_READER_LITE
LIVE PREVIEW

1 Types of Power-Saving MACs The Sensor MAC (S-MAC) Three - - PDF document

What Is Media Access Control? Media Access Control (MAC) determines who gets access to the shared medium, and when Media Access Control In wired settings, usually just tries to avoid Greg Hackmann contention In wireless settings, can


slide-1
SLIDE 1

1

Media Access Control

Greg Hackmann CSE520S Fall 2007

2

What Is Media Access Control?

Media Access Control (MAC) determines who gets access to the shared medium, and when In wired settings, usually just tries to avoid contention In wireless settings, can also significantly reduce energy consumption

3

Carrier Sense Multiple Access, Collision Avoidance (CSMA/CA)

CS CS

4

Hidden Terminal Problem

5

Virtual Carrier Sense: RTS/CTS

RTS CTS Payload NAV 6

Power-Saving MAC

Many applications’ expected lifetime: months or years Actual lifetime:

  • AA batteries: 2000 mAh (if you’re lucky)
  • CC2420 radio: 19.7 mA when idle but awake (RX mode)
  • 2000 mAh / 19.7 mA = 101.5 h 6 days

This is a problem! Solution: keep the radio asleep most of the time

  • Duty cycles on the order of 0.1% – 1%
slide-2
SLIDE 2

2

7

Types of Power-Saving MACs

  • Three distinct classes of power-saving MAC protocols:
  • Scheduled contention: nodes periodically wake up in unison,

contend for access to channel, then go back to sleep

  • S-MAC [Ye 2002], T-MAC [van Dam 2003]
  • Channel polling: nodes independently wake up to sample radio

channel

  • B-MAC [Polastre 2004], X-MAC [Buettner 2006]
  • Time division multiple access (TDMA): nodes maintain

schedule of when to wake and when they’re allowed to transmit

  • 802.15.4 [IEEE 2003], DRAND [Rhee 2006]
  • Different trade-offs for latency, power consumption,

runtime overhead, etc.

  • Motivation for hybrid protocols: SCP [Ye 2006], Z-MAC [Rhee

2005], Funneling MAC [Ahn 2006]

8

The Sensor MAC (S-MAC)

S-MAC is the first MAC protocol designed specifically for sensor networks Guiding assumptions:

  • Many small, self-configuring nodes arranged in a multi-

hop mesh

  • Node-to-base station traffic rare
  • Maximize application-wide performance over node-level

fairness

  • Reduce traffic through in-network processing
  • Sacrifice some latency for longer lifetime

9

S-MAC: Synchronized Sleeping

Nodes stay asleep most of the time Periodically wake for short intervals (0.5 s) to see if anyone’s sending Very low energy consumption when traffic is low

10

S-MAC: Boot Phase

5 s 4.5 s 3 s 3 s Waking up in 3 s 5 s Waking up in 5 s Waking up in 4.5 s 4.5 s

11

S-MAC: Sending a Packet

Time awake divided into two parts: SYNC and RTS Node periodically send SYNC packet to keep clocks in sync CSMA/CA used to contend for access to wireless channel

CS CS

Receiver Wants to SYNC Wants to SYNC & send data Wants to send data

SYNC RTS

12

S-MAC: Sending a Packet

  • RTS section used for

transmitting data

  • CSMA/CA again, followed

by RTS/CTS

CS CS CS CS

Receiver Wants to SYNC Wants to SYNC & send data Wants to send data

SYNC RTS

slide-3
SLIDE 3

3

13

S-MAC: Sending a Packet

CTS for someone else

  • > go to sleep
  • Overhearing avoidance

Sender does one RTS/CTS then sends data for rest of frame All data packets are ACKed

  • Packet fragmentation =

higher reliability

Receiver RTS Winner

RTS

RTS CTS DATA DATA ACK ACK

Sleep Sleep

14

S-MAC: Evaluation

15

A Look at S-MAC

Power savings over standard 802.11 MAC Long listening period is expensive

  • Everyone stays awake unless somebody transmits

Time synchronization overhead even when network is idle RTS/CTS and ACK overhead when sending data Complex to implement

16

Berkeley MAC (B-MAC)

t t

17

B-MAC: Throughput

18

B-MAC: Power Consumption

slide-4
SLIDE 4

4

19

A Look at B-MAC

  • Low overhead when network is idle
  • Simple to implement
  • Better power savings, latency, and throughput than S-MAC
  • Lower duty cycle -> longer preambles:
  • Higher average latency
  • Higher cost to send
  • Higher cost to overhear
  • More contention

20

X-MAC: Room for Improvement

Sender Recipient Neighbor Payload Header 21

X-MAC: Overhearing Avoidance

Sender Recipient Neighbor Payload Header Destination 22

X-MAC: Preamble ACKing

Sender Recipient Neighbor Payload Header Destination ACK 23

X-MAC: Current Draw

24

X-MAC: Latency

slide-5
SLIDE 5

5

25

A Look at X-MAC

  • Better latency, throughput, and power consumption than

B-MAC for unicast traffic

  • Little energy consumed by overhearing
  • Still simple to implement
  • No improvements over B-MAC for broadcast traffic
  • On average, cuts preamble by half -> sending packets is

still expensive

26

TDMA

A Transmits B Transmits C Transmits Sleep Sleep Time Sync Frame Slot

27

A Look at TDMA

Predictable latency, throughput, and duty cycle Low packet loss due to contention Schedules must be recreated when nodes leave/enter neighborhood Time synchronization overhead Slots wasted when scheduled node has nothing to send Often complex to implement

28

SCP: Scheduled Contention + Channel Polling

t t

29

SCP: Reducing Contention

  • Two-phase contention: CS before preamble and between

preamble & payload

  • Lower probability of contention vs. one longer CS window

CS

Receiver Sender

CS

30

SCP: Adaptive Channel Polling

  • Add N sub-intervals whenever packet received
  • Reduces latency of bursty data
  • Continue adding sub-intervals as long as they’re needed,

and as long as there’s room

Receiver Sender

slide-6
SLIDE 6

6

31

SCP: Multi-Hop Pipelining

  • Sender “gives up” first regular check after sending multi-

hop traffic

  • Whole network quickly moves into adaptive polling mode

Hop 1 Sender Hop 2 32

SCP: Energy Consumption

33

SCP: Multi-Hop Latency

34

A Look at SCP

Channel polling: low overhead when idle Scheduled contention: low cost to send Low latency for multi-hop traffic Complex to implement Experimental radio data required Overhead due to time synchronization

  • Reduced by piggybacking on data packets

35

Zebra MAC (Z-MAC): TDMA + Channel Polling

A Transmits B Transmits C Transmits Sleep Sleep Time Sync

A B C 36

A Look at Z-MAC

Reduces waste from unused slots

  • Higher throughput and lower latency

Throughput, latency, and duty cycle no worse than pure TDMA Nodes still stay awake if no one transmits Still overhead from time sync Complex to implement

slide-7
SLIDE 7

7

37

So Why Are They Rarely Used?

MAC protocols have additional radio-dependent requirements beyond normal application code

  • Turn radio on and off, low latency I/O, carrier sense,

etc.

Typically implemented by forking radio stacks

  • Hard to implement
  • Must be maintained as original radio stack changes

MAC layers supported by TinyOS today:

  • CC1000: “experimental” B-MAC
  • CC2420: X-MAC

38

A Better Approach: MLA

Unified Power Management Architecture (UPMA) to the rescue! Most recent addition to UPMA: MAC Layer Architecture (MLA) [Klues 07]

  • Low-level abstractions of radio functionality
  • High-level implementations of common MAC logic

Implemented on TinyOS 2.0.1 Used to create 5 platform-independent MAC layers

  • B-MAC, X-MAC, SCP, TDMA, variant of Z-MAC