CN Unit-2 Part 1
CN Unit-2 Part 1
CN Unit-2 Part 1
Presented by
P. Anusha,
Asst Prof, CSE(AIML)
INTRODUCTION TO DATA LINK LAYER
The data link layer uses the services of the physical layer to send and receive bits
over node-to-node communication channels. It has a number of functions,
including:
1. Providing a well-defined service interface to the network layer.
2. Dealing with error-free transmission of information
3. Regulating the flow of data so that slow receivers are not swamped by fast
senders.
Specific responsibilities of the data link layer include framing, addressing, flow
control, error control, and media access control.
To accomplish these goals, the data link layer takes the packets it gets
from the network layer and encapsulates them into frames for
transmission.
Each frame contains a frame header, a payload field for holding the
packet, and a frame trailer,
Frame management forms the heart of what the data link layer does.
DESIGN ISSUES IN DLL
The following are the data link layer design issues
1. Services Provided to the Network Layer
2. Framing
3. Error Control
4. Flow Control
Where reliability is an overall goal, and it is achieved when all the layers work together.
Services Provided to the Network Layer
The main function of the data link layer is to provide services to the network layer by
transferring data from the network layer on the source machine to the network layer
on the destination machine.
The DLL can be designed to offer various services, that are offered vary from
protocol to protocol. Three reasonable possibilities that we will consider in turn are:
1. Unacknowledged connectionless service (Eg: Ethernet)
2. Acknowledged connectionless service (Eg: WiFi)
3. Acknowledged connection-oriented service (Eg: Satellite
channel)
Framing
Frames are the streams of bits received from the network layer into manageable
data units. This division of stream of bits is done by Data Link Layer
The usual approach is to break up the bit stream into discrete frames, compute a
short token called a checksum for each frame, and include the checksum in the
frame when it is transmitted.
Breaking up the bit stream into frames is more difficult than it at first appears.
The following are the four methods in framing:
1. Byte count
2. Flag bytes with byte stuffing
3. Flag bits with bit stuffing
4. Physical layer coding violations
Byte count
This method uses a field in the header to specify the number of bytes in
the frame.
When the data link layer at the destination sees the byte count, it knows
how many bytes follow and hence where the end of the frame.
For noise-less
For noisy channels
channels