Stop-and-Wait ARQ

The primary purpose of the Stop-and-Wait ARQ Protocol is to ensure that each data packet sent by the sender is received and acknowledged by the receiver before the next packet is sent. This acknowledgment-based approach allows for error detection and recovery, ensuring the integrity and reliability of the transmitted data.

What is the Stop and Wait ARQ?

    \[Stop \hspace{0.1cm} and  \hspace{0.1cm} Wait\hspace{0.1cm}  ARQ = Stop \hspace{0.1cm} and  \hspace{0.1cm}Wait \hspace{0.1cm}+ \hspace{0.1cm}Timeout\hspace{0.1cm}  Timer \hspace{0.1cm}+ \hspace{0.1cm}Sequence \hspace{0.1cm} Numbers.\]

Let’s look at various scenarios:

Scenario 1: Sender receives acknowledgement before timeout.

Stop and Wait ARQ. Sender  receives acknowledgement before timeout.

This is the ideal scenario. Sender sends the frame and starts it’s timeout timer. The frame is received timely by the recevier and an acknowledgement is sent. Sender receives the acknowledgement before it’s timeout timer expires. It then transmits the next frame.

Scenario 2: The Frame sent by the sender is lost.

Stop and Wait ARQ. The Frame sent by the sender is lost.

In this case:

  • The sender sends the frame and starts the timeout timer.
  • Frame gets lost in transmission. It is not received by the receiver. Hence, no acknowledgement is sent.
  • The sender waits for the acknowledgement.
  • Timeout period expires. Sender retransmits the data frame.
  • Receiver receives the data frame and sends acknowledgement.
  • Acknowledgement is received before the timeout timer expires.

Scenario 3: The acknowledgement is lost.

Stop and Wait ARQ. The Acknowledgement sent by the receiver is lost.

In this case:

  • The sender sends the frame and starts the timeout timer.
  • Receiver receives the frame and sends the acknowledgement.
  • The acknowledgement gets lost in transmission.
  • The sender waits for the acknowledgement.
  • Timeout period expires. Sender retransmits the data frame.
  • Receiver receives the data frame. It uses the frame’s sequence number and realises that it is the same frame. It discards this frame and resends the acknowledgement.
  • Acknowledgement is received before the timeout timer expires.

Scenario 4: The acknowledgement is received after the timeout expires.

Stop and Wait ARQ. The acknowledgement is received after the timeout expires.

In this case:

  • The sender sends the frame and starts the timeout timer.
  • Receiver receives the frame and sends the acknowledgement.
  • The sender waits for the acknowledgement.
  • The acknowledgement arrives late. Timeout period expires. Sender retransmits the data frame.
  • Receiver receives the data frame. It uses the frame’s sequence number and realises that it is the same frame. It discards this frame and resends the acknowledgement.

Characterstics of Stop and Wait ARQ

  • ARQ stands for Automatic Repeat Request.
  • Only one frame is transmitted at a time
  • Sender Window Size = 1
  • Receiver Window Size = 1
  • Propagation Delay : Amount of time taken taken by frame to travel from one router to another.

    \[Propagation \hspace{0.1cm}Delay = (Distance\hspace{0.1cm} between\hspace{0.1cm} Routers)/(Velocity\hspace{0.1cm} of \hspace{0.1cm}Propagation)\]

  • Round Trip Time = 2 * Propagation Delay
  • Efficiency (η) is the ratio of the transmission time to the total time. The total time in this case is the sum of the transmission time and the round trip time.

    \[Efficiency (η) = Transmission \hspace{0.1cm}Time/(Transmission\hspace{0.1cm} Time \hspace{0.1cm}+ \hspace{0.1cm}Round\hspace{0.1cm} Trip\hspace{0.1cm} Time)\]

  • In stop and wait, this efficiency is extremely low when compared to other protocols like Go Back N and Selective Repeat. This is due to the waiting time introduced after each frame transmission. Thus, stop-and-wait is more suitable for scenarios where reliability is prioritized over throughput.
  • Retransmission = 1
  • Number of available sequence numbers in this protocol are 2.

Advantages of Stop-and-Wait ARQ:

The Stop-and-Wait ARQ Protocol offers several advantages in network communication:

Simplicity and Ease of Implementation

The protocol’s simplicity makes it relatively easy to understand and implement in various network environments, making it suitable for basic communication needs.

Error Detection and Recovery

The acknowledgment-based mechanism of the protocol allows for error detection. If the sender does not receive an acknowledgment within the timeout period, it assumes the packet was lost or corrupted and initiates retransmission, ensuring reliable data delivery.

Ensuring Sequential Delivery

The protocol guarantees that data packets are delivered sequentially. This feature is beneficial in applications where the order of data packets is crucial, such as streaming multimedia or file transfers.

Limitations of Stop-and-Wait ARQ:

Low Efficiency and Throughput:

The protocol operates in a stop-and-wait manner, where the sender must wait for acknowledgment before sending the next packet. This results in lower efficiency and reduced data throughput, especially in high-speed networks.

Increased Latency:

The round-trip time (RTT) for each packet, including transmission and acknowledgment, contributes to increased latency. This latency can affect real-time applications that require minimal delays, such as voice and video communication.

Inefficiency in High Bandwidth-Delay Networks:

In networks with high bandwidth and significant delays, the Stop-and-Wait Protocol may underutilize the available bandwidth, leading to decreased network efficiency.

In summary, the stop-and-wait ARQ protocol ensures reliable data transmission, as it guarantees that each frame is acknowledged before the next frame is sent. However, it can result in inefficiencies and reduced throughput due to the inherent waiting time.

Leave a Comment

Your email address will not be published. Required fields are marked *