Concept: Go-Back-N ARQ is a sliding window protocol that allows the sender to transmit multiple frames before needing an acknowledgment (ACK) β improving efficiency.
πΉ How It Works
- Sender Window (N): The sender can send up to N unacknowledged frames.
- ACK Mechanism: The receiver sends cumulative ACKs β e.g., ACK 4 means it has received frames 0-4 correctly.
- Timeout: If no ACK arrives for the oldest unacknowledged frame, the sender retransmits all frames from that frame onwards.
- Loss Handling: You can simulate losses or delays for both frames and ACKs to observe the protocolβs behavior.
π Real-World Example
Imagine sending 10 data packets with a window size of 4.
Frames 0β3 are sent. If frame 2 is lost, the receiver only ACKs up to 1.
When timeout occurs, the sender retransmits from frame 2 β onward.