Get your printer working with Apsfilter
Written by: MkIII_Supra
What is Apsfilter?
Apsfilter simplifies printing different file formats under Unix.
user@unixhost $ lpr -P720dpi ascii-file.gz LaTeX.dvi.bz2 picture.gif
xfig-file.fig.Z
This commandline shows, that the user doesn't have to know anymore, how
different file formats have to be converted with different Unix utilities,
to get printed on your printer.
So you can relax and simply concentrate on the simple fact, that you want
to print something, not how to pipe data through different Unix utilities.
On to the Installation
Now I am going to give credit here to the appropriate people and web sites. From Linuxnewbie.org, Sensei!
He turned me onto apsfilter, a print manager. It is a lot better than the one that came with Mandrake.
Below is what worked for me.
First thing you need to do is go to
http://www.freebsd.org/~andreas/apsfilter/download.html
and download apsfilter by Andreas Klemm.
Now to install apsfilter follow these directions:
After you download. All of this has to be done as root.
#mv apsfilter-5.1.3.tar.gz /usr/local/lib
#tar -xvzf apsfilter-5.1.3.tar.gz
#cd apsfilter
#./SETUP
Follow the directions of the program from here on out. Now if your
printer is still not working then the next steps are as follows:
#cat /proc/devices
You should see something like this:
1 mem
2 pty
3 ttyp
4 ttyS
5 cua
6 lp
There are more but I think you get the idea. Now here is where it gets
tricky, if you don't see lp anywhere then chances are you did not enable
parallel port support or printer support or both. You will need to go
back into your kernel and recompile
to add those features. Once you can recognize lp after a cat call and
the printer still doesn't work, then go to the next step below!
What I have found with the latest Mandrake installation is that when you
configure your printer is adds the letters lp to 2 lines in your printcap
file under apsfilter. I don't know what the original printcap looked
like because I installed apsfilter before I solved the printer problem.
That's why I tell people to use apsfilter, that and it's a better print
manager than stock.
This is the current set-up for my HP DeskJet 420 in Linux-Mandrake 6.5
(RedHat 6.1), Kernel 2.2.13-22mdk. This set-up allows me to print from
maxwell and StarOffice 5.1 as well as the Internet. I don't know if
this matters or not, but I have no SCSI hardware or interface cards. I
hope this helps! I did all my changes using VI as root. The areas that are
red are the areas I removed to get it to work. In the event
the red doesn't show the changed area will also be underlined. Let me
know if this helps you out!
First thing you want to do is get into your printcap file to do this
simply use the following command:
#vi /etc/printcap [ENTER]
You should see something similar to what I have below. That is my actual
printcap file, take into account that you have different hardware
so...
####
#### Please don't edit this file directly unless you know what you are doing!
#### Be warned that the control-panel printtool requires a very strict format!
#### Look at the printcap(5) man page for more info.
####
#### This file can be edited with the printtool in the control-panel.
###
###
#####PRINTTOOL3## LOCAL cdj500 300x300 letter {} DeskJet500 3 1
###HP Desk Jet:\
### :sd=/var/spool/lpd/lp:\
### :mx#0:\
### :sh:\
### :lp=/dev/lp0:\
### :if=/var/spool/lpd/lp/filter:
# LABEL apsfilter
# apsfilter setup Sat Nov 6 11:26:50 PST 1999
#
# APS_BASEDIR:/usr/local/lib/apsfilter
#
#
ascii |lp1|cdj500-letter-ascii-mono|cdj500 ascii mono:\
:lp=/dev/lp0:\
:sd=/var/spool/lpd/cdj500-letter-ascii-mono:\
:lf=/var/spool/lpd/cdj500-letter-ascii-mono/log:\
:af=/var/spool/lpd/cdj500-letter-ascii-mono/acct:\
:if=/usr/local/lib/apsfilter/filter/aps-cdj500-letter-ascii-mono:\
:mx#0:\
:sh:
#
lp2|cdj500-letter-auto-mono|cdj500 auto mono:\
:lp=/dev/lp0:\
:sd=/var/spool/lpd/cdj500-letter-auto-mono:\
:lf=/var/spool/lpd/cdj500-letter-auto-mono/log:\
:af=/var/spool/lpd/cdj500-letter-auto-mono/acct:\
:if=/usr/local/lib/apsfilter/filter/aps-cdj500-letter-auto-mono:\
:mx#0:\
:sh:
#
lp3|cdj500-letter-ascii-color|cdj500 ascii color:\
:lp=/dev/lp0:\
:sd=/var/spool/lpd/cdj500-letter-ascii-color:\
:lf=/var/spool/lpd/cdj500-letter-ascii-color/log:\
:af=/var/spool/lpd/cdj500-letter-ascii-color/acct:\
:if=/usr/local/lib/apsfilter/filter/aps-cdj500-letter-ascii-color:\
:mx#0:\
:sh:
#
lp|lp4|cdj500-letter-auto-color|cdj500 auto color:\
:lp=/dev/lp0:\
:sd=/var/spool/lpd/cdj500-letter-auto-color:\
:lf=/var/spool/lpd/cdj500-letter-auto-color/log:\
:af=/var/spool/lpd/cdj500-letter-auto-color/acct:\
:if=/usr/local/lib/apsfilter/filter/aps-cdj500-letter-auto-color:\
:mx#0:\
:sh:
#
raw|lp5|cdj500-letter-raw|cdj500 auto raw:\
:lp=/dev/lp0:\
:sd=/var/spool/lpd/cdj500-raw:\
:lf=/var/spool/lpd/cdj500-raw/log:\
:af=/var/spool/lpd/cdj500-raw/acct:\
:if=/usr/local/lib/apsfilter/filter/aps-cdj500-letter-raw:\
:mx#0:\
:sh:
Conclusion
Hopefully this helped to solve you printer problems. If you'll notice, I
am using the HP DeskJet 500 driver. I found that the 400 series drives
were inefficient and actually were not reliable. Below is a list
of drivers that are currently used by other Linux users. They submitted
them so that I could add them to my HELP files. As you can see I gave
credit to the person that submitted their driver / printer combination
solution.
#
Printer Make and Model
Apsfilter driver that worked
Provided By:
1
Hewlett Packard DeskJet 420
Hewlett Packard DeskJet 500
MkIII Supra
2
Cannon BJC-210
BJC-600
Ken Inman
3
|