mirror of
https://github.com/FrancescoRigoni/Lib65816.git
synced 2024-12-28 20:29:16 +00:00
add getter for stack, adjusted disply of vector for page direct with x/y
This commit is contained in:
parent
f18794b159
commit
3c36e71c04
@ -183,6 +183,9 @@ Address Cpu65816::getAddressOfOpCodeData(OpCode &opCode) {
|
||||
break;
|
||||
case AddressingMode::DirectPageIndirectIndexedWithY:
|
||||
{
|
||||
|
||||
Log::vrb(LOG_TAG).str("DirectPageIndirectIndexedWithY").hex( mSystemBus.readByte(mProgramAddress.newWithOffset(1))).show();
|
||||
|
||||
Address firstStageAddress(0x00, mD + mSystemBus.readByte(mProgramAddress.newWithOffset(1)));
|
||||
uint16_t secondStageOffset = mSystemBus.readTwoBytes(firstStageAddress);
|
||||
Address thirdStageAddress(mDB, secondStageOffset);
|
||||
|
@ -59,6 +59,10 @@ Address Cpu65816::getProgramAddress() {
|
||||
return mProgramAddress;
|
||||
}
|
||||
|
||||
Stack *Cpu65816::getStack() {
|
||||
return &mStack;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Resets the cpu to its initial state.
|
||||
|
@ -157,11 +157,11 @@ void Cpu65816Debugger::logOpCode(OpCode &opCode) const {
|
||||
log.str(" [Direct Page Indirect Long]");
|
||||
break;
|
||||
case AddressingMode::DirectPageIndexedIndirectWithX:
|
||||
log.str("(").hex(mCpu.mSystemBus.readByte(mCpu.getAddressOfOpCodeData(opCode)), 2).str(", X)").sp();
|
||||
log.str("(").hex(mCpu.mSystemBus.readByte(mCpu.mProgramAddress.newWithOffset(1)), 2).str(", X)").sp();
|
||||
log.str(" [Direct Page Indexed Indirect, X]");
|
||||
break;
|
||||
case AddressingMode::DirectPageIndirectIndexedWithY:
|
||||
log.str("(").hex(mCpu.mSystemBus.readByte(mCpu.getAddressOfOpCodeData(opCode)), 2).str("), Y").sp();
|
||||
log.str("(").hex(mCpu.mSystemBus.readByte(mCpu.mProgramAddress.newWithOffset(1)), 2).str("), Y").sp();
|
||||
log.str(" [Direct Page Indirect Indexed, Y]");
|
||||
break;
|
||||
case AddressingMode::DirectPageIndirectLongIndexedWithY:
|
||||
|
Loading…
Reference in New Issue
Block a user