Data Link Layer of Modems

Data Transparency
A modem uses the bit-oriented protocol for its frames. So bit stuffing is required to differentiate the data being transmitted from the flag bit sequence. The bit stuffing imposes an overhead of up to 20%. This is much better than byte stuffing, which could double the number of bytes to be transmitted.

Data Transmission
All modern modems are full-duplex (since the V.21 standard).

Error Detection/Correction
Today's modems use a Cyclical Redundancy Check (CRC) for error detection. In this check, an N must be chosen, and that is used for the polynomial checking sequence. The CRC will detect all single-bit errors, most double-bit errors, and most errors where the number of bits in error is odd. CRC will also detect all burst errors where the burst length is less than N. It will detect most where the burst length is greater than or equal to N. Thus, in order to detect as many errors as possible, the N should be chosen to be larger than the expected burst length.

Once errors are detected, they need to be corrected. The phone system uses a Selective Repeat Request. In this case, the information frames are sent to the receiver with a sequence number attached. This lets the receiver know what frames it should have received so far. If the receiver gets a frame out of order, it will send notification to the sender about that, and the sender will retransmit that frame only. The receiver also sends acknowledgements for frames receives, so in the case where the sender transmits a frame and receives nothing back, it will automatically retransmit after a certain time has elapsed. This assures that all the data that is meant to be transmitted actually arrives successfully.

Flow Control
Some modems use the X-ON/X-OFF flow control protocol. In this protocol, an X-ON control character (DC1 -- ASCII code 17) is transmitted. When received, the recipient knows that it can send data. Data continues to be transmitted until an X-OFF (DC3 -- ASCII code 19) is received. That tells the station sending data that the one receiving data is filling up, and can't take any more data. So that transmission stops until another X-ON is received. Of course, this flow control occurs the same in both directions, since it is a full-duplex system.

However, putting control characters in the data stream can cause problems. The control characters may appear in binary data, which will stop the data transfer unexpectedly. To avoid this, a flow control called RTS/CTS (Request to Send/Clear to Send). These are pins that are on the connector and signals are sent through these when the transmission should be stopped or started.

Data Compression/Coding
The only type of data compression that the modem itself can do is lossless compression. This type of compression allows the original data to be reconstructed perfectly once it is received. It is most successful for text-based information, since most binary information, especially images, sounds, movies, etc. have already had lossy compression applied to them, so further compression for documents of that type is not really possible.

Modems use ASCII character encoding. In order to code the ASCII characters into less than 7 bits, an encoding technique, such as Huffman coding, is used. Huffman coding makes the codes shorter for more common characters (2 or 3 bits long, as opposed to 7 bits).


Home Previous Next