converting NCR Sys-v serial printer filters to Redhat ES4 usb/parallel/network cups
Anonymous
anonymous at easysw.com
Sun Nov 20 21:51:32 PST 2005
Hi,
We're currently using a NCR SysV 3.02 server and we have
two printers connected to it - an Okidata 9-pin matrix and
two HP LJ4+ printers. This machine is more than 10 yrs old
so we're getting another Intel box running Redhat Linux ES 4
Both printers are currently connected via serial port and
they have their own filters in /etc/lp/interfaces/[printername]
The filters for the HP LJ4+ look like this (the filter for the
Okidata has similar logic but much simpler):
#* BEGIN *
[set some variable and their esc sequence (raw, noraw, manualfeed)]
...
[process user options]
copies=$4
opts=$5
...
for o in $opts
do
case $o in
troff|raw) SET="$SET\033E" ;;
land) SET="$SET\more escape sequences..." ;;
13cpi) ...
legal) ...
mf) ....
esac
done
[process the files]
while [ $i -le $copies ]
do
for file in $files
do
[more processing - this is where the file is 'cat-ed'
to the serial device]
done
i=`expr $i + 1`
done
#*END*
We are planning on getting a new dot-matrix printer (connected via
usb/parallel port) and a new HP 2500N (connected via network).
The printers are supported by CUPS (I checked the database).
My question is: How can I convert the filter function to our new
printers using CUPS? Here are the different lp commands we use
(there's more but I combined most of the options):
1) lp -s -c -o12cpi -omf -dlj4 -n3 file1 file2 file3
2) lp -c -dlj4 -oraw latex-file.lj
Thanks!
JohnF _jfont1992_ @ _yahoo.com_ (pls. omit space and underline if
replying)
More information about the cups
mailing list