Data Link 2 Lec9
Data Link 2 Lec9
The data link layer is responsible for maintaining the data link between two hosts or nodes. Its characteristics and
functions are as follows:
Management of frames, which contains data arranged in an organized manner, which provides for an orderly and
consistent method of sending data bits across the medium
Responsible for flow control, which is the process of managing the timing of sending and receiving data so that it
doesn't exceed the capacity of the physical connection
Responsible for error notification, including receiving and managing error messaging related to physical delivery
of packets
Network devices that operate at this layer include Layer 2 switches (switching hubs) and bridges.
DATA LINK LAYER
FUNCTIONS
The two main functions of the data link layer are:
1. Logical Link Control (LLC): The LLC is on top of the MAC layer and is responsible for cyclic redundancy
check (CRC), sequencing information, and addition of appropriate source and destination information.
2. Media Access Control (MAC): (MAC) sublayer provides control for accessing the transmission medium. It is
responsible for moving data packets from one network interface card (NIC) to another, across a shared
transmission medium. Physical addressing is handled at the MAC sublayer.
ERROR DETECTION AND CORRECTION METHODS
Because of Attenuation, distortion, noise and interferences, errors during transmission are inevitable, and this leads to
Some of the bits may be altered, damaged or lost during transmission. Such a condition is known as error.
TYPES OF ERRORS
1. Single bit error: Only one bit gets corrupted. Common in Parallel transmission.
2. Burst error: More than one bit gets corrupted very common in serial transmission of data occurs when the
Single bit errors are least likely type of errors in serial data transmission.
BURST ERROR
More than one bit gets corrupted very common in serial transmission of data occurs when the duration of noise
The number of bits affected depends on the data rate and duration of noise.
burst errors are more difficult to detect / correct
ERROR DETECTION TECHNIQUES
Basic approach used for error detection is the use of redundancy, where additional bits are added to facilitate detection and correction of
3. Checksum
Redundancy is the method in which some extra bits are added to the data so as to check whether the data contain error or not.
m - data bits (i.e., message bits)
n= (m + r).
An n-bit unit containing data and check-bits is often referred to as an n-bit codeword.
SIMPLE PARITY CHECK
The simplest and most popular error detection scheme. Appends a Parity bit to the end of the data.
A parity of 1 is added to the block if it contains an odd number of 1’s (ON bits) and 0 is added if it contains an
even number of 1’s. At the receiving end the parity bit is computed from the received data bits and compared
with the received parity bit.
This scheme makes the total number of 1’s even, that is why it is called even parity checking. Considering a 4-bit
word, different combinations of the data words and the corresponding code words are given in the given table.
SIMPLE PARITY CHECK CONT’D
PERFORMANCE OF SIMPLE PARITY CHECK
Simple parity check can detect all single-bit error
It can also detect burst error, if the number of bits in even or odd.
The technique is not foolproof against burst errors that invert more than one bit. If an even number of bits is inverted
due to error, the error is not detected.
TWO-DIMENSION PARITY CHECKING
Performance can be improved by using two dimensional parity check, which organizes the block of bits in the form
of table.
Parity check bits are calculated from each row, which is equivalent to a simple parity check.
At the receiving end these are compared with the parity bits calculated on the received data.
TWO-DIMENSION PARITY CHECKING
CONY’D
Performance:
If two bits in one data unit are damaged and two bits in exactly same position in another data
unit are also damaged, The 2-D Parity check checker will not detect an error.
If first and second from last bits in each of them is changed, making the data units as
01001110 and 00101110, the error cannot be detected by 2-D Parity check.
THANK YOU