all repos — mgba @ ed9fa2b118e7323774e29793c4e196e9eaa05ace

mGBA Game Boy Advance Emulator

GBA SIO: Improve SIO Normal dummy driver (fixes #520)
Vicki Pfau vi@endrift.com
Sat, 08 Jul 2017 13:50:08 -0700
commit

ed9fa2b118e7323774e29793c4e196e9eaa05ace

parent

e6593eb0d4a6489d920f8bc0ce6319304720ca14

2 files changed, 7 insertions(+), 4 deletions(-)

jump to
M CHANGESCHANGES

@@ -167,6 +167,7 @@ - Qt: Fix controls not saving on non-SDL builds

- GB Video: Fix LYC regression - Qt: Fix translation initialization (fixes mgba.io/i/776) - PSP2: Use custom localtime_r since newlib version is broken (fixes mgba.io/i/560) + - GBA SIO: Improve SIO Normal dummy driver (fixes mgba.io/i/520) Misc: - Qt: Add language selector - GBA Timer: Improve accuracy of timers
M src/gba/sio.csrc/gba/sio.c

@@ -155,11 +155,13 @@ switch (sio->mode) {

case SIO_NORMAL_8: case SIO_NORMAL_32: value |= 0x0004; - if ((value & 0x4080) == 0x4080) { - // TODO: Test this on hardware to see if this is correct - GBARaiseIRQ(sio->p, IRQ_SIO); + if ((value & 0x0081) == 0x0081) { + if (value & 0x4000) { + // TODO: Test this on hardware to see if this is correct + GBARaiseIRQ(sio->p, IRQ_SIO); + } + value &= ~0x0080; } - value &= ~0x0080; break; default: // TODO