Quantcast
Channel: LabWindows/CVI topics
Viewing all articles
Browse latest Browse all 5362

DAQmxRegisterEveryNSamplesEvent with DAQmxWriteAnalogF64 and memory growth/leak

$
0
0

Hello,

 

I am using

DAQmxRegisterEveryNSamplesEvent

to register a callback function to produce and write analogue output data for a NI PCI 6221 which is resulting in memory growth/leak of around 6MB per hour.

If I do not register a callback function and instead use 

DAQmxSetWriteRegenMode(taskHandle, DAQmx_Val_AllowRegen  ); 

to repeat the initial buffer then I do not see any growth in memory usage.

 

After experimenting with the contents of the callback function it appears that the growth is due to the function

DAQmxWriteAnalogF64(taskHandle,nSamps,FALSE,10.0, DAQmx_Val_GroupByScanNumber ,dataArray,NULL,NULL);

Is this expected behaviour or should I be able to use write data to the device in this manner without experiencing increasing memory usage?

 

Thanks


Viewing all articles
Browse latest Browse all 5362

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>