[aus.mac] Writing a Printer/Device Driver. - Help

JON@wehi.dn.mu.oz (Jon Eaves) (07/29/90)

G'day Net,
	I have been asked to write a device driver for a new printing task.
I am not sure what is involved but this is what I gather.

1)  The device will be available from the chooser.
2)  When 'Print' is chosen from any application the output will be 
    spooled to a shared folder on a TOPS network.  This output is
    picked up by a daemon style process and acted upon.

The daemon is not my problem, so all I need to know is what is involved with
writing the device driver (if that is the correct term).
Is there any skeleton code available?

I'd appreciate ANY comments because this whole style of programming is new
to me.
--------------------------------------------------------------------------------
  Jon Eaves         
               "As you wish...." - The Princess Bride    

ACSnet    ( jon@wehi.dn.mu.oz )    
UUCP      ( uunet!munnari!wehi.dn.mu.oz!jon )
Internet  ( jon%wehi.dn.mu.oz@uunet.uu.net )
--------------------------------------------------------------------------------

d_volaric@vaxa.cc.uwa.oz.au (07/31/90)

In article <10418@wehi.dn.mu.oz>, JON@wehi.dn.mu.oz (Jon Eaves) writes:
> G'day Net,
> 	I have been asked to write a device driver for a new printing task.

> The daemon is not my problem, so all I need to know is what is involved with
> writing the device driver (if that is the correct term).
> Is there any skeleton code available?

"MacTech Quarterly" Vol 1 No. 2; Summer 1989, page 44 "The Great Printer
Conspiracy". Aptly named. You may have to sell your soul to The Devil to make 
it all work.

The article lists source in 68000 and goes into depth about printer drivers
and their evils. It does not tell ALL the secrets of the way the Mac currently 
performs its printing, but it should be fine for what you're doing.

Also, it just so happens that a friend of mine has typed in the source or
a translation in pascal or something. He may give you what he's done for
your firstborn, pound of flesh or maybe just a disk :-).

> I'd appreciate ANY comments because this whole style of programming is new
> to me.

Get a copy of Inside Macintosh Vols 1-5 (and a draft of Vol 6 if you can get it)
before you even look sideways at programming a Mac. Make sure you've got a good
debugger (Macsbug, TMON), you'll need it.

>   Jon Eaves 
        
Darko Volaric.

tim@efi.com (Tim Maroney) (08/02/90)

In article <10418@wehi.dn.mu.oz> JON@wehi.dn.mu.oz (Jon Eaves) writes:
>	I have been asked to write a device driver for a new printing task.
>I am not sure what is involved but this is what I gather.
>
>1)  The device will be available from the chooser.
>2)  When 'Print' is chosen from any application the output will be 
>    spooled to a shared folder on a TOPS network.  This output is
>    picked up by a daemon style process and acted upon.
>
>The daemon is not my problem, so all I need to know is what is involved with
>writing the device driver (if that is the correct term).
>Is there any skeleton code available?
>
>I'd appreciate ANY comments because this whole style of programming is new
>to me.

There is a newly released (but apparently old) document called "Learning
to Drive" on AppleLink.  This is the long-awaited Apple manual on writing
print drivers for the Mac.  I believe it is under

Developer Services
	Mac Developer Technical Support
		Interim Documentation
			Learning to Drive

Thanks to Luke at MacDTS for pointing this out to me (and for his other
help on a related topic).