TRANSMISSION
CHAPTER 2: DATA
CHAPTER 2.1
Types and modes
of Data
Transmission
IGCSE COMPUTER SCIENCE
Do your homework
already?
YES (actually
no)
HOW IS DATA (TEXT, IMAGE, AND SOUND) TRANSMITTED?
YES!
Computer
Science
is Easy
LESSON
OBJECTIVE
Packet Packet Types of Data
Transmission
Structure Switching
Data Packets
• Data sent over long distances is usually broken up
into data packets (datagrams).
• Packet size is roughly 64KiB.
• This makes it easier to control than a long
continuous stream of data.
• Each Packet can be sent along a different route to
its destination.
Data is broken down into
packets
P1
Secret
Message P2
P3
Each packet can be sent along a different route
Any Route
P
1
Secret
Message P2 Destination
P3
One disadvantage : Data needs to be reassembled when it
reaches the destination.
P
1 Secret
Message Destination
P2
P3
Packet
Structure
P1
A typical packet is split up
into:
Header Payload Trailer
Packet Structure
(Header)
• Sender IP Address
Header • Receiver IP Address
• Sequence number of the packet.
• This is to ensure that all the packets can be
reassembled correctly once they reach the
destination.
• Size of the packet
• This is to ensure that the receiving station can
check if all of the packets have arrived.
Packet Structure
(Header)
• Sender IP Address
Header • Receiver IP Address
• Sequence number of the packet.
• This is to ensure that all the packets can be
reassembled correctly once they reach the
destination.
• Size of the packet
• This is to ensure that the receiving station can
Remember check if all of the packets have arrived.
SSSR
Packet Structure
(Payload)
The actual data in the packet.
Payload
“Have you done your
homework”
Packet Structure (Trailer)
• Some ways to identify the end of the packet.
Trailer This is essential to allow each packet to be
separated from each other as they travel from
the sending to receiving station.
Packet Structure (Trailer)
2. Some form of error checking to ensure packet
Trailer arrives error free.
Cyclic Redundancy
• The sending computer will add up all the 1-bits in
Checks
the payload and store it as a hex value in the trailer
Trailer
before it is sent.
Eg. Payload Number of 1 bit Hexadecimal Trailer
111010011010
0 1 F F
111101001010
1 5
Cyclic Redundancy
Checks
2. Once the packet arrives, the receiving computer
Trailer recalculate the number of 1-bits in the payload.
Trailer
Eg. Number of 1 bit Hexadecimal
F
Payload Compare
111010011010
0 1 F
111101001010 Does error
1 5 occur?
Packet Structure
P
1
A typical packet is split up
into:
Header Payload Trailer
Packet Switching
• Packet switching is a method of data transmission in which a message is
(Payload)
broken up into a number of packets.
• Each packet can be sent independently from start point to end point.
• At the destination, the packets will need to be reassembled into their correct
order.
• At each stage in the transmission there are nodes that contain a router.
• Each router will determine which route the packet needs to take, in order to
reach its destination (The destination IP address is used in this part of the
process).
Packet Switching
• Packet switching is a method of data transmission in which a message is
(Payload)
broken up into a number of packets.
• Each packet can be sent independently from start point to end point.
• At the destination, the packets will need to be reassembled into their correct
order.
• At each stage in the transmission there are nodes that contain a router.
• Each router will determine which route the packet needs to take, in order to
reach its destination (The destination IP address is used in this part of the
process).
1. The router will determine the route of each packet.
2. Routing Selection depends on the number of packets waiting to be
processed at each node.
3. The shortest possible path available is always selected.
4. Packets can arrive in a different order compared to the way they
were sent.
Benefits of packet switching
• There is no need to tie up a single communication line.
• A high data transmission rate is possible
Drawbacks of packet switching
• Data can be lost and need to be re-sent
• Delay at the destination whilst the packets are being re-ordered)
Data Transmission
• There are several different methods of transmitting data
depending on the types of hardware and connections being
used.
Transmission Mode
Types of data transmission
• Simplex
• Serial
• Half-duplex
• Parallel
• Full-duplex
Data Transmission
• There are several different methods of transmitting data
depending on the types of hardware and connections being
used.
Types of data transmission
• Serial
• Parallel
Types of data transmission - Serial
• Serial data transmission occurs when data is sent ONE BIT AT A TIME
over a single wire/channel.
• Bits are sent one after the other as a single stream.
1011100
Sender Receiver
1
Example : Computer is connected directly to the printer via a USB
connection.
Types of data transmission - Parallel
• Parallel data transmission occurs when SEVERAL BITS OF DATA are
sent down SEVERAL CHANNELS/WIRES all at the same time.
• Each channel/wire transmits one bit
1
1
Sender Receiver
1
Example : Internal circuits in a computer.
Advantage Disadvantage
• Reliable in transmitting data • Data transmission can be
over long distance slow as only one channel
Serial
• Fewer Errors is used
• Faster data transmission as • Expensive
multiple channels are used • Synchronisation errors can
• Parallel data transmission works happen due to the
Parallel
well over short distances. separation of data across
different channels
Data Transmission
• There are several different methods of transmitting data
depending on the types of hardware and connections being
used.
Transmission Mode
• Simplex
• Half-duplex
• Full-duplex
Transmission mode - Simplex
• Simplex mode occurs when data can be sent in ONE DIRECTION ONLY (for example,
from sender to receiver).
LAPTOP TO PRINTER
Print this page
for me
Transmission mode - Half-duplex
• Half-duplex mode occurs when data is sent in BOTH DIRECTIONS but
NOT AT THE SAME TIME (for example, data can be sent from ‘A’ to ‘B’
and from ‘B’ to ‘A’ along the same transmission line, but they can’t both
be done at the same time).
"OVER OVER"
WALKIE
TALKIE "YES?"
Transmission mode - Full-duplex
• Full-duplex mode occurs when data can be sent in BOTH DIRECTIONS
AT THE SAME TIME (for example, data can be sent from ‘A’ to ‘B’ and
from ‘B’ to ‘A’ along the same transmission line simultaneously).
BROADBAND
INTERNET
CONNECTION
Advantage Disadvantage
• The process can use full • Two way communication is
Simplex bandwidth for the channel not possible
• Enable two-way transmission • Delay in the communication
Half-Duplex using full bandwidth
• Fastest duplex transmission • Some networks are not able
Full-Duplex method due to each to utilise the technology.
communication using its own
simplex channel. No delay
DIY
Which types of data transmission are being described:
data is sent one bit at a time in one direction only
Transmission Mode
Types of data transmission
Serial Simplex
Parallel Half-duplex
Full-duplex
DIY
Which types of data transmission are being described:
data is being sent 8 bits at a time in one direction only
Transmission Mode
Types of data transmission
Serial Simplex
Parallel Half-duplex
Full-duplex
DIY
Which types of data transmission are being described:
data is being sent 16 bits at a time in both directions simultaneously
Transmission Mode
Types of data transmission
Serial Simplex
Parallel Half-duplex
Full-duplex
DIY
Which types of data transmission are being described:
data is sent one bit at a time in both directions simultaneously
Transmission Mode
Types of data transmission
Serial Simplex
Parallel Half-duplex
Full-duplex
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
Chapter 2.2
Universal Serial
Bus (USB)
YEAR 10
Universal Serial Bus (USB)
• Universal serial bus is a form of SERIAL data transmission.
• USB is a type of communication port that has been built into computers in order to do
away with other older forms of port.
• USB is now the most common type of input/output port found on computers and has
led to a standardisation method for the transfer of data between devices and a
computer.
• USB allows both half-duplex and full-duplex data transmission.
USB Cable
• The USB cable consists of a four-wired shielded cable, with
• two wires for power (red and black)
• two wires (white and green) are for data transmission.
When a device is plugged into a computer using one of the
USB ports:
• Computer automatically detects that a device is present (this is due to a
small change in the voltage on the data signal wires in the USB cable).
• The device is automatically recognised, and the appropriate device
driver software is loaded up so that the computer and device can
communicate effectively
• If this is not available, the user is prompted to download the appropriate
driver software
USB-C
• A new type of USB connector, referred to as USB-C, is now
becoming more common in laptops and tablets/phone .
• This is a 24-pin symmetrical connector which means it will fit
into a USB-C port either way round.
• It is much smaller and thinner than older USB connectors,
offers 100 watt (20 volt) power connectivity, which means full-
sized devices can now be charged and it can carry data at 10
gigabits per second (10 Gbps); this means it can now support
4K video delivery.
Advantages and disadvantages of USB
• Ubiquitous. It is • Data transmission
everywhere. speed is still relatively
• Able to supply power slow.
and data (external power
• Transmission quality will
source is not needed)
deteriorate when the
• Backward compatible as
cable becomes too long
well as suitable adaptor
(not more than 5m)
is used
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
Chapter 2.3
Methods of error
detection
IGCSE Computer Science
HELP!
The need to check for errors.
• 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:
1. Interference (all types of cable can suffer from electrical interference, which can cause
data to be corrupted or even lost)
2. Problems during packet switching (this can lead to data loss – or it is even possible to
gain data!)
3. Skewing of data (this occurs during parallel data transmission and can cause data
corruption if the bits arrive out of synchronisation)
Five error detection methods
Parity Checks Echo Check
Check Digit
Automatic
Checksum Repeat
Request
How do we know that bits are being
transmitted correctly?
0 1 1 0 1 1 0 0
0 1 1 0 1 0 0 0
Parity Checks
• Parity checking is one method used to check whether data has been changed or
corrupted following data transmission. This method is based on the number of 1-
bits in a byte of data.
• The parity check can be either called EVEN and ODD
• One of the bits in the byte (usually the most significant bit or left-most bit) is
reserved for a parity bit.
SETTING UP THE PARITY BIT - EVEN PARITY
The parity bit is set according to whether the parity being used is even or odd. For example, consider the byte:
What should I put here if I want an EVEN number of 1s?
0 1 1 0 1 1 0 0
0, awesome!
SETTING UP THE PARITY BIT - ODD PARITY
The parity bit is set according to whether the parity being used is even or odd. For example, consider the byte:
What should I put here if I want an ODD number of 1s?
1 1 1 0 1 1 0 0
1, awesome!
Steps to set up a parity bit:
1 1 0 1 1 0 0
• Count the number of 1s
• Ask a question:
• Even parity: What digit should I put in the empty box if I want an EVEN number
of 1s?
• Odd parity: What digit should I put in the empty box if I want an ODD number
of 1s?
• Decide yourself based on the question!
How does parity check helps detect errors?
Message
0 1 1 0 1 1 0 0
Let’s say that
even parity
is used
Let's say the message is corrupted...
0 1 1 0 0 1 0 0
Let’s say that
even parity
is used
Something is not
right ... the byte
The computer will detect that an error has occurred during the transmission of the byte. should contain
The error is detected by the recipient’s computer even number of 1
re-calculating the parity of the byte sent.
Do it yourself - does any error occur?
1 Message (even parity is used)
) 1 1 1 0 1 1 0 1
Message (odd parity is used)
2)
1 1 1 1 1 1 1 1
Opps, there is a problem with parity check ...
Message
0 1 0 1 1 1 0 0
Even parity
is used
Parity check will not work if two bits are corrupted!
Message
0 1 1 1 1 1 0 1
Even parity
is used
In all these cases, the byte has clearly been corrupted, but number of ‘1’ bits remains even. Therefore,
no error would be flagged in spite of the obvious errors in transmission.
Remember: When two bits (an even number of bits) are corrupted, parity check fails.
Echo Check
• Upon receiving a message, the receiver will immediately send a copy
back to the sender.
• A comparison will then be carried out.
• If there is no difference between the two sets of data during the echo
check, this means that no error has occurred.
• Otherwise, an error has occurred and the data will be retransmitted.
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.
1 0 1 0 EXAMPLES –
ECHO
CHECK IN
SENDER RECEIVER
ACTION
Automatic Repeat Requests
• ARQ uses positive and negative acknowledgements and timeout.
Process
• The receiving device receives an error detection code as part of the data transmission. This is
used to detect whether the received data contains any transmission error.
• If no error is detected, a positive acknowledgement is sent back to the sending device.
• If an error is detected, the receiving device now sends a negative acknowledgement to the
sending device and requests re-transmission of the data.
• A time-out is used by the sending device by waiting a predetermined amount of time. If no
acknowledgement of any type has been received by the sending device within this time limit, it
automatically re-sends the data until a positive acknowledgement is received. Or until a
predetermined number of re-transmissions has taken place.
EXAMPLES –
1 0 1 1 ARQ IN
ACTION
SENDER RECEIVER
Check Digits
• The error detection systems described above help to spot errors
during the transmission of data between two different devices.
Sometimes, data discrepancies can occur due to human input errors.
1. An incorrect digit entered, for example 5327 entered instead
of 5307
2. Transposition errors where two numbers have changed
order, for example 5037 instead of 5307
3. Omitted or extra digits, for example 537 instead of 5307 or
53107 instead of 5307
4. Phonetic errors, for example 13 (thirteen), instead of 30
International Standard Book Numbers
Check Digits - ISBN 13 methods
1. The check digit in ISBN 13 is the thirteenth digit in the number.
2 . The thirteenth digit is generated using the other 12 digits in a number.
Different methods are used for different system when calculating the
thirteenth digit.
3. The thirteenth digit will help to identify whether an error has occurred or
not.
International Standard Book Numbers
Check Digits - ISBN 13 methods
• Add all the odd numbered digits together (Not the 13rd number)
• Add all the even numbered digits together and multiply the result by 3
• Add the results from 1 and 2 together and divide by 10
• Take the remainder, if it is zero then use this value, otherwise subtract the
remainder from 10 to find the check digit.
EXAMPLES –
CHECK
DIGIT IN
ACTION
International Standard Book Numbers
Check Digits - ISBN 13 methods
• Add all the odd numbered digits together (Not the 13rd number)
• Add all the even numbered digits together and multiply the result by 3
• Add the results from 1 and 2 together and divide by 10
• Take the remainder, if it is zero then use this value, otherwise subtract the
remainder from 10 to find the check digit.
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S
Chapter 2.4
MAIN REASON:
PA S T Y E A R Q U E S T I O N S
PA S T Y E A R Q U E S T I O N S