Retrieves modem control-register values.
BOOLEAN GetCommModemStatus( COMMHANDLE hComm, // handle to communications device LPDWORD lpModemStat // control-register values );
hComm
lpModemStat
Value | Description |
---|---|
MS_CTS_ON | The CTS (clear-to-send) signal is on. |
MS_DSR_ON | The DSR (data-set-ready) signal is on. |
MS_RING_ON | The ring indicator signal is on. |
MS_RLSD_ON | The RLSD (receive-line-signal-detect) signal is on. |
0
(zero)
E_DISCONNECTED
E_PARAM
GetCommModemStatus is useful when you are using WaitCommEvent to monitor the CTS, RLSD, DSR, or ring indicator signals. To detect when these signals change state, use WaitCommEvent and then use GetCommModemStatus to determine the state after a change occurs.
If the hardware does not support the control-register values, the function fails.
Versions | Defined in | Include | Link to |
---|---|---|---|
INtime 3.1 | intime/rt/include/comm.h | comm.h | comm.lib |