High-Speed Digitizers

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting Time/Div on NI-5133

I am having trouble setting or verifying Time/Div setting on the NI-5133 Digitizer. I am sure that it is a function of Record Length and Sample Rate, but how can I ensure it's setting and verify what the current setting is?

 

 

Thanks!

0 Kudos
Message 1 of 4
(6,890 Views)

Nevermind... Since using this instrument (NI-5133) is somewhat new, I realized that Time\div is a function of Record Length & Sample Rate.

But I still question how one ensures that you have the minimum Time\Div set once you set Record Length and Sample Rate.

For instance, I took a spin with teh NI-SCOPE SFP and I can see various Time\Div in the dropdown, but how could I effectively have the same options in code?  

 

I am using C++ niScope.h in my C++ application so I am utilizing the niScope_ConfigureHorizontalTiming function.

0 Kudos
Message 2 of 4
(6,882 Views)

The Soft Front Panel is divided into 10 horizontal divisions.  You are correct that the available selections for time/division will change based upon how many samples you request (record length) and the sampling rate capabilities of the digitizer you are using. The software does some calculations behind the scenes to select nice round numbers for the dropdown list that are appropriate to match the requested record length and maximum sample rate of the digitizer.

 

Once you set the time/division, the sample rate will be displayed below your selection.  Based upon 10 divisions you can back calculate what the record length was coerced to.  For example,  I can set the number of samples to 1000 and select 1us/div.  This reports a sample rate of 100MS/s. 

 

       100MS/s x 1us/div x 10 div = 1000 samples

 

Therefore I was able to get exactly the number I requested.  If instead I choose 128 samples, I can get 100MS/s with 0.2us/div.

 

        100MS/s x 0.2us/divx10div = 200 samples 

 

Therefore I get some additional samples to be able to fill 10 divisions at the requested rate or time/div.

 

If you wish to code time/div into your own application instead of using sampling rate here are some suggestions:

 

1) Select how many divisions you want and set your display to have these settings for the horizontal axis

2) Select a list of possible values for time/div(1us, 2us, 5us, 10us, 50us, 100us etc)

3a) For simplicity you can always sample at full rate and only have the  record length fixed for each setting

3b) Alternatively based upon the requested number of samples and time/div, find the nearest valid sample rate (use the device specifications to understand what rates are valid for your digitizer or try setting the rate and use the "actual sample rate" property to see what it was coerced to.  Once you have the valid rate and time/div, calculate the record length required to achieve this setting.

4) For robustness you may wish to set minimum and maximum values on sample rate and recordlength to prevent trying to set a sample rate which is out of range,displaying large amounts of data or not having enough samples to fill the display (<10).

 

Hope this gives you some ideas on how to get started. 

0 Kudos
Message 3 of 4
(6,873 Views)

Thanks Jennifer. Yes, I pretty much came to the same conclusion that you discussed above. It just took me a little while to realize it!

 

 

0 Kudos
Message 4 of 4
(6,839 Views)