PWM modulator having quantizer with controllable analog gain and calibratable for multi-non-ideal gain-affecting characteristics
10819328 ยท 2020-10-27
Assignee
Inventors
- Ramin Zanbaghi (Austin, TX)
- Anuradha Parsi (Austin, TX, US)
- Kyehyung Lee (Austin, TX, US)
- John L. Melanson (Austin, TX)
Cpc classification
H03F2200/331
ELECTRICITY
H03F2203/45514
ELECTRICITY
H03M3/484
ELECTRICITY
H03F2200/351
ELECTRICITY
H03M3/442
ELECTRICITY
H03K4/50
ELECTRICITY
H03K4/56
ELECTRICITY
International classification
H03M3/00
ELECTRICITY
Abstract
A PWM modulator has a quantizer that generates a PWM output signal to speaker driver. When a first voltage swing range is supplied to the speaker driver, the quantizer analog gain is controlled to be a first gain value. When a second PWM drive voltage swing range is supplied to the speaker driver, the analog gain is controlled to be a second gain value. The first and second gain values of the analog gain of the quantizer cause the combined gain of the quantizer and driver to be approximately equal in the two modes. The quantizer has at least two gain-affecting measurable non-ideal characteristics. The quantizer is adjustable using measured first and second values to correct for first and second of the at least two non-ideal characteristics. The gain of the quantizer is calibratable while the quantizer is adjusted using the measured first and second measured values.
Claims
1. A closed loop pulse width modulation (PWM) modulator, comprising: a speaker driver that selectively receives distinct first and second PWM drive voltage swing ranges; a quantizer having an analog gain and that generates a PWM output signal to the speaker driver; wherein the quantizer and speaker driver have a combined gain; wherein while operating in a first mode in which the first PWM drive voltage swing range is supplied to the speaker driver, the analog gain of the quantizer is controlled to be a first gain value; wherein while operating in a second mode in which the second PWM drive voltage swing range is supplied to the speaker driver, the analog gain of the quantizer is controlled to be a second gain value distinct from the first gain value; and wherein the first and second gain values of the analog gain of the quantizer cause the combined gain of the quantizer and driver to be approximately equal in the first and second modes.
2. The closed loop PWM modulator of claim 1, wherein the speaker driver has a gain that is a third gain value while operating in the first mode and that is a fourth gain value while operating in the second mode; and wherein a product of the first and third gain values is approximately equal to a product of the second and fourth gain values.
3. The closed loop PWM modulator of claim 1, further comprising: a switched capacitor network that generates the first/second gain value to control the analog gain of the quantizer to be the first/second gain value.
4. The closed loop PWM modulator of claim 3, wherein the switched capacitor network receives an input signal voltage and a ramp voltage and responsively generates a voltage used to generate the PWM output signal, the ramp voltage having a swing range; and wherein a ratio of the ramp voltage swing range while operating in the first mode to the ramp voltage swing range while operating in the second mode is less than a ratio of the first PWM drive voltage swing range to the second PWM drive voltage swing range.
5. The closed loop PWM modulator of claim 3, wherein the switch capacitor network is controllable such that a ratio of the first and second analog gain values is a power of two.
6. The closed loop PWM modulator of claim 3, wherein the switch capacitor network further receives a common mode voltage and generates the voltage used to generate the PWM output signal responsively to the input signal voltage and the ramp voltage and the common mode voltage.
7. A method, comprising: in a closed loop pulse width modulation (PWM) modulator including a speaker driver that selectively receives distinct first and second PWM drive voltage swing ranges and a quantizer having an analog gain and that generates a PWM output signal to the speaker driver, wherein the quantizer and speaker driver have a combined gain: controlling the analog gain of the quantizer to be a first gain value while operating in a first mode in which the first PWM drive voltage swing range is supplied to the speaker driver; controlling the analog gain of the quantizer to be a second gain value while operating in a second mode in which the second PWM drive voltage swing range is supplied to the speaker driver, wherein the second gain value is distinct from the first gain value; and wherein the first and second gain values of the analog gain of the quantizer cause the combined gain of the quantizer and driver to be approximately equal in the first and second modes.
8. The method of claim 7, wherein the speaker driver has a gain that is a third gain value while operating in the first mode and that is a fourth gain value while operating in the second mode; and wherein a product of the first and third gain values is approximately equal to a product of the second and fourth gain values.
9. The method of claim 7, wherein said controlling the analog gain of the quantizer to be the first/second gain value comprises operating a switched capacitor network to generate the first/second gain value.
10. The method of claim 9, wherein said operating the switched capacitor network to generate the first/second gain value comprises: receiving, by the switched capacitor network, an input signal voltage and a ramp voltage and responsively generating a voltage used to generate the PWM output signal, the ramp voltage having a swing range; and wherein a ratio of the ramp voltage swing range while operating in the first mode to the ramp voltage swing range while operating in the second mode is less than a ratio of the first PWM drive voltage swing range to the second PWM drive voltage swing range.
11. The method of claim 9, wherein the switch capacitor network is controllable such that a ratio of the first and second analog gain values is a power of two.
12. The method of claim 9, further comprising wherein said operating the switched capacitor network to generate the first/second gain value further comprises: receiving, by the switch capacitor network, further a common mode voltage and generating the voltage used to generate the PWM output signal responsively to the input signal voltage and the ramp voltage and the common mode voltage.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1)
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
(10)
(11)
(12)
(13)
(14)
(15)
(16)
(17)
(18)
(19)
DETAILED DESCRIPTION
(20) Referring now to
(21) Referring now to
(22) Referring now to
(23) In one embodiment, the class-D modulator 100 loop operates in the analog domain similar to a continuous-time delta-sigma analog-to-digital converter (ADC). Unlike a double-sampling ADC, which is based on pulse-density modulation (PDM), the class-D modulator 100 is based on PWM. The PWM quantizer 304 converts an analog signal into a PWM signal. The quantizer 304 and the speaker driver 306 have respective gain values. In particular, the gain of the speaker driver 306 is proportional to the driver supply voltage V.sub.SPK provided to the speaker driver 306.
(24) Embodiments are described below in which the gain of the quantizer 304more specifically an analog gain of the quantizer 304is advantageously adjusted commensurate with a change in the speaker driver gain when the driver supply voltage V.sub.SPK changes in order to maintain a fixed combined gain of the quantizer 304 and speaker driver 306. As a result, a voltage range and associated ramp slope of a sawtooth waveform (compared with a signal input to generate a PWM output signal) generated by the quantizer 304 may advantageously be kept close and in some embodiments fixed. Embodiments are also described below in which the sawtooth waveform generator employs a chopping technique on an internally generated triangular wave to generate the sawtooth wave which results in reduced ramp capacitor reset times and swing voltages. Finally, embodiments of a calibration method are described in which multiple non-ideal characteristics (e.g., comparator time delay and offset, RC time constant of the ramp generator, etc.) of the quantizer 304 are measured and adjusted to improve the accuracy of the gain calibration of the quantizer 304.
(25) Referring now to
(26) Referring now to
K.sub.TOTAL=K.sub.ANA*K.sub.DRV*K.sub.CEM(1)
(27) As shown in equation (2) below, the driver gain K.sub.DRV is the ratio of the speaker voltage V.sub.SPK and the ramp voltage swing range V.sub.ramp(fd). Thus, when the operating mode is transitioned from HV mode to LV mode (or vice versa), the driver gain K.sub.DRV will be changed (assuming the ramp voltage swing range V.sub.ramp(fd) is maintained), and a change in the driver gain K.sub.DRV changes the combined gain K.sub.TOTAL. A change in the combined gain K.sub.TOTAL is undesirable because it changes the dynamics of the modulator 100 loop, e.g., changes the loop dynamics to be non-linear.
(28)
(29) One solution is to keep the driver gain K.sub.DRV fixed across mode changes in order to maintain a fixed combined gain K.sub.TOTAL, which requires a change of the ramp voltage swing range V.sub.ramp(fd) to match the change in the speaker voltage V.sub.SPK in order to maintain the combined gain K.sub.TOTAL across the two modes, as may be observed from equation (3) which rearranges equation (2) to specify the ramp voltage swing range V.sub.ramp(fd) as the ratio of the speaker voltage V.sub.SPK and the speaker driver gain K.sub.DRV.
(30)
(31) Per equations (4) below, in the example, it is assumed the analog gain K.sub.ANA is 0.5, the drive gain K.sub.DRV is 10, the CEM gain K.sub.CEM is 2, the total gain K.sub.TOTAL is 10, V.sub.BST is 12V for HV mode, and V.sub.BAT is 4V for LV mode. Consequently, as shown in equation (5), the ramp voltage swing range V.sub.ramp(fd) is 1.2 vpp in HV mode and 0.4 vpp in LV mode, which are summarized in the two left-most columns of the table of
(32)
(33) However, such a large difference in the ramp voltage swing range V.sub.ramp(fd) between the HV and LV modes, 1.2 vpp to 0.4 vpp, i.e., a factor of 3, is also highly undesirable because it may introduce sensitivity in the system. More specifically, because circuits in the PWM modulator 100 that perform voltage to time conversion (e.g., comparators and summing networks), for example, operate based on the sawtooth ramp characteristics, it may be difficult to design such components to operate properly in the two different modes.
(34) Embodiments are described that advantageously, while maintaining a fixed combined gain K.sub.TOTAL, reduce the variation (or in some embodiments eliminate it) in the ramp voltage swing range V.sub.ramp(fd) and associated ramp slope between the two modes by adjusting the analog gain K.sub.ANA of the quantizer 304, as shown in
(35) Referring now to
(36) The negative input to the comparator 406 is also coupled through a switch controlled by clock signal CLK.sub.f to a node that is coupled to a capacitor C1 and to positive signal input V.sub.IP through a switch controlled by clock signal CLK.sub.r. The positive input to the comparator 406 is also coupled through a switch controlled by clock signal CLK.sub.f to a node that is coupled to a capacitor C4 and to negative signal input V.sub.IM through a switch controlled by clock signal CLK.sub.r. The other terminal of capacitor C1 is coupled to node X, and the other terminal of capacitor C4 is coupled to node Y. Common mode voltage V.sub.cm is also coupled to node X and to node Y through switches controlled by a clock signal CLK.sub.r-hv. Negative signal input V.sub.IM is coupled to node X through a switch controlled by a clock signal CLK.sub.r-lv, and positive signal input V.sub.IP is coupled to node Y through a switch controlled by a clock signal CLK.sub.r-lv.
(37) Operation of the switched capacitor network 404 of
(38) In the embodiment of
(39) Advantageously, keeping the combined gain of the quantizer 304 and driver 306 close to the same or the same in both HV and LV mode avoids exacerbating non-idealities of the quantizer and exposing its design trade-offs and makes the modulator 100 loop behave similarly independent of the different speaker voltage values V.sub.SPK.
(40) Referring now to
(41) A disadvantage of the prior art ramp generator 902 of
(42) Referring now to
(43) The ramp generator 402 also includes a chopping block 1106, or chopping switch 1106, whose first and second outputs are coupled to the positive and negative inputs of the amplifier 1104, respectively. The two inputs to the chopping switch 1106 are coupled to receive respective positive and negative reference currents I.sub.refp and I.sub.refm. The positive reference current I.sub.refp is the quotient of positive reference voltage V.sub.refp and a reference resistance R.sub.ref, and the negative reference current I.sub.refm is the quotient of negative reference voltage V.sub.refm and the reference resistance R.sub.ref. The chopping switch 1106 operates as a crossbar switch that may be dynamically controlled to operate in either a pass-through configuration or a cross configuration. In the pass-through configuration, the chopping switch 1106 connects the positive reference current I.sub.refp to the positive input of the amplifier 1104 and the negative reference current I.sub.refm to the negative input of the amplifier 1104. In the cross configuration, the chopping switch 1106 connects the positive reference current I.sub.refp to the negative input of the amplifier 1104 and the negative reference current I.sub.refm to the positive input of the amplifier 1104. Depending upon the configuration of the chopping switch 1106, the reference currents I.sub.refp and I.sub.refm selectively push-pull through the ramp capacitors C.sub.rampp and C.sub.rampm to generate respective negative and positive ramp voltages V.sub.rampm and V.sub.rampp at the respective negative and positive outputs of the amplifier 1104, as described in more detail below.
(44) A common mode voltage V.sub.cm is selectively coupled to the positive and negative inputs of the amplifier 1104 through switches controlled by a clock signal CLK.sub.rst. The node holding the negative ramp voltage V.sub.rampm is selectively coupled to the negative reference voltage V.sub.refm through a switch controlled by a clock signal CLK.sub.rst_fall and is selectively coupled to the positive reference voltage V.sub.refp through a switch controlled by a clock signal CLK.sub.rst rise. The node holding the positive ramp voltage V.sub.rampp is selectively coupled to the negative reference voltage V.sub.refm through a switch controlled by the clock signal CLK.sub.rst_rise and is selectively coupled to the positive reference voltage V.sub.refp through a switch controlled by the clock signal CLK.sub.rst_fall.
(45) The ramp generator 402 also includes a de-chopping block 1108, or de-chopping switch 1108, whose first and second inputs are coupled to the negative and positive outputs of the amplifier 1104, respectively. The two outputs of the de-chopping switch 1108 are coupled to nodes that hold respective negative and positive output voltages V.sub.outm and V.sub.outp that may be provided to other portions of a quantizer (e.g., to switched capacitor network 404 for provision to comparator 406 of
(46) Referring now to
(47) As will be understood from the following description, the ramp voltage V.sub.ramp is a negatively sloping ramp also having a swing of V.sub.ramp(fd) during the next sampling period, which will be polarity-inverted to form another positively sloping ramp of the sawtooth wave of the output voltage V.sub.OUT. This pattern repeats for subsequent sampling period pairs, resulting in a triangular wave ramp voltage V.sub.ramp, which is polarity-swapped on alternating periods (e.g., on periods in which the triangular wave ramp voltage V.sub.ramp is negatively sloping) by the de-chopping switch 1108 to form the sawtooth wave on the output voltage V.sub.OUT, as shown. As a result, the ramp generator 402 advantageously enjoys the benefits perceived by smaller swings and reset times of the ramp capacitors, as described in more detail below.
(48) In the next (second) sampling period, CLK.sub.rst is again asserted to apply the common mode voltage V.sub.cm to the inputs of the amplifier 1104. Additionally, CLK.sub.rst_rise is asserted to apply the positive reference voltage V.sub.refp to the node holding the negative ramp voltage V.sub.rampm and to apply the negative reference voltage V.sub.refm to the node holding the positive ramp voltage V.sub.rampp. This manner of operation has the advantage of resetting the respective ramp voltages to the relevant reference voltage in the event that the respective ramp voltages at their peak did not reach the relevant reference voltage during their run up/down, which may help avoid drift away from the relevant reference voltages. Still further, the chopping switch 1106 is controlled to be in the pass-through configuration to connect the positive reference current I.sub.refp to the positive input of the amplifier 1104 and to connect the negative reference current I.sub.refm to the negative input of the amplifier 1104. The chopping switch 1106 is maintained in the pass-through configuration through the second sampling period to cause the voltage across ramp capacitor C.sub.rampm to decrease which decreases the negative ramp voltage V.sub.rampm from its positive peak to its negative peak and to cause the voltage across ramp capacitor C.sub.rampp to increase which increases the positive ramp voltage V.sub.rampp from its negative peak to its positive peak, as shown. Further during the second sampling period, the de-chopping switch 1108 is controlled to be in the cross configuration to cause the negative ramp voltage V.sub.rampm to be provided as the positive output voltage V.sub.outp and to cause the positive ramp voltage V.sub.rampp to be provided as the negative output voltage V.sub.outm. As shown in
(49) In the next (third) sampling period, as in the first sampling period, CLK.sub.rst is again asserted to apply the common mode voltage V.sub.cm to the inputs of the amplifier 1104, CLK.sub.rst_fall is asserted to apply the negative reference voltage V.sub.refm to the node holding the negative ramp voltage V.sub.rampm and to apply the positive reference voltage V.sub.refp to the node holding the positive ramp voltage V.sub.rampp (advantageously resetting the respective ramp voltages to avoid drift away from the reference values), and the chopping switch 1106 is controlled to be in the cross configuration to connect the negative reference current I.sub.refm to the positive input of the amplifier 1104 and to connect the positive reference current I.sub.refp to the negative input of the amplifier 1104, which is maintained through the third sampling period to increase the negative ramp voltage V.sub.rampm from its negative peak to its positive peak and to decrease the positive ramp voltage V.sub.rampp from its positive peak to its negative peak, as shown. Further during the third sampling period, the de-chopping switch 1108 is controlled to be in the pass-through configuration to cause the positive ramp voltage V.sub.rampp to be provided as the positive output voltage V.sub.outp and to cause the negative ramp voltage V.sub.rampm to be provided as the negative output voltage V.sub.outm. As shown in
(50) The operation of the various switches of the ramp generator 402 of
(51) Advantages of the use of a chopping technique to convert a triangular wave, employed internal to the ramp generator 402, to produce a sawtooth wave may now be described. First, the purpose of the PWM modulator is to convert continuous voltage domain information into time domain information in which the time domain has a period T. A large reset time in the conventional ramp generator 902 of
(52) In an alternate embodiment, the de-chopping switch 1108 provides a polarity-inverted version of the signal input V.sub.IN to the comparator 406 on alternating sampling periods, rather than a polarity-inverted version of the triangular wave, which may effectively accomplish a similar result.
(53) Referring now to
(54) Referring now to
(55)
(56) During calibration, the common mode voltage V.sub.cm is connected to the signal inputs, and the comparator 406 compares the ramp voltage V.sub.ramp to the common mode voltage V.sub.cm. The calibration reference clock CLK.sub.cal causes the D flip-flop 1407 to latch the comparator 406 output D.sub.P, as shown in
(57) For an ideal ramp voltage V.sub.ramp, the crossing occurs at the midpoint of the ramp. If the ramp slope is higher than normal (i.e., higher gain), a trim bit is changed in a step by step manner to reduce the slope of the ramp voltage V.sub.ramp until the polarity of Deal flips, as shown in
(58) Various non-idealities may exist in the quantizer 304. For example, the comparator 406 may have an offset which creates an error term on the gain calibration. The gain calibration process only looks for the crossing and perceives the offset as a gain error even when the slope of the ramp voltage V.sub.ramp is correct. Adjusting to make the crossing mid-ramp creates an undesired gain error, shown in
(59) For another example, the comparator 406 may have a time delay T.sub.d, shown in
(60) Advantageously, embodiments of an improved calibration process are now described that removes the comparator offset V.sub.os and compactor delay T.sub.d so that they do not create a gain error term which may advantageously result in a more accurate calibration of the gain of the quantizer 304, e.g., the ramp gain/slope.
(61) Referring now to
(62) During calibration, the common mode voltage V.sub.cm is connected to the signal inputs. Initially, higher than normal values of the reference voltage V.sub.refp and V.sub.refm are provided through the ramp generator 402 to the chopping switch 1605 and are scaled down over time until two consecutive values of the comparator 406 output D.sub.P are the same, at which time the comparator 406 offset Vos is measured, as shown in the timing diagram of
(63) Referring now to
(64) Referring now to
(65) In addition to the offset and the time delay of the comparator, other non-ideal characteristics of the quantizer 304 that may be separately measured and adjusted may include the RC time constant used by the ramp generator to generate the ramp voltage; a bandgap used in a current source of the quantizer; a resistor, capacitor and/or transistor size ratio that controls a gain of the quantizer; a clock speed of the quantizer; and various circuit parasitic. These other non-ideal characteristics of the quantizer 304 may be measured in addition to, in place of, and/or in combination with the comparator 406 offset V.sub.os and time delay T.sub.d and adjusted for while the gain error of the quantizer 304 is calibrated.
(66) Referring now to
(67) At block 1802, a first non-ideality is measured (e.g., comparator offset V.sub.os per
(68) At block 1804, a second non-ideality is measured (e.g., comparator delay T.sub.d per
(69) At block 1806, additional non-idealities may be measured (e.g., RC time constant, current source bandgap, resistor/capacitor/transistor size ratio clock speed). The operation proceeds to block 1808.
(70) At block 1808, the quantizer 304 is adjusted using the values of the non-idealities measured at blocks 1802 through 1806. The operation proceeds to block 1812.
(71) At block 1812, the gain of the quantizer 304 is calibrated while the quantizer 304 is adjusted using the non-ideality measured values.
(72) It should be understoodespecially by those having ordinary skill in the art with the benefit of this disclosurethat the various operations described herein, particularly in connection with the figures, may be implemented by other circuitry or other hardware components. The order in which each operation of a given method is performed may be changed, unless otherwise indicated, and various elements of the systems illustrated herein may be added, reordered, combined, omitted, modified, etc. It is intended that this disclosure embrace all such modifications and changes and, accordingly, the above description should be regarded in an illustrative rather than a restrictive sense.
(73) Similarly, although this disclosure refers to specific embodiments, certain modifications and changes can be made to those embodiments without departing from the scope and coverage of this disclosure. Moreover, any benefits, advantages, or solutions to problems that are described herein with regard to specific embodiments are not intended to be construed as a critical, required, or essential feature or element.
(74) Further embodiments likewise, with the benefit of this disclosure, will be apparent to those having ordinary skill in the art, and such embodiments should be deemed as being encompassed herein. All examples and conditional language recited herein are intended for pedagogical objects to aid the reader in understanding the disclosure and the concepts contributed by the inventor to furthering the art and are construed as being without limitation to such specifically recited examples and conditions.
(75) This disclosure encompasses all changes, substitutions, variations, alterations, and modifications to the example embodiments herein that a person having ordinary skill in the art would comprehend. Similarly, where appropriate, the appended claims encompass all changes, substitutions, variations, alterations, and modifications to the example embodiments herein that a person having ordinary skill in the art would comprehend. Moreover, reference in the appended claims to an apparatus or system or a component of an apparatus or system being adapted to, arranged to, capable of, configured to, enabled to, operable to, or operative to perform a particular function encompasses that apparatus, system, or component, whether or not it or that particular function is activated, turned on, or unlocked, as long as that apparatus, system, or component is so adapted, arranged, capable, configured, enabled, operable, or operative.