Backport Fixed missing open bus bit on $4015 reads

This commit is contained in:
vailkyte 2023-05-18 07:52:13 -05:00 committed by GitHub
parent 96da3f0b71
commit fc0b08f73c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -98,7 +98,7 @@ uint8_t APU::ReadRAM(uint16_t addr)
//$4015 read
Run();
uint8_t status = GetStatus();
uint8_t status = GetStatus() | (_console->GetMemoryManager()->GetOpenBus() & 0x20);
//Reading $4015 clears the Frame Counter interrupt flag.
_console->GetCpu()->ClearIrqSource(IRQSource::FrameCounter);