Forum for discussing PicoScope (version 5)
surf3rb0y
User
Posts: 8 Joined: Mon Nov 21, 2005 6:52 pm
Contact:
Post
by surf3rb0y » Mon Nov 21, 2005 6:57 pm
compile errors include the following.
Im using visual studio 6.0 to compile.
-------------------Configuration: ps3000 - Win32 Debug--------------------
Linking...
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_close_unit@4
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_set_siggen@32
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_get_times_and_values@36
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_stop@4
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_ready@4
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_run_block@20
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_get_timebase@28
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_set_ets@16
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_set_trigger@24
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_set_channel@20
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_get_unit_info@16
ps3000.obj : error LNK2001: unresolved external symbol __imp__ps3000_open_unit@0
LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
Debug/ps3000.exe : fatal error LNK1120: 13 unresolved externals
Error executing link.exe.
ps3000.exe - 14 error(s), 0 warning(s)
Not sure why have tryed reinstalling and compiling with new files but no luck.
Thanks in advance for any help you can offer.
Tyler
Sarah
Post
by Sarah » Tue Nov 22, 2005 1:14 pm
Hi Tyler
It looks as though it is not finding the .lib file. Have you included the ps3000.lib file in the resources?
Best Regards
surf3rb0y
User
Posts: 8 Joined: Mon Nov 21, 2005 6:52 pm
Contact:
Post
by surf3rb0y » Tue Nov 22, 2005 4:49 pm
Thanks for the reply Sarah,
not sure how to add that file
Tried to just put an #include "ps3000.lib" in the ps3000.c file but that resulted in more errors. Thanks for any help you can offer.
Tyler
Sarah
Post
by Sarah » Wed Nov 23, 2005 1:26 pm
Hi Tyler
The file needs to be added in the solution explorer under the resources section - it does not need to be referenced in the code.
Also make sure you have the header file also in the solution explorer.
Best Regards
surf3rb0y
User
Posts: 8 Joined: Mon Nov 21, 2005 6:52 pm
Contact:
Post
by surf3rb0y » Mon Nov 28, 2005 3:45 pm
Thanks for the help that fixed all but 2 of my errors. now i get the following
"--------------------Configuration: ps3000 - Win32 Debug--------------------
Linking...
LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
Debug/ps3000.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
ps3000.exe - 2 error(s), 0 warning(s)"
ive tried to iinclude other files that i thought might be missing but didn't help at all.
Thanks
surf3rb0y
User
Posts: 8 Joined: Mon Nov 21, 2005 6:52 pm
Contact:
Post
by surf3rb0y » Mon Dec 12, 2005 5:18 pm
I found the answer to my previous question. the program was being compiled as a consol app and not a windows app. I believe that this only affects visual studio 6 but could be experienced in other versions as well the solution can be found here. http://support.microsoft.com/?scid=kb;e ... 42&sid=220
Thanks for all the help.
Tyler