03-07-2012 08:36 PM
G'day,
I'm writing an applciation that will interface with NI USB-60xx hardware via the NIDAQmx Base API. I've got the latest version 3.5 and I can run the precompiled exampleswithout any issues. However, if I compile and run the example source code I get a heap of runtime warnings (see attachement) about missing objects for .cpp files. Some of these objects are expected to be in Labview folders.
Why have I got errors for C++ files when I compiling C? Why are these errors looking in the home directlroy for a user called /lvbuild (I have no such user)? Why should I require objects not provided in the NIDAQmx Base package to use it?
The attatchment is the list of runtime warnings after compiling the 'contAcquireNChan.c' example source file.
I am compilling with the frameworks nidaqmxbase, nidaqmxbaselv.
I am compiling under OSX 10.7.
Thanks for any help,
Lee.
03-08-2012 09:13 AM
Hello Tangle,
Thanks for letting us know about this. I just tried again and lucky for me, I can't reproduce the behavior that you are seeing. Here is what I did to try to reproduce the problem.
1. Reimage to a clean 10.7 system with Xcode installed.
2. Install NI-DAQmx Base 3.5 on the system. (reboot)
3. Navigate to "/Applications/National Instruments/NI-DAQmx Base/examles/ai" via the terminal
4. Type "make" and watch the examples build.
5. run "./contAcquireNChan" to run the example.
I received the usual samples from this example. I have a few questions for you to understand this better.
1. Is your kernel in 32-bit or 64-bit mode? (I've tested it on both in the past...just want to make sure)
2. Are you able to reproduce this issue with the process I listed above?
3. If not, what are you doing to reproduce the problem?
Thanks,
Steven T.
03-08-2012 08:26 PM
Steve,
Thank you for you reply.
I can't get back to a clean 10.7 install without loosing two days. However, I have followed your process starting at step 2.
When I make the files at the terminal (as you describe) I do not get the same runtime warnings.
I am using xCode to develop my application. I did trace these runtime warnings to adding the nidaqmxbase and nidaqmxbaselv frameworks to my xCode project. Even if I remove all my NIDAQmx Base function calls, just having those frameworks in the project (and linking to them) results in these warnings. If I remove the frameworks, the warnings disappear. However, I then tried to reproduce the warnings in a fresh xcode project, and could not. I went through and made sure that the compilers, compiler flags, etc all matched, but adding the frameworks did not cause runtime warnings in a fresh xcode project.
It must be some specific quirk in my application's project setup that for some reason is interacting with these frameworks in a strange way. When I have time to do so I will bring my source code across to a fresh project to see if I can identify what is triggering the warnings.
Thank you for your time. If you have any ideas, please let me know.
Lee.
P.S. I find it ammusing that you forum's spell checker does not know the words LabView or NIDAQ
03-09-2012 08:17 AM
Hello Tangle,
The idea that my colleague had is that xCode could be enabling some type of debug build of your project. I haven't used xCode, so I can't tell you exactly which setting it could be.
Funny, somehow NIDAQmx gets corrected to Indiana in the spell check!
Thanks for the details!
Steven T.
03-11-2012 10:56 PM
Steve,
I was using a debug build, but now have switched it off. It did not changed anything.
I I have since tried moving my source code into a new project and that removed the runtime warnings for the examples source code, most of the time. Now sometimes, maybe 1 in 5 times that I run, I get the same runtime warnings at the end of the task (previously they occured when the sampling task started).
Thanks
Lee.