md, reworked cart protection handling, added some unlicensed

This commit is contained in:
kub 2022-04-30 14:07:58 +02:00
parent 27b26d0478
commit e1e8ca17be
6 changed files with 625 additions and 195 deletions

View file

@ -833,7 +833,7 @@ PICO_INTERNAL void PicoMemSetup(void)
// align to bank size. We know ROM loader allocated enough for this
mask = (1 << M68K_MEM_SHIFT) - 1;
rs = (Pico.romsize + mask) & ~mask;
if (rs > 0x400000) rs = 0x400000; // max cartridge area
if (rs > 0xa00000) rs = 0xa00000; // max cartridge area
cpu68k_map_set(m68k_read8_map, 0x000000, rs - 1, Pico.rom, 0);
cpu68k_map_set(m68k_read16_map, 0x000000, rs - 1, Pico.rom, 0);