After trying to buil in Microsoft Visual c++ Express the spatial-simple project included in the phidget sample programs, I get the a bunch of errors like this one:
I Spatial-simple.obj : error LNK2019: unresolved external symbol __imp__CPhidget_getSerialNumber@8 referenced in function _AttachHandler@8
I followed the settings in the Getting started with Phidgets in Microsoft Visual Studio C\C++
someone else had this problem as well, so I just went to look and I am getting the same errors. there appears to be a problem with the 64 bit phidget21.lib. If you are running a 64 bit machine (guessing that you are), if you go into Project->Properties->Linker->Input and change the Additional Dependencies entry to
"$(SystemDrive)\Program Files\Phidgets\x86\phidget21.lib"
...
this will reference the x86 library file instead. You can use this as a temporary fix until we solve the x64 library issue.
In the Phidgets getting started manual is not specified the directory changes when you install windows ins spanish. The directory is called Archivos de Programa instead of program files.
However, after solving that, I am still getting un error. fatal error C1083: Cannot open include file: 'phidget21.h': No such file or directory
Even if I include that file in the header file I get the same error. I dont know if it should be included somehow in the external dependencies, in the source files, in the headers or anyware else. I included the 'phidget21.h' file in the header, and after in the source file, but I am getting the same error still...
Open the project properties window and navigate to Configuration Properties → C/C++. Add "$(SystemDrive)\Program Files\Phidgets" to the additional directories field, or which ever directory you install the Phidgets driver to.
You will need to change some project settings in order to accommodate x64 libraries.
When in visual studio, in the top middle click on the Win32 drop-down menu and select the configuration manager. Find the active project and under the platform option, select New... (if it appears select x64 instead. Then you are done) In the new pane that appears under the "New Platform" option select x64. Click Ok. You should now be able to use the 64 bit .lib file.
for anyone else having this issue, if the x64 option doesn't show up in the configuration manager, it is because Visual Studio will by default not install the C++ x64 compiler tools. To fix this, you need to go into your Windows Programs and Features, click Unintsall/Change on Visual Studio 2005, and select the Modify/Add Features option. Then under the C/C++ list, check the box next to the x64 option, and click Next. Finish the installation and the x64 option will now be available for C/C++.