mirror of
https://github.com/g4klx/MMDVMHost
synced 2025-12-21 23:45:49 +08:00
Remove sensitivity to the state of DSR (DTR on the modem).
This commit is contained in:
@@ -75,17 +75,18 @@ bool CSerialController::open()
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
dcb.BaudRate = DWORD(m_speed);
|
dcb.BaudRate = DWORD(m_speed);
|
||||||
dcb.ByteSize = 8;
|
dcb.ByteSize = 8;
|
||||||
dcb.Parity = NOPARITY;
|
dcb.Parity = NOPARITY;
|
||||||
dcb.fParity = FALSE;
|
dcb.fParity = FALSE;
|
||||||
dcb.StopBits = ONESTOPBIT;
|
dcb.StopBits = ONESTOPBIT;
|
||||||
dcb.fInX = FALSE;
|
dcb.fInX = FALSE;
|
||||||
dcb.fOutX = FALSE;
|
dcb.fOutX = FALSE;
|
||||||
dcb.fOutxCtsFlow = FALSE;
|
dcb.fOutxCtsFlow = FALSE;
|
||||||
dcb.fOutxDsrFlow = FALSE;
|
dcb.fOutxDsrFlow = FALSE;
|
||||||
dcb.fDtrControl = DTR_CONTROL_DISABLE;
|
dcb.fDsrSensitivity = FALSE;
|
||||||
dcb.fRtsControl = RTS_CONTROL_DISABLE;
|
dcb.fDtrControl = DTR_CONTROL_DISABLE;
|
||||||
|
dcb.fRtsControl = RTS_CONTROL_DISABLE;
|
||||||
|
|
||||||
if (::SetCommState(m_handle, &dcb) == 0) {
|
if (::SetCommState(m_handle, &dcb) == 0) {
|
||||||
LogError("Cannot set the attributes for %s, err=%04lx", m_device.c_str(), ::GetLastError());
|
LogError("Cannot set the attributes for %s, err=%04lx", m_device.c_str(), ::GetLastError());
|
||||||
|
|||||||
Reference in New Issue
Block a user