Subject: port-macppc/11435: Open Firmware OS boot select support
To: None <>
From: Y. Takizawa <>
List: netbsd-bugs
Date: 11/06/2000 20:47:09
>Number:         11435
>Category:       port-macppc
>Synopsis:       Open Firmware OS boot select support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    port-macppc-maintainer
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Mon Nov 06 20:47:00 PST 2000
>Originator:     Y. Takizawa
>Release:        1.5 current

	Installing NetBSD/macppc, LinuxPPC and MacOS to my PowerBook G3,
	I wrote an OS boot select script using Forth.
        (Thanks to Mr. Tsubai for Forth programming)
	It is better to describe on the macppc install documents
	for `NewWorld' Macintosh.

	Using SimpleText on MacOS or hfsutils on NetBSD/macppc,
	create a text file with the following code and put on
	the top directory of the first HFS partition (can not
	write CRs on the first lines).

PowerMac2,1 PowerBook3,1
Open Firmware OS Boot Selector
" get-key-map" " keyboard" open-dev $call-method
  00008000 of " boot hd:,\\:tbxi" endof
  00010000 of " boot hd:,yaboot" endof
  00004000 of " boot enet:0" endof
  02000000 of " boot cd:,\\:tbxi" endof
  00002000 of " noop" eval endof
  drop " boot hd:,ofwboot.elf hd:10" 0

	This IS only sample code. Maybe you need some changes
	for adapting to your environments, especially COMPATIBLE
	referring the Open Firmware boot messages. 

	The case values mean `0000ABCD EFGHIJKL MNOPQRST UVWXYZ00''
	which holding down is `1', or `0'. `00008000' means `M', `00010000'
	is `L' and `0C000000' is holding down both `A' and `B' keys,
	for example (I don't know values for space-bar, command and etc.)
	`drop' line is default case.

	Then, boot into the Open Firmware prompt to press down
	Command-Option-O-F keys while booting, type:

		setenv boot-device hd:,bootinfo
		setenv boot-command boot

	which the above text file is named `bootinfo'.

	You can boot MacOS, for example, to hold down 'M' key
	while booting.