DS-Homebrew / nds-bootstrap

Boot an nds file
https://wiki.ds-homebrew.com/nds-bootstrap/
GNU General Public License v3.0
1.17k stars 75 forks source link

Compatibility issue (game freeze) with Japanese Rev A version of Castlevania: Portrait of Ruin on nds-bootstrap (NDSi) #1484

Closed Aceearly1993 closed 7 months ago

Aceearly1993 commented 1 year ago

Your console: NDSi LL (Ver. 1.4 J)

Launch Method: SD Card

Version used: Ver. Release v0.66.0

Game tested/used/applicable: Database match: Akumajou Dracula - Gallery of Labyrinth (Japan) (Rev 1) Database: No-Intro: DS (all) (v. 20210227-111036) File/ROM SHA-1: 05F3ECEA560E1EAC9CDF955AFF59AB2AB8684FE9 File/ROM CRC32: 8708ECE6

Expected Behavior:

When accessing the in-game shop, shop menu should be opened in due time.

Actual Behavior:

In nds-bootstrap the game freezes at black screen when trying to access the in-game shop menu instead.

Steps to reproduce

  1. Grab the rom of Akumajou Dracula - Gallery of Labyrinth (Japan) (Rev 1) from somewhere
  2. Open the game via nds-bootstrap in Twilight Menu ++, going to Vincent's shop and try to access it
  3. Game freezes at black screen.

nds-bootstrap.ini

[NDS-BOOTSTRAP]
DEBUG = 0
LOGGING = 0
ROMREAD_LED = 3
DMA_ROMREAD_LED = 1
LOADING_SCREEN = 1
CONSOLE_MODEL = 0
EXTENDED_MEMORY = 0
CACHE_BLOCK_SIZE = 1
CACHE_FAT_TABLE = 0
PRECISE_VOLUME_CONTROL = 1
SOUND_FREQ = 1
NDS_PATH = sd:/roms/nds/built_rom_por (2).nds
HOMEBREW_ARG =
LANGUAGE = -1
DSI_MODE = 1
BOOST_CPU = 0
BOOST_VRAM = 0
SAV_PATH = sd:/roms/nds/saves/built_rom_por (2).sav
RAM_DRIVE_PATH = sd:/null.img
DONOR_SDK_VER = 0
PATCH_MPU_REGION = 0
PATCH_MPU_SIZE = 0
CARDENGINE_CACHED = 1
FORCE_SLEEP_PATCH = 1
GUI_LANGUAGE = en
REGION = 1
CARD_READ_DMA = 1
ASYNC_CARD_READ = 0
SDNAND = 0
MACRO_MODE = 0
HOTKEY = 284

USE_ROM_REGION = 1
B4DS_MODE = 0
SLEEP_MODE = 1

Logs

findModuleParamsOffset:
Module params offset restored: 02000BBC
sdk_version: 04027531
arm9 is not compressed

Switched to NTR mode BIOS
patchCardNds

cardIrqEnable location : 020933C4

startOffset : 02000000

cardRead location : 0209E2F8
03700000

swi12 location : 02000352

cardPullOut location : 0209E854

cardId location : 0209E3E8

patchCardSetDma

NDMA CARD SET METHOD ACTIVE
cardSetDma location : 0209E048

NDMA CARD READ METHOD ACTIVE
cardEndReadDma location : 0209E0E4

Mpu start: 02000ADC

Mpu data: 02000B70

Mpu init: 02094F64

Mpu data alt: 02094C14

Mpu start 2: 02000AE4

Mpu data 2: 02000B74

Mpu init 2: 02094F6C

waitCpuCycles location : 02095894

ERR_NONE

Sleep location : 0238D1F0

cardIrqEnable location : 02383AD8

forwardedRelocStartAddr
023801D0
vAddrOfRelocSrc
023801E8
Relocation src: 023801E8
Relocation dst: 037F8000

Arm7 (patch vAll)

JumpTableFunc: 0238B5BC
Eeprom read:    0238B5C8
Eeprom page write:  0238B5DC
Eeprom page prog:   0238B5F0
Eeprom verify:  0238B604
Eeprom page erase:  0238B614
swi12 location : 0238B9FC

swiGetPitchTable location : 02386FB4

ERR_NONE

hookNdsRetailArm7
hookLocation arm7: 0238F584

ERR_NONE
hookLocation arm9: 027C1580

chipID: 80003FC2

Other notes

The other versions of Portrait of Ruin are running perfectly fine on nds-bootstrap, but this version is rare and might be either missed or overlooked.

RocketRobz commented 1 year ago

Have you tried turning off card read DMA?

RocketRobz commented 1 year ago

Actually, before trying that, try the latest nds-bootstrap nightly: https://github.com/TWLBot/Builds/raw/master/nds-bootstrap.7z After installing it, set Bootstrap to Nightly in the per-game settings menu.

Aceearly1993 commented 1 year ago

Thanks. Did a lot of trial and error, turn off card read DMA alone didn't work, the newer nightly build didn't work, but found a temporary solution: Turn off card read DMA, set Run in to DSi mode, (ARM9 CPU Speed changed to 133mhz at the same time) and set VRAM Mode to DSi mode. It's so weird because for other versions of Portrait of Ruin it doesn't need to toggle the options in per game settings. I wonder what kind of extra magic the game's developers had made to this specific version, aside from bug fixes.