ECE1371 Advanced Analog Circuits Lecture 2 Higher-Order Modulators: MOD2 and MODN Richard Schreier [email protected]Trevor Caldwell [email protected]ECE1371 2-2 Course Goals • Deepen understanding of CMOS analog circuit design through a top-down study of a modern analog system— a delta-sigma ADC • Develop circuit insight through brief peeks at some nifty little circuits The circuit world is filled with many little gems that every competent designer ought to know.
29
Embed
Higher-Order Modulators: MOD2 and MODNindividual.utoronto.ca/schreier/lectures/2012/2-2.pdf · Higher-Order Modulators: MOD2 and MODN Richard Schreier [email protected]
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
STF (z ): signal transfer functionNTF (z ): noise transfer functionE (z ): quantization error
desired
shaped
Nyquist-ratePCM Data
noise
f s 2⁄f B
f s 2⁄f B
f B
signal
Y
ECE1371 2-7
Review: MOD1
QUE
NTF z( ) 1 z 1––( )=STF z( ) 1=
V z( ) NTF z( )E z( ) STF z( )U z( )+=
z-1
z-1
0 0.1 0.2 0.3 0.4 0.50
1
2
3
4NTF ej 2πf( ) 2
Normalized Frequency ( f )
ω2≅
NTF poles & zeros:
IQNPπ2σe
2
3------------- OSR( ) 3–=
ECE1371 2-8
Review Summary• ∆Σ works by spectrally separating the
quantization noise from the signalRequires oversampling. .
• Noise-shaping is achieved by the useof filtering and feedback
• A binary DAC is inherently linear,and thus a binary ∆Σ modulator is too
• MOD1 has NTF (z) = 1 – z–1
⇒ Arbitrary accuracy for DC inputs.9 dB/octave SQNR-OSR trade-off.
• MOD1-CT has inherent anti-aliasing
OSR f s 2f B( )⁄≡
ECE1371 2-9
MOD2: 2nd-Order ∆Σ Modulator[Ch. 3 of Schreier & Temes]
• Replace the quantizer in MOD1 with anothercopy of MOD1 in a recursive fashion:
V(z) = U(z) + (1–z–1)E1(z), E1(z) = (1–z–1)E(z)
⇒V(z) = U(z) + (1–z–1)2E(z)
z-1
Q
z-1
z-1
z-1
U VE1
E
ECE1371 2-10
Simplified Block Diagrams
Q1z−1
zz−1
U V
E
NTF z( ) 1 z 1––( )2=STF z( ) z 1–=
Q1z−1
1z−1
U V
E
-2-1 NTF z( ) 1 z 1––( )2=STF z( ) z 2–=
ECE1371 2-11
NTF Comparison
10–3 10–2 10–1−100
−80
−60
−40
−20
0N
TF
ej2
πf(
)(d
B)
Normalized Frequency
MOD1
MOD2MOD2 has twice as muchattenuation as MOD1at all frequencies
ECE1371 2-12
In-band Quant. Noise Power• For MOD2,
• As before, and
• So now
With binary quantization to ±1, and thus .
• “An octave increase in OSR increases MOD2’sSQNR by 15 dB (2.5 bits)”
H e jω( ) 2 ω4≈
IQNP H ejω( ) 2See ω( )dω0
ωB∫=
See ω( ) σe2 π⁄=
IQNPπ4σe
2
5------------- OSR( ) 5–=
∆ 2= σe2 ∆2 12⁄ 1 3⁄= =
ECE1371 2-13
Simulation ExampleInput at 75% of FullScale
0 50 100 150 200–1
0
1
Sample number
ECE1371 2-14
Simulated MOD2 PSDInput at 50% of FullScale
10–3 10–2 10–1–140
–120
–100
–80
–60
–40
–20
0
SQNR = 86 dB@ OSR = 128
40 dB/decade
Theoretical PSD(k = 1)
Simulated spectrum
Normalized Frequency
dBF
S/N
BW
(smoothed)
NBW = 5.7×10−6
ECE1371 2-15
SQNR vs. Input AmplitudeMOD1 & MOD2 @ OSR = 256
–100 –80 –60 –40 –20 00
20
40
60
80
100
120
Input Amplitude (dBFS)
SQ
NR
(dB
)
MOD1
MOD2Predicted SQNR
Simulated SQNR
ECE1371 2-16
SQNR vs. OSR
4 8 16 32 64 128 256 512 10240
20
40
60
80
100
120
SQ
NR
(dB
)
(Theoretical curve assumes-3 dBFS input)
(Theoretical curve assumes0 dBFS input)
MOD1
MOD2
Predictions for MOD2 are optimistic.Behavior of MOD1 is erratic.
ECE1371 2-17
Audio Demo: MOD1 vs. MOD2[dsdemo4]
MOD1
MOD2
SineWave
SlowRamp
Speech
ECE1371 2-18
MOD1 + MOD2 Summary• ∆Σ ADCs rely on filtering and feedback to
achieve high SNR despite coarse quantizationThey also rely on digital signal processing.∆Σ ADCs need to be followed by a digital decimationfilter and ∆Σ DACs need to be preceded by a digitalinterpolation filter.
• Oversampling eases analog filteringrequirements
Anti-alias filter in an ADC; image filter in a DAC.
• Binary quantization yields inherent linearity
• MOD2 is better than MOD115 dB/octave vs. 9 dB/octave SQNR-OSR trade-off.Quantization noise more white.Higher-order modulators are even better.
ECE1371 2-19
MODN[Ch. 4 of Schreier & Temes]
• MODN’s NTF is the Nth power of MOD1’s NTF
Q1z−1
zz−1U Vz
z−1
NTF z( ) 1 z 1––( )N=STF z( ) z 1–=
N integrators(N–1) non-delaying, 1 delaying
ECE1371 2-20
NTF Comparison
NT
Fe
j2πf
()
(dB
)
Normalized Frequency ( f )10
-310
-210
-1–100
–80
–60
–40
–20
0
20
40
MOD1
MOD2
MOD3
MOD4
MOD5
ECE1371 2-21
Predicted Performance• In-band quantization noise power
• Quantization noise drops as the (2 N+1)th powerof OSR— (6N+3) dB/octave SQNR-OSR trade-off
Not quite on the unit circle,but fairly close if g<<1.
Poles are the roots of1 gz
z 1–( )2--------------------+ 0=
i.e. z e jθ±=
Precisely on the unit circle,θcos 1 g 2⁄–=,
regardless of the value of g.
ECE1371 2-25
Problem: A High-Order ModulatorWants a Multi-bit Quantizer
E.g. MOD3 with an Infinite Quantizerand Zero Input
0 10 20 30 40-7
-5
-3
-1
1
3
5
7
Sample Number
v
Quantizer input getslarge, even if the
6 quantizer levels areused by a small input.
input is small.
ECE1371 2-26
Simulation of MOD3-1b(MOD3 with a Binary Quantizer)
• MOD3-1b is unstable, even with zero input!
0 10 20 30 40–1
0
1
0 10 20 30 40–200
–100
0
100
200
Sample Number
v
yHUGE!
Longstringsof +1/–1
ECE1371 2-27
Solutions to the Stability ProblemHistorical Order
1 Multi-bit quantizationInitially considered undesirable because we lose theinherent linearity of a 1-bit DAC.
2 More general NTF (not pure differentiation)Lower the NTF gain so that quantization error isamplified less.Unfortunately, reducing the NTF gain reduces theamount by which quantization noise is attenuated.
3 Multi-stage (MASH) architecture
• Combinations of the above are possible
ECE1371 2-28
Multi-bit QuantizationA modulator with NTF = H and STF = 1 isguaranteed to be stable if at all times,where and
• In MODN , so,
and thus
• impliesMODN is guaranteed to be stable with an N-bitquantizer if the input magnitude is less than ∆/2 = 1.This result is quite conservative.
• Similarly, guarantees that MOD N isstable for inputs up to 50% of full-scale
u u max<u max nlev 1 h 1–+= h 1 h i( )i 0=
∞∑=
H z( ) 1 z 1––( )N=h n( ) 1 a1– a2 a3– … 1–( )N aN 0…, , , , ,{ }= ai 0>
h 1 H 1–( ) 2N= =
nlev 2N= u max nlev 1 h 1–+ 1= =
nlev 2N 1+=
ECE1371 2-29
M-Step Symmetric Quantizer∆ = 2, (nlev = M + 1)
• No-overload range: ⇒
M even: mid-treadM odd: mid-rise
y
e = v – y
v
e = v – y
v
y1
M
–M
2
M
–M
–M –1 M +1 –M –1 M +1
v: odd integersfrom – M to +M
v: even integersfrom – M to +M
y nlev≤ e ∆ 2⁄≤ 1=
ECE1371 2-30
Inductive Proof of Criterion• Assume STF = 1 and
• Assume for .[Induction Hypothesis]
Then⇒⇒
• So by induction for all i > 0
h 1
n∀( ) u n( ) u max≤( )e i( ) 1≤ i n<
y n( ) u n( ) h i( )e n i–( )i 1=∞∑+=
u max h i( ) e n i–( )i 1=∞∑+≤
u max h i( )i 1=∞∑+≤ u max h 1 1–+=
u max nlev 1 h 1–+=y n( ) nlev≤e n( ) 1≤
e i( ) 1≤
ECE1371 2-31
More General NTF• Instead of with ,
use a more generalRoots of B are the poles of the NTF and must beinside the unit circle.
NTF z( ) A z( ) B z( )⁄= B z( ) z n=B z( )
Moving the poles awayfrom z = 1 toward z = 0makes the gain of theNTF approach unity.
ECE1371 2-32
The Lee Criterion for Stabilityin a 1-bit Modulator:
[Wai Lee, 1987]
• The measure of the “gain” of H is the maximummagnitude of H over frequency, aka the infinity-norm of H:
Q: Is the Lee criterion necessar y for stability?No. MOD2 is stable (for DC inputs less than FS)but .
Q: Is the Lee criterion sufficient to ensure stability?No. There are lots of counter-examples,but often works.
Loop filter can be specified by NTF orby ABCD, a state-space representation
ECE1371 2-40
NTF SynthesissynthesizeNTF
• Not all NTFs are realizableCausality requires , or, in the frequencydomain, . Recall
• Not all NTFs yield stable modulatorsRule of thumb for single-bit modulators:
[Lee].
• Can optimize NTF zeros to minimize themean-square value of H in the passband
• The NTF and STF share poles, and in somemodulator topologies the STF zeros are notarbitraryRestrict the NTF such that an all-pole STF is maximallyflat. (Almost the same as Butterworth poles.)
h 0( ) 1=H ∞( ) 1= H z( ) h 0( )z 0 h 1( )z 1– …+ +=
H ∞ 1.5<
ECE1371 2-41
Lowpass Example [ dsdemo1 ]5th-order NTF, all zeros at DC
Homework #2– Part ACreate a Matlab function that computes MOD2’soutput sequence given a vector of input samples andexercise your function in the following ways:
1 Plot the error as a function of u using 100-point rectangular and triangular * averages for v.
2 Produce a spectral plot like that on Slide 14.
3 Compare the in-band quantization noise of yoursystem with a half-scale sine-wave input againstthe relation given on Slide 12 for OSR in [2 3,210].
*. ,
v u–
v tri tri n( )v n( )n 0=
N 1–
∑= tri rect N 2⁄( )*rect N 2⁄( )=
ECE1371 2-52
Homework #2– Part BExtract code from dsdemo1 & dsdemo2 and modify itto:
1 Create a 3 rd-order NTF with zeros optimized forOSR = 32. Plot the poles/zeros and frequencyresponse of your NTF.
2 Simulate a 3-level ∆Σ modulator with this NTF.Plot example input and output waveforms.Plot a spectrum and the predicted noise curve. †
Plot the SQNR vs. input amplitude curve andnote the maximum stable input.
†. Beware that with an M-step modulator, the full-scale is Mand this must be accounted for in normalizing the FFT and incomputing the expected noise curve. You ought to checkyour code using a large value for M, say M = 20.
ECE1371 2-53
MOD2 Expanded
Q1z−1
zz−1
U VE
z-1
u n( )z-1
x 1 n( )
x 1 n 1+( ) x 2 n 1+( )Q
x 2 n( ) v n( )
Difference Equations:v n( ) Q x 2 n( )( )=
x 2 n 1+( ) x 2 n( ) v n( )– x 1 n 1+( )+=x 1 n 1+( ) x 1 n( ) v n( )– u n( )+=