From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Transferin program between PCs with/without DAQ drivers

Solved!
Go to solution

Hello guys,

 

I've been making a program with DAQmx elements on a test rig. Program surly can't run on a PC without DAQ drivers and/or NI HW.

But sometimes I want to upgrade those programs (with DAQmx elements) form my office or from my home, where I do not have NI HW or/and DAQ drivers.

 

I've been solving this issue with Diagram Disabe Structure, disabling every DAQmx element in my code. Sometimes its a pain in the ass, because I have to build or remove those Diagram Disabe Structures everytime I transfer the program from test rig to office or vice versa.

Is there any other elegant solution for this?

 

Best Regards,

Jakob

0 Kudos
Message 1 of 4
(1,846 Views)
Solution
Accepted by Jakob_Pin

Look at the conditional disable structure.

 

In your project file, you define a conditional symbol for that project.  (Project tree, right click the top line, select properties, look for Conditional Symbols.)  For example, you could name it "DAQ" and define it as DAQ = True or false.

 

In your code, you replace the regular diagram disable with the conditional diagram disable.  For the code you have with DAQmx functions, put it in the DAQ==True case, and in the other default case, just pass the wires through.

 

This way, you only need to change the value of the conditional symbol in the project tree once, rather than hunting down all the disable structures and flipping them.

Message 2 of 4
(1,810 Views)

FWIW, another option is to install the DAQ drivers on your dev machine even without any DAQ hardware present.  I frequently develop without hardware then deploy to a system with DAQ devices.

 

 

-Kevin P

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
0 Kudos
Message 3 of 4
(1,803 Views)

I do craploads of development without devices attached. Just install the DAQmx drivers (they're free) like Kevin said.

 

You can even create simulated DAQ devices in MAX to do some (limited) debugging without your hardware:

 

http://www.ni.com/tutorial/3698/en/

 

Note that analog devices will just return sine waves, digital data always "counts up", counter tasks return 0, etc. You can't actually simulate the data manually in real-time. The simulated devices WILL simulate timing though, which is great. To actually generate meaningful sample data, look into Hardware Abstraction Layers. It's a good bit of work to get going with a simulated DAQ data generator, so it might not be worth the effort, but it is doable. With this method, you could even dynamically load the classes at run-time. That way you would never even try to load the DAQ drivers, it would just load your simulated data generator (note: that's NOT the same thing as a simulated DAQ device in MAX.)

Message 4 of 4
(1,794 Views)