Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 Dec 1996 20:29:15 +1100 (EST)
From:      Joel Sutton <suttonj@interconnect.com.au>
To:        Robert Burns <rjburns@proceco.com>
Cc:        questions@freebsd.org
Subject:   Re: Canon BJC-210 printcap
Message-ID:  <Pine.BSF.3.95.961205182439.292F-100000@solsbury-hill.home>
In-Reply-To: <199611222227.OAA16776@zen1.lanzen.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Robert,

I've been catching up on my email and I noticed that your question didn't
appear to have an answer. I hope I'm not to late. If I am then at least
this will go into the mail archive.  :->

On Fri, 22 Nov 1996, Robert Burns wrote:

> Has anyone managed to configure a filter that works for the bubblejet
>  210?  I can't seem to get the necessary control codes from Canon and this
> printer does not have any dip switches.

I have set up two different print queues on my system - one for plain text
(lp) and one for postscript (ps).

My printcap file looks something like this:

lp|line printer:\
	:lp=/dev/lpt0:sd=/var/spool/lpd/lp:lf=/var/log/lpd-errs:sh:\
	:pw=80:pl=66:if=/usr/local/sbin/lp-bjif:

ps|Postscript Printer:\
	:lp=/dev/lpt0:sd=/var/spool/lpd/ps:lf=/var/log/lpd-errs:sh:\
	:if=/usr/local/sbin/ps-bjif:

Most of the above can be tailored to your own needs but the important
option is the if=<whatever>. I've created two scripts which look like
this.

lp-bjif:

#!/usr/local/bin/perl
#
# Cannon BJC-210 
#

while (<STDIN>) {

    $_ =~ s/\n/\r\n/g ;
    print $_ ;

}

print "\f" ;
#
# EOF

This is a simple perl script which does crlf changes and drops a form
feed on the end so that the printer ejects the paper. Probably could be
improved. You could re-write using sed if you don't like perl. 

#!/bin/sh
#
# Cannon BJC-210 Postscript filter script
#
#

/usr/local/bin/gs -dSAFER -dNOPAUSE -q -sDEVICE=bj200 -r360 -sOutputFile=- -

exit 0
#
# EOF

This is the bare bone minimum filter as outlined in the ghostscript
documentation. I find that it does a reasonable job of producing output
but when I need letter quality text then I print directly from one of my
windows 95 boxes.

You'll need to make both scripts publically executable but NOT writable.
Fingers crossed and using lpr should produce some decent results. 

Also, I found a number of the printer codes in the BJC-210 Dos manual for
the printer.

I hope this helps. Good luck,

Joel...





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.95.961205182439.292F-100000>