You are on page 1of 27

TRANSMISSION ERROR

BY: MR HUSSAIN KORIR


Phone+2547014980988
Email:hussainkorir@yahoo.co
m
TRANSMISSION ERRORS
Data is transmitted through a medium, which may use a cabled or a wireless connection. The
transmission media carries bits in the form of electrical, radio or optical (light) pulses. All types of
transmission media can be affected by errors.

Transmission errors can have serious effects. Every bit in a signal is important. Changing one bit alters
the value of the binary number.
The whole signal will be wrong. For this reason it is important to check for errors in transmitted data. If
the data has an error, it can be sent again.

When data is transmitted, there is always a risk that it may be corrupted, lost or even gained.
Errors can occur during data transmission due to:
 interference :(all types of cable can suffer from electrical interference, which can cause data to be
corrupted or even lost)
 problems during packet switching:(this can lead to data loss – or it is even possible to gain data!)
 skewing of data:(this occurs during parallel data transmission and can cause data corruption if the
bits arrive out of synchronization).
TYPES OF ERROR

Errors in transmission can mean that:


 some of the bits are lost from the data stream
 extra bits are added to the data stream
 1 bits change to 0, or 0 bits change to 1.
If a human operator is involved, for example someone typing the data, the person can also
make errors. An error made in copying data, for example:
 when typing it, is called a transcription error.
 An error where two letters or numbers are in the wrong order is called a transposition error.
METHODS USED IN ERROR DETECTIONS

A number of methods exist which can detect errors and, in some cases, actually
correct the error.
The methods used in error detections are:
• parity checking
• automatic repeat request (ARQ)
• checksum
• echo checking.
PARITY CHECKING
A parity check is one of the methods used to check for data transmission errors. Data is usually stored
or transmitted in bytes, which are a group of 8 bits. Each bit can either be a 1or a 0
A byte of data, for example, is allocated a PARITY BIT. This is allocated before transmission takes place.
There are two types of parity checks, these are:
• Even parity check – checks to see that the total number of 1s in the byte is even, and sets the parity bit
to 1 to make it an even number if not.
• Odd parity check – checks to see that the total number of 1s in the byte is odd, and sets the parity bit
to 1 to make it an odd number if not.
Before the data is sent, the transmitter counts how many Is there are in each byte. The transmitter then
adds an extra bit to the end of each byte:
• If there is an even number of 1’s in the byte, the parity bit is set to 0.
• If there is an odd number of 1s in the byte, the parity bit is set to 1.
This extra bit makes sure the number of is transmitted is an even number. After the data is received:
• The receiver counts how many 1’s there are in each byte plus its parity bit.
• Each byte plus parity bit should have an even number of 1’s. If any of the bytes with its parity bit has
an odd number of bits, the receiver will know there was an error during transmission. The data must be
sent again.
EXAMPLE:1
1 1 0 1 1 0 0
Even
 If this byte is using even parity, then the parity bit needs to be 0 since there is already an
Parity
even number of 1-bits (in this case, 4)
.
0 1 1 0 1 1 0 0
 If odd parity is being used, then the parity bit needs to be 1 to make the number of 1-bits
odd. Therefore, the byte just before transmission would be: either (even parity)or (Odd
Odd
parity)
Parity

1 1 1 0 1 1 0 0
EXAMPLE:2
If a byte has been transmitted from ‘A’ to ‘B’, and even parity is used, an error
would be flagged if the byte now had an odd number of 1-bits at the receiver’s end
Sender’s
bytes
0 1 1 0 1 1 0 0 Receiver’s
bytes

0 1 0 0 1 1 0 0
 In this case, the receiver’s byte has three 1-bits, which means it now has odd parity whilst
the byte from the sender had even parity (four 1-bits). This clearly means an error has
occurred during the transmission of the data.
 The error is detected by the computer recalculating the parity of the byte sent. If even
parity has been agreed between sender and receiver, then a change of parity in the
received byte indicates that a transmission error has occurred.
Example
All the bits are added together in the byte and depending on whether odd or even parity is being used a
1 or a 0 will be added as the finally parity bit.
If we use the example 1001100, using an even parity check, the parity bit would be a 1:
1+0+0+1+1+0+0=3
As 3 is an odd number we need to add 1 to it to make it even. This is why, when using even parity, the
parity bit for this byte will be a 1.
Using the example 1001100 and an odd parity check, the parity bit would be a 0:
1+0+0+1+1+0+0=3
As 3 is an odd number we need to add 0 to it to keep it odd. This is why, when using odd parity, the
parity bit for this byte will be a 0.
The devices that the data is being transferred between will be set to check for even parity or odd parity
before the data is sent. Parity check is a simple and effective method of error checking. it cannot detect
though if disturbance has affected a byte that would still have the same odd or even calculation, but the
bits themselves have changed. For example, even parity is being used, the byte 1001100 is being sent
with parity bit of 1. If the byte arrived as 110100 with the parity bit of 1, no error would be detected by a
parity check as the calculation of the bits is still even. Parity checking is also used on data that is stored
as well as data that is transmitted.
PARITY BLOCKS

A parity block uses the same rules as for normal


parity checks, odd or even, but takes a set of
binary numbers and arranges them in a table, so
that a parity bit is used in each row and each
column.
This block is using the first row and first
column for the parity bits, and is using even
parity.
EXAMPLE
Any errors thrown up by the parity check can
then be cross-referenced to locate problem bits.
This block is using the first row and first column
for the parity bits, and is using even parity.
Any errors thrown up by the parity check can
then be cross-referenced to locate problem bits.
The highlighted row and column will both show a
parity error, so the incorrect bit can be pinpointed
precisely.
Parity checks and parity blocks are both subject to
a similar limitation when it comes to identifying
when two bits have been transposed, but parity
blocks have more chance of catching these as the
double transposition is less likely to be present in
both the row and the column.
EXAMPLE 2
In this example, nine bytes of data have been transmitted.
Agreement has been made that even parity will be used.
Another byte, known as the parity byte, has also been sent.
This byte consists entirely of the parity bits produced by the vertical parity check.
The parity byte also indicates the end of the block of data.
Table shows how the data arrived at the receiving end. It is now necessary to check the parity of each byte
horizontally (bytes 1 to 9) and vertically (columns 1 to 8). Each row and column where the parity has
changed from even to odd should be flagged:
PARITY BLOCK SHOWING NINE BYTES AND PARITY BYTE
EXPLANATION
A careful study of Table shows the following:
»byte 8 (row 8) now has incorrect parity (there are three 1-bits)
»bit 5 (column 5) also now has incorrect parity (there are five 1-bits).
• First of all, the table shows that an error has occurred following data transmission (there has been a
change in parity in one of the bytes).

• Secondly, at the intersection of row 8 and column 5, the position of the incorrect bit value (which
caused the error) can be found.
The 1-bit at this intersection should be a 0-bit; this means that byte 8 should have been:
which would also correct column 5 giving an even vertical parity (now has four 1-bits).
This byte could therefore be corrected automatically as shown above, or an error message could be
relayed back to the sender asking them to re-transmit the block of data.
LIMITATIONS OF PARITY CHECKS
Even and odd parity checks on their own have a limitation. As much as they can tell us whether the
number of bits in a given binary number is even or odd, they cannot tell us exactly which bit has been
corrupted or changed during transmission. Let’s look at an example.
Priya sent a byte of data to Alexandria using odd parity. Determine whether the byte was transmitted
correctly.

Priya Alexandria
0111011 10111001

From Figure 1 above, the odd parity check suggests the byte was correctly transmitted. This is because
the total number of 1s in both the sent and received byte is odd.
However, we can see that the bits have changed. We call this change a transposition error resulting from
switching the bits’ positions in the binary number – the binary 0 changes to a 1 , and vice versa.
Transposition errors are mainly due to human error but can also be caused by a change in electrical
voltage during transmission. To detect these corrupt bits, you have to send the byte as a parity block.
CHECKSUM

A checksum is another type of error detection method. In this method, data is sent in blocks together
with a calculated value known as the checksum. The receiving computer will perform the same
calculation on the data to regenerate the checksum, and then compare the two checksum values. If there
is a mismatch, then an error has occurred, and the receiving computer will request the sending computer
to resend the data. This process is repeated until the correct data is received.
How to calculate a checksum
Data is sent in blocks and each block is made up of several bytes of data. The highest possible denary
value that can be represented in 1 byte (8 bits) is 2 8 − 1 = 255.
A few rules to follow when calculating a checksum are shown below:
Rule 1 : If the sum of the bytes in the block is less than or equal to 255, then this value is taken as
the checksum.
Rule 2 : If the sum of the bytes in the block is greater than 255, the following steps should be taken:
a. Divide the sum of the bytes in the block by 256 to get the quotient.
b. Convert the quotient to an integer to give the integer value (i.e. round down to the nearest integer).
c. Multiply the integer value by 256 to get the product.
d. Subtract the product from the sum of the bytes to get the checksum.
Rule 3 : The result of either Rule 1 or Rule 2 is the checksum of the block.
EXAMPLE:
If the sum of all the bytes in the transmitted block of data is <= 255, then the 38checksum is
this value.
However, if the sum of all the bytes in the data block > 255, then the checksum is found
using the simple algorithm
EXAMPLE :1
Suppose the value of X is 1185, then tracing When a block of data is about to be
transmitted, the checksum for the bytes is
through the algorithm, we get: first of all calculated. This value is then
X = 1185 transmitted with the block of data. At the
1.1185/256 = 4.629 receiving end, the checksum is recalculated
2. Rounding down to nearest whole number gives from the block of data received.
Y=4 This calculated value is then compared to
the checksum transmitted. If they are the
3. Multiplying by 256 gives Z = Y * 256 = 1024
same value, then the data was transmitted
4 .The difference (X – Z) gives the checksum: without any errors; if the values are
(1185 – 1024) = 161 different, then a request
is sent for the data to be retransmitted.
5 .This gives the checksum = 161
Activity

Calculate the checksum for blocks of data with the following byte sums:

a 148

b 905

c 1450

d 4095
ECHO CHECK

With ECHO CHECK, when data is sent to another device, this data is sent back again to the
sender. The sender compares the two sets of data to check if any errors occurred during the
transmission process.
In summary:
» a copy of the data is sent back to the sender
» the returned data is compared with the original data by the sender’s computer
» if there are no differences, then the data was sent without error
» if the two sets of data are different, then an error occurred at some stage during the data
transmission.

RECEIVE
SENDER
R
CHECK DIGITS Check digit
A check digit is the final digit included in a code; it is calculated from all the other digits in the code. Check
digits are used for: barcodes on products, such as International Standard Book Numbers (ISBN) and Vehicle
Identification Numbers (VIN).

Check digits are used to identify errors in data entry caused by mis-typing or mis-scanning a barcode.

They can usually detect the following types of error:

 an incorrect digit entered, for example 5327 entered instead of 5307

 transposition errors where two numbers have changed order, for


example 5037instead of 5307

 omitted or extra digits, for example 537 instead of 5307 or 53107


instead of 5307

 phonetic errors, for example 13 (thirteen), instead of 30 (thirty).


EXAMPLE 1: ISBN 13

There are a number of different methods used to generate a check digit. Two common
methods will be considered here:
• ISBN 13
• Modulo-11
The check digit in ISBN 13 is the thirteenth digit in the number. We will now consider two
different calculations.
• The first calculation is the generation of the check digit.
• The second calculation is a verification of the check digit (that is, a recalculation).
GENERATION OF THE CHECK DIGIT FROM THE OTHER 12 DIGITS IN A NUMBER

The following algorithm generates the check digit


from the 12 other digits:
1 add all the odd numbered digits together
2 add all the even numbered digits together and
multiply the result by 3
3 add the results from 1 and 2 together and divide by
10
4 take the remainder, if it is zero then use this value,
otherwise subtract the remainder from 10 to find the
1 9 + 8 + 3 + 0 + 8 + 8 = 36
check digit.
2 3 × (7 + 0 + 4 + 9 + 3 + 2) = 75
Using the ISBN 9 7 8 0 3 4 0 9 8 3 8 2 (note this is the
3 (36 + 75)/10 = 111/10 = 11
same ISBN above):
remainder 1
4 10 – 1 = 9 the check digit
RE-CALCULATION OF THE CHECK DIGIT FROM THE THIRTEEN-DIGIT NUMBER (WHICH NOW INCLUDES THE CHECK DIGIT)

To check that an ISBN 13-digit code is correct, including its check digit, a
similar process is followed:
1 add all the odd numbered digits together, including the check digit
2 add all the even number of digits together and multiply the result by 3
3 add the results from 1 and 2 together and divide by 10
4 the number is correct if the remainder is zero.

Using the ISBN 9 7 8 0 3 4 0 9 8 3 8 2 9 (including its check digit) from


Figure 2.17:

1 9 + 8 + 3 + 0 + 8 + 8 + 9 = 45
2 3 × (7 + 0 + 4 + 9 + 3 + 2) = 75
3 (45 + 75)/10 = 120/10 = 12 remainder 0
4 remainder is 0, therefore number is correct
Calculation
The example to be used has the following seven-digit number:

1 7-digit number: 4 1 5 6 7 1 0 weighting values: 8 7 6 5 4 3 2

2 sum: (8 × 4) + (7 × 1) + (6 × 5) + (5 × 6) + (4 × 7) + (3 × 1) + (2 × 0)

= 32 + 7 + 30 + 30 + 28 + 3 + 0

total = 130

3 divide total by 11: 130/11 = 11 remainder 9

4 subtract remainder from 11: 11 – 9 = 2 (check digit)

>>>>So we end up with the following eight-digit: 4 1 5 6 7 1 0 2


EXAMPLE : MODULO-11
The modulo-11 method can have varying lengths of number which makes it suitable for many
applications, such as product codes or VINs.
The first calculation is the generation of the check digit.

 The second calculation is a verification of the check digit (that is, a recalculation).
Generation of the check digit from the other digits in a number (we will assume the original
number contained only 7 digits.)

 The following algorithm generates the check digit from the other 7 digits:
1. each digit in the number is given a weighting of 8, 7, 6, 5, 4, 3 or 2 starting from the left (weightings
start from 8 since the number will become eight-digit when the check digit is added)
2. the digit is multiplied by its weighting and then each value is added to make a total
3.the total is divided by 11
4. the remainder is then subtracted from 11 to find the check digit (note if the remainder is 10 then the
check digit ‘X’ is used).
RE-CALCULATION OF THE CHECK DIGIT FROM THE EIGHT-DIGIT NUMBER
(WHICH NOW INCLUDES THE CHECK DIGIT)
Calculation 2
To check that the eight-digit number is correct, including its check digit, a similar
process is followed:
1 each digit in the number is given a weighting of 8, 7, 6, 5, 4, 3, 2 or 1 starting from
the left
2 the digit is multiplied by its weighting and then each value is added to make a total
3 the total is divided by 11
4 the number is correct if the remainder is zero
Using the 8-digit number: 4 1 5 6 7 1 0 2
1 weighting values: 8 7 6 5 4 3 2 1
2 sum: (8 × 4) + (7 × 1) + (6 × 5) + (5 × 6) + (4 × 7) + (3 × 1) + (2 × 0) + (1 × 2)
= 32 + 7 + 30 + 30 + 28 + 3 + 0 + 2
total = 132
3 divide total by 11: 132/11 = 12 remainder 0
4 remainder is 0, therefore number is correct
Automatic Repeat re-Quest (ARQ)
The error checks methods are used in a process called automatic repeat request (ARQ). This is a
method to ensure correct transmission of data. It works like this:
• The transmitter sends some data (called a packet).
• When the receiver gets the data packet, it checks it for errors.
• If the receiver finds no errors, it will send an acknowledgement.
• If the transmitter doesn’t receive an acknowledgement, it sends the data again.
The transmitter will keep on sending the data packet until it receives an acknowledgement.
There is usually a time limit. Once the time is up, the transmitter will stop trying to send the
package. The signal has timed out.

You might also like