Subject: Re: [netatalk-admins] PPD files on server

From: "Jeremy J. Reichman" <[email-masked]>
Date: Sat, 27 Mar 1999 08:15:14 -0500

The following directions were created for my employer, and as such, I
should mention they are Copyright © 1999 by Rochester Institute of
Technology. If you want to redistribute it, please contact me directly
([email-masked]) and/or send e-mail to [email-masked]. Thanks!

Okay, that said, these are heavily annotated with my own interesting
comments. But the instructions explain how to create and LPR-based
desktop printer queue on a Mac with LaserWriter 8.5.1 or later.

1.	Open the "Desktop Printer Utility" in the "Apple LaserWriter
Software" folder in the "Apple Extras" folder. (You did KEEP the "Apple
Extras" folder, right...?)

2.	Select the "LaserWriter 8" driver in the pop-up menu in the Desktop
Printer Utility's "New" window (which should open by default). You
should see four options:

- Printer (AppleTalk) 
- Printer (LPR) 
- Printer (no printer connection) 
- Translator (PostScript)

3.	Select "Printer (LPR)".

4.	Click "OK." The "Untitled 1" desktop printer queue window appears.
This is where you set the options for your desktop printer queue.
(Sadly, you can't set all of them; you have to go back and do this via
the Finder in a bit. But this is where you start.)

5.	Click on the "Change..." button next to the "PostScriptô Printer
Description (PPD) File" area of the window. Select the PPD file
appropriate to your printer. (If you were connecting via AppleTalk, the
LaserWriter driver would be able to query the printer, asking what PPD
to use. No such luck with LPR printing. That's the fun of almost
everything over TCP/IP ... more setup time on the client end.)

6.	Click on the "Select" button when you've chosen a PPD, to select that
PPD and go back to the print queue window.

7.	Click on the "Change..." button next to the "Internet Printer" area
of the window. A new dialog box with two fields appears.

8.	Enter information in the "Printer Address" field:

- the IP address or host name of the printer, if you're going to print
DIRECTLY to the printer (the printer must support direct TCP/IP
printing, and many do ... Apple printers with a slash in their model
name do (and it's a good way to explain to other people), as does the
8500 ... HP JetDirects do)

- the IP address or host name of the print server (i.e. the Windows NT,
AppleShare IP, or other LPR/LPD server).

9.	Enter the print queue in the "Queue" field:

- use a dummy queue name for printing DIRECTLY to most printers (unless
they have some sort of internal print server, like maybe a DocuTech or something)

- use the EXACT name of the print queue on the print server, spelling
does matter, and case may matter (hint: Windows NT print queues are the
names of the icons for the printers ... that's also what you see in the
Mac Chooser if you have Services For Macintosh turned on ... *that* took
a while to figure out) (print queues can be on Windows NT, AppleShare IP
6, UNIX, OpenVMS, or other servers, and different servers may be more
stringent on what you have to type, so you may need to experiment).

10.	Flit briefly with disaster. (Just kidding.)

11.	Click on the "Verify" button. This just verifies the "Printer
Address" field against your name server, essentially. At least, that's
all it seems to do.

12.	Click on "OK" to return to the desktop printer queue window.

13.	Select "Save As..." from the File menu. Save the printer somewhere
on your hard disk. (Remember, it doesn't have to be directly on your
desktop.) For LPR printers, I try to save them as
"queue_name@server_name" so that my users have an inkling this is an
Internet printer ... it looks like a Internet address. (Hopefully, no
one will try to email to that address, since it's not a mail address...).

Once you've saved the printer, that's it for setup. Now, customize it:

1.	Go to the Finder and select the desktop printer icon.

2.	Select "Change Setup..." from the Printing menu.

3.	Change the setup in the printer setup dialog box. It's not
super-friendly, but once you figure out the the top pop-up menu is
contains printer features, and the bottom one contains options for
whatever feature is selected, you're all set. This is where you'd change:

- printer memory 
- paper trays 
- paper handling (duplexing, stapling) 
- other stuff that's defined in the PPD, but you customize for your
particular printer model and options 
- don't rely on a server's printer queue to be set up properly, and that
doesn't mean the server will tell your computer what features/options
the printer has.

4.	Click "OK" to close the printer setup dialog box.

You're done! Try printing! (And as long as you've customized the desktop
printer icon setup, you'll have access to the features you didn't have
before, like extra memory or duplexing.)

I strongly recommend that you alias the Desktop Printer Utility in the
Control Panels folder, so you can get to it in the Apple menu. I do this
for my clients automatically in a big Installer VISE installer I've
worked on (I use it to create machine-customized disk images for Disk
Copy and Apple Software Restore, or to set up Macs that don't get my
disk image.)

If you don't have Mac OS 8.1, you can still install LaserWriter 8.5.1
separately (you can download it from Apple's Web site, but please read
its release notes for what OSes it works with). Please note: LW 8.5.1,
when installed separately, installs ColorSync 2.1 ... this is outdated
now. So, install the latest ColorSync AFTER the LW driver. (ColorSync
2.5.x is distributed separately, or with the latest Apple Displays
software -- as of version 1.6. The CS 2.5.x installer will remove older
versions automatically.)

Mac OS 8.5 includes a newer LW yet, but the Desktop Printer Utility is
still buried. It appears to be a much faster driver.

AdobePS 8.5.1 is equivalent to LW 8.5.1 (they're built from the same
core). You can have both on your system at the same time. Install
AdobePS first, trash the "PrintingLib" extension, then install LW 8.5.1
(the Apple driver adds to that shared core in the "PrintingLib"), and
then install ColorSync/Apple Displays. AdobePS does not support LPR
printing yet, but does work with Apple's (larger) "PrintingLib."

Note: Since I originally wrote this, I have discovered some issues with
some printers and some types of queues. The one that has affected me
personally is printing to an HP LaserJet 5SiNX through a queue served by
VMS. There, I get an extra page with an error message on it, although
documents otherwise print fine (assuming that extra page doesn't get
bundled in with the collating and duplexing I do). As far as we have
been able to track down, it's an emulation switching issue. It doesn't
happen with other OSes and their queues or most other printers. But it's
an example of the craziness that can happen with LPR that you probably
wouldn't see over AppleTalk.

-- 
Jeremy J. Reichman
Interim HelpDesk Manager of Operations
ISC HelpDesk
Information and Technology Services
Rochester Institute of Technology
Rochester, New York, USA

Voice                       (716) 475-HELP (4357)
TTY                         (716) 475-2810
Fax                         (716) 475-5306
World Wide Web              <http://www.rit.edu/~jjracc/>
Electronic mail             <mailto:[email-masked]>

For computer-related questions at RIT, make the ISC HelpDesk your first
point of contact; it's available by:
-   voice at (716) 475-HELP (4357)
-   TTY at (716) 475-2810
-   electronic mail to "[email-masked]"
-   World Wide Web at <http://www.rit.edu/isc/>
-   walk-up in the Frank E. Gannett Bldg
    (Room 1113, right off the main lobby).

---

From: PayPC System Mail Subscriber <[email-masked]>
Date: Sun, 28 Mar 1999 19:00:54 +1000

Thanks Jeremy, for the excellent summary of how to setup LPR printers under 
LaserWriter 8.5.1-8.6.1

I myself have used that technique, but you spared me the hassle of writing 
how to do it for my other users! :)

I have a question the printer gods on the list can probably answer (I'm sorry 
it's not netatalk-specific, but I have no other people I can ask within easy 
reach).

It's such an annoying little problem too, I'm sure someone has a ready answer 
that's super-obvious to the DTP guys.

Environment:

OS 8.5.1, ColorSync 2.5.1, Viewsonic G810, configured for 9300 K white point, 
1.8 gamma, LaserWriter 8.6, with HP's Laserjet 8.6 PPDs.  Printer is an HP 
Laserjet 4M [PostScript Rev 2011.110, 6MB RAM] 600 dpi.

Application:

Adobe Photoshop 5.0.2, properly informed of my ColorSync profile.

Here's what I do:

I take an image [it's just like a driver's licence photo -- medium light 
background, head-shot, brightness and contrast corrected on my Viewsonic 810 
display.  It's 100 dpi and is Grayscale.

Problem:

When I print it using "default printer screens" as-is, I get a "correct" 
looking printout, but it's "grainy" like a cheap newsletter picture.... I 
suspect it's because it's using 83 lpi screen or something worse.

Now, the real problem comes when I try to be "clever" and do the bitmap 
conversion myself.   I've tried probably 80 different ways....  

from Diffusion Dithering [which seems to do a correct job of converting the 
levels to perceptual "levels" look at as a whole] but alas it prints out 
HORRIBLY dark.  And the "medium light" background [even though the diffusion 
dither is also "medium light" in overall tone, gets printed out as SOLID 
BLACK!

OK, so then I try doing my own screens, however, aside from the 83 lpi 
setting, I can't find one that doesn't leave "tartan plaid" artifacts in the 
image.  I'm using diamond shaped, 45 degree, and yes, I've done the Sqrt(2) 
conversion factor, etc....  Theoretically, 141 lpi should be the optimal lpi 
for my image, no?  (100 dpi input, 600 dpi resulting bitmap).  

Does anyone have any advice for screen angles/lpi or a program to calculate 
these quickly and optimally for: 1) image dpi, 2) target device dpi, etc.  I 
am quite sure this is a blacker "art" than SCSI, but I imagine the print guys 
have figured out the basics.

When I MASSIVELY adjust the "Levels" of the image prior to using Diffusion 
Dithering, (making the image almost totally washed out white), the printout 
just STARTS to get close to be overall recognisable, but it's still quite 
poor in quality.

What am I missing here?  Is my PPD bad?   In all of my tests, I have "Smooth 
Graphics OFF" and HP's Resolution Enhancing Technology OFF.  I also have 
Black & White Colour Matching (as opposed to Colour/Grayscale).

I am almost tempted to write a PCL raster test program to see if it's 
something the printer engine is doing [unlikely] or some weird-ass 
interaction with PostScript and/or the LaserWriter driver [more likely].

Thanks for any help you guys can share,
=Rob=

---

From: Albert Max Lai <[email-masked]>
Date: Sun, 28 Mar 1999 17:51:40 -0500 (EST)

On Sat, 27 Mar 1999, Jeremy J. Reichman wrote:

Of course, since this is the netatalk mailing list, we'll all be printing
to our printers using papd instead of lpd ;-), but there is a bug in the
RedHat lpd. Here's what the bug is: If you don't have a username on the
machine running lpd and the client, the lpd spool will just drop the job
and the job will never get to the printer. (The username from a MacOS
client is the owner name.) The reason this is a bug is because it ignores
the tag to say whether or not to do this (which should be off by default
anyways.) Here's a link to the patch that I found:

<http://www.iet.unipi.it/~romano/linux/tricks.html>

Oh and BTW, I got a message from them stating that it would be fixed in a
future revision of the lpr package.

--
Albert Lai <[email-masked]>           1018D East Campus
Residential Computer Consultant           411 W. 116th St.
Columbia University                       New York, NY 10027
http://www.columbia.edu/~aml61            (212)853-4854

---

From: Stefan Bethke <[email-masked]>
Date: Mon, 29 Mar 1999 16:51:58 +0200

> wouldn't see over AppleTalk.

Just as a small note to this problem:
Some printers (like some HP models) have features which can only be set or
modified (i. e. resolution) by their "native" control language, but not
with the usual PostScript commands. Adobe has amended the PPD format
specifically for this purpose, so a printer driver can include arbitrary
codes at the beginning of the job.

If some program in the path from printer driver to printer (i. e. psf) does
add PostScript code before the submitted job (which is perfectly legal in
terms of the DSCs), the printer sees the %!PS-Adobe line at the start, and
switches to PostScript interpretation. However, if the original job
contains some PCL controls, the interpreter will choke on these (they would
have been interpreted correctly had they been at the start of the job).

The only solution in this case is to modify the printer's PPD to remove any
such non-PostScript commands. Look for *JCL lines in the PPD and remove
them.

Stefan

--
Stefan Bethke
Promo Datentechnik      |  Tel. +49-40-851744-18
+ Systemberatung GmbH   |  Fax. +49-40-851744-44
Eduardstrasse 46-48     |  e-mail: [email-masked]
D-20257 Hamburg         |  http://www.Promo.DE/