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H
1
3
DBNZX
2
INH
1
3
4
DBNZ
2
IX
3
2
PSHH
INH
1
1
2
2
3
3
4
2
3
ADD
1
IX
2
C
5
BRSET6
3
DIR
5
BSET6
2
DIR
4
2
4
INC
DIR
3
TST
DIR
2
INCA
INH
1
TSTA
INH
5
MOV
DD
1
CLRA
INH
1
INCX
INH
1
TSTX
INH
4
MOV
2 DIX+
1
2
3
INC
1
IX
2
1
CLRH
INH
1
1
2
3
3
2
JMP
1
IX
4
D
BRCLR6
3
DIR
BCLR6
2
DIR
4
2
2
1
1
2
3
TST
1
IX
4
1
4
BSR
REL
2
LDX
IMM
2
AIX
IMM
2
2
3
3
2
JSR
1
IX
2
E
5
BRSET7
3
DIR
5
BSET7
2
DIR
4
2
3
3
MOV
2 IX+D
1
STOP
INH
1
*
2
2
3
3
5
LDX
SP2
5
STX
SP2
4
2
4
LDX
SP1
4
STX
SP1
3
LDX
1
IX
2
F
BRCLR7
3
DIR
BCLR7
2
DIR
2
3
CLR
DIR
2
1
1
CLRX
INH
1
2
4
CLR
SP1
3
2
CLR
1
IX
1
WAIT
INH
1
1
TXA
INH
1
2
2
3
3
4
2
3
STX
1
IX
INH Inherent
IMM Immediate
DIR Direct
EXT Extended
DD
Direct-Direct
IX+D Indexed-Direct
*
Pre-byte for stack pointer indexed instructions
REL Relative
IX
Indexed, No Offset
IX1
Indexed, 8-Bit Offset
IX2
Indexed, 16-Bit Offset
IMD Immediate-Direct
DIX+ Direct-Indexed
SP1 Stack Pointer, 8-Bit Offset
SP2 Stack Pointer, 16-Bit Offset
IX+
Indexed, No Offset with
Post Increment
IX1+ Indexed, 1-Byte Offset with
Post Increment
0
High Byte of Opcode in Hexadecimal
Low Byte of Opcode in Hexadecimal
0
5
BRSET0
3
DIR
Cycles
Opcode Mnemonic
Number of Bytes / Addressing Mode
MSB
LSB
MSB
LSB