PATH 
ADC Home > Documentation > Hardware > Device Managers and Drivers > PCI Card Services > Designing PCI Cards and Drivers for Power Macintosh Computers


  

Invoking the User Interface Via Remote Connection

To enter the Open Firmware user interface, restart the target Power Macintosh computer while you immediately and simultaneously press the Command, Option, O, and F keys on its keyboard. (O and F represent Open Firmware.) Release the keys after you see the Open Firmware prompt on the screen or in the case of pre-NewWorld computers, the remote terminal. It should look similar to the following example:

Open Firmware, 3.1.0
To continue booting the MacOS type:
BYE<return>
To continue booting from the default boot device type:
BOOT<return>
ok
0 >

The Open Firmware version number varies upon the target. Macintosh computers that support the New World architecture have Open Firmware version 3.0.x. or greater. Older PCI-based Power Macintosh computers include Open Firmware versions up to 2.0.x.

The " ok " means the Open Firmware Forth interpreter is waiting for keyboard input. The 0 indicates the top of the stack.

If you see the Mac OS boot screen, "Welcome to Macintosh," on the target computer, you may have failed to press the keys quickly enough and should try again.

The Command, Option, O, and F key action just described causes the Macintosh startup firmware to enter the Open Firmware user interface at the point just before initiating an operating system startup process. At this point all FCode that was present on PCI cards has been executed and the assigned-addresses and other standard properties have been added to the device tree. When the user interface is invoked, it sends a bell character and a string identifying Open Firmware and its version number to the remote terminal. It then awaits input from the terminal. The default routes for both output and input devices are through the serial terminal connection.

To move from two machine to one machine mode during an individual session, enter the following redirection words:

0 > " pci2/@f" output \ the path must point to your display node
0 > " kbd" input \ the alias kdb could be " keyboard"

Note: " kbd" is an alias supported on some the machines, others may use " keyboard" instead. But there is no standard alias for display screen. The redirection of output is specific to pre-New World machines with Open Firmware version 2.0 or later. You will have to decide what is the display for the target machine and use that path name.

After the output is directed to the target machine, what you enter at the host for the second word (i.e., input) does not appear on the host display, but on the target display. You can now enter your session on the target machine until you restart your target. Once you restart, your input and output capabilities will again be at the host. To make the redirection change permanent, use the printenv and setenv words. Listing 5-1 shows an example of the display output produced after entering the printenv word and pressing the retun key.

The output shown Listing 5-1 is representative of what you would see if you entered printenv on a current Power Macintosh G3 computer. There are two columns displaying values for the configuration variables; the left column displays current setting; the right column displays the default setting. You must change the environmental variables called input-device and output-device to contain the path name to your keyboard and display, respectively. You use the setenv word followed by the variable name and a new value to change the variables. Then, when you restart your target, you will always be in one machine mode. Of course, since these variables are stored in NVRAM, you can reset them to the default behavior using the Option-Command-P-R keys upon restart.

If the Open Firmware configuration variable auto-boot? is set to false, the Macintosh startup firmware enters the user interface automatically after subsequent system restarts. This makes the Command-Option-O-F key combination unnecessary.

Listing 5-1 Example of printenv output

0 > printenv
-------------- Partition: common -------- Signature: 0x70 ---------------
little-endian?          false               false
real-mode?              false               false
auto-boot?              false               true
diag-switch?            false               false
fcode-debug?            false               false
oem-banner?             false               false
oem-logo?               false               false
use-nvramrc?            false               false
use-generic?            false               false
default-mac-address?    false               false
real-base               -1                  -1
real-size               -1                  -1
load-base               0x800000            0x800000
virt-base               -1                  -1
virt-size               -1                  -1
pci-probe-mask          -1                  -1
screen-#columns         100                 100
screen-#rows            40                  40
selftest-#megs          0                   0
boot-device             hd:5,\\:tbxi        hd:5,\\:tbxi
boot-file
boot-screen
console-screen
diag-device             floppy              floppy
diag-file               diags               diags
input-device            keyboard            keyboard
output-device           screen              screen
mouse-device            mouse               mouse
oem-banner
oem-logo
nvramrc
boot-command            mac-boot            mac-boot
forced-boot
fw-scsicfg
fw-boot-path
default-client-ip
default-server-ip
default-gateway-ip
default-subnet-mask
default-router-ip
boot-script
aapl,pci                Use PRINT-AAPL,PCI to view
ASVP                    30313036 30333030 31373030
ok
0 >

© 1999 Apple Computer, Inc. – (Last Updated 26 March 99)