From 78c2237ab8cf410b7cb1f4875acd419acd8a9da3 Mon Sep 17 00:00:00 2001 From: kub Date: Fri, 7 May 2021 18:40:55 +0200 Subject: [PATCH] core, big endian fix (cart sram detection) --- pico/cart.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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; -- 2.39.2