[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: printcap, filtering, etc



Richard Harran wrote:
> am having a bit of trouble setting up printcap properly.  Could someone
> who uses the cdj500 gs filters please tell me what to put in
> /etc/printcap, and associated filter.  I have been able to get some

The easiest way is to install magicfilter package, and then run as root
/usr/sbin/magicfilterconfig. It will create a /etc/printcap for your
printer provided there is a filter for your printer. In case there
isn't, then you'll have to create another one. The easiest way is to
modify for your printer an existing filter for a printer similar to
yours.

For example: I have a HP Deskjet 670c (two ink cartridges: black and
color, 600 dpi resolution), but magicfilter package doesn't have a
filter for my printer, and the closest printer with a filter file is HP
Deskjet 550c (two ink cartridges: black and color, 300 dpi resolution).

Thus ...
# cd /etc/magicfilter
# less dj550c-filter
# man gs    (to understand the options, specially the -r)
# man dvips (idem, but now look at the -D option)
# cp dj550c-filter dj670c-filter
# joe dj670c-filter
change the -r300 for -r600 in all the gs lines, and the -D 300 for -D
600 in the dvips line; save the modified file
# magicfilterconfig --force
answer that I have a HP Deskjet 670c (hpdj670c) in /dev/lp0, that my
filter is dj670c (it appears in the list of filters and five minutes ago
it didn't exist), and the my /etc/printcap looks like this:

# > This file was generated by /usr/sbin/magicfilterconfig. <
#
lp|dj|hpdj670c|HP Deskjet 670c:\
        :lp=/dev/lp0:sd=/var/spool/lpd/hpdj670c:\
        :sh:pw#80:pl#72:px#1440:mx#0:\
        :if=/etc/magicfilter/dj670c-filter:\
        :af=/var/log/lp-acct:lf=/var/log/lp-errs:

Note: I say my printer is in /dev/lp0 because I have kernel 2.2.1. For
older versions of kernel the device was /dev/lp1

-- 
Conrado Badenas (Assistant Lecturer)
Department of Thermodynamics. University of Valencia
c/. Doctor Moliner, 50       | e-m: Conrado.Badenas@uv.es
46100 Burjassot (Valencia)   | Phn: +34-63864350
SPAIN                        | Fax: +34-63983385


Reply to: