EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Do you still use "RS232" or something else?

Started by Oliver Betz January 14, 2011
On 1/15/2011 11:52 AM, Oliver Betz wrote:
> Grant Edwards wrote: > > Even if you use a CDC USB device with the Windows drivers, you have to > build a custom INF file, and you need admin rights to install them. > > So the question is not only whether Windows has drivers (it has for > CDC), but whether I need to "install" any drivers. > > I didn't try it yet, but as far as I see, a HID doesn't need explicit > installation, especially no admin rights under Windows. > > But of course, you need custom software to make the data accessible, > at least the equivalent to a terminal program.
This was the advantage of my "mass storage" device approach -- the user just deals with "files" accessed from his browser. If your "files" contain java applets, you could probably get lots of extra functionality than "plain old HTML" (though that forces the user to have java installed in his browser -- probably a reasonably safe bet?)
On Jan 15, 1:52=A0pm, Oliver Betz <OB...@despammed.com> wrote:
> rickman wrote: > > [...] > > >But I'm looking forward to the day when 232 is replaced by USB, not > >because laptop makers refuse to have them in the machine, but because > >USB is so easy to add there is no reason to use 232. > > Maybe I have a different understanding of "easy". > > Using a terminal program (e.g the one supplied with the PC operating > system) is easy. I can guide a customer's technician on the phone to > do it. He doesn't even need Internet access there. > > Providing software to access the USB HID data for every operating > system is IMNSHO less easy. Windows X86, Windows 64 bit, Linux, Mac OS > X, to be supported for more than ten years. I don't like to do it.
Why does this require more than a terminal program? I use a USB serial port with all sorts of software that is written to talk to a serial port. Can a USB device be configured to look like a serial port independent of what the USB chip is actually connected to? I would think you could use any interface you want from the MCU to the rest of the circuit, but the USB MCU should be able to fake out a serial port to the PC, no? When I say I look forward to, I meant look *forward* to. I'm not saying it is this easy right now. Has anyone considered USB development tools from http://www.tracesystemsinc= .com/ ? They seem to be selling tools that let you generate USB code for both the PC and the target system. It looks like it only supports Windows however. But I'm not clear on that either. Rick
On Jan 15, 1:33=A0pm, Spehro Pefhany <speffS...@interlogDOTyou.knowwhat>
wrote:
> On Sat, 15 Jan 2011 09:49:28 -0800 (PST), the renowned rickman > > > > <gnu...@gmail.com> wrote: > >On Jan 15, 2:41=A0am, Glenn <glenn2...@gmail.com> wrote: > >> On 15 Jan., 02:01, Clifford Heath <n...@spam.please.net> wrote: > > >> > On 01/14/11 23:13, Oliver Betz wrote: > > >> > > Do you still use EIA-232? Customers complaining? > > >> > Don't know, but I can tell you what I wished for, even 25 years > >> > ago when I had almost daily fights with RS-232 cabling. > > >> > A symmetrical standard based on a hermaphrodite 8-wire connector. > > >> > My-ground, I'm-ready, my-data, my-power/my-inverted-data (if > >> > differential), and the corresponding 4 inputs. > > >> > Put them all in a symmetric 8 conductor socket that's half > >> > male, half female, so if you can plug it in, and have the > >> > right data-rate, it'll work. In differential mode, it would > >> > be good for half-mile runs at decent data rates on CAT-5. > > >> > Center the data levels at 2.5V, with swings to 0 and 5V so you > >> > don't need elevated supplies from a 5V system, and you can > >> > easily transfer useful power, perhaps 100mA, for low-power > >> > peripherals, even when using differential transmission. > > >> > I don't get why hermaphrodite connectors never took off, it > >> > just seems like a no-brainer. They might be a little harder > >> > to make, but in volume would surely be cheaper than DE-25s. > > >> > Clifford Heath. > > >> Hi Clifford > > >> Please look here - the nearest EIA-232 wiring supporting some of your > >> wishes - via 8P8C aka "RJ-45": > > >>http://www.lammertbies.nl/comm/cable/yost-serial-rj45.html > > >> - > > >> The USB standard ought to be with for a long time - why?: > > >> It has only 1 twisted pair for bidirectional communication. It can not > >> get any simpler in hardware ! > > >> and 0V and to some extent optionally +5V. > > >One time, many years ago, I developed a standard pinout for an RJ-45 > >connector that allows every device to talk to every device. =A0It had > >two grounds and the other pins were paired, TX-RX, RTS-CTS, DTR-DSR > >and the RJ-45 cable was wired as a crossover always. =A0That part worked > >pretty well. =A0But you still needed up to four adapters just for one > >size connector, the DB-25 still being the dominant size. =A0By the time > >the DB-9 was adopted as an EIA standard, the DB-25 was getting to be > >rare and I found a lot less trouble getting things to pair up ok > >without the RJ-45. =A0Now it seems like the male DB-9 connectors are all > >wired DTE while the female DB-9 connectors are all wired DCE so one > >cable with a null modem on one end if needed does the trick. =A0If push > >comes to shove, and you find a DB-25 connector a DB-9 to DB-25 usually > >does the trick with the other stuff. > > >But I'm looking forward to the day when 232 is replaced by USB, not > >because laptop makers refuse to have them in the machine, but because > >USB is so easy to add there is no reason to use 232. > > RS-232 can (at low baud rates) tolerate a couple of orders of > magnitude longer cables than USB. Of course we have Ethernet for that, > but it adds a lot of complexity, both to the device and often for the > user to set it up.
Double edged sword. 232 =3D slow and far, USB =3D short and fast. Most of my stuff would benefit more from the short and fast. USB can be sent over longer distances using repeaters or actually one port hubs up to some hundred feet, I believe. Never tested it though. Rick
On Jan 15, 12:25=A0pm, rickman <gnu...@gmail.com> wrote:
> On Jan 15, 1:52=A0pm, Oliver Betz <OB...@despammed.com> wrote: > > > > > rickman wrote: > > > [...] > > > >But I'm looking forward to the day when 232 is replaced by USB, not > > >because laptop makers refuse to have them in the machine, but because > > >USB is so easy to add there is no reason to use 232. > > > Maybe I have a different understanding of "easy". > > > Using a terminal program (e.g the one supplied with the PC operating > > system) is easy. I can guide a customer's technician on the phone to > > do it. He doesn't even need Internet access there. > > > Providing software to access the USB HID data for every operating > > system is IMNSHO less easy. Windows X86, Windows 64 bit, Linux, Mac OS > > X, to be supported for more than ten years. I don't like to do it. > > Why does this require more than a terminal program? =A0I use a USB > serial port with all sorts of software that is written to talk to a > serial port. =A0Can a USB device be configured to look like a serial > port independent of what the USB chip is actually connected to? =A0I > would think you could use any interface you want from the MCU to the > rest of the circuit, but the USB MCU should be able to fake out a > serial port to the PC, no? >
Yes, any USB uC can implement CDC device. Window can use VCOM (Virtual Com port) for them. The problem is that VCOMXX can be changing. I am upto VCOM17 on my PC, without anything in between 1 and 16.
On Sat, 15 Jan 2011 12:27:51 -0800, rickman wrote:

>> RS-232 can (at low baud rates) tolerate a couple of orders of magnitude >> longer cables than USB. Of course we have Ethernet for that, but it >> adds a lot of complexity, both to the device and often for the user to >> set it up. > > Double edged sword. 232 = slow and far, USB = short and fast. Most of > my stuff would benefit more from the short and fast. USB can be sent > over longer distances using repeaters or actually one port hubs up to > some hundred feet, I believe. Never tested it though. >
High speed USB supports up to 5 meter of cable, and up to 7 tiers, including a host, a client, and 5 intermediate hubs, which means a maximum of 6x5 = 30 meter of cable. Cable length is actually a timing constraint, which is specified as <= 26 ns delay one-way.
On 01/15/11 18:41, Glenn wrote:
> On 15 Jan., 02:01, Clifford Heath<n...@spam.please.net> wrote: >> On 01/14/11 23:13, Oliver Betz wrote: >>> Do you still use EIA-232? Customers complaining? >> A symmetrical standard based on a hermaphrodite 8-wire connector. > Please look here - the nearest EIA-232 wiring supporting some of your > wishes - via 8P8C aka "RJ-45":
Not a bad way to go. Still lacks power and differential support, which I think is more important than the various flow control and status lines.
> The USB standard ought to be with for a long time - why?: > It has only 1 twisted pair for bidirectional communication. It can not > get any simpler in hardware !
At a huge cost in software though, especially host-side. Clifford Heath
On 01/16/11 04:30, Paul E. Bennett wrote:
> Clifford Heath wrote: >> A symmetrical standard based on a hermaphrodite 8-wire connector. >> My-ground, I'm-ready, my-data, my-power/my-inverted-data (if >> differential), and the corresponding 4 inputs. > If you go for inverted data as well that is 5 connections each way.
No. If you don't want to send differential data, pull the diff/power wire to 5V to provide power. The diff receiver on the other end can still get the noise immunity of diff wiring. If you do want to send diff, then one of the data wires is always at 5V while the other's at 0, so a pair of diodes can extract power.
> I'd consider two differentially driven circuits in each direction as > adequate. One TX pair and a Ready or Sync pair.
With a small receive buffer, the handshake circuits don't need the same data rate as the data lines, so arguably don't need differential wiring.
> If you are thinking like the LEMO half and half connectors, they are > somewhat pricey.
Chicken and egg problem though, no? Clifford Heath.
On Sat, 15 Jan 2011 12:34:10 -0700, D Yuniskis
<not.going.to.be@seen.com> wrote:

>> But I'm afraid our users won't use plain/clean Ethernet but switch to >> "Screwed-Up-Profibus" which I won't implement unless I'm forced to. > >If you can live with the (short) distance limitations of USB, what if >you made your device look like a mass storage device. I.e., damn >near every USB host out there will recognize a USB "disk drive". > >User can mount the drive (which is often automatic) and then access >X:\index.html to interact with it. That *static* page (i.e., a "file" >on your device) can have links to: X:\status.html, X:\log.html, >X:\diagnostics.html, etc. You don't even need a "web server" in >your device -- instead, you watch to see which "files" are accessed >and in which order.
If you want to look like a USB drive, you must also act like an USB drive (timeouts). For more than two years ago, I had problems installing a wireless broadband modem (Huawei). It used one Windows drive letter (file system) for actual modem operation and an other for distributing the (Windows) drivers. My installation attempts ended up with various timeout proplems. I finally figured out that by first copying the installation software and drivers from the USB modem "disk drive" to an external drive (such as USB memory stick) the installation process went OK. Apart from this, the modem has worked flawlessly, when I use the same USB port. Unfortunately using a diffeent USB purt caused a lot of problems.
On 14/01/2011 12:13, Oliver Betz wrote:
> although most of our (industrial) clients still use to have computers > with a "real" serial port, I observe a small but increasing number > struggling with bad USB adapters and asking for other interfaces. > > Therefore I'm reconsidering the best suited interface for device > configuration and diagnosis. > > Do you still use EIA-232? Customers complaining?
I've recently been working on a new family of data acquisition modules. Main interface is TCP/IP (actually UDP - there are reasons for that). But from day one I had an NRZ serial interface (RS-232 or RS-422 or RS-485, depending on hardware) for debugging purposes. Since then it's grown - we now need to talk NRZ to a GPRS modem and a GPS module. Serial comms are still useful. USB, not so much. Steve -- http://www.fivetrees.com
On 14 Jan., 13:13, Oliver Betz <ob...@despammed.com> wrote:
> Hello All,
...
> > More alternatives? > > Oliver > -- > Oliver Betz, Munich > despammed.com is broken, use Reply-To:
The alternative - long ago MacOS X begin to support IP-over-USB and IP- over-firewire - but this is not the point though. The point is that you can communicate with your device via layer 2 mac/ ethernet/physical-addresses ! You do not need IP and the DHCP functionality. You only need to write in the device mac-address to communicate with it. In principle the mac-address is unique in the whole world, but the mac-address is typically different on the different ports (USB, ethernet...). With todays open-source ip-stacks, you can simply remove the ip-part and only use layer 2 communication. Maybe you could use PPP over ethernet II framing? - layer 2 protocols: http://en.wikipedia.org/wiki/List_of_network_protocols#Layer_2_protocols_.28Data_Link_Layer.29 http://en.wikipedia.org/wiki/Data_link_layer e.g. http://en.wikipedia.org/wiki/Ethernet http://en.wikipedia.org/wiki/Ethernet_frame#Ethernet_frame_types E.g. Ethernet II frame = DIX frame - most used http://en.wikipedia.org/wiki/Point-to-Point_Protocol Other layer-2 examples over e.g. ethernet or 802.1 not used here: dhcp arp 802.1x ( http://en.wikipedia.org/wiki/IEEE_802.1x )

The 2024 Embedded Online Conference