Navigation: =>

Home / Electronics / Circuits / Special devices ... /

The scheme for connecting different devices through the printer port (LPT).

Scheme of connecting different devices through
Printer port (LPT)

The LPT port on the computer is used to control the printer. It can be successfully used to control a device.

To explain the work we use the control circuit of eight LEDs.

As you know LPT port consists of 25 pins. In the work of this scheme, all 25 conclusions are optional. It is enough to use eight pins to control the LEDs. The connection diagram is shown below.

The scheme for connecting different devices through the printer port (LPT)

2 D0
3 D1
4 D2
5 D3
6 D4
7 D5
8 D6
9 D7
Eight control pins

Resistors with a resistance of 470 Ohm. LEDs should be used with a small current consumption.

An example of a control program you can download here . The program works in the MS-DOS system. It also works in Borland Pascal 7.0 code when unloading into the compiled program.

Program lpt1_output;

Uses Dos;

Var
Addr: word;
Data: byte;
E: integer;

Begin
Addr: = MemW [$ 0040: $ 0008];
Val (ParamStr (1), data, e);
Port [addr]: = data;
End.

In addition to controlling the LEDs, it is also possible to control the electromagnetic relay by connecting it through the circuit shown below.

Attention!

With careless LPT experiments, the port may be damaged, which will result in the replacement of the computer's motherboard. Therefore, when experimenting, use an inexpensive computer and be very careful.

Date of publication 19.04.2003gg.