Fxing MOVW, fixing 0xEB MOV

Adding better temporary CPU-APU synchro
This commit is contained in:
Melefo
2020-05-27 19:17:37 +02:00
parent 73b84b1925
commit 0ee4575512
3 changed files with 6 additions and 4 deletions
@@ -11,9 +11,11 @@ namespace ComSquare::APU
uint24_t addr2 = addr + 1 + (this->_internalRegisters.p ? 0x0100 : 0);
if (to_ya) {
uint16_t value = ((this->_internalRead(addr2) << 8u) | this->_internalRead(addr));
uint8_t tmp = this->_internalRead(addr2);
uint16_t value = (tmp << 8) | this->_internalRead(addr);
this->_internalRegisters.ya = value;
this->_internalRegisters.a = value;
this->_internalRegisters.y = (value >> 8);
this->_setNZflags(value);
}
else {