2 Data Transmission NEW (MT-L)
2 Data Transmission NEW (MT-L)
Syllabus Requirements:
2 Data transmission
2.1 Types and methods of data transmission
Candidates should be able to:
1 (a) Understand that data is broken down into packets to be transmitted
(b) Describe the structure of a packet
Notes and guidance
A packet of data in a unit of data contains a: packet header , payload and trailer
The packet header includes the:
o destination address
o packet number
o originator’s address
(c) Describe the process of packet switching
Data is broken down into packets
o Each packet could take a different route
o A router controls the route a packet takes
o Packets may arrive out of order
o Once the last packet has arrived, packets are reordered
2 (a) Describe how data is transmitted from one device to another using different methods of
data transmission
(b) Explain the suitability of each method of data transmission, for a given scenario
3 Understand the universal serial bus (USB) interface and explain how it is used to transmit data
o Including: – serial – parallel – simplex – half-duplex – full-duplex
o advantages and disadvantages of each method
o Including the benefits and drawbacks of the interface
2.2 Methods of error detection
Candidates should be able to: 1 Understand the need to check for errors after data
transmission and how these errors can occur
Notes and guidance
o Errors can occur during data transmission due to interference, e.g. data loss, data gain and data
change
2 Describe the processes involved in each of the following error detection methods for detecting
errors in data after transmission: parity check (odd and even), checksum and echo check
Notes and guidance
o Including parity byte and parity block check
3 Describe how a check digit is used to detect errors in data entry and identify examples of
when a check digit is used, including international standard book numbers (ISBN) and bar
codes
4 Describe how an automatic repeat query (ARQ) can be used to establish that data is received
without error Notes and guidance
o Including the use of: – positive/negative acknowledgements – timeout
2.3 Encryption Candidates should be able to:
1 Understand the need for and purpose of encryption when transmitting data
2 Understand how data is encrypted using symmetric and asymmetric encryption
Notes and guidance • Asymmetric encryption includes the use of public and private keys
When data is sent from one device to another, it is important to consider how that data
is transmitted.
Data Packet:
Information on the internet is broken down into packets sometimes called datagram, and
are created by TCP and transmitted over the internet
Packets are small chunks of information/data
TCP stands for Transmission Control Protocol and is used for organising data
transmission over networks
Small chunks of data are easier and quicker to route over the internet than big chunks of
data
Routing involves finding the most optimal path over a network
Data can include anything from text, images, audio, video, animations, etc, or any
combination of these
Payload
(actual data being sent)
Packet Switching:
Sometimes it is possible for packets to get lost because they keep ‘bouncing’ around from router
to router and never actually reach their destination.
Eventually the network would just grind to a halt as the number of lost packets mount up,
clogging up the system.
To overcome this, a method called hopping is used. A hop number is added to the
header of each packet, and this number is reduced by 1 every time it leaves a router
Data transmission refers to the movement of data in the form of bits between two or
more digital devices. This transfer of data takes place via some form of transmission
media (for example, coaxial cable, fiber optics etc.)
Data transmission
Data transmission can be either over a short distance (for example, from computer to
printer) or over longer distances (for example, over a telephone network).
Essentially, three factors need to be considered when transmitting data (each factor has
to be agreed by both sender and receiver for this to work without error):
the direction of the data transmission (i.e. in one direction only or in both directions)
the method of transmission (how many bits are sent at the same time)
the method of synchronization between the two devices.
Example: a phone conversation between two people where only one person speaks at a
time a Walkie Talkie.
Half-Duplex is like the dreaded "one lane" road you may have run into at construction
sites. Only one direction will be allowed through at a time. Railroads have to deal with
this scenario more often since it's cheaper to lay a single track.
Full-Duplex
A common use for serial data transmission is (Universal Serial Bus (USB).
Integrated circuits:
Buses and other internal components all use parallel data transmission because of
the need for high speed data transfer.
o The use of 8-bit, 16-bit, 32-bit and 64-bit buses, for example, allow much faster data
transmission rates than could be achieved with single channel serial data transfer.
o An internal clock is used to ensure the correct timing of data transfer; it is essentially
synchronous in nature and the short distances between components mean that none
of the issues described earlier have any real impact on the accuracy of the data.
This means that the receiver of the data knows when the data starts and when it ends.
This prevents data becoming mixed up; without these control bits, it would be
impossible to separate groups of data as they arrived.
The timing must be very accurate here since there are no control bits sent in this type of
data transmission. However, it is a faster data transfer method than asynchronous and
is therefore used where this is an important issue (for example, in network
communications).
When a device is plugged into a computer using one of the USB ports:
the computer automatically detects that a device is present (this is due to a small
change in the voltage level on the data signal wires in the cable)
the device is automatically recognised, and the appropriate DEVICE DRIVER is
loaded up so that computer and device can communicate effectively
if a new device is detected, the computer will look for the device driver which
matches the device; if this is not available, the user is prompted to download the
appropriate software.
Error-checking methods
Following data transmission, there is always the risk that the data has been corrupted or
changed in some way.
This can occur whether data is being transmitted over short distances or over
long distances.
Checking for errors is important since computers aren’t able to check that text is
correct; they can only recognise whether a word is in their built-in dictionary or
not.
This is why error checking is such an important part of computer technology.
This section considers a number of ways that can be used to check for errors.
A number of methods exist which can detect errors and, in some cases, actually correct
the error. The methods covered in this section are:
parity checking
checksum
echo checking
automatic repeat request (ARQ)
Parity checking
PARITY CHECKING is one method used to check whether data has been changed or
corrupted following transmission from one device or medium to another device or
medium.
A byte of data, for example, is allocated a PARITY BIT. This is allocated before
transmission takes place. Systems that use EVEN PARITY have an even number of 1-
bits; systems that use ODD PARITY have an odd number of 1-bits.
If this byte is using even parity, then the parity bit needs to be 0 since there is already
an even number of 1-bits (in this case, 4).
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 parity)
If two of the bits change value following data transmission, it may be impossible to
locate the error using parity checking.
Let us imagine we are transmitting the following byte, using even parity:
Suppose more than one bit has been modified during data transmission.
This means the byte could have reached the destination as any of the following, parity remains
even and no error is detected although errors have occurred:
Parity blocks:
When error has been flagged, it is impossible to know exactly which bit is in error.
One of the ways round this problem is to use parity blocks.
In this method, a block of data is sent and the number of 1-bits are totalled horizontally
and vertically (in other words, a parity check is done in both horizontal and vertical
directions).
As the following example shows, this method not only identifies that an error has occurred but
also indicates where the error is.
If an acknowledgement isn’t sent back to the sender before timeout occurs, then the
message is automatically resent.
Checksum
CHECKSUM is another way to check if data has been changed or corrupted following
data transmission. Data is sent in blocks and an additional value, the checksum, is also
sent at the end of the block of data.
To explain how this works, we will assume the checksum of a block of data is 1 byte in
length. This gives a maximum value of 28 – 1 (i.e. 255). The value 0000 0000 is ignored
in this calculation. Example 3 explains how a checksum is generated.
Example
If the sum of all the bytes in the transmitted block of data is <= 255,
then the
38 checksum 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 in
1185/256 = 4.629
Rounding down to nearest whole number gives Y = 4
Multiplying by 256 gives Z = Y * 256 = 1024
The difference (X – Z) gives the checksum: (1185 – 1024) = 161
This gives the checksum = 161
When a block of data is about to be transmitted, the checksum for the bytes is
first of all calculated.
This value is then transmitted with the block of data. At the receiving end, the
checksum is recalculated from the block of data received.
This calculated value is then compared to the checksum transmitted.
If they are the same value, then the data was transmitted without any errors; if
the values are different, then a request is sent for the data to be retransmitted.
Example 1: 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:
Generation of the check digit from the other digits in a number (In this example, 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).
1. 7-digit number: 4 1 5 6 7 1 0
8 7 6 5 4 3 2 (weighting values)
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
11 – 9 = 2 (check digit)
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.
As you will have no doubt worked out, this isn’t very reliable. If the two sets of data are
different, it isn’t known whether the error occurred when sending the data in the first
place, or if the error occurred when sending the data back for checking!
However, if no errors occurred then it is another way to check that the data was
transmitted correctly.
ENCRYPTION
When data is transmitted over any public network (wired or wireless), there is always a risk of it
being intercepted by, for example, a hacker.
SYMMETRIC ENCRYPTION
which means every letter in a word is shifted across the alphabet +4, +2, +9, +1, and so on,
places.
For example, here is the message COMPUTER SCIENCE IS EXCITING (plaintext on the top
line)
After applying encryption key, the Cipertext in the bottom line becomes meaningless.
If symmetric key encryption is used, there needs to be a secure method for the sender and
receiver to be provided with the secret key
ASYMMETRIC ENCRYPTION
Using asymmetric key encryption, the process actually starts with the receiver.
The receiver must be in possession of Pair of keys.
One is a public key which is not secret. The other is a private key which is secret
and known only to the receiver.
The receiver can send the public key to a sender, who uses the public key for
encryption and sends the cipher text to the receiver
The receiver is the only person who can decrypt the message because the private
and public keys are a matched pair.
The public key can be provided to any number of different people allowing the
receiver to receive a private message from any of them.
Reference:
Hodder education Book by David Watson and Hellen Williams
https://www.computerscience.gcse.guru/theory/data-packets-and-packet-switching
https://www.savemyexams.co.uk/igcse/computer-science/cie/23/revision-notes/2-data-
transmission/2-1-types-and-methods-of-data-transmission/data-packets/
https://en.wikipedia.org/wiki/Public-key_cryptography