Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

Need to output 8 channels using double buffer

Hi,
I need to ouput 8 channels to the DAQ card.
I am getting an array 8 bytes of data every 10 milliseconds.
Each byte corresponds to a channel.

I am using your WFMDoubleBuffer.c code.

The changes I have made are :

1. Changed the buffer from 32K to 16 bytes. I am assuming 8 bytes with double buffer = 16 bytes

2. I'm not sure about updateRate, so I set it to 1.0

Result : I get an error from WFM_Group_Control(). It says "The operation could not complete within the time limit", error = -10800

I have attached the file for your reference.

Please help me.


Thanking you in anticipation

Chandra
0 Kudos
Message 1 of 2
(2,839 Views)
Chandra,

The timeout error here is slightly misleading. The reason this is happening is caused by a few things. By default, the card to setup to transfer data when the onboard FIFO is full, and so your half buffer must be the same size or large than your FIFO unless you have regeneration turned on. Regeneration will cause your buffer to be copied as many times as possible into the FIFO until it is full. Your 6713 has an AO FIFO size of 16,384. So your buffer size must be twice this, so that your half buffer is >= 16384. Where is your data coming from at these 10 ms intervals, from a program or another device? This could affect what method would be the best solution.

If you want to keep working on this, let�s stick to one channel, I sent you an email, did you get
it?

Kevin R
Applications Engineer
National Instruments
0 Kudos
Message 2 of 2
(2,839 Views)