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

VxWorks

开发平台:

C/C++

  1. /* ppc403Timerh.h - PPC 403 Timers header */
  2. /* Copyright 1984-2002, Wind River Systems, Inc. */
  3. /*
  4. modification history
  5. --------------------
  6. 01c,26apr02,dat  Adding cplusplus protection, SPR 75017
  7. 01b,19sep01,pch  Fix reversal of PIT and FIT in comments (for SPR 20698)
  8. 01a,23feb96,tam  created.
  9. */
  10. #ifndef __INCppc403Timerh
  11. #define __INCppc403Timerh
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15. /* defines */
  16. #define _PPC403_TSR_ENW 0x80000000 /* enable next watchdog mask */
  17. #define _PPC403_TSR_WIS 0x40000000 /* WDT interrupt status mask */
  18. #define _PPC403_TSR_WRS 0x30000000 /* watchdog reset status mask */
  19. #define _PPC403_TSR_PIS 0x08000000 /* PIT interrupt status mask */
  20. #define _PPC403_TSR_FIS 0x04000000 /* FIT interrupt status mask */
  21. #define _PPC403_TCR_WP 0xC0000000 /* watchdog period mask */
  22. #define _PPC403_TCR_WRC 0x30000000 /* wdog reset control mask */
  23. #define _PPC403_TCR_WIE 0x08000000 /* WDT interrupt enable mask */
  24. #define _PPC403_TCR_PIE 0x04000000 /* PIT interrupt enable mask */
  25. #define _PPC403_TCR_FP 0x03000000 /* FIT period mask */
  26. #define _PPC403_TCR_FIE 0x00800000 /* FIT interrupt enable mask */
  27. #define _PPC403_TCR_ARE 0x00400000 /* auto-reload enable mask */
  28. /* typedefs */
  29. typedef struct {
  30.         UINT32   fitPeriod; /* Fixed Interval Timer periods */
  31.         UINT32   fpMask; /* corresponding TCR mask */
  32. }FIT_PERIOD;
  33. typedef struct {
  34.         UINT32   wdtPeriod; /* Watchdog Timer periods */
  35.         UINT32   fpMask; /* corresponding TCR mask */
  36. }WDT_PERIOD;
  37. #ifdef __cplusplus
  38. }
  39. #endif
  40. #endif /* __INCppc403Timerh */