sicklebrick wrote:
So I guess if it helps any, here's
0x80012D74 and 0x80013278 to follow for more clues?
You my friend have provided me with a far better understanding of where im at ^^ cheers! Oh and yes eeproms or flash ic's have a cmd to enable write and so forth. its specific to a series of the ic's. So all i need to do is figure out a way to load the rom into ram prior to the xflash application, then patch the cd function to instead goto my roms location in memory and then probably hook back into the xflash app and return to the functions used to physically flash the ic. i think... lol
EDIT: Well i've been at this all morning so far lol(starting with your clues ^^) I went ahead and got no$psx (thanks nocash ^^), and havent used it much as of now. I will use it when testing the patches. But so far i've stumbled cross these subroutines.
- LoadTPage = 80013504
- LoadImage = 8001484C
- StoreImage = 800148AC w/ Subroutine @ 80014608
- MoveImage = 8001490C w/ Subroutine @ 80014608
These subs are interesting to me, though im still not 100% sure if im heading in the right direction? But "image" could be the rom img or some graphics on xflash... which it seems to have a minute amount of. Also Store and Move Image subs share the same nested 80014608 sub.
Heres the 80014608 Subroutine:
Code: Select all
TEXT:80014608
TEXT:80014608 # =============== S U B R O U T I N E =======================================
TEXT:80014608
TEXT:80014608 # Attributes: library function
TEXT:80014608
TEXT:80014608 sub_80014608: # CODE XREF: TEXT:80014754p
TEXT:80014608 # TEXT:800147E4p ...
TEXT:80014608
TEXT:80014608 var_10 = -0x10
TEXT:80014608 var_8 = -8
TEXT:80014608 var_4 = -4
TEXT:80014608
TEXT:80014608 addiu $sp, -0x20
TEXT:8001460C move $t0, $a0
TEXT:80014610 sw $s0, 0x20+var_8($sp)
TEXT:80014614 la $a0, byte_8001D366
TEXT:8001461C sw $ra, 0x20+var_4($sp)
TEXT:80014620 lbu $v1, (byte_8001D366 - 0x8001D366)($a0)
TEXT:80014624 li $v0, 1
TEXT:80014628 beq $v1, $v0, loc_80014644
TEXT:8001462C move $s0, $a1
TEXT:80014630 li $v0, 2
TEXT:80014634 beq $v1, $v0, loc_800146D0
TEXT:80014638 nop
TEXT:8001463C j loc_80014714
TEXT:80014640 nop
TEXT:80014644 # ---------------------------------------------------------------------------
TEXT:80014644
TEXT:80014644 loc_80014644: # CODE XREF: sub_80014608+20j
TEXT:80014644 lh $a1, 4($s0)
TEXT:80014648 lh $v1, (word_8001D368 - 0x8001D366)($a0)
TEXT:8001464C nop
TEXT:80014650 slt $v0, $v1, $a1
TEXT:80014654 bnez $v0, loc_800146C4
TEXT:80014658 nop
TEXT:8001465C lh $a3, 0($s0)
TEXT:80014660 nop
TEXT:80014664 addu $v0, $a1, $a3
TEXT:80014668 slt $v0, $v1, $v0
TEXT:8001466C bnez $v0, loc_800146C4
TEXT:80014670 nop
TEXT:80014674 lh $v1, 2($s0)
TEXT:80014678 lh $a0, (word_8001D36A - 0x8001D366)($a0)
TEXT:8001467C nop
TEXT:80014680 slt $v0, $a0, $v1
TEXT:80014684 bnez $v0, loc_800146C4
TEXT:80014688 nop
TEXT:8001468C lh $a2, 6($s0)
TEXT:80014690 nop
TEXT:80014694 addu $v0, $v1, $a2
TEXT:80014698 slt $v0, $a0, $v0
TEXT:8001469C bnez $v0, loc_800146C4
TEXT:800146A0 nop
TEXT:800146A4 blez $a1, loc_800146C4
TEXT:800146A8 nop
TEXT:800146AC bltz $a3, loc_800146C4
TEXT:800146B0 nop
TEXT:800146B4 bltz $v1, loc_800146C4
TEXT:800146B8 nop
TEXT:800146BC bgtz $a2, loc_80014714
TEXT:800146C0 nop
TEXT:800146C4
TEXT:800146C4 loc_800146C4: # CODE XREF: sub_80014608+4Cj
TEXT:800146C4 # sub_80014608+64j ...
TEXT:800146C4 lui $a0, 0x8001
TEXT:800146C8 j loc_800146D8
TEXT:800146CC la $a0, aSBadRect # "%s:bad RECT"
TEXT:800146D0 # ---------------------------------------------------------------------------
TEXT:800146D0
TEXT:800146D0 loc_800146D0: # CODE XREF: sub_80014608+2Cj
TEXT:800146D0 la $a0, aS # "%s:"
TEXT:800146D8
TEXT:800146D8 loc_800146D8: # CODE XREF: sub_80014608+C0j
TEXT:800146D8 lw $v0, off_8001D360
TEXT:800146E0 nop
TEXT:800146E4 jalr $v0
TEXT:800146E8 move $a1, $t0
TEXT:800146EC lh $a1, 0($s0)
TEXT:800146F0 lh $a2, 2($s0)
TEXT:800146F4 lh $a3, 4($s0)
TEXT:800146F8 lh $v1, 6($s0)
TEXT:800146FC lw $v0, off_8001D360
TEXT:80014704 la $a0, aDDDD # "(%d,%d)-(%d,%d)\n" //Reminds me of *nix DD cmd//
TEXT:8001470C jalr $v0
TEXT:80014710 sw $v1, 0x20+var_10($sp)
TEXT:80014714
TEXT:80014714 loc_80014714: # CODE XREF: sub_80014608+34j
TEXT:80014714 # sub_80014608+B4j
TEXT:80014714 lw $ra, 0x20+var_4($sp)
TEXT:80014718 lw $s0, 0x20+var_8($sp)
TEXT:8001471C jr $ra
TEXT:80014720 addiu $sp, 0x20
TEXT:80014720 # End of function sub_80014608
It would be extremely helpful if i could just take one of the asm lines with offsets and do something to calculate what the variable locations are for "lw $s0, 0x20+var_8($sp)" etc. That would better help me understand whats actually going on in these blocks of instructions. No$PSX seems to do this auto, but im looking for "manual or paper" method to get the locations referenced in these instructions.
The fact is ASM and im still a newb with this hardware and what not lol. I've been making some serious effort on learning from nocash's extremely adv documentation on the psx. I have never seen something as detailed and complex as that documentation XD. gj nocash ^^
EDIT2:
http://problemkaputt.de/psx-spx.htm#mod ... xbooupload
Thats epic nocash. I will be ordering "samples" from Microchip for SST39SF020A-70-4C-PHE && SST39SF040-70-4C-PHE. I plan on making a daughter board for my unit with 1x SST39SF020 && 1x SST39SF040 with a selector switch for /CE. Ill also be making the 74HC541 + DB25 board to add to the first daughter board when i can get some 74HC541's(or just find a PDIP of a Parallel to USB transceiver). Also i will be acquiring SCN2681 ic's for EXP2, and i plan on having the EXP2 internal & might even add a USB Transceiver.
From my experience with hardware development (in which 90% of my work experience has been with embedded systems), nothing is "impossible" but its simple as knowing your requirements for interfacing and with proper implementation from that perspective; Its "possible" to create an extensive "collection" of additional hardware for anything really. But the neat thing here is the psx has several (at least 3) methods of adding additional hardware; To expand upon the the original "legacy" hardware it already contains.
EDIT3:
https://docs.google.com/document/d/1Fal ... sp=sharing
Link to a Possible PIO Card project i conceived ^^.