Editing POPS
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 45: | Line 45: | ||
bit: | bit: | ||
0 = Used in GP0(E3-E4h) handler. | 0 = Used in GP0(E3-E4h) handler. | ||
2 = Used in GP0(A0h) handler. | 2 = Used in GP0(A0h) handler. | ||
3 = | 3 = Used in vblank related function. | ||
4 = Used in gpu dma related function. | 4 = Used in gpu dma related function. | ||
5 = Used in GP0(2x-3xh) commands handler. | 5 = Used in GP0(2x-3xh) commands handler. | ||
Line 55: | Line 53: | ||
7 = Spu irq address (0x1F801DA4) related setting. | 7 = Spu irq address (0x1F801DA4) related setting. | ||
8 = Spu reverb related setting. | 8 = Spu reverb related setting. | ||
9 = Spu dma related setting | 9 = Spu dma related setting. | ||
10 = Cdrom | 10 = Cdrom related, when enabled seems to update msf/lba more frequently. | ||
12 = | 12 = Counters/timers related setting. | ||
13 = Cdrom related setting. When enabled max_disc_lba_without_lead_out is used instead of second_track_lba in one function. | 13 = Cdrom related setting. When enabled max_disc_lba_without_lead_out is used instead of second_track_lba in one function. | ||
15 = Allows discs to be swapped when game didn't request to change ps1 gpu drawing parameters for long enough (60x this check). | 15 = Allows discs to be swapped when game didn't request to change ps1 gpu drawing parameters for long enough (60x this check). | ||
16 = Skip some additional checks for Pause/ReadS/ReadN/GetTN/Setmode cmds during cdrom command processing. | 16 = Skip some additional checks for Pause/ReadS/ReadN/GetTN/Setmode cmds during cdrom command processing. | ||
17 = Used in MDEC related functions | 17 = Used in MDEC related functions. | ||
20 = Use second nBuf in sceCtrlPeekBufferNegative instead of first one and change controller sampling cycles from 0 to 8341 in sceCtrlSetSamplingCycle. | 20 = Use second nBuf in sceCtrlPeekBufferNegative instead of first one and change controller sampling cycles from 0 to 8341 in sceCtrlSetSamplingCycle. | ||
23 = Allows discs to be swapped at any time, regardless of game prompting to or not. | 23 = Allows discs to be swapped at any time, regardless of game prompting to or not. | ||
Line 78: | Line 70: | ||
| 0x00 || Yes || Code analyzer flags, 16 bits usable, but only 6 bits seems to have any effect. Cfg 0x0C and 0x0D override this setting when used (only for selected pc). When set to 0xFFFFFFFF (default), value 3 (bit 0-1) is used. | | 0x00 || Yes || Code analyzer flags, 16 bits usable, but only 6 bits seems to have any effect. Cfg 0x0C and 0x0D override this setting when used (only for selected pc). When set to 0xFFFFFFFF (default), value 3 (bit 0-1) is used. | ||
bit: | bit: | ||
0 = Force code cache clear in one of recompiler | 0 = Force code cache clear in one of recompiler function.s | ||
1 = Skips check if opcode rd is $zero (seems to be related to branches/jumps). | 1 = Skips check if opcode rd is $zero (seems to be related to branches/jumps). | ||
2 = Analyze grater address range at once. PC + 0x2000, instead of default PC + 0xC00. | 2 = Analyze grater address range at once. PC + 0x2000, instead of default PC + 0xC00. | ||
Line 88: | Line 80: | ||
| 0x01 || No || Set minimal "Y2" drawing area. This setting overrides what game set in GP0(E4h) command (Set Drawing Area bottom Y2 coordinate). Setting is used only when given value is lower than what game originally sends. In simple words, this work as a crop for the bottom of drawing area. ''Warning! This setting can have bad effect when copied straight from PAL to NTSC game and vice versa.'' | | 0x01 || No || Set minimal "Y2" drawing area. This setting overrides what game set in GP0(E4h) command (Set Drawing Area bottom Y2 coordinate). Setting is used only when given value is lower than what game originally sends. In simple words, this work as a crop for the bottom of drawing area. ''Warning! This setting can have bad effect when copied straight from PAL to NTSC game and vice versa.'' | ||
|- | |- | ||
| 0x02 || | | 0x02 || Unk || | ||
|- | |- | ||
| 0x03 || | | 0x03 || Unk || | ||
|- | |- | ||
| 0x04 || Yes || This config is multi-command for cdrom behavior. Value is bitfield, but not usual one. This config default value is 0xFFFFFFFF, to "enable" bits we need to really disable them. Windows programmer mode calculator in dword mode should shed some light here. To see enabled bits just use NOT operator. | | 0x04 || Yes || This config is multi-command for cdrom behavior. Value is bitfield, but not usual one. This config default value is 0xFFFFFFFF, to "enable" bits we need to really disable them. Windows programmer mode calculator in dword mode should shed some light here. To see enabled bits just use NOT operator. | ||
|- | |- | ||
| 0x05 || No || Value is PS1 cpu cycles that will be added to currently passed cycles, eventually triggering events test earlier. Config is used only on BLEZ/BGTZ/BEQ/BNE/B PS1 opcodes. Emulator adds 1 to this value before using it, so default 0xFFFFFFFF = 0. | | 0x05 || No || Value is PS1 cpu cycles that will be added to currently passed cycles, eventually triggering events test earlier. Config is used only on BLEZ/BGTZ/BEQ/BNE/B PS1 opcodes. Emulator adds 1 to this value before using it, so default 0xFFFFFFFF = 0. | ||
Line 136: | Line 108: | ||
| 0x0A || No || | | 0x0A || No || | ||
|- | |- | ||
| 0x0B || No || | | 0x0B || No || Value is used as an Divider at some point, only u16 is used. | ||
|- | |- | ||
| 0x0C || No || Value is PS1 memory address. Set code analyzer memory range end address. This config has some restrictions and outcome depends on bit 2 of cfg 0x00. Pseudocode looks like this: | | 0x0C || No || Value is PS1 memory address. Set code analyzer memory range end address. This config has some restrictions and outcome depends on bit 2 of cfg 0x00. Pseudocode looks like this: | ||
Line 159: | Line 131: | ||
| 0x13 || No || When value is 0 or higher, store it on addr. Only u8 seems to be used. | | 0x13 || No || When value is 0 or higher, store it on addr. Only u8 seems to be used. | ||
|- | |- | ||
| 0x14 || | | 0x14 || No || SPU emulation related command. Command use 2x u8 value. | ||
value1 = cmdValue & 0xFF // Used only to compare for equality with some value at some point. | value1 = cmdValue & 0xFF // Used only to compare for equality with some value at some point. | ||
value2 = (cmdValue >> 8) & 0xFF // Used if compare mentioned above is true. | value2 = (cmdValue >> 8) & 0xFF // Used if compare mentioned above is true. | ||
Additionally, if whole s16 cmd is higher than 0 different code path is used in SPU DMA handler. | |||
|- | |- | ||
| 0x15 || No || | | 0x15 || No || Cdrom related. | ||
|- | |- | ||
| 0x16 || No || When value is not less than 0, run some additional code related to vblank (seems to be scheduling some event). | | 0x16 || No || When value is not less than 0, run some additional code related to vblank (seems to be scheduling some event). | ||
Line 180: | Line 150: | ||
| 0x1B || No || Initialize PSX scratchpad memory to given value + 1. Similar setting is found in ps1_netemu on PS3. Only one game seems to rely on it. | | 0x1B || No || Initialize PSX scratchpad memory to given value + 1. Similar setting is found in ps1_netemu on PS3. Only one game seems to rely on it. | ||
|- | |- | ||
| 0x1C || Unk || | | 0x1C || Unk || Seems to be unused on PSP. | ||
|- | |- | ||
| 0x1D || Unk || | | 0x1D || Unk || Seems to be unused on PSP. | ||
|- | |- | ||
| 0x1E || | | 0x1E || Unk || Seems to be unused on PSP. | ||
|- | |- | ||
| 0x1F || Unk || | | 0x1F || Unk || Seems to be unused on PSP. | ||
|- | |- | ||
|} | |} | ||
Line 6,401: | Line 6,355: | ||
|} | |} | ||
Additionally, emulator adds "penalty" cycles for every opcode if currently executed memory is not PS1 main memory. 2 cycles are added to every opcode when emu is running PS1 ROM (0x1FC00000 - 0x1FC80000), and 5 cycles are added when emu is running PS1 Scratchpad (is that even possible?). | Additionally, emulator adds "penalty" cycles for every opcode if currently executed memory is not PS1 main memory. 2 cycles are added to every opcode when emu is running PS1 ROM (0x1FC00000 - 0x1FC80000), and 5 cycles are added when emu is running PS1 Scratchpad (is that even possible?). | ||