Merge pull request #8278 from drojaazu/sega_mega_cd_prgram_from_main_fix

megacd - Read/write handlers for PRGRAM access from Main side was using u16 fo…
This commit is contained in:
ajrhacker 2021-07-09 22:08:28 -04:00 committed by GitHub
commit f2d74f9bd4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -750,14 +750,14 @@ void sega_segacd_device::segacd_comms_flags_maincpu_w(offs_t offset, uint16_t da
uint16_t sega_segacd_device::scd_4m_prgbank_ram_r(offs_t offset)
{
uint16_t realoffset = ((segacd_4meg_prgbank * 0x20000)/2) + offset;
uint32_t realoffset = ((segacd_4meg_prgbank * 0x20000)/2) + offset;
return m_prgram[realoffset];
}
void sega_segacd_device::scd_4m_prgbank_ram_w(offs_t offset, uint16_t data, uint16_t mem_mask)
{
uint16_t realoffset = ((segacd_4meg_prgbank * 0x20000)/2) + offset;
uint32_t realoffset = ((segacd_4meg_prgbank * 0x20000)/2) + offset;
// todo:
// check for write protection? (or does that only apply to writes on the SubCPU side?