Data Link Layer - Computer Networks - Lecture Slides, Slides of Computer Science

These are the Lecture Slides of Computer Networks which includes Specific Protocols, Socket Programming, Network Application Protocols, Service Models, Client Server Paradigm, Distributed Processes, Interprocess Communication etc. Key important points are: Data Link Layer, Link Layer Services, Error Detection, Multiple Access Protocols, Link Layer Addressing, Specific Link Layer Technologies, Physically Connected Devices, Error Correction

Typology: Slides

2012/2013

Uploaded on 03/22/2013

dhirendra
dhirendra šŸ‡®šŸ‡³

4.3

(78)

268 documents

1 / 30

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
5: DataLink Layer 5a-1
Chapter 5: The Data Link Layer
Our goals:
understand principles
behind data link layer
services:
error detection,
correction
sharing a broadcast
channel: multiple access
link layer addressing
reliable data transfer,
flow control:
done!
instantiation and
implementation of various
link layer technologies
Overview:
link layer services
error detection, correction
multiple access protocols and
LANs
link layer addressing, ARP
specific link layer technologies:
Ethernet
hubs, bridges, switches
IEEE 802.11 LANs
PPP
ATM
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e

Partial preview of the text

Download Data Link Layer - Computer Networks - Lecture Slides and more Slides Computer Science in PDF only on Docsity!

5: DataLink Layer 5a-

Chapter 5: The Data Link Layer

Our goals:

 understand principles behind data link layer services:  error detection, correction  sharing a broadcast channel: multiple access  link layer addressing  reliable data transfer, flow control:done!

 instantiation and implementation of various link layer technologies

Overview:

 link layer services  error detection, correction  multiple access protocols and LANs  link layer addressing, ARP  specific link layer technologies:  Ethernet  hubs, bridges, switches  IEEE 802.11 LANs  PPP  ATM

5: DataLink Layer 5a-

Link Layer: setting the context

5: DataLink Layer 5a-

Link Layer Services

 Framing, link access:

 encapsulate datagram into frame, adding header, trailer  implement channel access if shared medium,  ā€˜physical addresses’ used in frame headers to identify source, dest

  • different from IP address!

 Reliable delivery between two physically connected

devices:

 we learned how to do this already (chapter 3)!  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 5a-

Link Layer Services (more)

 Flow Control:

 pacing between sender and receivers

 Error Detection:

 errors caused by signal attenuation, noise.

 receiver detects presence of errors:

  • signals sender for retransmission or drops frame

 Error Correction:

 receiver identifies and corrects bit error(s)

without resorting to retransmission

5: DataLink Layer 5a-

Error Detection

EDC= Error Detection and Correction bits (redundancy) D = Data protected by error checking, may include header fields

  • Error detection not 100% reliable!
    • protocol may miss some errors, but rarely
    • larger EDC field yields better detection and correction

5: DataLink Layer 5a-

Parity Checking

Single Bit Parity:

Detect single bit errors

Two Dimensional Bit Parity :

Detect and correct single bit errors

d data bits parity bit

0111000110101011 1

even or odd parity

5: DataLink Layer 5a-

Checksumming: Cyclic Redundancy Check

 based on r+1 bit pattern (generator) G known to tx and rx

 treat data bits D as a binary number

 obtain r-bit CRC R such that <D,R> divisible (modulo 2) by G

 receiver divides <D,R> by G. non-zero remainder implies error

 can detect all burst errors less than r+1 bits

 widely used in practice (ATM, HDCL)

R = remainder[ D. 2 r]

G Docsity.com

5: DataLink Layer 5a-

CRC Example

R = remainder[ D. 2 r]

G

G = 1001 (r=3)

D = 101110

5: DataLink Layer 5a-

Multiple Access Protocols

 single shared communication channel

 two or more simultaneous transmissions by nodes:

interference

 only one node can send successfully at a time

 multiple access protocol:

 distributed algorithm that determines how stations share channel, i.e., determine when station can transmit  communication about channel sharing must use channel itself!  what to look for in multiple access protocols:

  • synchronous or asynchronous
  • information needed about other stations
  • robustness (e.g., to channel errors)
  • performance

5: DataLink Layer 5a-

MAC Protocols: a taxonomy

Three broad classes:

 Static 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ā€ (Dynamic channel partitioning)

 tightly coordinate shared access to avoid collisions

Goal: efficient, fair, simple, decentralized

5: DataLink Layer 5a-

Channel Partitioning (CDMA)

CDMA (Code Division Multiple Access)

 unique ā€œcodeā€ assigned to each user; ie, code set partitioning

 used mostly in wireless broadcast channels (cellular, satellite,etc)

 all users share same frequency, but each user has own ā€œchippingā€ sequence (ie, code) to encode data

 encoded signal = (original data) X (chipping sequence)

 decoding: inner-product of encoded signal and chipping

sequence

 allows multiple users to ā€œcoexistā€ and transmit simultaneously with minimal interference (if codes are ā€œorthogonalā€)

5: DataLink Layer 5a-

CDMA Encode/Decode

5: DataLink Layer 5a-

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 trasnmitting 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:

 slotted ALOHA  ALOHA  CSMA and CSMA/CD

5: DataLink Layer 5a-

Slotted Aloha

 time is divided into equal size slots (= pkt trans. time)

 node with new pkt: transmit at beginning of next slot

 if collision: retransmit pkt in future slots with

probability p, until successful.

Success (S), Collision (C), Empty (E) slots