Article 8408 of comp.periphs.printers:
Path: cs.utk.edu!darwin.sura.net!math.ohio-state.edu!sol.ctr.columbia.edu!xlink.net!sbusol.rz.uni-sb.de!gs-serv3.dfki.uni-sb.de!dfki.uni-sb.de!wladimir
From: wladimir@dfki.uni-sb.de (Wladimir Minenko)
Newsgroups: comp.periphs.printers
Subject: Re: Print drivers for HPDJ500
Date: 13 Jul 1993 10:23:28 GMT
Organization: DFKI - German Research Center for AI
Lines: 114
Distribution: world
Message-ID: <21u2f0$ojr@gs-serv3.dfki.uni-sb.de>
NNTP-Posting-Host: kik-11.dfki.uni-sb.de
Keywords: HPDJ500 driver

To: bcpa@mala.bc.ca
Subject: Print drivers for HPDJ500 - comp.periphs.printers #4550

In article <1993Jul12.141335.1969@mala.bc.ca>, bcpa@mala.bc.ca writes:
|> Hi there, all!...
|> 
|> We've been in the process of install LINUX on our local machine, and have come
|> across the lack of a Printcap file for our HP Deskjet 500.. I was wondering if
|> anyone out there might have said file, and if they do, whether they could
|> please mailer a copy to us.. If you do, it would be much appreciated...
|> 
|> Thanks for your time...
|> 					Cheers,
|> 					Rich W.
|>

It's also from this group:
_________________________________________________________________
Article: 4492 of comp.periphs.printers
Newsgroups: comp.periphs.printers

Marc:

I tried to mail you this, but all reasonable addresses I could
make out of mapl@dorado.rwth-aachen.de made it bounce :-(


Here's my solution:

Printcap entry: (works fine on SunOS 4.1.3)

3|lp3|deskjet|dj:\
        :lp=/dev/ttya:\
        :sd=/var/spool/lpd/Deskjet:\
        :lf=/var/spool/lpd/Deskjet/log:\
        :af=/var/spool/lpd/Deskjet/acct:\
        :if=/root/dj.if:\
        :sh:\
        :pw#80:\
        :br#19200:\
        :xc#0177777:\
        :ms=ixon,-ixany,raw:


And the filter: (This is a kludge)

#!/bin/sh
# called with
# $0 [-c] -wwidth -llength -iindent -n login -h host accountingfile

TMP=/tmp/djif.$$
trap "/bin/rm $TMP" 0 2 3 11 15

args=$@
while test $# -gt 0
do
  case $1 in
    -w*) width=`echo $1 | sed "s/-w//"`;;
  esac
  shift
done

cat > $TMP     # copy input to tmp file
# PostScript file
if /bin/egrep -s '^%!' $TMP
then
	/bin/echo "E(s1Q		PostScript is not understood by this printer!!"
	exit 2
fi
# PCL file
if /bin/egrep -s '^' $TMP   
then
	/bin/echo -n "E"   # reset printer
	/bin/cat $TMP
	exit 0
fi
# plain text, reset printer, print in draft mode, do accounting
/bin/echo "E(s1Q"
/usr/ucb/fmt -s -${width:=80} $TMP | /usr/lib/lpf $args | unix2dos -ascii
exit 0

(The ^[ I entered with Ctrl-V Esc in vi.)

One day i will transform it, so it only reads the first line.
sh's read interprets the stream, so it did not work. Maybe I
should play with IFS (see man sh) or use csh.

Anyway,

Good Luck

Andre++
-- 
-------------------------------------------------------------------------------
 Mechatronics Research Centre Twente     --     Mobile Autonomous Robot Twente
         adh@wb.utwente.nl -- ahoekstr@cs.utwente.nl -- +31 53 893296
 Twente University  WB/WA  P.O. box 217  NL-7500 AE  ENSCHEDE  THE NETHERLANDS
________________________________________________________________________________

Don't ask how it work. I haven't tested it.

--
Regards

	Wladimir Minenko
	Project KIK-TEAMKOM

	DFKI GmbH		===>	German Research Center for
	Stuhlsatzenhausweg 3		Artificial Intelligence Inc.
	66123 Saarbruecken
	Germany
	Tel. +49-681-302-5294
	Fax. +49-681-302-5297
	e-mail: minenko@dfki.uni-sb.de




 ****************************************************************************

If you are not sure your HP DeskJet 500 is mechanically working, here is
how to invoke the Self-Test.

With the power off, hold down the FONT button.  Keep holding FONT down
while you turn on the power to the printer; hold it down until the
paper feeds for the Self-Test to begin.  The Self-Test takes 3 sheets.

 ****************************************************************************
