You are on page 1of 131

TOPIC 1:

BASIC CONCEPT OF
DATA COMMUNICATION

DEPARTMENT
OF ELECTRICAL
ENGINEERING
1

At the end of the topic, student should be able


to explain the:

Importance of data communication.


Application of communication codes.
Basic data communication system.
Data encoding.
Data transmitting.
Error encoding.

Data Communication
data : number, alphabet or symbol processed by computer.(raw
facts before
processing).
computer data: binary digit (0s and 1s binary).
information: data, voice, image, character and code has been
processed in a form that can be use and understand by
receiver.
code : message that can be read and has a meaning that can be
understood by the end user (machine or human).
Main purpose of an electronic communications system is to
transfer information from one place to another.
Electronic communications can be viewed as the
transmission, reception and processing of information
between two or more locations using electronic
circuit/device.
Basic communication models shows the communication
flows between 2 points.
3

Definition of Data Communication

Exchangeable
of digital data
coding between
two devices via
some form of
transmission
medium.

The system
consists of
group up the
data, processing
the data and
transmit the data
using a specified
communication
channel
Data
Communication

IMPORTANCES OF DATA COMMUNICATION:

1) Electronic communication:
- email, video teleconferencing, etc.

2) Internet access:
- email, chat, download
3) ATM card:
- money draw from bank that has link

4) Shopping privilege:
- order through television or radio
5) Public access
- Jabatan Pendaftaran Negara, Jabatan Pengangkutan Jalan &
many others.

ADVANTAGES OF DATA COMMUNICATION:


1) Safety:
digital
system is much safer because it can be
encode to a code that is only knew by the sender
and
receiver.
2) Small error:
digital system has smaller error compare to analogue
system.
3) Low cost:
digital system has low cost compares to analogue
system, for example in a process of frequency
division.
4) Small interruption:
interruption did not affect data transmission because
digital data can be regenerate at each repeater station.
5) Easy to interface:
digital circuit is easier to interface because data digital
only consists of two levels, which are 1 and 0 bit.
6

HISTORY OF DATA COMMUNICATION

The evolution of telecommunication technologies


with the development of computer = Data
Communication.

HISTORY OF DATA COMMUNICATION

cont.

In 1837, Samuel Morse's invention of the telegraph began the


history of data communication.
In 1876, Alexander Graham Bell improved the telegraph with the
introduction of the telephone.
1910:Howard Krum developed Start/Stop Synchronization.
1930: Development of ASCII Transmission Code

The first generation of computers started in 1940s to be


used for World War II.
1945: Allied Governments develop the First Large Computer.
1950: IBM releases its first computer IBM 710.
1960: IBM releases the First Commercial Computer IBM 360.
In 1970s mainframe computes were used and people
connected to it with unintelligent terminals.
This was the first kind of computer network and several
persons could use the computer simultaneously.
8

HISTORY OF DATA COMMUNICATION

cont.

When the computer became cheaper and smaller people


tried to maintain large amounts of data in one computer.
Then the database management concept immerged.
One high-end computer called a server was used to
maintain the database and others could connect to the
server from their PCs.
Electronic Mail (e-mail or Email) replaces snail mail. Email is the forwarding of electronic files to an electronic
post office for the recipient to pick up.
Scheduling Programs allow people across the network to
schedule appointments directly by calling up their fellow
worker's schedule and selecting a time.
Videotext is the capability of having a two-way
transmission of picture and sound. Games like Red Alert,
distance education lectures, etc. use video text.

APPPLICATION OF DATA COMMUNICATION


1) E-mail:
send and receive mail by electronically.
2) Teleconferencing:
attend
meeting
or
discussion
without
present to the real location.
3) Fax:
send or receive fax.
4) Banking:
involving transfer of finance data, especially
which consumes the ATM machine.
5) Internet:
surf internet to get information and others.
6) Electronic government:
including many government sectors, for
example JPN, JPJ and many others.
10

Communication Codes

Definition coding is a representative set of symbols using


that used before being processed.
Coding is rule for converting a piece of information into another form or
representation in order to make it the system could read the
information.

2.Boudot code

3.EBCDIC
code
4.ASCII code

1.Morse code

COMMUNICATION
CODES

11

Communication Codes

cont...

Morse Code

The earliest code established.


The simplest code, just transmit characters for telegraphic
process.
Is a method of transmitting textual information of on-off
tones,light or click.
1890 began extensively use for early radio communication
before it was possible to transmit voice.

Morse code consist dot (.) and dashes (-)


Dot (.) short beep = 1 unit time base.
Dash (-) long beep = 3 unit time base.
The space between dot and dash = 1 unit time base
The space between letters = 3 unit times
12

Communication Codes

cont...

Morse
Code
Table

13

Communication Codes

cont...

14

Communication Codes

cont...

Exercise:
1. Convert English code back into Morse and
how many times required for data
transmission of
SWEET 17.
2. Convert Morse code back into English

15

Communication Codes

cont...

16

Communication Codes

cont...

17

1.2 .1

Communication Codes

cont...

Baudot code

1875 Thomas Murray named the code after Emily Baudot


First fixed-length character code develop for machines.

The first code is created for computer.


Using the number 0 and 1 to represent the character.
Each character contains 5 bits.

18

19

Communication Codes

cont...

Example:
Convert English code into Baudot code for;
2 BUS

Solution:
Shift to upper case column 2 : 11011
Space : 00100
Shift to lower case column B : 11111
Shift to lower case column U : 11111
Shift to lower case column S : 11111

10011
11001
00111
00101
20

Communication Codes

cont...

Exercise:

Translate those characters using Boudot code;


DIS 13

21

Communication Codes

cont...

Solution:
Shift to
Shift to
Shift to
Shift to
Space :
Shift to
Shift to
Shift to

upper case column :


lower case column D :
lower case column I :
lower case column S :
00100
lower case column 1 :
lower case column 3 :
upper case column :

11011
11111
11111
11111

10001
01001
00110
00101

11011 10111
11011 00001
11011 10001

22

Communication Codes

cont...

EBCDIC Code
Extended Binary coded Decimal Characters
Information.
8 bit characters created by IBM.
there are 256 different combination.
Often used in IBM.

23

24

Communication Codes

cont...

Example:
Translate those characters using EBCDIC code;
a) B
b) 5

Solution:
a) B:
b) 5:

1100 0010
1111 0101

25

Communication Codes

cont...

Exercise
Translate those characters using EBCDIC code;
a) A
b) 7
c) a
d) SYN

26

Communication Codes

cont...

Solution:
Translate those characters using EBCDIC code;
a) A : 1100
0001
b) 7 : 1111
0111
c) a : 1000
0001
d) SYN : 0011 0010

27

Communication Codes

cont...

ASCII Code
American Standard Character Information
Interchange
Consists of 7 bit character.
Has 128 different character combination.

ASCII was established to achieve compatibility between


various types of data processing equipment.
The standard ASCII character set consists of 128 decimal
numbers ranging from zero through 127 assigned to
letters, numbers, punctuation marks, and the most
common special characters.

28

ASCII Code Table

29

Communication Codes

cont...

Example:
Translate those characters using ASCII code;
a) 7
b) SYN

Solution:
Translate those characters using ASCII code;
a) 7 : 0110111
b) SYN : 0010110

30

Communication Codes

cont...

Exercise

Translate those phrases using ASCII code of


1 SeRaH

31

Communication Codes

cont...

Solution:
Translate those phrases using ASCII code of
1 SeRaH
: 010
0010
1 : 011
0001
S : 101
0011
E : 110
0101
R : 101
0010
A : 110
0001
H : 100
1000
: 010
0010
32

APPLICATION OF COMMUNICATION CODES


amateur radio operators

Morse
code

Boudot
code

EBCDIC
code

identification of navigational radio beacon and


land mobile transmitters, plus some military
communication, including flashing-light
semaphore communications between ships in
some naval services
Application for low speed teletype equipment
such as TWX/Telex system, radio teletype.
used extensively in telegraph systems
used mainly on IBM mainframe and IBM
midrange computer operating systems.
used for data communication, processing and
storage
33

APPLICATION OF COMMUNICATION CODES cont.

ASCII code

most popular code for serial data


communications today
used as the data code for keyboards in
computers

34

BASIC DATA COMMUNICATION SYSTEM

Terminal

Modem

DTE

DCE

Telecommunication
Network

Modem
DCE

Terminal
DTE

35

BASIC DATA COMMUNICATION SYSTEM

cont.

Transmitter /source/ sender


A part of system where the information signal is being
produce, process and transmit.
The device that sends the data message.
Example of sender: computer, workstation,
telephone handset, video camera and so on.
Example of information signal;
Audio signal
Video signal
Printed signal
Coding signal.
Transmission Medium
The physical path by which a message travels from
sender to receiver.
Example of medium transmission;
Coaxial cable
Twisted pair cable
Fiber optic
Copper cable
Microwave
36

BASIC DATA COMMUNICATION SYSTEM

cont.

Repeater
A device to regenerate
back the signal.

Receiver /sink
The device that receives the message.
a device to detect electrical signal and translate back to
the original signal.

37

Data Terminal Equipment (DTE) and Data


Equipment (DCE)

Communication

DTE
A subscriber equipment or users device for
data communications.
Consists of a source of data or receiving data
or both.
These tools may include an error control,
synchronization and identification capabilities
of the station.
Examples of DTE is the computers, logical
control, visual display units and work station.
DCE
Provided
by
authorities
or
by
client
communication network itself.
DCE is capable of implementing, operating and
terminate a data communication, exchanging
signals and coding needed to make the
relationship between the DTE and data circuits.
Internal or external parts of a computer.
Example: a modem or data set.
38

Information Capacity, Bits, Bit Rate and Baud


Information Capacity (I), unit: bps
Information capacity is a measure of how much information

can be propagated through a communications system and is


a function of bandwidth and transmission time.
Information capacity represents the number of independent

symbol that can be carried through a system in a given unit of


time. Usually expressed as a bit rate.

39

Information Capacity, Bits, Bit Rate and Baud cont....


BIT and BIT RATE
Bit :
A Bit is a digit in the binary number system. It can have two

values, 0 or 1 (basic digital symbol)


Bit Rate :
The number of bits transmitted in one second and
expressed in bits per second (bps).
The rate of change of a digital signal which usually binary.
Sometimes is written bit rate or data rate.

40

Information Capacity, Bits, Bit Rate and Baud


BAUD RATE and BANDWIDTH

cont....

Baud Rate :
The number of symbols transmitted during one second and is
expressed in symbols per second.
The rate of change of a signal on the transmission medium
after encoding and modulation have occurred.
Sometimes is written transmission rate, modulation rate or
symbol rate.

Bandwidth (BW), unit: Hz


(1) the range of frequencies contained in a composite
signal of frequency spectrum.
(2) the difference between the highest and lowest
frequencies contained in the information.
Indicates the capacity of data.
41

Information Capacity, Bits, Bit Rate and Baud

cont....

Bit Rate vs Baud Rate


Bit rate
Is the number of bits
per second.

Baud rate
Is the number of signal
units per second that
are require to
represent those bit

42

Information Capacity, Bits, Bit Rate and Baud cont....


Bit rate and baud rate are not always the same. The bit rate is the
number of bits transmitted per second, whereas, the baud rate is the number
of signal units transmitted per second. Therefore, baud rate is always less
than or equal to the bit rate but never greater.

Example:
What is the bit rate and baud rate for an analogue signal that carries 3
bits in each signal unit if 2000 signal units are sent per second?
Solution:
Baud rate = 2000 baud per second
Bit rate = 2000 x 3 = 6000 bps
What is the baud rate for an analogue signal if the bit rate of the

signal is 2000 and each signal unit carries 4 bits?


Solution:
Baud rate = 2000 / 4 = 500 baud
43

Information Capacity, Bits, Bit Rate and Baud

cont....

Exercise:
a) An analog signal carries 4 bits in each signal unit. If
1000 signal units are sent per second, find the baud rate
and the bit rate.
b) The bit rate of a signal is 3000. If each signal unit carries
6 bits, what is the baud rate?

44

Information Capacity, Bits, Bit Rate and Baud cont....

Solution:
a)

Baud rate = 1000 bauds per second (baud/s)


Bit rate = 1000 x 4 = 4000 bps

b)

Baud rate = 3000 / 6 = 500 baud/s

45

Information Capacity, Bits, Bit Rate and Baud cont....


Shannons Limit
Based on this law, the information capacity of any communication

channel is related to its bandwidth and the signal-to-noise ratio.


The higher the signal-to-noise ratio, the better the performance and
the higher the information capacity.
Mathematically stated, the Shannon limit for information capacity is;

I B log 2 1
N
or
S

I 3.32 B log10 1
N

where;
I = information capacity (bits per second)
B = bandwidth (Hz)
S/N = signal to noise power ratio (unitless)

46

Information Capacity, Bits, Bit Rate and Baud cont....

EXAMPLE:
For a standard telephone circuit with a signal-to-noise power ratio of
1000W (30dB) and a bandwidth of 2.7kHz, the Shannon limit for
information capacity is,

I 3.32 B log10 1
N
I ( 3.32 )( 2700 ) log10 1 1000
I 26.9kbps

47

DATA ENCODING
Encoding Techniques
1. Digital data Digital signal.
2. Digital data Analog signal.
3. Analog data Digital signal.
4. Analog data Analog signal.

Four possible combinations :


Digital data-to-digital signal:

Reason: equipment for encoding digital data into a digital

signal is less complex and less expensive than digital-toanalog conversion.

48

DATA ENCODING

cont

Digital data-to- analog signal:

Reason: Some transmission media, such as optical fiber


and the unguided media, will only propagate analog
signals.

Analog data-to- digital signal:


Reason: Conversion of analog data to digital form permits
the use of modern digital transmission and switching
equipment.
Analog data-to-analog signal:
Reason: Analog data in electrical form can be transmitted
as baseband signals easily and cheaply.

49

There are several ways for encoding digital data to digital signals:
Non-return to Zero (NRZ)
Return to Zero (RZ)

DATA
ENCODING

AMI (Alternate Mark Inversion)


Manchester
High Density Bipolar 3 Zero (HDB3)
50

Digital to Digital Encoding


Non Return to Zero (NRZ)
Traditionally, a unipolar scheme was design as a NRZ:
0 = Low voltage level (0V)
1 = High voltage level (+V volts)

Unipolar

51

Digital to Digital Encoding

cont.....

Non Return to Zero (NRZ)

cont

Another scheme is Polar.


Non Return to Zero Level (NRZ-L)
0 = Low voltage level (+V volts)
1 = High voltage level (-V volts)
Non Return to Zero Invert (NRZ-I)
0 = No changes voltage level
1 = Changes voltage level

52

Digital to Digital Encoding

cont.....

Non Return to Zero (NRZ)

cont

The main problem with NRZ encoding occurs when


the sender and receiver clocks are not synchronized.
The receiver does not know when one bit has ended
and the next bit is starting.
One solution is return-to-zero (RZ) scheme.

53

Digital to Digital Encoding

cont...

Return to Zero (RZ)

RZ uses there value: positive, negative and zero. The


signal changes not between bits but during the bit.
0 = Transition from high to low in the middle of a bit (-ve
in 1st half and 0 in 2nd half).
1= Transition from low to high in the middle of a bit (+ve
in 1st half and 0 in 2nd half).

54

Digital to Digital Encoding

cont...

Return to Zero (RZ) cont

The problem of RZ are:


That it requires two signal changes to encode a bit. A
sudden change of polarity resulting in all 0s interpreted
as 1s and all 1s interpreted as 0s but no DC component
problem.
Use three level of voltage which is more complex to
create and discern.
RZ has been replaced by better performing Manchester
and Differential Manchester schemes.

55

Digital to Digital Encoding

cont...

Manchester Code

Also known as Biphase Encoding.


The duration of the bit is divided into two halves. The
voltage remains at one level during the first half and moves
to the other level during the second half.
0 = Transition from high to low in the middle of a bit (-ve
in 1st half and +ve in 2nd half).
1= Transition from low to high in the middle of a bit (+ve in
1st half and -ve in 2nd half).
Since both 0 and 1 have mid-bit transitions, there is less/
no DC content. More importantly, this code is selfclocking (or self-synchronizing) code since a receiver can
extract the clock information from the incoming codes by
looking at the ever-present middle transitions.

56

Digital to Digital
Encoding
cont...
Manchester Code
1

cont
0

Note: There is always a transition at the


centre of bit duration.

57

Digital to Digital Encoding

cont...

Bipolar AMI (Alternate Mark Inversion)


0 = Neural zero (0 volts)
1 = Alternate Positive (+) and Negative (-) voltages for successive
1s
This code is used in long distance.
This code reduces/ no the DC(Direct Current) content from the line; the
1s will have positive voltage followed by negative voltage, in other
words, the voltages go up and down.
This code has a problem. A long stream of 0s can cause a receiver to
go out of synchronization (lose the bit boundaries) since 0s have no
voltage.
The commonly used cures are B8ZS and HDB3.

58

Digital to Digital Encoding

cont...

Bipolar AMI(Alternate Mark Inversion)

cont

59

Digital to Digital Encoding

cont...

High Density Bipolar Order 3 Encoding (HDB3)


Commonly used outside of North America.
The HDB3 code is a bipolar signaling technique (i.e. relies on the
transmission of both positive and negative pulses).
Four consecutive zero-level voltages are replaced with a
sequence of 000V or B00V.
The reason for two different substitutions is to maintain the even
number of nonzero pulses after each substitution.
The two rules states as follows:
a) If the number of nonzero pulses after the last substitution is
odd, the substitution pattern will be 000V, which makes the
total number of nonzero pulses even.
b) If the number of nonzero pulses after the last substitution is
even, the substitution pattern will be B00V, which makes the
total number of nonzero pulses even.
60

Digital to Digital Encoding

cont...

High Density Bipolar Order 3 Encoding (HDB3)

cont

61

Digital to Digital Encoding

cont...

High Density Bipolar Order 3 Encoding (HDB3)


Example:
The pattern of bits
11000011000000
+ - 0 0 0 0+ - 0 0 0 0 0 0 (AMI)

Encoded in HDB3 is:


+ - B 0 0 V - + B 0 0 V 0 0,
which is:
+ - +0 0 + - + - 0 0 - 0 0

Polarity of
preceding
pulse

cont
Number of
Bipolar
Pulses (Bit 1)
since Last
Substitution
Odd

Even

000-

+00+

000+ -00-

high density bipolar of order 3


(HDB3) code replaces any instance of
4 consecutive 0 bits with one of the
patterns "000V" or "B00V".
62

Digital to Digital Encoding

cont...

High Density Bipolar Order 3 Encoding (HDB3)

cont

Exercise:
Encoded the data below to AMI and HDB3:
a)

"10000110"

b)

"1010000011000011000000"

63

Digital to Digital Encoding cont...


High Density Bipolar Order 3 Encoding (HDB3)
Solution:
a)
The pattern of bits
"10000110"
the corresponding encoding using AMI is;
"+0000-+0"

cont

encoded in HDB3 is:


"+000V-+0"

b)

The pattern of bits


"1010000011000011000000"
the corresponding encoding using AMI is:
"+0-00000+- 0 000-+000000"
encoded in HDB3 is:
"+0- 000V0+-B00V-+B00V00"
which is:
"+0- 000 -0+- +00+-+ -00 -00"
64

Digital to Digital Encoding

cont...

DATA ENCODING WAVEFORM (NRZ, RZ and Manchester)

NRZ Non Return to Zero


(0 0, 1 +ve )
NRZ Non Return to Zero
(0 -ve, 1 +ve )
NZ Non Return to Zero
(0-ve in 1st half and 0 in 2nd
half, 1 +ve in 1st half and 0
in 2nd half)
Manchester
(0-ve in 1st half and +ve in
2nd half, 1 +ve in 1st half
and -ve in 2nd half)

65

Digital to Analogue Encoding


Information Signal is in digital waveform. While Carrier signal is in
analog waveform.
There are four basic technique for digital modulation .

66

Digital to Analogue Encoding cont....

Amplitude Shift Keying (ASK) - the amplitude (V) of the carrier is


varied proportional to the information signal.

Frequency Shift Keying (FSK) - the frequency (f) of the carrier is


varied proportional to the information signal.

Phase Shift Keying (PSK) - the phase () of the carrier is varied


proportional to the information signal.

Quadrature Amplitude Modulation (QAM) - both amplitude (V)


and phase () are varied proportional to the information signal.

67

Digital to Analogue Encoding

cont...

68

Digital to Analogue Encoding

cont...

Amplitude Shift Keying (ASK)

ASK is simplest digital modulation techniques.

ASK is a process where the binary information signal directly


modulates the amplitude of an analog carrier.

The carrier is transmitted when the modulating data is one and


the carrier is rejected from transmission when the data is zero

When the data is bit 1, the carrier signal has the amplitude,
when the data is bit 0, the amplitude of carrier signal is 0.

69

Digital to Analogue Encoding cont....


Frequency Shift Keying (FSK)

In FSK, the frequency of the carrier signal is varied to


represent data. Amplitude and phase of the carrier signal
remain the same.
As the binary input signal changes from a logic 0 to a logic
1 and vice versa, the output frequency shifts between two
frequencies: a mark, or logic 1 : high frequency (fm) and a
space, or logic 0 : low frequency (fs).
mark (fm) = logic 1 frequency
space (fs) = logic 0 frequency

70

Digital to Analogue Encoding cont....


Phase Shift Keying (PSK)
The phase of the carrier is varied to represent two or
more different signal elements. Both peak amplitude and
frequency remain constant.
The input is a binary digital signal and there are a limited
number of output phase possible.
The input binary information is encoded into groups of
bits before modulating the carrier.
The simplest form of PSK is binary shift keying (BPSK),
which have only 2 signal elements ; (phase of 0 & phase
of 180). These two phases will represent a logic 1 and
logic 0.
As the input digital signal changes (i.e. changes from a 1
to a 0 or from a 0 to a 1, the phase of the output carrier
shifts between two angles that are separated by 180).

71

Digital to Analogue Encoding cont....


Phase Shift Keying (PSK)

cont

Changes from a 1 to a 0 or from a 0 to a 1:


The phase of the output carrier shifts between
two angles that are separated by 180

72

Analogue to Analogue Encoding

Modulation has been defined as the process of combining


an input signal m (t) and a carrier frequency fc to produce
a signal s (t) whose bandwith is usually centered on fc.
Ex. Voice is represented by electromagnetic signal with
same frequency components and transmitted on voice
grade line
Can also produce a new analog signal at higher frequency.

73

Analogue to Analogue Encoding

cont...

Techniques used to modulate include


AM Amplitude Modulation
FM Frequency Modulation
PM Phase Modulation

74

Analogue to Analogue Encoding


cont...
Amplitude Modulation (AM)
AM also as ASK, means changing the height of the wave
to encode data.
Figure shows a simple case of amplitude modulation in
which one bit is encoded for each carrier wave change.
The frequency and phase of the carrier remain the same,
only the amplitude changes.
A high amplitude means
a bit value of 1.
Zero amplitude means
a bit value of 0.

75

Analogue to Analogue Encoding


cont...
Amplitude Modulation (AM) cont
Sending Multiple Bits Symbol
Each modification of the carrier wave to encode information is
called a symbol.
By using a more complicated information coding system, it is
possible to encode more than 1 bit/symbol.
Figure (b) gives an example of amplitude modulation using 4
amplitude levels, corresponding to 2 bits/symbol.
Increasing the possible number of symbols from 4 to 8
corresponds with encoding 3 bits/symbol, 16 levels to 4 bits,
and so on.

Fig (b) : Two-bit amplitude


modulation
76

Analogue to Analogue Encoding


cont...
Frequency Modulation (FM),
FM as FSK, means changing the frequency of the carrier
wave to encode data.
The peak amplitude and phase of the signal remain
constant.
Figure (c) shows a simple case of frequency modulation in
which one bit is encoded for each carrier wave change.
Changing the carrier wave to
a higher frequency encodes
a bit value of 1.
No change in the carrier wave
frequency means a bit value
of 0.

77

Analogue to Analogue Encoding


Phase Modulation (PM)

cont...

PM as PSK means changing the carrier waves phase to


carry data.
Figure (d) shows a simple case of phase modulation in
which one bit is encoded for each carrier wave change.
A 180o phase shift corresponds to change of bit either
from 1 to 0 or from 0 to 1. The normal carrier wave
would follow the broken line, but instead the phase
suddenly shifts and heads off in another direction.
No phase shift means the bit value remain the same.
Two bits per symbol could be encoded using phase
modulation using 4 phase shifts such as 0o, 90o, 180o and
270o.

78

Analogue to Digital Encoding


A digital signal is superior to an analog signal.

The tendency today is to change an analog signal to digital data.


In this section we describe pulse code modulation techniques.

Pulse Code Modulation (PCM)


The PCM is a technique to convert the analog signal to digital signal.
PCM also essentially analog-to-digital conversion of a special type where
the information contained in the instantaneous samples of an
analog signal is represented by digital words in a serial bit stream.
PCM consists of three steps to digitize an analog signal:
i. Sampling
ii. Quantization
iii. Encoding

79

Analogue to Analogue Encoding

cont...

Pulse Code Modulation (PCM)

cont...

The Sampling process is sometimes


referred to as a flat-top pulse
amplitude modulation signal (PAM)
Sampling
The analog signal is sampled
every Ts s, discrete in time.
Quantization
Makes the signal discrete in
amplitude.
Sampling
Encode
Maps the quantized values to
digital words that are bits long.

80

Analogue to Analogue Encoding

cont...

Pulse Code Modulation (PCM)

cont...

Three different sampling methods for PCM

81

Analogue to Analogue Encoding

cont...

Pulse Code Modulation (PCM)

cont...

Components of a PCM decoder

82

Analogue to Analogue Encoding

cont...

Pulse Code Modulation (PCM)

cont...

83

M-ary Coding

In binary coding:
Data bit 1 has waveform 1
Data bit 0 has waveform 2
Data rate = bit rate = symbol rate

In M-ary coding, take M bits at a time (M = 2k) and create a


waveform (or symbol).
00 waveform (symbol) 1
01 waveform (symbol) 2
10 waveform (symbol) 3
11 waveform (symbol) 4
Symbol rate = bit rate/k

84

M-ary Coding

cont

M-ary is a term derived from the word binary.


M = represents a digit that corresponds to the number of

conditions or levels or combinations possible for a given number of


binary variables (n).
For example, a digital signal with 4 possible conditions (either
voltage, levels, frequencies, phases and so on) is an M-ary system
where M = 4.
The number of bits that necessary to produce a given number of
conditions (M) is expressed mathematically as;

n log 2 M
Where;

n = number of bits
M = number of conditions, levels or
combinations possible with n bits

85

M-ary Coding

cont

Equation above can be simplified and rearranged to express the

number of conditions possible, M with n bits.

2n M
For example, with n = 1 bit, only 21 = 2 conditions are possible.

With two bits, 22 = 4 conditions are possible. With three bits, 23


= 8 conditions are possible, and so on.
M-ary Signaling

86

M-ary Coding

cont

Advantages:
Required transmission rate is low (bit rate/M).
Low bandwidth.
Disadvantages:
Low signal to noise ratio (due to multiple amplitude
pulses).

87

Digital to Analogue Encoding cont....


Quadrature Phase Shift Keying
(QPSK)
A phase modulation technique
that transmits two bits in four
modulation
states.

00 phase 0
10 phase 180
01 - phase 90
11 phase 270

88

Digital to Analogue Encoding cont....


PSK/QPSK
QPSK is a form of PSK in which two bits are modulated at
once, selecting one of four possible carrier phase shifts
0,90,180,270 or 0, 45, 135, .
QPSK perform by changing the phase of the In-phase (I)
carrier from 0 to 180 and the Quadrature-phase (Q) carrier
between 90 and 270.

QPSK
digital
data
is
represented by 4 points of a 2-bit
binary code around a circle
which correspond to 4 phases
of the carrier signal. These
points are called symbols.

89

Digital to Analogue Encoding cont....


PSK/QPSK

cont

90

Digital to Analogue Encoding cont....


PSK/QPSK
cont

Constellation diagram
example for BPSK.

Constellation diagram
for QPSK with Gray
coding. Each adjacent
symbol only differs by
one bit.
91

Digital to Analogue Encoding cont....


The 4-QAM (Quadrature Amplitude Modulation)
QAM is a combination of ASK and PSK so that a maximum

contrast between each signal unit (bit, dibit, tribit, and so


on) is achieved.

QAM technique that widely used to transmit digital signals

such as digital cable TV and cable Internet service, QAM


also used as the modulation technique in orthogonal
frequency division multiplexing .

The "quadrature" comes from the fact that the phase

modulation states are 90 degrees apart from each other.

92

Digital to Analogue Encoding cont....

The QAM

cont

93

Digital to Analogue Encoding cont....

The QAM
cont
4 QAM and 8 -QAM constellations

94

Digital to Analogue Encoding cont....


Comparison between QAM and QPSK
QAM

QPSK

Have amplitude levels

Using phases for


representation of messages.

Depending on type. i.e 16QAM,64-QAM,256-QAM.


How many amplitude levels to
be used accordingly i.e
16,64,256

2 bits per symbol is used with


four different phases.

95

Digital to Analogue Encoding cont....


The QAM

cont

Execise:
a)

Compute the bit rate for a 1000-baud 16-QAM signal.

b) Compute the baud rate for a 72,000-bps 64-QAM signal.

96

Digital to Analogue Encoding cont....


The QAM
cont
Solution:
a)

A 16-QAM signal has 4 bits per signal unit since


log216 = 4.
Thus,
(1000)(4) = 4000 bps

b)

A 64-QAM signal has 6 bits per signal unit since


log2 64 = 6.
Thus,
72000 / 6 = 12,000 baud

97

Data Transmitting
The importance of timing and framing

Data can be received appropriately without any error.


For example, if the sender sends data at the rate of
100Mbps speed, but the receiver can only process data at
a rate of 1Mbps, the data transmission will overload and
most of the transmitted data will be lost.

98

The importance of timing and framing cont


FRAMING (KERANGKA)
The data needs to pack bits into frames, so that each frame is
distinguishable from another.

A frame in a character-oriented protocol

The process of inserting additional bits along with the actual


data.
Bits may represent a station codes, error detection,
start/stop control bit either in front or end of the
data, or both.

Form a character or a complete block of


characters that is sent in each transmission.
99

The importance of timing and framing cont


FRAME STRUCTURE

HEADER

DATA

- consists of physical address (physical


address) sender and receiver.
- 48-bit address (6 bytes).
- consists of the codes related to the
station, start bit, SYN character , STX
and others.
- data

TRAILER - consists of error detection (Frame Check


Sequence), which includes error detection and
correction, ETX character and others.

10
0

The importance of timing and framing cont

TIMING (PEMASAAN)
Signal timing repetition signal (clock) used to control timing
operations.
Sender and receiver - should have the same timing bit so
that sampling process can be done appropriately (preferably
in the middle of the bit period) to determine exactly the level
of the data , either bit 0 or bit 1.

10
1

Data Transmitting

10
2

Data Transmitting
Parallel and Serial Transmission
Parallel Transmission

In this all the bits of a byte are


transmitted simultaneously on
separate wires.
Suitable for transmission over
short distance.
e.g.- Computer to Printer,
Communication within
the Computer

10
3

Data Transmitting
cont
Parallel and Serial Transmission cont
Serial Transmission

Bits are transmitted one


after the other
Usually
the
Least
Significant Bit (LSB) has
been transmitted first
Suitable for Transmission
over Long distance.

10
4

Data Transmitting

cont

Asynchronous and Synchronous Transmission


Timing problems require a mechanism to synchronize the transmitter and
receiver:
timing (rate, duration, spacing) of the data bits must be the same at
transmitter & receiver
receiver samples stream of data bits at bit intervals.
if clocks not aligned and drifting, the receiver will sample at wrong
time after sufficient bits are sent.
Example: for 1Mbps data stream, one bit will be transmitted every 1s.
With 1% clock drift at the receiver (faster or slower than transmitter),
then wrong sampling will occur after 50 bit (50*0.01s=0.5 s).

Two solutions to synchronizing clocks:


asynchronous transmission
synchronous transmission

105

Data Transmitting

cont

Asynchronous Transmission
Avoid timing problem by not sending long stream of bits.
Data is transmitted one character at a time, where each character is
five or eight bits in length
Receiver can synchronize at the beginning of each new character
idle state: no transmission,
NRZ-L signalling is common for asynchronous transmission.
The beginning of the character is signalled by a start bit .
This is followed by a character of 5 or 8 bits long as data.
The bits of the character are transmitted beginning with the least
significant bit
A parity bit is then added for the purpose of error detection.
The end of the character is a stop bit element.

106

Data Transmitting

cont.

Asynchronous Transmission

cont

107

Data Transmitting

cont

Asynchronous Transmission

cont

We send 1 start bit (0) at the beginning and 1 or more stop bits (1s) at the
end of each byte.
There may be a gap between each byte.

It is asynchronous at the byte level, bits are still synchronized;


their durations are the same.
10
8

Data Transmitting

cont

Asynchronous Transmission

cont

Effect of timing error in asynchronous transmission


Example: The figure below shows the effects of a timing error of sufficient
magnitude to cause error in reception. In this example, we assume a data
rate of 10Kbps; therefore each bit is 100s duration. Assume that the
receiver is fast by 6%, or 6s per bit time. Thus, the receiver samples the
incoming character every 94s. As we can see, the last sample is
erroneous.

109

Data Transmitting

cont

Synchronous Transmission
Block of data bits are transmitted as a frame.
Clocks must be synchronized:
can use separate clock line between transmitter & receiver
one side send one short pulse and the other side uses this
pulse for clocking; problem with long distances
or embed the clocking information in the data signal
Manchester encoding for digital signals
carrier frequency for analog transmission
Need to indicate start and end of block of data
use preamble (8bit flag) and postamble (8bit flag)
Control fields contain data link control protocol information.
More efficient (lower overhead) than asynchronous.

Synchronous Frame format


110

Data Transmitting

cont

Synchronous Transmission

cont

We send bits one after another without start or stop bits or gaps.
It is the responsibility of the receiver to group the bits.

111

11
2

Error and Error Coding

113

Error and Error Coding

cont

11
4

Error and Error Coding


(a) Single bit Error

cont

115

Error and Error Coding


cont
(b) Multiple bit and Burst Error
The condition when more than one bit is in error in a given number
of bits.
In case of burst error, if two or more bits from a data unit such as byte
change from 1 to 0 or from 0 to 1 then burst errors are said to have
occurred. the length of burst is measured from the first corrupted bit
to last corrupted bit.

116

Error and Error Coding

cont

(b) Multiple-bit and Burst Error

cont

117

Error and Error Coding

cont

Multiple-bit and Burst Error

cont

118

Error Control

Error control / Detection


Despite the best prevention techniques, errors may still
happen.
To detect an error, something extra has to be added to the
data/signal. This extra is an error detection code.
Lets examine two basic techniques for detecting errors:
Parity checking
Redundancy checking
~ VRC(Vertical Redundancy Check)
~ LRC(Longitudinal Redundancy) / BCC (Block Character
Checking)
~ Cyclic Redundancy Checksum (CRC).

11
9

Error Control cont


Error control / Detection

cont

120

Error Control cont


Error control / Detection

cont

One of the simplest error-detection schemes


It refers to the use of parity bits to check that data has
been transmitted accurately.
Add an extra bit to a code to ensure an even or odd
number of 1s.
1-bit error detection with parity.
Every code word has an even or odd number of 1s.
Parity checking has limitations.
It cannot detect an error when an even number of bits
change in the same data unit

121

Error control / Detection

cont

122

Error control / Detection

cont

(a) Parity Checks

What happens if the character 10010101 (parity bit is the last bit)
and the first two 0s accidentally become two 1s?
Thus, the following character is received: 11110101.
Will there be a parity error?
Problem: Simple parity only detects odd numbers of bits in
error (50%)

123

Error control / Detection

cont

(b) Cyclic Redundancy Checksum (CRC)

One of the simplest error-detection schemes

The CRC error detection method treats the packet of data


to be transmitted as a large polynomial.

The quotient is discarded but the remainder is attached to the


end of the message (remainder (mod) arithmetic).

The transmitter takes the message polynomial and using


polynomial arithmetic, divides it by a given generating
polynomial.

124

Error control / Detection

cont

(b) Cyclic Redundancy Checksum (CRC)

Polynomials
CRC generator(divisor) is most often represented not as
a string of 1s and 0s, but as an algebraic polynomial.

A polynomial representing a divisor

125

(b) Cyclic Redundancy Checksum (CRC)


EXAMPLE:
Data, M(x): 1001000
Generator, P(x): 1101

12
6

CRC Example Encoding


C(x) = x3 x2 1
M(x) = x7 x4 x3 x

= 1101
= 10011010

Generator
Message

11111001

1101

k + 1 bit check
sequence c,
equivalent to a
degree-k
polynomial

10011010000
1101

Message plus k
zeros

1001
1101

1000
1101

Result:

1011
1101

Replace the added data bit


0 with the remainder data
bit.

1100
1101

Remainder
m mod c

1000
1101
101

Transmit message followed


by remainder:
10011010101
127

CRC Example Decoding No Errors

11111001

Result:
CRC test is past.
128

CRC Example Decoding with Errors

Result:
CRC test is failed.
129

130

REFERENCES:
Main:
Forouzan, B.A. (2012). Data Communications
and Networking (5th edision). Mc Graw Hill.
(ISBN: 978-0-07-131586-9)

Additional:
William Stallings. (2011). Data And Computer
Communication (9th edition). Prentice Hall.
(ISBN-10: 0131392050)

13
1

You might also like