ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

multiple DAQ cards

Ed,

Due to some massive oversights on my part, I realized that I'd better output any NIDaq exceptions instead of ignoring them.  What I found is that I am getting the samples no longer available exception when just aquiring 4 cards with 10 channels at 100000 S/s.  I get the same error when recording 4 cards x 64 chans x 15625 S/s.  So I guess the first thing I need to do is figure out how to aquire 4 cards x 10 chans x 100000 S/s?   Sorry I didn't catch this earlier.

thanks for all the help
Download All
0 Kudos
Message 11 of 13
(1,168 Views)

Hi Mike,

 

This error can be avoided by doing just as the message says – increase your buffer size.  A good guideline to follow is to create a buffer size that is 10% (in bytes) of your channel count times your sample rate (in Hz).

 

buffer size B = 0.1 x  (# channels) x (sample rate Hz)

 

So if on each 6071E, you’re sampling at 10,000Hz on 10 channels, use a buffer size of 10,000 B for each device.

 

Best regards,

 

Ed W.

Applications Engineer
National Instruments

0 Kudos
Message 12 of 13
(1,160 Views)
Ed,

I was having trouble understanding how to increase the "buffer", because I wasn't aware that I could increase the buffer size since I was doing a continuous aquisition.  But I found the documentation that told me how to do just that using Task->Stream->Buffer->set_InputBufferSize( int ).  However I found that in order to get things to run smoothly for the case where I had 4 cards with 10 chans per card running at 100,000 S/s I had to set my buffers to 1,000,000.  It seems that for all the combinations of chans*rate that = 1 M S/s the size of the buffer can use the defaults for rates < 31250 S/s but above that I found that the buffer size would have to be around 10 times the sampling rate.  At this point
the CPU still is running at 100% but I am able to aquire with no exceptions and also record the data to the disk.  Hopefully I have not overlooked anything and this will be the end of this thread!

Thanks for the help


0 Kudos
Message 13 of 13
(1,143 Views)