Use a StyleWriter II printer on 10.2.X
Jun 03, '03 09:19:30AM
Contributed by: Anonymous
After going through the trials of getting an old StyleWriter II printer working on OSX 10.2, I felt I should publish how I did it for the benefit of others.
[robg adds: Read the rest of the article for the detailed how-to. Note that these steps assume you already have the Developer Tools installed. I have not tested these at all, given that I don't have a StyleWriter!]
Assumptions:
Printer serial port = /dev/cu.printer
Modem serial port = /dev/cu.modem
- Install enscript, gs etc. Get "ESP Ghostscript" (espgs) and install from Gimp-Print
- Install lpstyl StyleWriter driver:
- Grab the StyleWriter Driver
- Type this in the Terminal:
tar -zxvf stylewriter.tar.gz
cd stylewriter
cc -Dunix -o lpstyl lpstyl.c
sudo cp lpstyl /usr/local/bin/lpstyl
- Add serial support for CUPS (Standard doesn't support it):
- Download current (1.1.19) CUPS source from CUPS
- Type this in the Terminal (don't type the "##" line):
tar -zxvf cups-1.1.19.tar.gz
cd cups-1.1.19
./configure
make
## Next two lines should be one row, shown as two for spacing
sudo cp /usr/libexec/cups/backend/serial
/usr/libexec/cups/backend/serial.bak
sudo cp ./backend/serial /usr/libexec/cups/backend/serial
- Test printer. Type the following in the Terminal, and note that it's all one very long line:
enscript --output=- /etc/hosts | gs -q -dBATCH -dPARANOIDSAFER
-dQUIET -dNOPAUSE -sDEVICE=pbmraw -r360x360 -sOutputFile=- - |
lpstyl -f /dev/cu.printer
- Install printer PPD file:
- Visit the StyleWriter II page at linuxprinting.
- Download the stylewriter.ppd file.
- Edit the file with a pure text editor (vi/pico), and add -f /dev/cu.printer to the two *FoomaticRIPOptionSetting lines
- I also set full paths to lpstyl and gs but this is most probably unnecessary.
- Type sudo cp stylewriter.ppd /private/etc/cups/ppd/stylewriter.ppd.
- Install printer script (foomatic-rip)
- Go to Cups-Doc
- Download and save foomatic-rip
- Type sudo cp foomatic-rip /usr/libexec/cups/filter/foomatic-rip
- Type sudo chmod 755 /usr/libexec/cups/filter/foomatic-rip
- Bounce CUPS by typing:
sudo /System/Library/StartupItems/PrintingServices/PrintingServices stop
sudo /System/Library/StartupItems/PrintingServices/PrintingServices start
- Add printer by typing (this is all on one line):
sudo lpadmin -p stylewriter -m /private/etc/cups/ppd/stylewriter.ppd
-v serial:/dev/cu.printer -E
Then visit http://localhost:631/ in your browser and do a test print (can be very slow, be patient, check top for gs and 'perl' activity).
Thanks to:
Comments (18)
Mac OS X Hints
http://hints.macworld.com/article.php?story=20030530110330235