Data-Link-Layer Design Issue
Data-Link-Layer Design Issue
• Data bits are encoded, decoded and organized in the data link layer,
before they are transported as frames between two adjacent nodes on
the same LAN or WAN.
• The data link layer also determines how devices recover from collisions
that may occur when nodes attempt to send frames at the same time.
• The data link layer has two sublayers: the logical link control (LLC)
sublayer and the media access control (MAC) sublayer.
Framing in Data Link Layer
Data-link layer takes the packets from the Network Layer
and encapsulates them into frames. If the frame size
becomes too large, then the packet may be divided into
small sized frames. Smaller sized frames makes flow
control and error control more efficient. Then, it sends
each frame bit-by-bit on the hardware.
Parts of a Frame
A frame has the following parts −
Frame Header − It contains the source and the destination
addresses of the frame.
Payload field − It contains the message to be delivered.
Trailer − It contains the error detection and error correction
bits.
Flag − It marks the beginning and end of the frame.
Cyclic Redundancy Check (CRC)
CRC is a redundancy error technique used to determine the
error.
Following are the steps used in CRC for error detection:
In CRC technique, a string of n 0s is appended to the data
unit, and this n number is less than the number of bits in a
predetermined number, known as division which is n+1 bits.
Secondly, the newly extended data is divided by a divisor
using a process is known as binary division. The remainder
generated from this division is known as CRC remainder.
Thirdly, the CRC remainder replaces the appended 0s at the
end of the original data. This newly generated unit is sent to
the receiver.
The receiver receives the data followed by the CRC
remainder. The receiver will treat this whole unit as a single
unit, and it is divided by the same divisor that was used to
find the CRC remainder.
If the resultant of this division is zero which means that it has
no error, and the data is accepted.
Let's understand this concept through an example: