| Electronics > Projects, Designs, and Technical Stuff |
| Class D amplifier distortion measurement filter |
| (1/3) > >> |
| GregDunn:
Trying to find a satisfactory solution to the problem of measuring the distortion of a Class D amp (Crown XLS) with my HP 331A distortion analyzer. The problem is that even though the PWM signal is well filtered and not an issue in actually driving speakers, enough of it leaks through to make the distortion measurements invalid (the HP has a measurement bandwidth of about 600 kHz, and the PWM freq is about 384 kHz). I tested an amp and got distortion on the order of 1-10%, and I know it's much better than that within the audio range. So I need a filter between the amp output and the analyzer to get rid of the high frequency junk. There are commercial units which are too expensive for just casual measurements, and many schematics on the web which use not only hand-wound inductors (not a problem) but weird value low tolerance caps (a problem). Within limits I can make a custom cap network, but then I start getting problems from extra lead length. I would like the stopband to be at least -80 dB by the time it gets to the PWM freq so it will be below the HP measurement limit. It should be passive, because I may put 40-50V into it - the HP will withstand much more than that. Does anyone know of a passive filter design which uses near-standard cap values and has good rejection at 400 kHz with reasonable flatness in the audio band? I have been looking at https://rf-tools.com/lc-filter/ - would that work OK as long as I keep the input/output impedances well above the nominal 8Ω of typical speakers? |
| T3sl4co1l:
0. Are you after THD exactly, or THD+N? Because if I understand correctly, you already have the latter. More useful of course would be THD+N in 20-20k Hz bandwidth for example, or just plain old THD (i.e., the fundamental and harmonics only; but not IMD, but that doesn't exist in a single-tone test so that's fine). 1. Note that the output impedance is probably capacitive, and a speaker (if you're using it as load during this test) isn't very much of anything, it's all over the place. So to get a reasonable filter, you will probably need a constant-resistance type, or at least, informally, enough damping (at one or both ports) to keep it behaved. 2. Looser tolerances are found in lower-order filters, and the softer rolloff types (Bessel or Butterworth). You can probably get by with cored inductors just as well, too (but mind that they can introduce some distortion, so if you're down in the 0.01% range, you may consider air-core after all). The filter order, and to a lesser extent the filter type, determines the attenuation beyond the cutoff frequency. All [all-pole*] filters of a given order, have the same cutoff asymptote (-20dB/decade/pole), it's only shifted around depending on type. Your signal bandwidth, then, sets what order the filter must be (for a given type). *There are other types; if we allow a zero in the response, we can notch a specific frequency, or mold the stopband as we please; but this comes at the cost of less asymptotic attenuation. In the extreme case, the elliptic (Cauer) filter has as many zeroes as poles, giving actually a flat stopband; such is the price paid for a wickedly sharp cutoff. There are also filter types of historic interest (m-derived) which are easier to design than modern (analytic, pole-zero) types; but, they require more inductors and capacitors for the same overall response. To get -80dB at ~400kHz, that's four decade-poles; a single RC would thus have to roll off at 40Hz, which I'm guessing is a bit silly. To roll off by 20kHz, you'd need a bit less than a 4th order filter; maybe a bit more (5th?) if it's a bit on the loose side (closer to a Bessel). 3. To apply damping, the dumbest, easiest method is simply resistive attenuators. Put a 3 or 6dB pad between the amplifier and filter, and again between the filter and load (if it's a reactive load like a speaker). This is a tee or pi network of resistors, set so that the input and output resistances (when the other port is loaded by system resistance) equals the system resistance. So, in this case, 8 ohms. Easily calculated: http://www.chemandy.com/calculators/matching-pi-attenuator-calculator.htm e.g. 8 ohms, 8 ohms and 6dB requires 24, 24 and 6 ohms. (The network is always symmetrical if the input and output resistances are equal.) Or for tee, 2.7, 2.7 and 10.7 ohms. If you can't afford loss in the circuit, then a parallel R+C and/or series R||L (Zobel network) can be applied, which has no effect at low frequencies, but which introduces losses around the transition frequency, and this works in the same way as the attenuator, making the filter less sensitive to the amplifier or load impedance. Downside is the filter response gets softer (or maybe lumpier) as a result, so some tuning should be done to keep a reasonable response. (Set up the circuit in SPICE and keep poking values until the response looks right, whether the source is a voltage source, resistor or current source.) Tim |
| GregDunn:
I'm interested in THD or THD+N in the 20-20k band. The filter is not going between the amp and load, it's just going between the load and the measuring device, so I would really rather the impedance be as high as possible so that it doesn't dissipate any power. It shouldn't matter if there's some reactance because I'm not looking at the spectrum, just the total harmonics. I'm looking at air-core inductors because the limit of my measurement accuracy is under 0.1% and if I can reduce any added distortion below that level it will be much less hassle. My initial guess was a 5th order Chebyshev with about 10kΩ load impedance so it won't dissipate much power: |
| T3sl4co1l:
Ahyup, then higher Z is good, and simple series resistance will do for termination. I wouldn't go for kohms, good luck finding inductors good enough -- but 100 to 1000 ohms should be doable enough. Anything in that range should do, while loading the amp negligibly. :) Tim |
| David Hess:
Bob Cordell's book "Designing Audio Power Amplifiers" discusses that problem. The AES specifies a mostly passive filter, AES17, to be used between the class-d amplifier output and the distortion meter. Modern distortion meters may have this built in. Note that measuring harmonic distortion of higher frequency signals is practically impossible because their harmonics will either be removed by the filter or overwhelmed by the switching noise. |
| Navigation |
| Message Index |
| Next page |