Are there any alternatives to this ancient yet still popular way of communication?
It's just a communications standard, and very bare-bones at that. Your statement is not much different than, "It’s been more than 10 years, and we’re still using wires?" Despite optical and RF solutions being available, wire still has some very distinct advantages, just like RS-232. The main advantages are
Disadvantages include
There are certainly alternatives, but no competitors that have all the above advantages. We could list off the thousands of communication standards one might use in place of RS-232, but the bottom line is that RS-232 hasn't been replaced or superceded. USB is the closest thing to it, but is severely limited in terms of distance, cost, ease of use, and included silicon on most microcontrollers. USB has other significant advantages that RS-232 doesn't have, though. They aren't replacements for each other, and in fact happily coexist on many computers. The key point is that RS-232 is a tool, and as such isn't intrinsically bad, or in need of replacement. It's getting less use these days as people want more advanced features, or faster speeds, or have some other requirement which RS-232 doesn't fulfill. But that doesn't mean that it should or will go away, because there are still a lot of new applications where RS-232 is the perfect fit. |
||||
|
|
|
What do you mean - just 10 years. RS-232 was defined in 1962 and so is coming up to its 48th birthday. RS-232 uses a simple asynchronous serial data transfer method that requires very little silicon, is easy to code in software and can be used on micros with minute amounts of RAM or program memory. It has also had the advantage in the past that all computers and dumb terminals had RS-232 interfaces so using it for debug output was a no-brainer. If you needed higher speed or long distance transmission then you just replace the line drivers with RS-422 or RS-485 differential driver/receivers and no change to the software was needed. Implementing USB on tiny micros is just not possible. The processing/memory/silicon overhead is just too costly. SPI or I2C are possible (and used in some places) but the interface cards for your pc are unusual and expensive. I2C has a nasty lockup state that can make it die if the clock stops halfway through a slave data output cycle and the data bit is low. |
|||||||||
|
Frankly with that record, I would be surprised if it ever goes away entirely. |
||||
|
There are many alternatives. USB is the one that seems most commonly used nowadays. I2C is another. RS-232 still exists for legacy reasons. If you can put up with the mishmash of different data rates, stop bits, parity settings and wiring configurations, it is actually quite a simple, solid and reliable interface for low data rate applications. I listened to a podcast recently that discussed the handling of audio at a seminar. All of the audio pros still use XLR connectors and conventional microphone cables, a technology that's at least 50 years old, even though newer alternatives are available. They use it because it is stable, proven, reliable, and industry-standard. |
||||
|
|
|
Distinguish serial UART communication from the various voltage levels used to transmit it: RS232, RS485, LVDS. Serial UART communication is reliable and simple. |
|||
|
|
|
A lot of systems will convert the RS-232 to USB using a converter IC. The ones that seem to be the most popular are the FTDI devices. FTDI sells a cable with a USB connector on one end and six pin header on the other (FTDI TTL-232R-3V3). This converts from a USB to RS232 at TTL levels FTDI also makes an IC to perform the same function -- FTDI FT232RL. This is in an SMD package. You connect the data inputs to the USB connector and the outputs to an RS232 at TTL Levels. The cable is in the $15-$20 range. The IC is around $2.50 (100). The IC requires a half dozen passives. I also like to add a TVS IC. It you need to get true RS232 levels you would need a driver IC. More of the hobbyist parts are now starting to integrate USB into the low end controllers. RS232 will start to be used only where you need a large number of simple UARTs. |
||||
|
|
|
I'm a fan of USB <--> Serial IC's, handles all the dirty work of implementing USB, and you can pump up the bitrates to extreme levels (official RS232 tops out at what, 115k? I've seen USB<-->serial do several mbit/sec before) |
|||||||
|
|
RS232 voltage-level signaling is becoming less common, as more and more devices are designed to plug into a USB port rather than an RS-232 port. The common async 8-N-1 signaling protocol, however, allows data to be sent full duplex with predictable timing and no byte stuffing. A byte can be started at any desired moment when the line is otherwise idle, and there is no danger of data underrun. Hardware to support 8-N-1 signaling is common and cheap, and while the protocol isn't entirely optimal, many changes that would make it better for some applications would make it worse for others. The only significant downside to 8-N-1 is that it requires that both sides of the communication have a stable clock which is a known (generally integer) multiple of the desired communications rate. Incidentally, most async 8-N-1 hardware allows for at least one type of out-of-band signalling: the long break. While there are certainly times it would be helpful to have a few more types of out-of-band signaling, it's useful to have at least one. |
|||
|
|