LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

NI-DAQmx Configure Frequency and Analog Input Measurement

How do you use the NI-DAQmx functions to configure a task to have both analog input and frequency and thermocouple measurements?  Do you run separate tasks in parallel, or do you configure a single task ID using a sequence to call the appropriate versions of the polymorphic task configuration VI's?
 
Thanks
0 Kudos
Message 1 of 3
(2,869 Views)
I've had a similar task to this in that I wanted to synchronise a read and write task. How I did it was to set up each function as a seperate task, bind them both to use the same sample clock. Place the tasks in a read state, then start the clock. The tasks are then perfectly synchronised.

I've attached a vi that I hope shows you what I mean.

If you've got a more advanced DAQ than I'm using (6221) then I'd recommend looking at features such as edge detection for the triggering and sychronisation of tasks - and there appears to be alot of other ways of doing it.

good luck

Message Edited by davidpcl on 04-25-2006 05:49 AM

David Clark
CLA | CTA
Genesee Technologies Ltd
Hampshire, England
0 Kudos
Message 2 of 3
(2,867 Views)
Thank you for contacting National Instruments!
 
You are not going to be able to run multiple tasks in parallel, if all of the tasks are analog input.  You can do this task "paralleling" with one task being analog input and one task being analog output; however, not with multiple analog inputs.  The easiest way to do this is to use the DAQ Assistant.  You can configure one channel first, and then from the DAQ Assistant Set-up Window, you can select to "Add Channel".  You can then add a frequency channel, a resistance channel, thermocouple, etc.  Once the DAQ Assistant builds, you can right-click on the VI on the block diagram and choose to "Generate NI-DAQmx code".  This will create a configuration sub-VI that will show you the exact methodology of performing this.
 
-Jeff P.
Message 3 of 3
(2,847 Views)