Professional Documents
Culture Documents
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 2
After reading this chapter,
you should be able to (continued):
Cite the advantages of arithmetic checksum
Cite the advantages of cyclic redundancy checksum, and specify
what types of errors cyclic redundancy checksum will detect
Differentiate between the basic forms of error control, and
describe the circumstances under which each may be used
Follow an example of a Hamming self-correcting code
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 3
Introduction
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 4
White Noise
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 5
White Noise (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 6
Impulse Noise
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 7
Impulse Noise (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 8
Impulse Noise (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 9
Crosstalk
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 10
Crosstalk (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 11
Echo
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 12
Echo (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 13
Jitter
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 14
Jitter (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 15
Delay Distortion
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 16
Attenuation
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 17
Error Prevention
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 18
Error Prevention (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 19
ERROR DETECTION TECHNIQUES
Parity Check
Simple Parity (Even parity, Odd parity)
Longitudinal Parity
Arithmetic Checksum
Cyclic Redundancy Checksum
PARITY
CHECK
SIMPLE PARITY
Add a parity bit that is either 0 or
1 at the end of the bit stream.
EVEN PARITY
Produces an even number of 1s
ODD PARITY
Produces an odd numbers of 0s
PARITY
CHECK
SIMPLE PARITY contd
Even Parity
1 1 0 1 0 1 1
PARITY
CHECK
SIMPLE PARITY contd
Even Parity
1 1 0 1 0 1 1 1
PARITY
CHECK ERROR
SIMPLE PARITY contd
DETECTED!!!
Even Parity
1 1 0 1 0 0 1 1
PARITY
CHECK
SIMPLE PARITY contd
Odd Parity
1 1 0 1 0 1 1
PARITY
CHECK
SIMPLE PARITY contd
Odd Parity
1 1 0 1 0 1 1 0
PARITY
CHECK ERROR
SIMPLE PARITY contd
DETECTED!!!
Odd Parity
1 1 1 1 0 1 1 0
PARITY
CHECK
SIMPLE PARITY contd
1 1 0 1 0 1 1 0
PARITY
CHECK NO ERROR
SIMPLE PARITY contd
DETECTED!!!
Odd Parity
1 1 0 1 0 0 1 1
PARITY
CHECK
LONGITUDINAL PARITY
ROW 2 1 1 1 1 1 1 1 1
ROW 3 0 1 0 1 0 1 0 1
ROW 4 0 0 1 1 0 0 1 1
Parity 0 1 0 0 1 1 1 0
check
PARITY
CHECK
LONGITUDINAL PARITY
DATA PARIT
Y
ROW 1 (1) 0 (1) 0 0 1 0 1 1 1
ROW 2 1 1 1 1 1 1 1 1
ROW 3 0 1 0 1 0 1 0 1
ROW 4 0 0 1 1 0 0 1 1
Parity 0 1 0 0 1 1 1 0
check
PARITY
CHECK
LONGITUDINAL PARITY
DATA PARIT
Y
ROW 1 1 (1 )0 (0) 1 1 0 1 1 1
ROW 3 0 1 0 1 0 1 0 1
ROW 4 0 0 1 1 0 0 1 1
Parity 0 1 0 0 1 1 1 0
check
ARITHMETIC CHECKSUM
EX. This is cool.
ARITHMETIC CHECKSUM
EX. This is cool.
In ASCII the message would appear
1010100 1101000 1101001 1110011 0100000 1101001
1101001
T h i s i s
0100000 1100011
11
1101111
11
1101111
10
1101100 0101110
11 11 10
32 99 46
1 1 8
The decimal
ARITHMETIC CHECKSUM numbers are
EX. This is cool.
added
In ASCII the message would appear
1010100 1101000 1101001 1110011 0100000 1101001
1101001
10 10 11 10 11
84 32
4 5 5 5 5
0100000 1100011
32 99
11
11
1
1101111
11
1101111
10
11
1
10
8
1101100
46
01011101167
The sum is then
ARITHMETIC CHECKSUM added to the
end of the
message
10 10 11 10 11
84 32
4 5 5 5 5
11 11 10
32 99
1 1 8 46 1167
The receiver accepts
ARITHMETIC CHECKSUM the transmitted
message
10 10 11 10 11 11 11 10
84
4 5 5 32 5 5
32 99
1 1 8 46 1167
Received message
10 10 11 10 11 11 11 10
84
4 5 5 32 5 5
32 99
1 1 8 46 1167
ARITHMETIC CHECKSUM
10 10 11 10 11 11 11 10
84
4 5 5 32 5 5
32 99
1 1 8 46 1167
1167
ARITHMETIC CHECKSUM
1167
1167
Transmitted
ARITHMETIC CHECKSUM message
10 10 11 10 11 11 11 10
84
4 5 5 32 5 5
32 99
1 1 8 46 1167
Received message
10 10 11 10 11 11 11 10
84
4 5 5 32 7 5
32 99
1 1 8 46 1167
ARITHMETIC CHECKSUM
10 10 11 10 11 11 11 10
84
4 5 5 32 7 5
32 99
1 1 8 46 1167
1169
Then an error is
ARITHMETIC CHECKSUM
detected.
1167
1169
ARITHMETIC CHECKSUM
10 10 11 10 11 11 11 10
84
4 5 5 32 5 5
32 99
1 1 8 46 1167
Received message
10 10 11 10 11 11 11 10
84
4 5 3 32 7 5
32 99
1 1 8 46 1167
ARITHMETIC CHECKSUM
10 10 11 10 11 11 11 10
84
4 5 3 32 7 5
32 99
1 1 8 46 1167
1167
ARITHMETIC CHECKSUM
1167
1167
CYCLIC REDUNDANCY CHECKSUM
Yields an error detection capability approaching 100%
Treats the large packet of data as a Polynomial
Ex. The rightmost bit of the data
becomes the X0 term then
1 0 1 1 the next data bit to the left is
X3 X1 X0 X1 and so on
X3 X1 1
CYCLIC REDUNDANCY CHECKSUM
The transmitter take this message polynomial and divides it by a
given generating polynomial
example
Message = 1101101
Generating polynomial= 10101
append 0s to the original message before dividing.
(take note that the number of 0s is the same as the degree
of the size of the CRC of the generator polynomial or 1 bit less than
the divisor)
CYCLIC REDUNDANCY CHECKSUM
Take note that the addition and
subtraction are identical and are
Message = 1101101 simply based on the exclusive or
(XOR) operation
Generating polynomial= 10101 The quotient is disregarded then
1 10111
1 R= 1011 the remainder is appended to the
end of the original message
polynomial
1011 1101101 0000
1011
101 0000
0110
101
111001 0000
0
1011
01111
0000
CYCLIC REDUNDANCY CHECKSUM
11011
Message = 1101101
01
Generating polynomial= 10101 The When the data plus the
And this
quotient
remainder combined
is disregarded unit
arrived
then is
,the
the
1011 theend Iftransmitted
the remainder
remainder
ofsame
is appended is
to
over a zero,
generating
the original
thenpolynomial
there
message
is no error.
medium
polynomial
Otherwise aniserror
usedoccur.
to
detect the error
CYCLIC REDUNDANCY CHECKSUM
Some standard generating
polynomials:
CRC-12: x12 + x11 + x3 + x2 + x
+ 1
CRC-16: x16 + x15 + x2 + 1
CRC-CCITT: x16 + x15 + x5 + 1
CRC-32: x32 + x26 + x23 + x22 +
x16 + x12 + x11 + x10 + x8 + x7 +
5 4 2
r is the degree of the
Generating
CYCLIC REDUNDANCY CHECKSUM Polynomial
Error Control
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 60
Do Nothing (Toss the Frame/Packet)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 61
Return A Message
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 62
Stop-and-Wait Error Control
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 63
Stop-and-Wait Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 64
Sliding Window Error Control
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 65
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 66
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 67
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 68
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 69
Sliding Window Error Control (continued)
Notice that an ACK is not always sent after each frame is received
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 70
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 71
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 72
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 73
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 74
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 75
Sliding Window Error Control (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 76
Correct the Error
For a receiver to correct the error with no further help from the
transmitter requires a large amount of redundant information to
accompany the original data
This redundant information allows the receiver to determine the error
and make corrections
This type of error control is often called forward error correction
and involves codes called Hamming codes
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 77
Correct the Error (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 78
Correct the Error (continued)
Example (continued):
c8 will perform a parity check on bits b12, b11, b10, and b9
c4 will perform a parity check on bits b12, b7, b6 and b5
c2 will perform a parity check on bits b11, b10, b7, b6 and b3
c1 will perform a parity check on bits b11, b9, b7, b5, and b3
The next slide shows the check bits and their values
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 79
Correct the Error (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 80
Correct the Error (continued)
The sender will take the 8-bit character and generate the 4 check
bits as described
The 4 check bits are then added to the 8 data bits in the sequence
as shown and then transmitted
The receiver will perform the 4 parity checks using the 4 check
bits
If no bits flipped during transmission, then there should be no parity
errors
What happens if one of the bits flipped during transmission?
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 81
Correct the Error (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 82
Correct the Error (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 83
Error Detection In Action
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 84
Summary
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 85
Summary (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 86
Summary (continued)
Data Communications and Computer Networks: A Business User's Approach, Sixth Edition 87