2.2 Methods of Error Detection
2.2 Methods of Error Detection
Page 1 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Error Checking
Your notes
Why Errors Occur
Why do errors occur?
Errors can occur using wired or wireless technology due to interference
Examples of interference include wire degradation or electrical fields changing the signal
Results of interference include:
Data loss - data is lost in transmission
Data gain - additional data is received
Data change - some bits have been changed or flipped
Wireless technology uses radio signals or other electromagnetic signals to transmit data
These signals can be blocked by physical barriers such as buildings, walls, cars or other objects
Interference can be caused by bad weather such as rain or clouds, or by other wireless signals or
electromagnetic radiation
Wired technology carries more chance of causing an error as physical components can be damaged,
degrade or receive interference from outside signals
Data loss can also occur from interruptions to data transmission such as a blocked signal or if the
transmission is intermittent
Page 2 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Jul-04-16 (MMM/DD/YY)
If data is not as expected, things can go wrong
Your notes
For example, if a receiver expected to receive a date in format DD/MM/YY as 03/04/17 but received
04/03/17, did the sender mean 3rd April 2017 or 4th March 2017?
An error or corruption occurs when data received is not as expected and therefore is difficult or
impossible to process
WORKED EXAMPLE
Alex receives an email over a wireless connection from a work colleague containing an important
document.
Identify what interference Alex could experience when sending this email and identify the
outcomes of interference.
Further explain why Alex should check to make sure the document contains no errors.
[4]
Answer
Weather conditions or physical barriers such as building can affect signals, for example bits
could be flipped in the document making it hard to understand the original meaning [1]
Alex should be aware that interference can cause wirelessly received data to contain errors or
corruption [1]
Data could be lost, additional data could be gained or data could be changed [1]
As Alex received an important work document they need to check for errors so that their work is
unaffected and they do not receive incorrect information [1]
Page 3 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Even parity
Below is an arbitrary binary string
EVEN Byte
Parity bit
0 1 0 1 1 0 1 0
If an even parity bit is used then all bits in the byte, including the parity bit, must add up to an even
number
There are four 1’s in the byte
This means the parity bit must be 0 otherwise the whole byte, including the parity bit, would add up
to five which is an odd number
Odd parity
Below is an arbitrary binary string
Page 4 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
ODD Byte
Parity bit
Your notes
1 1 0 1 1 0 1 0
If an odd parity bit is used then all bits in the byte, including the parity bit, must add up to an odd
number
There are four 1’s in the byte. This means the parity bit must be a 1 otherwise the whole byte,
including the parity bit, would add up to four which is an even number
The table below shows a number of examples of the agreed parity between a sender and receiver and
the parity bit used for each byte
Example # Agreed parity Parity bit Main bit string Total number of 1’s
#1 ODD 0 1 1 0 1 0 1 1 5
#2 EVEN 1 0 0 0 1 0 0 0 2
#3 EVEN 1 0 1 0 1 1 1 1 6
#4 ODD 1 0 1 1 1 0 0 1 5
#5 ODD 1 1 0 1 0 1 0 1 5
#6 EVEN 0 1 0 0 1 1 1 0 4
Example #1: The agreed parity is odd. All of the 1’s in the main bit string are added (5). As this number is
odd already the parity bit is set to 0 so the whole byte stays odd
Example #2: The agreed parity is even. All of the 1’s in the main bit string are added (1). As this number is
odd the parity bit is set to 1 to make the total number of 1’s even (2)
Example #6: The agreed parity is even. All of the 1’s in the main bit string are added (4). As this number is
even already the parity bit is set to 0 so the whole byte stays even
Page 5 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Bits can be flipped or changed due to interference on a wire or wirelessly due to weather or other
signals
Your notes
Example # Agreed parity Parity bit Main bit string Total number of 1’s Error
#1 ODD 1 1 1 0 1 0 1 1 6 Error
#2 EVEN 1 0 0 0 1 0 0 0 2 No error
#3 EVEN 1 0 1 1 1 1 1 1 7 Error
#4 ODD 1 0 1 1 1 0 0 1 5 No error
#5 ODD 1 1 0 1 0 1 1 1 6 Error
#6 EVEN 0 1 0 0 0 1 1 0 3 Error
Parity checks are quick and easy to implement but fail to detect bit swaps that cause the parity to
remain the same
ODD Parity bit Bit 2 Bit 3 Bit 4 Bit 5 Bit 6 Bit 7 Bit 8
Byte 1 0 1 1 0 1 0 1 1
Byte 2 0 0 0 0 1 0 0 0
Page 6 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Byte 3 1 0 1 0 1 1 1 1
Your notes
Byte 4 1 0 1 1 1 0 0 1
Byte 5 1 1 0 1 0 1 0 1
Byte 6 1 1 0 0 1 1 1 0
Byte 7 0 0 1 1 1 1 1 0
Byte 8 0 1 0 1 1 0 0 0
Parity byte 0 1 1 1 1 1 1 1
Checksum
What is a checksum?
Checksums determine if data has been corrupted but do not reveal where
Data is sent in blocks and an additional checksum value is added at the end of the block
Checksums are custom, user-created algorithms that perform mathematical calculations on data
An example of a custom checksum algorithm in computer science is:
A checksum byte is defined as a value between 1 and 255 which is stored in 8 bits
Page 7 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
WORKED EXAMPLE
Describe the process a checksum algorithm uses to determine if an error has occurred
[5]
Answer
Before data is transmitted a checksum value is calculated [1]
The checksum value is transmitted with the data [1]
Page 8 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
The receiver calculates the checksum value using the received data [1]
The calculated checksum is compared to the transmitted checksum [1]
If they are the same then there is no error otherwise an error has occurred [1] Your notes
Echo Check
What is an echo check?
An echo checks involve transmitting the received data back to the sender
The sender then checks the data to see if any errors occurred during transmission
This method isn’t reliable as an error could have occurred when the sender transmits the data or
when the receiver transmits the data
If an error does occur the sender will retransmit the data
WORKED EXAMPLE
Four 7-bit binary values are transmitted from one computer to another.
A parity bit is added to each binary value creating 8-bit binary values. All the binary values are
transmitted and received correctly.
(a) Identify whether each 8-bit binary value has been sent using odd or even parity by writing odd or
even in the type of parity column.
01100100
10010001
00000011
10110010
[4]
(b) An error may not be detected when using a parity check.
Identify why an error may not be detected.
[1]
Answers
(a)
Page 9 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
(b)
Any one from:
there is a transposition of bits [1]
it does not check the order of the bits (just the sum of 1s/0s) [1]
even number of bits change [1]
incorrect bits still add up to correct parity [1]
Page 10 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Check Digits
Your notes
Check Digits
What is a check digit?
A check digit is used to determine if data has been corrupted but does not reveal where
Data is sent in blocks and an additional check digit value is added at the end of the block
Check Digits are custom, user-created algorithms that perform mathematical calculations on data
Examples of where check digits can be used include:
ISBN book numbers
Barcodes
Barcodes
Barcodes consist of black and white lines which can be scanned using barcode scanners
Barcode scanners shine a laser on the black and white lines which reflect light into the scanner
The scanner reads the distance between these lines as numbers and can identify the item
Barcodes also use a set of digits to uniquely identify each item
The final digit on a barcode is usually the check digit, this can be used to validate and authenticate an
item
WORKED EXAMPLE
Check digit algorithms are used to determine whether an error has occurred in transmitted data.
Page 11 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
Page 12 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
EXAM TIP
In this specification ARQ is referred to as Automatic Repeat Query but in past exam questions it has
been referred to as Automatic Repeat reQuests
Both words are interchangeable and should not cause any confusion!
WORKED EXAMPLE
Explain how Automatic Repeat reQuests (ARQ) are used in data transmission and storage
[2]
Answer
Any two from:
Set of rules for controlling error checking/detection // it’s an error detection method // used to
detect errors
Uses acknowledgement and timeout
Request is sent (with data) requiring acknowledgement
If no response/acknowledgment within certain time frame data package is resent
When data received contains an error a request is sent (automatically) to resend the data
Page 13 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers
Head to www.savemyexams.com for more awesome resources
The resend request is repeatedly sent until packet is received error free/limit is
reached/acknowledgement received
Your notes
Page 14 of 14
© 2015-2024 Save My Exams, Ltd. · Revision Notes, Topic Questions, Past Papers