Don’t buy cheap USB to RS232 converters
So, my girlfriend bought me a STM32F103 board to play around with that has a RS-232 serial port on it to program it. Since I haven’t owned any computer in the last few years that has a serial port, I needed to get a converter.
I decided to go the cheap route and grab one from dealextreme.com. I figured that since most of these converters contains the PL-2303 chip that it wouldn’t really matter what I got. So I decided to buy this converter for $2.99:
I actually bought two of them since I needed one for another development board that I had. So I hooked everything up, ran Flash Loader Demonstrator, and sure enough it didn’t work. I tried all sorts of settings and speeds. At the lowest speed, I got the thing to upload once out of 20 times.
I took the adapter apart and I can see in there some missing components. Now, this happens all the time in manufacturing and it’s usually not a mistake. So it doesn’t really raise a red flag as to that being the problem. I didn’t really test anything with a volt meter or an oscilloscope, but my guess would be that it doesn’t do the RS232 voltages properly.
Those converters ended up being a waste of money for me (luckily, not that big of a deal since they were cheap). The problem was that I still needed a converter, and what device was I going to trust?
Well, Sparkfun has a good reputation so I decided to look at their USB to RS232 converter. It’s a little more costly at $13, and it contains the same PL-2303 chip. If this converter didn’t work, it would be a bigger hit since I had to pay to ship this thing. The product description mentioned it was a high quality converter. I decided to take their word for it.
…it worked perfectly! I could crank it up all the way to 256000 bps and it programmed the STM32 without a hitch.
Conclusion
So the moral of the story is don’t go cheap on a USB to RS232 converter if you’re going to be programming microcontrollers with it. The cheap converters may still work with other things, though. But I think the particular STM32 board that I have is pretty strict on the voltage levels that it receives.
I don’t have any recommendations on other converters to use. All I can say is the one provided by Sparkfun definitely works and is worth the money.





Posted on September 11th, 2010 at 2:34 pm
In this exactly time i ‘m using Flash Loader with your first usb rs232 adapter ..and works perfectly…
maybe the problem is in your driver…
check it out
ps. thanks for your work and your “open source mind”
Posted on December 4th, 2010 at 6:27 pm
You can also get a PCI card with some serial ports. I got mine for cca 12 EUR and it works like a dream.
Posted on February 28th, 2011 at 5:25 am
I had a similar problem with a parallel port and a eprom programmer, in the end I ended up buying a PCI based port card, as it just would not function with the onboard port. Seems things got cheaper and standards got forgotton.
DrF´s last blog ..Todays Random pic