Platform SDK: Files and I/O

COMSTAT

The COMSTAT structure contains information about a communications device. This structure is filled by the ClearCommError function.

typedef struct _COMSTAT { 
  DWORD fCtsHold : 1; 
  DWORD fDsrHold : 1; 
  DWORD fRlsdHold : 1; 
  DWORD fXoffHold : 1; 
  DWORD fXoffSent : 1; 
  DWORD fEof : 1; 
  DWORD fTxim : 1; 
  DWORD fReserved : 25; 
  DWORD cbInQue; 
  DWORD cbOutQue; 
} COMSTAT, *LPCOMSTAT; 

Members

fCtsHold
Specifies whether transmission is waiting for the CTS (clear-to-send) signal to be sent. If this member is TRUE, transmission is waiting.
fDsrHold
Specifies whether transmission is waiting for the DSR (data-set-ready) signal to be sent. If this member is TRUE, transmission is waiting.
fRlsdHold
Specifies whether transmission is waiting for the RLSD (receive-line-signal-detect) signal to be sent. If this member is TRUE, transmission is waiting.
fXoffHold
Specifies whether transmission is waiting because the XOFF character was received. If this member is TRUE, transmission is waiting.
fXoffSent
Specifies whether transmission is waiting because the XOFF character was transmitted. If this member is TRUE, transmission is waiting. Transmission halts when the XOFF character is transmitted to a system that takes the next character as XON, regardless of the actual character.
fEof
Specifies whether the end-of-file (EOF) character has been received. If this member is TRUE, the EOF character has been received.
fTxim
If this member is TRUE, there is a character queued for transmission that has come to the communications device by way of the TransmitCommChar function. The communications device transmits such a character ahead of other characters in the device's output buffer.
fReserved
Reserved; do not use.
cbInQue
Specifies the number of bytes received by the serial provider but not yet read by a ReadFile operation.
cbOutQue
Specifies the number of bytes of user data remaining to be transmitted for all write operations. This value will be zero for a nonoverlapped write.

Requirements

  Windows NT/2000: Requires Windows NT 3.1 or later.
  Windows 95/98: Requires Windows 95 or later.
  Header: Declared in Winbase.h; include Windows.h.

See Also

Communications Overview, Communication Structures, ClearCommError, ReadFile, TransmitCommChar