Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
RTS/DTR ComPort lines Problems
Message
From
14/09/2004 15:13:53
 
 
To
14/09/2004 12:56:42
General information
Forum:
Visual C++
Category:
C++ Managed Code
Miscellaneous
Thread ID:
00941977
Message ID:
00942057
Views:
11
>Hi,
>
>Problem with RTS, DTR lines during the baud rate change.
>
>I am currently using the Serial Port class CSerialPort (by Remon Spekreijse) in MS Visual C++.
>When I am changing the baud rate by the following lines of code:
>
>m_dcb.BaudRate = CBR_115200;baud;
>if (SetCommState(m_hComm, &m_dcb)) {
>} else {
>}
>After executing these command, the lines RTS, DTR that are used for the control purposes, set into initial settings, different from my system’s default settings.
>Guys, Help me!!!!!!
>Thanks Alex


Hi Alex,

I don't know about managed code, but I think you have to get the default state first (GetCommState) before you set it. So it fills in the DCB structure

Hope it works
Regards
Herman
Previous
Reply
Map
View

Click here to load this message in the networking platform