Back to Computer Networks
Data Link Layer
Error detection, correction, and flow control mechanisms
Key Concepts
CRC, Hamming codes, sliding window protocols
Applications
Ethernet, Wi-Fi, reliable data transmission
Exam Focus
CRC calculations, Hamming code construction, protocol analysis
Data Link Layer Topics
Error Detection Details
CRC (Cyclic Redundancy Check) Calculator
CRC Result
Data: 1011011
Polynomial: 1101
CRC Remainder: 001
Transmitted Data: 1011011001
Calculation Steps
Initial data with 3 zeros appended: 1011011000
Step 1: Dividing at position 0
After XOR: 0110011000
Step 3: Dividing at position 1
After XOR: 0000111000
Step 5: Dividing at position 4
After XOR: 0000001100
Step 7: Dividing at position 6
After XOR: 0000000001
Final remainder: 001
Error Detection Methods
Parity Check
Adds extra bit to make total 1s even or odd
Even Parity: Total 1s = even number
Odd Parity: Total 1s = odd number
Detection: Single bit errors
Limitation: Cannot detect even number of errors
Checksum
Sum of data words, complement sent
Process: Add all data, send 1s complement
Verification: Add received data + checksum = all 1s
Used in: TCP, UDP, IP headers
CRC Properties
Detection Capability:
• All single bit errors
• All double bit errors
• All odd number of errors (if generator has factor (x+1))
• All burst errors ≤ degree of polynomial
• Most burst errors > degree of polynomial
Common Polynomials:
• CRC-8: x⁸ + x² + x + 1
• CRC-16: x¹⁶ + x¹⁵ + x² + 1
• CRC-32: x³² + x²⁶ + x²³ + ... + 1
📝 Exam Preparation Tips
Key Topics to Master
- • Practice CRC division step-by-step
- • Master Hamming code construction and error correction
- • Understand sliding window protocols and efficiency
- • Know error detection vs correction trade-offs
- • Calculate protocol efficiency for different scenarios
Common Exam Questions
- • "Calculate CRC for given data and polynomial" (8 marks)
- • "Generate Hamming code for 4-bit data" (6 marks)
- • "Find efficiency of sliding window protocol" (5 marks)
- • "Compare Go-Back-N vs Selective Repeat" (6 marks)
- • "Correct error using Hamming code" (4 marks)