SlideShare une entreprise Scribd logo
1  sur  15
SlidingSliding WindoWWindoW
ProtocolProtocol
(1 bit protocol)(1 bit protocol)
By : W.M.L.S.Abeythunga
A.A.D.S Nirmani
2010/ICT/12
2010/ICT/23
Content
• • Communication
• • Sliding Window Protocol
• • Key concepts
• • Piggybacking
• • Sender Side
• • Receiver Side
• • One bit Sliding Window
• • Merits & demerits
Communication ……
Sliding Window Protocol
• Sliding window algorithms are a method of flow
control for network data transfers.
• Data Link Layer uses a sliding window algorithm,
which allows a sender to have more than one
unacknowledged packet "in flight" at a time,
which improves network throughput.
Key concepts of the Sliding
Window
• Both the sender and receiver maintain a finite size buffer to hold
outgoing and incoming packets from the other side.
• Every packet sent by the sender, must be acknowledged by the
receiver. The sender maintains a timer for every packet sent, and
any packet unacknowledged in a certain time, is resent.
• The sender may send a whole window of packets before
receiving an acknowledgement for the first packet in the window.
This results in higher transfer rates, as the sender may send
multiple packets without waiting for each packet's
acknowledgement.
• The Receiver advertises a window size that tells the sender how
much data it can receive, in order for the sender not to fill up the
receivers buffers.
• Efficiency can also be improved by making use of the full-duplex
line
A B
Sliding Window
Piggybacking
• when a data frame arrives, instead of immediately
sending a separate control frame, the receiver restrains
itself and waits until the network layer passes it to the next
packet.
• The acknowledgement is attached to the outgoing data
frame (using the ack field in the frame header).
• The acknowledgement gets a free ride on the next
outgoing data frame.
• The technique of temporarily delaying outgoing
acknowledgements so they can be hooked onto the next
out going data frame is piggybacking
Sender Side
• To keep track of the frames, sender station sends sequentially
numbered frames.
• Since the sequence number to be used occupies a field in the
frame, it should be limited size.
• If the header of the frame allows k bits, the sequence numbers
range from 0 to 2k
– 1.
• Sender maintains a list of sequence numbers that it is allowed to
send(sender window).
• The size of the senders window is at most 2k
– 1.
– Eg:- if frame allows 3 bits, then the size of the window is
23
-1=7
• The sender is provided with a buffer equal to the window size.
0 1 2 3 4 5 6
Receiver Side
• Receiver always maintains window size as 1.
• The receiver acknowledges a frame by sending an ACK frame
that includes the sequence number of the next frame expected.
• This also explicitly announces that it is prepared to receive the
next N frames, beginning with the number specified.
• This scheme can be used to acknowledge multiple frames.
• It could receive frames 2,3,4 but withhold ACK until frame 4 has
arrived. By returning an ACK with sequence number 5, it
acknowledges frames 2, 3, 4 at one time.
• The receiver needs a buffer of size 1.
One bit Sliding Window
• Here K=1 at the senders side.
• Then the size of the senders window is,
2k
– 1
K=1
21
-1=2-1=1
• This is same as the stop and wait protocol.
-A sliding window of size 1, with a 3-bit sequence number-
(a) Initially.
(b) After the first frame has been sent.
(c) After the first frame has been received.
(d) After the first acknowledgement has been received.
One bit Sliding Window protocol
• The notation is (seq, ack, packet number).
Part (a): If B waits for A’s first frame before sending one of its own. Each frame
arrival brings a new packet for the network layer; there are no duplicates.
Part (b): If A and B simultaneously initiate communication, their first frames
cross, and the data link layers gets into a situation. Half of the frames contain
duplicates, even though there are no transmission errors
Merits
• Multiple packets can be transmit without waiting for
acknowledgements.(not like stop & wait)
• Piggibacking (using full-duplex lines)
Demerits
• No limit of the size or sequence numbers that can be
required in this protocol.
• The bandwidth may be wasted in some special situations.
Reference
• Sliding window animation reference:
www.youtube.com/watch?v=zY3Sxvj8kZA
ThankThank
You !You !

Contenu connexe

Tendances

Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And CorrectionRenu Kewalramani
 
Sliding window protocol(ARQ technique)
Sliding window protocol(ARQ technique)Sliding window protocol(ARQ technique)
Sliding window protocol(ARQ technique)shilpa patel
 
Congestion control
Congestion controlCongestion control
Congestion controlAman Jaiswal
 
What Is Sliding Window Protocol?
What Is Sliding Window Protocol?What Is Sliding Window Protocol?
What Is Sliding Window Protocol?Simplilearn
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)k33a
 
Network Layer design Issues.pptx
Network Layer design Issues.pptxNetwork Layer design Issues.pptx
Network Layer design Issues.pptxAcad
 
Guided Transmission Media
Guided Transmission MediaGuided Transmission Media
Guided Transmission Mediaasrabatool
 
Design issues for the layers
Design issues for the layersDesign issues for the layers
Design issues for the layersjayaprakash
 
Leaky Bucket & Tocken Bucket - Traffic shaping
Leaky Bucket & Tocken Bucket - Traffic shapingLeaky Bucket & Tocken Bucket - Traffic shaping
Leaky Bucket & Tocken Bucket - Traffic shapingVimal Dewangan
 

Tendances (20)

Osi reference model
Osi reference modelOsi reference model
Osi reference model
 
Issues in Data Link Layer
Issues in Data Link LayerIssues in Data Link Layer
Issues in Data Link Layer
 
Transport layer
Transport layerTransport layer
Transport layer
 
Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And Correction
 
Sliding window protocol(ARQ technique)
Sliding window protocol(ARQ technique)Sliding window protocol(ARQ technique)
Sliding window protocol(ARQ technique)
 
Congestion control
Congestion controlCongestion control
Congestion control
 
Osi model
Osi modelOsi model
Osi model
 
What Is Sliding Window Protocol?
What Is Sliding Window Protocol?What Is Sliding Window Protocol?
What Is Sliding Window Protocol?
 
Framing Protocols
Framing ProtocolsFraming Protocols
Framing Protocols
 
Network layer tanenbaum
Network layer tanenbaumNetwork layer tanenbaum
Network layer tanenbaum
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)
 
Stop and-wait protocol
Stop and-wait protocolStop and-wait protocol
Stop and-wait protocol
 
OSI Model
OSI ModelOSI Model
OSI Model
 
Network Layer design Issues.pptx
Network Layer design Issues.pptxNetwork Layer design Issues.pptx
Network Layer design Issues.pptx
 
Guided Transmission Media
Guided Transmission MediaGuided Transmission Media
Guided Transmission Media
 
System calls
System callsSystem calls
System calls
 
Application Layer
Application Layer Application Layer
Application Layer
 
go back n protocol
go back n protocolgo back n protocol
go back n protocol
 
Design issues for the layers
Design issues for the layersDesign issues for the layers
Design issues for the layers
 
Leaky Bucket & Tocken Bucket - Traffic shaping
Leaky Bucket & Tocken Bucket - Traffic shapingLeaky Bucket & Tocken Bucket - Traffic shaping
Leaky Bucket & Tocken Bucket - Traffic shaping
 

Similaire à Sliding window protocol

Different protocols for data communication networks
Different protocols for data communication networks Different protocols for data communication networks
Different protocols for data communication networks Nt Arvind
 
PCCN DATA LINK LAYER UNIT 4 NOTES
PCCN DATA LINK LAYER UNIT 4 NOTESPCCN DATA LINK LAYER UNIT 4 NOTES
PCCN DATA LINK LAYER UNIT 4 NOTESsirishayerraboina
 
Computer Networks Module 2.pdf
Computer Networks Module 2.pdfComputer Networks Module 2.pdf
Computer Networks Module 2.pdfShanthalaKV
 
Data link layer elementry protocols
Data link layer elementry protocolsData link layer elementry protocols
Data link layer elementry protocolssabitha sairam
 
Unit IV_Flow.pptx
Unit IV_Flow.pptxUnit IV_Flow.pptx
Unit IV_Flow.pptxTejasRao8
 
Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control gondwe Ben
 
New framing-protocols
New framing-protocolsNew framing-protocols
New framing-protocolsNitesh Singh
 
Datalink control(framing,protocols)
Datalink control(framing,protocols)Datalink control(framing,protocols)
Datalink control(framing,protocols)Hira Awan
 
Data Link Control Protocols
Data Link Control ProtocolsData Link Control Protocols
Data Link Control ProtocolsTechiNerd
 
Dcn ppt by roma
Dcn ppt by romaDcn ppt by roma
Dcn ppt by romaboraroma
 
Dcn ppt on data link layer
Dcn ppt on data link layerDcn ppt on data link layer
Dcn ppt on data link layerroma bora
 
09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.ppt09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.pptShaliniKumariGupta1
 
Module 2.pptx.............sdvsdcdssdfsdf
Module 2.pptx.............sdvsdcdssdfsdfModule 2.pptx.............sdvsdcdssdfsdf
Module 2.pptx.............sdvsdcdssdfsdfShivakrishnan18
 

Similaire à Sliding window protocol (20)

Different protocols for data communication networks
Different protocols for data communication networks Different protocols for data communication networks
Different protocols for data communication networks
 
PCCN DATA LINK LAYER UNIT 4 NOTES
PCCN DATA LINK LAYER UNIT 4 NOTESPCCN DATA LINK LAYER UNIT 4 NOTES
PCCN DATA LINK LAYER UNIT 4 NOTES
 
Go back.pptx
Go back.pptxGo back.pptx
Go back.pptx
 
Flow Control.pptx
Flow Control.pptxFlow Control.pptx
Flow Control.pptx
 
Computer Networks Module 2.pdf
Computer Networks Module 2.pdfComputer Networks Module 2.pdf
Computer Networks Module 2.pdf
 
Data link layer elementry protocols
Data link layer elementry protocolsData link layer elementry protocols
Data link layer elementry protocols
 
Unit IV_Flow.pptx
Unit IV_Flow.pptxUnit IV_Flow.pptx
Unit IV_Flow.pptx
 
Data link layer (Unit 2).pdf
Data link layer (Unit 2).pdfData link layer (Unit 2).pdf
Data link layer (Unit 2).pdf
 
Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control
 
Nigga.pdf
Nigga.pdfNigga.pdf
Nigga.pdf
 
Flow control main
Flow control mainFlow control main
Flow control main
 
New framing-protocols
New framing-protocolsNew framing-protocols
New framing-protocols
 
Datalink control(framing,protocols)
Datalink control(framing,protocols)Datalink control(framing,protocols)
Datalink control(framing,protocols)
 
Data Link Control Protocols
Data Link Control ProtocolsData Link Control Protocols
Data Link Control Protocols
 
Transport layer
Transport layerTransport layer
Transport layer
 
Dcn ppt by roma
Dcn ppt by romaDcn ppt by roma
Dcn ppt by roma
 
Dcn ppt on data link layer
Dcn ppt on data link layerDcn ppt on data link layer
Dcn ppt on data link layer
 
09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.ppt09 Data Link LayerFlow Control.ppt
09 Data Link LayerFlow Control.ppt
 
Module 2.pptx.............sdvsdcdssdfsdf
Module 2.pptx.............sdvsdcdssdfsdfModule 2.pptx.............sdvsdcdssdfsdf
Module 2.pptx.............sdvsdcdssdfsdf
 
Error control
Error controlError control
Error control
 

Dernier

Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integrationmarketing932765
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observabilityitnewsafrica
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Nikki Chapple
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...itnewsafrica
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Strongerpanagenda
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 

Dernier (20)

Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 

Sliding window protocol

  • 1. SlidingSliding WindoWWindoW ProtocolProtocol (1 bit protocol)(1 bit protocol) By : W.M.L.S.Abeythunga A.A.D.S Nirmani 2010/ICT/12 2010/ICT/23
  • 2. Content • • Communication • • Sliding Window Protocol • • Key concepts • • Piggybacking • • Sender Side • • Receiver Side • • One bit Sliding Window • • Merits & demerits
  • 4. Sliding Window Protocol • Sliding window algorithms are a method of flow control for network data transfers. • Data Link Layer uses a sliding window algorithm, which allows a sender to have more than one unacknowledged packet "in flight" at a time, which improves network throughput.
  • 5. Key concepts of the Sliding Window • Both the sender and receiver maintain a finite size buffer to hold outgoing and incoming packets from the other side. • Every packet sent by the sender, must be acknowledged by the receiver. The sender maintains a timer for every packet sent, and any packet unacknowledged in a certain time, is resent. • The sender may send a whole window of packets before receiving an acknowledgement for the first packet in the window. This results in higher transfer rates, as the sender may send multiple packets without waiting for each packet's acknowledgement. • The Receiver advertises a window size that tells the sender how much data it can receive, in order for the sender not to fill up the receivers buffers. • Efficiency can also be improved by making use of the full-duplex line A B
  • 7. Piggybacking • when a data frame arrives, instead of immediately sending a separate control frame, the receiver restrains itself and waits until the network layer passes it to the next packet. • The acknowledgement is attached to the outgoing data frame (using the ack field in the frame header). • The acknowledgement gets a free ride on the next outgoing data frame. • The technique of temporarily delaying outgoing acknowledgements so they can be hooked onto the next out going data frame is piggybacking
  • 8. Sender Side • To keep track of the frames, sender station sends sequentially numbered frames. • Since the sequence number to be used occupies a field in the frame, it should be limited size. • If the header of the frame allows k bits, the sequence numbers range from 0 to 2k – 1. • Sender maintains a list of sequence numbers that it is allowed to send(sender window). • The size of the senders window is at most 2k – 1. – Eg:- if frame allows 3 bits, then the size of the window is 23 -1=7 • The sender is provided with a buffer equal to the window size. 0 1 2 3 4 5 6
  • 9. Receiver Side • Receiver always maintains window size as 1. • The receiver acknowledges a frame by sending an ACK frame that includes the sequence number of the next frame expected. • This also explicitly announces that it is prepared to receive the next N frames, beginning with the number specified. • This scheme can be used to acknowledge multiple frames. • It could receive frames 2,3,4 but withhold ACK until frame 4 has arrived. By returning an ACK with sequence number 5, it acknowledges frames 2, 3, 4 at one time. • The receiver needs a buffer of size 1.
  • 10. One bit Sliding Window • Here K=1 at the senders side. • Then the size of the senders window is, 2k – 1 K=1 21 -1=2-1=1 • This is same as the stop and wait protocol.
  • 11. -A sliding window of size 1, with a 3-bit sequence number- (a) Initially. (b) After the first frame has been sent. (c) After the first frame has been received. (d) After the first acknowledgement has been received.
  • 12. One bit Sliding Window protocol • The notation is (seq, ack, packet number). Part (a): If B waits for A’s first frame before sending one of its own. Each frame arrival brings a new packet for the network layer; there are no duplicates. Part (b): If A and B simultaneously initiate communication, their first frames cross, and the data link layers gets into a situation. Half of the frames contain duplicates, even though there are no transmission errors
  • 13. Merits • Multiple packets can be transmit without waiting for acknowledgements.(not like stop & wait) • Piggibacking (using full-duplex lines) Demerits • No limit of the size or sequence numbers that can be required in this protocol. • The bandwidth may be wasted in some special situations.
  • 14. Reference • Sliding window animation reference: www.youtube.com/watch?v=zY3Sxvj8kZA