We've just updated MediaWiki and its underlying software. If anything doesn't look or work quite right, please mention it to us. --RanAS
ADC (SPC700): Difference between revisions
From SnesLab
(→External Links: Table C-7) |
(linkify flags) |
||
Line 71: | Line 71: | ||
!colspan="8"|Flags Clobbered | !colspan="8"|Flags Clobbered | ||
|+ | |+ | ||
|N | |[[Negative Flag|N]] | ||
|V | |[[Overflow Flag|V]] | ||
|P | |[[Direct Page Flag|P]] | ||
|B | |[[Break Flag|B]] | ||
|H | |[[Half-Carry Flag|H]] | ||
|I | |[[Interrupt Enable Flag|I]] | ||
|Z | |[[Zero Flag|Z]] | ||
|C | |[[Carry Flag|C]] | ||
|+ | |+ | ||
| | | |
Revision as of 04:53, 27 November 2023
Basic Info | |||||||
---|---|---|---|---|---|---|---|
Addressing Mode | Opcode | Length | Speed | ||||
Immediate | 88 | 2 bytes | 2 cycles | ||||
Implied (type 1) | 86 | 1 byte | 3 cycles | ||||
Direct Page | 84 | 2 bytes | 3 cycles | ||||
Direct Page Indexed by X | 94 | 2 bytes | 3 cycles | ||||
Absolute | 85 | 3 bytes | 4 cycles | ||||
Absolute Indexed by X | 95 | 3 bytes | 5 cycles | ||||
Absolute Indexed by Y | 96 | 3 bytes | 5 cycles | ||||
Direct Page Indexed by X | 87 | 2 bytes | 6 cycles | ||||
Direct Page Indirect Indexed by Y | 97 | 2 bytes | 6 cycles | ||||
Implied (type 1) | 99 | 1 byte | 5 cycles | ||||
Direct Page | 89 | 3 bytes | 6 cycles | ||||
Direct Page Immediate | 98 | 3 bytes | 5 cycles |
Flags Clobbered | |||||||
---|---|---|---|---|---|---|---|
N | V | P | B | H | I | Z | C |
. | . | . |
ADC (Add with Carry) is an SPC700 instruction that adds the value of the two operands together (along with the carry flag) and stores the sum in the left operand. Often, the left operand is the accumulator.
The operands are stored in the instruction stream in the opposite order they appear in the assembler source. In the assembler source, the operand on the right is the source and the operand on the left is the destination.
See Also
External Links
- Official Super Nintendo development manual on ADC: Table C-7 in Appendix C-5 of Book I