NI Home > Community > NI Discussion Forums

High-Speed Digitizers

Showing results for 
Search instead for 
Do you mean 
Reply
Member
wickiwau
Posts: 10
0 Kudos
Accepted Solution

Average on board of NI5922

Hi

 

Is it possible to sample at 15 MS/s and calculate the average of 15 Samples on board of NI5922? That would rusult in 1 MS/s averaged datapoints.

 

I use NIScope 3.8.1 and LabView 10.0.1 (64-bit) Software.

 

Thanks!

Tobi

Active Participant
Marco_Brauner
Posts: 641

Re: Average on board of NI5922

Hi Tobi,

 

as you can read in http://digital.ni.com/public.nsf/allkb/657C83B20DF586678625720D0028A7D1?OpenDocument, 

you can use Onboard Signal Processing (OSP) in some cases, but it is more like for doing filtering, decimation and related stuff.

 

 

"...For instance, all functions and properties labelled NI-SCOPE Measurements are done in software (Array Measurements, Waveform Measurements, and Scalar Measurements). This includes Windowing, Histograms, IIR and FIR digital filters, FFTs and Power Spectrums, Interpolation, Averaging, Max/Min Detection, etc." 

 

So averaging won´t be done on the Scope´s FPGA, but that´s no issue, just use the respective NI-Scope-Funktion to average your samples.

 

regards

Marco Brauner NIG

 

 

 

Member
wickiwau
Posts: 10
0 Kudos

Re: Average on board of NI5922

Hi Marco

 

Thanks for your answer!!!

Actually I didn't´t find an appropriate averaging function in NIScope. There is "RIS Num Avg" in the NiScope Property Node, but I don´t think it´s the right function... Do you know a specific function?

 

At the moment I do it as followed:

- fetch digitizer data (e.g. 2000 points per fetch, at 2 MS/s)

- Send the digitizer data into a queue

- build the averages with the attached sub-vi after dequeueing in LabView

- write the averages to TDMS datafile

 

Problem: the averaging seems to be very slow and the bottleneck (my queue fills up!!!). Maybe the conversion back to I16 is problematic... How could I build averages straight away from I16?

 

any suggestions to make it faster or do it differently?

 

Thanks

Tobi Broger

Institut für Mikrotechnik Mainz

 

Trusted Enthusiast
Henrik_Volkers
Posts: 2,230

Re: Average on board of NI5922

Im also interested in this question since we use quite a bunch of them :smileywink:

I haven't found an answer in the Manual,  KB. 

 

The 5922 is a flex resolution card with a tricky delta-sigma converter. So the answer might be buried in the way the ADC works. Other scope cards have different converter architectures.

 

My current understanding is, that the card constantly sample with 120MHz 6bit delta-sigma and the chosen 'samplerate' determine the way of decimation/averaging/weighting/filter

Might be, that if you sample with 1MS/s the value is already a short term average of 1µs, but the aliasing filter diagram (fig 16 in the paper here or see spec) is an indicator that it is not.

And to extend the question: In lower samplerates, will there be a point where pure decimation is used?

Please NI point to some (or publish) papers that put light to that question.  

 

Maybe a solution is to use the on board FIR filter to do the averaging (read the filter, fold it with a rectangular window (your averaging), write back) and use a simple decimate. BTW have you tried the decimate (continous).vi ?

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'
Member
wickiwau
Posts: 10
0 Kudos

Re: Average on board of NI5922

Hallo Henrik

 

Thanks for your interesting post!

If it is really the case that i would already get the averages at lower sampling rates I wouldn't have to do anything at all. I will perform the following experiment to find out: measure noise at 1 MS s-1 and at 10 MS s-1: If the Amplitude of the Noise is similar >> there is no averaging, If the amplitude of the noise at 1 MS s-1 is lower >> there is averaging (Averaging shoud reduce noise, right?). Does that experiment make sense?

 

I will also have a look at decimate.vi and get back to you asap!

 

Greetings from a Appenzeller in Germany

(Which is quite unusual at the moment, most Swiss do only shopping in Germany at the moment :-)

Tobi

Member
wickiwau
Posts: 10

Re: Average on board of NI5922

Already did the experiment

 

I fetched data (I16) at different sampling rates and measured the Amplitude (i was to lazy to scale it to Volts, as it is not important for the comparison):

 

Results:

1 MS s-1 >>   Amplitude 290

10 MS s-1 >> Amplitude 1170

10 MS s-1 and with AverageSignal.vi >> Amplitude 300

 

It really seems, that NI5922 does averaging on board by default!

Could someone from NI approve this?

 

@Henrik: I had a look at decimate.vi. It would be perfect to use - but i guess it won´t be necessary anymore ;-).

It would be great to hear your comment about the little experiment above!

 

Ciao Tobi

 

 

Trusted Enthusiast
Henrik_Volkers
Posts: 2,230
0 Kudos

Re: Average on board of NI5922

[ Edited ]

The expected noise reduction would be SQRT(10) .. about 3.16   you measured factor 4  ... what type of noise did you use (had a look at the spectrum)?

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'
Trusted Enthusiast
DFGray
Posts: 2,804

Re: Average on board of NI5922

If I remember correctly (and it has been awhile), the 5922 has a 6-bit ADC and gets it resolution by averaging.  So if you take a 1MHz sample rate, you should get the time average of the signal you would get if you averaged ten points taken at 10MHz.  This is not true for other National Instuments high-speed digitizers (non-flex-resolution).

 

If you prefer to use an explicit averaging, I rewrote your code and got about an order of magnitude speed increase.  You can get more by turning off debugging in the VI properties.  You can also set it to subVI priority, but only do that if you can guarantee you will not be calling it simultaneously, or it will slow you down a lot.

 

Let us know if you have further questions.

Using LabVIEW 2011 - 2013 on Windows 7 64-bit
Trusted Enthusiast
Henrik_Volkers
Posts: 2,230
0 Kudos

Re: Average on board of NI5922


Henrik Volkers wrote:

Im also interested in this question since we use quite a bunch of them :smileywink:

 

And to extend the question: In lower samplerates, will there be a point where pure decimation is used?

 

Please NI point to some (or publish) papers that put light to that question.  

 


Maybe it's my lag of understanding deltasigma converter , but this card is special ... and some kind of workhorse here, so everything bit of extra information is wellcome.

(It took me long time to understand the HP3458 in detail (much more than a dual slope converter :smileywink: ) but you can get about 4-5kg documentation for it.

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'
Member
wickiwau
Posts: 10
0 Kudos

Re: Average on board of NI5922

[ Edited ]

Thanks a lot for the constructive discussion and the code! Very kind! I´ll prefer methode1: the "averaging" on a lower sampling rate!

 

Best wishes

Tobias Broger