Created
July 10, 2016 17:32
-
-
Save RdlP/321cd30fb9807a0a6b663f6d67425334 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void CPU::step() | |
{ | |
BYTE instruction = fetch(); | |
registers.pc++; | |
decode(instruction); | |
} | |
BYTE CPU::fetch() | |
{ | |
BYTE instruction = memory->readByte(registers.pc); | |
return instruction; | |
} | |
void CPU::decode(BYTE instruction) | |
{ | |
(this->*bOps[instruction])(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment