Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How to swap hardware when using DAQ assistant?

My colleagues and I have several VIs that get used with more than one fixture and so they have different DAQs on each fixture. Right now we just make sure that the DAQ has the same name in each DAQmx and everything works well enough. Most of our programs use the DAQ assistant. 

 

Now we're trying to downsize the number of computers we are supporting and allow multiple fixtures to be plugged in to the same computer. This means we have the case where Fixture 1 with DAQ 1 and Fixture 2 with DAQ 2 are both using the same program. This is not running the program at the same time, rather each fixture will be plugged in one at a time. What I want to do is make it so I can swap hardware and handle any program changes in software without having to have the user mess with DAQmx. What is the easiest way to do this? Looking through the forums it looks like we need to move away from the DAQ assistant, is there an easy way to do this?

0 Kudos
Message 1 of 4
(3,010 Views)

First stab...try to use the DAQmx System Property Node to get a list of all the devices in the system, then use a DAQmx Device Property Node to figure out what type of device it is and then run whichever DAQ Assistant program (you can make it into a subVI) you want for that type of board.

 

Does that help accomplish what you want to do?

 

-gaving

0 Kudos
Message 2 of 4
(2,989 Views)

This is the solution I came up with... First find the name of the connected device:

1Find_First_DAQ_Named.png

 

Then use that name and convert the express to code and modify that to accept the name that is found in the first vi:

 

DAQ_Independent_MUX_Driver.png

 

The limitation is that the first listed daq is the one used so there is less control. But this does seem to accomplish what I needed. Thanks for the ideas gaving

0 Kudos
Message 3 of 4
(2,975 Views)

An elegant solution!! Well done!!

 

Just to follow up on your "limitation", you could add an "OR" to your while loop stop condition and add other logic...like based off of "product type" or even "serial number".  (you could pass in the serial number you expect to your subVI)

 

Anyway, just a few ideas.  Good luck!

 

-gaving

 

0 Kudos
Message 4 of 4
(2,973 Views)