Measuring Distortion on the Cheap

Wow, lots of good feedback. Thanks. The two sweep fn/tabs are pretty much Joost Breed's code with conversion to WPF and slight cleanups. I kind of like having the two tabs because each tab retains its settings while you're working. Also the amplitude sweep does some cool auto-ranging as you run it whereas the frequency sweep doesn't.

I thought about a dropdown for the attenuation, but as the only 'dangerous' setting and one you use all the time I don't mind it as a few obvious buttons - especially when the bottom row are voltage attenuated and all my usage is on a touchscreen. I could add a dropdown. Hmmm.

I like Range (dB) better. Most of the wording is Joost's original wording and as much as it's a great starting point I don't think english is necessarily his first language. I'll see about improving some of that.

I haven't implemented the Bode plot at all because I just don't need it. I would like to implement an impednace+inductor+capacitor test though since the box could totally do that. I think the main thing the Bode plot does is accurate phase results but I haven't tried Joost's version at all.

Really appreciate the feedback. Check the build in a week if you're curious. The current Release is very usable albeit slightly buggy but next week is planned for esthetics and some robustness. I don't really have any other charts on my to-do list other than the passive (R/L/C/Z) tests if you'all have suggestions.

Frankly I'd rather Matt at QuantAsylum use my code as a base or at least a learning experience. Not there yet.

Mark

Ah, also, all the frequency entries (and many voltage entries) are currently editable dropdowns. The IMD photo on github (and below) is the only 'current' image and it shows that I totally agree. And I know Hann is a crappy window for IMD but the stock windowing choices are pretty bad.
 

Attachments

  • CCIFImdPlot.png
    CCIFImdPlot.png
    534.7 KB · Views: 43
Last edited:
By the way I considered a Mac version. My preferred language for this stuff nowadays is typescript (i.e. a totally portable a web app) but Joost provided this really nice starting point in C# and math in typescript is a bit slow so...

Even there, using the rest interface is kind of piggy compared to straight USB.

Finally, given that the actual QA40x application is in C# I thought seeing source code in C# for something usable might be a hint to QA. : )
 
Hey @tomchr

You might take a look at this program I'm working on. Compared to the stock app, well...
View attachment 1431714

See: https://github.com/MZachmann/QA40xPlot
Looks interesting. Might have a play with this. I second tomchr's plea for portability to MacOS and Linux...
BTW it would be nice to have two modes, line spectrum (dBV) and noise spectral density (i.e. dB(V/√Hz)) - or at least display the conversion factor (which depends on sample rate, FFT points and window function).
 
I kind of like having the two tabs because each tab retains its settings while you're working.
That's a really good point, actually. That's actually something the APx500 software does not do. Not in Bench Mode anyway. It's not a major annoyance as it's actually pretty rare that I sweep vs frequency, but if you have to switch back and forth it's annoying to have to reenter the sweep settings.

Also the amplitude sweep does some cool auto-ranging as you run it whereas the frequency sweep doesn't.
Why not? What if you're measuring the amplitude response of a filter? It'd then be rather handy that the analyzer did the auto-ranging so you could get precision even as the filter starts to attenuate.

I thought about a dropdown for the attenuation, but as the only 'dangerous' setting and one you use all the time I don't mind it as a few obvious buttons - especially when the bottom row are voltage attenuated and all my usage is on a touchscreen. I could add a dropdown. Hmmm.
I'm not super passionate either way. I'm just surprised that radio buttons were used. Then again, I'm used to the AP which has auto-ranging built in and enabled by default, so I tend to not worry about range switching except in the few cases where I need to turn it off. Maybe in actual use, the two-click process of a drop-down would annoy me whereas radio buttons wouldn't.

Why is it a dangerous setting? Is there a risk of frying the analyzer if 0 dB is selected with a high-voltage input? How is it any less dangerous with radio buttons than with a drop-down?

I haven't implemented the Bode plot at all because I just don't need it. I would like to implement an impednace+inductor+capacitor test though since the box could totally do that. I think the main thing the Bode plot does is accurate phase results but I haven't tried Joost's version at all.
If the difference between Bode plot and the other plots in the software is that the phase is added, then I suggest having a drop-down or checkbox type selector on the frequency sweep pane that allows the user to show/hide the phase.

I don't really have any other charts on my to-do list other than the passive (R/L/C/Z) tests if you'all have suggestions.
I would get the basics working really, really, REALLY well before adding features.

math in typescript is a bit slow so...
Yeah. I wouldn't be willing to give up speed to have a Mac version. QA's application is not super optimized on the math either. I had trouble running a 1M-point FFT. If I recall correctly, it would barely run with 48 kHz sampling rate and cause the application to become irresponsive at 192 kHz SR. I didn't mention it in the video as I was running some resource-hogging applications (AP software, video capture) at the same time and the PC isn't the latest generation. If I recall it's an Intel i9-8700 with 16 GB of RAM. Still... That should be plenty for an FFT even a 1M-point one.

Tom
 
  • Like
Reactions: anatech
Wow long and useful thread... let's see to Tom's Points

1) "I kind of like having the two tabs because each tab retains its settings while you're working." Yeah, in addition the settings are saved for both tabs when you save settings so it's like a bunch of different test instruments simultaneously.

2) "for the attenuation, but as the only 'dangerous' setting " - it's dangerous because there's a chance of frying the input caps if you set it to 0 (or any top-row attenuation) by mistake with big amps (I was just testing a 200-300WPC class A last week). I've done this twice and luckily it's ok if you react quickly. For serious testing I run on a small tablet with a small display and it's tough to quickly hit a combobox, pull it down, and quickly tap on the right value. Buttons are no issue. I am tomorrow, however, adding an "Automatically set at start" button to the group of radios so in practice it should never get manually set.

3) "be rather handy that the analyzer did the auto-ranging so you could get precision even as the filter starts to attenuate." The frequency sweep does autorange once so it's not "cool" because it's a single voltage value. Having it work correctly for the whole f range is a neat idea. I can do that...

4) yeah I agree with the bode plot comment. I haven't look at Joost's implementation at all. Maybe there's something else cool there.

5) I'd love to boost the performance more. I saw a few places in the code where delays existed to allow viewing stuff all of which I truncated and it's still piggy so this is the analyzer now. Maybe some fft work is happening in the QA403 itself or it's just native C# or something. So, no typescript.

to Mark's comments:
I completely agree and I have time planned out to work on math and those data summaries. It just wasn't highest priority but, for example, having percents with 7 leading zeros is amusing albeit not useful. Suggestions are welcome.


Thanks for the input. btw I've taken a fair amount of advice already. ++
Mark
 
Last edited:
Hi Tom,
There are times when autoranging isn't desired. To each his own, depending on what you are looking at.

Bench mode is how I would typically be running an AP. Production line isn't my thing. They went to a lot of effort to make it possible for unskilled techs to use the equipment on a line.
 
it's dangerous because there's a chance of frying the input caps
That's a design flaw in my book.

There are times when autoranging isn't desired. To each his own, depending on what you are looking at.
I agree. But I also didn't say that auto-ranging should be forced onto anyone. I would enable it by default and allow the user to select the input range from a drop-down menu if they want to override the auto-ranging. But that, of course, assumes that the analyzer is designed to handle this.

If auto-ranging runs the risk of blowing the analyzer, then it's obviously best to have it be disabled by default and maybe include a warning or allowing the user to set min/max limits for the auto-ranger when it's enabled.

It happens once every couple of years that I need to use a fixed range on the AP. But then again, that also is designed so it can handle whatever you throw at it without blowing up parts. Maybe I'm spoiled by having tools that work well. I didn't realize that was being spoiled. 🙂

Bench mode is how I would typically be running an AP. Production line isn't my thing. They went to a lot of effort to make it possible for unskilled techs to use the equipment on a line.
I use Bench Mode the vast majority of the time. Sequence Mode is very handy when you need to repeat the same set of measurements. I do that quite a bit during the final stages of debugging and also during characterization of a new amp. I've also used it to test all the HPA-1 and HPA-10 headphone amps I've built. It works well. I think both modes have their uses.

Tom
 
Hi Tom,
Agreed, sequencing is really only useful for production. In debugging, you normally are looking at one function / range solving a problem. Performance is normally done at 1 watt, then if you do a full power test, you know the range. I rarely do full power tests (measurements). That is too dependent on the supply voltage and it will vary at each client's home or business. Anyway, my input range is typically the same most of the time. If you know the supply voltages of the amplifier it's easy to set our input range for full power.

I use M.I., and that sequences as well. It's cheaper than AP's UI and does the same. It just won't run the AP. That's why I say they are asking the moon for their software.

As for autoranging, you assume the operator is half intelligent. A good analyzer has overload indication far below damage level. That and the display fills up - lol! There's a hint something is clipping! I believe it should be off by default. So if a bit of overload might damage a distortion analyzer (within reason), I agree is it poorly designed. That covers just about every sound card. They were designed for consumer 0 Vu, 316 mV, not as amplifier test units. You can't blame the hardware for being misused. That is 100% an operator issue.

I test everything fro msignal amplifiers, including MC amps to MM levels. Then up to stupidly high powered amplifiers. Some having balanced outputs. You have got to be aware of what you are doing.
 
It just won't run the AP. That's why I say they are asking the moon for their software.
Oh, I 200% agree that AP is asking stupid amounts for their software. Note that the $3k-ish for the "base model" of the software does NOT give you Bench Mode. That costs extra. It also doesn't do much beyond what a DMM does. That costs extra too. Want to measure crosstalk? That'll cost ya. Want multi-tone analysis -> $$$. By the time you have something that's useful you're spending about $7k just on the software. Now, it is really good software. But c'mon! $7k!

Also note that on the "lower cost" analyzer, the APx51x-series, Bench Mode costs extra. I seem to recall that you have to pay extra for things like multi-tone. That was one of the things that pushed me into the APx525 in 2014.

I completely understand that businesses exist to make money and if they don't make money there's no business. But I think you should get fully functional software and not some crippled version when you spend many kilobucks on the analyzer. But, hey... That's me.

You have to buy the APx525 or 555 to get fully functional software.

Tom
 
Hi Tom,
Yes, that is pretty close to what I found out at the seminar I was at last. I agree, no way will I buy an overpriced analyzer and then get completely soaked with software prices. My scope was bad enough! I'd buy a Keysight U8903B before an AP at those prices.

Right now my RTX with M.I. does everything needed.
 
I agree, no way will I buy an overpriced analyzer and then get completely soaked with software prices.
Well... The software does come for "free" with the analyzer when you buy the APx525 or APx555. I think with the APx585 as well, but I'm not sure.

As far as I remember it's only with the APx51x analyzers that you have to pay for Bench Mode and "advanced measurements". I do disagree with that model. Proprietary hardware should come with the control software. The full version, not a crippled one. I'm fine having to pay extra for advanced smart speaker measurements and whatnot, but I shouldn't have to pay extra to be able to measure crosstalk as is the case with the APx51x.

One can argue whether the prices for the analyzers are fair. They're not intended for the hobbyist, that's for sure. OTOH the hardware is pretty darn amazing and the software is very good. I guess if customers no longer feel they get good value for the money with AP they'll take their money elsewhere.

Right now my RTX with M.I. does everything needed.
M.I.? I'd like to buy a vowel. What's M.I. mean? Not V.I.? Virtins?

Tom
 
Hi Tom,
The Keysight unit is something I would trust more. It might be controlled my M.I., maybe not. But you can write your own sequences for any Keysight (Agilent / HP) instrument. Others may have already written what you need if it is beyond the natural abilities. I haven't directly compared the software.

Yes, Multi-Instrument by Virtins. That was $600 and represented great value. It does a great job with the RTX 6001.

As for value. There just isn't that much money in the AP anything. I can sort of see 35K for the U8903B that goes up to 1.5 MHz. I feel that is far too expensive as well. This stuff isn't built like it used to be, far east construction (not Japan). The old 3585A was built like a tank, far more costly to build than new instruments. Great signal isolation between stages. That was worth what you paid for it back then, plus you could write your own stuff (and were encouraged to). Control was open and standard, published. Same for the U8903B from a control standpoint.

What you are paying for is the ability, not the technology. That and the name and control abilities. You can manufacture this stuff and sell it a lot cheaper, while still making a large profit. My 4 channel MSO scope at 1 GHz is another matter (built in arb too). Frequency costs money, processing doesn't.

I bet the software charges exceed costs of the entire instrument to build. Supporting AP is another thing again.

Sure, nothing is really intended for hobbyists. That doesn't mean you soak the market. I feel all test and measurement equipment has exceeded it's worth in the last decade. Quality has dropped at the same time.
 
I can sort of see 35K for the U8903B that goes up to 1.5 MHz
The APx555 goes past 1 MHz as well. I seem to recall that the highest sampling rate is 2.5 MHz. The generator tops out at 204 kHz, which certainly is plenty for audio. It is an AUDIO analyzer after all.

The main selling point of the AP is that it goes pretty darn close to -150 dBc THD at 1 kHz at a few volt output. For the THD+N, mine bottoms out around -125 dB. It's possible there is a fancier U8903B than the one I looked up recently, but the one I looked at bottomed out at -108 dB THD+N. Keysight doesn't specify the THD.

The extra dB is what you pay for.

That doesn't mean you soak the market.
Agreed.

Tom
 
  • Like
Reactions: anatech and mlloyd1
Competition needs to get just a little better. AP doesn't feel enough heat yet to be "reasonable". But a REALLY key reason folks buy AP is because the printouts say "AP". Back in my telecomm days, I sometimes had customer meetings where reviewing AP test results was offically part of the meeting!🙂
 
But a REALLY key reason folks buy AP is because the printouts say "AP".
That's definitely a part. A plot captured with a stack of COSMOS gear and REW will never carry the same weight as the same plot captured on an AP. That's what happens when you develop a reputation as someone who provides top performing gear.

One of the selling points for Ferrari is the yellow badge that says Ferrari on it. There are many other cars that are also low to the ground and go fast, but it's just not the same.

Humans are not rational critters.

Tom
 
  • Like
Reactions: mlloyd1 and anatech
There is cachet in the AP brand / having the logo on your print-out when you give it to the client. However, Bruce is now retired and the firm is effectively under the control of private equity (how's that working out for Tek? My '70s Teks still work, but all 3 of the post 2001 models have faults). How long will it keep this reputation for? What are the chances that it even has a designer capable of moving performance forwards from the 555? For example, Sam Groener works in the RF world now… If you have the chops to design something that will outperform the 555 why would you focus on audio, when there is far more $$$ to be had in RF?

For the THD+N, mine bottoms out around -125 dB

At what voltage / frequency? Is this 2VRMS / 1KHz / 20-20K? My understanding is that AP guarantee the 555 to have -120dB THD+N at this standard and anything beyond that is a bonus (discussion at audio science review suggests quite a bit of variation between machines). My 2722 hits -115dB and my best UPV will hit -114dB with its own B1 oscillator, or -115 when fed from the 2722.

I can sort of see 35K for the U8903B that goes up to 1.5 MHz. I feel that is far too expensive as well. This stuff isn't built like it used to be, far east construction (not Japan)

The UPV was built in Germany and they still service them. There is one on Ebay at the moment for $5.2K USD (it has the B1 oscillator and is a steal at this price IMO – I am telling you in the hope that you will buy it before I give into temptation and get another). You can compare the construction against the 555 in these links:

https://www.eevblog.com/forum/repair/rohde-schwarz-upv-audio-analyzer-teardown-and-repair/

https://archimago.blogspot.com/2020/07/pictures-audio-precision-apx555-b.html

Were R+S to release a UPV successor, I can’t envisage it being any cheaper than the 555. The subscription for SW updates after you’ve spent $40K on the 555 grates with me. R+S have never done that. The R+S has a live FFT FR feature that shows 20Hz-22K in real time with almost no lag. It’s something I’ve never seen on any AP model. I have an awful feeling that if I got a 555 the UPV would get more use on account of this feature. The UPV is such a workhorse. It gets more use than any other piece of test gear, bar bench PSUs.
 
  • Like
Reactions: anatech