Anda di halaman 1dari 6

3/22/2010

Outline

 802.11 specifications overview


CHAPTER 8:
 Carrier Sensing:problems, issues, and solutions
WIFI

ðặng Lê Khoa
Email: dlkhoa@fetel.hcmuns.edu.vn

Facuty of Electronics & Telecommunications, HCMUS


1 2

802.11 Specifications

Applications

802.11 specifications overview LLC

WEP MAC
MAC Mgmt

MIB
PHY
DSSS FH IR OFDM

 Specification of layers below LLC


 Associated management/control interfaces
3 4

802.11 Specifications 802.11 Specifications


MAC Service LLC
Interface MAC Mgmt Service
LLC Interface (clause 10)
MAC MAC Mgmt (clause 6)
Service Service
MAC sublayer MAC Management
Interface Interface
LLC MAC framing (clause 7) Protocols (clause 11)
MAC MAC Layer MAC operation (clause 9) State Machines (Annex C)
sublayer Management WEP (clause 8) MIBs (Annex D)
WEP MAC State Machines (Annex C)
MAC Mgmt
PHY
PHY Service
PHY Mgmt Interface (clause 12) PHY Mgmt Service
Service Service Interface (clause 13)
MIB Interface
PLCP Sublayer Interface PHY Layer PHY Management
PHY PHY layer FH (clause 14)
DSSS FH IR OFDM Management DSSS (clause 15)
PMD Sublayer
Infrared (clause 16) MIBs (Annex D)
OFDM (clause 17)
High rate DSSS (clause 18)

5 6

1
3/22/2010

802.11 System Architecture Extended Service Set


Basic Service Set (BSS): a set of stations which communicate ESS: a set of BSSs interconnected by a distribution system (DS)
with one another

Independent Basic Service Infrastructure Basic Service


Set (IBSS) Set (BSS)

• only direct communication • AP provides


possible • connection to wired network
• no relay function • relay function • ESS and all of its stations appear to be a single MAC layer
• stations not allowed to • AP communicate among themselves to forward traffic
communicate directly • Station mobility within an ESS is invisible to the higher layers

7 8

802.11 PHY 802.11 PHY


Sender Receiver
MAC Protcol Data MAC Protcol Data
Unit (MPDU) Unit (MPDU)
Applications MAC
PHY
PLCP MAC Protcol Data
PLCP MAC Protcol Data
header Unit (MPDU)
header Unit (MPDU)
LLC
Physical Media
PMD layer
WEP Dependent (PMD) layer
MAC
MAC Mgmt
Frequency Hopping Direct Sequence Spread Infrared (IR)
MIB Spread Spectrum Spectrum (DSSS) PHY PHY
PHY (FHSS) PHY 1,2 Mbps 1,2 Mbps
DSSS FH IR OFDM 1, 2 Mbps Orthogonal Frequency
Higher rate (DSSS) PHY High rate (DSSS) PHY Division Multiplexing
20+ Mbps 11, 5.5 Mbps (OFDM) PHY
802.11g 802.11b 6,9,12,18,24,36,48,54 Mbps
802.11a
2.4 GHz
9 10
5.7 GHz

DSSS PHY DSSS PHY


Ch 1 Ch 6 Ch 11
Preamble Header MPDU Preamble Header MPDU 22 Mhz
1 Mbps 1, 2 Mbps 1 Mbps 1, 2 Mbps
DPSK
modulation DPSK
Spread the signal using Barker word (11 bits) de-modulation 83.5 Mhz
+1, -1, +1, +1, -1, +1, +1, +1, -1, -1, -1

Transmitter Transmitted signal after spreading Received signal after  Direct sequence spread spectrum
baseband signal despreading  Each channel is 22 Mhz wide
 Symbol rate
 1 Mb/s with DBPSK modulatio
 Baseband signal is spread using Barker word (10 dB processing gain)
 2 Mbps with DQPSK modulation
 Spread signal occupies approximately 22 Mhz bandwidth
 11, 5.5 Mb/ps with CCK modulation
 Receiver recovers the signal by applying the same Barker word
 DSSS provides good immunity against narrowband interferer
 Max transmit power
 CDMA (multiple access) capability is not possible  100 Mw

11 12

2
3/22/2010

802.11 MAC 802.11 MAC

 Carrier sensing (CSMA)


Applications  Rules:
• carrier ==> do not transmit
• no carrier ==> OK to transmit
LLC  But the above rules do not always apply to
wireless.
WEP
MAC • Solution: RTS/CTS
MAC Mgmt
 Collision detection (CD)
MIB  Does not work over wireless
PHY
DSSS FH IR OFDM  Therefore, use collision avoidance (CA)
• random backoff
• priority ack protocol

13 14

802.11 MAC protocol: CSMA/CA 802.11 MAC : Contention window

contention 1023
window CW max
DIFS For DSSS PHY
Slot time = 20 µs
Busy medium Next Frame
slot time
Defer access 511

255
127
63
 Use CSMA with collision Avoidance
CW min 31
 Based on carrier sense function in PHY called Clear Channel Assessment
(CCA)
 Reduce collision probability where mostly needed Fifth retransmission
Fourth retransmission
 Efficient backoff algorithm stable at high loads Third retransmission
Second retransmission
 Possible to implement different fixed priority levels First retransmission
Initial attempt

15 16

Backoff procedure CSMA/CA + ACK protocol


DIFS DIFS DIFS DIFS
DIFS DIFS

CWindow CWindow Data


Src
Frame Frame
A SIFS
defer
Frame ACK
B Dest
defer contention
Frame DIFS
C window
defer
Frame Next Frame
D Other

 Immediate access when medium is free >= DIFS


 When medium is not free, defer until the end of current frame trasnsmission + DIFS period
 Defer access based on carrier sense
 To beging backoff procedure
 Choose a random number in ( 0, Cwindow)  Direct access when medium is sensed free longer than DIFS
 Use carrier sense to determine if there is activity during each slot
 Decrement backoff time by one slot if no activity is detected during that slot  Receiver of directed frames to return an ACK immediately when
 Suspend backoff procedure if medium is determined to be busy at anytime during a backoff CRC is correct
slot
 Resume backoff precedure after the end of current frame transmission  When no ACK received then retransmit frame after a random backoff

17 18

3
3/22/2010

Fragments transmission 802.11 - MAC layer


Fragment burst
DIFS
SIFS SIFS SIFS SIFS SIFS Backoff  Priorities
Source SIFS window
Fragment 0 Fragment 1 Fragment 2  defined through different inter frame spaces
 no guaranteed, hard priorities
ACK 0 ACK 1 ACK 2
 SIFS (Short Inter Frame Spacing)
Destination • highest priority, for ACK, CTS, polling response
 PIFS (PCF IFS)
 Fragment transmission supported to improve transmission reliability under noisy • medium priority, for time-bounded service using PCF
environments
 Transmitter holds the channel until the end of fragment transmission burst  DIFS (DCF, Distributed Coordination Function
 If the source does not receive and ACK frame, it will transmit the failed MPDU IFS)
after performing the backoff procedure and the contention process • lowest priority, for asynchronous data service
 Receiver may receive duplicate fragments and is responsible for detecting and DIFS DIFS
discarding duplicate fragments PIFS
SIFS
medium busy contention next frame
t
direct access if
medium is free ≥ DIFS
19 20

Problems with carrier sensing


Exposed terminal problem

W
Carrier Sensing: problems, issues, Z is transmitting
to W
and solutions Z

X Y

Y will not transmit to X


even though it cannot interfere

/
Presence of carrier ===> hold off transmission

21 22

Problems with carrier sensing Solving Hidden Node problem with RTS/CTS
Hidden terminal problem
- listen RTS RTS CTS
- wait long enough
for the requested X Z
station to respond
with CTS - listen CTS
Z Y
- if (timeout) then W - wait long enough
ready to transmit
Y for the transmitter
W to send its data

W finds that medium is free


and it transmits a packet to Z listen RTS ==> transmitter is close to me
listen CTS ==> receiver is close to me

no carrier ===>
/ OK to transmit
Note: RTS/CTS does not solve exposed terminal problem. In the example above,
X can send RTS, but CTS from the responder will collide with Y’s data.

23 24

4
3/22/2010

RTS/CTS exchange example


SIFS
802.11 MAC sublayer Management
DIFS

RTS Frame
Src Applications

CTS ACK
Dest
352 304 8192 µs 304
µs 10 µs 10 10 µs LLC
µs µs
µs
Dest NAV (RTS) WEP
MAC
NAV (CTS) MAC Mgmt
 RTS + CTS + Frame + ACK exchange invoked when frame size is large
 Overhead estimation
MIB
 RTS -- 18 bytes (PCLP Preamble) + 6 bytes (PCLP Header) + 20 bytes (RTS) PHY
• 192 µs + 160 µs = 352 µs
 CTS -- 18 bytes (PCLP Preamble) + 6 bytes (PCLP Header) + 14 bytes (RTS) DSSS FH IR OFDM
• 192 µs + 112 µs = 304 µs
 SIFS – 10 µs
 NAV (Network Allocation Vector)
 NAV maintains prediction of future traffic on the medium based on duration information
that is announced in RTS/CTS frames prior to actual exchange of data

25 26

MAC Management: Beacon & Probes MAC Mgmt : Authentication & Association
 A station can first scan the network
and discover the presence of BSS in
Access Point

a given area AP3


AP2  With respect to an access point, a
 Scanning
station can be in one of the
Access Point

 Passive following three states


 listen for beacons on each 1) Auth exchg  Unauthenticated/Unassociated
channel
 Authenticated/Unassociated
 Active Unauthenticated
 Authenticated/Associated
 send probe and wait for Unassociated
response on each channel 2) Association exchg  A station can pre-authenticate with
Access Point

 Beacon and probe response packets Authenticated several access points in advance
contain: Unassociated to speedup roaming
 AP timing information, 3) Data exchg  A station can be associated with
 Beacon period, Authenticated only one AP at a given time
 AP capability information, Associated  Association state is used by the
distribution system to figure out
Station

 SSID, To DS
 PHY parameter set, Station the current location of the station
 Traffic Indication Map (TIM) Access Point 1 within the ESS.
 SSID (Service set identifier)
 identifies an ESS or IBSS

27 28

MAC Mgmt : Power Management 802.11 Frame Format


Beacon interval
TIM TIM DTIM TIM
bytes
2 2 6 6 6 2 6 0 - 2312 4
AP Frame Duration Addr 1 Addr 2 Addr 3 Seq Addr 4 Frame body CRC
control ID ctrl

802.11 MAC header (30 bytes)


Station

Listen interval
 802.11 frame has more fields than other
 A station which is synchronized with an AP clock can wake up periodically to
media type frames
listen for beacons
 30 bytes frame header appears too long!
 Beacon packets contain Traffic Indication Map (TIM), a bit vector, which
indicates whether a station has a packet buffered at AP  All fields are not present in all frames
 The station sends a PS-Poll message to the AP asking the AP to release
buffered packets for the station
 All broadcast and multicast frames are transmitted following beacons with DTIM
flag set

29 30

5
3/22/2010

Frame Control Field


bytes bits
2 2 2 4 1 1 1 1 1 1 1 1
Frame Prot Type Subtype To From More Retry Pwr More WEP Order
control Ver DS DS Frag Mgmt Data

00 01 10 11
Mgmt Control Data Reserved

Association req Power save (PS)-poll Data


Association resp Request to Send (RTS) Data + CF+ACK
Re-association req Clear to send (CTS) Data + CF-Poll
Re-association resp Acknowledgement (ACK) Data + CF-ACK + CF-Poll
Probe req Contention free (CF)-END Null
Probe resp CF-END + CF-ACK CF-ACK
Beacon CF-Poll
Announcement Traffic CF-ACK + CF-Poll
Indication Request (ATIM)
Disassociation
Authentication
De-authentication

31

Anda mungkin juga menyukai