vme.h
上传用户:luoyougen
上传日期:2008-05-12
资源大小:23136k
文件大小:2k
源码类别:

VxWorks

开发平台:

C/C++

  1. /* vme.h - VMEbus constants header file */
  2. /* Copyright 1984-1992 Wind River Systems, Inc. */
  3. /*
  4. modification history
  5. --------------------
  6. 02d,06sep01,rcs  added VME_AM_CSR SPR# 7243
  7. 02c,10feb99,tm   added documentation about number 0x40 and above
  8. 02b,22sep92,rrr  added support for c++
  9. 02a,04jul92,jcf  cleaned up.
  10. 01g,26may92,rrr  the tree shuffle
  11. 01f,13jan92,ccc  fixed VME_AM_IS_XXX macro for 16 and 24 bit AM's.
  12. 01e,04oct91,rrr  passed through the ansification filter
  13.   -changed copyright notice
  14. 01d,05oct90,shl  added copyright notice.
  15.                  made #endif ANSI style.
  16. 01c,04may90,gae  added VME_AM_IS_XXX test macros for 16, 24, & 32 bit AM's.
  17. 01b,08nov89,shl  added ifdef to prevent inclusion of vxWorks.h more than once.
  18. 01a,02jun87,dnw  written.
  19. */
  20. /*
  21. DESCRIPTION
  22. This file contains address space descriptor definitions for the VME bus. 
  23. Note that address space descriptors above 0x3f have already been assigned
  24. to other busses, and additional address space descriptors should be 
  25. added only after consulting the appropriate header files and allocating
  26. the next available descriptor.
  27. */
  28. #ifndef __INCvmeh
  29. #define __INCvmeh
  30. #ifdef __cplusplus
  31. extern "C" {
  32. #endif
  33. /* address modifier codes */
  34. #define VME_AM_STD_SUP_ASCENDING 0x3f
  35. #define VME_AM_STD_SUP_PGM 0x3e
  36. #define VME_AM_STD_SUP_DATA 0x3d
  37. #define VME_AM_STD_USR_ASCENDING 0x3b
  38. #define VME_AM_STD_USR_PGM 0x3a
  39. #define VME_AM_STD_USR_DATA 0x39
  40. #define VME_AM_CSR 0x2f
  41. #define VME_AM_SUP_SHORT_IO 0x2d
  42. #define VME_AM_USR_SHORT_IO 0x29
  43. #define VME_AM_EXT_SUP_ASCENDING 0x0f
  44. #define VME_AM_EXT_SUP_PGM 0x0e
  45. #define VME_AM_EXT_SUP_DATA 0x0d
  46. #define VME_AM_EXT_USR_ASCENDING 0x0b
  47. #define VME_AM_EXT_USR_PGM 0x0a
  48. #define VME_AM_EXT_USR_DATA 0x09
  49. #define VME_AM_IS_SHORT(addr) ((addr & 0xf0) == 0x20)
  50. #define VME_AM_IS_STD(addr) ((addr & 0xf0) == 0x30)
  51. #define VME_AM_IS_EXT(addr) ((addr & 0xf0) == 0x00)
  52. #ifdef __cplusplus
  53. }
  54. #endif
  55. #endif /* __INCvmeh */