started adding illegal instructions

This commit is contained in:
Lauchmelder 2021-10-23 01:29:15 +02:00
parent a345421963
commit bfdf3f88cf
3 changed files with 176 additions and 170 deletions

View file

@ -14,7 +14,9 @@ enum Operation
INC, INX, INY, JMP, JSR, LDA, LDX, LDY,
LSR, NOP, ORA, PHA, PHP, PLA, PLP, ROL,
ROR, RTI, RTS, SBC, SEC, SED, SEI, STA,
STX, STY, TAX, TAY, TSX, TXA, TXS, TYA
STX, STY, TAX, TAY, TSX, TXA, TXS, TYA,
JAM, SLO, ANC
};
enum AddrMode
@ -28,6 +30,7 @@ struct Opcode
enum AddrMode addr;
Byte cycles;
Byte length;
Byte illegal;
const char str[4];
};
@ -68,7 +71,7 @@ struct CPU
Word word;
} pc;
Byte remainingCycles;
char remainingCycles;
size_t totalCycles;
Byte fetchedVal;