In the moment of writing this HOWTO, the latest version is pnm2ppa-1.03
,
so I will explain about it. I will try to maintain a revision of this HOWTO
whenever a new version is available (but I can't promise it).
Once donwloaded, untar the source code using:
tar -xzvf pnm2ppa-1.03.tar.gz
and you will get a pnm2ppa-1.03
directory. Cd to it.
Compile the software typing:
make
and you will get two binaries: pnm2ppa
and calibrate_ppa
.
The first file is the filter itself, and the second one is a helper for calibration.
NOTE: if you want message in a language other than English, you can edit
the Makefile
and select LANG
to the correct value (actually
available ones are Czech, English, Spanish, French, Italian and Dutch). Man
pages and documentation will yet be in English, but syslog messages will be
in the language you have selected.
Just type
make install
and the binaries will be copied into /usr/local/bin/
and the configuration
file into /etc
.
You need to edit /etc/pnm2ppa.conf
to set some parameters. For
the present, just comment the line
version ERROR # PNM2PPA WIIL *NOT* WORK UNTIUL THIS ENTRY IS REMOVED!!!!
and uncomment the one for your printer, and uncomment the line defining your papersize.
If you are using some BSD-like spooling system (lpd
, LPRng
or any other), you need to follow theses instructions.
Cd to lpd
directory and copy printcap
file to /etc/printcap
:
cp /printcap /etc/printcap
If you had another printer configured in the system, don't copy the file, but add entries to it (anyway, if you got another printer, you probably know what to do).
Create spooler directories and copy scripts using:
./lpdsetup papersize
Where papersize
can be any of: a3, a4, legal, letter
.
Cd to /usr/local/bin/
and edit the files to fit your system. You
will probably only need to edit ascii.if
, if you don't have installed
enscript
and want to use other text-to-Postscript converter (for example,
I use a2ps).
You have now five defined printers in you system: ascii, bw, bweco, color, coloreco
.
You can print in any of them typing:
lpr -Pprinter file
For example, you can print a PostScript file, in economic color mode, using:
lpr -Pcoloreco myFile.ps
One more thing... if you don't provide the -Pprinter
parameter,
the lp
printer is used (called too the "default printer"). If you edit
the /etc/printcap
file, you will see a line as:
coloreco|lp:\
That means that coloreco
and lp
printers are actually
the same, so miss out the -Pprinter
parameter is the same that using
-Pcoloreco
. You can change it to:
coloreco:\
and then add the |lp
to any other printer... For example, changing:
bweco:\
to:
bweco|lp:\
you make lp
the same printer than bweco
.
Test it by printing some text file (lpr -Pascii aFile.txt
) and
some PostScript file (lpr -Pcoloreco anotherFile.ps
).
I don't use PDQ printing system, so I can't explain the installation proccess here.
Copying/pasting from pdq/README.pdq
file:
gs-pnm2ppa is a driver that integrates pnm2ppa into Jacob Langford's simple spool-free printing system PDQ ('Print, Don't Queue').
It will work for the following printers that use the PPA protocol:
HP DeskJet 710C, 712C HP DeskJet 720C, 722C HP DeskJet 820Cse, 820Csi HP DeskJet 1000Cse, 1000Csi
The printer must be installed LOCALLY on the host that runs pdq; translation to the PPA format that the printer accepts must be done on the host to which the printer is physically attached. gs-pnm2ppa cannot be used to print to a PPA printer that is accessed over a network. -------------------------------------------------------------
PDQ currently has a homepage at:
http://pdq.sourceforge.net
The latest release (as of September 2000) is pdq-2.2.1. ------------------------
After installing a version of pdq that does not include this driver, just copy the file 'gs-pnm2ppa' into the pdq ghostscript driver directory (usually /etc/pdq/drivers/ghostscript/), and the file 'dummy' into the interfaces directory (usually /etc/pdq/interfaces). You must be root to do this:
cp gs-pnm2ppa /etc/pdq/drivers/ghostscript cp dummy /etc/pdq/intefaces
Then run 'xpdq' to setup the printer, selecting the driver 'gs-pnm2ppa', and the interface 'dummy'. You must specify The local parallel printer port to which the printer is attached when configuring the driver. You must then return to the 'driver option' screen and select the correct printer model and desired color mode. You may need to exit xpdq to activate the settings you just entered.
Note that the user of the printer must have write permission to the port it is attached to.
Thats all!. ------------------------------------------------------------------ The pnm2ppa homepage is at: http://sourceforge.net/projects/pnm2ppa
send comments/bug reports about gs-pnm2ppa (but not pdq) to:
pnm2ppa_advice@users.sourceforge.net