From owner-freebsd-questions Thu Aug 10 12:50:11 1995 Return-Path: questions-owner Received: (from majordom@localhost) by freefall.FreeBSD.org (8.6.11/8.6.6) id MAA19171 for questions-outgoing; Thu, 10 Aug 1995 12:50:11 -0700 Received: from netcomsv.netcom.com (uucp9.netcom.com [163.179.3.9]) by freefall.FreeBSD.org (8.6.11/8.6.6) with ESMTP id MAA19138 for ; Thu, 10 Aug 1995 12:49:15 -0700 Received: from ssi3000.UUCP by netcomsv.netcom.com with UUCP (8.6.12/SMI-4.1) id MAA13288; Thu, 10 Aug 1995 12:24:51 -0700 Received: by seaysys.com (4.1/SMI-4.1) id AA04778; Thu, 10 Aug 95 14:19:10 CDT From: edward@seaysys.com (Edward E. Elzey) Message-Id: <9508101919.AA04778@seaysys.com> Subject: Re: Printcap and Laser printer To: fadorno@ix.netcom.com (Fred Adorno) Date: Thu, 10 Aug 1995 14:19:10 -0500 (CDT) Cc: kuku@gilberto.physik.rwth-aachen.de, marino.ladavac@aut.alcatel.at, kelly@fsl.noaa.gov, questions@FreeBSD.org In-Reply-To: <199508101832.LAA29873@ix2.ix.netcom.com> from "Fred Adorno" at Aug 10, 95 11:32:05 am X-Mailer: ELM [version 2.4 PL22] Content-Type: text Content-Length: 3243 Sender: questions-owner@FreeBSD.org Precedence: bulk Received from Fred Adorno: > > You wrote: > > > >> > >> You wrote: > >> > > >> >> > >> >> I have not been able to configure my Epson laser printer with > this > >> >> software. It is setup for a single user on a 486DX66 machine. > The > >> >> printer device is lpt0. Please help me!!!!! > >> > > >> >What happens, if you type > >> > > >> >lpr /etc/passwd > >> > > >> >Does anything come out of the printer on a freshly powered up and > >> rebooted > >> >system ?(I'm saying that because the history sometimes can > >> >make things more complicated). > >> > > >> >> > >> >Send me your /etc/printcap > >> > > >> >Consult the file /var/log/lpd-errs (normally). > >> > > >> > > >> >--Chris Christoph P. U. Kukulies kuku@gil.physik.rwth-aachen.de > >> > > >> Thanks for responding, Chris! I did as you ask and I got an error > msg > >> on screen that reads "lpd [158]: cannot execv > >> /usr/libexec/lpr/#!/bin/sh:" > >> > >> My printcap reads: > >> > >> lp|epson|action|laser|Epson Actionlaser 1500:\ > >> :lp=/dev/lpt0:sd=/var/spool/lpd/epson:mx#0:\ > >> :if=/usr/libexec/lpr/#!/bin/sh:\ > >> printf "\033&k3G" > >> exec /bin/cat > >> > >Maybe this 'in-line shell script in printcap is a tricky > >feature but unless I had understood that trick in full > >and were sure that FreeBSD supports feature > >I'd be conservative and wrtoe the if line as follows > > > > :if=/usr/local/bin/lpf:\ > > > >and create that script 'lpf' in /usr/local/bin: > > > >#!/bin/sh > >echo "\033&k3G" > >exec /bin/cat > > > >proviced that the guy who gave you that escape sequence knows what > he's doing. > > > >See what happens then. > > > >> What's the solution? When it prints, I get garbage and it form > feeds > >> forever. When I do the lptest, I only get 1 line of ASCI characters > > >> and it form feeds indefinitely. > >> > > > >--Chris Christoph P. U. Kukulies kuku@gil.physik.rwth-aachen.de > > > I did as you said. Still when I do the lptest, > I get 1 line of ASCII and form feeds forever. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Your printer is not seeing any "carriage return" characters. The echo "\033&k3G" should be telling the printer to add a preceeding each character. It seems that this is not happening. I can think of a couple of reasons this might be. Perhaps the \033 is not being properly expanded into an character. Or, the printer may not be in PCL emulation mode (emulating an HP LaserJet). Or that printer may not be capable of PCL emulation. Do any of the characters "&k2G" show up at the beginning of the line that does print? This would indicate that the is not being handled right. If the printer can be set-up to always translate into , you might try setting that. > I get the feeling also that I should be doing > something with "chmod" and other when I keep changing this printcap. > Show me how to undo all of this and let's start from scratch. The > printer emulates HP III LaserJet, Epson LQ, FX, GL/2. I just want to > be able to print text files, shells, man pages or word processing. Are > my options limited? > -- Edward E. Elzey FreeBSD by avocation, All others by vocation.