Computer networking

25
Functions of data li layer Subject: computer network CE-B Maulik togadiya

Transcript of Computer networking

Page 1: Computer networking

Functions of data link layer

Subject: computer network

CE-B

Maulik togadiya

Page 2: Computer networking

Data link layer

The data link layer transmit data packet(frames) sequentially over the transmission medium.

The data link layer provides reliable information transfer capabilities by sending ack frame to the sender after receiving data packet.

Page 3: Computer networking

The data link layer has two sub layers:  1) logical link control (LLC)  2) media access control (MAC).

LLC: It specifies which mechanisms are to be used for addressing stations over the transmission medium and for controlling the data exchanged between the originator and recipient machines.

MAC: when several computer are trying to transmit data, MAC determine which computer should get a transmission medium to transfer the data.

Page 4: Computer networking

Main functionsEncapsulation of network layer data packets

into frames.Frame synchronizationError control and error detectionFlow control

Page 5: Computer networking

Frames A frame is a digital data transmission unit

in computer networking and telecommunication . A frame typically includes frame

synchronization features consisting of a sequence of bits or symbols that indicate to the receiver the beginning and end of the payload data within the stream of symbols or bits it receives. If a receiver is connected to the system in the middle of a frame transmission, it ignores the data until it detects a new frame synchronization sequence.

Page 6: Computer networking

Framing Method Implemented By Data Link Layer Are:-

Character Count.Starting & Ending Characters With Character

Stuffing.Starting & ending Flags With Bit Stuffing.Physical Layer Coding Violation.

Page 7: Computer networking

3 0 41 1 57 7 02 41 26 12

Character count

Character Count Method

Frame 1 Frame 2 Frame 3 Frame 4

Page 8: Computer networking

Starting & Ending Characters With Character Stuffing

DLE ASTX B DC ETXDLE

Start Of Frame Data End Of Frame

A B DC Data From Network Layer

Page 9: Computer networking

Character Stuffing

DLE ASTX B DC ETXDLE

Start Of Frame

Data End Of Frame

A B DCDLE

DLE DLE

A B DCDLE

data on Sender side

data on Receiver side

Page 10: Computer networking

Starting & ending Flags With Bit Stuffing

0 1 10 0 10 1 11 1 01 1001111110 01111110

Starting flag BitEnding Flag BIT

Shifted Bit

BIT stuffing

Stuffing Performed By Data

Link layer

0 1 10 0 10 1 11 1 01 101 Data received by Network layer On receiver side After Performing Destuffing By data link Layer

Page 11: Computer networking

Physical Layer Coding ViolationIn this method Bit 1 Is encoded into high-low(10)

Pair And Bit 0 Is Encoded Into low-high(01)pair shown in figure.

0 1 10 01

Menchester Encoding

Page 12: Computer networking

Physical Layer Coding Violation.

0 1 10 01

Menchester Encoding

Page 13: Computer networking

Error detection and correction

Error detectionError detection means to decide whether the received data is correct or not without having a copy of the original message.

Error detection uses the concept of redundancy, which means adding extra bits for detecting errors at the destination.

Page 14: Computer networking

Four types of redundancy checks are used in data communications

Page 15: Computer networking

Vertical Redundancy CheckVRC

Page 16: Computer networking

Longitudinal Redundancy CheckLRC

Page 17: Computer networking

Cyclic Redundancy Check CRC

Page 18: Computer networking

Checksum

Page 19: Computer networking

Error Correction

It can be handled in two ways:1) receiver can have the sender retransmit the entire

data unit.2) The receiver can use an error-correcting code,

which automatically corrects certain errors.

Page 20: Computer networking

Hamming Code

Page 21: Computer networking

Hamming Code

Page 22: Computer networking

Hamming Code

Page 23: Computer networking

Example of Hamming Code

Page 24: Computer networking

Error Detection

Page 25: Computer networking

Thank You