0
votes

I have a SerialPort object to control a gsm modem connected to a virtual com port. My problem is that i do not receive any data under Windows XP. The DataReceived Event is not triggered nor outputs port.ReadExisting() any data if called periodically. But when i shut down my program and connect with putty to this port, the response of the modem is displayed.

Under Windows 7 data is received correctly.

What could be the problem here?

1
Can you please add the settings from Putty and the settings from your application? Just for a small comparation.adricadar
Please Install the driver for the Connected device.Usually RS232 DriverArjun Prakash
Could you post minimal code sample, which works under Win7 and doesn't work under WinXP?Dennis
@adricadar thank you for your answer. I think I have asked and did too less investigation. I compared with the Putty settings and found out that software handshake needs to be enabled (see my own answer below). But maybe this helps someone doing the same mistake.wewa

1 Answers

1
votes

Software handshake needs to be enabled.

this.serialPort.Handshake = System.IO.Ports.Handshake.XOnXOff;

I found this out by comparing the putty settings with the serial port settings in my program. So the problem was not the operating system itself, but the used flow control.