EE4512 Analog and Digital Communications Chapter 8. Chapter 8 Analog-to. to-digital and Digital to Analog Conversion

EE4512 Analog and Digital Communications Chapter 8 Analog-to-Digital and Digital to Analog Conversion Chapter 8 EE4512 Analog and Digital Communic...
Author: Jerome Williams
31 downloads 3 Views 4MB Size
EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital to Analog Conversion

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Sampling and Quantization • Pages 390-391

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• Traditional analog transmission (AM, FM and PM) are less complex than digital data transmission have been the basis of broadcasting and communication for 100 years. S&M Figure 8-1a

Analog television signal

Analog television spectrum

EE4512 Analog and Digital Communications

Chapter 8

• Digital data transmission (PAM, ASK, PSK, FSK and QAM) is more complex but (perhaps) offers higher performance with control of accuracy and easier storage, simpler signal processing for noise reduction, error detection and correction and encryption.

S&M Figure 8-1b

EE4512 Analog and Digital Communications

Chapter 8

• Digital data transmission requires analog-to-digital (ADC) and digital-to-analog (DAC) converters. The ADC process utilizes sampling and quantization of the continuous analog signal. ADC

DAC

S&M Figure 8-1b

EE4512 Analog and Digital Communications

Chapter 8

• ADC sampling occurs at a uniform rate (the sampling rate) and has a continuous amplitude. S&M Figure 8-2a,b

Uniform sampling rate

Analog signal

Continuous amplitude

EE4512 Analog and Digital Communications

Chapter 8

• The continuous amplitude sample is then quantized to n bits or resolution for the full scale input or 2n levels. Uniform sampling rate

Continuous amplitude

Quantized

S&M Figure 8-2b,c

EE4512 Analog and Digital Communications

Chapter 8

• Here n = 4 and there are 24 = 16 levels for a full scale input of 2 V (± 1 V). The step size = 2 V / 16 = 0.125 V and the quantized value is the midpoint of the voltage range.

S&M Table 8.1

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Sampling Baseband Analog Signals • Pages 392-399

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• The analog signal x(t) which is continuously, uniformly sampled is represented by: ∞

x s (t) = x(t) ∑ δ(t − kTS )

S&M Eq. 8.1

k = −∞

Multiplication in the temporal domain is convolution in the frequency domain and the frequency domain representation is:  ∞  Xs (f) = X(f) ∗  ∑ δ(t − k TS ) k = −∞ 

F

 Xs (f) = X(f) ∗ fS  Xs (f) = fS





k = −∞

 δ(f − k fS ) ∑ k = −∞  ∞

X(f − k fS )

S&M Eq. 8.2

EE4512 Analog and Digital Communications

Chapter 8

• Temporal and spectral representation of the continuous sampling process for a sum of three sinusoids.





k = −∞



δ(t − kTS )



x s (t) = x(t) ∑ δ(t − kTS )

∑ δ(f − k f

S

k = −∞

Xs (f) = fS





k = −∞

)

X(f − k fS )

k = −∞

S&M Figure 8-3

EE4512 Analog and Digital Communications

• 2 V, 20° initial phase, 500 Hz sinusoid sampled at 5 k samples/sec

S&M Figure 8-4a,b

Chapter 8

EE4512 Analog and Digital Communications

• Aliased samples can be reconstructed for a 4500 Hz and a 5500 Hz sinusoid that appears to be a 500 Hz sinusoid

S&M Figure 8-4a,c,d

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• The aliasing of the signal can be predicted by the magnitude spectrum of the original 500 Hz sampled signal. If the 4500 Hz and 5500 Hz signals are then sampled at S&M Figure 8-4a,b 5 k samples/sec aliasing at occurs at | 4500 – 5000 | and (5500 – 5000) Hz

EE4512 Analog and Digital Communications

• The sum of three sinusoids does not have any aliased frequencies since the sampling frequency fS is greater than twice the highest frequency fmax

Chapter 8

S&M Figure 8-4a,c

fS > 2 fmax S&M Figure 8-5

EE4512 Analog and Digital Communications

• The frequency 2 fmax is called the Nyquist frequency. Harry Nyquist, S&M Figure 8-4a who contributed to the understanding of thermal noise while at Bell Labs, is also remembered in electrotechnology for his analysis of sampled data signals. Harry Nyquist 1889-1976

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• The analog signal is reconstructed from the quantized samples by a DAC and a low pass filter (LFP). S&M Figure 8-6

EE4512 Analog and Digital Communications

Chapter 8

• For practical signals fS > 2 fmax using a guard band for LPFs fS = 2 fmax

Guard band fS > 2 fmax

S&M Figure 8-7

EE4512 Analog and Digital Communications

Chapter 8

• With out-of-band noise and sample signals, aliases of the noise now appear in-band and should be filtered before the sampling process. S&M Figure 8-8

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Sampling Baseband Analog Signals • Pages 302-312

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• The periodic baseband signal consisting of three sinusoids is impulse sampled, sampled-and-held, processed by an 8-bit ADC-DAC and a quantizer in SystemVue.

Impulse sampler

Sample-and-hold

ADC

SVU Figure 6.1

Quantizer

DAC

EE4512 Analog and Digital Communications

Chapter 8

• The periodic baseband signal is the sum of a 1 V 500 Hz, a 0.5 V 1.5 kHz and a 0.2 V 2.5 kHz sinusoid. SVU Figure 6.2

EE4512 Analog and Digital Communications

Chapter 8

• The power spectral density (PSD) of the periodic baseband signal has the expected peaks at 0.5, 1.5 and 2.5 kHz. SVU Figure 6.3 Three sinusoids

EE4512 Analog and Digital Communications

Chapter 8

• The periodic baseband signal is overlaid with the continuous amplitude sample-and-hold signal with fS = 8 kHz. SVU Figure 6.4

0.125 msec

EE4512 Analog and Digital Communications

Chapter 8

• The analog signal x(t) here is sampled and held rather than impulse sampled:

y s-h (t) = ∑ x(nTS ) h(t − nTS ) h(t) = 1

0 ≤ t ≤ TS

n

h(t) = 0

otherwise

SVU Eq. 6.3

The power spectral density (PSDs-h) of the sample and hold operation is:

PSDs-h = fS2 PSDs-h =





k = −∞





k = −∞

| X(f − k fS ) | 2 TS2 sinc 2 ( 2π f TS )

| X(f − k fS ) | 2 sinc 2 ( 2π f TS ) SVU Eq. 6.4

EE4512 Analog and Digital Communications

Chapter 8

• The PSD of the continuous amplitude sample and hold sum of three sinusoid signal with fS = 8 kHz is: SVU Figure 6.6 8 kHz

16 kHz

Sinc2 term

EE4512 Analog and Digital Communications

Chapter 8

• However, if the analog signal x(t) is impulse sampled:

x(nTS ) = ∑ x(t) δ(t − nTS )

SVU Eq. 6.1

n

Then the power spectral density (PSD) does not have a sinc2 term:

PSD = fS2





k = −∞

| X(f − k fS ) | 2

SVU Eq. 6.2

The PSDs-h does have the sinc2 term:

PSDs-h =





k = −∞

| X(f − k fS ) | 2 sinc 2 ( 2π f TS ) SVU Eq. 6.4

EE4512 Analog and Digital Communications

Chapter 8

• The PSD of the continuous amplitude sample and hold sum of three sinusoid signal with fS = 8 kHz is: SVU Figure 6.5 8 kHz

16 kHz

No sinc2 term

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Sampling Bandpass Analog Signals • Pages 399-400

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• A bandpass signal does not need to be sampled at 2 f2. Nyquist’s bandpass sampling theory states that the sampling rate fS > 2(f2 − f1) which is substantially less than 2 f2 S&M Figure 8-9 8

LPF 10 kHz

BPF 8-10 kHz

10 kHz

f1 f2

fS = 20 ksamples/sec

fS = 7 ksamples/sec

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Sampling Bandpass Analog Signals • Pages 339-342

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• A SystemVue simulation of bandpass sampling utilizes the sum of the same three sinusoids to modulate a DSC-LC AM signal with fC = 20 kHz.

SVU Figure 6-34

EE4512 Analog and Digital Communications

Chapter 8

• The SystemVue simulation initially uses a sampling rate of 5 MHz and results in 4 194 304 = 222 sampling points. The PSD shows the DSB-LC AM signal with the LSB and USB. fC LSB

USB

Scaled PSD fmax = 2.5 MHz

SVU Figure 6-35

EE4512 Analog and Digital Communications

Chapter 8

• The bandwidth of the bandpass signal is f2 − f1 = 22.5 − 17.5 = 5 kHz and the SystemVue sampling rate is set to 50 kHz and results in only 32 768 = 215 sampling points. fC* LSB

USB

Scaled PSD fmax = 25 kHz

SVU Figure 6-36

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Quantizing Process: Uniform Quantization • Pages 400-404

Chapter 8

EE4512 Analog and Digital Communications

Chapter 8

• The quantizing process divides the range (± full scale) into 2n (n = 4 here) regions which are assigned an n-bit binary code.

S&M Figure 8-10

EE4512 Analog and Digital Communications

Chapter 8

• The error associated with the quantizing process is assumed to have a uniform probability density function. The maximum error for uniform quantization is:  2 Vmax q = ± 0.5  n  2

Vmax   = ± 2n 

The quantizer range is ± Vmax and the uniform quantizer voltage step size is: ∆=

2 Vmax Vmax = n-1 n 2 2

SVU Eq. 6.6

S&M Figure 8-11 The mean square quantizing Eq is the normalized quantizing noise power: ∆/2

2 2 Vmax Vmax 1 ∆2 2 = = Eq = q dq = 2 ∫ n ∆ −∆ / 2 12 3 2 3 22n

( )

( )

SVU Eq. 6.7

EE4512 Analog and Digital Communications

Chapter 8

• The signal to quantizing noise power (SNRq) is: SNRq =

12 PS PS 2n 3 2 = 2 ∆2 Vmax

( )

SVU Eq. 6.8

PS is the normalized power of the signal that is quantized. For the ADC here ∆ = 10 mV and n = 8. The sum of three sinusoids as the input signal has a peak amplitude of 1.1 V and the quantizing noise has a peak amplitude of 4 mV.

SVU Figure 6.7

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Quantizing Process: Nonuniform Quantization • Pages 400-404

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• Nonuniform quantization divides the dynamic range of an analog signal into nonuniform quantization regions. Lower magnitudes have smaller quantization regions than high magnitudes. The quantization of speech benefits from nonuniform quantization since the perception of hearing is logarithmical rather than linear.

EE4512 Analog and Digital Communications

• Uniform quantization (top) results in a large amount of error for small sample amplitude. Non-uniform quantization (bottom) reduces the error for small sample amplitudes.

Uniform quantization

Nonuniform quantization

S&M Figure 8-13

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• Uniform quantization is simpler to implement so a compressor (a non-linear transfer function) is used before the quantizer.  Vin  ln  1+µ  The µ-Law Vmax  Vin  compressor Vout = Vmax 0 ≤ ≤1 ln (1+µ) Vmax is used in telephony SVU with Eq. 6.10 µ = 255. At the receiver an expander has the inverse non-linear transfer function and results in companding (COMpressing and exPANDING).

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Companding and Pulse Code Modulation • Pages 312-320

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• The µ-Law compander concept can be simulated in SystemVue. An 8-bit ADC-DAC quantizer processes the speech signal after µ-Law compression. SVU Figure 6.15

EE4512 Analog and Digital Communications

Chapter 6

• The pulse code modulator (PCM) transmitter utilizes a µ-Law compressor, an 8-bit ADC and a parallel-to-serial data converter.

SVU Figure 6.19

EE4512 Analog and Digital Communications

• The parallel-to-serial data converter uses an 8-bit to 1-bit multiplexer. A 3-bit counter sequences the multiplexer to select 1 of the 8 inputs.

Chapter 6

SVU Figure 6.20

Multiplexer

3-bit counter

EE4512 Analog and Digital Communications

Chapter 6

• The pulse code modulator (PCM) receiver utilizes a serial to-parallel data converter, an 8-bit DAC and a µ-Law expander.

SVU Figure 6.19

EE4512 Analog and Digital Communications

• The serial-to-parallel data converter uses an 8-bit shift register to buffer the data and an 8-bit latch hold and output the data.

Chapter 6

SVU Figure 6.21

Shift register

Latch

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Differential Pulse Code Modulation • Pages 407-411

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• Sampled speech data are highly correlated and differential pulse code modulation (DPCM) exploits this to lower the overall data rate. DPCM uses a predictor to subtract a predicted S&M Figure 8-15 value from the input. The error difference is sent.

EE4512 Analog and Digital Communications

• The predictor is a recursive equation, for example: S(n) = 0.75 s(n−1) + 0.2 s(n−2) +0.05 s(n−3) where S(n) is the predicted value of the n th sample and s(n-i) is the n-i th sample. The error signal is s(n) − S(n)

S&M Figure 8-15

Chapter 6

EE4512 Analog and Digital Communications

Chapter 6

• A typical continuous analog signal is sampled and results in a discrete signal s(n), The discrete predicted signal S(n) is recursively computed. The discrete error signal is transmitted and has less quantizing bits than the actual discrete signal. S&M Figure 8-16b

EE4512 Analog and Digital Communications

Chapter 6

• A DPCM example of actual discrete values, predicted values and the error terms:

S&M Table 8-3

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Differential Pulse Code Modulation • Pages 333-339

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• The differential pulse code modulator (DPCM) can be simulated in SystemVue. The serial data transmission PCM system is not implemented and a 4-bit error signal is sent in parallel.

Predictor and error signal MetaSystem

Predictor and signal reconstruction MetaSystem

Input

Amplifier LPF

SVU Figure 6.28

EE4512 Analog and Digital Communications

Chapter 6

• The first order linear predictor MetaSystem determines the error signal: e(n) = s(n+1) − 2 s(n) + s(n-1) Error signal

Input

Command

SVU Figure 6.29

EE4512 Analog and Digital Communications

Chapter 6

• The peak magnitude of the error signal is 0.32 V. The peak magnitude of the sinusoidal input test signal is 1 V. The PCM transmitted error signal requires only 4 bits, rather than the 8 bits required for the sampled input signal. SVU Figure 6.30

EE4512 Analog and Digital Communications

Chapter 6

• The first order linear predictor MetaSystem reconstructs and estimate of the signal se(n) from the error signal e(n) received Reconstructed signal and past estimates: se(n+1) = e(n+1) + 2 se(n) − se(n−1)

Input

SVU Figure 6.31

EE4512 Analog and Digital Communications

Chapter 6

• The output of the first order linear predictor MetaSystem is the quantized estimate of the signal se(n) for an input sinusoid. SVU Figure 6.32

EE4512 Analog and Digital Communications

Chapter 6

• The output of the DPCM receiver predictor and signal reconstruction MetaSystem is amplified and low pass filtered (LPF).

Predictor and error signal MetaSystem

Predictor and signal reconstruction MetaSystem

Input

Amplifier LPF

SVU Figure 6.28

EE4512 Analog and Digital Communications

Chapter 6

• The estimate of the input signal (top) from the DPCM receiver and the original analog baseband signal (bottom).

SVU Figure 6.33

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Delta Modulation • Pages 411-415

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• Delta modulation is an extreme example of DPCM using 1-bit data representing ± ∆: S(n) = S(n−1) + ∆ bi = 1 if S(n−1) ≤ s(n−1) S(n) = S(n−1) − ∆ bi = 0 if S(n−1) > s(n−1) S&M Eq. 8.10

DM transmitter

DM receiver

S&M Figure 8-18

EE4512 Analog and Digital Communications

Chapter 6

• The reconstructed signal increments ± ∆ on each transmitted bit. bi = 1 S(n) = S(n−1) + ∆ bi = 0 S(n) = S(n−1) − ∆

4 1s

4 0s

S&M Figure 8-19

EE4512 Analog and Digital Communications

Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion • Delta Modulation • Pages 128-133

Chapter 8

EE4512 Analog and Digital Communications

Chapter 6

• Delta modulation can be simulated in SystemVue. The DM receiver utilizes a sample and hold token as an accumulator. The step size ∆ = 1 mV. DM transmitter

m(t)

5 Hz sinusoid A=1V

SVU Figure 2.54

DM receiver

EE4512 Analog and Digital Communications

Chapter 6

• DM can be subject to slope overload which occurs when: ∆ / TS < max | d m(t) / dt | SVU Eq. 2.61 modified SVU Figure 2.56

EE4512 Analog and Digital Communications

Chapter 6

• Granular noise occurs in DM because if the input m(t) is constant the received signal oscillates by ± ∆ because there is no 0 possible. SVU Figure 2.57 ∆ = 1 mV

EE4512 Analog and Digital Communications

Chapter 6

• The tradeoff between slope overload and granular noise is that a large value of ∆ (to avoid slope overload) would increase granular noise. A decrease in Ts (again to avoid slope overload) would increment the data rate rS. The step size ∆ = 1 mV and TS = 50 µsec (rS = 20 kb/sec) here.

EE4512 Analog and Digital Communications

Chapter 6

• If m(t) = sin (2π 5t), max | d m(t) / dt | = 10π, step size ∆ = 1 mV and TS = 50 µsec. ∆ / TS = 20 < max | d m(t) / dt | so slope overload is predicted to occur. If TS = 25 µsec, ∆ / TS = 40 > max | d m(t) / dt | and slope overload is mitigated but rb = 40 kb/sec. In comparison 8-bit sampling of a 5 Hz sinusoid at a sampling rate of 500 Hz has rb = 8(500) = 4 kb/sec or only 10% of the data rate.

EE4512 Analog and Digital Communications

End of Chapter 8 Analog-to-Digital and Digital-to-Analog Conversion

Chapter 8