SlideShare a Scribd company logo
1 of 20
DATA COMMUNICATIONS &
NETWORKING
                LECTURE-
23

          Course Instructor : Sehrish Rafiq
          Department Of Computer Science
          University Of Peshawar
LECTURE OVERVIEW
 Flow Control
 Error Control

 Stop &Wait ARQ
DATA LINK CONTROL
 The most important responsibilities of the data
  link layer are flow control and error control.
 Collectively ,these functions are known as
  datalink control.
FLOW CONTROL
 Flow control coordinates the amount of data that
  can be sent before receiving acknowledgement
  and is one of the most important duties of the
  data link layer.
 In most cases flow control is a set of procedures
  that tells the sender how much data it can
  transmit before it must wait for an
  acknowledgement from the receiver.
 The flow of data must not be allowed to
  overwhelm the receiver.
WHY WE NEED FLOW CONTROL???
 Any receiving device has a limited speed at which
  it can process incoming data and a limited
  amount of memory in which to store incoming
  data.
 The receiving device must be able to inform the
  sending device before that limit is reached.
 And to request that the transmitting device send
  fewer frames or stop temporarily.
 Incoming data must be checked and processed
  before they can be used.
 The rate of such processing is slower than the
  rate of transmission.
ERROR CONTROL
 Error control is both error detection and error
  correction.
 It allows the receiver to inform the sender of any
  frames lost or damaged in transmission and
  coordinates the retransmission of those frames
  by the sender.
 In data link layer the term error control refers
  primarily to methods of error detection and
  retransmission.
 Any time an error is detected in an exchange
  specified frames are retransmitted.
 This process is called Automatic Repeat
  Request(ARQ).
FLOW AND ERROR CONTROL
           MECHANISMS
 Stop and Wait ARQ
 Go-Back N-ARQ

 Selective Repeat ARQ
STOP & WAIT ARQ
   The sending device keeps a copy of the last frame
    transmitted until it receives an
    acknowledgement for that frame.

   For identification purposes both data frames and
    acknowledgement (ACK) frames are numbered
    alternately 0 and 1.

   This numbering allows for identification of data
    frames in case duplicate transmission.
NORMAL OPERATION
STOP & WAIT ARQ CONT…
 The sender has a control variable which we call S
  that holds the number of the recently sent
  frame(0 or 1).
 The receiver has a control variable which we call
  R that holds the number of the next frame
  expected (0 or 1).
 The receiver sends only positive
  acknowledgements for frames received safe and
  sound.
 It is silent about the frames damaged or lost.

 The acknowledgement number always defines
  the number of the next expected frame.
DAMAGED OR LOST FRAME
   A damaged or lost frame is treated in the same
    manner by the receiver.

   If the receiver detects an error in the received
    frame, It simply discard the frame and sends no
    acknowledgement.

   If the receiver receives a frame that is out of
    order, It knows that the frame is lost.
DAMAGED OR LOST FRAME
              CONT…
   It discards the out of order received frame.

   The sender starts a timer when it sends a frame.

   If an acknowledgement is not received within an
    allotted time period, the sender assumes that the
    frame was lost or damaged and resends it.
LOST FRAME
LOST ACKNOWLEDGEMENT
 A lost or damaged acknowledgement is handled
  in the same way by the sender.
 If the sender receives a damaged
  acknowledgement ,it discards it.
 The waiting sender does not know if frame 1 has
  been received.
 When the timer for frame1 expires, the sender
  retransmits frame 1.
 The receiver has already received frame 1 and is
  expecting to receive frame 0(R=0),therefore it will
  silently discard the second copy of frame 1.
LOST ACKNOWLEDGEMENT
DELAYED ACKNOWLEDGEMENT
   An acknowledgement can be delayed at the
    receiver or by some problem with the link.
DELAYED ACKNOWLEDGEMENT
BIDIRECTIONAL TRANSMISSION
   The stop and wait mechanism we have discussed
    is unidirectional.

   However we have bidirectional transmission If
    the two parties have separate channels for full
    duplex transmission or share the same channel
    for half duplex transmission.

   In this case each party needs both S and R
    variables to track frames sent and expected.
PIGGYBACKING
   Piggybacking is a method to combine a data
    frame with an acknowledgement .
THANKS!!!

More Related Content

What's hot

Flow control and error control techniques in the data link layer protocol
Flow control and error control techniques in the data link layer protocolFlow control and error control techniques in the data link layer protocol
Flow control and error control techniques in the data link layer protocolmdmuaj
 
New framing-protocols
New framing-protocolsNew framing-protocols
New framing-protocolsNitesh Singh
 
Advance Repeat reQuest (ARQ)
Advance Repeat reQuest (ARQ)Advance Repeat reQuest (ARQ)
Advance Repeat reQuest (ARQ)Muhammad Irtiza
 
Data Link Control Protocols
Data Link Control ProtocolsData Link Control Protocols
Data Link Control ProtocolsTechiNerd
 
Data link control
Data link controlData link control
Data link controlIffat Anjum
 
Data link control & protocol concepts
Data link control & protocol conceptsData link control & protocol concepts
Data link control & protocol conceptsRaji Lakshmi
 
Simplex stop and_wait_protocol
Simplex stop and_wait_protocolSimplex stop and_wait_protocol
Simplex stop and_wait_protocolMusfira Ameer
 
Unit 4 data link layer
Unit 4 data link layerUnit 4 data link layer
Unit 4 data link layermekind
 
Unit 2 data link control
Unit 2 data link controlUnit 2 data link control
Unit 2 data link controlVishal kakade
 
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocolranakishi
 

What's hot (20)

Flow control and error control techniques in the data link layer protocol
Flow control and error control techniques in the data link layer protocolFlow control and error control techniques in the data link layer protocol
Flow control and error control techniques in the data link layer protocol
 
6 data linkcontrol
6  data linkcontrol6  data linkcontrol
6 data linkcontrol
 
Ch 11
Ch 11Ch 11
Ch 11
 
New framing-protocols
New framing-protocolsNew framing-protocols
New framing-protocols
 
Advance Repeat reQuest (ARQ)
Advance Repeat reQuest (ARQ)Advance Repeat reQuest (ARQ)
Advance Repeat reQuest (ARQ)
 
Data Link Control Protocols
Data Link Control ProtocolsData Link Control Protocols
Data Link Control Protocols
 
Data link control
Data link controlData link control
Data link control
 
Flow control
Flow controlFlow control
Flow control
 
Data link layer
Data link layerData link layer
Data link layer
 
Data link control & protocol concepts
Data link control & protocol conceptsData link control & protocol concepts
Data link control & protocol concepts
 
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocol
 
Simplex stop and_wait_protocol
Simplex stop and_wait_protocolSimplex stop and_wait_protocol
Simplex stop and_wait_protocol
 
Error control
Error controlError control
Error control
 
Chapter3
Chapter3Chapter3
Chapter3
 
Unit 4 data link layer
Unit 4 data link layerUnit 4 data link layer
Unit 4 data link layer
 
Data link layer tutorial
Data link layer tutorialData link layer tutorial
Data link layer tutorial
 
Unit 2 data link control
Unit 2 data link controlUnit 2 data link control
Unit 2 data link control
 
Go Back N Arq1
Go  Back N Arq1Go  Back N Arq1
Go Back N Arq1
 
Stop-and-Wait ARQ Protocol
Stop-and-Wait ARQ ProtocolStop-and-Wait ARQ Protocol
Stop-and-Wait ARQ Protocol
 
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocol
 

Viewers also liked (20)

Lecture 19
Lecture 19Lecture 19
Lecture 19
 
Lecture 06
Lecture 06Lecture 06
Lecture 06
 
Lecture 14
Lecture 14Lecture 14
Lecture 14
 
Lecture 15
Lecture 15Lecture 15
Lecture 15
 
Lecture 22
Lecture 22Lecture 22
Lecture 22
 
Lecture 03
Lecture 03Lecture 03
Lecture 03
 
Lecture 18
Lecture 18Lecture 18
Lecture 18
 
Lecture 12
Lecture 12Lecture 12
Lecture 12
 
Lecture 13
Lecture 13Lecture 13
Lecture 13
 
Lecture 07
Lecture 07Lecture 07
Lecture 07
 
Lecture 10
Lecture 10Lecture 10
Lecture 10
 
Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16
 
Lecture 21
Lecture 21Lecture 21
Lecture 21
 
Lecture 20
Lecture 20Lecture 20
Lecture 20
 
Lecture 17
Lecture 17Lecture 17
Lecture 17
 
Lecture 11
Lecture 11Lecture 11
Lecture 11
 
Data communication - Lecture-01
Data communication - Lecture-01 Data communication - Lecture-01
Data communication - Lecture-01
 
RTOS APPLICATIONS
RTOS  APPLICATIONSRTOS  APPLICATIONS
RTOS APPLICATIONS
 
Message Authentication: MAC, Hashes
Message Authentication: MAC, HashesMessage Authentication: MAC, Hashes
Message Authentication: MAC, Hashes
 
Data communications Class notes
Data communications  Class notesData communications  Class notes
Data communications Class notes
 

Similar to Lecture 23

Similar to Lecture 23 (20)

Presentation on dll
Presentation on dllPresentation on dll
Presentation on dll
 
session -7 - Sliding Window Protocol 1- N oisy Channels.ppt
session -7 - Sliding Window Protocol 1- N oisy Channels.pptsession -7 - Sliding Window Protocol 1- N oisy Channels.ppt
session -7 - Sliding Window Protocol 1- N oisy Channels.ppt
 
09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.ppt09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.ppt
 
Flowctrl
FlowctrlFlowctrl
Flowctrl
 
07 data linkcontrol
07 data linkcontrol07 data linkcontrol
07 data linkcontrol
 
Unit IV_Flow.pptx
Unit IV_Flow.pptxUnit IV_Flow.pptx
Unit IV_Flow.pptx
 
PROTOCOL ICT.pptx
PROTOCOL ICT.pptxPROTOCOL ICT.pptx
PROTOCOL ICT.pptx
 
DATA LINK LAYER.pdf
DATA LINK LAYER.pdfDATA LINK LAYER.pdf
DATA LINK LAYER.pdf
 
Micro project on ARQ
Micro project on ARQMicro project on ARQ
Micro project on ARQ
 
stop and wait
stop and waitstop and wait
stop and wait
 
Flow control & error control
Flow control & error controlFlow control & error control
Flow control & error control
 
Different protocols for data communication networks
Different protocols for data communication networks Different protocols for data communication networks
Different protocols for data communication networks
 
8th lec flow and error control
8th lec   flow and error control8th lec   flow and error control
8th lec flow and error control
 
DATA LINK CONTROL.pptx
DATA LINK CONTROL.pptxDATA LINK CONTROL.pptx
DATA LINK CONTROL.pptx
 
computer network
computer networkcomputer network
computer network
 
Data link layer (Unit 2).pdf
Data link layer (Unit 2).pdfData link layer (Unit 2).pdf
Data link layer (Unit 2).pdf
 
07 data linkcontrol
07 data linkcontrol07 data linkcontrol
07 data linkcontrol
 
Flow & Error Control
Flow & Error ControlFlow & Error Control
Flow & Error Control
 
Flow control main
Flow control mainFlow control main
Flow control main
 
Flow Control (1).ppt
Flow Control (1).pptFlow Control (1).ppt
Flow Control (1).ppt
 

More from Sehrish Rafiq

Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14Sehrish Rafiq
 
Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13Sehrish Rafiq
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Sehrish Rafiq
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Sehrish Rafiq
 
Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10Sehrish Rafiq
 
Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9Sehrish Rafiq
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Sehrish Rafiq
 
Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7Sehrish Rafiq
 
Introduction to computers Lecture # 4
Introduction to computers Lecture # 4Introduction to computers Lecture # 4
Introduction to computers Lecture # 4Sehrish Rafiq
 
Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5Sehrish Rafiq
 
Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3Sehrish Rafiq
 
Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2Sehrish Rafiq
 
Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1Sehrish Rafiq
 

More from Sehrish Rafiq (13)

Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14
 
Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11
 
Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10
 
Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8
 
Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7
 
Introduction to computers Lecture # 4
Introduction to computers Lecture # 4Introduction to computers Lecture # 4
Introduction to computers Lecture # 4
 
Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5
 
Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3
 
Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2
 
Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1
 

Recently uploaded

A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Celine George
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 

Recently uploaded (20)

A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 

Lecture 23

  • 1. DATA COMMUNICATIONS & NETWORKING LECTURE- 23 Course Instructor : Sehrish Rafiq Department Of Computer Science University Of Peshawar
  • 2. LECTURE OVERVIEW  Flow Control  Error Control  Stop &Wait ARQ
  • 3. DATA LINK CONTROL  The most important responsibilities of the data link layer are flow control and error control.  Collectively ,these functions are known as datalink control.
  • 4. FLOW CONTROL  Flow control coordinates the amount of data that can be sent before receiving acknowledgement and is one of the most important duties of the data link layer.  In most cases flow control is a set of procedures that tells the sender how much data it can transmit before it must wait for an acknowledgement from the receiver.  The flow of data must not be allowed to overwhelm the receiver.
  • 5. WHY WE NEED FLOW CONTROL???  Any receiving device has a limited speed at which it can process incoming data and a limited amount of memory in which to store incoming data.  The receiving device must be able to inform the sending device before that limit is reached.  And to request that the transmitting device send fewer frames or stop temporarily.  Incoming data must be checked and processed before they can be used.  The rate of such processing is slower than the rate of transmission.
  • 6. ERROR CONTROL  Error control is both error detection and error correction.  It allows the receiver to inform the sender of any frames lost or damaged in transmission and coordinates the retransmission of those frames by the sender.  In data link layer the term error control refers primarily to methods of error detection and retransmission.  Any time an error is detected in an exchange specified frames are retransmitted.  This process is called Automatic Repeat Request(ARQ).
  • 7. FLOW AND ERROR CONTROL MECHANISMS  Stop and Wait ARQ  Go-Back N-ARQ  Selective Repeat ARQ
  • 8. STOP & WAIT ARQ  The sending device keeps a copy of the last frame transmitted until it receives an acknowledgement for that frame.  For identification purposes both data frames and acknowledgement (ACK) frames are numbered alternately 0 and 1.  This numbering allows for identification of data frames in case duplicate transmission.
  • 10. STOP & WAIT ARQ CONT…  The sender has a control variable which we call S that holds the number of the recently sent frame(0 or 1).  The receiver has a control variable which we call R that holds the number of the next frame expected (0 or 1).  The receiver sends only positive acknowledgements for frames received safe and sound.  It is silent about the frames damaged or lost.  The acknowledgement number always defines the number of the next expected frame.
  • 11. DAMAGED OR LOST FRAME  A damaged or lost frame is treated in the same manner by the receiver.  If the receiver detects an error in the received frame, It simply discard the frame and sends no acknowledgement.  If the receiver receives a frame that is out of order, It knows that the frame is lost.
  • 12. DAMAGED OR LOST FRAME CONT…  It discards the out of order received frame.  The sender starts a timer when it sends a frame.  If an acknowledgement is not received within an allotted time period, the sender assumes that the frame was lost or damaged and resends it.
  • 14. LOST ACKNOWLEDGEMENT  A lost or damaged acknowledgement is handled in the same way by the sender.  If the sender receives a damaged acknowledgement ,it discards it.  The waiting sender does not know if frame 1 has been received.  When the timer for frame1 expires, the sender retransmits frame 1.  The receiver has already received frame 1 and is expecting to receive frame 0(R=0),therefore it will silently discard the second copy of frame 1.
  • 16. DELAYED ACKNOWLEDGEMENT  An acknowledgement can be delayed at the receiver or by some problem with the link.
  • 18. BIDIRECTIONAL TRANSMISSION  The stop and wait mechanism we have discussed is unidirectional.  However we have bidirectional transmission If the two parties have separate channels for full duplex transmission or share the same channel for half duplex transmission.  In this case each party needs both S and R variables to track frames sent and expected.
  • 19. PIGGYBACKING  Piggybacking is a method to combine a data frame with an acknowledgement .