How to set the DCD line status manually for virtual serial port?

In order to set the DCD line status manually you should add the following code to CVC7ExampleDlg::OnBnClickedButton1 function to be able to manage DCD line, i.e.:

CODE: 

if (m_VSPort1.CreatePort (m_strPort1) || m_VSPort1.Attach (m_strPort1))
{
m_VSPort1.SetWiring (0x20, 0x10, 0, 0);
}

Using this code you will be able to control DCD signal line status manually. In order to check the status of the signal lines you can use our Advanced Serial Port Terminal: http://www.eltima.com/products/serial-port-terminal/

Use Switch DCD option in our example and refer to Terminal signal lines buttons to make sure that you are able to control DCD signal lines manually.