Subject: success! Re: pap w/DeskWriter
From: Software Development (junkyard@primate.wisc.edu)
Date: Wed Jul 03 1996 - 21:23:48 EDT
> > Has anyone managed to spool to a Macintosh network-connected
> > DeskWriter560C (or any of its kin)? I can create a file of raw printer
> > data using gs(1) and send it to such a DeskWriter560C using pap(1) (I
> > found that I have to add a ^Z to the end of the file to get the last page
> > to eject). All pages print correctly; however, pap never exits, and
> > papstatus(1) reports the printer as "busy" forever. When I eventuall kill
> > off pap, the printer stays "busy" for part of a minute, then returns to
> > its idle state.
>
> I'm trying to do this myself with a DeskWriter 540 under MkLinux and
> I see the same thing (except that the printer just disappears from the
> network after it times out). Has anyone managed to figure out what's
> going on here?
Well, I think I have it working now. I cheated and looked at the
pap source code and discovered an undocumented -E flag that means
not to wait for the final protocol close from the device. Evidently
it was put in there for printers that violate protocol. Anyway, adding
it works to allow me to print to my DW 540 as a fake PostScript printer
using ghostscript (gs) to convert PostScript to DeskWriter-talk.
Here's the lpd input filter I use on my MkLinux box. Any suggestions
for improvement welcome.
#!/bin/sh
# lpd input filter for DeskWriter 540 printer (may work for others)
# - assumes PostScript input is on stdin
# - assumes printer is named in .paprc in printer spool directory
# - uses pap -E to not wait for printer to do device close because
# DeskWriter seems to violate protocol
PATH=/usr/local/atalk/bin:/usr/local/bin:/bin:$PATH
export PATH
gs -q -dNOPAUSE -sDEVICE=cdjcolor -sOutputFile=- - | pap -E
This archive was generated by hypermail 2b28 : Sat Dec 18 1999 - 16:24:08 EST