Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Multi Task DAQmx

I am trying to develop an application for completing multiple measurements and measurement types with a DAQcaed 6024-E multifunction DAQ.

How can I run multiple tasks in DAQmx to accomplish multiple measurement types at once.

The tasks I need to complete are:

1) A single counter input to measure rising edges.
2) Two analog inputs so that i can measure the phase shift between two signals.


I have been able to  develop individual VIs that can complete the individuals tasks. How can i run these tasks in parallel?



Thank you -

Sean


0 Kudos
Message 1 of 4
(3,941 Views)
Are you programming in labview? if so, you can place each task in their own loop which will force the application to multithreading.  You should look at queues and synchronized functions to allow for interthread communication (simple communications can be done with local variables.
 
Paul
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 2 of 4
(3,918 Views)
If you just want the tasks to run at the same time I don't think you need to worry about two loops, queues, multithreading, etc.  Look at the example :
..\DAQmx\Synchronization\Multi-Function.llb\Multi-function-Synch Ai-Read Dig chan.  It shows an example of how you might do 2 tasks.  You can replace the digital input task with your counter task.  You don't have to use the ai/sample clock for the counter task if you don't want them synchronized.  Then just put 2 reads inside your loop.  If you want to read 2 AI channels and they are both of the same type just specify both channels in your physical channel list.  If you want them to be separate then just do another create task and do a separate read in the loop.
 
StuartG
0 Kudos
Message 3 of 4
(3,903 Views)
thank you! That helped greatly.

SeanB
0 Kudos
Message 4 of 4
(3,873 Views)