Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

nidaq32.lib & nidex32.lib

 Where can I get those files?

 I'm using Labview2010, but there are no nidaq32.lib and nidex32.lib in the dir.

 I found nidaq32b.lib and nidex32b.lib in the website. So I'm using these files instead them.

 I know that ~b i for bolland C++. But I'm using visual C++ 6.0.

 

 My problem is that I'm using the below codes that made 10 yrs ago. I'm modifying this batch file, but I keep having some errors.

 I don't know what caused the problem.

 

%%%%%%%Error Message%%%%%%%%%%%%%%%%%%%%%%%%

>> mex -f mex_nidaq.bat nidaq_read.c
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86
Copyright (C) Microsoft Corp 1984-1998. All rights reserved.
 
LINK : fatal error LNK1104: cannot open file "getValidInputLinkLibraries.obj"
 
  C:\PROGRA~1\MATLAB\R2010B\BIN\MEX.PL: Error: Link of 'nidaq_read.dll' failed.
 
??? Error using ==> mex at 208
Unable to complete successfully.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 

 

 

Batch file.

 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

set MATLAB=C:\Program Files\MATLAB\R2010b

rem not in original copy
set NI_DAQ=C:\Program Files\National Instruments\NI-DAQ

set MSVC_ROOT=c:\Program Files\Microsoft Visual Studio
set PATH=%MSVC_ROOT%\VC98\BIN;%MSVC_ROOT%\Common\MSDEV98\Bin;%PATH%

rem set INCLUDE=%MSVC_ROOT%\VC98\INCLUDE;%MSVC_ROOT%\VC98\MFC\INCLUDE;%MSVC_ROOT%\VC98\ATL\INCLUDE;C:\NI-DAQ\Include;%INCLUDE%;c:\Matlab6p5\extern\include
set INCLUDE=%MSVC_ROOT%\VC98\Include;%MSVC_ROOT%\VC98\MFC\Include;%MSVC_ROOT%\VC98\ATL\Include;%NI_DAQ%\DAQmx ANSI C Dev\lib\msvc;%MATLAB%\extern\include;%INCLUDE%

rem set LIB=%MSVC_ROOT%\VC98\LIB;%MSVC_ROOT%\VC98\MFC\LIB;C:\NI-DAQ\Lib;C:\MATLAB6p5\extern\lib\win32\microsoft\msvc60;%LIB%
set LIB=%MSVC_ROOT%\VC98\LIB;%MSVC_ROOT%\VC98\MFC\Lib;%NI_DAQ%\DAQmx ANSI C Dev\lib\msvc;%MATLAB%\extern\lib\win32\microsoft;%MATLAB%\extern\lib\win32\lcc;%LIB%


rem ********************************************************************
rem Compiler parameters
rem ********************************************************************
set COMPILER=cl
set COMPFLAGS=-c -Zp8 -G5 -W3 -DMATLAB_MEX_FILE
set OPTIMFLAGS=-O2
set DEBUGFLAGS=-Zi

rem ********************************************************************
rem Library creation command
rem ********************************************************************
set PRELINK_CMDS=lib /def:"%MATLAB%\extern\include\matlab.def" /machine:ix86 /OUT:%LIB_NAME%1.lib
set PRELINK_DLLS=lib /def:"%MATLAB%\extern\include\%DLL_NAME%.def" /machine:ix86 /OUT:%DLL_NAME%.lib 

rem ********************************************************************
rem Linker parameters
rem ********************************************************************
set LINKER=link
set LINKFLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib nidaq32b.lib

nidex32b.lib libmex.lib libmx.lib libmatlbmx.lib /nologo /subsystem:console /dll /incremental:yes /debug /machine:I386  /implib:"nidaq_init.lib" /pdbtype:sept

/libpath:"c:\NI-DAQ\lib" /libpath:"c:\matlab6p5\extern\lib\win32\microsoft\msvc60" /export:mexFunction
rem set LINKFLAGS=/dll /export:mexFunction %LIB_NAME%1.lib /implib:%LIB_NAME%l.lib /libpath:"c:\NI-DAQ\lib" /libpath:"c:\matlab6p5\extern\lib\win32\microsoft\msvc60"
set LINKOPTIMFLAGS=
set LINKDEBUGFLAGS=/debug
set LINK_FILE=nidaq32b.lib nidex32b.lib libmex.lib libmx.lib libmatlbmx.lib
set LINK_LIB=nidaq32b.lib nidex32b.lib libmex.lib libmx.lib libmatlbmx.lib
set NAME_OUTPUT=/out:%MEX_NAME%.dll

rem ********************************************************************
rem Resource compiler parameters
rem ********************************************************************
set RC_COMPILER=rc /fo mexversion.res
set RC_LINKER=

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 

 

0 Kudos
Message 1 of 2
(3,455 Views)

mazinga,

 

What you need is our Traditional NI-DAQ (Legacy) drivers. From the following page you can download the latest 7.4.4 version.

http://search.ni.com/nisearch/app/main/p/bot/no/ap/tech/lang/en/pg/1/sn/catnav:du,ssnav:sup/q/tradit...

 

When you run the setup.exe, in the features selection, choose to install the Microsoft Visual C Support. Now finish the installation. The DLLs you need will now be found in C:\Program Files\National Instruments\NI-DAQ\Lib. There is also a folder C:\Program Files\National Instruments\NI-DAQ\Includes if you find you need any .h files.

 

Regards,

Danny F

Danny Funk -- Senior Group Manager -- Software R&D -- NI
0 Kudos
Message 2 of 2
(3,447 Views)