home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / DC-POS24.LZX / pOS / IncPOS.lzx / Device / Timer.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-03-18  |  1.4 KB  |  62 lines

  1. #ifndef __INC_POS_DEVICE_TIMER_H
  2. #define __INC_POS_DEVICE_TIMER_H
  3. /*******************************************************************
  4.  Includes Release 24
  5.  (C) Copyright 1995-1997 proDAD
  6.      All Rights Reserved
  7.  
  8.  $AUT Holger Burkarth
  9.  $DAT >>Timer.h<<   19 Nov 1996    11:24:44 - (C) ProDAD
  10. *******************************************************************/
  11. #ifndef __INC_POS_PEXEC_DEVICE_H
  12. #include <pExec/Device.h>
  13. #endif
  14.  
  15. enum pOS_TimerDeviceUnitNum
  16. {
  17.   TIMERUNIT_MicroHz =0, /* */
  18.   TIMERUNIT_VBlank,     /* */
  19. };
  20.  
  21.  
  22.  
  23. enum pOS_TimerIOReqCommands
  24. {
  25.  TRCMD_AddRequest= CMD_NONSTD,
  26.  TRCMD_GetSysTime,
  27.  TRCMD_SetSysTime,
  28. };
  29.  
  30.  
  31. #define TIME_MICROS 1000000  /* Micros per Sec.  */
  32.  
  33.  
  34. /*----------------------------------
  35. -----------------------------------*/
  36. struct pOS_TimeVal
  37. {
  38.   ULONG tv_Secs;
  39.   ULONG tv_Micro;
  40. };
  41.  
  42.  
  43. /*----------------------------------
  44. -----------------------------------*/
  45. struct pOS_TimerIO
  46. {
  47.   struct pOS_Message      tio_Message;
  48.   struct pOS_TimerDevice *tio_Device;   /* device node pointer  */
  49.   struct pOS_TimerUnit   *tio_Unit;     /* unit (driver private) */
  50.   UWORD                   tio_Command;  /* (enum pOS_IOReqCommands) */
  51.   UBYTE                   tio_Flags;    /* (enum pOS_IOReqFlags)  */
  52.   SBYTE                   tio_Error;    /* (enum pOS_IOReqErrors) */
  53.   struct pOS_TimeVal      tio_Time;
  54. };
  55.  
  56.  
  57.  struct pOS_TimerDevice {struct pOS_Device Dev; };
  58.  
  59.  
  60.  
  61. #endif
  62.