Syllabus: Unit 5
Framing
Flow and Error Control protocols
Noisy and Noiseless channels
HDLC
Point to point protocols.
Data link control
DLC (Data Link Control) deals with procedures for communication
between two adjacent nodes (
node-to-node communication
) no
matter whether the link is dedicated or broadcast
It includes:
Framing
Physical layer is responsible for:
Converting bits into signals
Transmitting them over physical medium as electrical signals Bit synchronization
Sender and receiver should use same bit duration
Sender and receiver must understand order of bit sequence
Data link layer is responsible for:
Pack bits intoindependently distinguishable frames Adds address of sender and receiver during framing
Destination address defines where to go!
Frame Size
Usually the whole message is not framed in a single frame
Even a single bit error will corrupt the message
Frame size can be fixed or variable
Fixed size frames does not need definition of frame boundary Variable Size framing requires definition of frame boundaries Two approaches are used to define boundaries:
Character/Byte oriented framing
Data is a byte (8 bits) defined by a coding system like ASCII
Header and trailers are also multiples of bytes
Header has source and destination address as well as other control
information
Trailer has redundant bits for error detection
Separation of frames is performed using a byte ling
flags
Flags are added at beginning and end of message bye
Character/Byte oriented framing
Was popular when only text was exchanged as data
Flags could be chosen to be any character which is not used as text
With audio, video and other data, choice of flag character is a serious
issue
Solution:
Byte Stuffing
Special byte is added to the data section of the frame when there is a character which is same as character for flag
Since the data section is stuffed with an extra byte so it is termed as byte stuffing
This byte is usuallyescape character ESC
Byte stuffing
Bit oriented Framing
Data section of frame is a sequence of bits
It also has usual header and Trailer
Delimiter/Flag is a special 8-bit pattern 01111110 to define beginning
and end of frame
What if flag bit pattern appears in data
Bit stuffing
A single bit is stuffed in the bit pattern to make it look different from the flag
An extra zero is added if 011111 appears so that it becomes 0111110 instead of flag
Bit stuffing
Flow and error control
Flow control + Error control = Data link control
Flow control
Data link layer at sender and receiver ensureflow control usingbuffers Buffers are set of memory locations that can hold packets at sender and receiver
Two buffers (one at sender and one at receiver end)
When buffer at receiver is full, it sends a request to receiver for not pushing data into the same
Error control
Connection
DLC can be connectionless or connection oriented
Connectionless
There is no relationship between frames Each frame is independent
Frames arenot numbered and there is no ordering.
Connection-oriented
Duringsetup phase, a logical connection is established between two nodes
DLC protocols
Simple protocol
Stop-and-wait
Noisy Channel
Practically speaking, channels are rarely noiseless
Noisy channels uses:
Stop-and-wait Automatic Repeat Request
HDLC
High-level Data Link Control
HDLC is a bit-oriented protocol for communication over
point-to-point and multi-point links. It implements the ARQ
mechanisms
Two modes
Normal mode (NRM)
Primary station can send commands and secondary stations can only respond
Asynchronous balanced mode (ABM)
HDLC transfer modes
HDLC frames
Information frames
Supervisory frames
Unnumbered frames
HDLC frames
Point-to-point protocol
Mostly used on internet communication at data-link layer
It is byte oriented protocol
Link Control Protocol
Responsible for:
Establishing Maintaining Configuring Terminatinglinks
Also responsible for negotiating mechanisms to set options between
two end points
Authentication protocols
PAP (Password Authentication Protocol)
The user who wants to access the system sends an authentication identification (username) and a password
System checks validity of identification and password and further either accepts or denies the connection
CHAP (Challenge Handshake Authentication Protocol)
System sends user a challenge value
User applies predefined function which takes challenge value and user’s own password and creates a result which is sent to the system
System performs the same and compares the two. If they match, the connection is allowed and denied otherwise
Network Control Protocols
PPP is a multi-network-layer protocol.
It can carry a network layer data packet from protocols defined by
Internet, OSI, Xeros, DECnet etc.
WWW
World Wide Web
Distributed client-server service
Client uses abrowser can access a service using aserver
Services provided aredistributed over many locations calledwebsites Each website hold one or manywebpages