Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

Errors on OSIBUS when compiling

Hi,
    I am developing device drivers for PXI system for VxWorks. I got the nimhddk_visa_windows_bus_interface.zip  and aswellas the example code(mseries.zip)  for NI PXI 6259. I tried to compile on TURBOC and also in Microsoft VC++ compiler on WINDOWS, I am getting follwing errors on OSIBUS.H header file. Has any one else tried using it? Can I use the same osiusercode.cpp for building my ibus(acquireBoard and release board) interface since it uses VISA which is a OS independent header on vxworks also? If any one has any idea let me know
 
S.Harikumar 


 
0 Kudos
Message 1 of 4
(8,709 Views)
Hi,

Most of the errors seem related to the osiTypes.h file.  This is where all the data types for the rest of the DDK are defined.  Try compiling a little application that uses this file and try to use the data types it defines. 

Also, the osiTypes.h file depends on osiPlatform.h, which is defines macros the rest of the source can use for conditional compilation.  At the moment VxWorks is not defined in there, so you should add it.  Basically, the first part of the file tries to define OS and CPU macros based on compiler pre-define macros.  Then, using these macros it defines others that the code can use (endianness, export qualifiers, ...).  If it gets to complicated, just delete everything and define the macros that apply to your platform.

You should be able to use the VISA osinterface in VxWorks.  I haven't don't it personally, but as far as I know VxWorks uses the gcc toolchain, so build for VxWorks should be similar to linux.  You have to create a .mak file for VxWorks the defines the VxWorks specific build commands.

Can you post the files you are trying to compile?
Diego
0 Kudos
Message 2 of 4
(8,633 Views)

Hi,
      The files I included in the project are ai.cpp, aiex1.cpp, common.cpp main.cpp and scale.cpp of the following attached file. I am also getting the following errors when i am tried to bulid a driver file completly using nivisa only and i got the following errors, i cross checked with your osiuser code.cpp i am getting the error. The nivisa.obj plz do comment on this also. I'l check your comments and give you a feedback.

S.Harikumar

partialImage.o: In function `visaCloseVXIlibrary':
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gInByte'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gInWord'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gInLong'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gOutByte'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gOutWord'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gOutLong'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciFindC
lass'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciFindD
evice'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciConfi
gLibInit'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciIntCo
nnect'
D:\Tornado\target\proj\Project7\default\src\nivxi.c:64: undefined reference to `pciIntDi
sconnect'
make: *** [vxWorks] Error 0x1

2/4/1998 10.18 size 766kb

0 Kudos
Message 3 of 4
(8,614 Views)
I have attached the example file i tried compiling .
0 Kudos
Message 4 of 4
(8,611 Views)