lecture 25: 802 - cseweb.ucsd.edu€¦ · lecture 25 overview 802.11 wireless phy layer overview...
TRANSCRIPT
![Page 1: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/1.jpg)
CSE 123: Computer Networks Alex C. Snoeren
Lecture 25:802.11
HW4 due NOW
![Page 2: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/2.jpg)
Lecture 25 Overview ● 802.11 Wireless
◆ PHY layer overview
● Hidden Terminals ◆ Basic wireless challenge
● RTS/CTS ◆ Virtual carrier sense
● CSMA/CA ◆ Limits of half-duplex radios
2 CSE 123 – Lecture 25: 802.11
![Page 3: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/3.jpg)
3
IEEE 802.11 Infrastructuremobile terminal
access point
fixed terminal
application
TCP
802.11 PHY
802.11 MAC
IP
802.3 MAC
802.3 PHY
application
TCP
802.3 PHY
802.3 MAC
IP
802.11 MAC
802.11 PHY
LLC
infrastructure network
LLC LLC
CSE 123 – Lecture 25: 802.11
![Page 4: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/4.jpg)
4
802.11 Frame Format
synchronization SFD signal service HEC payload
PLCP preamble PLCP header
128 16 8 8 16 variable bits
length 16
● Synchronization ◆ synch., gain setting, energy detection, frequency offset compensation
● SFD (Start Frame Delimiter) ◆ 1111001110100000
● Signal ◆ data rate of the payload (0A: 1 Mbit/s DBPSK; 14: 2 Mbit/s DQPSK)
● Service Length ◆ future use, 00: 802.11 compliant q payload length
● HEC (Header Error Check) ◆ protection of signal, service and length, x16+x12+x5+1
CSE 123 – Lecture 25: 802.11
![Page 5: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/5.jpg)
5
WLAN: IEEE 802.11b● Data rate
◆ 1, 2, 5.5, 11 Mbit/s ◆ User data rate max. approx. 6 Mbit/s
● Transmission range ◆ 300m outdoor, 30m indoor ◆ Max. data rate ~10m indoor
● Frequency ◆ Free 2.4 GHz ISM-band
CSE 123 – Lecture 25: 802.11
![Page 6: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/6.jpg)
6
Physical Channels
US (FCC)/Canada (IC)
2400 [MHz]
2412 2483.5 2437 2462
channel 1 channel 6 channel 11
22 MHz
● 12 channels available for use in the US ◆ Each channel is 22 MHz wide ◆ Only 3 orthogonal channels ◆ Using any others causes interference
CSE 123 – Lecture 25: 802.11
![Page 7: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/7.jpg)
7
CSMA: listen before transmit: ● If channel sensed idle: transmit entire pkt ● If channel sensed busy, defer transmission
◆ Persistent CSMA: retry immediately with probability p when channel becomes idle (may cause instability)
◆ Non-persistent CSMA: retry after random interval
Carrier Sense Multiple Access
CSE 123 – Lecture 25: 802.11
![Page 8: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/8.jpg)
8
A B C
Hidden Terminal Problem
● B can communicate with both A and C ● A and C cannot hear each other ● Problem
◆ When A transmits to B, C cannot detect the transmission using the carrier sense mechanism
◆ If C transmits, collision will occur at node B ● Solution
◆ Hidden sender C needs to defer
CSE 123 – Lecture 25: 802.11
![Page 9: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/9.jpg)
9
CSMA/CA● Cannot detect collision w/half-duplex radios
● Wireless MAC protocols often use collision avoidance techniques, in conjunction with a (physical or virtual) carrier sense mechanism
● Collision avoidance ◆ Nodes negotiate to reserve the channel. ◆ Once channel becomes idle, the node waits for a
randomly chosen duration before attempting to transmit.
CSE 123 – Lecture 25: 802.11
![Page 10: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/10.jpg)
10
A B C
● When A wants to send a packet to B, A first sends a Request-to-Send (RTS) to B
● On receiving RTS, B responds by sending Clear-to-Send (CTS), provided that A is able to receive the packet
● When C overhears a CTS, it keeps quiet for the duration of the transfer ◆ Transfer duration is included in both RTS and CTS
RTS/CTS (MACA)
CSE 123 – Lecture 25: 802.11
![Page 11: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/11.jpg)
11
Backoff Interval ● Problem: With many contending nodes, RTS
packets will frequently collide ● Solution: When transmitting a packet, choose a
backoff interval in the range [0, CW] ◆ CW is contention window
● Wait the length of the interval when medium is idle ◆ Count-down is suspended if medium becomes busy ◆ Transmit when backoff interval reaches 0
● Need to adjust CW as contention varies
CSE 123 – Lecture 25: 802.11
![Page 12: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/12.jpg)
12
Non-symmetric ranges
C F A B E D DATA
Transmit “range”
Interference “range”
Carrier sense range
F A
CSE 123 – Lecture 25: 802.11
![Page 13: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/13.jpg)
13
802.11 MAC Modes● Distributed Coordination Function (DCF) CSMA/CA
◆ collision avoidance via randomized “back-off“ mechanism ◆ minimum distance between consecutive packets ◆ ACK packet for acknowledgements (not for broadcasts)
● DCF w/ RTS/CTS ◆ Distributed Foundation Wireless MAC ◆ avoids hidden terminal problem
● Point Control Fuction (PCF) - optional ◆ Access point polls terminals according to a list ◆ We’re not going to discuss…
CSE 123 – Lecture 25: 802.11
![Page 14: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/14.jpg)
14
IEEE 802.11 DCF ● DCF is CSMA/CA protocol
◆ Uses a Network Allocation Vector (NAV) to implement collision avoidance
● DCF suitable for multi-hop ad hoc networking
● Optionally uses RTS/CTS exchange to avoid hidden terminal problem ◆ Any node overhearing a CTS cannot transmit for the duration
of the transfer
● Uses ARQ to provide reliability
CSE 123 – Lecture 25: 802.11
![Page 15: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/15.jpg)
15
C F A B E D RTS
RTS = Request-to-Send
Pretending a circular range
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 16: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/16.jpg)
16
C F A B E D RTS
RTS = Request-to-Send
NAV = 10
NAV = remaining duration to keep quiet
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 17: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/17.jpg)
17
C F A B E D CTS
CTS = Clear-to-Send
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 18: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/18.jpg)
18
C F A B E D CTS
CTS = Clear-to-Send
NAV = 8
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 19: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/19.jpg)
19
C F A B E D DATA
• DATA packet follows CTS. Successful data reception acknowledged using ACK.
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 20: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/20.jpg)
20
C F A B E D ACK
Reserved area
IEEE 802.11
CSE 123 – Lecture 25: 802.11
![Page 21: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/21.jpg)
802.11 Summary
21
● Common technology for local-area wireless
● Uses CSMA/CA
● Needs to handle hidden terminal problem
● Challenges due to asymmetric ranges
CSE 123 – Lecture 25: 802.11
![Page 22: Lecture 25: 802 - cseweb.ucsd.edu€¦ · Lecture 25 Overview 802.11 Wireless PHY layer overview Hidden Terminals Basic wireless challenge RTS/CTS Virtual carrier sense CSMA/CA Limits](https://reader033.vdocument.in/reader033/viewer/2022053021/5f8d2813dcc99343f576f807/html5/thumbnails/22.jpg)
For next time… ● Finish up Project 2
● Final exam review next lecture
22 CSE 123 – Lecture 25: 802.11