Lecture 4 Wireless Medium Access Control

Slides:



Advertisements
Similar presentations
Nick Feamster CS 4251 Computer Networking II Spring 2008
Advertisements

IEEE CSMA/CA DCF CSE 6590 Fall /7/20141.
Ethernet, Wireless LAN. Ethernet Frame Format (a) DIX Ethernet, (b) IEEE
Contents IEEE MAC layer operation Basic CSMA/CA operation
EECC694 - Shaaban #1 lec #5 Spring Data Link In Broadcast Networks: The Media Access Sublayer Broadcast networks with multi-access (or random.
Lecture 5: IEEE Wireless LANs (Cont.). Mobile Communication Technology according to IEEE (examples) Local wireless networks WLAN a.
– Wireless PHY and MAC Stallings Types of Infrared FHSS (frequency hopping spread spectrum) DSSS (direct sequence.
© Kemal AkkayaWireless & Network Security 1 Department of Computer Science Southern Illinois University Carbondale CS591 – Wireless & Network Security.
Comp 361, Spring 20056:Basic Wireless 1 Chapter 6: Basic Wireless (last updated 02/05/05) r A quick intro to CDMA r Basic
Module C- Part 1 WLAN Performance Aspects
Network Technology CSE Network Technology CSE3020 Week 9.
1 Pertemuan 13 Teknik Akses Jaringan - Random Matakuliah: H0174/Jaringan Komputer Tahun: 2006 Versi: 1/0.
Copyright © 2003, Dr. Dharma P. Agrawal and Dr. Qing-An Zeng. All rights reserved. 1 Chapter 6 Multiple Radio Access.
20 – Collision Avoidance, : Wireless and Mobile Networks6-1.
6: Wireless and Mobile Networks6-1 Chapter 6: Wireless and Mobile Networks Background: r # wireless (mobile) phone subscribers now exceeds # wired phone.
1 Elements of a wireless network network infrastructure wireless hosts r laptop, PDA, IP phone r run applications r may be stationary (non- mobile) or.
5: DataLink Layer5-1 Chapter 5 Link Layer and LANs Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross.
5-1 Data Link Layer r Wireless Networks m Wi-Fi (Wireless LAN) Example Problems m RTS/CTS.
5-1 Data Link Layer r What is Data Link Layer? r Wireless Networks m Wi-Fi (Wireless LAN) r Comparison with Ethernet.
Semester EEE449 Computer Networks The Data Link Layer Part 2: Media Access Control En. Mohd Nazri Mahmud MPhil (Cambridge, UK) BEng (Essex,
8/7/20151 Mobile Computing COE 446 Wireless Multiple Access Tarek Sheltami KFUPM CCSE COE hthttp://faculty.kfupm.edu.sa/coe/tarek/coe446.htm Principles.
Medium Access Control Sublayer
6: Wireless and Mobile Networks6-1 Elements of a wireless network network infrastructure wireless hosts r laptop, PDA, IP phone r run applications r may.
Wi-Fi Wireless LANs Dr. Adil Yousif. What is a Wireless LAN  A wireless local area network(LAN) is a flexible data communications system implemented.
Opersating Mode DCF: distributed coordination function
MAC layer Taekyoung Kwon. Media access in wireless - start with IEEE In wired link, –Carrier Sense Multiple Access with Collision Detection –send.
IEEE Project started by IEEE for setting standard for LAN. This project started in (1980, February), Name given to project is year and month.
Wireless Medium Access. Multi-transmitter Interference Problem  Similar to multi-path or noise  Two transmitting stations will constructively/destructively.
1 Computer Communication & Networks Lecture 12 Datalink Layer: Multiple Access Waleed Ejaz
Ethernet. Problem In an Ethernet, suppose there are three stations very close to each other, A, B and C. Suppose at time 0, all of them have a frame to.
4-1 Last time □ Link layer overview ♦ Services ♦ Adapters □ Error detection and correction ♦ Parity check ♦ Internet checksum ♦ CRC □ PPP ♦ Byte stuffing.
Computer and Data Communications Semester Mohd Nazri Mahmud Session 4a-12 March 2012.
Medium Access Control NWEN302 Computer Network Design.
IEEE Wireless LAN Standard. Medium Access Control-CSMA/CA IEEE defines two MAC sublayers Distributed coordination function (DCF) Point coordination.
Wireless and Mobility The term wireless is normally used to refer to any type of electrical or electronic operation which is accomplished without the use.
4: DataLink Layer1 Multiple Access Links and Protocols Three types of “links”: r point-to-point (single wire, e.g. PPP, SLIP) r broadcast (shared wire.
Medium Access Control Sub Layer
Chapter 6 Multiple Radio Access
5: DataLink Layer 5a-1 Multiple Access protocol. 5: DataLink Layer 5a-2 Multiple Access Links and Protocols Three types of “links”: r point-to-point (single.
Data Link Layer. Useful References r Wireless Communications and Networks by William Stallings r Computer Networks (third edition) by Andrew Tanenbaum.
Ch 12. Multiple Access. Multiple Access for Shared Link Dedicated link – Point-to-point connection is sufficient Shared link – Link is not dedicated –
Background of Ad hoc Wireless Networks Student Presentations Wireless Communication Technology and Research Ad hoc Routing and Mobile IP and Mobility Wireless.
Wi-Fi. Basic structure: – Stations plus an access point – Stations talk to the access point, then to outside – Access point talks to stations – Stations.
Universität Karlsruhe Institut für Telematik ECE 591
Lecture 27 University of Nevada – Reno Computer Science & Engineering Department Fall 2015 CPE 400 / 600 Computer Communication Networks Prof. Shamik Sengupta.
MAC Sublayer MAC layer tasks: – Control medium access – Roaming, authentication, power conservation Traffic services – DCF (Distributed Coordination.
Medium Access Control in Wireless networks
Wireless Protocols. 2 Outline MACA 3 ISM: Industry, Science, Medicine unlicensed frequency spectrum: 900Mhz, 2.4Ghz, 5.1Ghz, 5.7Ghz.
EE 122: Lecture 6 Ion Stoica September 13, 2001 (* this talk is based in part on the on-line slides of J. Kurose & K. Rose)
MAC Layer Protocols for Wireless Networks. What is MAC? MAC stands for Media Access Control. A MAC layer protocol is the protocol that controls access.
Network and Systems Laboratory nslab.ee.ntu.edu.tw Copyright © Wireless Sensor Networks: Zigbee Stack Polly Huang Department of Electrical.
1 Chapter 4 MAC Layer – Wireless LAN Jonathan C.L. Liu, Ph.D. Department of Computer, Information Science and Engineering (CISE), University of Florida.
CSMA/CA Simulation  Course Name: Networking Level(UG/PG): UG  Author(s) : Amitendu Panja, Veedhi Desai  Mentor: Aruna Adil *The contents in this ppt.
Distributed-Queue Access for Wireless Ad Hoc Networks Authors: V. Baiamonte, C. Casetti, C.-F. Chiasserini Dipartimento di Elettronica, Politecnico di.
DSSS PHY packet format Synchronization SFD (Start Frame Delimiter)
IEEE Wireless LAN. Wireless LANs: Characteristics Types –Infrastructure based –Ad-hoc Advantages –Flexible deployment –Minimal wiring difficulties.
5: DataLink Layer5-1 Slotted ALOHA Assumptions r all frames same size r time is divided into equal size slots, time to transmit 1 frame r nodes start to.
Wireless MAC.
EA C451 (Internetworking Technologies)
Medium Access Control MAC protocols: design goals, challenges,
Mobile and Ad hoc Networks
Services of DLL Framing Link access Reliable delivery
Multiple access.
CS 457 – Lecture 7 Wireless Networks
Overview Jaringan Komputer (3)
Link Layer and LANs Not everyone is meant to make a difference. But for me, the choice to lead an ordinary life is no longer an option 5: DataLink Layer.
MAC continued.
Link Layer: Multiple Access
Chapter 6 Multiple Radio Access.
Dr. John P. Abraham Professor UTPA
Presentation transcript:

Lecture 4 Wireless Medium Access Control http://jjcweb.jjay.cuny.edu/ssengupta/ Lecture 4 Wireless Medium Access Control Prof. Shamik Sengupta Office 4210 N ssengupta@jjay.cuny.edu http://jjcweb.jjay.cuny.edu/ssengupta/ Fall 2010 Lecture 1

Medium Access Control (MAC) Base Station Forward link Reverse link Mobile Station Mobile Station Mobile Station Mobile Station

Earlier MAC Protocols: A quick overview Channel Partitioning: TDMA, FDMA divide channel into “pieces” (time slots, frequency) allocate piece to node for exclusive use C B A Time f Frequency A B C Frequency Time f 2 1 Channel Partitioning: adv., disadv. Share channel efficiently at high load inefficient at low load: delay in channel access, 1/N bandwidth allocated even if only 1 active node!

Earlier MAC Protocols: A quick overview Packet Radio (PR) Access Technique: Users attempt to access a single channel in an uncoordinated or random manner Random Access: Aloha, Slotted Aloha allow collisions “recover” from collisions Random access MAC protocols efficient at low load: single node can fully utilize channel high load: collision overhead

Pure (unslotted) ALOHA Devised by Norman Abramson and his colleagues University of Hawaii Simple, no synchronization when frame first arrives transmit immediately collision probability increases: frame sent at t0 collides with other frames sent in [t0-1,t0+1]

Pure Aloha efficiency What is the efficiency?

Slotted ALOHA Assumptions: all frames same size time divided into equal size slots (time to transmit 1 frame) nodes start to transmit only slot beginning nodes are synchronized if 2 or more nodes transmit in slot, all nodes detect collision Operation: when node obtains fresh frame, transmits in next slot if no collision: node can send new frame in next slot if collision: node retransmits frame in each subsequent slot with prob. p until success

Slotted ALOHA Pros single active node can continuously transmit at full rate of channel highly decentralized: only slots in nodes need to be in sync simple Cons collisions, wasting slots idle slots nodes may be able to detect collision in less than time to transmit packet clock synchronization

Slotted Aloha efficiency At best: channel used for useful transmissions 37% of time! ! 5: DataLink Layer

Why Aloha protocols were disadvantageous? Aloha protocols do not listen to the channel before transmission Do not exploit info about other users Listening to the channel if any user is transmitting is key to the efficient wireless access This was the basic of CSMA protocols Carrier Sense Multiple Access Protocol

Carrier Sense Multiple Access (CSMA) Protocol Two imp parameters in CSMA Detection delay Propagation delay A function of the receiver hardware Time reqd for a terminal to sense whether or not the channel is idle Relative measure of how fast a packet travels from one station to another station (BS or AP) Systems must be built taking this parameter significantly in account High propagation delay impact efficiency E.g., two extreme transmitting users may get into collision again and again due to high propagation delay

Variations of CSMA 1-persistent CSMA p-persistent CSMA CSMA/CD Listens to the channel, if idle transmit p-persistent CSMA Listens to the channel, if idle, transmit with prob p in the first slot or (1-p) in the next slot CSMA/CD Further improvement over earlier CSMA Not only listens to channel before transmissions but also during transmissions If collision is detected, transmissions are aborted immediately Saves valuable resources from wastage Combines “listen before talk” and “listen while talk” Happens in Ethernet (because of full-duplex radios)

CSMA in wireless The concept of CSMA/CD is interesting How about applying it in wireless medium access control? Problems in wireless networks signal strength decreases proportional to the square of the distance the sender would apply CS and CD, but the collisions happen at the receiver a sender cannot “hear” the collision at the same time of transmission, because transmission power suppresses receiving power i.e., CD does not work furthermore, CS might not work if, e.g., a terminal is “hidden” Wireless MAC use variants of CSMA CSMA/CA (collision avoidance protocol) Does not make collision zero, just tries to reduce it Very popular in IEEE 802.11 (WLAN)

infrastructure network IEEE802.11 infrastructure network ad-hoc network AP wired network AP: Access Point

802.11 infrastructure mode Station (STA) Basic Service Set (BSS) terminal with access mechanisms to the wireless medium and radio contact to the access point Basic Service Set (BSS) group of stations using the same radio frequency Access Point station integrated into the wireless LAN and the distribution system Portal bridge to other (wired) networks Distribution System interconnection network to form one logical network (ESS: Extended Service Set) based on several BSS Distribution System Portal 802.x LAN Access Point 802.11 LAN BSS2 BSS1 STA1 STA2 STA3 ESS 9

802.11: ad-hoc mode Direct communication within a limited range Station (STA): terminal with access mechanisms to the wireless medium Basic Service Set (BSS): group of stations in range and using the same radio frequency 802.11 LAN STA1 BSS1 STA3 STA2 BSS2 STA5 STA4 802.11 LAN

infrastructure network IEEE standard 802.11 mobile terminal access point server fixed terminal application TCP 802.11 PHY 802.11 MAC IP 802.3 MAC 802.3 PHY LLC infrastructure network

How does the medium access work in WLAN? Access methods DCF CSMA/CA (mandatory) collision avoidance via exponential backoff Minimum distance (IFS) between consecutive packets ACK packet for acknowledgements (not for broadcasts) DCF with RTS/CTS (optional) Distributed Foundation Wireless MAC avoids hidden terminal problem PCF (optional) access point polls terminals according to a list Contention Based Contention Free Distributed Coordination Function (DCF) Point Coordination Function (PCF)

direct access if medium is free  DIFS 802.11 – MAC Priorities defined through different inter frame spaces SIFS (Short Inter Frame Spacing) highest priority, for ACK, CTS, polling response PIFS (PCF IFS) medium priority, for time-bounded service using PCF DIFS (DCF, Distributed Coordination Function IFS) lowest priority, for asynchronous data service, competing stations aSIFSTime = aRxRFDelay + aRxPLCPDelay + aMACProcessingDelay + aRxTxTurnaroundTime. aSlotTime = aCCATime + aRxTxTurnaroundTime + aAirPropagationTime + aMACProcessingDelay. PIFS = aSIFSTime + aSlotTime DIFS = aSIFSTime + 2*aSlotTime EIFS = aSIFSTime + (8 ´ ACKSize) + aPreambleLength + aPLCPHeaderLngth+ DIFS For DSSS: aSlotTime 20 µs aSIFSTime 10 µs aCCATime < 15 µs aRxTxTurnaroundTime <5 µs SIFS = PIFS = DIFS = DIFS DIFS PIFS SIFS medium busy contention next frame t direct access if medium is free  DIFS

WLAN CSMA/CA access method contention window (randomized back-off mechanism) DIFS DIFS medium busy next frame direct access if medium is free  DIFS t slot time Station ready to send starts sensing the medium (Carrier Sense) If the medium is free for the duration of an Inter-Frame Space (IFS), the station can start sending (IFS depends on service type) 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 freezes 12

WLAN access scheme details Sending unicast packets 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 DIFS data sender SIFS ACK receiver DIFS data other stations t waiting time contention

Contention for channel When the other stations find the channel idle, they would like to transmit their own packets Contention for channel If all the waiting stations attempt at once, this will surely result in collision Some CA scheme is necessary Backoff intervals can be used to reduce collision probability

B1 and B2 are backoff intervals 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 packet B1 = 25 B2 = 20 B1 = 5 B2 = 15 data wait data wait B2 = 10 B1 and B2 are backoff intervals at nodes 1 and 2 Assume cw = 31

Backoff Interval The time spent counting down backoff intervals is a part of MAC overhead Choosing a large cw leads to large backoff intervals and can result in larger overhead Choosing a small cw leads to a larger number of collisions (when two nodes count down to 0 simultaneously) Since the number of nodes attempting to transmit simultaneously may change with time, some mechanism to manage contention is needed IEEE 802.11 DCF: contention window cw is chosen dynamically depending on collision occurrence Follows Binary exponential backoff algorithm

Binary Exponential Backoff (BEB) in DCF Even before the first collision, nodes follow BEB Initial backoff interval (before 1st collision) [0,7] If still packets collide, double the collision interval [0,15], [0,31] and so on… Express this binary exponential backoff interval as a function of collision number

Numerical example #1 Two nodes, A and C both waiting for a busy channel to be idle so that they can proceed with their first transmission. After the channel becomes idle, what is the probability of A and C colliding in their first transmissions?

Numerical example #2 Two nodes, X and Y intend to transmit frames of 10 and 5 timeslots. Initially after waiting for DIFS, X and Y both generate random backoff number, rX and rY as 2. In the next stage, X generates rX =1 and Y generates rY =3. What will be the time (slots) taken to complete both transmissions and receive acks? Assume, SIFS=1 timeslot, DIFS=2 timeslots

Avoiding collisions (more) idea: allow sender to “reserve” channel rather than random access of data frames: avoid collisions of long data frames sender first transmits small request-to-send (RTS) packets to BS using CSMA RTSs may still collide with each other (but they’re short) BS broadcasts clear-to-send CTS in response to RTS CTS heard by all nodes sender transmits data frame other stations defer transmissions avoid data frame collisions completely using small reservation packets!

Collision Avoidance: RTS-CTS exchange B AP RTS(A) RTS(B) reservation collision RTS(A) CTS(A) DATA (A) ACK(A) defer time

802.11 access scheme details – RTS/CTS Sending unicast packets station can send RTS with reservation parameter after waiting for DIFS (reservation determines amount of time the data packet needs the medium) ack via CTS after SIFS by receiver (if ready to receive) sender can now send data at once, acknowledgement via ACK other stations store reservations distributed via RTS and CTS DIFS RTS data sender SIFS SIFS SIFS CTS ACK receiver DIFS NAV (RTS) data other stations NAV (CTS) t defer access contention

All backlogged nodes choose a random number, R Each node counts down R 802.11 Steps – RTS/CTS All backlogged nodes choose a random number, R Each node counts down R Continue carrier sensing while counting down Once carrier busy, freeze countdown Whoever reaches ZERO transmits RTS Neighbors freeze countdown, decode RTS RTS contains (CTS + DATA + ACK) duration = T_comm Neighbors set NAV = T_comm Remains silent for NAV time

Receiver replies with CTS 802.11 Steps – RTS/CTS Receiver replies with CTS Also contains (DATA + ACK) duration. Neighbors update NAV again Tx sends DATA, Rx acknowledges with ACK After ACK, everyone initiates remaining countdown Tx chooses new R = rand (0, CW) If RTS or DATA collides (i.e., no CTS/ACK returns) Indicates collision RTS chooses new random no. following BEB

Numerical example #3 Two nodes, X and Y intend to transmit frames of 10 and 5 timeslots. Initially after waiting for DIFS, X and Y both generate random backoff number, rX and rY as 2. In the next stage, X generates rX =1 and Y generates rY =3. What will be the time (slots) taken to complete both transmissions and receive acks? Assume, SIFS=1 timeslot, DIFS=2 timeslots RTS threshold = 8.

Another special access – with Fragmentation DIFS RTS frag1 frag2 sender SIFS SIFS SIFS SIFS SIFS CTS ACK1 ACK2 receiver NAV (RTS) NAV (CTS) DIFS NAV (frag1) data other stations NAV (ACK1) t contention

Point Coordination Function SuperFrame medium busy PIFS SIFS SIFS D1 D2 point coordinator SIFS SIFS U1 U2 wireless stations stations‘ NAV NAV

Point Coordination Function PIFS SIFS D3 D4 CFend point coordinator SIFS U4 wireless stations stations‘ NAV NAV contention free period t contention period