Loren is a good friend of mine, and he sent this to me some time ago.

PRPORT.DOC	10-MAR-2002


                       PARALLEL PRINTER PORT


                         IBM PC REGISTERS

CENTRONICS            STATUS         CONTROL                 CENTRONICS
                      (LPT+1)        (LPT+2)
                      -------        -------
11          |\       |       |      |       |
-- BUSY ----|  >o----|7      |      |    7-5|--- NC 
            |/       |       |      |       | 
10                   |       |      |       |
-- /ACK -------------|6      |      |       |      |\ 
                     |       |      |      4|------|  >o---- /IRQ_EN  (IRQ7)
12                   |       |      |       |      |/ 
-- PE ---------------|5      |      |       |
                     |       |      |       |      |\ 
13                   |       |      |      3|------|  >o---- /SLCT IN  36 
-- SLCT -------------|4      |      |       |      |/ 
                     |       |      |       | 
32                   |       |      |       | 
-- /ERROR -----------|3      |      |      2|--------------- /INIT     31 
                     |       |      |       |  
                     |       |      |       | 
                  ---|2      |      |       |      |\  
                     |       |      |      1|------|  >o---- /AUTOFEED 14 
                     |       |      |       |      |/ 
                  ---|1      |      |       | 
                     |       |      |       |      |\ 
                     |       |      |      0|------|  >o---- /STROBE    1 
                  ---|0      |      |       |      |/ 
                     |       |      |       |
                      -------        -------


LPT = 378h, 278h, etc.

van Gilluwe's "The Undocumented PC" incorrectly states that the /ERROR
input is inverted (a second time). Axelson's "Parallel Port Complete" and
Sam's "Computerfacts" are correct. Eggebrecht's "Interfacing to the IBM
PC" 2nd Edition is so riddled with errors that it cannot be taken
seriously.

BIOS interrupt 17h returns printer status by reading the contents of the
above status register and inverting bits 3 and 6. In other words, when
the BIOS shows bit 3 set (=1) there is an error. (This is verified by the
BIOS listings in IBM's "Technical Reference Personal Computer AT").

Ralf Brown's Interrupt List (release 61) says that PRINTFIX from MS-DOS
5.0 hooks the status function (Int 17h, Func 02h) and always returns
status AH=90h (SLCTed and not BUSY). My observation is that this problem
exists in Windows 98 but not in DOS 5.0 nor in pure DOS under Win98.
Win98 also ruins the status returned by func 0 by permanently setting it
to AH=10h.

-Loren Blaney



All rights reserved
Legal Notice
Copyright © 1984-2008 Forever Young Software
Return to My Home Page