I am trying to interface my laptop with a DAQ card. There's a dll file to which a sample c code (provided by the manufacturer) can communicate. The manufacturer's sample executable (generated from that same c code) runs fine. I intend to make modifications to c code so that I can make it write the data from my DAQ card to a file of my choice. But, as a first step, I tried to compile the existing c code (without modifications) in wxDev-C++. But I am getting a build error. I know for sure that this cannot be the result of something being wrong in the actual code since the c code is directly from the manufacturer. I think the problem is with the way I am compiling this code.
Anyways, here is what I get in the compile log:
Code: Select all
Compiler: Default GCC compiler
Building Makefile: "C:\Users\...\Trial Compile\Makefile.win"
Executing make clean
del /Q "Objects\MingW\AD7760_sample_code.o" "Objects\MingW\ADI_CED1_dll.o" "Output\MingW\first_attempt.exe"
C:\Users\...\Trial Compile\Output\MingW\first_attempt.exe
Access is denied.
g++.exe -c AD7760_sample_code.c -o Objects/MingW/AD7760_sample_code.o -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/" -I"C:/Program Files (x86)/Dev-Cpp/include/common" -D__WXMSW__ -D__GNUWIN32__ -D_UNICODE
g++.exe -c ADI_CED1_dll.c -o Objects/MingW/ADI_CED1_dll.o -I"C:/Program Files (x86)/Dev-Cpp/MinGW32/include" -I"C:/Program Files (x86)/Dev-Cpp/" -I"C:/Program Files (x86)/Dev-Cpp/include/common" -D__WXMSW__ -D__GNUWIN32__ -D_UNICODE
g++.exe "Objects/MingW/AD7760_sample_code.o" "Objects/MingW/ADI_CED1_dll.o" -o "Output/MingW/first_attempt.exe" -L"C:/Program Files (x86)/Dev-Cpp/lib/wx/gcc_lib" -L"C:/Program Files (x86)/Dev-Cpp/lib" -L"C:/Program Files (x86)/Dev-Cpp/MinGW32/lib" -mwindows -lwxmsw29u -lwxmsw29u_gl -lwxscintilla -lwxtiff -lwxjpeg -lwxpng -lwxzlib -lwxregexu -lwxexpat -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32 -lodbc32 -lopengl32
c:/program files (x86)/dev-cpp/mingw32/bin/../lib/gcc/mingw32/4.6.1/../../../../mingw32/bin/ld.exe: cannot open output file Output/MingW/first_attempt.exe: Permission denied
collect2: ld returned 1 exit status
mingw32-make.exe: *** [Output/MingW/first_attempt.exe] Error 1
Execution terminated
Compilation Failed. Make returned 2
Thanks.
tdeshp