LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Samples to Read and Rate (Hz)

Solved!
Go to solution

@sandeep23 wrote:
  1.  How do you determine how long it takes for your loop to run, and
  2. How often is data read from this "buffer" (time in seconds)

The loop rate in a properly written application will be determined by your DAQ Read.  And that time is determined by the number of samples you are asking for and the sample rate of the task.  So if you are sampling at 1kS/second (1ms/sample) and requesting 100 samples per read, you loop rate should be around 100ms.  It is very simple math if you just keep your units straight.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 11 of 13
(1,678 Views)

For those who want to save time reading all the answers. In the Test Panel, and when you select "Continous" Mode, the items "Rate (Hz)" and "Samples to Read" both combined serve to represent THE QUALITY of the analog signal acquired at the selected input.

 

In practice, both determine the time interval represented in the panel, in the simple way: time interval = (samples to Read)/(Rate), in seconds. For exampe, if your input signal has a period of 10 ms, and you select a Rate of 30000, and 900 samples to read, you will observe 3 periods of your input signal in the panel.

 

So one guess there are many different combinations to represent your input signal... But here the QUALITY enters. If you select a low Rate and  consequently, reduce in the same proportion your Samples to Read (in order to conserve the time interval represented), for example Rate = 3000 and Samples to Read = 90,  you observe again 3 periods in the panel, but the quality of the curve represented is worse. If Rate = 300 Hz, and Sample to Read = 9, much worse. 

 

Hope it has been helpful.

0 Kudos
Message 12 of 13
(897 Views)

Hi buzentauro,

 

what you call "quality" is infact described by Nyquist and Shannon!

You need to define the sample rate first, depending on your signal/DUT...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 13
(889 Views)