SUMMARY: Mac to SPARCprinter

From: Bruce Roe (
Date: Sat Feb 01 1992 - 08:55:00 CST

This is a SUMMARY of the responses I got to my posting:

>I am trying to get a SPARCprinter (attached to a SPARCstation2)
>to serve as a printer for AppleTalk and EtherNet connected Macs.
>The reason is the SPARCstation supposidly can serve as a spooler
>and the SPARCprinter is much newer than our antique AppleLaserWriter.
>The SPARCstation2 is running Sun OS 4.1.1 and printer software 1.0.
>I've succeeded in getting CAP (Columbia AppleTalk Package) installed
>and can see the SPARCprinter in the Mac Chooser. However, when I
>try to print a Mac file (created either with MSWord4.0, or EDIT)
>even though I do get output, this output is a page of meaningless
>letters and other symbols.
>It's my guess that the SPARCprinter is *not* recognizing and converting
>the Mac PostScript to something the SPARCprinter can successfully deal
>with. At this point I'm clue-less as to where to look or what magic
>incantation(s) to use.
>Has anyone out there is beautiful net-land gotten Mac file printed
>through a SPARCstation/SPARCprinter? If so, please clue me in.

The first thing is getting CAP to compile, etc correctly. For that
the CAP documentation is rather straight forward and at least a
molecular biologist like me could figure out. The key here
for my situation here was to realize that I should say YES when
prompted with the question regarding if I would use Native Ether Talk.
If all this works then you should be able to see your printer from
the Mac chooser. If not, most likely the path given in CAP or LIB
in start-cap-servers or one of the options for lwsrv was incorrect.
As I said above, this was working at the time of my posting but I
was getting garbage as a printout. Read on if you are not of faint
heart. BTW, you should be su for all this.

Then read the README file in the source file ../applications/lwsrv
Sounds like something very logical to do but several responders
to my question suggested this and I thank them since I didn't
know which of the zillion README files contained the info I needed.
However, read carefully as the info is very cryptic and you are
not explicitly told to create a directory called "procsets".
So, one needs to do an mkdir for ${LIB}/procsets (where ${LIB}
is defined in start-cap-servers) as without this directory all
is lost.

Once you've got this directory made and correctly pointed to
in start-cap-servers, you're almost home free. Run start-cap-servers,
and print a test file from the Mac to the SPARCprinter. Garbage
will be printed but don't give up. Go back an read the README
file in ../applications/lwsrv because you now have to edit the
file which now has appeared in the ${LIB}/procsets directory.

Editing is somewhat of a problem since you can't use vi and will
have to use textedit (which if you're a Mac person ain't so bad).
Delete the stuff as directed in the ../applications/lwsrv/README
file and save the edited file. If you've deleted the appropriate
lines then all should be fine. So go back to the Mac and try to
print your test file again. For me, at least, it worked just as
it should and the output now was real text just as it was supposed
to be.

Below is a copy of my start-cap-servers file with some comments
in it.

------------------ start-cap-servers -----------------------

# start-cap-servers file
# which is started from '/etc/rc.local' at boot time


LWARGS="-a ${LIB}/procsets -f ${LIB}/LWPlusFonts -A off "

# Start UAB first if used, uab is not used because during
# the CAP compile, said yes when
# asked if Native Ether Talk would
# be used.
# /usr/local/cap/uab
# sleep 10

# Otherwise start aarpd first for Native EtherTalk
${CAP}/aarpd "le0" "chem"

# uncomment the next line for positive feedback during de-bugging
# echo "aarp started"
# allow atis to startup before other CAP programs

# uncomment the next line for positive feedback during de-bugging
# echo "atis started"
# Make this 15 seconds or more if using aarpd because aarpd prints
# out stuff to the screen which obscures the login prompt and looks
# ugly.
sleep 25

${CAP}/lwsrv -n "dna1sparcprinter" -p dna1sparc ${LWARGS} -T "quote8bit" -T
"makenondscconformant" -l /usr/spool/dna1sparc/logfile

# End of start-cap-servers
------------------------------- cut here ---------------------------------

The following are the personal messages I received which set me going in
the right direction. Many thanks to all who responded.
From: IN%"" "Frank Terhaar-Yonkers"

I've been doing it for a long time ...
I start lwsrv with the following:

LWARGS="-T quote8bit -T makenondscconformant -a ${LIB}/procsets
 -f ${LIB}/LW+Fonts"
${CAP}/lwsrv -l /usr/people/fty/lwsrv.log -n "Viz Lab SPARCprinter"
 -p ps4 -h $}

You need to explore the "prepfix" command to process the postscript
procsets sent from the Mac and store them in the "-a" directory

cheers - Frank
From: IN%"" "Bruce Perkins"

We have a Sparcprinter running via CAP.
The program "lwsrv" which controls CAP printing to UNIX is invoked as:
        LWARGS="-a ${CAP}/procsets -T crtolf -T makenondscconformant -h"
        ${CAP}/lwsrv -n "Computer Lab" -p sparc -f ${CAP}/LWPlusFonts ${LWARGS}

The other thing needed is the Procset/AppleDict stuff. The README file
in the source directory for lwsrv tells you how to modify the Procsets
that are "captured" by lwsrv in "/usr/local/cap/procsets". As these contain
"long" records with no CR you will have to use textedit rather than vi.

We have several Unix printers, NewsPrint and TranScript driven hooked up
this way via CAP. We also use MAC LaserWriters from the Sun side routinely.
Good luck,

| Bruce Perkins CSIRO Division of Geomechanics |
* PO. Box 54 Mt. Waverley *
| Tel: (+61) 03 811 1233 Victoria, Australia, 3149 |

From: IN%""

Make sure you're starting your lwsrv up like the following:

/usr/local/cap/lwsrv -T quote8bit -n "SCSD rocky Laser" -p ps -f
/usr/local/cap/LWPlusFonts -a /usr/local/cap

Note that the above is all on one command line....

Good luck......

Dave Pascoe    |    GTE Gov't. Systems/SCSD
KM3T                    |    (617) 455-5704
From:   IN%""

You need to run the Mac output through a program called macps. It adds a header which makes everything works.

This is from the macps documentation

This is how Mac printing works. When a Mac talks to a LaserWriter, it asks if the LaserWriter has had a LaserPrep file downloaded to it. A LaserWriter that is first powered up, has no such LaserPrep file, and so the Mac downloads it and makes the LaserPrep file resident in memory. Then the actual print file is sent to the LaserWriter. Subsequent print requests need not download the LaserPrep file, unless it is a different version.

Since a LaserWriter connected to a Unix system usually does things other than Mac printing, it is unwise to make LaserPrep files resident in memory so that other PostScript jobs have less memory to work with. What prepfix does is to modify a LaserPrep file so that, among other things, it does not make itself resident in memory. Thus, the LaserPrep file must be downloaded for each Mac print job. This is the function of macps, to automatically append the appropriate LaserPrep file.

Macps should be available from most good ftp sites. _ _ _ _ _ Michael Gordon - OR | |_| |_| |__| |_| | | . . . . . . | It's not an optical illusion, it just looks like one |_________|~~|_____| ======================================================================== From: IN%"optigfx!jans@uunet.UU.NET" Bruce, I saved this a while back...hope it helps

Submitted-By: Ed Moy <> Posting-Number: Volume 25, Issue 30

Archive-Name: macps

Macps is a Unix program that takes an uploaded PostScript file created on a Macintosh (by typing Command-F at the LaserWriter dialog box; see macps.1 for more details) and includes an appropriately modified LaserPrep file so that the result can be sent to a PostScript printer X>From Unix. The LaserPrep file contains macros used by the PostScript generator on the Macintosh.

..< i've deleted the shell archive file as 1) it is rather large and 2) i did not need to use it However, after studying the MacPS shell, it seems that this is doing what I described above but from the Mac end. I'll re-post the MacPS shell as a separate message for those who what to take a look at it.> Many Many Thanks again to those who responded. --bruce - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ Bruce A. Roe Professor of Chemistry and Biochemistry / / University of Oklahoma INTERNET: \ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:06:35 CDT