Sie sind auf Seite 1von 34

Lecture 4:

Signal Encoding Techniques

ELE4NET: Signal Encoding

Electronic Engineering

Encoding and Modulation Techniques


Overview

ELE4NET: Signal Encoding

Electronic Engineering

Encoding and Modulation Techniques


Overview (contd)
Digital data, digital signal
NRZ, Multilevel binary, Biphase

Digital data, analog signal


ASK, FSK, PSK

Analog data, digital signal


PCM, DM

Analog data, analog signal


AM, FM, PM

ELE4NET: Signal Encoding

Electronic Engineering

Digital Data, Digital Signal


Digital signal
Discrete, discontinuous voltage pulses
Each pulse is a signal element
Binary data are transmitted byencodingeachdatabit
intosignalelements

User input at a PC is converted into a stream of binary


digits (1s and 0s). Binary 1 is represented by -5v and
binary 0 by +5v.
ELE4NET: Signal Encoding

Electronic Engineering

Some Terms
Unipolar
All signal elements have same sign (all positive or all negative)

Polar
One logic state represented by positive voltage, the other by
negative voltage

Data signaling rate (or just data rate)


Rate of data transmission in bits per second (bps)

Duration or length of a bit


Time taken for transmitter to emit the bit (for data rate R, bit
duration is 1/R)

Modulation rate
Rate at which the signal level changes
Measured in baud = signal elements per second

Mark and Space


Binary 1 and Binary 0 respectively
ELE4NET: Signal Encoding

Electronic Engineering

Interpreting Signals
To interpret digital signals, the receiver needs to know
Timing of each bit - when a bit starts and ends
Signal level (high [0] or low [1]) for each bit position

Factors affecting successful interpreting of signals

Signal to noise ratio (SNR)


Data rate
Bandwidth
Encoding scheme (i.e. mappingdatabitstosignalelements)

With other factors held constant, the following are true:


An increase in data rate increases bit error rate (BER).
An increase in SNR decreases BER.
An increase in bandwidth allows an increase in data rate.

ELE4NET: Signal Encoding

Electronic Engineering

When comparing different encoding schemes,


we need to consider
Signal Spectrum
Lack of high frequencies reduces required bandwidth
Lack of dc component allows ac coupling via transformer, providing
electrical isolation
Concentrate power in the middle of the transmission bandwidth

Clocking
Synchronizing transmitter and receiver
External clock or self clocking?

Error detection
Responsibility of data link control
But can be built into signal encoding to detect errors more quickly

Signal interference and noise immunity


Some codes are better than others, performance measured by BER

Cost and complexity


Higher signaling rate lead to higher costs
Some codes require signaling rate greater than data rate
ELE4NET: Signal Encoding

Electronic Engineering

Nonreturn to Zero-Level (NRZ-L)


Two different voltage levels for two binary bits
Voltage constant during bit interval
no transition, i.e. no return to zero voltage

Implementations:
Unipolar (absence of voltage for one, constant positive voltage for
zero)
Polar (negative voltage for one value and positive for the other)
0 = high level
1 = low level

ELE4NET: Signal Encoding

Electronic Engineering

Nonreturn to Zero Inverted (NRZ-I)


Nonreturn to zero, inverted on ones
Constant voltage pulse for duration of bit
Data encoded as presence or absence of signal transition at
beginning of bit time
Transition (low to high or high to low) denotes a binary 1
No transition denotes binary 0
NRZ-I is a type of differential encoding
Differential encoding rule: if the current bit is a binary 0, then the
current bit is encoded with the same signal as the preceding bit; if
the current bit is a binary 1, then the current bit is encoded with a
different signal than the preceding bit.
In differential encoding, data represented by changes rather than
levels. In the presence of noise, it is more reliable to detect a
transition than to compare a value to a threshold.

ELE4NET: Signal Encoding

Electronic Engineering

NRZ Pros and Cons


Pros
Easy to engineer
Make good use of bandwidth (requires half the bandwidth of
Manchester in some cases)

Cons
dc component
Lack of synchronization capability
e.g. with a long string of 1s or 0s for NRZ-L or a long string of 0s
for NRZI, the output is a constant voltage over a long period of
time. So any drift between the clocks of transmitter and receiver
will result in loss of synchronization between the two

Used for digital magnetic recording


Not often used for signal transmission
ELE4NET: Signal Encoding

Electronic Engineering

10

Multilevel Binary Bipolar-AMI


Bipolar-AMI (Alternate Mark Inversion)
0 represented by no line signal (0v)
1 represented by alternating positive and negative pulses
(e.g. +5, -5, +5)
Binary 1 pulses alternate in polarity
No loss of sync if a long string of 1s occurs (0s still a
problem)

ELE4NET: Signal Encoding

Electronic Engineering

11

Multilevel Binary Pseudoternary


Reverse of Bipolar-AMI
1 represented by no line signal (0v)
0 represented by alternate positive and negative pulses (e.g.
+5, -5, +5)
Binary 0 pulses alternate in polarity
No loss of sync if a long string of 0s occurs (1s still a problem)
No advantage or disadvantage over bipolar-AMI

ELE4NET: Signal Encoding

Electronic Engineering

12

Multilevel Binary Pros and Cons


Use more than two voltage levels to represent data:
Bipolar-AMI (Alternate Mark Inversion)
Pseudoternary

Advantages
No net dc component
Less bandwidth than NRZ
No loss of synchronization if a long string of 1s occurs in BipolarAMI or a long string of 0s in Pseudoternary

Disadvantages:
Synchronization problem with long runs of 0s in the case of AMI
or 1s in the case of pseudoternary
Not as efficient as NRZ
Each signal element only represents one bit (although for 3-level
systems, each signal element could represent log 23 = 1.58 bits)

Receiver must distinguish between three levels (+A, -A, 0)


Requires approx. 3dB more signal power than a two-valued signal
for the same probability of bit error

ELE4NET: Signal Encoding

Electronic Engineering

13

Biphase Manchester

Transition in the middle of each bit period


Transition serves as clock and data
Low to high represents one
High to low represents zero
Specified in IEEE 802.3 (Ethernet) for baseband coaxial
cable and twisted-pair bus LANs

ELE4NET: Signal Encoding

Electronic Engineering

14

Biphase Differential Manchester

Midbit transition is clocking only


Always a transition in middle of interval
Transition at start of a bit period represents zero
No transition at start of a bit period represents one
Specified in IEEE 802.5 for token ring LANs

ELE4NET: Signal Encoding

Electronic Engineering

15

Biphase Pros and Cons


At least one possibly 2 transitions per bit time
Types:
Manchester
Differential Manchester

Advantages:
Synchronization: self clocking (midbit transition serves
as a clock)
No dc component
Built-in error detection (absence of an expected
transition can be used to detect errors)

Disadvantages
Maximum modulation rate is twice that for NRZ
Requires more bandwidth than multilevel binary codes
ELE4NET: Signal Encoding

Electronic Engineering

16

Data Rate and Modulation Rate


Data rate (expressed in
bits per second) and
modulation rate
(expressed in baud).
The data rate, or bit
rate, is 1/Tb, where Tb =
bit duration.
The modulation rate
is the rate at which
signal elements are
generated.
The figure shows that
the maximum
modulation rate for
Manchester is 2/Tb.

ELE4NET: Signal Encoding

In this case, the bandwidth of Manchester is


twice that of NRZI.
Electronic Engineering

17

Scrambling
Despite the self-clocking mechanism, biphase codes are not
widely used in long-distance applications because they
require a high signaling rate relative to data rate
Scrambling use filling sequences to replace sequences that
would produce constant voltage
Requirements:

Must produce enough transitions to maintain sync


Must be recognized by receiver and replaced with original sequence
Same length as original
No dc component
No long sequences of zero-level line signal
No reduction in data rate
Error detection capability

Implementations:
B8ZS (bipolar with 8-zeros substitution)
HDB3 (high-density bipolar-3 zeros)
ELE4NET: Signal Encoding

Electronic Engineering

18

B8ZS (Bipolar with 8-Zeros Substitution)


Based on bipolar-AMI
If an octet of all zeros occurs and last voltage pulse preceding this
octet was positive, encode as 000+-0-+
If an octet of all zeros occurs and last voltage pulse preceding this
octet was negative, encode as 000-+0+ Causes two violations of AMI code, an event unlikely to occur as
a result of noise
Receiver detects and interprets the octet as all zeros

ELE4NET: Signal Encoding

B=valid bipolar
signal
V=Bipolar violation
Electronic Engineering

19

HDB3 (High-Density Bipolar-3 Zeros)


Based on bipolar-AMI
String of 4 zeros replaced with one or two pulses with 4th zero replaced with a code violation

B=valid bipolar signal


V=Bipolar violation

ELE4NET: Signal Encoding

Electronic Engineering

20

Digital Signal Encoding Schemes (Summary)

ELE4NET: Signal Encoding

Electronic Engineering

21

Digital Data, Analog Signal


Transmittingdigitaldatausinganalogsignals
Public telephone system
Voice frequency range 300Hz to 3400Hz
Use modem (modulator-demodulator), whichconvertsdigitaldata
toanalogsignals,andviceversa

Modulation involves operation on one or more of the three


characteristics of a carrier signal: amplitude, frequency,
and phase.
Encoding/modulation techniques
Amplitude shift keying (ASK)
Frequency shift keying (FSK)
Phase shift keying (PSK)

ELE4NET: Signal Encoding

Electronic Engineering

22

Amplitude Shift Keying


Two binary values represented by two different amplitudes of the carrier
frequency
Usually, one amplitude is zero
i.e. one binary digit is represented by the presence, at constant amplitude, of
the carrier, the other by the absence of the carrier.

A cos(2f c t ) binary1
Susceptible to sudden gain changes
s (t )
Inefficient modulation
0
binary 0

Up to 1200bps on voice-grade lines


Used to transmit digital
data over optical fiber

ELE4NET: Signal Encoding

Electronic Engineering

23

Binary Frequency Shift Keying


Most common form is binary FSK (BFSK)
Two binary values represented by two different frequencies
(near carrier)
A cos(2f t ) binary 1
1

s (t )

A cos(2f 2t ) binary 0

where f1 and f2 are offset from the carrier frequency by equal but
opposite amounts
Less susceptible to error than ASK
Up to 1200bps on voice-grade lines
Used for high frequency radio transmission (3-30 MHz)
Used at even higher frequency on LANs using co-axial cable

Multiple FSK (MFSK):


more than two
frequencies used.
ELE4NET: Signal Encoding

Electronic Engineering

24

Phase Shift Keying


Phase of carrier signal is shifted to represent data
Binary PSK
Two phases represent two binary digits

A cos(2f c t )

BPSK s (t )

binary1

A cos(2f c t ) A cos(2f c t ) binary 0

Differential PSK
Phase shift is relative to
previous transmission rather
than some reference signal. DPSK
Binary0isrepresentedby
sendingasignalburstofthe
samephaseastheprevious
signalburstsent.Binary1is
representedbysendinga
signalburstofoppositephase
totheprecedingone.
ELE4NET: Signal Encoding

Electronic Engineering

25

Modulation of Analog Signals for Digital Data

ELE4NET: Signal Encoding

Electronic Engineering

26

Analog Data, Digital Signal


Transforming analog data into digital signals
Analog data, such as voice and video, is often digitized to be
able to use digital transmission facilities. Strictly speaking, the
process of converting analog data into digital data is known as
digitization.
Once analog data have been converted into digital data, the
following can happen:
The digital data can be transmitted using NRZ-L. In this case, we
have in fact gone directly from analog data to a digital signal.
The digital data can be encoded as a digital signal using a code
other than NRZ-L. Thus an extra step is required.
The digital data can be converted into an analog signal via ASK,
FSK, or PSK.

The device used for converting analog data into digital form for
transmission, and subsequently recovering the original analog
data from the digital, is known as a codec (coder-decoder). Two
principal techniques used in codecs:
Pulse code modulation (PCM)

ELE4NET: Signal Encoding

Electronic Engineering

27

Pulse Code Modulation


PCM is based on sampling theorem: If a signal is
sampled at regular intervals at a rate higher than twice the
highest signal frequency, the samples contain all the
information of the original signal.
Voice data are limited to below 4000Hz. Require 8000
samples per second.
However, these are analog samples, called pulse amplitude
modulation (PAM) samples.
To convert to digital, each of these analog samples must be
assigned a binary code.

ELE4NET: Signal Encoding

Electronic Engineering

28

Pulse Code Modulation (contd)


Each PAM sample is approximated by being quantized into one of
16 different levels. Each sample can then be represented by 4 bits.

ELE4NET: Signal Encoding

Electronic Engineering

29

Pulse Code Modulation (contd)


If we use an 8-bit sample, which allows 256 quantizing
levels, the quality of the recovered voice signal is
comparable with that achieved via analog transmission.
This implies that a data rate of 8000 samples per second
8 bits per sample = 64 kbps is needed for a single voice
signal.

PCM block diagram


ELE4NET: Signal Encoding

Electronic Engineering

30

Delta Modulation
A variety of techniques have been used to improve the
performance of PCM or to reduce its complexity. One of
the most popular alternatives to PCM is delta modulation
(DM).
With DM, analog input is approximated by a staircase
function that moves up or down one quantization level ()
at each sampling interval.
The staircase function has binary behavior
Hence encode each sample as a single binary digit
1 for up, 0 for down

ELE4NET: Signal Encoding

Electronic Engineering

31

Delta Modulation Example

ELE4NET: Signal Encoding

Electronic Engineering

32

DM & PCM - Performance


Two important parameters in DM: step size and sampling rate.
When the analog waveform changes very slowly, there will be
quantizing noise. This noise increases as increases. When the
analog waveform changes more rapidly than the staircase can
follow, there is slope overload noise. This noise increases as
decreases. So must be chosen to balance two types of noise.
The accuracy of DM can be improved by increasing the
sampling rate. However, this increases the data rate of the output
signal.
DM is simpler to implement than PCM.
PCM exhibits better SNR characteristics at the same data rate.
Bandwidth issue: for good voice reproduction with PCM
128 levels (7 bits)
With voice bandwidth 4 kHz, we need 8000 x 7 = 56kbps, this digital
signal could require on the order of 28 kHz of bandwidth.

Digital techniques continue to grow in popularity for


transmitting analog data. See reasons in Stallings pp.195-196.
ELE4NET: Signal Encoding

Electronic Engineering

33

Analog Data, Analog Signals


Analog data can be modulated by a carrier frequency to
produce an analog signal in a different frequency band,
which can be utilized on an analog transmission system.
Why modulate analog signals?
A higher frequency is needed for effective transmission, e.g. voice
signalsaretransmittedovertelephonelinesattheiroriginal
spectrum(basebandtransmission),forunguidedtransmission,itis
virtuallyimpossibletotransmitbasebandsignals.
Permits frequency division multiplexing (chapter 8)

Types of modulation
Amplitude modulation(AM)
Frequency modulation(FM)
Phase modulation(PM)
ELE4NET: Signal Encoding

Electronic Engineering

34

Das könnte Ihnen auch gefallen