# What are noiseless and noisy channels?

Data link layer protocols are divided into two categories based on whether the transmission channel is noiseless or noisy.

The data link layer protocol is diagrammatically represented below −

## Noiseless Channels

There are two noiseless channels which are as follows −

• Simplex channel
• Stop & wait channel

Let us consider an ideal channel where no frames are lost, duplicated, or corrupted. We introduce two protocols for this type of channel. These two protocols are as follows −

• Protocol that does not use flow control.
• Protocol that uses the flow control.

Now let us consider the Protocols that do not use flow control −

## Simplest Protocol

Step 1 − Simplest protocol that does not have flow or error control.

Step 2 − It is a unidirectional protocol where data frames are traveling in one direction that is from the sender to receiver.

Step 3 − Let us assume that the receiver can handle any frame it receives with a processing time that is small enough to be negligible, the data link layer of the receiver immediately removes the header from the frame and hands the data packet to its network layer, which can also accept the packet immediately.

## Stop-and-Wait Protocol

Step 1 − If the data frames that arrive at the receiver side are faster than they can be processed, the frames must be stored until their use.

Step 2 − Generally, the receiver does not have enough storage space, especially if it is receiving data from many sources. This may result in either discarding of frames or denial of service.

Step 3 − To prevent the receiver from becoming overwhelmed with frames, the sender must slow down. There must be ACK from the receiver to the sender.

Step 4 − In this protocol the sender sends one frame, stops until it receives confirmation from the receiver, and then sends the next frame.

Step 5 − We still have unidirectional communication for data frames, but auxiliary ACK frames travel from the other direction. We add flow control to the previous protocol.

## Noisy Channels

There are three types of requests for the noisy channels, which are as follows −

• Stop & wait Automatic Repeat Request.
• Go-Back-N Automatic Repeat Request.
• Selective Repeat Automatic Repeat Request.

Noiseless channels are generally non-existent channels. We can ignore the error or we need to add error control to our protocols.

## Stop and Wait Automatic Repeat Request

Step 1 − In a noisy channel, if a frame is damaged during transmission, the receiver will detect with the help of the checksum.

Step 2 − If a damaged frame is received, it will be discarded, and the transmitter will retransmit the same frame after receiving a proper acknowledgement.

Step 3 − If the acknowledgement frame gets lost and the data link layer on 'A' eventually times out. Not having received an ACK, it assumes that its data frame was lost or damaged and sends the frame containing packet 1 again. This duplicate frame also arrives at the data link layer on 'B', thus part of the file will be duplicated and protocol is said to be failed.

Step 4 − To solve this problem, assign a sequence number in the header of the message.

Step 5 − The receiver checks the sequence number to determine if the message is a duplicate since only the message is transmitted at any time.

Step 6 − The sending and receiving station needs only a 1-bit alternating sequence of '0' or '1' to maintain the relationship of the transmitted message and its ACK/ NAK.

Step 7 − A modulo-2 numbering scheme is used where the frames are alternatively labelled with '0' or '1' and positive acknowledgements are of the form ACK 0 and ACK 1.

Normal operation of Stop & Wait ARQ is given below −

Stop & Wait ARQ with Lost frame is as follows −

## Go-Back-N ARQ

To improve the transmission efficiency, we need more than one frame to be outstanding to keep the channel busy while the sender is waiting for acknowledgement.

There are two protocols developed for achieving this goal and they are as follows −

• Go – Back - N – Automatic – Repeat Request
• Sliding window protocol

### Go-Back-N ARQ

Step 1 − In this protocol we can send several frames before receiving acknowledgements.

Step 2 − we keep a copy of these frames until the acknowledgment arrives.

Step 3 − Frames from a sending station are numbered sequentially. However, we need to include the sequence number of each frame in the header; we need to set a limit.

Step 4 − If the header of the frame allows m bits for the sequence number, the sequence numbers range from 0 to 2m-1. We can also repeat the sequence numbers.

### Example

For m = 2, the range of sequence numbers is: 0 to 3, i.e.

0,1,2,3, 0,1,2,3,…

The Go-Back-N ARQ is shown below in diagram format −

### Example

Given below is an example problem on noiseless and noisy channel

Problem − Consider a binary signal sent over 4 KHZ wide channel, find out the maximum data rate for noiseless and a noisy channel whose signal to noise ratio is 20dB.

### Solution

Maximum Data Rate for noiseless = 2 * Bandwidth * log2(2)
=> 2 * 4khz * log2(2)
= 2*4000
= 8000 bps
Maximum Data Rate for noisy = Channel Capacity * log2(1 + SNR)
= 4000 * log2(1 + 20)
= 4000 * 4.39 = 17569.269 bps