Editing Hardware Registers
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
= Introduction = | = Introduction = | ||
On the PSP, except interruptions, almost all the interaction with the hardware is done through memory accesses to "hardware registers" located at the 0xBC000000~0xBFFFFFFF range (actually 0x1C000000~0x1FFFFFFF to which we add the 0x4 uncached flag and the 0x8 kernel flag). Which is the reason why documenting this is vital to understand the PSP hardware. | |||
= | = 0x07F00000: L2 cache = | ||
If we believe in the sysmem NIDs, 04g+ seem to have a "L2" cache we can send commands (writeback/invalidate/probe) to through this address. | If we believe in the sysmem NIDs, 04g+ seem to have a "L2" cache we can send commands (writeback/invalidate/probe) to through this address. | ||
0x07F80000~ also exists. | |||
TODO need more info. | TODO need more info. | ||
Line 300: | Line 300: | ||
| 0xBC000044 || 32 || RW || Hardware register user read/write enable (range unknown) | | 0xBC000044 || 32 || RW || Hardware register user read/write enable (range unknown) | ||
|- | |- | ||
| 0xBC000048 || 32 || RW || | | 0xBC000048 || 32 || RW || Hardware register user read/write enable (range unknown) | ||
|- | |- | ||
| 0xBC00004C || 32 || | | 0xBC00004C || 32 || RW || Hardware register user read/write enable (range unknown) | ||
|- | |||
|} | |||
Granularity that these work on is not known. For each 1 bit an IO range is exposed to usermode for Read/Write. To find the usermode address, subtract 0x60000000 from the kernelmode one. | |||
{| class="wikitable sortable" | |||
|- | |||
! Physical Address !! Size !! R/W !! Description | |||
|- | |- | ||
| 0xBC000050 || 32 || ? || Reads 0x07EFFFFF | | 0xBC000050 || 32 || ? || Reads 0x07EFFFFF | ||
Line 431: | Line 439: | ||
Bit 1 = ATA HDD | Bit 1 = ATA HDD | ||
Bit 4 = | Bit 4 = ? | ||
Bit 7 = ? | Bit 7 = ? | ||
Line 451: | Line 459: | ||
Bits 6-11 = UART 0-5 | Bits 6-11 = UART 0-5 | ||
Bits 12-15 = APB ( | Bits 12-15 = APB (?) 0-3 | ||
Bits 16-17 = Audio 0-1 | Bits 16-17 = Audio 0-1 | ||
Bit 22 = SIRCS (?) | |||
Bit 22 = SIRCS ( | |||
Bit 23 = GPIO | Bit 23 = GPIO | ||
Line 498: | Line 498: | ||
| 0xBC100064 || 4 || RW || SPI clock select | | 0xBC100064 || 4 || RW || SPI clock select | ||
|- | |- | ||
| 0xBC100068 || 4 || RW || | | 0xBC100068 || 4 || RW || 0xF - PLL get/set out select | ||
|- | |- | ||
| 0xBC100074 || 4 || RW || Unknown | | 0xBC100074 || 4 || RW || Unknown | ||
|- | |- | ||
| 0xBC100078 || 4 || RW || I/O enable | | 0xBC100078 || 4 || RW || I/O enable (?) (TODO: verify indices) | ||
Bit | Bit 0 = NAND | ||
Bit 1 = USB | |||
Bit | Bit 2 = ATA | ||
Bits 3-4 = Memstick Interface | |||
Bit | Bit 5 = LCDC | ||
Bit | Bit 6-7 = Audio | ||
Bit | Bit 8 = IIC | ||
Bit | Bit 9 = SIRCS | ||
Bit | Bit 10 = Audio? | ||
Bit 11 = KEY | |||
Bit 12 = PWM | |||
Bits | Bits 13-18 = UART | ||
Bits 19-24 = SPI | |||
|- | |- | ||
| 0xBC10007C || 4 || RW || Either GPIO pin enable, or GPIO pin direction | | 0xBC10007C || 4 || RW || Either GPIO pin enable, or GPIO pin direction | ||
Line 579: | Line 566: | ||
|} | |} | ||
= 0xBC200000: | = 0xBC200000: System Controller? = | ||
{| class="wikitable" | {| class="wikitable" | ||
Line 588: | Line 575: | ||
! Description | ! Description | ||
|- | |- | ||
| 0xBC200000 || 4 || RW || | | 0xBC200000 || 4 || RW || Unknown (used by sceSysreg_driver) | ||
|- | |- | ||
| 0xBC200004 || 4 || RW || | | 0xBC200004 || 4 || RW || Unknown (used by sceSysreg_driver) | ||
|} | |} | ||
Line 607: | Line 589: | ||
! Description | ! Description | ||
|- | |- | ||
| 0xBC300000 || 4 || RW || | | 0xBC300000 || 4 || RW || Unknown | ||
|- | |- | ||
| 0xBC300004 || 4 || RW || Flags for the first 32 interrupts | | 0xBC300004 || 4 || RW || Flags for the first 32 interrupts (see below for the list of interrupts) | ||
|- | |- | ||
| 0xBC300008 || 4 || RW || Mask for the first 32 interrupts | | 0xBC300008 || 4 || RW || Mask for the first 32 interrupts (see below for the list of interrupts) | ||
|- | |- | ||
| 0xBC300010 || 4 || RW || | | 0xBC300010 || 4 || RW || Unknown | ||
|- | |- | ||
| 0xBC300014 || 4 || RW || Flags for the next 32 interrupts | | 0xBC300014 || 4 || RW || Flags for the next 32 interrupts | ||
Line 619: | Line 601: | ||
| 0xBC300018 || 4 || RW || Mask for the next 32 interrupts | | 0xBC300018 || 4 || RW || Mask for the next 32 interrupts | ||
|- | |- | ||
| 0xBC300020 || 4 || RW || | | 0xBC300020 || 4 || RW || Unknown | ||
|- | |- | ||
| 0xBC300024 || 4 || RW || Flags for | | 0xBC300024 || 4 || RW || Flags for other interrupts? | ||
|- | |- | ||
| 0xBC300028 || 4 || RW || Mask for | | 0xBC300028 || 4 || RW || Mask for other interrupts? | ||
|- | |- | ||
|} | |} | ||
Line 661: | Line 643: | ||
| 13 || KEY | | 13 || KEY | ||
|- | |- | ||
| 14 || IrDA | | 14 || IrDA | ||
|- | |- | ||
| 15 || Systimer 0 | | 15 || Systimer 0 | ||
Line 686: | Line 668: | ||
|- | |- | ||
| 26 || USB_MAIN | | 26 || USB_MAIN | ||
|- | |- | ||
| 30 || Display VSync | | 30 || Display VSync | ||
Line 838: | Line 816: | ||
|- | |- | ||
| 0xBC50003C || 4 || RW || Same as above, for hardware timer 3 | | 0xBC50003C || 4 || RW || Same as above, for hardware timer 3 | ||
|- | |- | ||
| 0xBC5003D0 || 4 || RW || Same as 0xBC500000, but with the current PSP's system time value. A timer's current count is computed by subtracting the timer's base time (the init time point) from this value. | | 0xBC5003D0 || 4 || RW || Same as 0xBC500000, but with the current PSP's system time value. A timer's current count is computed by subtracting the timer's base time (the init time point) from this value. | ||
Line 873: | Line 843: | ||
|- | |- | ||
|} | |} | ||
= 0xBC700000: ? = | |||
= 0xBC800000: DMACPlus = | = 0xBC800000: DMACPlus = | ||
Line 999: | Line 971: | ||
|} | |} | ||
== | == Unknown == | ||
{| class="wikitable" | {| class="wikitable" | ||
Line 1,008: | Line 980: | ||
! Description | ! Description | ||
|- | |- | ||
| 0xBC800180 || | | 0xBC800180 || ? || ? || Unknown | ||
|- | |- | ||
| | |} | ||
= 0xBC900000: DMAC related = | |||
= 0xBCA00000: DMAC related = | |||
= 0xBCC00000: VME Control = | |||
These can only be accessed from the ME CPU. | |||
{| class="wikitable" | |||
|- | |||
! Address | |||
! Size | |||
! Read/write | |||
! Description | |||
|- | |||
| 0xBCC00010 || 4 || RW || VME reset: writing anything here causes the VME to reset; it reads 0xFFFFFFFF while resetting, and 0 when reset is complete | |||
|- | |- | ||
| | | 0xBCC00030 || 4 || W? || Unknown, 8 is stored there when the ME boots | ||
|- | |- | ||
| | | 0xBCC00040 || 4 || W? || Unknown, 2 is stored there when the ME boots | ||
|- | |- | ||
| | | 0xBCC00070 || 4 || W? || Unknown, 1 is stored there when the ME boots | ||
|- | |- | ||
|} | |} | ||
= | = 0xBD000000: DDR? = | ||
= 0xBD100000: NAND Flash = | |||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
! Address | ! Address | ||
! Size | |||
! Read/write | |||
! Description | |||
|- | |- | ||
| | | 0xBD101000 || 4 || R || NAND control | ||
Bit 16 = read ECC (0 = don't calculate, 1 = calculate) | |||
Bit 17 = write ECC (0 = don't calculate, 1 = calculate) | |||
|- | |- | ||
| | | 0xBD101004 || 4 || R || NAND status | ||
Bit 0 = status (0 = busy, 1 = ready) | |||
Bit 7 = write protection (1 = write protected) | |||
|- | |- | ||
| | | 0xBD101008 || 4 || W || NAND command | ||
0x00/0x01 = read (1?) | |||
0x50 = read (2?) | |||
0x90 = read ID | |||
0xFF = reset | |||
0x80, or 0x10 at 2nd cycle = page program | |||
0x00, or 0x8A at 2nd cycle = copy-back program | |||
0x60, or 0xD0 at 2nd cycle = block erase | |||
0x70 = read status | |||
|- | |- | ||
| | | 0xBD10100C || 4 || W || NAND address. | ||
Bits 10-26: page to access. | |||
Possibly just LBA >> 1? | |||
|- | |- | ||
| | | 0xBD101014 || 4 || W || NAND reset? (bit 0) | ||
|- | |- | ||
| | | 0xBD101020 || 4 || W || NAND DMA address | ||
Bits 10-26: page to access during DMA. | |||
Possibly just LBA >> 1? | |||
|- | |- | ||
| | | 0xBD101024 || 4 || RW || NAND DMA control | ||
Bit 0 = DMA transfer progress (0 = stopped, 1 = running) | |||
Bit 1 = transfer direction (0 = NAND -> MEM, 1 = MEM -> NAND) | |||
Bit 8 = page data transfer enabled | |||
Bit 9 = spare data transfer enabled | |||
|- | |- | ||
| | | 0xBD101028 || 4 || R || NAND DMA status | ||
|- | |- | ||
| | | 0xBD101038 || 4 || RW || NAND DMA intr? | ||
|- | |- | ||
| | | 0xBD101200 || 4 || RW || NAND resume? (0x0B040205 to resume) | ||
|- | |- | ||
| | | 0xBD101300 || 4 || RW || NAND serial data | ||
|- | |- | ||
| | |} | ||
= 0xBD200000: MemoryStick = | |||
| | = 0xBD300000: WLAN = | ||
= 0xBD400000: Graphics Engine = | |||
{| class="wikitable" | |||
|- | |- | ||
! Physical Address !! Size !! R/W !! Description | |||
|- | |- | ||
| | | 0xBD400000 || 4 || RW || RW bit 1: set to 1 to reset, wait until bit is 0 to know the GE has been reset | ||
|- | |- | ||
| | | 0xBD400004 || 4 || RW? || Unknown (accessible through sceGeSet/GetReg() and passed to the interrupt handlers but unused) | ||
|- | |- | ||
| | | 0xBD400008 || 4 || R || RO bits 0x0000FFFF: shifted left by 10, gives the EDRAM hardware size (sceGeEdramGetHwSize()) (only used for tachyon < 0x00500000) | ||
|- | |- | ||
| | | 0xBD400100 || 4 || RW || RW bit 0x001: 0 = stopped, 1 = running | ||
= | R bit 0x002: 0 = branching condition true, 1 = false | ||
R bit 0x100: 1 = is at depth 1 (or 2) of calls | |||
R bit 0x200: 1 = is at depth 2 of calls | |||
|- | |- | ||
| 0xBD400104 || 4 || RW? || Unknown (accessible through sceGeSet/GetReg() but unused) | |||
|- | |- | ||
| | | 0xBD400108 || 4 || RW || Address of the display list currently being run | ||
|- | |- | ||
| | | 0xBD40010C || 4 || RW || Stall address of the display list (0 = no stall address) | ||
|- | |- | ||
| | | 0xBD400110 || 4 || RW || First return address (after the first CALL command) | ||
|- | |- | ||
| | | 0xBD400114 || 4 || RW || Second return address (after the second CALL command) | ||
|- | |- | ||
| | | 0xBD400118 || 4 || RW || Address of vertices (for bezier etc) | ||
|- | |- | ||
| 0xBD40011C || 4 || RW || Address of indices (for bezier etc) | |||
|- | |- | ||
| | | 0xBD400120 || 4 || RW || Address of the origin (set by ORIGIN, destination address for JUMP/BJUMP/CALL after adding BASE and the address specified in the command) | ||
|- | |- | ||
| | | 0xBD400124 || 4 || RW || Same as above, for the first call | ||
|- | |- | ||
| | | 0xBD400128 || 4 || RW || Same as above, for the second call | ||
|- | |- | ||
| | | 0xBD400200 || 4 || RW || Bit 1 set by sceGeSetGeometryClock(), exact usage unknown | ||
|- | |- | ||
| | | 0xBD400300 || 4 || RW || Unknown (accessible through sceGeSet/GetReg() but unused) | ||
|- | |- | ||
| | | 0xBD400304 || 4 || R || Current interrupt status? | ||
|- | |- | ||
| | | 0xBD400308 || 4 || RW || Currently accepted interrupts? (1 = SIGNAL, 2 = END, 4 = FINISH, 8 = ERROR) | ||
|- | |- | ||
| | | 0xBD40030C || 4 || W? || Set to the value of 0xBD400308 on init & reset | ||
|- | |- | ||
| | | 0xBD400310 || 4 || W? || Set current interrupt status? Set to the value of 0xBD400308 on init & reset | ||
|- | |- | ||
| | | 0xBD400400 || 4 || RW || Set to 4 when the used edram size is 0x00200000 and 2 when it's 0x00400000 (!) | ||
|- | |- | ||
| 0xBD400800 || 1024 || R || Each type a command is executed by the GE, its value, including arguments, is saved here (4 bytes per command) | |||
|- | |||
| 0xBD400C00 || 384 || R || BONE matrices | |||
|- | |||
| 0xBD400D80 || 48 || R || WORLD matrices | |||
|- | |||
| 0xBD400DB0 || 48 || R || VIEW matrices | |||
|- | |||
| 0xBD400DE0 || 48 || R || PROJ matrices | |||
|- | |||
| 0xBD400E20 || 48 || R || TGEN matrices | |||
|- | |- | ||
| | | 0xBD400E50 || 48 || R || COUNT matrices (probably) | ||
|- | |- | ||
| | |} | ||
= 0xBD500000: Graphics Engine EDRAM = | |||
{| class="wikitable" | |||
|- | |- | ||
! Address | |||
! Size | |||
! Read/write | |||
! Description | |||
|- | |- | ||
| | | 0xBD500000 || 4 || RW || Unknown, bits 0x00F00000 set by sceGeEdramSetRefreshParam's 4th argument | ||
|- | |- | ||
| | | 0xBD500010 || 4 || RW || Set to 2 before reset and 0 after reset is done, bit 1 seems to be initialization (used by sceGeEdramInit()) | ||
|- | |- | ||
| | | 0xBD500020 || 4 || RW || Set to 0x6C4 by default and bits 0x007FFFFF set by sceGeEdramSetRefreshParam's second argument | ||
|- | |||
Bits | | 0xBD500030 || 4 || RW || Bits 0x000003FF set by sceGeEdramSetRefreshParam's third argument | ||
|- | |||
| 0xBD500040 || 4 || RW || Set to 1 in sceGeEdramInit(), and to 3 if sceGeEdramSetRefreshParam's first argument (mode) is 1 and the bit 2 isn't set | |||
|- | |||
| 0xBD500050 || 4 || RW || Unknown, accessible through sceGeSetReg/GetReg() | |||
|- | |- | ||
| | | 0xBD500060 || 4 || RW || Unknown, accessible through sceGeSetReg/GetReg() | ||
|- | |- | ||
| | | 0xBD500070 || 4 || RW || Bit 1: disable address translation | ||
|- | |- | ||
| | | 0xBD500080 || 4 || RW || The address translation value | ||
|- | |- | ||
| | | 0xBD500090 || 4 || RW || Unknown, set to 3 in sceGeEdramInit(), accessible through sceGeSetReg/GetReg() | ||
|- | |- | ||
| | | 0xBD5000A0 || 4 || RW || Unknown, accessible through sceGeSetReg/GetReg() | ||
|- | |- | ||
|} | |} | ||
= | = 0xBD600000: ATA/UMD = | ||
= 0xBD700000: ATA/UMD = | |||
= 0xBD800000: USB = | |||
= 0xBDE00000: KIRK = | |||
{| class="wikitable" | |||
|- | |- | ||
! Address | |||
! Size | |||
! Read/write | |||
! Description | |||
|- | |- | ||
| | | 0xBDE00000 || 4 || R || KIRK signature 'KIRK' (or 1?) | ||
|- | |- | ||
| | | 0xBDE00004 || 4 || R || KIRK version '0010' (or 1?) | ||
|- | |- | ||
| | | 0xBDE00008 || 4 || RW || Set to 1 on error by the command subroutine | ||
|- | |- | ||
| | | 0xBDE0000C || 4 || RW || Set to 1 to start processing | ||
|- | |- | ||
| | | 0xBDE00010 || 4 || RW || KIRK command | ||
0x01 = Private decrypt | |||
0x02 = Encrypt (type2) | |||
0x03 = Decrypt (type2) | |||
0x04 = Encrypt (type3) (IV = 0) | |||
0x05 = Encrypt (type3) (IV = Fuse) | |||
0x06 = Encrypt (type3) (IV = User) | |||
0x07 = Decrypt (type3) (IV = 0) | |||
0x08 = Decrypt (type3) (IV = Fuse) | |||
0x09 = Decrypt (type3) (IV = User) | |||
0x0A = Private Signature Check | |||
0x0B = SHA-1 Hash | |||
0x0C = ECDSA Key Generate | |||
0x0D = ECDSA Point Multiply | |||
0x0E = Pseudo-random Number Generator | |||
0x0F = PRNG Seed? Init? | |||
0x10 = ECDSA Sign | |||
0x11 = ECDSA Signature Check | |||
|- | |- | ||
| | | 0xBDE00014 || 4 || RW || Result of the command | ||
|- | |||
| 0xBDE00018 || 4 || RW || Unknown | |||
|- | |- | ||
| | | 0xBDE0001C || 4 || RW || KIRK status | ||
Bit 0 = phase finish | |||
Bit | Bit 1 = phase error? | ||
Bit | Bit 4 = phase 2 needed | ||
Bit | Bit 5 = ? (phase 1 error maybe?) | ||
This should be used for checking processing status, and will notify when the processing has finished. | |||
All bits are 0 while execution is still in progress. | |||
If the command has two phases, Phase 2 Needed will be set when Phase Finish gets set. | |||
Bit1 and bit5 are not well known, but it seems that bit1 is Error for Phase 1, and Success for Phase 2? Bit5 is only checked for Phase 1, and leads to the same error codepath as bit1. | |||
|- | |||
| 0xBDE00020 || 4 || RW || Unknown | |||
|- | |||
| 0xBDE00024 || 4 || RW || Unknown | |||
|- | |||
| 0xBDE00028 || 4 || RW || Set to the value of 0xBDE0001C at the end of the command subroutine | |||
|- | |||
| 0xBDE0002C || 4 || RW || KIRK source buffer (physical address) | |||
|- | |||
| 0xBDE00030 || 4 || RW || KIRK destination buffer (physical address) | |||
|- | |- | ||
| | | 0xBDE0004C || 4 || RW || Unknown | ||
|- | |- | ||
| | | 0xBDE00050 || 4 || RW || Unknown | ||
|- | |- | ||
|} | |} | ||
= | = 0xBDF00000: UMD? = | ||
= 0xBE000000: Audio = | |||
= 0xBE100000: MagicGate hardware for memory stick? = | |||
= | = 0xBE140000: LCDC = | ||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
! | ! Address | ||
! Size | |||
! Read/write | |||
! Description | |||
|- | |- | ||
| | | 0xBE140000 || 4 || RW || First LCDC controller enable | ||
Bits 0-1 = 3 to enable first LCDC controller (tachyon version < 0x800000; otherwise it's set to 0) | |||
|- | |- | ||
| | | 0xBE140004 || 4 || RW || Synchronization difference: (xsync / zoom) - ysync | ||
|- | |- | ||
| | | 0xBE140008 || 4 || RW || Unknown (fourth argument of sceLcdcCheckMode and sceLcdcSetMode) | ||
|- | |- | ||
| | | 0xBE140010 || 4 || RW || X back porch | ||
|- | |- | ||
| | | 0xBE140014 || 4 || RW || X sync width | ||
|- | |- | ||
| | | 0xBE140018 || 4 || RW || X front porch | ||
|- | |- | ||
| | | 0xBE14001C || 4 || RW || X resolution | ||
|- | |- | ||
| | | 0xBE140020 || 4 || RW || Y back porch | ||
|- | |- | ||
| | | 0xBE140024 || 4 || RW || Y sync width | ||
|- | |- | ||
| | | 0xBE140028 || 4 || RW || Y front porch | ||
|- | |- | ||
| | | 0xBE14002C || 4 || RW || Y resolution | ||
|- | |- | ||
| | | 0xBE140030 || 4 || R || HPC (?), returned by sceLcdcReadHPC() | ||
|- | |- | ||
| | | 0xBE140034 || 4 || R || VPC (?), returned by sceLcdcReadVPC() | ||
|- | |- | ||
| | | 0xBE140040 || 4 || RW || Y shift (between hardware & software resolution) | ||
|- | |- | ||
| | | 0xBE140044 || 4 || RW || X shift (between hardware & software resolution) | ||
|- | |- | ||
| | | 0xBE140048 || 4 || RW || Scaled X resolution | ||
|- | |- | ||
| | | 0xBE14004C || 4 || RW || Scaled Y resolution (same as the physical Y resolution) | ||
|- | |- | ||
| | | 0xBE140050 || 4 || RW || Unknown, set to 1, maybe used by sceLcdcReadUnderflow (to be verified) | ||
|- | |- | ||
| | | 0xBE140070 || 4 || W || Set to 1 when running sceLcdcResume() or sceLcdcInit() on tachyon version >= 0x5000000 | ||
|- | |- | ||
| | |} | ||
The exact same registers are at 0xBE1401.., these ones being used for tachyon version >= 0x8000000 (PSP Go?). <br> | |||
These registers are only set on tachyo version >= 0x8000000: | |||
{| class="wikitable" | |||
|- | |- | ||
! Address | |||
! Size | |||
! Read/write | |||
! Description | |||
|- | |- | ||
| | | 0xBE140180 || 4 || RW || Always set to 1 when 0xBE140184 - 0xBE140198 are used | ||
|- | |- | ||
| | | 0xBE140184 || 4 || RW || Scaled X resolution (read instead of the (real) X resolution above when enabled) | ||
|- | |- | ||
| | | 0xBE140188 || 4 || RW || Y resolution (read instead of the (real) Y resolution above when enabled) | ||
|- | |||
| 0xBE14018C || 4 || RW || Unknown (0x580 - 0x678) | |||
|- | |- | ||
| | | 0xBE140190 || 4 || RW || Unknown (0x4C4 - 0x71C) | ||
|- | |- | ||
| | | 0xBE140194 || 4 || RW || Unknown (0xAFC - 0xCEC) | ||
|- | |- | ||
| | | 0xBE140198 || 4 || RW || Unknown (0x910 - 0xE38) | ||
|- | |- | ||
| | | 0xBE140200 || 4 || W || Set to 1 on initialization | ||
|- | |- | ||
|} | |} | ||
= | = 0xBE200000: I2c = | ||
= 0xBE240000: GPIO = | |||
{| class="wikitable" | {| class="wikitable" | ||
Line 1,419: | Line 1,381: | ||
! Description | ! Description | ||
|- | |- | ||
| | | 0xBE240000 || 4 || RW || Unknown | ||
|- | |- | ||
| | | 0xBE240004 || 4 || R || GPIO read pin (1 bit = 1 pin) | ||
|- | |- | ||
| | | 0xBE240008 || 4 || W || GPIO set pin (1 bit = 1 pin) | ||
|- | |- | ||
| | | 0xBE24000C || 4 || W|| GPIO clear pin (1 bit = 1 pin) | ||
|- | |- | ||
| | | 0xBE240010 || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE240014 || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE240018 || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE24001C || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE240020 || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE240030 || 4 || ? || Unknown | ||
|- | |- | ||
| | | 0xBE240040 || 4 || ? || Unknown | ||
|- | |||
| 0xBE240048 || 4 || ? || Unknown | |||
|- | |- | ||
|} | |} | ||
= | = 0xBE300000: Power management? = | ||
= 0xBE400000 & 0xBE500000: UART = | |||
The second 'xx' bytes of the addresses can be 0x40, 0x44, 0x48, 0x4C, 0x50, 0x54, 0x58, 0x5C for the different UART ports (1-8, in that order). | |||
Note that: | |||
* UART1 = ? | |||
* UART2 = ? | |||
* UART3 = ? | |||
* UART4 = ? | |||
* UART5 = Headphone/remote SIO | |||
* UART6 = Infrared | |||
* UART7 = Syscon | |||
* UART8 = PSP 2k+ display-related | |||
{| class="wikitable" | {| class="wikitable" | ||
Line 1,452: | Line 1,430: | ||
! Description | ! Description | ||
|- | |- | ||
| | | 0xBExx0000 || 4 || RW || Read/write FIFO of the UART port | ||
Bits 0-7 = data | |||
Writing writes a byte to the Tx buffer and advances the write position. | |||
Reading reads a byte from the Rx buffer and advances the read position. | |||
The FIFO is 32(?) bytes long. | |||
|- | |- | ||
| | | 0xBExx0018 || 4 || RW || Port status | ||
Bit 4 = Rx buffer status is empty | |||
Bit 5 = Tx buffer status is full | |||
|- | |- | ||
| | | 0xBExx0024 || 4 || W || Upper bits of baudrate divisor, ie (96000000 / baudrate) >> 6 | ||
|- | |- | ||
| | | 0xBExx0028 || 4 || W || Lower bits of baudrate divisor, ie (96000000 / baudrate) & 0x3f | ||
|- | |- | ||
| | | 0xBExx002C || 4 || W || Set bits 5-6 to set the baud rate? | ||
|- | |- | ||
|} | |} | ||
= | = 0xBE600000: ? = | ||
= 0xBE700000: Display = | |||
= 0xBFC00000: MIPS Reset Vector = | |||
= 0xBFF00000: NAND DMA buffer = | = 0xBFF00000: NAND DMA buffer = | ||
Line 2,350: | Line 1,477: | ||
= References = | = References = | ||
* [http://daifukkat.su/docs/psptek/ PSPTEK] | * [http://daifukkat.su/docs/psptek/ PSPTEK] (done) | ||
* [https://gigawiz.github.io/yapspd/html_chapters_split/chap8.html yapspd] | * [https://gigawiz.github.io/yapspd/html_chapters_split/chap8.html yapspd] (done) | ||
* [https://github.com/uofw/uofw uOFW] | * [https://github.com/uofw/uofw uOFW] (todo: some more info to grab in some modules) | ||
* [https://github.com/jpcsp/jpcsp Jpcsp] | * [https://github.com/jpcsp/jpcsp Jpcsp] (todo: contains a lot of stuff) |