diff options
author | Michael Pavone <pavone@retrodev.com> | 2017-01-04 23:01:58 -0800 |
---|---|---|
committer | Michael Pavone <pavone@retrodev.com> | 2017-01-04 23:01:58 -0800 |
commit | 8850361638a09a0ec25764678a2c1cbaf965d9e5 (patch) | |
tree | 6f753241dfd88882d5a626aab83ecc60bffd662f | |
parent | 839a67f4d4dbaf39d3b77cdc6a6397572da71090 (diff) |
Fix to pass a couple more tests in VDPTEST.sms
-rw-r--r-- | vdp.c | 7 |
1 files changed, 2 insertions, 5 deletions
@@ -2177,7 +2177,7 @@ int vdp_control_port_write(vdp_context * context, uint16_t value) } else { uint8_t mode_5 = context->regs[REG_MODE_2] & BIT_MODE_5; context->address = (context->address &0xC000) | (value & 0x3FFF); - //Genesis Plus GX doesn't clear out the mode bits in Mode 4, but instead + //Genesis Plus GX doesn't clear out the upper mode bits in Mode 4, but instead //ignores the uppper mode bits when it comes to reads/writes //testing on hardware is needed to determine which is truly correct context->cd = (mode_5 ? context->cd &0x3C : 0) | (value >> 14); @@ -2388,10 +2388,7 @@ uint8_t vdp_data_port_read_pbc(vdp_context * context) //Should this happen after the prefetch or after the read? increment_address(context); } - context->cd &= ~1; - if (context->cd == VRAM_READ) { - context->cd = VRAM_READ8; - } + context->cd = VRAM_READ8; return context->prefetch; } |