LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

HELP~~~URGENT! what's the difference between hardware-timed acquisition and continuous acquisition in NI DAQ

I am very confused about this question. I use the traditional DAQ to acquire data by using continuous mode without buffer. Please see the printscreen below, AIconfig.PNG is the AI config in the file and readdata.PNG is the start task and read data in the loop. The main purpose of the loop is to collect data and control the application real-time. I have 11 channels in the task. The sampling rate is 10000HZ. The interchannel delay is 6E-6 s. It is acquired data in continuous mode with the buffer set as 0. 

 

Another case is I use the hardware-timed acquisition in DAQmx with same sampling rate. Data are collected in a timed-loop. 

My question is what is the difference between this configuration and the case that I use  the hardware-timed acquisition? For me, in traditional DAQ, the continuous mode without buffer is same with the hardware-timed acquisition in DAQMX. Is it correct? Or hardware-timed acquisition in DAQMX can syncronize the control loop in real-time. But the continuous mode without buffer will lose the syncronization for the real-time control. Who can advise me?

 

Furthermore, the interchannel delay in traditional DAQ is like the AIconv.Rate in the DAQmx Timing. I set interchannel delay as 6E-6. It's ok to run the program successfully. But in hardware-timed mode in DAQmx, I have to increase the AIconv.Rate to be 222222.2Hz. It is converted to the interchannel delay is 4.5E-6.  If I run the AIconv.Rate to be 166666Hz, the software operation cannot keep up with the hardware timing. An error message will be displayed. Why? It's really confusing me. So what's the difference between them.

 

 

 

Many thank~~~~.

 

 

Regards!

Zhao

 

Download All
0 Kudos
Message 1 of 3
(2,633 Views)

If you rephrase your question a bit simpler you might get more help. There's a lot to digest for what seems to be a simple question.

 

Typically, with Continuous Acquisition, data is available at the speed you setup with Sample Clock vi (or the equivalent property node). You have to be careful how fast you read the data; for example, you don't want to read data before it is available, or read it in loop which runs the buffer dry.

 

Hardware based acquisition does not use a buffer, and is expecting to use a change detection or hardware finger of some type as the acquire trigger. Again, you have to be even more careful to not read data that isn't there.

Richard






0 Kudos
Message 2 of 3
(2,533 Views)

What does the end that is generating the data look like?  Is it like a transducer that changes its value asynchronously?  Is it like a synchronous output that sends a value at specific time intervals.  This makes a difference in how to acquire the data.

 

If asynchronous, you need to poll continously to read the data (continuous acquisition).  Your sample rate should be at least twice as fast  as the generating hardware can change the value.  A timed loop can be used with the timer set to your ideal sample rate.  Use a queue to store the data and process it in a separate loop (producer-consumer architecture).  Be careful that you don't fill up your memory by not processing fast enough.

 

 For synchronous outputs, you should have some sort of clock signal to trigger your AI aquisition (hardware timed acquisition).  To do this, you must set up a hardware trigger to act on the clock edge.  A normal while loop works here.  The AI won't execute until it sees the trigger.  So the loop will run once with each trigger.

 

I hope this helps.

 

- tbob

Inventor of the WORM Global
0 Kudos
Message 3 of 3
(2,477 Views)