Audio Measurement Pre-Amplifier - Page 1
Forum section: electronics / projects

author: toli
author_rank: Frequent Contributor
timestamp: August 16, 2019, 03:33:11 pm
content: Hi All,I wanted to share a project I have been working on for a few months in my (limited) spare time. To allow me to make easier and better measurements of audio equipment (and a few other things as I'll mention later) I wanted to design a measurement pre-amplifier for audio band frequency. I have initially considered building something that is "readily available" like thesoundcard interfaceproject from pmillett. However, I wanted something that is very versatile that will have a high maximum voltage range, low noise for low signal measurement, SE and BAL support for both input and output signals even for higher voltage swings at the input. Therefore I've decided to design one that will meet my specific needs.I plan on using it for both testing audio gear for distortion and other possible issues (noise for instance), as well as being able to measure low noise densities for things like voltage regulators and a few other low noise projects I have in mind where this will come in handy.To support all of this I went for a balanced input structure, and 6 different gain range (selected by relays) from -40dB to +60dB in 20dB steps. For the most sensitive ranges (+40dB and +60dB gain) the input referred noise is 7nV/rtHz (assuming it is driven from a low impedance source obviously). The input resistance is 100Kohm at each terminal, so 200Kohm differential.The schematic for the main part of the circuit is shown below:The schematic is actually fairly straight forward with a resistive voltage divider with 3 different outputs for 0dB/-20dB/-40dB settings, then an input protection circuit to keep the first stage opamp's safe. This is followed by 2 more stages with gain (0dB/+20dB in the first stage, -6dB/+14dB/+34dB in the second stage), and finally enters the output line driver which adds its own +6dB of gain.There is also a T-RMS -> DC converter chip there to be able to measure the input signal amplitude (this isn't shown in this snip of the schematic).The PS section shown below:It starts with some input protection, into an isolated DC-DC module, followed by low-noise linear regulators and some filters. This is done to keep the supply noise+ripple low enough for the higher gain settings where noise coupling could be an issue.I've used an additional smaller board to mount some of the controls to be able to place everything into a moderate size case when I'm finished.The complete schematic can be downloaded here:http://tolisdiy.com/wp-content/uploads/2019/08/MeasurementPreAmp_Schematic_TolisDIY-1.pdfThe assembled pre-amplifier can be seen below:It is comprised of the main board that does all of the heavy lifting, a smaller control board for range selection and mounting of the range select LED's, and a panel mount DC voltmeter that I got from AliExpress obviouslyI have done some measurements for THD, noise, and a few other parameters. I am measuring i t with amodded EMU 0404 USB soundcard. To extent linearity of the measurement setup I use alow distortion oscillator, and anotch filterfor 1KHz measurement. I am actually very happy with the performance, they match my expectations and calculated values quite well. I think I could potentially get more out of with a higher end soundcard or interface, but if I'm being honest, the current level of distortion is just excellent for my hobby use.THD vs. frequency, unfortunately this is limited by the EMU 0404 USB:Spectrum with external oscillator at 1KHz 2Vrms SE signal, through the pre-amplifier and into the soundcard, again, THD is limited by the EMU 0404 USB:With a notch filter added before the EMU:The notch filter transfer function can be seen here:http://tolisdiy.com/wp-content/uploads/2019/08/fr_measure.pngOverall it seems that THD on the order of 0.0001% can be measured even with a full-scale signal. I'm saying "on the order of" and not giving an exact number because even with the notch filter, it seems like the residual distortion of the EMU is preventing me from getting an accurate reading of the distortion of the pre-amplifier.Finally, I've measured the input noise density on the higher gain settings (terminated with 50ohm to reduce coupling and measure the noise assuming a low impedance source is connected), with 0dBFS being 4mVrms:This translates to ~8nV/rtHz, which is very close to the calculated value of 7nV/rtHz that I've expected based on the datasheed of the input amplifier (3.3nV/rtHz typical value) and the value of resistors in the input protection and the feedback loop of the first stage.This project isn't done yet, as I still need to design the front and rear panels for the aluminium case, to make it look nicer, easier to use, and reduce external coupling especially on the more sensitive ranges.However, this project finally reached a point where I've been able to verify its performance meet the target I have set when I've started it, so I figured I should share it on the forumI have tried to keep this post shorter and to the point, which is why I have omitted many measurements results, and comments about the circuit design. However, if you'd like to read in more detail, I have posted all of it with much more detail onmy blog.

author: magic
author_rank: Super Contributor
timestamp: August 16, 2019, 09:20:28 pm
content: 1ppm ain't badI think this is territory where a low-noise bipolar like 5534 or OPA2210 could give those JFET opamps a good run for their money. But the -20dB attenuator would cause problems because of its 9k output impedance.Speaking of which, what's THD at 10kHz on -20dB range? The datasheet of ADA4625 is silent on certain important issue.

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 03:38:03 am
content: You are right, the need for a low current at the input of the op-amp is why I had to opt for something with a FET input. Otherwise going for a BJT input device would have been better and noise could have also been even better on the 2mV/20mV ranges.Measuring at 10KHz is something I can do only with the EMU 0404 as my external oscillator and notch are tuned for 1KHz only. Therefore at 10KHz I'm limited to ~2Vrms and a measurement limit of ~0.001% THD which is the best the EMU can do at this frequency. This means that on the 20V (-20dB) range the input amplitude will be much smaller than full-scale simply because I don't have anything on the bench that can generate a low distortion 20V 10KHz signal. Given these limitations, I've measured this, and the measurement is still limited by the EMU 0404 performance at ~0.001% at 10KHz.

author: magic
author_rank: Super Contributor
timestamp: August 17, 2019, 05:36:32 am
content: Okay, that's not terrible. The problem is of course capacitance of the opamp's input JFETs (and, frankly, your protection diodes too but it's smaller in comparison) which varies with signal level. Its impedance forms a divider with the attenuator resistors and the division ratio varies with input voltage.It may still become somewhat worse when the full 20Vrms input range is utilized.The protection diodes could be bootstrapped if it ever becomes a problem. As for opamps, they exhibit this problems in various amounts and it's rarely documented. Maybe the ADA4625 isn't too bad. At least its inputs seem to be cascoded.http://www.ti.com/lit/an/slyt595/slyt595.pdf

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 06:23:06 am
content: You are right on point there magicThis is the exactly why I went for discrete small signal diodes that have very low capacitance in the input protection circuit, and I've biased them with 5V of reverse voltage so that their contribution is minimal to the input capacitance of the opamps even with maximal expected signal swing.The results of 0.001% are limited by the EMU as I've mentioned, so I can't really say what the exact limit under these conditions is.What is possible to do relatively easily is to add a series resistor of 10K at the input and measure this on the 2V range. This will have little attenuation, so it will allow measurement with maximal swing at the input of the opamps. While this will still be limited to 0.001% by the EMU limits, this will be done with a full swing input at the input of the opamps which will stress them significantly more. I actually think that's valuable information as it will give me some indication of the limits in a range that I can't verify otherwise. So this discussion is already bearing fruitsIn fact, its actually so easy to do, that I went ahead and added 10K in series with each of the inputs in a very improvised fashion and measured it now (see attached image for the improvised connection).For the full swing of 2V at 10KHz (1.97Vrms to be exact), the THD is now about 0.0012% (vs 0.001% in bypass mode). So ~0.001% is about the best THD that could be measured with a full-swing 20Vrms signal on the 20V range at 10KHz. This will obviously be better in other ranges, so if THD is all I would like to measure, I can always switch to the 200V range even for a 20V signal which will both reduce the output impedance of the divider and reduce swing at the opamp input

author: magic
author_rank: Super Contributor
timestamp: August 17, 2019, 12:56:59 pm
content: What happens if a unity gain amplifier is connected such that its input goes to IN- and output to IN+?In theory the fundamental should be eliminated and distortion amplified by whatever gain is selected, in practice some IN-/IN+ difference will exist because of phase delay through the DUT and will be amplified too. I always wandered how bad it is but too lazy to do the math

author: SiliconWizard
author_rank: Super Contributor
timestamp: August 17, 2019, 01:19:26 pm
content: Well, the input stage of your design is basically a "discrete" instrumentation amp. Resistor matching will be critical, otherwise you'll get pretty poor performance. Getting good enough CMRR could cost you a lot more than you'd expect. I would personally use an integrated instrumentation amp instead. Less components and guaranteed performance. Something like the INA163 for instance.

author: magic
author_rank: Super Contributor
timestamp: August 17, 2019, 01:41:53 pm
content: I don't think it was meant for the kind of madness I proposedFor normal buffering/attenuation/amplification of DUT output, CMRR is only needed to suppress common mode noise from EMI and ground loops.Now, check out THD specs of that in-amp

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 02:47:42 pm
content: There is a subtle difference between this structure and an instrumentation amplifier like the INA163 - the output here is differential, not SE.The part that follows the input divider, around the ADA4625 and the OPA1632, is not as sensitive to a CM signal. In the INA163 structure, the sensitivity to resistor matching is coming mainly from the 2nd stage where a diff->se translation takes place, and therefore resistor matching there is critical. For the circuit I've used, the OPA1632 is operating in diff-in-diff-out structure, the sensitivity is reduced.Translation to SE signal (if a SE load is connected) is done by the THAT 1606 line driver. It uses integrated resistors with good matching obviously.For the 20V/200V range, there is matching issue on the input voltage divider, this will remain the same for an integrated solution like the INA163 as these voltages will have to be scaled down with the same resistive divider.On the other hand, by implementing it this way I have a far larger selection of opamps I can use according to some other specs I might want to optimize.EDIT:Because of the CMFB of the OPA1632, despite the fact it is diff-in-diff-out, mismatch in resistors around it will translate CM voltage into DM at this stage. This is unlike for the first stage around the ADA4625 where the CM is passed along as is with a gain of unity, without translation to differential and is being translated to DM in the next stage.Therefore, while this won't have as high of a CMR as an integrated (or trimmed) instrumentation amp, this will still be better than a discrete instrumentation amp like structure with a SE output.With that being said, I think there is a simple circuit modification to improve this significantly without any resistor matching on board, although it may (or may not) affect other parameters such as distortion. If I were to move the Vocm pin of the OPA1632 to a point that is sitting at the CM of its inputs, this will remove the CM->DM translation and leave it as a CM signal at the output. Since the last stage (THAT 1606) has integrated resistors with better matching, it will have less CM->DM translation and improve this further.This is actually fairly easy to do, all it takes are a couple of resistors, and perhaps a small capacitor to filter very high frequencies. I will consider this if I ever do make a new revision of the board, although I will have to make sure it doesn't affect other parameters, as THD and noise are more critical for me than CMR.

author: udok
author_rank: Regular Contributor
timestamp: August 17, 2019, 05:29:33 pm
content: The 12 Volt supply is a bad decision. Line level signals goes up to 20 dBu or about 11 Volt peak. The AD4625 Jfet Opamp has a common mode range of12 Volt - 3.5 Volt = 8.5 Volt max. For best CMRR of 130 dB the datasheet says Vcc - 6 Volt!Better use a LM4562 or AD795. They have lower noise, better THD, no nonlinear input capacitance, and the 20 nA input current does not hurt in Audio stuff.The input voltage divider should use an resistor network and/or trimmers if precision is a goal.The Audio Precision Sys1 input divider even uses cap trimmers to improve frequency response, and NE5534 (if i remember correctly).The Amp structure is too complicated for my taste.Maybe it would be better to use an Audio transformer for the balanced to single ended conversion?

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 07:02:35 pm
content: udok, lets not forget what this pre-amplifier is meant to do. It wasn't designed to operate with a 20dBu signal right at the input of the op-amp, its only meant to measure the distortion of that signal. Using a voltage divider at the input to bring it down to a voltage level that is more comfortable for the opamp is completely ok from my point of view. Especially when you consider the fact that the output signal must be 2Vrms or lower to be within the linear range of my sound-card. BTW, the 12V supply isn't limiting this here, the input protection circuit will kick in before this happens, as it wasn't designed to have more than a 2Vrms signal at the opamps input. 20dBu out of range? No problem, switch to a higher range, all the way up to 200VrmsAbsolute reading accuracy is also not too critical here, I'm totally ok with 1-2% measurement error as the readout is meant mostly for measuring output power of amplifiers.This was meant to be another tool for my work bench. It will be used to measure output of low impedance speaker amplifiers, as well as internal nodes measurements for both transistor and valve amplifier (where high impedance and DC voltage could be present) and more. Therefore, it is AC coupled at the input, and has a 100Kohm input impedance at each input.The LM4562 you mention is one of my preferred opamps, when it meets the requirements. In fact, if you'll have a look at my blog, you'll see that I've modified the EMU 0404 USB and used LM4562's quite extensively there. This is a low cost, low noise, low distortion opamp, which I use very often. However, for this application where the input is AC coupled and has a 100Kohm resistance at the input, the 10nA (72nA max) input bias current is simply too high for the higher gain settings.There are obviously other ways to implement every circuit, each with its own pros and cons. I've actually had a few different circuit drawings until I've finally decided that this one seemed like a good compromise between my different requirements. This pre-amplifier was designed for my own use to be able to measure distortion and noise of my other projects. It achieves the target spec I was aiming for, so I'm happy with itWith that being said, I do take your (and everyone else's who have replied here) comments into account, and if I ever modify the circuit in the future I will revisit these design decisions once more.

author: SiliconWizard
author_rank: Super Contributor
timestamp: August 17, 2019, 07:32:59 pm
content: Quote from: magic on August 17, 2019, 01:41:53 pmI know this part pretty well, have used it in several designs actually. It's been a popular solution for XLR input stages in audio gear.A 0.002% THD+N figure @1kHz (and 1nV/rtHz) is not too shabby really.I understand the OP was after something much better than 0.002% THD+N. He only talks about THD though, not THD+N. The difference could surprise him, but maybe he just said THD for THD+N.I was wondering about the overall performance of the circuit.Not completely convinced about CMRR not being an issue in the OP's design (as he later admitted), but not as big a deal as a SE output as he stated.Although I completely understand the OP's approach, and the theoretical benefits, I'd still be curious to compare it with a much simpler one with something like a INA163 (with the lowest gain you can get by with) + DRV135 for the output stage.I admit it would be more of a design for a pure audio device rather than for a measurement equipment, still I'd be curious to see what you can get out of that (especially in terms of noise).

author: magic
author_rank: Super Contributor
timestamp: August 17, 2019, 07:49:57 pm
content: Quote from: udok on August 17, 2019, 05:29:33 pmNo, they are horrible. Their current noise of a few pA/rtHz will annihilate whatever voltage noise advantage they have, in this circuit. There are better bipolar opamps for 1.5k source impedance.Quote from: udok on August 17, 2019, 05:29:33 pmSamuel Groner's paper shows plenty of problems in bipolar opamps trying to pass 20Vpp from 100k source impedance. Often worse than the old DIFET OPA627. I'm not sure how it translates to this circuit, though.Their inputs actually still have variable capacitance, between base and collector. Additionally, Early effect modulates their beta, producing nonlinear bias current which impresses nonlinear voltage drop on source resistance. Both of these effects can be mostly eliminated by dynamic cascoding, do you know if your favorite opamp does it?Less obviously, Early effect in the tail source modulates input stage standing current, which again modulates bias current.Finally, distorted current output from the input stage is required to compensate for second/third stage nonlinearity. Again, divided by beta, this nonlinearity leaks to the outside world.Quote from: udok on August 17, 2019, 05:29:33 pmHaven't those been ditched because of distortion and frequency response inaccuracy?Quote from: toli on August 17, 2019, 07:02:35 pmConsider switching attenuation on the input side, so that impedance seen by the opamp stage is always 1k. Only the DUT will see less load impedance at -20dB than at -40dB.Quote from: SiliconWizard on August 17, 2019, 07:32:59 pmOkay, at last some improvement over the parts I postedBut frankly, noise isn't the primary concern in THD measurements, just use longer FFTs, up to the limits of lifetime of the UniverseeditThough you are right, it will interfere with noise floor measurements. Frankly, I would separate the two and use different preamps for each. Amplifying noise is no rocket science, at least at audio frequencies.

author: SiliconWizard
author_rank: Super Contributor
timestamp: August 17, 2019, 07:58:18 pm
content: Quote from: magic on August 17, 2019, 07:49:57 pmTrue, if you're talking about gaussian noise. So if we're talking about the nV/rtHz figures, you're mostly right.As for THD vs. THD+N, this is yet another story. If using the definitions correctly, THD is only pure harmonic distortion. THD+N includes any form of distortion. Some forms of distortion that you can typically find in audio circuits are non-harmonic. Thus a low, pure THD figure may look misleadingly low.Quote from: magic on August 17, 2019, 07:49:57 pmYep, and why not.

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 08:38:49 pm
content: Regarding the N of the THD+N, it isn't neglected, its simply low enough to be sufficiently below that of the EMU at the 2V range. For the higher gain ranges the input ref'd noise improves as expected and the added gain brings the external amplified noise above the noise floor of the EMU. This shows things that are otherwise too small in amplitude for the EMU to display, but unfortunately this means that the maximum input signal amplitude must drop accordingly with the range or else it would clip the input of the soundcard.The EMU 0404 USB is the most limiting part of the setup at the moment, despite the fact it has improved with the opamp replacement to LM4562. However, if I'm being honest, the measurement capabilities I have with this setup are sufficient for my current needs. Extending this further will probably cost significantly more than the 40$ I payed for the EMU 0404 USB on eBayIf anyone is familiar with another USB sound interface (must be external since I'm using a laptop) that performs better than this EMU for a reasonable price, do share.

author: udok
author_rank: Regular Contributor
timestamp: August 17, 2019, 08:47:07 pm
content: Quote from: toli on August 17, 2019, 07:02:35 pmIf it never sees 20dBu at the input, this is not a problem. Anyway it is simple to change the supply to +-15 Volt in the future if needed.QuoteUsing a divider at the input is bad for SNR and you get more THD and noise from the Opamps. Better use a divider in front ofthe ADC as you could use low value resistors there.If you use a JFet Opamp you could even increase the input impedance to 1 MOhm as 100k is often on the low side.QuoteThat circuit is a lot of complexity for 2% measurements. For power amps a simple voltage divider is all you need.But if the circuit work for your needs, it is ok. There are always compromises to be taken.

author: udok
author_rank: Regular Contributor
timestamp: August 17, 2019, 09:00:10 pm
content: Quote from: magic on August 17, 2019, 07:49:57 pmHorrible is somwhat exaggerated....1.6 pA * 1kOhm of source impedance is 1.6 nV , the 1 kOhm alone has 4 nV of Gaussian noise.QuoteNo, but because the good ones are expensive and not small.The top line of Audio Precisions Analyzers still use them in the generator output stage.

author: toli
author_rank: Frequent Contributor
timestamp: August 17, 2019, 09:02:04 pm
content: Quote from: udok on August 17, 2019, 08:47:07 pmThere's the issue of high voltage at the input which means the input must have a divider, simply because I want to measure output of amplifiers directly with this.Regarding 1Mohm, I doubt it will be practical. The output impedance of the divider will result in significantly increased distortion, as magic mentioned earlier in this thread.Quote from: udok on August 17, 2019, 08:47:07 pmWhat I was really after is the THD(+N) in the audio band, and getting low enough noise density on the sensitive ranges. The absolute amplitude accuracy of the readout isn't of significant importance to me and 1% is completely acceptable. If I ever need a more accurate absolute reading, I can always connect the 34401A in parallel. So far I didn't need better than 1% accuracy when measuring output power of amplifiers. No one really cares if its 64W or 65WQuote from: udok on August 17, 2019, 09:00:10 pmInteresting, I didn't know they still use these, I was also under the impression these weren't good enough for these applications. Do you know what part # they use there or something else that is of similar spec? It'd be interesting to see what sort of spec they have (and how much they cost)

author: udok
author_rank: Regular Contributor
timestamp: August 17, 2019, 09:33:43 pm
content: Quote from: toli on August 17, 2019, 09:02:04 pmMaybe, but as suggested you could use 1 MOhm in the 200 Volt range. Useful, if you plan to use the Diff amp for in circuit measurements.QuoteThe same argument is valid for 60 dB or 100 dB THD. Nobody cares in real lifeQuoteThey are custom made Jensen Transformers. In addition they use an opamp feedback trick to lower distortion at low frequencies.The circuit is described in a patent by Bruce Hofer.

author: magic
author_rank: Super Contributor
timestamp: August 18, 2019, 06:38:26 am
content: Quote from: udok on August 17, 2019, 09:00:10 pmOK, exaggerated. I thought that they are slightly worse, actually.Nevertheless, source impedance is 1k5 due to that series protection resistor so 2.4nV/rtHz. Combined with voltage noise, 3.3nV/rtHz. That's only marginally better than the 40+ year old NE5534Meanwhile OPA2210 gets 2.3nV/rtHz. Combined with Johnson noise, it's only 5.5 vs 6, though.Somebody have the specs of LT1028 at hand?BTW, JRC has an interesting part, the NJM2122. Quite cheap, rated 1.5nV/rtHz and 3.6µA bias, so only 1pA/rtHz of shot noise. Not sure how close they get to theoretical limits, though. The datasheet is as helpful as you can expect from JRCQuote from: udok on August 17, 2019, 09:33:43 pmSuggested by me? Not really, to make things clear, I suggested reducing input impedance at -20dB to 10k for lower noise and THD.But maybe there is a solution to this madness. Make it LEGO: one box for preamp, several boxes with various dividers connecting straight onto its BNC inputs. No relays, only music in the signal pathQuote from: udok on August 17, 2019, 08:47:07 pmTry to sell a 60dB amplifier without some good "audiophile" story behind itAudio, ahemScienceReview will review it, measure the lousy THD and then perform a listening test definitely concluding you are worse than the Benchmark AHB2.I'm not even kidding, check them out.