Open In App

Stop and Wait ARQ

Characteristics

Useful Terms:

Propagation Delay = (Distance between routers) / (Velocity of propagation)

Simple Stop and Wait

Sender:

Rule 1) Send one data packet at a time. 
Rule 2) Send the next packet only after receiving acknowledgement for the previous. 
 



Receiver:

Rule 1) Send acknowledgement after receiving and consuming a data packet. 
Rule 2) After consuming packet acknowledgement need to be sent (Flow Control) 

  
 



 

Problems :

1. Lost Data 
 

2. Lost Acknowledgement: 
 

3. Delayed Acknowledgement/Data: After a timeout on the sender side, a long-delayed acknowledgement might be wrongly considered as acknowledgement of some other recent packet. 

 

Stop and Wait for ARQ (Automatic Repeat Request)

The above 3 problems are resolved by Stop and Wait for ARQ (Automatic Repeat Request) that does both error control and flow control. 
 

1. Time Out: 
 

2. Sequence Number (Data) 
 

3. Delayed Acknowledgement: 
This is resolved by introducing sequence numbers for acknowledgement also. 
 

Working of Stop and Wait for ARQ:

1) Sender A sends a data frame or packet with sequence number 0. 
2) Receiver B, after receiving the data frame, sends an acknowledgement with sequence number 1 (the sequence number of the next expected data frame or packet) 
There is only a one-bit sequence number that implies that both sender and receiver have a buffer for one frame or packet only. 

 

 

Characteristics of Stop and Wait ARQ:

Constraints:

Stop and Wait ARQ has very less efficiency , it can be improved by increasing the window size. Also , for better efficiency , Go back N and Selective Repeat Protocols are used.

The Stop and Wait ARQ solves the main three problems but may cause big performance issues as the sender always waits for acknowledgement even if it has the next packet ready to send. Consider a situation where you have a high bandwidth connection and propagation delay is also high (you are connected to some server in some other country through a high-speed connection). To solve this problem, we can send more than one packet at a time with a larger sequence number. We will be discussing these protocols in the next articles. 

So Stop and Wait ARQ may work fine where propagation delay is very less for example LAN connections but performs badly for distant connections like satellite connections. 

Advantages of Stop and Wait ARQ :

Disadvantages of Stop and Wait ARQ :

  
References: 

This Article is contributed by G. Shabharesh.

Article Tags :