Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

The Parallel Port

A photograph of a short ISA card in green, with a DB-25 connector at the I/O faceplate.

The IBM Printer Adapter

The term parallel is in contrast to serial. The parallel port provides an 8-bit bidirectional data path, whereas a bidirectional serial connection typically uses a pair of wires, transferring one bit at a time.

The PC parallel port was typically used to interface with a printer, but over the years a number of other devices utilized the parallel port, from storage devices to sound generators. Hobbyists could use the parallel port to connect to breadboards and control various projects.

When connecting to a printer, a printer cable was typically used with a male DB-25 connector on one end and a Centronics connector on the other, named after the Centronics Data Computer Corporation.

The parallel port can be implemented entirely with off-the-shelf 74-series logic chips and a few discrete components. IBM sold a dedicated ISA card called the IBM Printer Adapter that provided a single parallel port. A parallel port was often included as a ‘bonus accessory’ on other cards, such as the Monochrome Display Adapter, various multifunction adapters, and several other third-party video cards.

At a Glance

ItemDescription
Typical LPT1 base address378h (or 3BCh on the MDA*)
Typical LPT2 base address278h
Data registerBase address + 0
Status registerBase address + 1
Control registerBase address + 2
InterruptsUsually IRQ7 for LPT1, IRQ5 for LPT2
DMANone

Note

*There is no fixed address for LPT1, 2 and 3. Device names are assigned to ports discovered in the order 3BCh, 378h, 278h.

Registers

The Parallel Data Register

Data Register @ Base + 0Data input and output register.Data RegisterData input and output register.Base + 076543210DATA
BitsNameDescription
0:7DATAData byte

The Parallel Status Register

Status RegisterBuffered status pins from the printer.Status RegisterBuffered status pins from the printer.Base + 176543210BUSYACKPESLCTERRORUnused
BitsNameDescription
0:2UnusedUnused
3ERROR0: The printer has encountered an error condition.
1: The printer reports no current error condition.
4SLCT0: The printer has not been selected (Printer offline)
1: The printer has been selected (Select/Online button pressed)
5PE0: The printer reports it has paper.
1: The printer reports it is out of paper.
6ACK0: The printer has acknowledged the last character and is ready to receive another.
1: The printer is processing (busy).
7BUSY0: The printer is busy and cannot accept data.
1: The printer is not busy and can receive data.

The Parallel Control Register

Control RegisterSet control signals from the CPU to the printer.Control RegisterSet control signals from the CPU to the printer.Base + 276543210UnusedIRQENSLCT_ININITALFSTR
BitsNameDescription
0STRData clock strobe to feed data into the printer.
1ALF0: Do not line-feed automatically.
1: Line-feed automatically.
2INIT0: Initialize the printer.
1: Do nothing.
3SLCT_IN0: Leave printer unselected.
1: Select the printer.
4IRQEN0: Disable interrupts.
1: Enable interrupts triggered by a rising edge of the ACK pin.
5:7UnusedUnused

Datasheet