/* reading disc */
if (cdd.status == CD_PLAY)
{
+ if (cdd.index >= cdd.toc.last)
+ {
+ /* end of disc */
+ cdd.status = CD_END;
+ return;
+ }
+
/* track type */
if (!is_audio(cdd.index))
{
/* data track sector read is controlled by CDC */
cdd.lba += cdc_decoder_update(header);
}
- else if (cdd.index < cdd.toc.last)
+ else
{
uint8 header[4] = { 0, };
/* next audio block is automatically read */
cdd.lba++;
}
- else
- {
- /* end of disc */
- cdd.status = CD_END;
- return;
- }
/* check end of current track */
if (cdd.lba >= cdd.toc.tracks[cdd.index].end)
Pico_mcd->m.state_flags = PCD_ST_S68K_RST;
Pico_mcd->m.busreq = 2; // busreq on, s68k in reset
Pico_mcd->s68k_regs[3] = 1; // 2M word RAM mode, m68k access
- if (Pico.romsize <= 0x20000)
+ if (Pico.romsize <= 0x20000) // hack to detect BIOS, no GA HINT vector for MSU
memset(Pico.rom + 0x70, 0xff, 4);
}
// MSU cartridge. Fake BIOS detection\r
cpu68k_map_set(m68k_read8_map, 0x400000, 0x41ffff, PicoReadM68k8_bios, 1);\r
cpu68k_map_set(m68k_read16_map, 0x400000, 0x41ffff, PicoReadM68k16_bios, 1);\r
- // RAM cart\r
} else {\r
+ // RAM cart\r
cpu68k_map_set(m68k_read8_map, 0x400000, 0x7fffff, PicoReadM68k8_ramc, 1);\r
cpu68k_map_set(m68k_read16_map, 0x400000, 0x7fffff, PicoReadM68k16_ramc, 1);\r
cpu68k_map_set(m68k_write8_map, 0x400000, 0x7fffff, PicoWriteM68k8_ramc, 1);\r