Question? Leave a message!

Medium Access Control in Wireless Networks

Medium Access Control in Wireless Networks 45
Medium Access Control in Wireless NetworksAcknowledgements Many of the slides are based on a tutorial by Prof. Nitin Vaidya and some other sources.Overview • Issues with spectrum sharing • Current MAC protocols • Power management • Rate control • Interaction with PHY layerMedium Access Control • Wireless channel is a shared medium • MAC coordinates transmission between users sharing the spectrum • Goals: prevent collisions while maximizing throughput and minimizing delay • Types: – Centralized – DecentralizedMAC Protocols: a taxonomy Three broad classes: • Channel Partitioning – divide channel into smaller “pieces” (time slots, frequency) – allocate piece to node for exclusive use • Random Access – allow collisions – “recover” from collisions • “Taking turns” – tightly coordinate shared access to avoid collisions Goal: efficient, fair, simple, decentralizedChannel Partitioning MAC protocols: TDMA TDMA: time division multiple access • Access to channel in "rounds" • Each station gets fixed length slot (length = pkt trans time) in each round • Unused slots go idle Channel Partitioning MAC protocols: FDMA FDMA: frequency division multiple access • Channel spectrum divided into frequency bands • Each station assigned fixed frequency band • Unused transmission time in frequency bands go idle Random Access Protocols: Unslotted ALOHA • Simpler, no synchronization • Packet needs transmission: – Send without awaiting for beginning of slot – Maximum throughput: 18.4Slotted Aloha • time is divided into equal size slots (= pkt trans. time) • node with new arriving pkt: transmit at beginning of next slot • if collision: retransmit pkt in future slots with probability p, until successful. • Maximum throughput: 37 Success (S), Collision (C), Empty (E) slotsCarrier Sense Multiple Access (CSMA) • In some shorter distance networks, it is possible to listen to the channel before transmitting • In radio networks, this is called “sensing the carrier” • The CSMA protocol works just like Aloha except: If the channel is sensed busy, then the user waits to transmit its packet, and a collision is avoided • This really improves the performance in short distance networksHidden Terminal Problem A B C Nodes A and C cannot hear each other Transmissions by nodes A and C can collide at node B Nodes A and C are hidden from each otherBusy Tone Solutions Tobagi75 • A receiver transmits busy tone when receiving data • All nodes hearing busy tone keep silent • Avoids interference from hidden terminals • Requires a separate channel for busy toneMACA Solution for Hidden Terminal Problem Karn90 • When node A wants to send a packet to node B, node A first sends a RequesttoSend (RTS) to A • On receiving RTS, node A responds by sending CleartoSend (CTS), provided node A is able to receive the packet • When a node (such as C) overhears a CTS, it keeps quiet for the duration of the transfer – Transfer duration is included in RTS and CTS both A B CReliability • Wireless links are prone to errors. High packet loss rate detrimental to transport layer performance. • Mechanisms needed to reduce packet loss rate experienced by upper layersSimple Solution to Improve Reliability • When node B receives a data packet from node A, node B sends an Acknowledgement (Ack). This approach adopted in many protocols. • If node A fails to receive an Ack, it will retransmit the packet. A B CIEEE 802.11 Wireless MAC Distributed and centralized MAC components – Distributed Coordination Function (DCF) – Point Coordination Function (PCF) • DCF suitable for multihop ad hoc networking • DCF is a Carrier Sense Multiple Access/Collision Avoidance (CSMA/CA) protocolIEEE 802.11 DCF • Uses RTSCTS exchange to avoid hidden terminal problem – Any node overhearing a CTS cannot transmit for the duration of the transfer • Uses ACK to achieve reliability • Any node receiving the RTS cannot transmit for the duration of the transfer – To prevent collision with ACK when it arrives at the sender – When B is sending data to C, node A will keep quite A B CCollision Avoidance • With halfduplex radios, collision detection is not possible • CSMA/CA: Wireless MAC protocols often use collision avoidance techniques, in conjunction with a (physical or virtual) carrier sense mechanism • Carrier sense: When a node wishes to transmit a packet, it first waits until the channel is idle. • Collision avoidance: Nodes hearing RTS or CTS stay silent for the duration of the corresponding transmission. Once channel becomes idle, the node waits for a randomly chosen duration before attempting to transmit.IEEE 802.11 RTS = RequesttoSend RTS A B C D E F Pretending a circular rangeIEEE 802.11 RTS = RequesttoSend RTS A B C D E F NAV = 10 NAV = remaining duration to keep quietIEEE 802.11 CTS = CleartoSend CTS A B C D E FIEEE 802.11 CTS = CleartoSend CTS A B C D E F NAV = 8IEEE 802.11 •DATA packet follows CTS. Successful data reception acknowledged using ACK. DATA A B C D E FIEEE 802.11 ACK A B C D E FIEEE 802.11 Reserved area ACK A B C D E FIEEE 802.11 Carrier sense Interference range “range” DATA A A B C D E F F Transmit “range”CSMA/CA • Physical carrier sense, and • Virtual carrier sense using Network Allocation Vector (NAV) • NAV is updated based on overheard RTS/CTS/DATA/ACK packets, each of which specified duration of a pending transmission • Nodes stay silent when carrier sensed (physical/virtual) • Backoff intervals used to reduce collision probabilityBackoff Interval • 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 – Countdown is suspended if medium becomes busy • When backoff interval reaches 0, transmit RTSDCF Example B1 = 25 B1 = 5 wait data data wait B2 = 10 B2 = 20 B2 = 15 B1 and B2 are backoff intervals cw = 31 at nodes 1 and 2Backoff 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)Backoff Interval • 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 occurrenceBinary Exponential Backoff in DCF • When a node fails to receive CTS in response to its RTS, it increases the contention window – cw is doubled (up to an upper bound) • When a node successfully completes a data transfer, it restores cw to CWmin • cw follows a sawtooth curveFairness Issues in MAC • Many definitions of fairness plausible • Simplest definition: All nodes should receive equal bandwidth A B Two flows C DFairness Issues in MAC • Assume that initially, A and B both choose a backoff interval in range 0,31 but their RTSs collide • Nodes A and B then choose from range 0,63 – Node A chooses 4 slots and B choose 60 slots – After A transmits a packet, it next chooses from range 0,31 – It is possible that A may transmit several packets before B transmits its first packet A B Two flows C DFairness Issues in MAC • Unfairness occurs when one node has backed off much more than some other node A B Two flows C DMACAW Solution for Fairness Bharganav94 • When a node transmits a packet, it appends the cw value to the packet, all nodes hearing that cw value use it for their future transmission attempts • Since cw is an indication of the level of congestion in the vicinity of a specific receiver node, MACAW proposes maintaining cw independently for each receiver • Using perreceiver cw is particularly useful in multihop environments, since congestion level at different receivers can be very differentAnother MACAW Proposal • For the scenario below, when node A sends an RTS to B, while node C is receiving from D, node B cannot reply with a CTS, since B knows that D is sending to C • When the transfer from C to D is complete, node B can send a RequesttosendRTS to node A – Node A may then immediately send RTS to node B D C B AProblems • This approach, however, does not work in the scenario below – Node B may not receive the RTS from A at all, due to interference with transmission from C D C B AEnergy Conservation • Since many mobile hosts are operated by batteries, MAC protocols which conserve energy are of interest • Two approaches to reduce energy consumption – Power save: Turn off wireless interface when desirable – Power control: Reduce transmit powerPower Aware MultiAccess Protocol (PAMAS) Singh98 • A node powers off its radio while a neighbor is transmitting to someone else Node A sending to B Node C stays powered off B A CPower Aware MultiAccess Protocol (PAMAS) • What should node C do when it wakes up and finds that D is transmitting to someone else – C does not know how long the transfer will last Node D sending to E Node A sending to B C stays powered off B C wakes up and A C finds medium busy D E SKIPPAMAS • PAMAS uses a control channel separate from the data channel • Node C on waking up performs a binary probe to determine the length of the longest remaining transfer – C sends a probe packet with parameter L – All nodes which will finish transfer in interval L/2,L respond – Depending on whether node C sees silence, collision, or a unique response it takes varying actions • Node C (using procedure above) determines the duration of time to go back to sleepDisadvantages of PAMAS • Use of a separate control channel • Nodes have to be able to receive on the control channel while they are transmitting on the data channel – And also transmit on data and control channels simultaneously • A node (such as C) should be able to determine when probe responses from multiple senders collideAnother Proposal in PAMAS • To avoid the probing, a node should switch off the interface for data channel, but not for the control channel (which carries RTS/CTS packets) • Advantage: Each sleeping node always knows how long to sleep by watching the control channel • Disadvantage: This may not be useful when hardware is shared for the control and data channels – It may not be possible turn off much hardware due to the sharingPower Save in IEEE 802.11 Ad Hoc Mode • Time is divided into beacon intervals ATIM window Beacon interval • Each beacon interval begins with an ATIM windowPower Save in IEEE 802.11 Ad Hoc Mode • If host A has a packet to transmit to B, A must send an ATIM Request to B during an ATIM Window • On receipt of ATIM Request from A, B will reply by sending an ATIM Ack, and stay up during the rest of the beacon interval • If a host does not receive an ATIM Request during an ATIM window, and has no pending packets to transmit, it may sleep during rest of the beacon intervalPower Save in IEEE 802.11 Ad Hoc Mode Node A ATIM ATIM Data Ack Req Ack Node B Sleep Node CPower Save in IEEE 802.11 Ad Hoc Mode • Size of ATIM window and beacon interval affects performance • If ATIM window is too large, reduction in energy consumption reduced – Energy consumed during ATIM window • If ATIM window is too small, not enough time to send ATIM requestPower Save in IEEE 802.11 Ad Hoc Mode • How to choose ATIM window dynamically – Based on observed load Jung02infocom • How to synchronize hosts – If two hosts’ ATIM windows do not overlap in time, they cannot exchange ATIM requests – Coordination requires that each host stay awake long enough (at least periodically) to discover outofsync neighbors Tseng02infocom ATIM ATIMImpact on Upper Layers • If each node uses the 802.11 powersave mechanism, each hop will require one beacon interval – This delay could be intolerable • Allow upper layers to dictate whether a node should enter the power save mode or not Chen01mobicomEnergy Conservation • Power save • Power controlPower Control • Power control has two potential benefits – Reduced interference increased spatial reuse – Energy savingPower Control • When C transmits to D at a high power level, B cannot receive A’s transmission due to interference from C A B C DPower Control • If C reduces transmit power, it can still communicate with D • Reduces energy consumption at node C • Allows B to receive A’s transmission (spatial reuse) A B C DPower Control a • Received power level is proportional to 1/d , a = 2 • If power control is utilized, energy required to transmit to a host at distance d is proportional to a d + constant • Shorter hops typically preferred for energy consumption (depending on the constant) Rodoplu99 – Transmit to C from A via B, instead of directly from A to C C A BPower Control with 802.11 • Transmit RTS/CTS/DATA/ACK at least power level needed to communicate with the received A B C D • A/B do not receive RTS/CTS from C/D. Also do not sense D’s data transmission • B’s transmission to A at high power interferes with reception of ACK at CA Plausible Solution • RTS/CTS at highest power, and DATA/ACK at smallest necessary power level Data sensed A B C D Data RTS Ack Interference range • A cannot sense C’s data transmission, and may transmit DATA to some other host • This DATA will interfere at C • This situation unlikely if DATA transmitted at highest power level – Interference range sensing rangeSolution (cont.) • Transmitting RTS at the highest power level also reduces spatial reuse • Nodes receiving RTS/CTS have to defer transmissionsCaveat • Energy saving by power control is limited to savings in transmit energy • Other energy costs may not change, and may represent a significant fraction of total energy consumptionPower Controlled Multiple Access (PCMA) Monks01infocom • If receiver node R can tolerate interference E, it sends a busy tone at power level C/E, where C is an appropriate constant • When some node X receives a busytone a power level Pr, it may transmit at power level Pt = C/Pr busy tone Pt X R data C/E Y SPower Controlled Multiple Access (PCMA) • If receiver node R can tolerate noise E, it sends a busy tone at power level C/E, where C is an appropriate constant • When some node X receives a busytone a power level Pr, it may transmit at power level Pt = C/Pr • Explanation: – Gain of channel RX = gain of channel XR = g – Busy tone signal level at X = Pr = g C / E – Node X may transmit at level = Pt = C/Pr = E/g – Interference received by R = Pt g = EPower Controlled Multiple Access (PCMA) • Advantage – Allows higher spatial reuse, as well as power saving using power control • Disadvantages: – Need a separate channel for the busy tone – Since multiple nodes may transmit the busy tones simultaneously, spatial reuse is less than optimalAdaptive Modulation • Channel conditions are timevarying • Received signaltonoise ratio changes with time A BAdaptive Modulation • Multirate radios are capable of transmitting at several rates, using different modulation schemes • Choose modulation scheme as a function of channel conditions Modulation schemes provide a tradeoff between Throughput throughput and range DistanceAdaptive Modulation • If physical layer chooses the modulation scheme transparent to MAC – MAC cannot know the time duration required for the transfer • Must involve MAC protocol in deciding the modulation scheme – Some implementations use a senderbased scheme for this purpose Kamerman97 – Receiverbased schemes can perform betterSenderBased “Autorate Fallback” Kamerman97 • Probing mechanisms • Sender decreases bit rate after X consecutive transmission attempts fail • Sender increases bit rate after Y consecutive transmission attempt succeedAutorate Fallback • Advantage – Can be implemented at the sender, without making any changes to the 802.11 standard specification • Disadvantage – Probing mechanism does not accurately detect channel state – Channel state detected more accurately at the receiver – Performance can suffer • Since the sender will periodically try to send at a rate higher than optimal • Also, when channel conditions improve, the rate is not increased immediatelyReceiverBased Autorate MAC Holland01mobicom • Sender sends RTS containing its best rate estimate • Receiver chooses best rate for the conditions and sends it in the CTS • Sender transmits DATA packet at new rate • Information in data packet header implicitly updates nodes that heard old rateReceiverBased Autorate MAC Protocol C RTS (2 Mbps) A B CTS (1 Mbps) Data (1 Mbps) D NAV updated using rate specified in the data packet802.11b Physical LayerSpectrum • 802.11 operates in the unlicensed band (ISM – Industrial Scientific and Medical band) 3 such bands • Cordless Telephony: 902 to 928 MHz • 802.11b: 2.4 to 2.483 GHz rd • 3 ISM Band: 5.725 to 5.875 GHz • 802.11a: 5.15 to 5.825 GHzData Rates and Range • 802.11: 2Mbps (Proposed in 1997) • 802.11b: 1, 2, 5.5 and 11 Mbps, 100mts. range (product released in 1999, no product for 1 or 2 Mbps) • 802.11g: 54Mbps, 100mts. range (uses OFDM) • 802.11a: 6 to 54 Mbps, 50mts. range (uses OFDM)802.11x a  OFDM in the 5GHz band b  High Rate DSSS in the 2.4GHz band c  Bridge Operation Procedures e  MAC Enhancements for QoS to improve QoS for better support of audio and video (such as MPEG2) applications. g  OFDM based 2.4 GHz WLAN. i  Medium Access Method (MAC) Security Enhancements: enhance security and authentication mechanisms. IEEE 802.11a – 5 GHz (5.155.25, 5.255.35, 5.7255.825 GHz) – OFDM (Orthogonal Freq. Div. Multiplexing) ISM – 52 Subcarriers in OFDM – BPSK/QPSK/QAM – Forward Error Correction (Convolutional) – Rates: 6, 9, 12, 18, 24, 36, 48, 54 MbpsBase specifications • Three Physical Layers: – FHSS (Frequency Hopping Spread Spectrum) – DSSS (Direct Sequence Spread Spectrum) – OFDM (Orthogonal Frequency Division Multiplexing)Why Spread Spectrum • C = Blog2(1+S/N) • To achieve the same channel capacity C – Large S/N, small B – Small S/N, large B – Increase S/N is inefficient due to the logarithmic relationship power power signal noise, interferences signal frequency B B e.g. B = 1.25 MHz e.g. B = 30 KHzFrequency Hopping SS (FHSS) • 2.4GHz band divided into 75 1MHz subchannels • Sender and receive agree on a hopping pattern (pseudo random series). 22 hopping patterns defined One possible pattern f f f f f f f f f f f • Different hopping sequences enable coexistence of multiple BSSs • Robust against narrowband interferencesDirect Sequence SS • Direct sequence (DS): most prevalent – Signal is spread by a wide bandwidth pseudorandom sequence (code sequence) – Signals appear as wideband noise to unintended receivers • Not for intracell multiple access – Nodes in the same cell use same code sequence802.11b PHY FRAME Locked clock, mod. select Data Rate Scrambled 1’s Start of Frame SYNC SFD SIGNAL SERVICE LENGTH CRC (128) (16) (8) (8) (8) (16) Frame Details Lock/Acquire Frame (data rate, size) PLCP Header PSDU PLCP Preamble (48) (2304 max) (144) Preamble at 1Mbps (DBPSK) 2Mbps (DQPSK) 5.5 and 11 Mbps PPDU (CCK) (PLCP Protocol Data Unit)
Document Information
User Name:
User Type:
Uploaded Date: