Nov 24 2004 1
Chapter 5 IEEE 802.11 WLANs
http://standards.ieee.org/getieee802/802.11.html
2
WLAN architecture
Two types of topologies: single-hop ad hoc network and infrastructure network
An ad hoc network forms an independent basic service set (IBSS) and cannot communicate with the external worldAn Access Point (AP) in an infrastructure network acts as a hub and connects the basic service set (BSS) network to an extended service set (ESS) network
The architectural component used to connect two BSSs is called a distribution system
Services provided by DS: distribution, integration, association, reassociation, disassociation
3
Network topologies
Infrastructure network ad hoc network
4
Protocol stack
MAC layer and PHY layer are specified in 802.11MAC is divided into MAC and MAC ManagementPHY consists of three sublayers: PLCP (PHY layer convergence protocol), PMD (PHY medium dependent) and PHY layer management
LLC
MAC
PLCP
PMD
MACmanagement
PHYmanagement
Data linklayer
Physical layer
5
Sub-layer responsibilities
MAC: access mechanism, fragmentation, encryptionMAC layer management: roaming in ESS, power management, asso- disasso- reasso- ciation
LLC
MAC
PLCP
PMD
MACmanagement
PHYmanagement
Data linklayer
Physical layer
6
Sub-layer responsibilities
PLCP: carrier sensing assessment, forming packets for PHYsPMD: modulation and codingPHY layer management: channel tuning
LLC
MAC
PLCP
PMD
MACmanagement
PHYmanagement
Data linklayer
Physical layer
7
IEEE 802.11 PHY Layer
Two sub-layers: Physical Layer Convergence Protocol (PLCP) – adapts the MPDU to different PMD and produces Clear Channel Assessment (CCA) for carrier sensingPhysical Medium Dependent (PMD) – responsible for signaling with the medium
Several optionsFrequency Hopping Spread Spectrum (FHSS)Direct Sequence Spread Spectrum (DSSS)Diffused Infra Red (DFIR)OFDM: orthogonal frequency division multiplexing, 54Mb/sCCK: complementary code keying, 5.5Mb/s and 11Mb/s
8
Frequency Hopping Spread Spectrum (FHSS)
FHSS PHY consists of two protocol functions:A physical layer convergence function, which adapts the capabilities of the physical medium dependent (PMD) system to the PHY service: PLCPA PMD system, whose function defines the characteristics of, and method of transmitting and receiving data through a wireless medium between two and more STAs (STA: STAtion)
Three entities: PLCP sublayer: simplifies the provision of a PHY service interface to MAC servicesPhysical layer management entity (PLME): performs management of local PHY functionsPMD sublayer: provides a transmission interface
9
Frequency Hopping Spread Spectrum (FHSS)
0 1 2 3 4 5 6 7877767574
2.402 GHz – 2.480 GHz
0 1 2 3 4 5 6 2221201918
2.473 GHz – 2.495 GHz
North America
Japan
10
PLCP sublayer
This sublayer provides a convergence procedure to map MPDUs into a frame format designed for FHSS radio transceiversThe PLCP protocol data unit (PPDU) frame format provides for the asynchronous transfer of MAC sublayerMPDUs from any transmitting STA to all receiving STAswithin the wireless LAN’s BSS
The PPDU consists of three parts: preamble, header and PSDU
11
PLCP
The PLCP preamble consists of two separate parts: the preamble synchronization field and start frame delimiter (SFD), to allow the PHY circuitry to reach steady-state demodulation and synchronization of bit clock and frame start
SYNC is an 80-bit field containing an alternating 1-0 pattern, transmitted starting with 0, used by the PHY sublayer to detect a potentially received signal, reach a steady state frequency offset correction and synchronizationSFD: 0000110010111101. Used to define frame timing
12
PLCP
PLCP Header fieldPSDU length word: 12 bits, specifies the number of octets contained in the PSDU
PLCP signaling field (PSF): 3 bits, indicates the data rate
Header error check (HEC) field: 16 bits, to check the integrity of the header
13
PLCP signaling field
This field indicates the data rate of the whitened PSDU from 1 Mbit/s to 4.5 Mbit/sin 0.5 Mbit/sincrements
b1 b2 b3 =Data Rate0 0 0 =1.0 Mbit/s0 0 1 =1.5 Mbit/s0 1 0 =2.0 Mbit/s0 1 1 =2.5 Mbit/s1 0 0 =3.0 Mbit/s1 0 1 =3.5 Mbit/s1 1 0 =4.0 Mbit/s1 1 1 =4.5 Mbit/s
PLCP_BITRATE1:3
reservedDefault=0reserved0
DescriptionParameter valuesParameter nameBit
14
Operating frequency range
79 channels provided in US and Europe, the frequency for channel k is 2402+k MHzHopping rate: 2.5 hops per second
15
Hop sequencesThe hopping sequence of an individual PMD entity is used to create a pseudorandom hopping pattern. Sets of hopping sequences are used to co-locate multiple PMD entities in the same area to enhance the overall efficiencyAn FH pattern, Fx, consists of a permutation of all frequency channels. For a given number, x, the hopping sequence can be written as:
Fx={fx(1), fx(2), ….., fx(p)}where fx(i) is the channel number for ith frequency in xth
hopping patternP is the number of frequency channels in hopping pattern
fx(i)=[b(i)+x) mod (79) +2
16
Base-hopping sequence b(i)
17
Hopping pattern set
The hopping pattern numbers x are divided into three sets to avoid prolonged collision periods between different hopping sequences in a set
For 79 channel system:
For 23 channel system:
18
Direct sequence spread spectrum (DSSS) PHY
The DSSS PHY system operates in 2.4 GHz bandSupports 1Mb/s and 2Mb/s data connectionsChipping rate 11MHz with 11-chip PN code (Barker code)Modulation scheme: phase shift keying
1Mb/s, DBPSK; 2Mb/s, DQPSK
Three functional entities: PLCP sublayer, PMD sublayer and physical layer management entity (PLME)
19
DSSS PLCP sublayer
This sublayer provides a convergence procedure in which MPDUs are converted to and from PPDUs
20
PLCP frame format
SYNC field: 128 bits. For the receiver to perform necessary operations for synchronizationStart frame delimiter (SFD): 16 bits, to indicate the start of frame
21
PLCP frame format (cont’d)
PLCP signal field: 8 bits, to indicate to the PHY the modulation that shall be used for transmission of the MPDU
X’0A’: 1Mb/s, DBPSKX’14’: 2Mb/s, DQPSK
PLCP service: 8 bits, reserved
22
PLCP frame format (cont’d)
Length: 16 bits, indicates the number of microseconds required for transmitting the MPDUCRC: 16 bits, for header protection
23
DSSS PMD sublayer11-chip Barker sequence is used as the PN code sequence:
+1, -1, +1, +1, -1, +1, +1, +1, -1, -1, -1
Two modulation formats and data rates are specified for DSSS PHY: base access rate and enhanced access rate
The basic access rate is on 1 Mb/s DBPSK modulation
Enhanced access rate is for 2Mb/s DQPSK
24
Operating frequency rangeThe DSSS PHY shall operate in the frequency range of 2.4GHz to 2.4835 GHzChannel spacing: 5MHz
25
FHSS VS DSSS
FHSS is basically a narrowband system that is easier to implement and consumes less powerDSSS provides better coverage and a more robust received signalRAKE implementation of DSSS improves the performance
26
MAC servicesAsynchronous data services: this service provides peer LLC entities with the ability to exchange MAC service data units (MSDUs)
Best effort, connectionlessBroadcast and multicast transportTwo service classes: strictly ordered service and reorder-able multicast service
Security services: provided by the authentication service and the WEP mechanism
Limited to station-to-station data exchangeConfidentialityAuthenticationAccess control in conjunction with layer management
27
MAC frame format
Each frame consists of three basic components:A MAC header, which comprises frame control, duration, address, and sequence control informationA variable length frame body, which contains information specific to the frame typeA frame check sequence (FCS), which contains an IEEE 32-bit cyclic redundancy code (CRC)
Frame control
Duration /ID
Address 1 Address 2 Address 3 Sequence control
Address 4 Frame body
FCS
Octets: 2 2 6 6 6 2 6 0-2312 4
MAC Header
28
Frame control field
Protocol version field: 2 bits, current version: 0Type and subtype: used to identify the function of the frame. There are three frame types: control, data and management. Each frame type has several subtypesTo DS: set to 1 in data type frames destined for the DSFrom DS: set to 1 in data type frames exiting the DSMore Fragments: set to 1 in all data or management type frames that have another fragment of the current MSDU
Protocol Version
Subtype To DS
More Data
Order
B0 B1B2 B3B4 B7 B8 B9 B10 B11 B12 B13 B14 B15
Type From DS
More Frag
Retry PwrMgt
WEP
29
Frame control field (cont’d)
Retry: set to 1 in any data or management type frame that is a retransmission of an earlier framePower management: used to indicate the power management mode of a STA. A value of 1 indicates that the STA will be in power-save modeMore data: used to indicate a STA in power-save mode that more MSDUs, or MMSDUs are buffered for that STA in AP
Protocol Version
Subtype To DS
More Data
Order
B0 B1B2 B3B4 B7 B8 B9 B10 B11 B12 B13 B14 B15
Type From DS
More Frag
Retry PwrMgt
WEP
30
Frame control field (cont’d)
WEP: set to 1 if the frame body field contains information that has been processed by the WEP algorithmOrder: set to 1 in any data type frame that contains an MSDU which is transferred using StrictlyOrdered service class
Protocol Version
Subtype To DS
More Data
Order
B0 B1B2 B3B4 B7 B8 B9 B10 B11 B12 B13 B14 B15
Type From DS
More Frag
Retry PwrMgt
WEP
31
Other frame fieldsDuration/ID field: contains a duration value defined for each frame typeAddress fields: to indicate the BSSID, source address, destination address, transmitting station address, and receiving station addressSequence control field:
Sequence number: each MSDU or MMSDU transmitted by a STA is assigned a sequence number from 0 to 4095, incremented by 1Fragment number: indicates the number of each fragment of an MSDU or MMSDU
Fragment Number Sequence Number
B0 B3 B4 B15
32
Other frame fields
Duration/ID field: contains a duration value defined for each frame typeAddress fields: to indicate the BSSID, source address, destination address, transmitting station address, and receiving station address
Frame control
Duration /ID
Address 1 Address 2 Address 3 Sequence control
Address 4 Frame body
FCS
Octets: 2 2 6 6 6 2 6 0-2312 4
MAC Header
33
Other frame fields (cont’d)
Sequence control field:Sequence number: each MSDU or MMSDU transmitted by a STA is assigned a sequence number from 0 to 4095, incremented by 1Fragment number: indicating the number of each fragment of an MSDU or MMSDU
Frame control
Duration /ID
Address 1 Address 2 Address 3 Sequence control
Address 4 Frame body
FCS
Octets: 2 2 6 6 6 2 6 0-2312 4
MAC Header
Fragment Number Sequence Number
B0 B3 B4 B15
34
Format for individual frame types
Request to send (RTS) frame:
Clear to send (CTS) frame:
Acknowledgement (ACK) frame:
Frame control
Duration RA TA FCS
Octets: 2 2 6 6 4
Frame control
Duration RA FCS
Octets: 2 2 6 4
Frame control
Duration RA FCS
Octets: 2 2 6 4
35
Data frame format
Frame control
Duration /ID
Address 1 Address 2 Address 3 Sequence control
Address 4 Frame body
FCS
Octets: 2 2 6 6 6 2 6 0-2312 4
MAC Header
36
MAC architecture
Includes the distributed coordination function (DCF), and the point coordination function (PCF)
PointCoordination
Function(PCF)
DistributedCoordination Function
(DCF)
Used for ContentionServices and basis for PCF
Required for ContentionFree Services
MACExtent
37
Distributed coordination function (DCF)Carrier sense multiple access with collision avoidance (CSMA/CA)
Implemented in all STAsFor an STA to transmit, it shall sense the medium to determine if another STA is transmittingA gap of a minimum specified duration exist between contiguous frame sequencesIf the medium is busy, the STA shall select a random backoff delayA refinement uses short control frames (RTS and CTS)
38
Point coordination function (PCF)
Only usable for infrastructure network configurationsA point coordinator (PC), operating at the access point, determines which STA currently has the right to transmit
Polling
Virtual carrier sense mechanism: setting network allocation vector (NAV)Contention-free (CF) access
39
Fragmentation/defragmentation
Fragmentation is used for increasing reliabilityEach fragment can be transmitted independently
Defragmentation is performed at the receiver
40
DCF
DCF allows for automatic medium sharing between compatible PHYs through the use of CSMA/CA and a random backoff time
CSMA/CA is designed to reduce collisionsCarrier sense can be performed both through physical and virtual mechanismsVirtual carrier-sense is achieved by distributing reservation information announcing the impending use of the medium
Exchange of RTS/CTSFast collision inference and a transmission path checkHidden terminal problem solvedRTS/CTS cannot be used with broadcast and multicast addresses
41
Carrier-sense mechanismTwo carrier-sense mechanisms adopted: virtual and physical
Either one indicates the medium is busy, it should be considered busy
A physical carrier-sense mechanism is provided by PHYVirtual carrier-sense mechanism is provided by network allocation vector (NAV)
NAV maintains a prediction of future traffic on the medium based on duration information announced
Carrier-sense mechanism combines the NAV state and the STA’s transmitter status with physical carrier-sense to determine the medium state
42
Interframe space (IFS)
Four IFSs:SIFS: short interframe spacePIFS: PCF interframe spaceDIFS: DCF interframe spaceEIFS: extended interframe space
43
Interframe space (IFS) (cont’d)
SIFS: used for an ACK frame, a CTS frame, the second or subsequent MPDU of a fragment burst, and by an STA responding to any polling by the PCF
SIFS is used when STAs have seized the medium and need to keep it for the duration of the frame exchange sequence to be performedPriority is given for completion of the frame exchange sequence in progress
44
Interframe space (IFS) (cont’d)
PIFS: used only by STAs under the PCF to gain access to the medium during CFP (Contention-Free Period)
DIFS: used by STAs operating under the DCF to transmit data frames and management frames
EIFS: used by the DCF whenever the PHY has indicated to the MAC that a frame transmission was begun that did not result in correct reception of a complete MAC frame with a correct FCS value
45
Random backoff time
When an STA desiring to initiate transfer of data MPDU and/or management MMPDUs senses the medium busy, it shall defer until the medium is idle. Then after waiting for another period of time equal to DIFS or EIFS, the STA shall generate a random backoff period for an additional deferral before transmitting
Backoff time = Random()*aSlotTimeRandom() ∈[0, CW] where CW is the contention window. CWmin ≤ CW ≤ CWmax. Initial value of CW = CWminCW should be reset to CWmin after every successful attempt to transmit an MSDU or MMPDUWith an unsuccessful attempt, CW should be sequentially ascending integer powers of 2, minus 1
46
An example of exponential increase of CW
47
DCF basic access procedure
If medium is idle, and is still idle after a DIFS, transmit
If medium is busy, defer until this transmission is complete, wait for another DIFS or EIFS. Then delay a random backoff time, then transmit
For FH PHY, if the dwell time is not enough for transmitting the MPDU and ACK (if required), the STA shall defer the transmission by selecting a random backoff time
48
Backoff procedure
When an STA senses the medium busy, random backoff procedure is invokedAn STA performing the backoff procedure should use the carrier-sense mechanism to determine whether there is activity during each backoff time slot. If no, decrement the backoff timerOtherwise, backoff procedure suspended
49
Setting and resetting NAV
STAs receiving a valid frame shall update their NAVs with the information received in the Duration/ID field, but only when the new NAV value is greater than the current NAV value.
50
Control of the channel
SIFS is used to provide an efficient MSDU delivery mechanism. Once the STA has contended for the channel, that STA shall continue to send fragments until all fragments have been sentAn STA shall transmit after the SIFS only when:
The STA has just received a fragment that requires ACKThe source STA has received an ACK for the previous fragment and has more fragment(s) to send
ACK 0 ACK 1 ACK 2
SIFSSIFS SIFS SIFS SIFS
Source
Destination
Fragment 0 Fragment 2Fragment 1
Fragment burst
51
RTS/CTS usage with fragmentation
The RTS/CTS frames define the duration of the following frame and ACKThe duration/ID field in the data and ACK frames specifies the total duration of the next fragment and ACK
CTS ACK 0 ACK 1 ACK 2
Frag. 0 Frag. 1 Frag. 2
NAV(RTS)
NAV(CTS)
NAV(Fragment 1)NAV(Fragment 0)
NAV(ACK 0) NAV(ACK 1)
RTSSIFS SIFS SIFS SIFS SIFS SIFS SIFS
Other
Source
Destination
52
PCF
Contention-free frame transferOnly for infrastructure networkCF-pollable STA can transmit MPDU after being polledCF-pollable STA should not retransmit until polledNon-CF-pollable STA only reply ACK after receiving MPDUData frames sent:
PC: data+CF-poll, data+CF-Ack+CF-poll, CF-poll, CF-Ack+CF-PollPC or CF-pollable STA: data, data+CF-Ack, null function, CF-Ack
53
CFP structure and timing CFP alternates with CPCFP begins with a beacon that contains a DTIM elementCFPs occur at a predefined repetition rateLength of the CFP is controlled by the PC
PC ends a CFP by sending CF-End or CF-End+Ack
NAV
Busymedium
PCFBPCFB
Contention PeriodDCF
CF Period
CFP repetition interval
CF Period
Foreshortened CFP
Delay (due to busy medium)
Variable length(per superframe)
CPDCF
54
PCF access procedure
Based on pollingPC maintains control for the entire CFP by waiting a shorter time between transmissions than the STAs using DCFNAV is set to prevent most contentionsAt the beginning of each CFP, the PC senses the medium
When the medium is idle for one PIFS period, beacon is sent to announce the beginning of CFPAfter the initial beacon frame, the PC waits for at least one SIFS period, then transmits one frame
No traffic and poll to send, a CF-End should be sent
55
NAV operation during the CFPEach STA, except the STA with PC, shall preset its NAV to the CFPMaxDuration value at each target beacon transmission time at which a CFP is scheduled to start
Each non-PC STA shall update its NAV using the CFPDurRemaining value in each beacon frame the STA receives
Prevents STAs from taking control of the medium during the CFP
The PC shall transmit CF-End or CF-End+Ack at the end of each CFP. An STA receiving CF-End should reset its NAV
DTIM DTIM DTIM
Beacons
CFP CFPCP
CFP_Dur_RemainingValue in beacon
56
PCF transfer procedureFrame transfers under PCF typically consist of frames alternately sent from and to the AP/PC
In an STA having an FH PHY, channel control is lost at a dwell time boundary. It is required that the current MPDU transmission and the accompanying Ack be transmitted before the dwell time boundary
NAV
CF_Max_Duration
Beacon D1+poll
U1+ack
D2+ack+poll
U2+ack
D3+ack+poll
D4+poll
U4+ack
CF-End
Reset NAV
No response To CF-Poll
Contention-free Period
Contention-free Repetition Interval
ContentionPeriod
PIFS SIFS SIFS SIFS SIFS SIFS
PIFS SIFS SIFS