LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

onboard buffer size

Solved!
Go to solution

Hi, can anyone tell me the difference between the "buffer size" and "onboard buffer size" under the DAQmx buffer>>output property?

 

Thanks,

David
www.controlsoftwaresolutions.com
0 Kudos
Message 1 of 5
(4,510 Views)

Hi David,

 

Short Name: Input.BufSize

Property of DAQmx Buffer

Specifies the number of samples the input buffer can hold for each channel in the task. Zero indicates to allocate no buffer. Use a buffer size of 0 to perform a hardware-timed operation without using a buffer. Setting this property overrides the automatic input buffer allocation that NI-DAQmx performs.

 

Short Name: Input.OnbrdBufSize

Property of DAQmx Buffer

Indicates in samples per channel the size of the onboard input buffer of the device.

 

Kind Regards, 

Applications Engineer
0 Kudos
Message 2 of 5
(4,473 Views)

Hi Rob,

 

thanks for the reply. I did however check the context help myself.

 

I was actually looking at the output buffer but looking at the input buffer property may have helped. My confusion is because (for the output buffer) as I understand them the descriptions are effectively the same.

 

Looking at the properties for the input buffer the main difference is the words 'specifies' and 'indicates', implying a set/get on the same property? and in fact when you place the Input.OnbrdBufSize property it is read only.

 

However, the output properties Output.BufSize and Output.OnbrdBufSize both use the word 'specifies'

 

Output.BufSize  

"Specifies the number of samples the output buffer can hold for each channel in the task......"

 

Output.OnbrdBufSize  

"Specifies in samples per channel the size of the onboard output buffer of the device"

 

I might be missing something glaring obvious but I am struggling to work out the difference.

 

Your help is greatly appreciated Smiley Happy

 

 

David
www.controlsoftwaresolutions.com
0 Kudos
Message 3 of 5
(4,451 Views)
Solution
Accepted by topic author DavidMaidman

OnbrdBufSize - is the fast memory every DAQ card has to store the acquired data. It's like RAM in the PC. For example here you find that the NI PCI 6120 has 128MB of this memory which will equal to some amount of samples the buffer can store (this number you will read). This said it also explains why you can read and not set this property.

Output.BufSize - Before you start data acquisition software buffer is defined based on the task you perform. I think it just allocates part of the fast memory of the DAQ card. The reason why the buffer is set (either by the user or automatically) is to have defined memory space for each task. Imagine you have more tasks using the card and each of them needs some memory of the card - if I am wrong correct me somebody.

If your acquisition is finite (sample mode on the Timing function/VI set to Finite Samples), NI-DAQmx allocates a buffer equal in size to the value of the samples per channel attribute/property. For example, if you specify samples per channel of 1,000 samples and your application uses two channels, the buffer size would be 2,000 samples. Thus, the buffer is exactly big enough to hold all the samples you want to acquire.

If the acquisition is continuous (sample mode on the Timing function/VI set to Continuous Samples), NI-DAQmx allocates a buffer equal in size to the value of the samples per channel attribute/property, unless that value is less than the value listed in the following table. If the value of the samples per channel attribute/property is less than the value in the table, NI-DAQmx uses the value in the table.

Sample Rate Buffer Size
No rate specified 10 kS
0–100 S/s 1 kS
100–10,000 S/s 10 kS
10,000–1,000,000 S/s 100 kS
>1,000,000 S/s 1 MS

LV 2011, Win7
Message 4 of 5
(4,441 Views)

Hi Ceties,

 

thanks for the explanation, it all makes sense now. Efficatively OnbrdBufSize is the maximum allowabale buffer size and Output.BufSize is the configured buffer size for your task.

 

The Output.OnbrdBufSize property is read/write and the context help implies you can set this, which doesn't help understanding (it is the Input.OnbrdBufSize property that is read only)

 

Thanks once again

 

David
www.controlsoftwaresolutions.com
0 Kudos
Message 5 of 5
(4,430 Views)