Peter Evans
89ddd20658
Add read_byte function to return the next byte in memory
2017-12-05 20:40:35 -06:00
Peter Evans
50a84b4099
Remove cycles field from mos6502 struct
...
It was both unused and not necessary, as we can simply compute the
number of cycles in the execute function.
2017-12-05 20:23:17 -06:00
Peter Evans
5ada987c83
Add the execute function for the 6502
...
This executes a single opcode. Note this also makes a change to the
get_address_resolver function such that accepts an opcode, not the
address mode itself.
2017-12-05 19:01:43 -06:00
Peter Evans
eaaf63a069
Zero out last_addr and cycles
...
This fixes a super-annoying bug in the unit-test suite where we would
fail randomly because sometimes last_addr would have garbage in it.
2017-12-05 18:41:34 -06:00
Peter Evans
8454d1a6c9
Add instruction handler function, handler table
2017-12-05 18:38:36 -06:00
Peter Evans
54473be302
Add functions for instructions, cycles, and address modes.
...
This also adds a new table for cycles, and adds unit test functions for
the work as well.
2017-12-04 23:30:18 -06:00
Peter Evans
87de0a877a
Add all our tests, plus other fixes
2017-12-03 20:19:17 -06:00
Peter Evans
fe9ce3aca3
Tests for the new mos6502 functions
2017-12-02 13:27:30 -06:00
Peter Evans
3cebed2377
Adding all of the instruction files
2017-12-02 13:05:53 -06:00