| Installing a printer is rather easy for people without postscript printers. The
program apsfilter sets up your printcap so anything that goes through is
converted from postscript to whatever format your 'windows' printer uses. First you
must install apsfilter, I'm assuming you know how to do this. I installed
from a package so things might be a little different if you use ports.
I'm also assuming you already have the printer device in your kernel and that /dev/lpt0
works. See Building
and Installing a Custom Kernel in the FreeBSD
Handbook for more information on modifying your kernel.
Remember, I have the entire ports tree. So it was
easy. See also, Installing a port without installing
the ports. To install apsfilter from the ports, do this:
cd /usr/ports/print/apsfilter
make install
After the install, go to /usr/local/apsfilter [in recent versions
of apsfilter, go to /usr/local/share/apsfilter] and run SETUP.
# su
Password: (if you are not running as root)
# cd /usr/local/apsfilter
# ./SETUP
You will see a bunch of license junk, just nod and say Y. When you finally enter
the config screen, you should see this:
=============================================================
A P S F I L T E R S E T U P -- MAIN MENUE --
=============================================================
currently selected
-------------------------------------------------------------
(D) Available Device Drivers in your gs binary (gs -h)
(R) Ghostscript 5.50 docu about printer drivers (devices.txt)
(1) Printer Driver Selection [ ]
(2) Interface Setup []
For printing the test page:
(3) Print Resolution in "dots per inch" []
(4) Toggle Monochrom/Color (1bpp=b&w) []
(5) Paper Format []
(T) Print Test Page (after step 1-5)
(V) View perf.log (times of print attempts)
(C) ==> Continue printer setup with values shown above
(Q) Quit Setup
Your choice ?
First you should hit 'R' to make sure your printer is supported. If not, I doubt
if you'll find any driver for your printer.
Next, hit '1' to select your printer. A menu will pop up with a list of choices.
I suggest that you look under the Uniprint section (number 8 then 'B') first.
When you have selected your printer you should tell apsfilter what device file you use,
'2' on the main menu. It tells you what the default device files are, and the MSDOS
equivalents. The choice is yours.
If you would like to print a test page, skip 3 and 4, they are automatic. Under 5
choose the paper size of your location, the US is 'letter'. Then hit 'T'.
If everything looks good (note: the colors may be distorted on some printers) hit 'C'.
It will prompt you on what kind of printer, color or monochrome. Then it will
check the permissions on the printer spool. You should see something like this:
drwxrwxrwx 7 root daemon 512 Apr 1 13:34 /var/spool/lpd
If the first thing you see is drwx-r-xr-x then you need to change it so
users can write to it. If you only want certain users to write to it, you should
already know how to set the proper permissions.
After that you'll see some notes on apsfiler and usage, read it if you like. When
it's done, set the permissions to /var/spool/lpd by doing this:
# chmod a+rw /var/spool/lpd
# chmod a+rw /var/spool/lpd/*
# chmod a+rw /var/spool/lpd/*/*
This will let all the users write to the spool directory, to each printer's directory,
and to the lock files.
Then you need to have lpd load on boot. lpd is the printer
daemon that sits around, waiting for somebody to print, then it puts it on the queue so
every prints, but one at a time. Create a file in /usr/local/etc/rc.d/
that looks something like this:
#!/bin/sh
[ -x /usr/sbin/lpd] && /usr/sbin/lpd && echo -n " lpd"
Perhaps you could call this file lpd.sh. This file does the following:
- tests for the existance of the executable
- starts the executable
- prints to the screen
For more information on this, please see Starting stuff at boot
time
Now your printer should work. |