Cat
WinTypes.h
Go to the documentation of this file.
1 #ifndef __WINDOWS_TYPES__
2 #define __WINDOWS_TYPES__
3 
4 #define MAX_NUM_DEVICES 50
5 #include <sys/time.h>
6 
7 typedef unsigned long DWORD;
8 typedef unsigned long ULONG;
9 typedef unsigned short USHORT;
10 typedef short SHORT;
11 typedef unsigned char UCHAR;
12 typedef unsigned short WORD;
13 typedef unsigned char BYTE;
14 typedef unsigned char *LPBYTE;
15 typedef int BOOL;
16 typedef char BOOLEAN;
17 typedef char CHAR;
18 typedef int *LPBOOL;
19 typedef unsigned char *PUCHAR;
20 typedef const char *LPCSTR;
21 typedef char *PCHAR;
22 typedef void *PVOID;
23 typedef void *HANDLE;
24 typedef long LONG;
25 typedef int INT;
26 typedef unsigned int UINT;
27 typedef char *LPSTR;
28 typedef char *LPTSTR;
29 typedef DWORD *LPDWORD;
30 typedef WORD *LPWORD;
31 typedef ULONG *PULONG;
32 typedef PVOID LPVOID;
33 typedef void VOID;
34 typedef unsigned long long int ULONGLONG;
35 
36 typedef struct _OVERLAPPED {
39  DWORD Offset;
41  HANDLE hEvent;
43 
44 typedef struct _SECURITY_ATTRIBUTES {
45  DWORD nLength;
46  LPVOID lpSecurityDescriptor;
47  BOOL bInheritHandle;
49 
50 typedef struct timeval SYSTEMTIME;
51 typedef struct timeval FILETIME;
52 #ifndef TRUE
53 #define TRUE 1
54 #endif
55 #ifndef FALSE
56 #define FALSE 0
57 #endif
58 
59 //
60 // Modem Status Flags
61 //
62 #define MS_CTS_ON ((DWORD)0x0010)
63 #define MS_DSR_ON ((DWORD)0x0020)
64 #define MS_RING_ON ((DWORD)0x0040)
65 #define MS_RLSD_ON ((DWORD)0x0080)
66 
67 //
68 // Error Flags
69 //
70 
71 #define CE_RXOVER 0x0001 // Receive Queue overflow
72 #define CE_OVERRUN 0x0002 // Receive Overrun Error
73 #define CE_RXPARITY 0x0004 // Receive Parity Error
74 #define CE_FRAME 0x0008 // Receive Framing error
75 #define CE_BREAK 0x0010 // Break Detected
76 #define CE_TXFULL 0x0100 // TX Queue is full
77 #define CE_PTO 0x0200 // LPTx Timeout
78 #define CE_IOE 0x0400 // LPTx I/O Error
79 #define CE_DNS 0x0800 // LPTx Device not selected
80 #define CE_OOP 0x1000 // LPTx Out-Of-Paper
81 #define CE_MODE 0x8000 // Requested mode unsupported
82 
83 #ifndef INVALID_HANDLE_VALUE
84 #define INVALID_HANDLE_VALUE 0xFFFFFFFF
85 #endif
86 
87 #endif
struct timeval FILETIME
Definition: WinTypes.h:51
char * LPSTR
Definition: WinTypes.h:27
WORD * LPWORD
Definition: WinTypes.h:30
struct _OVERLAPPED OVERLAPPED
unsigned char UCHAR
Definition: WinTypes.h:11
unsigned char BYTE
Definition: WinTypes.h:13
DWORD * LPDWORD
Definition: WinTypes.h:29
struct _SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES
DWORD Offset
Definition: WinTypes.h:39
struct timeval SYSTEMTIME
Definition: WinTypes.h:50
unsigned int UINT
Definition: WinTypes.h:26
char * LPTSTR
Definition: WinTypes.h:28
int * LPBOOL
Definition: WinTypes.h:18
DWORD Internal
Definition: WinTypes.h:37
HANDLE hEvent
Definition: WinTypes.h:41
void * PVOID
Definition: WinTypes.h:22
unsigned long long int ULONGLONG
Definition: WinTypes.h:34
DWORD InternalHigh
Definition: WinTypes.h:38
char BOOLEAN
Definition: WinTypes.h:16
void VOID
Definition: WinTypes.h:33
unsigned char * LPBYTE
Definition: WinTypes.h:14
unsigned long ULONG
Definition: WinTypes.h:8
void * HANDLE
Definition: WinTypes.h:23
unsigned short USHORT
Definition: WinTypes.h:9
short SHORT
Definition: WinTypes.h:10
DWORD OffsetHigh
Definition: WinTypes.h:40
PVOID LPVOID
Definition: WinTypes.h:32
const char * LPCSTR
Definition: WinTypes.h:20
unsigned short WORD
Definition: WinTypes.h:12
char * PCHAR
Definition: WinTypes.h:21
struct _SECURITY_ATTRIBUTES * LPSECURITY_ATTRIBUTES
int BOOL
Definition: WinTypes.h:15
char CHAR
Definition: WinTypes.h:17
struct _OVERLAPPED * LPOVERLAPPED
int INT
Definition: WinTypes.h:25
unsigned long DWORD
Definition: WinTypes.h:7
unsigned char * PUCHAR
Definition: WinTypes.h:19
ULONG * PULONG
Definition: WinTypes.h:31
long LONG
Definition: WinTypes.h:24