Author Topic: use your Rigol DS1052E to measure distortion?  (Read 16471 times)

0 Members and 2 Guests are viewing this topic.

Offline slburrisTopic starter

  • Frequent Contributor
  • **
  • Posts: 556
  • Country: us
use your Rigol DS1052E to measure distortion?
« on: July 12, 2010, 08:13:22 pm »
I'm working on calibrating a newly repaired WaveTek 275 function generator.
Internally, it produces triangle waves and shapes them into sine waves, using
a variety of circuits to make the sine waves "clean".

The calibration procedure calls for a distortion analyzer and in spite of my
predilection for getting odd test equipment off of Ebay, this is something I
don't have.

Since the procedure requires looking at sine waves to 100Khz, I was thinking
I could just feed it to my Rigol scope and turn on the FFT.  Then do the
adjustments looking for the best display with the fewest spurs. 
Crackpot idea? 

Does the 1502E have enough resolution to make a half-way decent
distortion analyzer?

Failing that, I may just skip that part of calibration and hope that it's
good enough.

Scott
 

alm

  • Guest
Re: use your Rigol DS1052E to measure distortion?
« Reply #1 on: July 12, 2010, 10:03:41 pm »
Not really half-way decent (which would be something like .01% distortion), but most function generators don't produce sines with half-way decent distortion either, so it might just work, not sure what the distortion specs are? I believe I verified something for harmonics below -55dB, but it was on a different scope. Hook it up, set the scope to FFT and check if the harmonics are significantly above the noise floor. If they are, you can adjust for lowest harmonic amplitude. If it's hard to see, I would just leave it, if it's reasonably close, no point in risking making it worse. Note that THD is based on the sum of squares of the amplitudes of the harmonics.
 

Offline slburrisTopic starter

  • Frequent Contributor
  • **
  • Posts: 556
  • Country: us
Re: use your Rigol DS1052E to measure distortion?
« Reply #2 on: July 12, 2010, 10:10:46 pm »
Looking at the manual:

Sine Distortion (THD at 5Vp-p)
< 0.5% 10mHz to 99.9kHz (yes, that's millihertz)
No harmonics above
- 40 dBc 100Khz to 999kHz
- 30 dBc 1Mhz to 12Mhz

Scott
 

Offline saturation

  • Super Contributor
  • ***
  • Posts: 4787
  • Country: us
  • Doveryai, no proveryai
    • NIST
Re: use your Rigol DS1052E to measure distortion?
« Reply #3 on: July 12, 2010, 10:58:07 pm »
There's a discussion on this on a thread on spectrum analyzers

https://www.eevblog.com/forum/index.php?topic=525.0

https://www.eevblog.com/forum/index.php?topic=653.0

Since the Rigol has an 8 bit ADC, the maximum resolution is 1/256.  That likewise is the maximum the FFT can measure.  It should detect the amplitude of harmonics >= 0.4% but it wouldn't be able to measure values lower than that.
« Last Edit: July 12, 2010, 11:04:21 pm by saturation »
Best Wishes,

 Saturation
 

alm

  • Guest
Re: use your Rigol DS1052E to measure distortion?
« Reply #4 on: July 12, 2010, 11:14:31 pm »
-40dBc should be detectable I think, <0.5% probably not. Noise is likely to limit dynamic range even more than the vertical resolution would suggest, the effective number of bits of the system is likely significantly less than 8.
 

Offline DJPhil

  • Frequent Contributor
  • **
  • Posts: 511
  • Country: 00
Re: use your Rigol DS1052E to measure distortion?
« Reply #5 on: July 12, 2010, 11:18:17 pm »
Check out the distortion analyzer project on Rod Elliot's audio projects page. He's got a bunch of audio test equipment builds projects with the details to go with them.

The circuit itself may not be very useful at high frequencies, but it's a start. He's got a good discussion of theory in that project that really explained to me what was happening in a dedicated distortion analyzer.

Hope that helps some. :)
 

Offline NiHaoMike

  • Super Contributor
  • ***
  • Posts: 9780
  • Country: us
  • "Don't turn it on - Take it apart!"
    • Facebook Page
Re: use your Rigol DS1052E to measure distortion?
« Reply #6 on: July 13, 2010, 01:06:35 am »
Since the Rigol has an 8 bit ADC, the maximum resolution is 1/256.  That likewise is the maximum the FFT can measure.  It should detect the amplitude of harmonics >= 0.4% but it wouldn't be able to measure values lower than that.
At lower frequencies, there's a trick called "decimation" that increases SNR at the expense of bandwidth. Not sure if the Rigol does that, but I wouldn't be surprised given that it has a fast CPU.

One thing you could do is build a highpass filter set to just below twice the test frequency. Then you can examine for harmonics and minimize them.
Cryptocurrency has taught me to love math and at the same time be baffled by it.
Cryptocurrency lesson 0: Altcoins and Bitcoin are not the same thing.
BTC: 18813fu8LQEdDwH9YLM1ABed3XwCfeSeFi
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 42284
  • Country: au
    • EEVblog
Re: use your Rigol DS1052E to measure distortion?
« Reply #7 on: July 13, 2010, 02:30:50 am »
One thing you could do is build a highpass filter set to just below twice the test frequency. Then you can examine for harmonics and minimize them.

Yes, that's a common technique.

It might be possible to use the Rigol's digital high pass filter to knock out the signal and then gain it up to get a better look at the harmonics, but I haven't tried it.

On an analog scopes, you can actually *see* the distortion under 1% if you know what you are looking for. Lower if you have a grey beard and stroke it and have your tongue at the correct angle  ;D

Dave.
 

Offline DJPhil

  • Frequent Contributor
  • **
  • Posts: 511
  • Country: 00
Re: use your Rigol DS1052E to measure distortion?
« Reply #8 on: July 13, 2010, 04:17:00 am »
On an analog scopes, you can actually *see* the distortion under 1% if you know what you are looking for. Lower if you have a grey beard and stroke it and have your tongue at the correct angle  ;D

I immediately took that as a Robert Pease reference, as I am working my way through Troubleshooting Analog Circuits at the moment. His temperament is almost exactly that of my grandfather, from whom I inherited all my technical leanings. A man after my own heart indeed!

I strongly recommend the book. I've only been through about two dozen electronics books so far, but this one is #2 right behind AoE for me and I'm only half done!
 

alm

  • Guest
Re: use your Rigol DS1052E to measure distortion?
« Reply #9 on: July 13, 2010, 04:28:20 am »
It might be possible to use the Rigol's digital high pass filter to knock out the signal and then gain it up to get a better look at the harmonics, but I haven't tried it.
I doubt it, since the limiting factor is ADC dynamic range / noise.

For analog high pass/notch filters, you need a pretty sharp cut-off (Rod Elliot discusses this), multiple poles or active filters are probably needed. They're probably the best cheap solution, but you do need to tune it to the output frequency pretty accurately (less so for high pass filters, but they only work if you're just interested in harmonic distortion), and the output frequency may not be that stable for a function generator.
 

Offline saturation

  • Super Contributor
  • ***
  • Posts: 4787
  • Country: us
  • Doveryai, no proveryai
    • NIST
Re: use your Rigol DS1052E to measure distortion?
« Reply #10 on: July 13, 2010, 12:17:18 pm »
Its a fast enough test to see if the Rigol can discern the harmonics at 100kHz, why not slburris give it a whirl on the Rigol and send us a pic?



It might be possible to use the Rigol's digital high pass filter to knock out the signal and then gain it up to get a better look at the harmonics, but I haven't tried it.
I doubt it, since the limiting factor is ADC dynamic range / noise.

For analog high pass/notch filters, you need a pretty sharp cut-off (Rod Elliot discusses this), multiple poles or active filters are probably needed. They're probably the best cheap solution, but you do need to tune it to the output frequency pretty accurately (less so for high pass filters, but they only work if you're just interested in harmonic distortion), and the output frequency may not be that stable for a function generator.
Best Wishes,

 Saturation
 

Offline NiHaoMike

  • Super Contributor
  • ***
  • Posts: 9780
  • Country: us
  • "Don't turn it on - Take it apart!"
    • Facebook Page
Re: use your Rigol DS1052E to measure distortion?
« Reply #11 on: July 13, 2010, 01:37:05 pm »
For analog high pass/notch filters, you need a pretty sharp cut-off (Rod Elliot discusses this), multiple poles or active filters are probably needed. They're probably the best cheap solution, but you do need to tune it to the output frequency pretty accurately (less so for high pass filters, but they only work if you're just interested in harmonic distortion), and the output frequency may not be that stable for a function generator.
Switched capacitor filters like the Maxim MAX264 allow you to build a filter that can be tuned by adjusting the clock frequency.
Cryptocurrency has taught me to love math and at the same time be baffled by it.
Cryptocurrency lesson 0: Altcoins and Bitcoin are not the same thing.
BTC: 18813fu8LQEdDwH9YLM1ABed3XwCfeSeFi
 

Offline jahonen

  • Super Contributor
  • ***
  • Posts: 1057
  • Country: fi
Re: use your Rigol DS1052E to measure distortion?
« Reply #12 on: July 13, 2010, 08:11:53 pm »
I'm not sure if this has effect on the Rigol, but on Agilent MSO6034 you get quite an improvement on the FFT noise floor (about 20 dB) when using trace averaging. That is also worth trying.

Regards,
Janne
 

alm

  • Guest
Re: use your Rigol DS1052E to measure distortion?
« Reply #13 on: July 13, 2010, 08:40:42 pm »
Its a fast enough test to see if the Rigol can discern the harmonics at 100kHz, why not slburris give it a whirl on the Rigol and send us a pic?
I agree that the first test should be to see if the scope can see the harmonics directly, that's an easy test and was also my first suggestion. It's just that I didn't think any digital high-pass/notch filter would do much good, but of course no harm in trying.

Switched capacitor filters like the Maxim MAX264 allow you to build a filter that can be tuned by adjusting the clock frequency.
The MAX264 sounds like a neat solution, although probably not good enough for low-distortion signals (eg. any halfway-decent audio amplifier), it should be fine for this application. The $14 or so each might be more than Scott is willing to spend, not to mention availability.

I'm not sure if this has effect on the Rigol, but on Agilent MSO6034 you get quite an improvement on the FFT noise floor (about 20 dB) when using trace averaging. That is also worth trying.
Averaging should work, as long as you're only after harmonics, and not something like SINAD. It will improve the noise floor, but not the dynamic range (at least not on cheap scopes). Even with 8.00 bits ENOB, the best you're going to get is -48dB (.4%).
 

Offline slburrisTopic starter

  • Frequent Contributor
  • **
  • Posts: 556
  • Country: us
Re: use your Rigol DS1052E to measure distortion?
« Reply #14 on: July 15, 2010, 03:30:11 am »
I haven't yet tried the DS1052E yet on the distortion test because I'm stuck
several steps before that in the calibration trying to
calibrate the 10 millihertz to 10 hertz range.  The WaveTek 275
uses current sources to charge and discharge capacitors to form a
triangle wave.  For most of the frequencies up to 12 Mhz, that's done
by selecting different capacitors and varying the charge current.

Below 10 Hz though, it's done with what they call a capacitance
multiplier circuit.  Looks like that selectively bleeds some of the charging current
to extend the time period.  However, the potentiometers to adjust this
won't let me get to the frequencies the manual says.  So something
must be wrong in the multiplier.  Having to read the manual now
to figure out how this circuit works.

One I get past these low frequency alignments, I'll start trying the distortion
tests.

Scott
 

Offline slburrisTopic starter

  • Frequent Contributor
  • **
  • Posts: 556
  • Country: us
Re: use your Rigol DS1052E to measure distortion?
« Reply #15 on: July 16, 2010, 09:08:14 pm »
I've gotten past the calibration problems -- helps to be adjusting
the correct potentiometer!

Attached is a capture of the FFT from my Rigol doing the
distortion adjustment.  Hmm, do I believe it?

Maybe I'll just leave well enough alone and carry on.

Scott
 

Offline saturation

  • Super Contributor
  • ***
  • Posts: 4787
  • Country: us
  • Doveryai, no proveryai
    • NIST
Re: use your Rigol DS1052E to measure distortion?
« Reply #16 on: July 16, 2010, 10:51:30 pm »
Looks good to me, slburris.  Just to confirm your read push out a square wave at the same frequency, it should have a clearly defined set of harmonics diminishing at a mathematically predicted rate, i.e.,  the sinewave with a frequency 11 times the fundamental will have an amplitude of 1/11th the fundamental.   So it could show you the limits of its resolution.
Best Wishes,

 Saturation
 

Offline slburrisTopic starter

  • Frequent Contributor
  • **
  • Posts: 556
  • Country: us
Re: use your Rigol DS1052E to measure distortion?
« Reply #17 on: July 16, 2010, 10:57:51 pm »
Yes, if I feed my scope a square wave, the FFT shows a dropoff at each harmonic.

Scott
 

alm

  • Guest
Re: use your Rigol DS1052E to measure distortion?
« Reply #18 on: July 17, 2010, 05:03:18 am »
The fundamental looks way too low to me to show any harmonics, you should set the vertical scale to dB, and adjust vertical settings and amplitude so the fundamental is as large as possible (without clipping), to maximize dynamic range. Adjust window for best amplitude accuracy. If the fundamental is 5Vpp, the harmonics should be below 50mV (-40dB) for 100kHz plus, and even less for lower frequencies. You should probably decrease the horizontal scale of the FFT (don't have a Rigol, but I'd expect that you have to increase the timebase setting), since you're mainly interested in the first few harmonics.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf

 

-->