home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / BC_DICE2.DMS / in.adf / INCLUDE / devices / timer.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-01-10  |  789 b   |  48 lines

  1. #ifndef DEVICES_TIMER_H
  2. #define DEVICES_TIMER_H 1
  3. /*
  4. ** $Filename: devices/timer.h $
  5. ** $Release: 2.04 Includes, V37.4 $
  6. ** $Revision: 36.16 $
  7. ** $Date: 91/01/25 $
  8. **
  9. ** Timer device name and useful definitions.
  10. **
  11. ** (C) Copyright 1985-1991 Commodore-Amiga Inc.
  12. ** All Rights Reserved
  13. */
  14.  
  15. #include <exec/types.h>
  16. #include <exec/io.h>
  17.  
  18.  
  19. #define UNIT_MICROHZ 0
  20. #define UNIT_VBLANK 1
  21. #define UNIT_ECLOCK 2
  22. #define UNIT_WAITUNTIL 3
  23. #define UNIT_WAITECLOCK 4
  24.  
  25. #define TIMERNAME "timer.device"
  26.  
  27. struct timeval {
  28.  ULONG tv_secs;
  29.  ULONG tv_micro;
  30. };
  31.  
  32. struct EClockVal {
  33.  ULONG ev_hi;
  34.  ULONG ev_lo;
  35. };
  36.  
  37. struct timerequest {
  38.  struct IORequest tr_node;
  39.  struct timeval tr_time;
  40. };
  41.  
  42.  
  43. #define TR_ADDREQUEST CMD_NONSTD
  44. #define TR_GETSYSTIME (CMD_NONSTD+1)
  45. #define TR_SETSYSTIME (CMD_NONSTD+2)
  46.  
  47. #endif 
  48.