Medium Access Control

Similar documents
Topic 2b Wireless MAC. Chapter 7. Wireless and Mobile Networks. Computer Networking: A Top Down Approach

Wireless and Mobile Networks 7-2

Wireless Networks. CSE 3461: Introduction to Computer Networking Reading: , Kurose and Ross

CSC 4900 Computer Networks: Wireless Networks

MULTIPLE ACCESS PROTOCOLS 2. 1

Topics. Link Layer Services (more) Link Layer Services LECTURE 5 MULTIPLE ACCESS AND LOCAL AREA NETWORKS. flow control: error detection:

ECE 4450:427/527 - Computer Networks Spring 2017

Chapter 5 Link Layer and LANs

The Link Layer and LANs. Chapter 6: Link layer and LANs

6.9 Summary. 11/20/2013 Wireless and Mobile Networks (SSL) 6-1. Characteristics of selected wireless link standards a, g point-to-point

CS 455/555 Intro to Networks and Communications. Link Layer

Mohammad Hossein Manshaei 1393

Chapter 5: Link layer

Master Course Computer Networks IN2097

Computer Networks. Today. Principles of datalink layer services Multiple access links Adresavimas, ARP LANs Wireless LANs VU MIF CS 1/48 2/48

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 16

CC451 Computer Networks

CS 332 Computer Networks Wireless Networks

Lecture 6. Data Link Layer (cont d) Data Link Layer 1-1

Chapter 6 Wireless and Mobile Networks

Module 10 Data Link Layer CS655! 10-1!

Data Link Layer: Multi Access Protocols

COMP 3331/9331: Computer Networks and Applications

Chapter 5 Link Layer and LANs

Adaptors Communicating. Link Layer: Introduction. Parity Checking. Error Detection. Multiple Access Links and Protocols

CS 43: Computer Networks Media Access. Kevin Webb Swarthmore College November 30, 2017

Chapter 5 Link Layer. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Link Layer. 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 Link-Layer Addressing 5.

Lecture 8 Link Layer: functionality, error detection, media access algorithm

Multiple Access Links and Protocols

Shared Access Networks Wireless. 1/27/14 CS mywireless 1

CS 43: Computer Networks. 27: Media Access Contd. December 3, 2018

Outline. Introduction to Networked Embedded Systems - Embedded systems Networked embedded systems Embedded Internet - Network properties

CSC 4900 Computer Networks: The Link Layer

Wireless Networks. CSE 3461: Introduction to Computer Networking Reading: , Kurose and Ross ( 6th ed.); , Kurose and Ross (7th ed.

Chapter V: Link Layer

Last Lecture: Data Link Layer

Master Course Computer Networks IN2097

Links Reading: Chapter 2. Goals of Todayʼs Lecture. Message, Segment, Packet, and Frame

Adaptors Communicating. Link Layer: Introduction. Parity Checking. Error Detection. Multiple Access Links and Protocols

CPSC 826 Internetworking. Wireless and Mobile Networks. Wireless Networks Wireless Hosts

Mobile and Sensor Systems

Chapter 5 Link Layer and LANs

Data Communication & Networks G Session 5 - Main Theme Wireless Networks. Dr. Jean-Claude Franchitti

ECE 4450:427/527 - Computer Networks Spring 2017

Chapter 5 Link Layer. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Lecture 19. Principles behind data link layer services Framing Multiple access protocols

CSCI-1680 Wireless Chen Avin

Elements of a wireless network. Elements of a wireless network. Characteristics of selected wireless link standards. Elements of a wireless network

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

Mobile devices for wireless

transferring datagram from one node data-link layer has responsibility of to adjacent node over a link 5-1 TDTS06 Computer networks

Chapter 6 Wireless and Mobile Networks. Chapter 6 outline. Chapter 6: Wireless and Mobile Networks. Elements of a wireless network.

Lecture 5 The Data Link Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Module 4 Data Link Layer CS655! 4-1!

Chapter 6: Link layer and LANs. Link layer, LANs: outline. Link layer: introduction. Link layer: context. Link layer services (more)

Chapter 6 The Link Layer and LANs

COMP 3331/9331: Computer Networks and Applications

Link Layer and LANs 안상현서울시립대학교컴퓨터 통계학과.

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

CMPE 150: Introduction to Computer Networks

Wireless and WiFi. Daniel Zappala. CS 460 Computer Networking Brigham Young University

Chapter V: Link Layer

Elements of a wireless network. Elements of a wireless network. Some wireless link standards. Elements of a wireless network

Review. Error Detection: CRC Multiple access protocols. LAN addresses and ARP Ethernet. Slotted ALOHA CSMA/CD

Link Layer and Ethernet

Principles behind data link layer services

Lecture 6 The Data Link Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Link Layer and Ethernet

Links. Error Detection. Link Layer. Multiple access protocols. Nodes Links Frame. Shared channel Problem: collisions How nodes share a channel

CSC 401 Data and Computer Communications Networks

Link layer, LANs: outline. Chapter 5-1 Link Layer. Link layer: introduction. Link layer services

Principles behind data link layer services:

Link Layer and LANs. Our Goals. Link Layer

Chapter 5: DataLink Layer

CSCD 330 Network Programming

1-1. Switching Networks (Fall 2010) EE 586 Communication and. November 8, Lecture 30

COMP211 Chapter 6/7 Link Layer

Home Area Networks. Outline

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

CSC 8560 Computer Networks: Wireless and Mobility

CSMA/CD (Collision Detection)

CSCI Computer Networks Spring 2017

Principles behind data link layer services:

Principles behind data link layer services:

CSCI Computer Networks Fall 2016

Computer Network Fundamentals Spring Week 3 MAC Layer Andreas Terzis

Chapter 6 Wireless and Mobile Networks. Chapter 6 outline. Chapter 6: Wireless and Mobile Networks. Elements of a wireless network

High Level View. EE 122: Ethernet and Random Access protocols. Medium Access Protocols

Multiple Access in Cellular and Systems

Link Layer and LANs. CMPS 4750/6750: Computer Networks

EE 122: Ethernet and

Physical Layer. Medium Access Links and Protocols. Point-to-Point protocols. Modems: Signaling. Modems Signaling. Srinidhi Varadarajan

Links. CS125 - mylinks 1 1/22/14

Announcements: ECE/CS 372 introduction to computer networks. Assignment 4 due now. Chapter 7

CMPE 257: Wireless and Mobile Networking

Chapter 5: The Data Link Layer

Wireless and Mobile Networks

Redes de Computadores. Medium Access Control

Getting Connected (Chapter 2 Part 4) Networking CS 3470, Section 1 Sarah Diesburg

Transcription:

Medium Access Control All material copyright 1996-2009 J.F Kurose and K.W. Ross, All Rights Reserved 5: DataLink Layer 5-1

Link Layer Introduction and services Multiple access protocols Ethernet Wireless links Wireless LANs (802.11) 5: DataLink Layer 5-2

Link Layer Services, : encapsulate datagram into frame, adding header, trailer channel access if shared medium MAC addresses used in frame headers to identify src, dest different from IP address! seldom used on low bit-error link (fiber, some twisted pair) wireless links: high error rates Q: why both link-level and end-end reliability? 5: DataLink Layer 5-3

Link Layer Services (more) : pacing between adjacent sending and receiving nodes : errors caused by signal attenuation, noise. receiver detects presence of errors: signals sender for retransmission or drops frame : receiver identifies and corrects bit error(s) without resorting to retransmission half-duplex and full-duplex with half duplex, nodes at both ends of link can transmit, but not at same time 5: DataLink Layer 5-4

Where is the link layer implemented? in each and every host link layer implemented in adaptor (aka network interface card NIC) application transport network host schematic Ethernet card, PCMCI cpu memory link card, 802.11 card implements link, physical layer attaches into host s system buses combination of hardware, software, firmware link physical controller physical transmission host bus (e.g., PCI) network adapter card 5: DataLink Layer 5-5

Multiple Access Links and Protocols Two types of links : point-to-point PPP for dial-up access point-to-point link between Ethernet switch and host broadcast (shared wire or medium) old-fashioned Ethernet upstream hybrid fiber coax shared wire (e.g., cabled Ethernet) shared RF (e.g., 802.11 WiFi) shared RF (satellite) humans at a cocktail party (shared air, acoustical) 5: DataLink Layer 5-6

Multiple Access protocols single shared broadcast channel two or more simultaneous transmissions by nodes: interference collision if node receives two or more signals at the same time multiple access protocol distributed algorithm that determines how nodes share channel, i.e., determine when node can transmit communication about channel sharing must use channel itself! no out-of-band channel for coordination 5: DataLink Layer 5-7

MAC Protocols: a taxonomy Three broad classes: divide channel into smaller pieces (time slots, frequency, code) allocate piece to node for exclusive use channel not divided, allow collisions recover from collisions nodes take turns, but nodes with more to send can take longer turns 5: DataLink Layer 5-8

Channel 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 example: 6-station LAN, 1,3,4 have pkt, slots 2,5,6 idle 6-slot frame 1 3 4 1 3 4 5: DataLink Layer 5-9

5: DataLink Layer 5-10 FDM cable frequency bands example: 6-station LAN, 1,3,4 have pkt, frequency bands 2,5,6 idle unused transmission time in frequency bands go idle each station assigned fixed frequency band channel spectrum divided into frequency bands FDMA: frequency division multiple access Channel Partitioning MAC protocols: FDMA

Random Access Protocols When node has packet to send transmit at full channel data rate R. no a priori coordination among nodes two or more transmitting nodes collision, random access MAC protocol specifies: how to detect collisions how to recover from collisions (e.g., via delayed retransmissions) Examples of random access MAC protocols: 5: DataLink Layer 5-11

CSMA (Carrier Sense Multiple Access) CSMA: listen before transmit: If channel sensed idle: transmit entire frame If channel sensed busy, defer transmission human analogy: don t interrupt others! 5: DataLink Layer 5-12

CSMA collisions collisions can still occur: propagation delay means two nodes may not hear each other s transmission collision: entire packet transmission time wasted note: role of distance & propagation delay in determining collision probability 5: DataLink Layer 5-13

CSMA/CD (Collision Detection) CSMA/CD: carrier sensing, deferral as in CSMA collisions detected within short time colliding transmissions aborted, reducing channel wastage collision detection: easy in wired LANs: measure signal strengths, compare transmitted, received signals difficult in wireless LANs: received signal strength overwhelmed by local transmission strength human analogy: the polite conversationalist 5: DataLink Layer 5-14

Taking Turns MAC protocols channel partitioning MAC protocols: share channel efficiently and fairly at high load inefficient at low load: delay in channel access, 1/N bandwidth allocated even if only 1 active node! Random access MAC protocols efficient at low load: single node can fully utilize channel high load: collision overhead taking turns protocols look for best of both worlds! 5: DataLink Layer 5-15

Summary of MAC protocols channel partitioning, by time, frequency or code Time Division, Frequency Division random access (dynamic), ALOHA, S-ALOHA, CSMA, CSMA/CD carrier sensing: easy in some technologies (wire), hard in others (wireless) CSMA/CD used in Ethernet CSMA/CA used in 802.11 taking turns polling from central site, token passing Bluetooth, FDDI, IBM Token Ring 5: DataLink Layer 5-16

Ethernet dominant wired LAN technology: cheap $20 for NIC first widely used LAN technology simpler, cheaper than token LANs and ATM kept up with speed race: 10 Mbps 10 Gbps Metcalfe s Ethernet sketch 5: DataLink Layer 5-17

Star topology bus topology popular through mid 90s all nodes in same collision domain (can collide with each other) today: star topology prevails active switch in center each spoke runs a (separate) Ethernet protocol (nodes do not collide with each other) switch bus: coaxial cable star 5: DataLink Layer 5-18

Ethernet: Unreliable, connectionless connectionless: No handshaking between sending and receiving NICs unreliable: receiving NIC doesn t send acks or nacks to sending NIC stream of datagrams passed to network layer can have gaps (missing datagrams) gaps will be filled if app is using TCP otherwise, app will see gaps Ethernet s MAC protocol: unslotted CSMA/CD 5: DataLink Layer 5-19

Ethernet CSMA/CD algorithm 1. NIC receives datagram from network layer, creates frame 2. If NIC senses channel idle, starts frame transmission If NIC senses channel busy, waits until channel idle, then transmits 3. If NIC transmits entire frame without detecting another transmission, NIC is done with frame! 4. If NIC detects another transmission while transmitting, aborts and sends jam signal 5. After aborting, NIC enters exponential backoff: after mth collision, NIC chooses K at random from {0,1,2,,2 m -1}. NIC waits K 512 bit times, returns to Step 2 5: DataLink Layer 5-20

Ethernet s CSMA/CD (more) Jam Signal: make sure all other transmitters are aware of collision; 48 bits Bit time:.1 microsec for 10 Mbps Ethernet ; for K=1023, wait time is about 50 msec Exponential Backoff: Goal: adapt retransmission attempts to estimated current load heavy load: random wait will be longer first collision: choose K from {0,1}; delay is K 512 bit transmission times after second collision: choose K from {0,1,2,3} after ten collisions, choose K from {0,1,2,3,4,,1023} 5: DataLink Layer 5-21

Elements of a wireless network network infrastructure wireless hosts laptop, PDA, IP phone run applications may be stationary (non-mobile) or mobile wireless does not always mean mobility 6: Wireless and Mobile Networks 6-22

Elements of a wireless network base station typically connected to wired network relay - responsible for sending packets between wired network network and wireless infrastructure host(s) in its area e.g., cell towers, 802.11 access points 6: Wireless and Mobile Networks 6-23

Elements of a wireless network network infrastructure wireless link typically used to connect mobile(s) to base station also used as backbone link multiple access protocol coordinates link access various data rates, transmission distance 6: Wireless and Mobile Networks 6-24

Data rate (Mbps) Characteristics of selected wireless link standards 200 802.11n 54 5-11 4 1 802.11a,g 802.11b 802.15 802.11a,g point-to-point data 802.16 (WiMAX) UMTS/WCDMA-HSPDA, CDMA2000-1xEVDO 3G cellular enhanced.384 UMTS/WCDMA, CDMA2000 3G.056 IS-95, CDMA, GSM 2G Indoor 10-30m Outdoor 50-200m Mid-range outdoor 200m 4 Km Long-range outdoor 5Km 20 Km 6: Wireless and Mobile Networks 6-25

Elements of a wireless network network infrastructure mode base station connects mobiles into wired network handoff: mobile changes base station providing connection into wired network 6: Wireless and Mobile Networks 6-26

Elements of a wireless network mode no base stations nodes can only transmit to other nodes within link coverage nodes organize nodes organize themselves into a network: route among themselves 6: Wireless and Mobile Networks 6-27

Wireless network taxonomy single hop multiple hops infrastructure (e.g., APs) host connects to base station (WiFi, WiMAX, cellular) which connects to larger Internet host may have to relay through several wireless nodes to connect to larger Internet: mesh net no infrastructure no base station, no connection to larger Internet (Bluetooth, ad hoc nets) no base station, no connection to larger Internet. May have to relay to reach other a given wireless node MANET, VANET 6: Wireless and Mobile Networks 6-28

Wireless Link Characteristics Differences from wired link. : radio signal attenuates as it propagates through matter (path loss) : standardized wireless network frequencies (e.g., 2.4 GHz) shared by other devices (e.g., phone); devices (motors) interfere as well : radio signal reflects off objects ground, arriving ad destination at slightly different times. make communication across (even a point to point) wireless link much more difficult 6: Wireless and Mobile Networks 6-29

Wireless network characteristics Multiple wireless senders and receivers create additional problems (beyond multiple access): C A B C A B problem B, A hear each other B, C hear each other A, C can not hear each other means A, C unaware of their interference at B space 6: Wireless and Mobile Networks 6-30

802.11 LAN architecture BSS 1 AP Internet hub, switch or router AP wireless host communicates with base station (aka cell ) in infrastructure mode contains: wireless hosts access point (AP): base station ad hoc mode: hosts only BSS 2 6: Wireless and Mobile Networks 6-31

802.11: Channels, association 802.11b: 2.4GHz-2.485GHz spectrum divided into channels at different frequencies AP admin chooses frequency for AP interference possible: channel can be same as that chosen by neighboring AP! y g g host: must associate with an AP 6: Wireless and Mobile Networks 6-32

IEEE 802.11: multiple access avoid collisions: 2 + nodes transmitting at same time 802.11: CSMA - sense before transmitting don t collide with ongoing transmission by other node 802.11: no collision detection! difficult to receive (sense collisions) when transmitting due to weak received signals s (fading) can t sense all collisions in any case: hidden terminal, fading goal: avoid collisions: CSMA/C(ollision)A(voidance) C A B C A B A s signal strength C s signal strength space 6: Wireless and Mobile Networks 6-33

IEEE 802.11 MAC Protocol: CSMA/CA 802.11 sender 1 if sense channel idle for DIFS then transmit entire frame (no CD) 2 if sense channel busy then start random backoff time timer counts down while channel idle transmit when timer expires if no ACK, increase random backoff interval, repeat 2 802.11 receiver - if frame received OK return ACK after SIFS (ACK needed due to hidden terminal problem) DIFS sender receiver data ACK SIFS 6: Wireless and Mobile Networks 6-34

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 s to RTS CTS heard by all nodes sender transmits data frame other stations defer transmissions avoid data frame collisions completely using small reservation packets! 6: Wireless and Mobile Networks 6-35

Collision Avoidance: RTS-CTS exchange A B AP time 6: Wireless and Mobile Networks 6-36

6: Wireless and Mobile Networks 6-37 operating point 2. When BER becomes too high, switch to lower transmission rate but with lower BER QAM256 (8 Mbps) QAM16 (4 Mbps) BPSK (1 Mbps) 1. SNR decreases, BER increase as node moves away from base station base station, mobile dynamically change transmission rate (physical layer modulation technique) as mobile moves, SNR varies 10 20 30 40 SNR(dB) 10-7 10-6 10-5 BER 10-4 10-3 10-2 Rate Adaptation 10-1 802.11: advanced capabilities

802.11: advanced capabilities Power Management node-to-ap: I am going to sleep until next beacon frame AP knows not to transmit frames to this node node d wakes up before next beacon frame beacon frame: contains list of mobiles with APto-mobile frames waiting to be sent node will stay awake if AP-to-mobile frames to be sent; otherwise sleep again until next beacon frame 6: Wireless and Mobile Networks 6-38

802.15: personal area network less than 10 m diameter replacement for cables (mouse, keyboard, headphones) ad hoc: no infrastructure master/slaves: slaves request permission to send (to master) S S P M P S P radius of coverage P master grants requests 802.15: evolved from Bluetooth specification 2.4-2.5 GHz radio band M S P Master device Slave device Parked device (inactive) up to 721 kbps 6: Wireless and Mobile Networks 6-39

Wireless, mobility: impact on higher layer protocols logically, impact should be minimal best effort service model remains unchanged TCP and UDP can (and do) run over wireless, mobile but performance-wise: packet loss/delay due to bit-errors (discarded packets, delays for link-layer retransmissions), and handoff TCP interprets loss as congestion, will decrease congestion window un-necessarily delay impairments for real-time traffic limited bandwidth of wireless links 6: Wireless and Mobile Networks 6-40