Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I replicate what MAX program does to initialize a DAQ device

I am building applications using NIDAQ and C++.
I frequently change the device using either a PCI-6040 or a DAQ-Pad.
Whenever I change the device, my application gives me a -10401 (unknown device) status error the first time I run it.
I can run the NI MAX program without error, and after that, my application runs without error, even if I shutdown and restart (as long as I don't change devices).
What is the MAX program doing and can I replicate it in my application?
Thanks for any hints?
Gordon
0 Kudos
Message 1 of 2
(3,010 Views)
Gordon,

With Traditional (Legacy) NI-DAQ driver device numbers are assigned when MAX starts; however there is a method of assigning these device numbers using a stand-alone utility.  More information about the utility is located in the following KB:

KnowledgeBase 3IABNTT
Y: Is it possible to Setup an NI DAQ Board Without Launching Measurement and Automation Explorer (MA...

If you have further questions about using this utility feel free to post back to this thread.  Good luck with your application.

Regards,

Neil Stoddard
Applications Engineer
National Instruments
0 Kudos
Message 2 of 2
(2,996 Views)