Vous êtes sur la page 1sur 23

ERROR DETECTION AND CORRECTION

WHEN ERROR OCCURS?

DATA SENT DATA RECEIVED

TYPES OF ERROR
Single bit

Burst

SINGLE BIT ERROR


One bit altered. Adjacent bits not affected. Rare in serial data communication. Example :
Data Sent Data Received

11000

10000

BURST ERROR
Two or more bits altered. Adjacent bits may be affected. Likely to occur in Serial Communication. Example :
Data Sent 1100110 Data Received 1111110

Error Detection

Error Detection Methods

Parity Check
most common and least expensive mechanism for error detection. A redundant bit is added to every data unit so that the total number of 1in the unit (including the parity bit) becomes even.

Parity Check

Cyclic Redundancy Check


For a block of k bits transmitter generates n bit sequence. Transmit k+n bits which is exactly divisible by some number. Receiver divides frame by that number If no remainder, assume no error.

Cyclic Redundancy check

Checksum
The unit is divided into K sections, each of n bits. Section 1 and 2 are added together using ones complement. Section 3 is added to the result of the previous step. Section 4 is added to the result of the previous step. The process repeats until section k is added to the result of the previous step. The final result is complemented to make the checksum.

CHECKSUM

Error Correction
Correction of detected errors usually requires data block to be retransmitted. Not appropriate for wireless applications
Bit error rate is high
Lots of retransmissions

Propagation delay can be long (satellite) compared with frame transmission time
Would result in retransmission of frame in error plus many subsequent frames

Need to correct errors on basis of bits received

Error Correction
~ can be handled in two ways when an error is discovered, the receiver can have the sender retransmit the entire data unit. a receiver can use an error-correcting code, which automatically corrects certain errors.

Error Correction Process


Each k bit block mapped to an n bit block (n>k)
Codeword Forward error correction (FEC) encoder

Codeword sent Received bit string similar to transmitted but may contain errors Received code word passed to FEC decoder
If no errors, original data block output Some error patterns can be detected and corrected Some error patterns can be detected but not corrected Some (rare) error patterns are not detected Results in incorrect data output from FEC

Error Correction Process

Working of error correction


Add redundancy to transmitted message Can deduce original in face of certain level of error rate E.g. block error correction code
In general, add (n k ) bits to end of block
Gives n bit block (codeword) All of original k bits included in codeword

Some FEC map k bit input onto n bit codeword such that original k bits do not appear

Hamming Code
Hamming code is a set of error-correction codes that can be used to detect and correct bit errors. Uses the concept of parity and parity bits. Each r bit is the parity bit for one combination of data bits: r1: bits 1, 3, 5, 7, 9, 11 r2: bits 2, 3, 6, 7, 10, 11 r4: bits 4, 5, 6, 7 r8: bits 8, 9, 10, 11

Hamming Code

Hamming Code

Hamming Code

THANK YOU

Vous aimerez peut-être aussi