Peter Evans
724dbb1577
Add test to ensure decimal mode is respected for SBC
2018-02-26 20:33:33 -06:00
Peter Evans
0333e308e7
Test decimal mode with ADC
2018-02-26 20:02:58 -06:00
Peter Evans
30c07df9cb
When carry is set, subtract one fewer, not one more
...
A subtle misunderstanding... which led to bizarre and unexpected
behavior elsewhere.
2018-02-26 18:59:25 -06:00
Peter Evans
0d1e22a348
Add support for decimal mode ADC/SBC.
...
This also corrects a bug where SBC set carry incorrectly in binary mode.
2018-02-23 00:46:07 -06:00
Peter Evans
8623945bbf
Add the ability to INC or DEC the accumulator
...
This is an oversight from the 6502 processor that was rectified in the
65c02 model.
2018-02-21 21:20:05 -06:00
Peter Evans
5656b271ee
Account for carry being set by default
2018-01-23 16:30:52 -06:00
Peter Evans
746e2246b3
Set negative and unset zero since the operand >= A
2018-01-23 16:29:53 -06:00
Peter Evans
3c7002c6c7
Carry is only unset if the operand >= A
2018-01-23 16:29:08 -06:00
Peter Evans
dc97a6996e
Account for carry being set by default
2018-01-23 16:28:39 -06:00
Peter Evans
7d6886a3a8
Change last_addr field to eff_addr
2018-01-12 13:57:48 -06:00
Peter Evans
8d9b48912e
Add memory injection to 6502; main memory in apple2
...
Note that memory _is_ now managed in apple2, and _not_ in mos6502.
2018-01-10 21:28:05 -06:00
Peter Evans
1de1e7788a
Rename status flags to MOS_
2018-01-05 14:18:39 -06:00
Peter Evans
00ff9f069d
Vastly simplify unit tests for mos6502
...
Criterion's init and fini config options allow us to register setup and
teardown functions. We now use this to register the common cpu variable
for the mos6502 tests, albeit through the use of a global variable.
Doing so necessitated that each of the different test files have their
own suites, due to some implementation details in Criterion, but this is
No Big Deal.
2017-12-06 15:57:15 -06:00
Peter Evans
87de0a877a
Add all our tests, plus other fixes
2017-12-03 20:19:17 -06:00