diff --git a/pico/cart.c b/pico/cart.c index 339b9fe7..13218031 100644 --- a/pico/cart.c +++ b/pico/cart.c @@ -1341,10 +1341,6 @@ static void PicoCartDetect(const char *carthw_cfg) memset(Pico.sv.data, 0xff, Pico.sv.size); } - // Unusual region 'code' - if (rom_strcmp(0x1f0, "EUROPE") == 0 || rom_strcmp(0x1f0, "Europe") == 0) - *(u32 *) (Pico.rom + 0x1f0) = CPU_LE4(0x20204520); - // tweak for Blackthorne: master SH2 overwrites stack of slave SH2 being in PWM // interrupt. On real hardware, nothing happens since slave fetches the values // it has written from its cache, but picodrive doesn't emulate caching. diff --git a/pico/pico.c b/pico/pico.c index 0e7e1d8f..b84fda6e 100644 --- a/pico/pico.c +++ b/pico/pico.c @@ -97,15 +97,21 @@ PICO_INTERNAL void PicoDetectRegion(void) { int support=0, hw=0, i; unsigned char pal=0; + char *pr = (char *)(Pico.rom + 0x1f0); if (PicoIn.regionOverride) { support = PicoIn.regionOverride; } + else if (strcmp(pr, "EUROPE") == 0 || strcmp(pr, "Europe") == 0) + { + // Unusual cartridge region 'code' + support|=8; + } else { // Read cartridge region data: - unsigned short *rd = (unsigned short *)(Pico.rom + 0x1f0); + unsigned short *rd = (unsigned short *)pr; int region = (rd[0] << 16) | rd[1]; for (i = 0; i < 4; i++)