Hi
I am working on a project with PS2206B.
The OS is Win10 pro. Compiled with MSVC, the example ps2000aCon.c runs fine.
Compiled with mingw-w64, using ps2000a 64-bit library (I have to fix warnings on "scanf_s" and "fscanf_s" first):
gcc ps2000aCon.c -o ps.exe -L. -lps2000a
I get many errors like these:
undefined reference to `_imp__ps2000aCloseUnit@4'
undefined reference to `_imp__ps2000aSetEts@20'
Then I compile with MinGW_64, using ps2000a 32-bit library. The compilation goes fine and I can run the ps.exe program, but it won't work:
> ./ps
PicoScope 2000 Series (A API) Driver Example Program
Version 2.3
Opening the device...
Handle: -1
Unable to open device
Error code : 78
Hi Martyn
Thank you for answer.
mingw-w64 does not "understand" 64-bit MSVC library files, so I have focused on 32-bit SDK. I have tried with both 32bit and 64bit SDK's installed, one by one, not simultanuous.
Command line: gcc ps2000aCon.c -o ps.exe -L. -lps2000a (With 32-bit lib2000a.lib in directory ".")
MSVC compilation work for 64bit CPU type. I have not tested 32bit.