
...Works as "LD %X, 0157D"
...Works as "ADD %X, 0xB84F"
...Works as "CMP %X, 0x19A2"
∗19H = FFH - [EXT] (E6H)
Above examples use the X register, but they work the same even when the Y register is used.
Note: The CMP instruction performs a subtraction with a complement, therefore it is necessary to set the complement (1’s complement) of the
EXT register ← [FFH -
•8-bit absolute addressing
The
Instructions that operate in the 8-bit absolute addressing mode with the E flag
Instruction | Operand |
|
|
|
|
|
|
| |
LD | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
EX | %r,[%X] | %r,[%Y] |
|
|
|
|
| ||
ADD | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
ADC | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
| %B,[%X],n4 | %B,[%Y],n4 | [%X],%B,n4 | [%Y],%B,n4 |
| ||||
| [%X],0,n4 |
| [%Y],0,n4 |
|
|
|
| ||
SUB | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
SBC | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
| %B,[%X],n4 | %B,[%Y],n4 | [%X],%B,n4 | [%Y],%B,n4 |
| ||||
| [%X],0,n4 |
| [%Y],0,n4 |
|
|
|
| ||
INC | [%X],n4 | [%Y],n4 |
|
|
|
|
| ||
DEC | [%X],n4 | [%Y],n4 |
|
|
|
|
| ||
CMP | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
AND | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
OR | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
XOR | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
BIT | %r,[%X] | %r,[%Y] | [%X],%r | [%Y],%r | [%X],imm4 | [%Y],imm4 | |||
SLL | [%X] | [%Y] |
|
|
|
|
|
| |
SRL | [%X] | [%Y] |
|
|
|
|
|
| |
RL | [%X] | [%Y] |
|
|
|
|
|
| |
RR | [%X] | [%Y] |
|
|
|
|
|
|
∗"r" indicates the A or B register. Instructions with an operand other than above or the
Examples: |
| |
LDB | %EXT,0x37 |
|
LD | %A,[%X] | ...Works as "LD %A, [0x0037]" |
LDB | %EXT,0x9C |
|
ADD | [%Y],5 | ...Works as "ADD [0xFF9C]" |
36 | EPSON | S1C63000 CORE CPU MANUAL |