Subject: ROM glue under development
To: None <>
From: grantham <>
List: macbsd-development
Date: 09/01/1994 15:58:30
Brad's progress report, September 1, 1994

I've spent the last several evenings (and lunches) hacking together
some Mac ROM glue routines.  So far I've coded
	macrom.c	macromasm.s	macrom.h
	adbsysasm.s	macglobals.h
and changes to
	adbsys.c	locore.s

I've added space and defaults for some of the MacOS low-memory
global variables to locore.s, added an A-trap handler for ROM
and kernel calls to some Mac OS traps, support for calling the
ADBReInit trap to configure ADB, support for using my ADB device
interrupt as the ADB transaction completion routine, and a whole
slew of administrative tidbits.

At this point, I can successfully call A-line traps and return with
the correct result code from my own routines and from a known point
in the ROMs which only contains a RTS.

I'm in the process of ironing out the bugs in the ADBReInit trap,
but I've got it initiating interrupts, so I'm fairly sure that with
a little more investigation I can actually have the ROM routines
handle ADB for me.  (I get two interrupts and I'm stuck in a busy-
loop waiting for a third. I'm probably forgetting to initialize a
global variable.)

My general goal is to use the Macintosh ROMs for some device drivers
that we can't ordinarily implement because of lack of documentation
and just plain laziness, including ADB, floppy, sound, power management,
and NuBus Ethernet.  This means that the keyboard and mouse problem
for IIsi and later machines will have a general solution.

Just so you know what I'm doing.  Comments?

Brad Grantham, >+------+< Happily slaved to NetBSD/Mac68k!
MacBSD : II, IIx, IIcx, IIci, SE/30, IIsi, IIvx -- The list is growing...