模擬器 - Nintendo Entertainment System - OP Code



參考資料:
http://nesdev.com/6502.txt
http://wiki.nesdev.com/w/index.php/Nesdev_Wiki
http://www.6502.org/tutorials/6502opcodes.html
https://www.masswerk.at/6502/6502_instruction_set.html

x0 x1 x2 x3 x4 x5 x6 x7 x8 x9 xA xB xC xD xE xF
0x BRK ORA X, ind ORA zero ASL zero PHP ORA # ASL A ORA abs ASL abs
1x BPL rel ORA ind, Y ORA zero, X ASL zero, X CPC ORA abs, Y ORA abs, X ASL abs, X
2x JSR abs AND X, ind BIT zero AND zero ROL zero PLP AND # ROL A BIT abs AND abs ROL abs
3x BMI rel AND ind, Y AND zero, X ROL zero, X SEC AND abs, Y AND abs, X ROL abs, X
4x RTI EOR X, ind EOR zero LSR zero PHA EOR # LSR A JMP abs EOR abs LSR abs
5x BVC rel EOR ind, Y EOR zero, X LSR zero, X CLI EOR abs, Y EOR abs, X LSR abs, X
6x RTS ADC X, ind ADC zero ROR zero PLA ADC # ROR A JMP ind ADC abs ROR abs
7x BVS rel ADC ind, Y ADC zero, X ROR zero, X SEI ADC abs, Y ADC abs, X ROR abs, X
8x STA X, ind STY zero STA zero STX zero DEY TXA STY abs STA abs STX abs
9x BCC rel STA ind, Y STY zero, X STA zero, X STX zero, X TYA STA abs, Y TXS STA abs, X
Ax LDY # LDA X, ind LDX # LDY zero LDA zero LDX zero TAY LDA # TAX LDY abs LDA abs LDX abs
Bx BCS rel LDA ind, Y LDY zero, X LDA zero, X LDX zero, Y CLV LDA abs, Y TSX LDY abs, X LDA abs, X LDX abs, Y
Cx CPY # CMP X, ind CPY zero CMP zero DEC zero INY CMP # DEX CPY abs CMP abs DEC abs
Dx BNE rel CMP ind, Y CMP zero, X DEC zero, X CLD CMP abs, Y CMP abs, X DEC abs, X
Ex CPX # SBC X, ind CPX zero SBC zero INC zero INX SBC # NOP CPX abs SBC abs INC abs
Fx BEQ rel SBC ind, Y SBC zero, X INC zero, X SED SBC abs, Y SBC abs, X INC abs, X

Cycles

AssemblyOpodeBytesCycles
ADC #Immediate6922
ADC ZeroPage6523
ADC ZeroPage,X7524
ADC Absolute6034
ADC Absolute,X7034*
ADC Absolute,Y7934*
ADC (Indirect,X)6126
ADC (Indirect),Y7125*
AND #Immediate2922
AND ZeroPage2523
AND ZeroPage,X3524
AND Absolute2D34
AND Absolute,X3D34*
AND Absolute,Y3934*
AND (Indirect,X)2126
AND (Indirect),Y3125
ASL A0A12
ASL ZeroPage0625
ASL ZeroPage,X1626
ASL Absolute0E36
ASL Absolute,X1E37
BCC Relative9022*
BCS RelativeB022*
BEQ RelativeF022*
BIT ZeroPage2423
BIT Absolute2C34
BMI Relative3022*
BNE RelativeD022*
BPL Relative1022*
BRK0017
BVC Relative5022*
BVS Relative7022*
CLC1812
CLDD812
CLI5812
CLVB812
CMP #ImmediateC922
CMP ZeroPageC523
CMP ZeroPage,XD524
CMP AbsoluteCD34
CMP Absolute,XDD34*
CMP Absolute,YD934*
CMP (Indirect,X)C126
CMP (Indirect),YD125*
CPX #ImmediateE022
CPX ZeroPageE423
CPX AbsoluteEC34
CPY #ImmediateC022
CPY ZeroPageC423
CPY AbsoluteCC34
DEC ZeroPageC625
DEC ZeroPage,XD626
DEC AbsoluteCE36
DEC Absolute,XDE37
DEXCA12
DEY8812
EOR #Immediate4922
EOR ZeroPage4523
EOR ZeroPage,X5524
EOR Absolute4034
EOR Absolute,X5034*
EOR Absolute,Y5934*
EOR (Indirect,X)4126
EOR (Indirect),Y5125*
INC ZeroPageE625
INC ZeroPage,XF626
INC AbsoluteEE36
INC Absolute,XFE37
INXE812
INYC812
JMP Absolute4C33
JMP Indirect6C35
JSR Absolute2036
LDA #ImmediateA922
LDA ZeroPageA523
LDA ZeroPage,XB524
LDA AbsoluteAD34
LDA Absolute,XBD34*
LDA Absolute,YB934*
LDA (Indirect,X)A126
LDA (Indirect),YB125*
LDA #ImmediateA222
LDA ZeroPageA623
LDA ZeroPage,YB624
LDA AbsoluteAE34
LDA Absolute,YBE34*
LDY #ImmediateA022
LDY ZeroPageA423
LDY ZeroPage,XB424
LDY AbsoluteAC34
LDY Absolute,XBC34*
LSR A4A12
LSR ZeroPage4625
LSR ZeroPage,X5626
LSR Absolute4E36
LSR Absolute,X5E37
NOPEA12
ORA #Immediate0922
ORA ZeroPage0523
ORA ZeroPage,X1524
ORA Absolute0D34
ORA Absolute,X1D34*
ORA Absolute,Y1934*
ORA (Indirect,X)0126
ORA (Indirect),Y1125
PHA4813
PHP0813
PLA6814
PLP2814
ROR A2A12
ROL ZeroPage2625
ROL ZeroPage,X3626
ROL Absolute2E36
ROL Absolute,X3E37
ROR A6A12
ROR ZeroPage6625
ROR ZeroPage,X7626
ROR Absolute6E36
ROR Absolute,X7E37
RTI4D16
RTS6016
SBC #ImmediateE922
SBC ZeroPageE523
SBC ZeroPage,XF524
SBC AbsoluteED34
SBC Absolute,XFD34*
SBC Absolute,YF934*
SBC (Indirect,X)E126
SBC (Indirect),YF125
SEC3812
SEDF812
SEI7812
STA ZeroPage8523
STA ZeroPage,X9524
STA Absolute8034
STA Absolute,X9035
STA Absolute,Y9935
STA (Indirect,X)8126
STA (Indirect),Y9126
STX ZeroPage8623
STX ZeroPage,Y9624
STX Absolute8E34
STY ZeroPage8423
STY ZeroPage,X9424
STY Absolute8C34
TAXAA12
TAYA812
TSXBA12
TXA8A12
TXS9A12
TYA9812