Academic Company Events Community Support Solutions Products & Services Contact NI MyNI
This Document is not yet Rated

DAQmx Base C Examples Do Not Compile After Copying to New Directory

Primary Software: Driver Software>>NI-DAQmx Base
Primary Software Version: 1.0
Primary Software Fixed Version: N/A
Secondary Software: N/A

I have copied the DAQmx Base C examples on my computer to a new location on disk. After doing so, I get errors regarding the NIDAQmxBase.h file when I try to compile. The original examples in the install location (<DAQmxBase Install Directory>/examples/) continue to build without problems.  What do I need to change for the DAQmx Base files in the new location to compile?

The Makefile in each subsystem example directory contains an includes flag that tells the compiler where to find the NIDAQmxBase.h header file.  For DAQmx Base this include flag is a relative path.  Changing the location of the Makefile and the examples resulted in the wrong directory being used for finding the NIDAQmx Base.h header file.

To modify the Makefile to search the correct location, find the absolute path of the header file.  The default absolute path is /usr/local/natinst/nidaqmxbase/include on Linux and /Applications/National Instruments/NI-DAQmx Base/include on Mac.

After finding the absolute path of the header file, change -I../../include in the Makefile to -I<absolute path to header>.

Related Links:
Products and Services: NI-DAQmx Base Software
White Paper: Technical Assistance for Linux and National Instruments Products
National Instruments and Mac OS X -- Frequently Asked Questions
KnowledgeBase 3BC6I9GP: Where Can I Find NI-DAQmx Base Examples?
KnowledgeBase 38R99NRF: What is the  NI-DAQmx Base Driver for Pocket PC?
KnowledgeBase 3739LUHU: No Analog Output Examples Work in NI-DAQmx Base for Pocket PC


Report Date: 02/24/2012
Last Updated: 05/20/2016
Document ID: 5UNB1U5A

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit