Computer Network No.4 (Data Link Layer) From APCOMS
Computer Network No.4 (Data Link Layer) From APCOMS
Packetizing Addressing
1
ERROR DETECTION (Contd…) Simple Parity Check
Types of error detection techniques A redundant “Parity-bit” added to every
o Parity Check data unit
Simple In “Even” parity, the total number of 1s
Two-Dimensional
including the parity bit must be even.
o Cyclic Redundancy Check (CRC)
o Checksum
In “Odd” parity, the total number of 1s
including the parity bit must be Odd
Original data
Row parity
1 0 0 0 1 0 1 1
Column parity
Transmitted data
1 0 1 0 0 1 1 0 1 0 0 0 1 0 1 1 0 0 1 0 1 1 1 0
1 0 0 0 1 0 1 1 1 0 0 0 1 0 0 0
2
CRC - Generation
Quotient
1 1 1 1 0 1
Pre-determined
CRC - Checking
Divisor 1 1 0 1 1 0 0 1 0 0 0 0 0 Extra 0s
1 1 0 1
1 0 0 0
1 1 0 1
1 0 1 0
1 1 0 1
Similar process – Remainder must be all 0s, for data to
1 1 1 0 be correct
1 1 0 1
0 1 1 0
0 0 0 0 CRC Divisor is represented as a polynomial e.g. in our
1 1 0 0 example its equivalent polynomial is x3 + x2 + 1 (1101)
1 1 0 1
0 0 1 Remainder / CRC
Original Data 1 0 0 1 0 0
Original Data + CRC 1 0 0 1 0 0 0 0 1
Checksum - Generation
CHECKSUM
Steps at Sender
Original data 1 0 1 0 1 0 0 0 0 1 1 1 0 0
1 0 1 0 1 0 0 1
o All sections are added using “1’s Compliment” 0 0 1 1 1 0 0 1
1 0 1 0 1 0 0 1
o The resulting sum is complemented 0 0 1 1 1 0 0 1
0 0 0 1 1 1 0 1
o If the result is zero, data is accepted.
1 1 1 1 1 1 1 1 Sum
0 0 0 0 0 0 0 0 Complement
Faisal Amjad CPS 422
ASSIGNMENT # 2
Write a note on the performance of fol:
o Simple Parity check
o Two-Dimensional parity check
o CRC
o Checksum