Click here to Skip to main content
15,878,602 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have To communicate with "Schneider Electric's Smart Relay".
Everything works fine, but randomly at some point serial communication fails.
i.e program hangs.
While debugging i found that either at serial->Read or serial->Write,this thing happens.

I tried the same communication using Labview and still faced the same problem.

Even though I have set read and write timeouts.It's like during this random event -it goes to infinite timeout.

The communication cable is "SR2USB01" ... A USB to serial converter

1 solution

The driver on the USB/SERIAL device is an FTDI chip and the driver is bugged they are notorious for it.

If you look at windows update it's probably an optional update you haven't downloaded or go to the USB converter website they probably have a updated driver for the converter. On some of the USB converter drivers they also have weird setting stuff you can play with.

You can recover the problem by taking the DTR line down and up on the PC once you get the timeout but you always seem to lose characters so it's useless unless you have CRC communication protocol and block sending to fix the data error.

That problem drove us mad on our CNC controller software for years and in the end we migrated to telnet on ethernet port just to get away from the stupid problems of USB to serial converters.
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900