0% found this document useful (0 votes)
67 views

Data Link Layer - I

The document discusses the data link layer of the OSI model. It describes the data link layer as the second layer that hides hardware details and transfers datagrams between directly connected hosts. The main responsibilities of the data link layer include framing data, performing error detection and flow control, and using access protocols like CSMA/CD. Common data link layer protocols are Ethernet, token ring, FDDI, and PPP.

Uploaded by

imtiyaz beigh
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
67 views

Data Link Layer - I

The document discusses the data link layer of the OSI model. It describes the data link layer as the second layer that hides hardware details and transfers datagrams between directly connected hosts. The main responsibilities of the data link layer include framing data, performing error detection and flow control, and using access protocols like CSMA/CD. Common data link layer protocols are Ethernet, token ring, FDDI, and PPP.

Uploaded by

imtiyaz beigh
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 18

DATA LINK LAYER

UNIT-III
By
Deepika
Assistant Professor
Data Link Layer is second layer of OSI Layered Model.

This layer is one of the most complicated layers and has


complex functionalities and liabilities.

Data link layer hides the details of underlying hardware and


represents itself to upper layer as the medium to
communicate.
Data Link Data link layer works between two hosts which are directly
connected in some sense.
Layer:
The main responsibility of the Data Link Layer is to transfer
the datagram across an individual link.

The Data link layer protocol defines the format of the packet
exchanged across the nodes as well as the actions such as
Error detection, retransmission, flow control, and random
access.
The Data Link Layer protocols are Ethernet, token ring,
FDDI and PPP.
Logical Link Control (LLC): This sublayer of the
data link layer deals with multiplexing, the flow of data
among applications and other services, and LLC is
responsible for providing error messages and
acknowledgments as well. 
Media Access Control (MAC): MAC sublayer
manages the device’s interaction, responsible for
Sub-Layers: addressing frames, and also controls physical media
access.

The data link layer receives the information in the form


of packets from the Network layer, it divides packets
into frames and sends those frames bit-by-bit to the
underlying physical layer. 
FUNCTIONALITY:
Services On Data
Link Layer:
The packet received from the Network layer is known
as a frame in the Data link layer.

At the sender’s side, DLL receives packets from the


Network layer and divides them into small frames,
then, sends each frame bit-by-bit to the physical layer.
Framing:
It also attaches some special bits (for error control and
addressing) at the header and end of the frame.

At the receiver’s end, DLL takes bits from the Physical


layer organizes them into the frame, and sends them to
the Network layer. 
Addressing:

• The data link layer encapsulates the source and destination’s MAC address/ physical address in
the header of each frame to ensure node-to-node delivery.
• MAC address is the unique hardware address that is assigned to the device while manufacturing. 

Error Control:

• Data can get corrupted due to various reasons like noise, attenuation, etc.
• So, it is the responsibility of the data link layer, to detect the error in the transmitted data and
correct it using error detection and correction techniques respectively.
• DLL adds error detection bits into the frame’s header, so that receiver can check received data is
correct or not.

Flow Control:

• If the receiver’s receiving speed is lower than the sender’s sending speed, then this can lead to an
overflow in the receiver’s buffer and some frames may get lost.
• So, it’s the responsibility of DLL to synchronize the sender’s and receiver’s speeds and establish
flow control between them. 
Access Control:
• When multiple devices share the same communication channel there is a high probability of collision,
• So it’s the responsibility of DLL to check which device has control over the channel and CSMA/CD
 and CSMA/CA can be used to avoid collisions and loss of frames in the channel. 
Error detection:
• Errors can be introduced by signal attenuation and noise.
• Data Link Layer protocol provides a mechanism to detect one or more errors.
• This is achieved by adding error detection bits in the frame and then receiving node can perform an
error check.
Error correction:
• Error correction is similar to the Error detection, except that receiving node not only detect the errors
but also determine where the errors have occurred in the frame.
Half-Duplex & Full-Duplex:
• In a Full-Duplex mode, both the nodes can transmit the data at the same time.
• In a Half-Duplex mode, only one node can transmit the data at the same time.
Types of
Error on
DLL:
◦ Errors can be of three
types, namely single
bit errors, multiple
bit errors, and burst
errors.
◦ Single bit error:
◦  In the received frame,
only one bit has been
corrupted, i.e. either
changed from 0 to 1
or from 1 to 0.
MULTIPLE
BITS ERROR

In the received
frame, more than one bits
are corrupted.
Burst error  In the received frame, more than one
consecutive bits are corrupted.
Error Detection Techniques:
◦ Error Detecting Codes:
◦ Implemented either on Data Link Layer Simple Parity Check
or Transport Layer:
◦ Whenever a message is transmitted, it
Two-dimensional Parity Check
may get scrambled by noise or data may
get corrupted. To avoid this, we use
error-detecting codes which are Checksum
additional data added to a given digital
message to help us detect if any error
has occurred during transmission of the Cyclic Redundancy Check
message.
Simple Parity check

◦ Blocks of data from the source are subjected


to a check bit or parity bit generator form,
where a parity of :
• 1 is added to the block if it contains odd
number of 1’s, and
• 0 is added if it contains even number of 1’s

◦ This scheme makes the total number of 1’s


even, that is why it is called even parity
checking.
Two-dimensional
Parity check
◦ Parity check bits are calculated for
each row, which is equivalent to a
simple parity check bit.
◦ Parity check bits are also calculated
for all columns, then both are sent
along with the data.
◦ At the receiving end these are
compared with the parity bits
calculated on the received data.
Checksum

◦ In this error detection scheme, the following procedure is


applied
◦ Data is divided into fixed sized frames or segments.
◦ The sender adds the segments using 1’s complement
arithmetic to get the sum. It then complements the sum to get
the checksum and sends it along with the data frames.
◦ The receiver adds the incoming segments along with the
checksum using 1’s complement arithmetic to get the sum
and then complements it.
◦ If the result is zero, the received frames are accepted;
otherwise, they are discarded.
Cyclic Redundancy Check
(CRC)
◦ Cyclic Redundancy Check (CRC) involves binary
division of the data bits being sent by a
predetermined divisor agreed upon by the
communicating system.
◦ The divisor is generated using polynomials.
◦ Here, the sender performs binary division of
the data segment by the divisor. It then
appends the remainder called CRC bits to the
end of the data segment.
◦ This makes the resulting data unit exactly
divisible by the divisor.
◦ The receiver divides the incoming data unit by the
divisor.
◦ If there is no remainder, the data unit is
assumed to be correct and is accepted.
◦ Otherwise, it is understood that the data is
corrupted and is therefore rejected.
CRC

You might also like