LaserWriter II baud rate question

Ralph Finch rfinch at caldwr.UUCP
Thu May 18 00:46:17 AEST 1989


In article <1875 at kodak.UUCP>, drl at kodak.com (Daniel R Lance) writes:
. . .
> I have had my LaserWriterIINTX running reliably on /dev/ttya of a 3/260,
> OS 4.0.1, at 38,400 baud for the last week.  It's easy to do:

I called Daniel on the phone and clarified some points:

> 1) Stop the line printer queue.

I.E. type:

lpc
disable lw
stop lw
quit

<substitute your printer name for lw above>

> 2)  Send the following PostScript code to the printer.  (using cat or
> kermit).  This is documented in the LaserWriter IINTX manual from Apple.
. . .

Sort of documented.  I used the following csh script file:
____cut here____
#
# set the Laserwriter IINTX baud rate

cat << EOF | lpr
%!
serverdict begin 0 exitserver
statusdict begin 25 38400 64 setsccbatch
EOF
____cut here____

Cut the above to a file by the name of, say, set_rate.  Then type:
chmod +x set_rate
set_rate

> 3) Change the entry in /etc/termcap to read :br#38400:

/etc/printcap

> 4) Kill -HUP the lpd process.

Sometimes this was necessary, sometimes step 5) alone did the trick.

> 5) Restart the line printer queue.

I.E. type:
lpc
restart lw
enable lw
quit

If you used the kill -HUP <lpd process #> in step 4), to restart type:

/usr/lib/lpd

Here is a file to check your current settings (Postscript material
taken from the Apple LaserWriter IINTX guide, p. 123-124).
____cut here____
#
# get the current settings (status) of the LaserWriterIINTX.

cat << EOF | lpr
%!
/Helvetica findfont 14 scalefont setfont
/cr{show 182 currentpoint 20 sub exch pop moveto}def
/tb{show 300 currentpoint exch pop moveto}def
/Which{5 -1 roll 4 exch sub -1 roll cr
3{pop}repeat}def
statusdict begin 25 sccbatch end 182 650 moveto
exch (Baud  :)tb 10 string cvs cr
(Parity:)tb dup 30 bitshift -30 bitshift
(none-space) (odd) (even) (none-mark) Which
(Handshake:)tb dup 27 bitshift -29 bitshift
(XON/XOFF) (DSR/DTR) (ETX/ACK) (bad value) Which
(Data bits:)tb dup 25 bitshift -30 bitshift
(standard)(7)(8)(bad value) Which
(Stop bits:)tb -7 bitshift 0 eq{(1)}{(2)}ifelse
show showpage
EOF
____cut here____

Treat this in a similar fashion as the set_rate program above.

Ralph Finch
...ucbvax!ucdavis!caldwr!rfinch



More information about the Comp.sys.sun mailing list