From: kub Date: Fri, 7 May 2021 16:40:55 +0000 (+0200) Subject: core, big endian fix (cart sram detection) X-Git-Tag: v2.00~531 X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=78c2237ab8cf410b7cb1f4875acd419acd8a9da3;p=picodrive.git core, big endian fix (cart sram detection) --- diff --git a/pico/cart.c b/pico/cart.c index 35c449fd..1d17c713 100644 --- a/pico/cart.c +++ b/pico/cart.c @@ -1256,11 +1256,11 @@ static void PicoCartDetect(const char *carthw_cfg) int fill_sram = 0; memset(&Pico.sv, 0, sizeof(Pico.sv)); - if (Pico.rom[0x1B1] == 'R' && Pico.rom[0x1B0] == 'A') + if (Pico.rom[MEM_BE2(0x1B0)] == 'R' && Pico.rom[MEM_BE2(0x1B1)] == 'A') { Pico.sv.start = rom_read32(0x1B4) & ~0xff000001; // align Pico.sv.end = (rom_read32(0x1B8) & ~0xff000000) | 1; - if (Pico.rom[0x1B2] & 0x40) + if (Pico.rom[MEM_BE2(0x1B3)] & 0x40) // EEPROM Pico.sv.flags |= SRF_EEPROM; Pico.sv.flags |= SRF_ENABLED;