LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sample rate different of buffer size.

Solved!
Go to solution

Hi,

I am new to Labview and I encoutered a problem.

I did some measurments using two DAQs and used continous samples type. One device was NI 9239 and this one has a different possible sample rate than the buffer size that I set. I set the buffer size 3000 and the possible samples rate of the device were 2941 and 3125.

From what I understood, this type (continous samples type) gets filled up the buffer size and send it to the PC.

My question is the following: the sample rate of my device is 3000 or 3125?

0 Kudos
Message 1 of 8
(3,761 Views)

Sample rate and buffer size are not really related.  So that makes things a little confusing.

 

The way DAQs work is they sample at a certain rate and put the data into a buffer.  Since you did not set the Samples Per Channel in the DAQmx Timing, the buffer should be as large as possble (this is a good thing).  When you go to read  the data, you are just reading everything currently in the buffer (number of samples to read was unwired, therefore read everything).  As samples are read, they are removed from the buffer.  You want to avoid having the buffer fill up since that will cause data to be lost.

 

Now the clock rate will be rounded off to the closes valid clock rate.  If you really want to know what your exact clock rate is, put a property node after the DAQmx Timing VI and read the sample rate.


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
0 Kudos
Message 2 of 8
(3,744 Views)

The problem is that I've done the measurments already. I cannot run the measurments again.

Now I just want to find the sample rate.

I believed that it was 3000 and now I discovered some differences and I went back to the sample rate.

And when I analyze the data I can see that the sample rate seems to be 3000. But I see that the sample rate of the DAQ is 3125.

Is this thing possible?

0 Kudos
Message 3 of 8
(3,740 Views)
Of course it's possible. Haven't you read the specs and the possible sample rates with the internal clock? You also chose to not read and store the sample rate. If you had acquired a waveform data type, the information would be in the file. As mentioned, the result had nothing at all to do with the buffer size.
0 Kudos
Message 4 of 8
(3,724 Views)

I read the specifications of the DAQ. It has 2941 and 3125 as sample rate values.

I didnt used waveform writing.

0 Kudos
Message 5 of 8
(3,720 Views)
So the question is solved.
0 Kudos
Message 6 of 8
(3,716 Views)

So my sample rate is 3000 or 3125?

0 Kudos
Message 7 of 8
(3,710 Views)
Solution
Accepted by topic author ramirez988
Why do you keep asking? You just said that you know a sample rate of 3000 is not possible.
0 Kudos
Message 8 of 8
(3,707 Views)