• Example CSMA/CD – Carrier Sense Multiple Access with Collision Detection – send as soon as the medium is free, listen into the medium if a collision occurs original method in IEEE 802.
Trang 1ACN2016 1
Wireless LANs
Trang 3AP wired network
AP: Access Point
Source: Schiller
Trang 4ACN2016 4
Wireless LANs are different…
• Destination address does not equal destination location
• The media impact the design
– wireless LANs intended to cover reasonable geographic distances must be built from basic coverage blocks
• Impact of handling mobile (portable) stations
– Propagation effects
– Mobility management
– power management
Trang 6ACN2016 6
Wireless PHY
– Medium has neither absolute nor readily
observable boundaries outside which stations are unable to receive frames
– Are unprotected from outside signals and are
significantly less reliable than wired PHYs
– Have time varying and asymmetric propagation properties
– Lack full connectivity
• the assumption that every station (STA) can hear every other STA in invalid
Trang 7ACN2016 7
Wireless MAC: Motivation
• Can we apply media access methods from fixed
networks?
• Example CSMA/CD
– Carrier Sense Multiple Access with Collision Detection
– send as soon as the medium is free, listen into the
medium if a collision occurs (original method in IEEE 802.3)
Trang 8ACN2016 8
Wireless MAC
– signal strength decreases inversely proportional to the square of the distance
– sender would apply CS and CD, but the collisions
happen at the receiver
– sender may not “hear” the collision, i.e., CD does not work
– CS might not work, e.g if a terminal is “hidden”
Trang 9ACN2016 9
– A and C cannot hear each other
– A sends to B, C cannot receive A
– C wants to send to B, C senses a “free” medium
Trang 11ACN2016 11
Solution for Hidden Terminals
• A first sends a Request-to-Send (RTS) to B
• On receiving RTS , B responds Clear-to-Send (CTS)
• Hidden node C overhears CTS and keeps quiet
– Transfer duration is included in both RTS and CTS
• Exposed node overhears a RTS but not the CTS
– D’s transmission cannot interfere at B
RTS
DATA D
RTS
Trang 12ACN2016 12
IEEE 802.11
• Wireless LAN standard defined in the unlicensed spectrum (2.4 GHz and 5 GHz U-NII bands)
Trang 13ACN2016 13
802.11 (contd.)
• Standards covers the MAC sublayer and PHY layers
• Three different physical layers in the 2.4 GHz band
– FHSS, DSSS and IR
• OFDM based PHY layer in the 5 GHz band
Trang 16– Basic Service Set (BSS):
group of stations using the same radio frequency
Trang 17ESS
Trang 18ACN2016 18
PCF components
wireless medium and radio contact to the access point
radio frequency
the distribution system
logical network (ESS: Extended Service Set) based
on several BSS
Trang 19ACN2016 19
Distribution System (DS) concepts
• The Distribution system interconnects multiple BSSs
• 802.11 standard logically separates the wireless medium from the distribution system – it does not preclude, nor demand, that the multiple
media be same or different
Trang 20ACN2016 20
DS (contd.)
• An Access Point (AP) is a STA that provides access
to the DS by providing DS services in addition to
acting as a STA
• Data moves between BSS and the DS via an AP
• The DS and BSSs allow 802.11 to create a wireless network of arbitrary size and complexity called the Extended Service Set network (ESS)
Trang 21application TCP
802.3 PHY 802.3 MAC
IP
802.11 MAC 802.11 PHY
LLC
infrastructure network
Trang 22ACN2016 22
802.11 - Layers and functions
• PLCP Physical Layer Convergence Protocol
– clear channel assessment signal (carrier sense)
• PMD Physical Medium Dependent
PMD PLCP MAC
Trang 23ACN2016 23
802.11 - Physical layer
• 3 versions: 2 radio (typically 2.4 GHz), 1 IR
– data rates 1, 2, 5.5, or 11 Mbit/s
• Infrared
– 850-950 nm, diffuse light, typ 10 m range
– carrier detection, energy detection, synchonization
• FHSS (Frequency Hopping Spread Spectrum)
– spreading, despreading, signal strength
– typically 1 Mbit/s (mandatory), 2Mbits/s (optional)– min 2.5 frequency hops/s (USA), two-level GFSK (Gaussian FSK) modulation
Trang 24ACN2016 24
802.11 DSSS
• DSSS (Direct Sequence Spread Spectrum)
– DBPSK modulation for 1 Mbit/s (Differential Binary Phase Shift Keying),
– DQPSK (differential quadrature PSK) for 2 Mbit/s, CCK
(complementary code keying) for 5.5 and 11 Mbits/s
– preamble and header of a frame is always transmitted with 1 Mbit/s
– chipping sequence: +1, -1, +1, +1, -1, +1, +1, +1, -1, -1, -1 (Barker code) (11 chip)
– max radiated power 1 W (USA), 100 mW (EU)
– min 1mW
Trang 25ACN2016 25
Spread-spectrum communications
Source: Intersil
Trang 26ACN2016 26
DSSS Barker Code modulation
Source: Intersil
Trang 27ACN2016 27
802.11 - MAC layer
• Traffic services
– Asynchronous Data Service (mandatory) – DCF
– Time-Bounded Service (optional) - PCF
Trang 29ACN2016 29
802.11 - Carrier Sensing
• In IEEE 802.11, carrier sensing is performed
– at the air interface (physical carrier sensing), and – at the MAC layer (virtual carrier sensing)
• Physical carrier sensing
– detects presence of other users by analyzing all detected packets
– Detects activity in the channel via relative signal strength from other sources
Trang 30ACN2016 30
802.11 virtual carrier sensing
• Virtual carrier sensing is done by sending MPDU duration
information in the header of RTS/CTS and data frames
• Channel is busy if either mechanisms indicate it to be
– Duration field indicates the amount of time (in microseconds) required to complete frame transmission
– Stations in the BSS use the information in the duration field
to adjust their network allocation vector (NAV)
Trang 31ACN2016 31
802.11 – Reliability: ACKs
– When B receives DATA from A, B sends an ACK
– If A fails to receive an ACK, A retransmits the DATA
– Both C and D remain quiet until ACK (to prevent
Trang 32ACN2016 32
802.11 - CSMA/CA
– station ready to send starts sensing the medium
(Carrier Sense based on CCA, Clear Channel
DIFS DIFS
next frame
contention window (randomized back-off mechanism)
slot time direct access if
medium is free DIFS
Trang 33ACN2016 33
802.11 – CSMA/CA
– if the medium is busy, the station has to wait for a free IFS, then the station must additionally wait a random back-off time (collision avoidance, multiple of slot-
time)
– if another station occupies the medium during the
back-off time of the station, the back-off timer stops (fairness)
Trang 34ACN2016 34
802.11 –CSMA/CA example
t busy
elapsed backoff time
bor residual backoff time busy medium not idle (frame, ack etc.)
Trang 35– When transmitting a packet, choose a backoff interval
in the range [0,cw]; cw is contention window
– Count down the backoff interval when medium is idle– Count-down is suspended if medium becomes busy
– When backoff interval reaches 0, transmit RTS
Trang 36B1 and B2 are backoff intervals
at nodes 1 and 2
cw = 31
B2 = 10
Trang 37ACN2016 37
802.11 - Congestion Control
• Contention window ( cw ) in DCF: Congestion control achieved by dynamically choosing cw
• large cw leads to larger backoff intervals
• small cw leads to larger number of collisions
Trang 38ACN2016 38
Congestion control (contd.)
• Binary Exponential Backoff in DCF:
– When a node fails to receive CTS in response to its
RTS, it increases the contention window
– Upon successful completion data transfer, restore cw
to CWmin
Trang 39ACN2016 39
802.11 - Priorities
• defined through different inter frame spaces – mandatory idle time intervals between the transmission of frames
• SIFS (Short Inter Frame Spacing)
– highest priority, for ACK, CTS, polling response
– SIFSTime and SlotTime are fixed per PHY layer – (10 s and 20 s respectively in DSSS)
Trang 40– lowest priority, for asynchronous data service
– DCF-IFS (DIFS): DIFSTime = SIFSTime +
2xSlotTime
Trang 41ACN2016 41
802.11 - CSMA/CA II
• station has to wait for DIFS before sending data
• receivers acknowledge at once (after waiting for SIFS) if the packet was received correctly (CRC)
• automatic retransmission of data packets in case of transmission errors
t
SIFS DIFS
data ACK
Trang 42ACN2016 42
802.11 –RTS/CTS
t
SIFS DIFS
data ACK
NAV (RTS)
NAV (CTS)
Trang 43• acknowledgement via CTS after SIFS by receiver (if ready to receive)
• sender can now send data at once, acknowledgement via ACK
• other stations store medium reservations (NAV) distributed via RTS and CTS
Trang 44ACN2016 44
Fragmentation
t
SIFS DIFS
SIFS
Trang 45ACN2016 45
802.11 - Point Coordination Function
Trang 46SIFS
D2
U2SIFS
Trang 47CFend
contention period contention free period
t2 t3 t4
t2 = time when CFP actually finished t3 = initial planned CFP (but PCF finished polling earlier than expected)
Trang 48ACN2016 48
CFP structure and Timing
CFP is greater than beacon interval DTIM – Delivery Traffic Indication Message
Source: 802.11 spec
Trang 49ACN2016 49
CFP
• Then length of CFP is controlled by PC
– CFPMaxDuration field is used for this
• When CFP is more than beacon interval
– CFP_Dur_Remaining is included in beacons
– CFP_Dur_Remaining is set to 0 for beacons in CP
Trang 50ACN2016 50
PCF- Data transmission
Source: 802.11 standard
Trang 52– CF-End is used to signal the end of the CFP
• CFPs are generated at the CFP repetition rate and each CFP begins with a beacon frame
Trang 53• Superframe: One CFP + One CP It repeats
according to the CFP repetition rate and each CFP begins with a beacon frame
Trang 54Address 1
Address 2
Address 3
Sequence Control
Trang 56ACN2016 56
Frame Control Field
Trang 57– Association Request– Association Response– Dis/Reassociation
– Authentication
– Deauthentication
– ATIM (Announcement
TIM)
Trang 58ACN2016 58
MAC address format
scenario to DS from
DS address 1 address 2 address 3 address 4
AP: Access Point
DA: Destination Address
SA: Source Address
BSSID: Basic Service Set Identifier
RA: Receiver Address
TA: Transmitter Address
Trang 59– scanning, i.e active search for a network
– roaming, i.e change networks by changing APs
• MIB - Management Information Base
– managing, read, write
Trang 60ACN2016 60
Synchronization using a Beacon (infrastructure)
• Synchronized clocks are needed for PCF, Power
saving and for frequency hopping
• Within a BSS timing is conveyed by a periodic
beacon
• STAs use the timestamp in beacon to adjust its
internal local clock
• AP always tries to send beacon at scheduled period (even if the prev beacon was delayed)
Trang 61ACN2016 61
Synchronization using a Beacon (infrastructure)
beacon interval
t medium
Trang 62ACN2016 62
Synchronization using a
Beacon (ad-hoc)
• Synchronization in ad hoc mode is more difficult,
since there is no AP for beacon transmission
• Each STA maintains its synchronization timer and
starts transmission of a beacon periodically
• Standard random back off is applied to beacon
frames so that only one STA wins transmitting beacon
Trang 63ACN2016 63
Synchronization using a
Beacon (ad-hoc)
t medium
station1
busy
B1beacon interval
B1
value of the timestamp B beacon frame
random delay
Trang 64ACN2016 64
Power saving in 802.11
• Basic idea is to switch off transceiver when there is
no communication
• Easy for sender since they know when to send data
• Receivers should wakeup periodically to check if it has to receive anything
Trang 67• All stations announce a list of buffered frames during
a period when all of them are awake
– Destinations are announced using ATIM (Adhoc TIM)
Trang 68a acknowledge ATIM d acknowledge data
Trang 69• Station then selects the best AP (e.g based on signal strength)
– sends association Request to the AP
• association Response
– success: AP has answered, station is now associated with the new AP
– failure: continue scanning
Trang 70ACN2016 70
Roaming (contd.)
• AP accepts Association Request
– signal the new station to the distribution system
– the distribution system updates its data base (i.e., location information)
– typically, the distribution system now informs the old
AP so it can release resources
Trang 73ACN2016 73
IEEE 802.11 Summary
• Infrastructure (PCF) and adhoc (DCF) modes
• Signaling packets for collision avoidance
– Medium is reserved for the duration of the
transmission
• Acknowledgements for reliability
• Binary exponential backoff for congestion control
• Power save mode for energy conservation
Trang 74ACN2016 74
HIPERLAN
• Wireless LAN ratified by ETSI
• HIPERLAN1
– First of the series of spec
– Supports five different priorities
– Data rate of 23.5 Mbps
– Forwards packets using several relays
• Extends communication beyond the radio range
– Power conservation by specific sleep and wakeup pattern – MSDU lifetime can be set to have time bound services
– MAC layer uses residual lifetime and user priority to choose the next MSDU to be transmitted
Trang 75– Negotiation of QoS parameter during connection establishment
• Dynamic frequency selection
– Best frequency chosen based on interference level and usage of radio channels
• Power save
– Mobile devices can negotiate certain sleep and wakeup pattern for power save
• Access Points can have multiple transceivers
• APs can have sectorized antenna
Trang 76– This is the optional ad hoc mode of HiperLAN2
– Data is directly exchanged between MS
• But the network is still controlled
• Done via an AP that has the central controller (CC) functionality
or via an MS that has CC functionality
• This ensures QoS support in ad hoc mode also
Trang 77Centralized mode
AP/CC
data control
Direct mode
Different modes of operation of HiperLAN2
Trang 78ACN2016 78
Bluetooth
• Design goal was to set up short range ad hoc
network (called piconets)
• 79 channels in the 2.4 GHz band with 1 MHz carrier spacing
• Devices perform frequency hopping at 1600 hops/s
• Maximum data rate of 1Mbps
• Range of about 10m
Trang 80– One of the devices is the master, all others are slaves
– Master determines the hopping pattern in the piconet and the slaves have to synchronize to this pattern
– Each piconet has a unique hopping pattern
Trang 81• Upto 8 devices can be active in a piconet
– Parked devices use 8-bit parked member address (PMA)
– Standby devices do not need address
Trang 82ACN2016 82
Bluetooth
• Scatternet
– Only having 1 piconet within 80 MHz in total is not very efficient
– Many piconets with overlapping coverage can exist simulatenously
• A device may participate in two different piconets
– Bluetooth uses FH-CDMA for separation of piconet
– A slave first syncs to one piconet and communicates, then leaves that piconet and enters the other piconet (of scatternet) by syncing to its FH sequence – A master cannot be shared between two piconets of a scatternet
– Master can leave one piconet and enter the other as a slave
• All traffic in the former piconet is suspended until the master returns