3
\$\begingroup\$

I think the minimum for simplex communication are TX so we can transmit and the power supply pins +Vcc and GND. That is all we need. When do we need to use all 9 pins of RS-232? I think that the reciever can decipher when data has started coming in and if it knows the baud rate already, it also knows when the latch the incoming bits. Therefore, I don't see the purpose of all the remaining pins on the RS-232 cable besides TX, RX, +Vcc and GND. Do we still need them?

The problem is that I wish to connect a PC to a waveform generator through RS-232 cable. I have the software for this installed on the PC but no RS-232 cable. If I do make my own using RS-232 connectors (which is what I intend) with my own wires soldered to it, how do I know if I just need TX, RX, +Vcc and GND or if I need all the other pins as well?

Soldering all the pins is not such a hard thing to do anyway, but I am just curious.

\$\endgroup\$
  • 10
    \$\begingroup\$ 9 pins? there used to be 25. \$\endgroup\$ – Brian Drummond Jan 20 '14 at 16:50
  • 4
    \$\begingroup\$ I don't recall there being a supply voltage in the DB25 either. \$\endgroup\$ – Adam Lawrence Jan 20 '14 at 16:54
  • \$\begingroup\$ When do we use all pins? Maybe in 1970 we did. Today we commonly use three wire, usually with XON/XOFF protocol for which the cables are much cheaper, but you need some intelligence at both ends to run that. \$\endgroup\$ – jippie Jan 20 '14 at 17:37
  • \$\begingroup\$ Power supply pins? There is no Vcc on as part of the standard RS-232 spec pinout. If you need a small amount of power at the end of an RS-232 cable, you can sometimes "steal" some positive voltage (usually +5 or +12) from the DTR lead, which is usually asserted positive when a port is open. Note that it goes negative when the port is closed, so you must use a diode in series. It is also current-limited, so you can only expect to have a few ma available. \$\endgroup\$ – tcrosley Jan 21 '14 at 15:17
  • \$\begingroup\$ @AdamLawrence I have +/- 12V in the DB25 serial port on my Amiga. It's very handy. The cross-reference list in the Amiga Hardware Reference Manual informs me that this is also the case with Commodore PCs, but not in the standard RS-232. \$\endgroup\$ – pipe Dec 13 '15 at 11:00
6
\$\begingroup\$

The RS-232 standard was originally specified to support connections between Data Terminal Equipment (DTE) such as computers, teletypes and video display terminals and Data Communications Equipment (DCE) such as modems and Automatic Calling Units (ACUs).

At the time, DCE did not have any internal intelligence, so dedicated signals were designed into the RS-232 specification to manage specific features that were common to such equipment, such as flow control, on-hook/off-hook status and call progress.

Nowadays, modems have their own microprocessors, so it's actually easier (and cheaper) to ignore the dedicated signals in the RS-232 connector and do everything over the serial data lines, using the ubiquitous "AT" protocol.

\$\endgroup\$
  • 2
    \$\begingroup\$ I find it hilarious that you're talking about modems when your rep is 28.8k... \$\endgroup\$ – Brian Drummond Jan 21 '14 at 21:32
  • \$\begingroup\$ @BrianDrummond: Yeah, I had noticed that yesterday, too! :-) \$\endgroup\$ – Dave Tweed Jan 21 '14 at 21:50
3
\$\begingroup\$

The RS-232 (DB9) pinout specifies only the TX and RX pins necessary for communication. The rest of the pins are necessary only if you implement some form of hardware flow control. In no particular order these are RTS (Request to Send), CTS (Clear to Send), DTR (Data Terminal Ready) and couple others. You can get the details here.

If your intended hardware doesn't use any form of hardware handshaking (most trivial applications don't; you'd need to check yours, however) you can get away with using the two data pins along with GND.

HTH.

\$\endgroup\$
  • \$\begingroup\$ Some applications use spare pins to supply +5v and ground to things like bluetooth dongles, so always beware of wiring "unused" pins if you don't really need them. \$\endgroup\$ – John U Jan 20 '14 at 16:51
  • \$\begingroup\$ The normal DE-9 RS-232 connector does not have a +5 volt pin (nor did the older DB-25 connector). For most appliocations, TX, RX and ground are the only connections required. \$\endgroup\$ – Peter Bennett Jan 20 '14 at 17:10
  • \$\begingroup\$ @PeterBennett I was thinking of external hardware when I wrote it. I've edited the post to reflect the correct pins. \$\endgroup\$ – Shrikant Giridhar Jan 20 '14 at 17:13
1
\$\begingroup\$

The answer to your question is in the spec for the waveform generator: what does it say about the protocol or flow control that it requires?

The other approach to this is to just wire tx, rx and ground and see if it works, if not then figure out what else. Takes about as much time to research, google, asks questions on stackexchange, and wait for answers as it would to just build a full cable.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.