Data Link Control General principles ICSA 341 Data

  • Slides: 15
Download presentation
Data Link Control �General principles ICSA 341 Data Communications and Computer Networks 1

Data Link Control �General principles ICSA 341 Data Communications and Computer Networks 1

Data Link Control �Coordinating between two end-systems across a Link to send/receive data correctly

Data Link Control �Coordinating between two end-systems across a Link to send/receive data correctly �Who should send and when – Medium Access �Coordinating sending and receiving – Line Discipline – involves Link establishment etc �What happens if received data is in error – Error control �Error correction �Retransmission �Processing capacity & Buffer and sending and receiving processes – Flow Control ICSA 341 Data Communications and Computer Networks 2

Line Discipline �No Device should send unless it has ascertained that the receiver is

Line Discipline �No Device should send unless it has ascertained that the receiver is ready to receive �Link Establishment – logical check �Two Basic Schemes �Enquiry /Ack (peer to peer) �Poll /Select (Master /Slave) ICSA 341 Data Communications and Computer Networks 3

SIMPLE ENQ/ACK protocol T ENQ ACK R Establish data (e. g. , "peer-to-peer", dedicated

SIMPLE ENQ/ACK protocol T ENQ ACK R Establish data (e. g. , "peer-to-peer", dedicated line) ACK Transfer data ACK data ENQ - enquiry ACK - Acknowledgement EOT - end of transmission ACK ICSA 341 Data Communications and Computer Networks EOT Terminate 4

POLL protocol T POL R L Establish NAK (e. g. , multipoint) POL Secondary

POLL protocol T POL R L Establish NAK (e. g. , multipoint) POL Secondary stations L data Transfer ACK Primary data POLL - "have anything? " ACK - Acknowledgement EOT - end of transmission Address the secondary ? ACK EOT POL ICSA 341 Data Communications and Computer Networks L Terminate 5

SELECT protocol T SEL NAK (e. g. , multipoint) R Establish SEL Secondary stations

SELECT protocol T SEL NAK (e. g. , multipoint) R Establish SEL Secondary stations ACK Transfer data Primary ACK SEL - "ready to receive? " ACK - Acknowledgement NAK - Negative Acknowledgement EOT - end of transmission data ACK ICSA 341 Data Communications and Computer Networks EOT Terminate 6

Flow Control �How fast and How much data to send? �Tx & rx speed

Flow Control �How fast and How much data to send? �Tx & rx speed physical layer �Memory storage at sender and receiver �Processing capacity at sender and receiver �Two most popular schemes �STOP & WAIT �SLIDING WINDOW ICSA 341 Data Communications and Computer Networks 7

T STOP and WAIT data WAIT TIME ACK R Establish data WAIT TIME ACK

T STOP and WAIT data WAIT TIME ACK R Establish data WAIT TIME ACK Transfer data ACK - Acknowledgement WAIT TIME ACK data EOT - end of transmission Frames can be numbered 0, 1 WAIT TIME ACK EOT ICSA 341 Data Communications and Computer Networks Terminate 8

T SLIDING WINDOW WAIT (without error control) Data R Data Establish , 0 ,

T SLIDING WINDOW WAIT (without error control) Data R Data Establish , 0 , 1 TIME Data WAIT TIME , 2 Data , 3 Transfer ACK, 4 Data , 4 data, n - data, frame sent WAIT TIME Data , 5 Data ACK, n - ACK, expected frame EOT - end of transmission WAIT TIME , 6 7 , K C A EOT ICSA 341 Data Communications and Computer Networks Terminate 9

T STOP and WAIT Data R 0 TIME OUT!! ARQ: lost frame Data 0

T STOP and WAIT Data R 0 TIME OUT!! ARQ: lost frame Data 0 TIME OUT!! Data ACK - Acknowledgement 0 ACK 1 Data 1 ACK 0. . . ICSA 341 Data Communications and Computer Networks 10

T STOP and WAIT Data TIME OUT!! R ACK 1 ARQ: lost ACK TIME

T STOP and WAIT Data TIME OUT!! R ACK 1 ARQ: lost ACK TIME OUT!! 0 Data 0 ACK 1 ACK - Acknowledgement ICSA 341 Data Communications and Computer Networks . . . 11

T STOP and WAIT Data WAIT TIME ACK 1 ARQ: damaged frame WAIT TIME

T STOP and WAIT Data WAIT TIME ACK 1 ARQ: damaged frame WAIT TIME Data ACK - Acknowledgement NAK - Negative Acknowledgement 1 ACK 0 Data WAIT TIME R 0 0 NAK Data WAIT TIME ERROR! 0 ACK 1. . . ICSA 341 Data Communications and Computer Networks 12

Data T SLIDING WINDOW ARQ: Go-Back-n: Damaged Frame R , 0 Data , 1

Data T SLIDING WINDOW ARQ: Go-Back-n: Damaged Frame R , 0 Data , 1 , 2 Data , 3 CK Da Data, n - data, sent frame ACK, n - ACK, expected frame NAK, n - NAK, damaged frame EOT - end of transmission ERROR! ta, 4 A K A N , 3 Data , 5 Discarded Data , 3 ICSA 341 Data Communications and Computer Networks , K C A 3 13

Data T SLIDING WINDOW Go-Back-n: Lost Frame R , 0 Data , 1 Data

Data T SLIDING WINDOW Go-Back-n: Lost Frame R , 0 Data , 1 Data , 2 , 3 LOST! Data, 4 Data, n - data, sent frame ACK, n - ACK, expected frame NAK, n - NAK, damaged frame EOT - end of transmission Discarded 5 , 3 K A D ata, 6 N Data, 3 4 , K C A ICSA 341 Data Communications and Computer Networks 14

Data T SLIDING WINDOW Select-Reject: Lost Frame R , 0 Data , 1 Data

Data T SLIDING WINDOW Select-Reject: Lost Frame R , 0 Data , 1 Data , 2 , 3 LOST! Data, 4 Data, n - data, sent frame ACK, n - ACK, expected frame NAK, n - NAK, damaged frame EOT - end of transmission 5 , 3 K A D ata, 6 N Data, 3 , 7 K C A ICSA 341 Data Communications and Computer Networks 15