<<

Switched- Circuits

University of Toronto 1 of 48

© D. Johns, K. Martin, 1997

Basic Building Blocks Opamps • Ideal opamps usually assumed. • Important non-idealities — dc gain: sets the accuracy of charge transfer, hence, transfer-function accuracy. — unity-gain freq, phase margin & slew-rate: sets the max clocking frequency. A general rule is that unity-gain freq should be 5 times (or more) higher than the clock-freq. — dc offset: Can create dc offset at output. Circuit techniques to combat this which also reduce 1/f noise.

University of Toronto 2 of 48

© D. Johns, K. Martin, 1997 Basic Building Blocks Double-Poly C metal 1 metal poly1

Cp1 thin oxide bottom plate C1 poly2 Cp2 thick oxide C p1 Cp2

(substrate - ac ground)

cross-section view equivalent circuit • Substantial parasitics with large bottom plate capacitance (20 percent of C1 ) • Also, metal-metal capacitors are used but have even larger parasitic capacitances.

University of Toronto 3 of 48

© D. Johns, K. Martin, 1997

Basic Building Blocks φ φ Symbol n-channel

v1 v2 v1 v2

φ transmission φ φ gate v1 v p-channel v 2 1 v2 φ • Mosfet switches are good switches. — off-resistance near GΩ range — on-resistance in 100Ω to 5kΩ range (depends on sizing) • However, have non-linear parasitic capacitances.

University of Toronto 4 of 48

© D. Johns, K. Martin, 1997 Basic Building Blocks Non-Overlapping Clocks φ1 T V φ on φ1 Voff n – 2 n – 1 n n + 1 tT⁄ 1 delay φ fs ≡ --- delay V 2 T on φ Voff 2 n – 32⁄ n – 12⁄ n + 12⁄ tT⁄ • Non-overlapping clocks — both clocks are never on at same time • Needed to ensure charge is not inadvertently lost.

• Integer values occur at end of φ1 .

• End of φ2 is 1/2 off integer value.

University of Toronto 5 of 48

© D. Johns, K. Martin, 1997

Switched-Capacitor Equivalent φ φ 1 2 Req V V V1 V2 1 2 C1 T ∆QC= ()V – V every clock period Req = ------1 1 2 C1 Qx = CxVx (1)

• C1 charged to V1 and then V2 during each clk period.

∆Q1 = C1()V1 – V2 (2) • Find equivalent average current C ()V – V I = ------1 1------2 (3) avg T where T is the clk period.

University of Toronto 6 of 48

© D. Johns, K. Martin, 1997 Switched-Capacitor Resistor Equivalent • For equivalent resistor circuit

V1 – V2 Ieq = ------(4) Req • Equating two, we have T 1 Req ==------(5) C1 C1fs • This equivalence is useful when looking at low-freq portion of a SC-circuit. • For higher frequencies, discrete-time analysis is used.

University of Toronto 7 of 48

© D. Johns, K. Martin, 1997

Resistor Equivalence Example • What is the equivalent resistance of a 5pF capacitance sampled at a clock frequency of 100kHz . • Using (5), we have 1 R ==------2MΩ eq –12 3 ()510× ()100× 10 • Note that a very large equivalent resistance of 2MΩ can be realized. • Requires only 2 , a clock and a relatively small capacitance. • In a typical CMOS process, such a large resistor would normally require a huge amount of silicon area.

University of Toronto 8 of 48

© D. Johns, K. Martin, 1997 Parasitic-Sensitive Integrator

vc2()nT

φ1 φ2 C vcx()t 2 φ1 vci()t vco()t

vc1()t C1 v ()n = v ()nT vi()n = vci()nT o co

• Start by looking at an integrator which IS affected by parasitic capacitances

• Want to find output voltage at end of φ1 in relation to input sampled at end of φ1 .

University of Toronto 9 of 48

© D. Johns, K. Martin, 1997

Parasitic-Sensitive Integrator

C2 C2 v ()nT– T ci vci()nT– T ⁄ 2 C 1 v ()nT– T C1 co vco()nT– T ⁄ 2

φ1 on φ2 on

• At end of φ2

C2vco()nT– T ⁄ 2 = C2vco()nT– T – C1vci()nT– T (6)

• But would like to know the output at end of φ1

C2vco()nT = C2vco()nT– T ⁄ 2 (7) • leading to

C2vco()nT = C2vco()nT– T – C1vci()nT– T (8)

University of Toronto 10 of 48

© D. Johns, K. Martin, 1997 Parasitic-Sensitive Integrator • Modify above to write

C1 vo()n = vo()n – 1 – ------vi()n – 1 (9) C2 and taking z-transform and re-arranging, leads to

Vo()z C1 1 Hz()≡ ------= –------(10) Vi()z C2 z – 1 • Note that gain-coefficient is determined by a ratio of two capacitance values. • Ratios of capacitors can be set VERY accurately on an (within 0.1 percent) • Leads to very accurate transfer-functions.

University of Toronto 11 of 48

© D. Johns, K. Martin, 1997

Typical Waveforms

φ1

t φ2

t vci()t

t

vcx()t

t

vco()t

t

University of Toronto 12 of 48

© D. Johns, K. Martin, 1997 Low Frequency Behavior • Equation (10) can be re-written as

C z–12/ Hz()= – ------1 ------(11) 12/ –12/ C2 z – z • To find freq response, recall

ze==jωT cos()ωT + jsin()ωT (12) ωT ωT z12/ = cos------+ jsin------(13) 2 2 ωT ωT z–12/ = cos------– jsin------(14) 2 2 ωT ωT cos------– jsin------jωT C1 2 2 He()= –------(15) C ωT 2 j2sin------2

University of Toronto 13 of 48

© D. Johns, K. Martin, 1997

Low Frequency Behavior • Above is exact but when ωT « 1 (i.e., at low freq)

jωT C1 1 He()≅ –------(16) C2 jωT

• Thus, the transfer function is same as a continuous- time integrator having a gain constant of

C1 1 KI ≅ ------(17) C2T which is a function of the integrator capacitor ratio and clock frequency only.

University of Toronto 14 of 48

© D. Johns, K. Martin, 1997 Parasitic Capacitance Effects Cp3 Cp4 C2

φ1 φ2 φ1 vi()n vo()n C1 Cp1

Cp2 • Accounting for parasitic capacitances, we have

C1 + Cp1 1 Hz()= –------(18) C2 z – 1 • Thus, gain coefficient is not well controlled and partially non-linear (due to Cp1 being non-linear).

University of Toronto 15 of 48

© D. Johns, K. Martin, 1997

Parasitic-Insensitive Integrators

C2

φ1 φ C 2 1 φ v ()t 1 ci vco()t

φ2 φ1 vi()n = vci()nT vo()n = vco()nT

• By using 2 extra switches, integrator can be made insensitive to parasitic capacitances — more accurate transfer-functions — better linearity (since non-linear capacitances unimportant)

University of Toronto 16 of 48

© D. Johns, K. Martin, 1997 Parasitic-Insensitive Integrators C 2 C2 vci()nT– T vci()nT– T ⁄ 2 + - C - 1 C1 vco()nT– T + vco()nT– T ⁄ 2

φ1 on φ2 on

• Same analysis as before except that C1 is switched in polarity before discharging into C2 .

Vo()z C1 1 Hz()≡ ------= ------(19) Vi()z C2 z – 1 • A positive integrator (rather than negative as before)

University of Toronto 17 of 48

© D. Johns, K. Martin, 1997

Parasitic-Insensitive Integrators

Cp3 Cp4

C2 φ1 φ C 2 1 φ1 vi()n vo()n φ2 φ1

Cp1 Cp2

• Cp3 has little effect since it is connected to virtual gnd

• Cp4 has little effect since it is driven by output

• Cp2 has little effect since it is either connected to virtual gnd or physical gnd.

University of Toronto 18 of 48

© D. Johns, K. Martin, 1997 Parasitic-Insensitive Integrators

• Cp1 is continuously being charged to vi()n and discharged to ground.

• φ1 on — the fact that Cp1 is also charged to vi()n – 1 does not affect C1 charge.

• φ2 on — Cp1 is discharged through the φ2 attached to its node and does not affect the charge accumulating on C2 . • While the parasitic capacitances may slow down settling time behavior, they do not affect the discrete-time difference equation

University of Toronto 19 of 48

© D. Johns, K. Martin, 1997

Parasitic-Insensitive Inverting Integrator C2 φ1 φ1 C1 φ1 vi()n vo()n Vi()z φ2 φ2 Vo()z

C2vco()nT– T ⁄ 2 = C2vco()nT– T (20)

C2vco()nT = C2vco()nT– T ⁄ 2 – C1vci()nT (21) • Present output depends on present input(delay-free)

Vo()z C1 z Hz()≡ ------= –------(22) Vi()z C2 z – 1 • Delay-free integrator has negative gain while delaying integrator has positive gain.

University of Toronto 20 of 48

© D. Johns, K. Martin, 1997 Signal-Flow-Graph Analysis

C1 V1()z φ φ 1 C 2 2 CA V2()z φ φ 2 1 φ1 V ()z φ1 φ1 o C3 V3()z φ2 φ2

–1 –C1()1 – z V1()z –1 C2z 1 1 ------V ()z  –1 V ()z 2 CA 1 – z o

–C3 V3()z

University of Toronto 21 of 48

© D. Johns, K. Martin, 1997

First-Order Filter

Vin()s Vout()s

• Start with an active-RC structure and replace with SC equivalents. • Analyze using discrete-time analysis.

University of Toronto 22 of 48

© D. Johns, K. Martin, 1997 First-Order Filter φ φ 1 1 φ1 φ1 C2 C3

φ2 φ2 φ2 φ2

CA φ C1 1 Vi()z Vo()z

–C3

–C2 1 1 V z ------V ()z i()  –1 o CA 1 – z –1 –C1()1 – z

University of Toronto 23 of 48

© D. Johns, K. Martin, 1997

First-Order Filter –1 –1 CA()1 – z Vo()z = – C3Vo()z – C2Vi()z – C1()1 – z Vi()z (23)

C1 C2 ------()1 – z–1 + ------CA CA –------Vo()z C Hz()≡ ------= 1 – z–1 + ------3- (24) V ()z i CA

C1 + C2 C ------z – ------1- CA CA = –------C 1 + ------3- z – 1 CA

University of Toronto 24 of 48

© D. Johns, K. Martin, 1997 First-Order Filter • The pole of (24) is found by equating the denominator to zero

CA zp = ------(25) CA + C3 • For positive capacitance values, this pole is restricted to the real axis between 0 and 1 — circuit is always stable. • The zero of (24) is found to be given by

C1 zz = ------(26) C1 + C2 • Also restricted to real axis between 0 and 1.

University of Toronto 25 of 48

© D. Johns, K. Martin, 1997

First-Order Filter The dc gain is found by setting z = 1 which results in –C H()1 = ------2 (27) C3 • Note that in a fully-differential implementation, effective negative capacitances for C1, C2 and C3 can be achieved by simply interchanging the input . • In this way, a zero at z = –1 could be realized by setting

C1 = –0.5C2 (28)

University of Toronto 26 of 48

© D. Johns, K. Martin, 1997 First-Order Example • Find the capacitance values needed for a first-order SC-circuit such that its 3dB point is at 10kHz when a clock frequency of 100kHz is used. • It is also desired that the filter have zero gain at 50kHz (i.e. z = –1 ) and the dc gain be unity.

• Assume CA = 10pF . Solution • Making use of the bilinear transform pz= ()– 1 ⁄ ()z + 1 the zero at –1 is mapped to Ω∞= . • The frequency warping maps the -3dB frequency of 10kHz (or 0.2π rad/sample ) to

University of Toronto 27 of 48

© D. Johns, K. Martin, 1997

First-Order Example 0.2π Ω ==tan------0.3249 (29) 2 • in the continuous-time domain leading to the continuous-time pole, pp , required being

pp = –0.3249 (30)

• This pole is mapped back to zp given by

1 + pp zp ==------0.5095 (31) 1 – pp • Therefore, Hz() is given by kz()+ 1 Hz()= ------(32) z – 0.5095

University of Toronto 28 of 48

© D. Johns, K. Martin, 1997 First-Order Example • where k is determined by setting the dc gain to one (i.e. H()1 = 1) resulting 0.24525()z + 1 Hz()= ------(33) z – 0.5095 • or equivalently, 0.4814z + 0.4814 Hz()= ------(34) 1.9627z – 1 • Equating these coefficients with those of (24) (and assuming CA = 10pF ) results in

C1 = 4.814pF (35) C2 = –9.628pF (36) C3 = 9.628pF (37)

University of Toronto 29 of 48

© D. Johns, K. Martin, 1997

Switch Sharing

φ1 C3

φ2 C1 CA

φ1 φ1 C2 ) Vo()z φ2 φ2

• Share switches that are always connected to the same potentials.

University of Toronto 30 of 48

© D. Johns, K. Martin, 1997 Fully-Differential Filters • Most modern SC filters are fully-differential • Difference between two voltages represents signal (also balanced around a common-mode voltage). • Common-mode noise is rejected. • Even order distortion terms cancel

2 3 4 v = k v ++++k v k v k v … p1 1 1 2 1 3 1 4 1 v nonlinear 1 element 3 5 + v = 2k v +++2k v 2k v … diff 1 1 3 1 5 1 - –v nonlinear 1 element 2 3 4 v = – k v +++k v – k v k v … n1 1 1 2 1 3 1 4 1

University of Toronto 31 of 48

© D. Johns, K. Martin, 1997

Fully-Differential Filters C1 C 3 φ1

φ2 C φ2 A φ2 + C2 φ1 φ1 + V ()z V ()z i φ o φ1 1 - - C2 C φ2 φ2 A φ2

C 3 φ1

C1

University of Toronto 32 of 48

© D. Johns, K. Martin, 1997 Fully-Differential Filters • Negative continuous-time input — equivalent to a negative C1

C1 C 3 φ1

φ2 C φ2 A φ2 + C2 φ1 φ1 + V ()z V ()z i φ o φ1 1 - - C2 C φ2 φ2 A φ2

C 3 φ1

C1

University of Toronto 33 of 48

© D. Johns, K. Martin, 1997

Fully-Differential Filters • Note that fully-differential version is essentially two copies of single-ended version, however ... area penalty not twice. • Only one opamp needed (though common-mode circuit also needed) • Input and output signal swings have been doubled so that same dynamic range can be achieved with half capacitor sizes (from kT⁄ C analysis) • Switches can be reduced in size since small caps used. • However, there is more wiring in fully-differ version but better noise and distortion performance.

University of Toronto 34 of 48

© D. Johns, K. Martin, 1997 Low-Q Biquad Filter 2 Vout()s k2s ++k1sko Ha()s ≡ ------= –------(38) Vin()s 2 ω 2 s ++------o s ω Q o

1 ⁄ ωo Q ⁄ ωo C = 1 A Vc1()s CB = 1 ω ⁄ k o o –1 ⁄ ωo Vin()s Vout()s 1 ⁄ k1

k2

University of Toronto 35 of 48

© D. Johns, K. Martin, 1997

Low-Q Biquad Filter

φ1 φ1 K4C1

φ2 φ2 φ1 φ1 K6C2

φ2 φ2 C1 V ()z C2 φ 1 φ1 K C 1 1 1 φ1 φ2 φ Vi()z K5C2 1 Vo()z φ2 φ2 φ2 φ1 φ φ1 K C 1 2 2

φ2 φ2

K3C2

University of Toronto 36 of 48

© D. Johns, K. Martin, 1997 Low-Q Biquad Filter

–K4

–K6 V1()z –K 1 K z–1 1 V ()z 1 ------5 ------V ()z i 1 – z–1 1 – z–1 o

–K2 –1 –K3()1 – z

2 V ()z ()K + K z ++()K K – K – 2K zK Hz()≡ ------o = –------2 3------1 5 ------2 3 ------3- (39) 2 Vi()z ()1 + K6 z ++()K4K5 – K6 – 2 z 1

University of Toronto 37 of 48

© D. Johns, K. Martin, 1997

Low-Q Biquad Filter Design 2 a z ++a za Hz()= –------2 ------1 0 (40) 2 b2z ++b1z 1 • we can equate the individual coefficients of “z” in (39) and (40), resulting in:

K3 = a0 (41) K2 = a2 – a0 (42) K1K5 = a0 ++a1 a2 (43) K6 = b2 – 1 (44) K4K5 = b1 ++b2 1 (45) • A degree of freedom is available here in setting internal V1()z output

University of Toronto 38 of 48

© D. Johns, K. Martin, 1997 Low-Q Biquad Filter Design • Can do proper dynamic range scaling • Or let the time-constants of 2 integrators be equal by

K4 ==K5 b1 ++b2 1 (46) Low-Q Biquad Capacitance Ratio • Comparing resistor circuit to SC circuit, we have

K4 ≈≈K5 ωoT (47) ω T K ≈ ------o - (48) 6 Q • However, the sampling-rate, 1 ⁄ T , is typically much larger that the approximated pole-frequency, ωo ,

ωoT « 1 (49)

University of Toronto 39 of 48

© D. Johns, K. Martin, 1997

Low-Q Biquad Capacitance Ratio • Thus, the largest capacitors determining pole positions are the integrating capacitors, C1 and C2 .

• If Q < 1 , the smallest capacitors are K4C1 and K5C2 resulting in an approximate capacitance spread of

1 ⁄ ()ωoT . • If Q > 1 , then from (48) the smallest capacitor would be K6C2 resulting in an approximate capacitance

spread of Q ⁄ ()ωoT — can be quite large for Q » 1

University of Toronto 40 of 48

© D. Johns, K. Martin, 1997 High-Q Biquad Filter • Use a high-Q biquad filter circuit when Q » 1 • Q-damping done with a cap around both integrators • Active-RC prototype filter

1 ⁄ ωo 1 ⁄ Q C = 1 1 C2 = 1 ωo ⁄ ko –1 ⁄ ω Vin()s o Vout()s k1 ⁄ ωo

k2

University of Toronto 41 of 48

© D. Johns, K. Martin, 1997

High-Q Biquad Filter

φ1 K C φ1 4 1

φ2 φ2 K6C1 C 1 V ()z 1 C2 φ1 K C φ1 1 1 φ φ2 φ V ()z 1 K5C 1 i 2 Vo()z φ2 φ2 φ2 φ1

K C 2 1

K3C2

• Q-damping now performed by K6C1

University of Toronto 42 of 48

© D. Johns, K. Martin, 1997 High-Q Biquad Filter

• Input K1C1 : major path for lowpass

• Input K2C1 : major path for band-pass filters

• Input K3C2 : major path for high-pass filters • General transfer-function is: 2 V ()z K z ++()K K + K K – 2K zK()– K K Hz()≡ ------o = –------3 ------1 5 ------2 5 ------3 ------3 ------2 5 (50) 2 Vi()z z ++()K4K5 + K5K6 – 2 z ()1 – K5K6 • If matched to the following general form 2 a z ++a za Hz()= –------2 ------1 0 (51) 2 z ++b1zb0

University of Toronto 43 of 48

© D. Johns, K. Martin, 1997

High-Q Biquad Filter K1K5 = a0 ++a1 a2 (52)

K2K5 = a2 – a0 (53)

K3 = a2 (54)

K4K5 = 1 ++b0 b1 (55)

K5K6 = 1 – b0 (56) • And, as in lowpass case, can set

K4 ==K5 1 ++b0 b1 (57)

• As before, K4 and K5 approx ωoT « 1 but K6 ≅ 1 ⁄ Q

University of Toronto 44 of 48

© D. Johns, K. Martin, 1997 Charge Injection • To reduce charge injection (thereby improving distortion) , turn off certain switches first.

φ1 C3 Q6 φ Q5 2 C1

CA φ1 φ1a C2 φ1 Vi()z Q1 Q4 Vo()z φ φ2 Q2Q3 2a

• Advance φ1a and φ2a so that only their charge injection affect circuit (result is a dc offset)

University of Toronto 45 of 48

© D. Johns, K. Martin, 1997

Charge Injection

• Note: φ2a connected to ground while φ1a connected to virtual ground, therefore ... — can use single n-channel transistors — charge injection NOT signal dependent

QCH ==–WLCoxVeff –WLCox()VGS – Vt (58)

• Charge related to VGS and Vt and Vt related to substrate-source voltage.

• Source of Q3 and Q4 remains at 0 volts — amount of charge injected by Q3, Q4 is not signal dependent and can be considered as a dc offset.

University of Toronto 46 of 48

© D. Johns, K. Martin, 1997 Charge Injection Example • Estimate dc offset due to channel-charge injection when C1 = 0 and C2 ==CA 10C3 =10pF .

• Assume switches Q3, Q4 have Vtn = 0.8V , W = 30µm , –3 2 L = 0.8µm, Cox = 1.9× 10 pF ⁄ µm , and power supplies are ±2.5V .

• Channel-charge of Q3, Q4 (when on) is

QCH3 ==QCH4 –()30 ()0.8 ()0.0019 ()2.5– 0.8 (59) –3 = –77.5 × 10 pC • dc feedback keeps virtual opamp input at zero volts.

University of Toronto 47 of 48

© D. Johns, K. Martin, 1997

Charge Injection Example

• Charge transfer into C3 given by Q = –C v (60) C3 3 out

• We estimate half channel-charges of Q3 , Q4 are injected to the virtual ground leading to 1 ---()Q + Q = Q (61) 2 CH3 CH4 C3 which leads to –3 77.5× 10 pC v ==------78 mV (62) out 1pF • dc offset affected by the capacitor sizes, switch sizes and power supply voltage.

University of Toronto 48 of 48

© D. Johns, K. Martin, 1997