Download - 3 Digitization
-
7/28/2019 3 Digitization
1/32
Sampling First step in digitizing speech
Establish a set of discrete times at which the input waveform is
sampled Sampling Intervals
Regular
Irregular
Minimum sampling frequency is given by Nyquist theorem.
To reconstruct the original waveform from the sampled sequencethe sampling frequency must be at least twice the maximumfrequency of the original waveform.
Fs 2H
Fs=Sampling frequency or Nyquist rate
H=maximum frequency component in the analog waveform
-
7/28/2019 3 Digitization
2/32
Sampling H is the bandwidth of the input waveform
In this case the waveform is reconstructed by passing the sampled
values through a low pass filter which smoothens out or interpolates
the signal between sampled values
vi(t) vo(t)
T TT
time time
1
0
vi(t)
Input Signal
WaveformSampled Signal
Waveform
(i)(ii) Sampling (iii)
...011101010011010011...
Samples are coded for transmission
(iv)
Analogue-to-digitalConverter
Digital-to-analogue
Converter
Sampled signal is recovered
(v)
Vi(t)
-
7/28/2019 3 Digitization
3/32
PAM System
Sampling is a process of
multiplying a constant
amplitude impulse train
with the input signal
Like an Amplitude
modulation system where
pulse train acts as the
carrier
Called Pulse Amplitude
Modulation (PAM)
-
7/28/2019 3 Digitization
4/32
Foldover Distortion
For a sine carrier
Frequency range is Fc-H to Fc+H (Fc is carrier frequency)
For PAM, the output spectrum contains the fundamental as well as
the harmonics of the fundamentals.
If the pulse train is square wave with 50% duty cycle, only the
fundamental and odd harmonics are present. The low pass filter at
the receiver end allows only the baseband component 0-H to pass.
If Fs is less than twice H, portions of PAM spectrum overlaps
This overlapping of the sidebands produces beat frequencies that
interfere with the desired signal and such an interference is referred
as aliasing or foldover distortion. The filter used for band limiting the
input speech waveform is known as antialiasing filter..
-
7/28/2019 3 Digitization
5/32
Foldover Distortion
In digital speech system speech is sampled as 8KHz.
8KHz sampling results in oversampling.
This oversampling provides for the nonideal filter
characteristics such as lack of sharp cutoff.
The sampled signal is sufficiently attenuated at the
overlap frequency of 4 KHz. To adequately reduce the
energy level of the foldover spectrum
-
7/28/2019 3 Digitization
6/32
Quantization and Binary Coding
Pulse amplitude modulation systems are not useful over long
distance, for the vulnerability of individual pulse amplitudes to noise,distortion and crosstalk.
The susceptibility of amplitude may be eliminated by converting the
PAM samples into a digital format. (Using regenerative repeaters) A finite number of bits are used for coding PAM samples.
n bit number can represent 2n samples.
PAM samples amplitude can take on an infinite range of values.
The PAM sample amplitude is quantized to the nearest of a range of
discrete amplitude levels.
-
7/28/2019 3 Digitization
7/32
Quantization Process Signal V is confined to a range of VL
and VH. This range is divided into M(M=8) equal steps.
The step size S is given by
The center of each steps locate thequantization levels V0, V1V8.
Quantized signal Vq takes any of thequantized level value
A signal V is quantized to its nearestquantization level.
( )H LV VS =
The convention followed to quantize the signal is
Thus, the signal Vq makes quantum jump of step size S and at any instant of time thequantization error (V-Vq) has magnitude which is equal or less than S/2
The quantization in which the step size is uniform is called linear or uniform quantization.
q
q
V =V3 (if (V3-S/2) V< (V3+S/2)
V =V4 (if (V4-S/2) V< (V4+S/2)
-
7/28/2019 3 Digitization
8/32
Quantization
Quantization brings about a certain amount of noise in immunity to the
signal.
Repeaters with quantizers are used after certain distance to control the
variation in instantaneous amplitude for attenuation and channel noise
within S/2.
If instantaneous noise level is larger than S/2, error occurs in the
quantization level.
The quantized signal is an approximate of the original signal. Quality can be increased by increasing the number of quantization levels
Sometimes increased levels introduces noise in the repeaters.
The susceptibility to noise can be greatly minimized by resorting the digital
coding of the PAM sample amplitude Each quantized level is represented by a code number and transmitted
instead of the level value.
If binary arithmetic is used the number will be transmitted as a series of
pulses.
Such a system is called PCM System.
-
7/28/2019 3 Digitization
9/32
Binary PCM The analog signal is limited in
its excursions to the range -4
V to + 4V. The step size is 1 volt.
Eight quantization levels are
used and are located at -
3.5V, -2.5V ., +3.5V. Code
number 000 is assigned to -3.5V and so on.
If the analog samples are
transmitted the 1.3, 2.7, 0.5
etc will be transmitted.
If the quantized values are
transmitted voltages 1.5, 2.5,
0.5 etc will be transmitted
In binary PCM the binary
code patterns 101, 110,100are transmitted.
-
7/28/2019 3 Digitization
10/32
PCM System The functional diagram for PCM is shown in the next figure
The analog input V is bandlimited to 3.4 KHz to prevent aliasing and
sampled at 8 KHZ.
Samples are quantized to produce PAM signals, and applied to encoder.
Encoder generates a unique pulse pattern for each quantized sample level.
The quantizer and encoder together work as Analog to Digital Converter
(ADC)
Receiver first separates the noise from the signals.
A qunatizer does it by determining the two voltage levels of the pulse.
Then it regenerates the appropriate pulse depending on the decision.
The regenerated pulse train is now fed to a decoder which assembles the
pulse pattern and generates a corresponding quantised voltage level. Qunatizer and decoder work together as a Digital to Analog converter
(DAC)
The quantized PAM is now passed through a filter which rejects the
frequency components lying outside the baseband signal.
-
7/28/2019 3 Digitization
11/32
PCM System
-
7/28/2019 3 Digitization
12/32
Digital Data, Digital Signal
Digital signal
Discrete, discontinuous voltage pulses
Each pulse is a signal element
Binary data encoded into signal elements
-
7/28/2019 3 Digitization
13/32
Terms
Unipolar
All signal elements have same sign
Polar
One logic state represented by positivevoltage the other by negative voltage
Data rate
Rate of data transmission in bits per second
Duration or length of a bit
Time taken for transmitter to emit the bit
-
7/28/2019 3 Digitization
14/32
Terms
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
-
7/28/2019 3 Digitization
15/32
Interpreting Signals
Need to know
Timing of bits - when they start and end
Signal levels
Factors affecting successful interpreting ofsignals
Signal to noise ratio
Data rate Bandwidth
-
7/28/2019 3 Digitization
16/32
Analogue to Digital
After sampling, the analogue amplitude value of each
sampled (PAM) signal is quantized into one of a numberof L discrete levels. The result is a quantized PAM
signal.
A codeword can then be used to designate each level at
each sample time. This procedure is referred to as Pulse Code Modulation .
Low-pass
Filter
Encoder;
Pulse
modulate
Sampler Quantizer
Continuous-
time
message
signal
PCM
wave
Quantized
PAM signal
-
7/28/2019 3 Digitization
17/32
Encoding
After quantization, a digit is assigned to each of the
quantized signal levels in such a way that each level hasa one-to-one correspondence with the set of real
integers. This is called digitization of the waveform .
Each integer is then expressed as an n-bit binary
number, called codeword, or PCM word.
The number of codewords, M , is related to n by: 2n = M
Quantized
PAM
signal
A real
integer
PCM
codeword
(bit stream)
digitization To binary
-
7/28/2019 3 Digitization
18/32
Codeword
Quantization followed by digitization maps input
amplitudes into PCM words.
A cell is the set of input amplitudes mapped to a
codeword.There are M integers, PCM words, or codewords
to correspond to the M allowed output
amplitudes of the quantizer.
Codebook is the set of all these M codewords.
-
7/28/2019 3 Digitization
19/32
Analogue to Digital
time
Analoguewaveform
voltage
00000011010101111001101111011111
0010
010001101000101011001110
01
1110 1000 0100 0010 0000 0011 0101 1011
Bit stream
Sign bit
1 1 1 0 1 0 0 0 0 1 0 0 0 0 101 0 0 0 0 0 0 0 1 1 0 1 0 1 1 1
PCM Codeword
3. Digitize into real integers
1. Sample analogue waveform at discrete times
2.
Quantize
intodiscre
televels
01234567
-1
-2-3-4-5-6-7
-7 -4 -2 -1 0 1 2 5
4. To binary
-
7/28/2019 3 Digitization
20/32
Encoder Attributes
RZ (return to zero), NRZ (non-return to
zero)
Unipolar, Polar, Bipolar
Biphase
-
7/28/2019 3 Digitization
21/32
NRZ coding may be unipolar or polar
1 0 1 1 0 11 0 01
UnipolarNRZ-L
Polar
NRZ-L
-
7/28/2019 3 Digitization
22/32
NRZ-L Coding
NRZ-L (level):
1 higher level; 0 lower level
Used in SONET XOR bit sequence, and inearly magnetic tape recording
Long sequence of same bit causes
difficulty in clock recovery; also indetecting the average DC level
-
7/28/2019 3 Digitization
23/32
NRZ pros and cons
Pros
Easy to engineer
Make good use of bandwidth
Cons dc component
Lack of synchronization capability
Used for magnetic recordingNot often used for signal transmission
-
7/28/2019 3 Digitization
24/32
RZ Coding may be unipolar or bipolar
1 0 1 1 0 11 0 01
Unipolar
RZ
Bipolar
RZ
-
7/28/2019 3 Digitization
25/32
RZ Coding may be unipolar or bipolar
Unipolar-RZ:
1 is represented by positive for the first half of T and zero for the
second half.
0 is represented by 0
Bipolar-RZ:
1 is represented by positive for the first half of T and zero for the
second half.
0 is represented by negative for the first half of T and zero for the
second half.
Used in baseband data transmission, magnetic
recording.
The transitions at T/2 may be used for synchronization.
-
7/28/2019 3 Digitization
26/32
Quantization Noise
The quantized signal is an
approximation to the original signal andsome error.
The instantaneous errore= V-Vq is
randomly distributed within the range
S/2 and is called quantization error or
noise.
The mean square quantization error is
S2.
For linear quantization the probability
distribution of the error is constant
within the (S/2).
-
7/28/2019 3 Digitization
27/32
Quantization Noise
The average qunatizationnoise output power is given by
the variance
Where =mean, which is zerofor qunatization noise.
The range of qunatization error
(S/2) determines the limits ofintegration.
/ 2
2 2
/ 2
/ 2
2
/ 2
/ 23
/ 2
2
1( 0)
1
1
3
12
S
S
S
S
S
S
e deS
e
S
e
S
S
=
=
=
=
2 2( ) ( )e p e de
=
-
7/28/2019 3 Digitization
28/32
Quantization Noise
Signal to quantization noise ratio (SQR) is a good measure of
performance of a PCM system transmitting speech.
If Vr is the r.m.s. value of the input signal and the resistance level is
1 ohm, then SQR is given by
( ) ( )2
210log
12
10log(12) 20log
10.8 20log
r
r
r
VSQR dBS
VdBS
VdB
S
=
= +
= +
-
7/28/2019 3 Digitization
29/32
Quantization Noise
If the input signal is a sinusoidal wave and Vm as the maximum
amplitude, SQR may be calculated from the full range sine wave as
( )
( )
2
210log122
10log(6) 20log
7.78 20log
m
m
m
V SSQR dB
V S dB
V S dB
=
= +
= +
-
7/28/2019 3 Digitization
30/32
Quantization Noise
Expressing S in terms of Vm and the
number of steps, M, we have
( )( )
2
2 2
2
210log
4 12
10log(1.5 )20log(1.225 )
m
m
VSQR dB
V M
M dBM dB
=
==
-
7/28/2019 3 Digitization
31/32
Quantization Noise
Quantity 1.225M represents the signal to quantization
noise voltage ratio for a full range sinusoidal input
voltage.
M=2n, where n is the number of bits used to code a
quantization level. Therefore
20log(1.225) 20 log(2)
1.76 6.02
SQR n dB
n dB
= +
= +
-
7/28/2019 3 Digitization
32/32
Quantization Noise
The table is showing
the values of SQR fordifferent binary code
word sizes for
sinusoidal input
systems
Every additional code
bits gives an
increment of 6 dB in
SQR