[RS-232] Garbage Read when using USB to RS-232 adapter vs. normal RS-232 Port

Not open for further replies.


Mar 8, 2017

I have been using a program that I created in C++ to control test equipment using the RS-232 interface. The computer running this program is a Windows XP laptop with a physical RS-232 port on the back. I recently tried to make the move to a Windows 7 laptop without a physical RS-232 port by using several USB to RS-232 adapters. Each one can write successfully, but reads garbage values (zeros). I did not change the affected code when I moved from one PC to the other and I didn't change the serial settings. Can someone explain why moving from a physical RS-232 port to an emulated one can cause this problem? Thanks.

Serial Device Specs:
Baud Rate: 115.2k Hz
Data Bits: 8
Stop Bits: 1
Parity: None
Flow Control: None
Terminator: Carriage Return Line Feed


Probably a matter of the USB to RS-232 pinouts.

Although there are standard configurations many manufacturers created proprietary cables/adapters for their own purposes. Mostly to sell their own products.

Good chance that there is some unique USB to RS-232 connection requirement: physical or virtual.

Google USB to RS-232 pinouts. Start by looking at images. Especially wiring diagrams. See if you can match up the physical configurations to the connectivity required by your application.

Full disclosure: Not sure how much you can really do with C++ with respect to the desired emulation.

But the first step is to verify the requirement for both write and read connectivity.

You have made (at least) two changes:
- replaced serial hardware (RS-232 with USB adapter)
- replaced actual hardware (snail-slow ten-year old laptop with modern desktop)
- replaced OS (XP with 7/10)

If said remote device can operate using standard serial terminal, try first talking to it using eg Putty. Your custom software could not set up properly the port, or rely on timeouts which do not work properly on USB ports


Feb 13, 2017
What if you add more delay in your code (wait for answer) and change the buffer ?
Make sure that the adapter is properly installed (proper drivers). I use these kind of adapters and they work fine.
Not open for further replies.
Thread starter Similar threads Forum Replies Date
M Apps General Discussion 1
J Apps General Discussion 1
Tigro Apps General Discussion 3
G Apps General Discussion 0
S Apps General Discussion 2
A Apps General Discussion 2
D Apps General Discussion 1
S Apps General Discussion 1
J Apps General Discussion 2
S Apps General Discussion 1
A Apps General Discussion 1
O Apps General Discussion 2
F Apps General Discussion 4
T Apps General Discussion 4
Roger Narq Apps General Discussion 1
W Apps General Discussion 3
J Apps General Discussion 7
K Apps General Discussion 1
F Apps General Discussion 3
P Apps General Discussion 1