I've refactored the tests and extracted to CPU6502Spec, and them start playing with py65. Didn't take long to have most of the test working. Now I have the same test spec running with either ApplyPy or Py65 6502, and that's amazing. Although, let's keep in mind that the goal is a Ricoh 2A03 CPU, the NES CPU. And that lead us to deal with interrupts.
IRQ and NMI
IRQ stands for "Interrupt Request" and NMI for "Non-Masked Interrupt". As far as I know, and please someone correct me if I got it wrong. Interrupts are used for event handling. On the NES, you have two CPUs (Main and PPU for graphics) that runs in parallel. There fore, to accurately emulate a NES, we need to deal with several race conditional on the hardware. Or, for start, we can make then serial (NMI Thread on NESDev gives good tips in NMI only), and be able to run Super Mario Bros.
As usual, you can checkout the progress at wedNESday repository.
- Create a fake PPU and a memory bridge and try to run a simple waitvblank program.
- Create a pull request with CPUSpec and send to py65.