2.2 Error checking
Errors can occur during data transmission due to interference eg. Data loss, data gain and data change
When and why do errors occur?
- Errors can occur during data transmission due to interference eg. Data loss, data gain and data change
- Problems during packet switching (can lead to data loss or even data gain)
- Skewing of data (can occur during parallel transmission, causing data to arrive out of synchronisation)
Types of error checking methods:
Parity check (UPDATED by Z)
- FOR EXAMPLE IF ODD PARITY WAS USED:
- Even or Odd parity is chosen before transmission
- The number of 1 s/0 s are counted
- to make the sum of the bits/ 1 or 0 s in each byte odd/even(depending on the initial agreement
- A parity bit is added (to the parity byte)
- After transmission, if the number is odd no error is detected
- After transmission, if the number is even an error is detected
Problem with Parity check
- Cannot detect transposition errors
- Cannot detect if bits have flipped
Parity Block
- Instead of sending 1 byte of data at a time an entire block is sent. This means that the 1 bits are checked both horizontally and vertically:
- Using parity blocks not only identifies that an error has occurred but where the error occurred
Check digit
- A digit that is calculated from the data // uses modulo to calculate digit // valid description of modulo
- It is appended / added to the data
- Digit is recalculated when data is entered
- Digits are compared to check for error
- (Used to identify books ISBN Number)
Checksum
- A value is calculated from the data // Valid description of calculation
- It is transmitted with the data
- Value is recalculated after transmission
- Values are compared after transmission to check for error
Echo Check
- When data is sent to another device, this data is sent back again to the sender
- The sender compares the two sets to check if any errors occurred
- Not reliable as we cannot know whether the error occurred when sending the data in the first place, or if the error occurred when sending the data back for checking!
Automatic Repeat request (UPDATED by Z)
- Timer is started when sending device transmits a data packet to receiver
- Receiving device checks the data packet for errors
- Once the receiving device knows the packet is error free it sends a positive acknowledgement back to the sending device .
- ...and the next packet is sent
- If the sending device does not receive an acknowledgement before the timer ends .
- ...a timeout occurs
- ...the data packet is resent .
- until acknowledgement received