From: sysmark@helios.physics.utoronto.ca (Mark Bartelt)
Subject: Re: /dev/plp on PIs
Reply-To: mark@cita.toronto.edu
Organization: University of Toronto Physics/Astronomy/CITA
Date: Tue, 6 Oct 1992 18:50:13 GMT

Yesterday I described a problem with the parallel port on our PIs:  Printers
that work just fine attached to an IBM PC clone don't work on any of the PIs.
Trying to cat something to /dev/plp (with the "lp" stuff turned off, natch),
nothing appears on the printer and the cat (or whatever) command hangs until
aborted with ^C.

[ me ]

|            I doubt that it's a cabling problem (SGI's documentation tells
|  me that the pinout of the parallel port is IBM PC compatible), and it's
|  also not the case of the parallel port on the PI being sick, since all of
|  our PIs behave the same way.

[ Dave Olson ]

| I don't think we phrase it as being PC compatible.  It sure sounds to
| me as though you have a cabling problem, or a device that is very picky
| about its signals, or perhaps you have a long cable (we recommend 8 ft
| or less, as I recall).

As it turns out, the cable is exactly eight feet long.  Also, to quote from
the Personal IRIS Owner's Guide, page C7:

  Parallel Printer    Construction:     Centronics 25-line interface with
                                        full shield attached 360 to solid
                                        metal D shell; IBM PC compatible
                      [ etc. ]

Granted, this section is talking about the *cable* one should use, not the
characteristics of the port itself.  But one could hardly be faulted for
inferring that the interface is IBM PC compatible, eh?

[ me ]

| So I suspect that I've overlooked something.  Is there any reason I can't
| just copy stuff to /dev/plp, given that the lp cruft isn't running?

[ Dave ]

| No, cat'ing a file to /dev/plp should work just fine (and does, for
| the printers we have around here).

Well, at this point I was puzzled.  Then it occurred to me that, besides our
eight PIs, we also have an Indigo, so perhaps I could try the printers there
to see whether the Indigo exhibited the same behaviour.

At first, I was worried, because there is no reference to the parallel port,
anywhere in the IRIS Indigo Owner's Guide, and I feared that perhaps Indigos
came without a parallel port.  But, glancing at the back, I spied a connector
(25-pin D connector), labeled "//", and deciding that this was intended to
mean "parallel" rather than "C++ comment", I gave it a try.

Bingo!  The same printers which work fine on the PC clone and don't work on
the PIs work just fine on the Indigo.

So now, the question is why?  I suspect that there is some signal which the
PI's parallel port hardware expects to see asserted, which the PCs and the
Indigos don't care about.  Anyone care to hazard a guess as to what that may
be?

The documentation isn't a lot of help.  The PI Owner's Guide doesn't give the
pinout for the parallel port, as it does for the serial ports.  And, as I've
already noted, the Indigo Owner's Guide doesn't seem to even acknowledge that
the parallel port exists.  (Why?)

The plp(7) man page gives a superficial overview of the electrical interface,
giving mapping of signal names onto pins, but no description of just what the
signals mean.  If I compare these with the corresponding documentation for an
IBM (a real IBM) parallel interface, most of the signals correspond, but there
are a couple minor differences.

Most curious is the fact that the plp(7) man page says there's a signal called
"RESET" on pin 31.  However, given that the parallel interface on both the PI
and the Indigo is a 25-pin connector, I'd be interested in finding out which
pin that signal is actually mapped to.

Any useful hints, from either SGIers or non-SGIers?  Although there's no great
time pressure involved here, we will likely be getting a Phaser IIsd at some
point, and it's quite possible that we'll want to hook it up to one of our PIs
rather than to our Indigo.  TIA.

Mark Bartelt                                                      416/978-5619
Canadian Institute for                                   mark@cita.toronto.edu
Theoretical Astrophysics                                 mark@cita.utoronto.ca

"Clothes not busy being worn are busy drying."     -     Dylan, on laundry day
             [ singing "It's all right, ma (I'm only bleaching)" ]
Newsgroups: comp.sys.sgi,comp.protocols.tcp-ip.domains