home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 8 Other / 08-Other.zip / os2upsd.zip / upsd.h < prev    next >
C/C++ Source or Header  |  1997-10-18  |  646b  |  34 lines

  1. #ifndef UPSD_H
  2. #define UPSD_H
  3.  
  4. #define INCL_PM
  5. #define INCL_DOSDEVICES
  6. #define INCL_DOSPROCESS
  7. #define INCL_WINMESSAGEMGR
  8. #define INCL_WINWINDOWMGR
  9. #define INLC_WINWORKPLACE
  10.  
  11. #include <os2.h>
  12. #include <pmwp.h>
  13. #include <stdio.h>
  14. #include <stdlib.h>
  15. #include <bsedev.h>
  16. #include <io.h>
  17. #include <fcntl.h>
  18. #include <sys\stat.h>
  19.  
  20. #define WORD unsigned short int
  21.  
  22. #define ST_OK        (BYTE) 0;
  23. #define ST_POWERFAIL     (BYTE) 1;
  24. #define ST_POWERLOW    (BYTE) 2;
  25.  
  26. static int fd = 0;
  27. static int state = ST_OK;
  28.  
  29. const BYTE PRT_CTS =     0x10;
  30. const BYTE PRT_DSR =     0x20;
  31. const BYTE PRT_RI  =     0x40;
  32. const BYTE PRT_DCD =     0x80;
  33.  
  34. #endif