Classic Mac OS debugging output
From Computers Wiki
Jump to navigationJump to search
You can make the Classic Mac OS dump a bunch of debugging output during boot.
Instructions
- Boot into Open Firmware (Command-Option-O-F).
- Since log output is massive, consider logging over the network instead of to the screen:
- Run
dev /packages/telnet. - Run
" enet:telnet,192.168.18.10" io, substituting the IP address as necessary.- On-screen text input and output will end.
- On another computer, telnet into that IP address.
- The screen will blank itself until booting begins.
- Run
- Use the #Bitflags table to choose a debugging configuration.
- Run
dev / 3013FFF encode-int " AAPL,debug" property, substituting the hexadecimal number as necessary. - Run
mac-boot.
Bitflags
From the beginning of the debugging output:
AAPL,debug bit settings (-OR- bits together):
1 * = Print general informative messages.
2 * = Print formatted Mac OS tables (except config/universal info).
4 * = Print formatted config info table.
8 * = Dump Mac OS tables (except config/universal info).
10 * = Print node names while copying the device tree.
20 * = Print property info while copying the device tree.
40 * = Print interrupt-related info.
80 * = Print interrupt tree traversal info.
100 * = Print address resolution info.
200 * = Print NV-RAM info.
400 * = Print Mac OS "universal" info.
800 * = Print "special" node info.
1000 * = Load EtherPrintf utility via parcel for post FCode debugging.
2000 * = Print BOOTP/DHCP/BSDP information.
4000 = Allocate writable ROM aperture.
8000 = Mark Toolbox image as non-cacheable.
10000 * = Print parcel info while copying the device tree.
20000 = Print information on device tree data checksums.
1000000 * = Enable the Nanokernel debugger.
2000000 * = Display the Nanokernel log during boot.
10000000 = Dont attempt to unhibernate system.
40000000 = Halt after end of FCode (useful if outputting to screen).
Adding all the bitflags together that enable logging (anything with an asterisk) gives 3013FFF.
Notes
- This does not work on a tray-loading iMac G3 because
/packages/telnetdoes not exist. - Telnet output starts about two seconds after the screen turns gray. Output then ends, before the Happy Mac even appears.
- When this happens, the following is printed to the screen:
Off to MacOS. The next (and last) call into OpenFirmware is quiesce().
- When this happens, the following is printed to the screen:
- After telnet output ends, a separate NanoKernel Log will appear on screen, get covered by the Welcome to Mac OS dialog, then appear a second time before disappearing entirely with the "Starting up..." text.