Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

"Assign DAQ device name at run time"

Hello,
 
I am currently working on creation of API for a DAQ M 6251 device and would like to know whether there is a possibility to assign the device name for the DAQ card at run time through program instead of MAX (Measurement and Automation Explorer). Here I use Labwindows/CVI 8.5 version for programming the DAQ device.
 
Regards
Sreekantha S
0 Kudos
Message 1 of 2
(2,924 Views)
Hi Sreekantha S,

One way to do this programmatically is to export the NI-DAQmx configuration into an INI file, modify the INI file, and import the configuration from the INI file.

The NIMAX_CopyConfiguration() function is in nimaxconfig.h, which gets installed if you select NI Measurement & Automation Explorer >> LabWindows/CVI Support when you are installing NI-DAQmx. Something like NIMAX_CopyConfiguration("system://localhost", "file:///C:\Data\nimaxconfig.ini", "DAQmx", NIMAX_ReplaceDst) should export your NI-DAQmx configuration, and the reverse should import it. I don't have CVI installed on this PC, but I verified that the equivalent function in LabVIEW does what I expected.

There may be a more direct way that I'm not aware of.

Brad


Message Edited by Brad K on 04-25-2008 01:00 PM
---
Brad Keryan
NI R&D
0 Kudos
Message 2 of 2
(2,907 Views)