Choosing DB9 Cables: Null Modem, Straight-Through and Gender Adaptors
Two DB9 cables can have identical connectors and perform different jobs. One extends a serial connection, another crosses signals for a direct equipment link, and a third may join every contact to two branches. Selecting by plug gender alone can therefore produce a connection that fits but never communicates.
The useful starting point is a connection requirement: which equipment is at each end, what interface it uses, and which signals it needs. This guide helps turn that requirement into a purchasing and acceptance checklist for the DB9 cable and adaptor collection, without assuming every nine-pin socket is a standard RS232 port.
Separate the mechanical problem from the electrical problem
Mechanical compatibility includes plug gender, shell clearance, mounting screws and cable length. Electrical compatibility includes the interface standard, contact assignments and control signals. Solving one does not solve the other.
A gender adaptor changes which connectors can mate. A null-modem adaptor changes signal routing. Some products perform both functions, but the words are not interchangeable. For example, a female-to-female adaptor does not automatically provide the crossover needed between two conventional DTE serial ports.
| Accessory | Main function | Check before ordering |
|---|---|---|
| Straight-through cable | Preserve corresponding contact connections | All required contacts and shield arrangement |
| Null-modem cable | Cross relevant serial signals | The particular handshake wiring |
| Gender adaptor | Change mating connector gender | Actual continuity map |
| DB9-to-another-connector adaptor | Rearrange contacts between connector formats | Both equipment pin assignments |
| Passive splitter | Join branches according to its wiring | Whether the interface permits that topology |
Keep each function on a separate line in your notes. “Female DB9 at both ends, RS232 null modem, hardware flow control required” is far more useful than “nine-pin lead for the printer”.
Use DTE and DCE to choose the cable function
Conventional RS232 equipment is described as data terminal equipment, or DTE, and data communications equipment, or DCE. A conventional DTE-to-DCE link uses straight-through wiring. Two DTE endpoints typically need a null-modem arrangement so one transmitter reaches the other receiver. Equipment manuals take priority over assumptions based on the device's name.
NI's guide to null-modem and straight-through cables explains the distinction. A product such as the PMD Way RS232 DB9 null-modem cable belongs in the crossover category, but confirm its detailed wiring against your devices before relying on handshake signals.
This is especially important when replacing an old working lead. Its appearance may hide crossed contacts or internal links. Preserve it as the reference until the replacement passes a real communication test.
Handshaking makes apparently similar cables different
Some systems exchange only transmitted data, received data and a signal reference. Others use control lines to indicate readiness or regulate the flow of data. A cable that carries basic text successfully may still be unsuitable for long transfers if required control signals are absent.
Null-modem wiring is consequently not one universal circuit. NI publishes a specific DTE-to-DTE example with handshaking. Treat that as an illustration of the information a cable specification should contain, rather than a diagram that automatically applies to every instrument.
Consider a workshop label printer that accepts short test messages but stops during a large job. Repeatedly changing baud rate is unlikely to help if the host is configured to wait for a readiness signal that the cable never connects. Compare the printer's required flow-control mode, the computer settings and the cable specification together.
Build a useful replacement-cable specification
Before ordering, record the following details from the actual installation:
- Equipment manufacturer, model and exact port label at both ends.
- Interface type, including whether the port is genuinely RS232.
- Required cable function and control-signal arrangement.
- Connector genders, screw fittings and space behind each device.
- Practical routing length, including enough slack to service the equipment.
- Any manufacturer-specified cable or adaptor part number.
Photograph the current arrangement with its labels visible. If an adaptor stack is involved, record the order of the pieces. Two crossover adaptors in a chain can undo a crossover, while an innocent-looking extension may omit contacts used by the application.
The DB9 gender adaptors can address a mating problem, but their listing is not a substitute for an application wiring specification. Similarly, a connector-size adaptor does not convert RS232 voltage levels to TTL, RS485 or Ethernet.
Do not treat a splitter as an extra serial port
A passive DB9 splitter is not a serial hub. PMD Way explicitly describes its DB9 splitter cable as joining like-numbered contacts across the three connectors and warns against simultaneous twin RS232 signals. That topology can connect output drivers together if used indiscriminately.
If two instruments need independent conversations with a computer, use separate suitable serial interfaces or a purpose-designed switching or conversion arrangement. Decide whether you need simultaneous operation, selected operation or monitoring before choosing hardware. Those are different requirements even when all connectors look alike.
Accept the cable with a repeatable test
Check an unpowered, disconnected cable against the required continuity map before installation if its wiring is uncertain. Then test the real application with a known harmless command and an expected response. Do not send arbitrary text to control equipment whose commands may trigger motion or other operations.
Follow with the longest normal transfer and any required bidirectional exchange. Record the serial settings, cable identity and result. If the old cable works and the replacement does not, change only the cable during comparison; changing software settings at the same time destroys useful evidence.
Once verified, label the lead with its purpose, endpoints and wiring category. A dedicated, documented cable is easier to maintain than a drawer of visually identical adaptors, and the next replacement becomes a straightforward specification exercise.