/* ILC Data Device Corp. * * MIL-STD-1553 Simulator/Tester * 'C' Software Library * * BUS-69068 rel 2.00 * * Copyright (c) 1997 by ILC Data Device Corp. * All Rights Reserved. * * TS_drv.h (Main include module) * * This is the master header file for the Tester/Simulator Library. It contains compiler * directives used throughout the library. It makes the necessary defines for * the dynamic link library compilation and use. In addition, macros are * defined for standard data types and dynamic memory allocation to make * the Tester/Simulator library transportable. * * NOTE: Any changes to this file will require re-compilation of the * Tester/Simulator Library for the changes to take effect. * * ILC Data Device Corp. * 105 Wilbur Place * Bohemia N.Y. 11716 * (516) 567-5600 * * Revision History for TS_drv.h (HEADER FILE) * * Release Date Description * * 1.0 01-DEC-1997 initial release * 2.00 21-DEC-1998 * 4.1.1 04-SEP-2001 Updated Linux support */ #ifndef TS_DRV_H #define TS_DRV_H #include #include #include #ifdef _WIN32 #ifndef LABWINDOWS_CVI #include #endif #endif /* _WIN32 */ #ifdef DOS #include #endif /* DOS */ /* Determine if we are running Windows, if so define include file */ #if defined( _WINDOWS ) || defined( _WIN32 ) #define _UseWindows 1 #endif /* If we are compiling on Linux, define our local directive. */ #ifdef linux #ifndef LINUX #define LINUX #endif #endif /* linux */ /* If we are compiling on VXWorks, include the appropriate headers. */ #ifdef VX_WORKS #include #include "semlib.h" #endif /* VX_WORKS */ #include "typedef.h" #ifdef _UseWindows #include #else #ifndef LINUX typedef const void* HANDLE; #endif /* LINUX */ //typedef void* LPVOID; #endif /* library is written in 'C' */ #ifdef __cplusplus extern "C" { #endif /* If compiling a dll then define __IMPORTDLL__ */ /* added _DLL for MSC WIN32 compatability */ #ifdef _WIN32 /* Function calling convention */ #define __DECL WINAPI #define far /* To NULL */ #elif defined( LINUX ) #define __DECL #define __stdcall /* To NULL */ #define far /* To NULL */ #define interrupt /* To NULL */ #define OSVERSIONINFO struct utsname #elif defined( VX_WORKS ) #define __DECL /* To NULL */ #define __stdcall /* To NULL */ #define far /* To NULL */ #elif defined( DOS ) #define __DECL far pascal _export #define __stdcall /* To NULL */ #else #if defined(__DLL__) || defined(_DLL) || defined(_WINDLL) #define __IMPORTDLL__ #endif /* __IMPORTDLL__ creates exportable function declarations */ #ifdef __IMPORTDLL__ /* WIN16 DLL */ #define __DECL far pascal #else /* 16Bit application */ #ifdef __UseWindows #define __DECL #else #define __DECL far pascal _export #endif #endif #endif /* Memcpy is not reliable so we create our own */ #define _MemCpy(src,dest,size) \ {int i;for(i=0;i