1
\ *****************************************************************************
2
\ * Copyright (c) 2004, 2008 IBM Corporation
3
\ * All rights reserved.
4
\ * This program and the accompanying materials
5
\ * are made available under the terms of the BSD License
6
\ * which accompanies this distribution, and is available at
7
\ * http://www.opensource.org/licenses/bsd-license.php
10
\ * IBM Corporation - initial implementation
11
\ ****************************************************************************/
14
s" Executing following boot-command: "
15
boot-command $cat nvramlog-write-string-cr
16
s" boot-command" evaluate \ get boot command
17
['] evaluate catch ?dup IF \ and execute it
18
." boot attempt returned: "
19
abort"-str @ count type cr
20
nip nip \ drop string from 1st evaluate
25
\ Note: The following ESC sequences has to be handled:
29
\ Reads and converts the function key.
31
: (function-key) ( -- n )
41
\ Checks if an ESC sequence occurs.
42
: (esc-sequence) ( -- n )
45
4f OF (function-key) ENDOF
47
key key drop (function-key) ENDOF
54
s" An 's' has been pressed. Entering Open Firmware Prompt"
55
nvramlog-write-string-cr
59
of-prompt? not auto-boot? and IF
65
#include "sms/sms-load.fs"
68
\ Watchdog will be rearmed during load if use-load-watchdog variable is TRUE
69
TRUE VALUE use-load-watchdog?
75
[char] s OF (s-pressed) ENDOF
79
1 OF console-clean-fifo sms-start (boot) ENDOF
90
disable-watchdog FALSE to use-load-watchdog?