Computer Communication & Networks Lecture 9 Datalink Layer: Error Detection Waleed Ejaz

Slides:



Advertisements
Similar presentations
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
Advertisements

10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Introduction to Information Technologies
NETWORKING CONCEPTS. ERROR DETECTION Error occures when a bit is altered between transmission& reception ie. Binary 1 is transmitted but received is binary.
Chapter 10 Error Detection and Correction
PART III DATA LINK LAYER. Position of the Data-Link Layer.
The Data Link Layer Chapter 3. Position of the data-link layer.
Chapter 2 : Direct Link Networks (Continued). So far... Modulation and Encoding Link layer protocols Error Detection -- Parity Check.
Error Detection and Correction
Error Detection and Correction Rizwan Rehman Centre for Computer Studies Dibrugarh University.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2000 PART III: DATA LINK LAYER ERROR DETECTION AND CORRECTION 7.1 Chapter 10.
Shashank Srivastava Motilal Nehru National Institute Of Technology, Allahabad Error Detection and Correction : Data Link Layer.
1 Kyung Hee University Data Link Layer PART III. 2 Kyung Hee University Position of the data-link layer.
Copyright © NDSL, Chang Gung University. Permission required for reproduction or display. Chapter 10 Error Detection and Correction 長庚大學資訊工程學系 陳仁暉 副教授.
1 Data Link Layer Lecture 20 Imran Ahmed University of Management & Technology.
PART III DATA LINK LAYER. Position of the Data-Link Layer.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
British Computer Society
CIT 307 Online Data Communications Error Detection Module 11 Kevin Siminski, Instructor.
10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Data Link Layer: Error Detection and Correction
Chapter 10. Error Detection and Correction
Data Communications, Kwangwoon University10-1 Part 3 Data Link Layer Chapter 10 Error Detection and Correction Chapter 11 Data Link Control Chapter 12.
Cyclic Redundancy Check CRC Chapter CYCLIC CODES Cyclic codes are special linear block codes with one extra property. In a cyclic code, if a codeword.
Unit 5 Lecture 2 Error Control Error Detection & Error Correction.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
Error Detection and Correction
10/27/ Data Link Layer - Lin 1 CPET/ECET Data Link Layer Data Communications and Networking Fall 2004 Professor Paul I-Hai Lin Electrical.
COMPUTER NETWORKS Ms. Mrinmoyee Mukherjee Assistant Professor St. Francis Institute of Technology, Mount Poinsur, S.V.P Road, Borivli (west), Mumbai
Lecture 5 Checksum. 10.2CHECKSUM Checksum is an error-detecting technique that can be applied to a message of any length. In the Internet, the checksum.
Error Detection and Correction
Lecture Focus: Data Communications and Networking  Data Link Layer  Error Control Lecture 19 CSCS 311.
CHAPTER 3: DATA LINK CONTROL Flow control, Error detection – two dimensional parity checks, Internet checksum, CRC, Error control, Transmission efficiency.
Error Detection.
10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Computer Communication & Networks Lecture 10 Datalink Layer: Error Correction Waleed Ejaz
10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
1 Block Coding Messages are made up of k bits. Transmitted packets have n bits, n > k: k-data bits and r-redundant bits. n = k + r.
10.1 Chapter 10 Error Detection and Correction Data can be corrupted during transmission. Some applications require that errors be detected and.
1 Kyung Hee University Position of the data-link layer.
Error Detection. Data can be corrupted during transmission. Some applications require that errors be detected and corrected. An error-detecting code can.
Chapter 10 Error Detection And Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Data Link Layer. Data Link Layer Topics to Cover Error Detection and Correction Data Link Control and Protocols Multiple Access Local Area Networks Wireless.
Error Detection and Correction
McGraw-Hill©The McGraw-Hill Companies, Inc., 2000 PART III: DATA LINK LAYER ERROR DETECTION AND CORRECTION 7.1 Chapter 10.
Data Communications and Networking
1 Kyung Hee University Error Detection and Correction.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
10.1 Chapter 10 Error Detection and Correction Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Part III: Data Link Layer Error Detection and Correction
Data Link Layer 1. 2 Single-bit error 3 Multiple-bit error 4.
ERROR DETECTION AND CORRECTION Chapter 8 Data Communications & Networking ERROR DETECTION AND CORRECTION Chapter 8 First Semester 2007/2008.
ERROR DETECTION AND CORRECTION
Part III. Data Link Layer
Error Detection and Correction
Subject Name: COMPUTER NETWORKS-1
DATA COMMUNICATION AND NETWORKINGS
CIS 321 Data Communications & Networking
Part III Datalink Layer 10.
Chapter 10 Error Detection And Correction
Error Detection Bit Error Rate(BER): It is the ratio of number Ne of errors appearing over a certain time interval t to the number Nt of 1 and 0 pulses.
Chapter 7 Error Detection and Correction
Error Detection and Correction
Error Detection and Correction
Error Detection and Correction
DATA COMMUNICATION Lecture-34.
Chapter 10 Error Detection and Correction
Presentation transcript:

Computer Communication & Networks Lecture 9 Datalink Layer: Error Detection Waleed Ejaz

Data Link Layer

Data Link Layer Topics to Cover Error Detection and Correction Data Link Control and Protocols Multiple Access Local Area Networks Wireless LANs

Error Detection Why we need it ?  To avoid retransmission of whole packet or message What to do if error detected ?  Discard, and request a new copy of the frame: explicitly or implicitly  Try to correct error, if possible

Data can be corrupted during transmission. Some applications require that errors be detected and corrected. Note

Types of Errors Single Bit Error  In a single-bit error, only 1 bit in the data unit has changed. Burst Error  A burst error means that 2 or more bits in the data unit have changed.

Redundancy To detect or correct errors, we need to send extra (redundant) bits with data.

Error Detection

Simple Parity Check A simple parity-check code is a single-bit error-detecting code in which n = k + 1.

Example Let us look at some transmission scenarios. Assume the sender sends the dataword The codeword created from this dataword is 10111, which is sent to the receiver. We examine five cases: 1.No error occurs; the received codeword is The syndrome is 0. The dataword 1011 is created. 2.One single-bit error changes a1. The received codeword is The syndrome is 1. No dataword is created. 3.One single-bit error changes r0. The received codeword is The syndrome is 1. No dataword is created.

Example (contd.) 4. An error changes r0 and a second error changes a3. The received codeword is The syndrome is 0. The dataword 0011 is created at the receiver. Note that here the dataword is wrongly created due to the syndrome value. 5. Three bits—a3, a2, and a1—are changed by errors. The received codeword is The syndrome is 1. The dataword is not created. This shows that the simple parity check, guaranteed to detect one single error, can also find any odd number of errors.

Performance A Simple parity check can detect all single-bit errors. It can detect burst errors only if the total number of errors in each data unit is odd.

Two-dimensional Parity-check Code

Two-Dimensional Parity

Example Suppose the following block is sent: However, it is hit by a burst noise of length 8, and some bits are corrupted When the receiver checks the parity bits, some of the bits do not follow the even-parity rule and the whole block is discarded

Performance 2D parity check increases the likelihood of detecting burst errors. As we have seen in the example given in the previous slide, a redundancy of n bits can easily detect a burst error of n bits. There is, however, one pattern of errors that remains un-detectable. If 2 bits in one data unit are damaged and 2 bits in exactly in the same positions in another data unit are also damaged, the checker will not detect an error.

Cyclic Redundancy Check Cyclic Redundancy Check (also called polynomial code) Based on modulo-2 binary division No carries (because it's modulo-2) Subtraction is equivalent to XOR

Division in CRC encoder

Division in the CRC decoder for two cases

A polynomial to represent a binary word

CRC division using polynomials

Performance In a cyclic code, those e(x) errors that are divisible by g(x) are not caught. If the generator has more than one term and the coefficient of x0 is 1, all single errors can be caught. A generator that contains a factor of x + 1 can detect all odd-numbered errors.

Performance (contd.) All burst errors with L ≤ r will be detected. All burst errors with L = r + 1 will be detected with probability 1 – (1/2) r–1. All burst errors with L > r + 1 will be detected with probability 1 – (1/2) r.

Which of the following g(x) values guarantees that a single-bit error is caught? For each case, what is the error that cannot be caught? a. x + 1 b. x 3 c. 1 Solution a. No x i can be divisible by x + 1. Any single-bit error can be caught. b. If i is equal to or greater than 3, x i is divisible by g(x). All single-bit errors in positions 1 to 3 are caught. c. All values of i make x i divisible by g(x). No single-bit error can be caught. This g(x) is useless. Example

Properties of Good Polynomials A good polynomial generator needs to have the following characteristics: It should have at least two terms. The coefficient of the term x 0 should be 1. It should have the factor x + 1.

Table 10.7 Standard polynomials

Summary CRC can detect all burst errors that affect an odd number of bits. CRC can detect all burst errors of length less than or equal to the degree of polynomial. CRC can detect, with a very high propability, burst errors of length greater than the degree of polynomial.

Checksum 1. The data unit is divided into k sections, each of n bits 2. All sections are added using 1’s complement 3. The sum is complemented 4. The checksum is sent with data Example: IP header

Checksum: Sending Suppose the following block of 16 bits is to be sent using a checksum of 8 bits The numbers are added using one’s complement Sum Checksum (Take 1’s complement of Sum) The pattern sent is

Checksum: Receiving Now suppose the receiver receives the pattern sent and there is no error When the receiver adds the three sections, it will get all 1s, which, after complementing, is all 0s and shows that there is no error Sum Complement means that the pattern is OK.

Checksum: Error A burst error of length 5 that affects 4 bits When the receiver adds the three sections, it gets Partial Sum Carry 1 Sum => Complement !!!??

Readings Chapter 10 (B.A Forouzan)  Section 10.1, 10.3, 10.4  (Cover only those contents which are related to topics covered in class)