Hardware - Connecting a printer with a Centronics interface to the LPT port.

╔════════════════════════ ═══════════════════ ═══════════════════╗
║ Iron.            ║
╙─────────────────────────────── ───────────────────────────────╜
(R) EVP-SOFT

 Connecting a printer with a Centronics interface to the LPT port.

 Connecting the cable to the parallel interface adapter
is carried out through a 25-pin connector type D-shell (DB-25), and with
printer side uses a special 36-pin connector
type Centronics.  Since the frequency of transmitted signals can
reach tens of kilohertz, the length of such cables usually does not exceed
rises three meters.  Distribution of signals across the contacts of both
connectors are shown in Tables 1 and 2. Generally speaking, for simple
transferring data to the printer does not require all signals that define
divided by the Centronics standard.  In order to ensure
operation of the interface, it is enough to use 8 bits of data
data (D0-D7), data strobe and busy signal
printer (Busy). Now a few words about those signals that
rye are commonly used.

 Data Strobe. When the computersends data to the printer, it
within 5 µs should activate this signal (low level
Ven).  This printer is notified that the data is ready according to
appropriate tires.

 Data D0 - D7. Data is transmitted via these 8 signal lines
from computer to printer. After the Data Strobe signal is established
the printer reads the information.

Acknowledge.  If the printer accepted the values set by the computer
data, then in confirmation it is within approximately 10 µs
keeps this line active (low level).

 Busy. If the printer cannot receive data, then the signal is activated
is changing (high level). This can happen, for example, following
the following cases: when initializing the printer, if the printer prints
symbol, is in the OFF-LINE or PAUSE state, when it appears
internal error or when the end of paper is detected.

 Paper out. This signal (high level) tells the computer
about running out of paper. If you insert a new one into the printer
sheet, the signal is deactivated (low level).

 Select.  Using this signal, the printer tells the computer
ru that it is selected and active. Umany Select printers have
constant value (high level) or does not use at all -
Xia.

 Auto feed. Activation of this signal (low level) causes
advances the paper one line forward in the printer. Usually
it can be fixed at one of two DIP switch levels
chatel.  As a rule, the transition to another line is carried out
programmatically - by outputting certain codes to the port.

 Error.  This signal from the printer can be active (low
level) in the following situations: if the printer is in
OFF-LINE or PAUSE if you run out of paper or while printing
There was an error in the chat.

 Init.  If the signal on this line is active (low level),
ven) within approximately 50-100 μs, then the initiation occurs
The printer's implementation is the same as when it is turned on. In this case,
The print buffer is also cleared.

 Select Input. Activation (low level) and deactivation
The application of this signal is similar to the supply of control codes DC1 (De-
vice Control 1) - select device and DCЗ - cancel selection
devices.

 Ground.  This is the "Body" ("Ground") signal for signalsdata and
control signals.

Table 1. Parallel signals Table 2. Parallel signals
interface (DB-25 connector) interface (Centronics connector
on a computer) on a printer)
╔═════╤════════╤════════════╗ ╔═════╤════════╤══════════════╗
║Cont.│Direction│Signal ║ ║Cont.│Direction│Signal ║
╠═════╪════════╪════════════╣ ╠═════╪════════╪══════════════╣
║ 1 │ Output │Data Strobe ║ ║ 1 │ Input │Data Storbe ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 2 │ Output │Data 0 ║ ║ 2 │ Input │Data 0 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 3 │ Output │Data 1 ║ ║ 3 │ Input │Data 1 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 4 │ Output │Data 2 ║ ║ 4 │ Input │Data 2 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 5 │ Output │Data 3 ║ ║ 5 │ Input │Data 3 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 6 │ Output │Data 4 ║ ║ 6 │ Input │Data 4 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 7 │ Output │Data 5 ║ ║ 7 │ Input │Data 5 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 8 │ Output │Data 6 ║ ║ 8 │ Input │Data 6 ║╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 9 │ Output │Data 7 ║ ║ 9 │ Input │Data 7 ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 10 │ Input │Acknowledge ║ ║ 10 │ Output │Acknowledge ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 11 │ Input │Busy ║ ║ 11 │ Output │Busy ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 12 │ Input │Paper Out ║ ║ 12 │ Output │Paper Out ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 13 │ Input │Select ║ ║ 13 │ Output │Select ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 14 │ Exit │Auto feed ║ ║ 14 │ Input │Auto feed ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 15 │ Input │Error ║ ║ 15 │ - │No connect ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 16 │ Exit │Init ║ ║ 16 │ - │Ground ║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║ 17 │ Output │Select Input║ ║ 17 │ - │Chassis Ground║
╟─────┼────────┼────────────╢ ╟─────┼────────┼──────────────╢
║18-25│ - │Ground ║ ║ 18 │ - │+5V ║
╚═════╧════════╧════════════╝ ╟─────┼────────┼──────────────╢
                              ║19-30│ - │Ground ║╟─────┼────────┼──────────────╢
                              ║ 31 │ Input │Init ║
                              ╟─────┼────────┼──────────────╢
                              ║ 32 │ Exit │Error ║
                              ╟─────┼────────┼──────────────╢
                              ║ 33 │ - │Ground ║
                              ╟─────┼────────┼──────────────╢
                              ║ 34 │ - │Clock ║
                              ╟─────┼────────┼──────────────╢
                              ║ 35 │ Login │Test ║
                              ╟─────┼────────┼──────────────╢
                              ║ 36 │ Input │Select Input ║
                              ╚═════╧════════╧══════════════╝

Share your thoughts about the article