Open Firmware 2.4 has all the fcodes named so it's really nice to work with.so " fd:,\jvt5.rom" (load) return (load) unknown word on oOF 2.0.x.
For Open Firmware 2.0f1, you need to find the fcode by address (execution token) or fcode number. But fcode number doesn't always work because multiple fcode images can use the same fcode number.
Code:
0 > see load
: load
" load " ^-7DB1C0 init-program ; ok
0 > -7DB1C0 (see)
: ^-7DB1C0
^-7DB5D8 pack drop ['] ^-7DB520 to init-program carret word count ^-7DB6B0
; ok
0 > -7DB6B0 (see)
: ^-7DB6B0
state-valid off ^-7DB8C8 ^-7DB8E0 2!
begin
^-7DB8E0 2@ bl left-parse-string ^-7DB8F8 2! ^-7DB8E0 2! ^-7DB8E0
@ while/if
^-7DB8F8 2@ ['] open-dev catch if
2drop false
then
dup if
dup close-dev
then
else
true
then
until
^-7DB8F8 2@ ^-7DB7A8 ; ok
0 > -7DB6B0 20 - 40 dump
FF824930: FF 81 09 60 4B FE 47 F5 FF 80 F6 88 4B FE 58 95 :...`K.G.....K.X.:
FF824940: 4B FF A3 A9 4B FE 49 B4 FF FF FF 08 A0 B7 08 B2 :K...K.I.........:
FF824950: 96 7E FF FC 7E 68 02 A6 4B FF 1A 39 4B FE 67 DD :.~..~h..K..9K.g.:
FF824960: 4B FF FD D9 4B FF FD BD 4B FE 65 49 4B FE 55 FD :K...K...K.eIK.U.: ok
0 > 8b2 get-token ok
2 > u. 0 ok
1 > u. FF86B3D0 ok
0 > FF86B3D0 (see)
: ^-794C30
3 ^-794C68 ; ok
0 >
But for our purposes, you can use
-7DB6B0 execute
on Open Firmware 2.0f1 instead of (load)
.
Last edited: