Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Status
The first post of this thread is a WikiPost and can be edited by anyone with the appropiate permissions. Your edits will be public.
These are the properties that exist when fcode from rom starts on the emulation:
Code:
[ probe-all
[ NV43
here:FF85D064 

vendor-id               000010DE 
device-id               00000221 
revision-id             000000A1 
class-code              00030000 
interrupts              00000001 
min-grant               00000005 
max-latency             00000001 
subsystem-vendor-id     000010DE 
subsystem-id            0000004D 
devsel-speed            00000001 
fast-back-to-back       
AAPL,interrupts         00000018 
AAPL,slot-name          B1
fcode-rom-offset        00000000 

get subsystem-id
val93f=4D
 
So here is, how far i got now:

Code:
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff8588b0
ABORTvendor-id missing
 ok
0 > words
close           open
 ok
0 > " pci/@e" select-dev r_3 @00007010.l = 82000000
w_3 @00007010.l = ffffffff
r_3 @00007010.l = ff000000
w_3 @00007010.l = 82000000
r_3 @00007014.l = 90000008
w_3 @00007014.l = ffffffff
r_3 @00007014.l = f0000008
w_3 @00007014.l = 90000008
r_3 @00007018.l = 81000000
w_3 @00007018.l = ffffffff
r_3 @00007018.l = ff000000
w_3 @00007018.l = 81000000
r_3 @00007030.l = 80820000
w_3 @00007030.l = ffffffff
r_3 @00007030.l = fffe0001
w_3 @00007030.l = 80820000
r_3 @00007004.w = 4
w_3 @00007004.w = 6
w_0 @00000004.l = 1000000
 ok
0 > 4d encode-int " subsysem-id" property  ok
0 > load-base 1 byte load byte, unknown word
 ok
It aborted because you didn't have the current instance, you can ignore it, once you do select-dev you'll have the current instance and you can't do select-dev until you have the open word.

Anyway, just ignore that error.

What didn't work was load-base 1 byte-load, so do printenv load-base, and use that instead.

4000 1 byte-load
or
600000 1 byte-load
or just whatever you load-base is.
 
vendor-id is a property that Mac firmware inits before calling fcode. Check .properties like I asked, before you run the fcode. I don't think the fcode looks at the rom image.
In the properties of the device @ pci e the vendor-id is present. But it doesn't help, trying to load the test-ROM to it. As soon as the pci-header with the vendor-id is cut, the evaluation just stops the file from loading.

Code:
0 > dev pci/@e  ok
0 > pwd .properties /pci@80000000/pci10de,221@e
vendor-id               000010de
device-id               00000221
revision-id             000000a1
class-code              00030000
interrupts              00000001
min-grant               00000005
max-latency             00000001
devsel-speed            00000001
fast-back-to-back
AAPL,interrupts         00000018
AAPL,slot-name          B1
name                    pci10de,221
compatible              pci10de,221
device_type             display
reg                     00007000 00000000 00000000  00000000 00000000
                        02007010 00000000 00000000  00000000 01000000
                        42007014 00000000 00000000  00000000 10000000
                        02007018 00000000 00000000  00000000 01000000
                        02007030 00000000 00000000  00000000 00020000
power-consumption       00000000 00000000
assigned-addresses      c2007014 00000000 90000000  00000000 10000000
                        82007010 00000000 82000000  00000000 01000000
                        82007018 00000000 81000000  00000000 01000000
                        82007030 00000000 80820000  00000000 00020000

 ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 >
 
What didn't work was load-base 1 byte-load, so do printenv load-base, and use that instead.

4000 1 byte-load
or
600000 1 byte-load
or just whatever you load-base is.
Thanks! Default is 4000. Current is 600000. So i tried 600000. But it still doesn't seem to start loading.

Code:
0 > printenv

VARIABLE            CURRENT             DEFAULT
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?        true                false
real-base           -1                  -1
real-size           100000              100000
virt-base           -1                  -1
virt-size           100000              100000
load-base           600000              4000
pci-probe-list      -40001              -1
screen-#columns     64                  64
screen-#rows        28                  28
selftest-#megs      0                   0
boot-device         ide1/@0:7           /AAPL,ROM
boot-file
diag-device         fd:\diags           fd:\diags
diag-file
input-device        ttya                kbd
output-device       ttya                screen
oem-banner
oem-logo

Code:
0 > dev pci/@e  ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 > words
close           open
 ok
0 > " pci/@e" select-dev r_3 @00007010.l = 82000000
w_3 @00007010.l = ffffffff
r_3 @00007010.l = ff000000
w_3 @00007010.l = 82000000
r_3 @00007014.l = 90000008
w_3 @00007014.l = ffffffff
r_3 @00007014.l = f0000008
w_3 @00007014.l = 90000008
r_3 @00007018.l = 81000000
w_3 @00007018.l = ffffffff
r_3 @00007018.l = ff000000
w_3 @00007018.l = 81000000
r_3 @00007030.l = 80820000
w_3 @00007030.l = ffffffff
r_3 @00007030.l = fffe0001
w_3 @00007030.l = 80820000
r_3 @00007004.w = 4
w_3 @00007004.w = 6
w_0 @00000004.l = 1000000
 ok
0 > 4d encode-int " subsystem-id" property  ok
0 > 600000 1 byte-load  ok
0 >
 
These are the properties that exist when fcode from rom starts on the emulation:
Code:
[ probe-all
[ NV43
here:FF85D064

vendor-id               000010DE
device-id               00000221
revision-id             000000A1
class-code              00030000
interrupts              00000001
min-grant               00000005
max-latency             00000001
subsystem-vendor-id     000010DE
subsystem-id            0000004D
devsel-speed            00000001
fast-back-to-back      
AAPL,interrupts         00000018
AAPL,slot-name          B1
fcode-rom-offset        00000000

get subsystem-id
val93f=4D
Looks a lot like what i get. Except of the fcode-rom-offset and the subsystem-ids.

Could a command like...

Code:
10de encode-int " subsystem-vendor-id" property

...similar to...

Code:
4d encode-int " subsystem-id" property

...help to avoid the aborting?
 
Code:
600000 100 dump

That should dump 100 bytes of the load-base to the screen. Compare it to the ROM you loaded with the load command.
I get a DEFAULT CATCH! for that.

Code:
0 > dev pci/@e  ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 > 600000 100 dump
00600000:
DEFAULT CATCH!, code=fff00300 at   %SRR0: ff80b480   %SRR1: 0000b070
 ok
 
I get a DEFAULT CATCH! for that.

Code:
0 > dev pci/@e  ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 > 600000 100 dump
00600000:
DEFAULT CATCH!, code=fff00300 at   %SRR0: ff80b480   %SRR1: 0000b070
 ok
Apple buggy ass OF!

Try:

Code:
setenv load-base 800000
reset-all

dev pci/@e
load ide0/@0:1,\TEST5.ROM
800000 100 dump
Did you capture the log?
No Serial connection capture the log with, I don't have another Mac with the Old World Serial.

Isn't there some sort of adapter I can use?
 
Last edited:
Apple buggy ass OF!

Try:

Code:
setenv load-base 800000
reset-all

dev pci/@e
load ide0/@0:1,\TEST5.ROM
800000 100 dump
Sadly keep getting the error.

Code:
0 > printenv load-base

VARIABLE            CURRENT             DEFAULT
load-base           800000              4000
 ok
0 > dev pci/@e  ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 > 800000 100 dump
00800000:
DEFAULT CATCH!, code=fff00300 at   %SRR0: ff80b480   %SRR1: 0000b070
 ok
0 >
 
Sadly keep getting the error.

Code:
0 > printenv load-base

VARIABLE            CURRENT             DEFAULT
load-base           800000              4000
 ok
0 > dev pci/@e  ok
0 > load ide0/@0:1,\TEST5.ROM
loader: evaluating FCode[ NV43
here:ff85886e
ABORTvendor-id missing
 ok
0 > 800000 100 dump
00800000:
DEFAULT CATCH!, code=fff00300 at   %SRR0: ff80b480   %SRR1: 0000b070
 ok
0 >
I get that a lot too when I try and dump some bytes from the load-base, not sure why other than a bug in OF 2.x.x

Just to confirm, you only clipped to 0x40( F1 ) when you edited to ROM?

Let's make sure we are on the same page, I get that same error about the Vendor-id too, but the byte-load command sends me down the debug line. So we really need to get a look at what exactly is in your load-base address, because it acts like it's not executing anything.

Just to double check, be sure to use this ROM:
 

Attachments

  • jvt5.rom.zip
    31.1 KB · Views: 63
It aborted because you didn't have the current instance, you can ignore it, once you do select-dev you'll have the current instance and you can't do select-dev until you have the open word.

Anyway, just ignore that error.
So with the Beige G3, you need to load it which should fail because it loads and evaluates. Then you byte-load?
I tried getting floppy to work in emulation but got an exception

What didn't work was load-base 1 byte-load, so do printenv load-base, and use that instead.

4000 1 byte-load
or
600000 1 byte-load
or just whatever you load-base is.
There is a variable load-base in Open Firmware 2.4.

Looks a lot like what i get. Except of the fcode-rom-offset and the subsystem-ids.

Could a command like...

Code:
10de encode-int " subsystem-vendor-id" property

...similar to...

Code:
4d encode-int " subsystem-id" property

...help to avoid the aborting?
The fcode doesn't care about subsystem-vendor-id. Only vendor-id. And it should be set-up already. Maybe the load isn't happening in the correct context.

No Serial connection capture the log with, I don't have another Mac with the Old World Serial.
A Power Mac with USB serial adapter would also work.
 
..., then you just start it from the FCODE offset 0x40 on nVidia ROMs

So you add 0x40 to the load-base:

800000 1 byte-load vs 800040 1 byte-load.
Couldn't this be a solution here in OF 2.4 too? Maybe the entry point could be set directly with the load command and the ROM could be left untouched with the header. So the vendor-id would still be present. For the pci/@e it is. But that doesn't stop the ABORT form happening.
 
So with the Beige G3, you need to load it which should fail because it loads and evaluates. Then you byte-load?
Yes, well load doesn't really fail, tho it aborts, but it gives us the open and close words that we need to get the current instance with select-dev.

Not sure what's going wrong here, some bug in OF 2.5.x that doesn't effect 2.0.x, so without the ability to load from disk in Dingus I can't reproduce it here.

I suppose you could try:

Code:
dev pci/@e
: open true ; : close ;
" pci/@e" select-dev
4d encode-int " subsystem-id" property
load ide0/@0:,\jvt5.rom

But that doesn't work on OF 2.0.x, I still have to issue the load-base byte-load command.

We could also to open-dev to my-self rather than select-dev.

Code:
dev pci/@e
load ide0/@0:1,\jvt5.rom
" pci/@e" open-dev to my-self
4d encode-int " subsystem-id" property
800000 1 byte-load

Check after the byte-load command if you now have two open and close words?

A Power Mac with USB serial adapter would also work.
I can't find the correct one, all I find is USB to PC serial connections, is there some sort of adapter to make that work with the old world serial?
 
Couldn't this be a solution here in OF 2.4 too? Maybe the entry point could be set directly with the load command and the ROM could be left untouched with the header. So the vendor-id would still be present. For the pci/@e it is. But that doesn't stop the ABORT form happening.
You're chasing you tail worrying about the first abort on the vendor-id, I get that too, but it means nothing. Something is going wrong with 1 byte-load and we have no clue what a dump of you load-base looks like.

IMG_0470.jpeg
 
Couldn't this be a solution here in OF 2.4 too? Maybe the entry point could be set directly with the load command and the ROM could be left untouched with the header. So the vendor-id would still be present. For the pci/@e it is. But that doesn't stop the ABORT form happening.
An Open Firmware patch could fix it probably. I would have to look at the load command to see how it can be modified or if it uses lower level commands that don't do an evaluate immediately.

If you really want to work on this load method, then you can try this 128K rom. You can also try flashing it to the card. I don't know if it will fail gracefully if the rom is really 64K, or if it will brick the card. Anyway this rom has the .properties command at the beginning so we can see where in the device tree the load is happening.
 

Attachments

  • 6200 #6.zip
    2.4 MB · Views: 56
At least this should be the case

View attachment 2049766

...and OF version in my case is 2.4.
Sorry yes, Rev 3 ROM is 2.4.x not 2.5.x.

I had this same type of issue with byte-load not doing anything testing some PCI IDE ATA cards in my Beige G3 and loading FCODE from disk. I just gave up because I had a PM9600 along with my many New World Mac's to test in. Some reason it works for me now with the nVidia card, but I didn't do much different, other than figure out that load does load then go, so I make sure I get on the PCI node I need to be one before I do load.

Check to see if you have two open and close words on your nVidia card after 1 byte-load returns OK!
 
So it is trying to run the FCODE from the load-base address, but it's going to abort without any debug info, very odd.

We know it's getting this far:

Code:
external
: open                                                                            \ (dc6)                [0ca 0b7]
    value_db1_0                                                                    \ (db1 0)            [db1]
    0=                                                                            \                    [034]
    if                                                                            \ (0x7)                [014]
        colon_definition_function_db6                                            \ (db6)                [db6]
        colon_definition_function_db3                                            \ (db3)                [db3]
    then                                                                        \                    [0b2]
    value_db1_0                                                                    \ (db1 0)            [db1]
    1+                                                                            \                    [0a6 01e]
    to value_db1_0                                                                \ (db1 0)            [0c3 db1]
    -1                                                                            \                    [0a4]
    ;                                                                            \                    [0c2]


: close                                                                            \ (dc7)                [0ca 0b7]
    value_db1_0                                                                    \ (db1 0)            [db1]
    1                                                                            \                    [0a6]
    <                                                                            \                    [03a]
    if                                                                            \ (0x4)                [014]
        exit                                                                    \                    [033]
    then                                                                        \                    [0b2]
    value_db1_0                                                                    \ (db1 0)            [db1]
    1                                                                            \                    [0a6]
    =                                                                            \                    [03c]
    if                                                                            \ (0xa)                [014]
        0                                                                        \                    [0a5]
        colon_definition_function_d90                                            \ (d90)                [d90]
        colon_definition_function_d97                                            \ (d97)                [d97]
        colon_definition_function_db7                                            \ (db7)                [db7]
    then                                                                        \                    [0b2]
    value_db1_0                                                                    \ (db1 0)            [db1]
    1-                                                                            \                    [0a6 01f]
    to value_db1_0                                                                \ (db1 0)            [0c3 db1]
    ;                                                                            \                    [0c2]

Then it aborts sometime after without any debug info.

Get the .properties of the card before 1 byte-load and after and the words.
 
Last edited:
I can't find the correct one, all I find is USB to PC serial connections, is there some sort of adapter to make that work with the old world serial?
To exclude differences: I'm doing all the stuff over a serial connection but not at the machine itself. Can this cause any problems?
 
I can't find the correct one, all I find is USB to PC serial connections, is there some sort of adapter to make that work with the old world serial?
I made my own adapter for Mac to PC serial connection.
But I also have the Keyspan Twin Serial Adapters USA-28 and USA-28X.

I had this same type of issue with byte-load not doing anything testing some PCI IDE ATA cards in my Beige G3 and loading FCODE from disk. I just gave up because I had a PM9600 along with my many New World Mac's to test in. Some reason it works for me now with the nVidia card, but I didn't do much different, other than figure out that load does load then go, so I make sure I get on the PCI node I need to be one before I do load.

Check to see if you have two open and close words on your nVidia card after 1 byte-load returns OK!

Try these commands on Open Firmware 2.4:

" devicepath\filepath" (load)
Then check load-base contents
load-base 100 dump
Also check
pwd .properties words to make sure load didn't do anything to the context. Then you can byte-load from the offset in the rom where the 0xF1 start fcode is at.
load-base offset + 1 byte-load
 
If you really want to work on this load method, then you can try this 128K rom. You can also try flashing it to the card. I don't know if it will fail gracefully if the rom is really 64K, or if it will brick the card. Anyway this rom has the .properties command at the beginning so we can see where in the device tree the load is happening.
I just tested. Output is somehow different and no errors anymore. (see attached)

But after the byte-load command still nothing happening.
 

Attachments

  • load.zip
    10.2 KB · Views: 68
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.