FANDOM


Cpu






A full version of the Crib sheet below can be downloaded in Word format from the Crib Sheets page.


6502 Crib Sheet

CPU Model

A

Accumulator

X

Y

Index Registers

PCH

PCL

Program Counter

SP

Stack Pointer

N

V

*

B

D

I

Z

C

Status Register

Status Flags

Logic Operators

C

- Carry

Opcode

Description

Store

Flags

Z

- Zero

AND

Acc AND memory 

Acc

Z, N

I

- Interrupt

D

- Decimal  

ORA

Acc OR memory 

Acc

Z, N

B

- BRK 

*

- Unused

EOR

Acc EOR memory 

Acc

Z, N

V

- Oveflow  

N

- Negative 

BIT

Acc AND memory

No

Z, V, N

Addressing Mode

Form

Description

Implied

Opcode

No parameter

Immediate 

OpCode  #1BN

1BN is Data

Absolute 

OpCode    2BN

2BN is memory location of Data

Zero page 

OpCode  #1BN

1BN is memory location of Data (MSB always 0)

Relative

OpCode    1BN

1BN plus PC is memory location of Data

Indirect

OpCode   (2BN)

2BN is address of memory location of Data

Absolute Indexed

OpCode    2BN, X/Y

2BN plus register is memory location of data

Zero Page Indexed

OpCode    1BN, X/Y

1BN plus register is memory location of data (MSB always 0)

Pre-indexed Indirect

OpCode   (1BN, X/Y)

1BN plus register is address of memory location of Data

Post-indexed Indirect

OpCode   (1BN), X/Y

1BN is zero page location of a 2BN pointer which added to register is address of memory location of Data

Instruction Addressing Modes

Instruction

Mode

LDX, LDY

Immediate

Absolute

Zero page

Zero Page Indexed

Absolute Indexed

STX, STY

Absolute

Zero page

Zero Page Indexed

BCC, BCS, BEQ, BMI, BNE, BPL, BVC, BVS

Implied

ADC, SBC, CMP, AND, EOR, ORA, LDA, STA

Immediate (not STA)

Absolute

Zero Page

Absolute Indexed

Zero Page Indexed (X only)

Pre-indexed Indirect(X only)

Post-indexed Indirect (Y only)

BIT, CPX, CPY

Implied

Absolute

Zero Page

DEC, INC

Absolute

Zero page

Zero Page Indexed (X only)

Absolute Indexed (X only)

JMP, JSR

Absolute

Indirect (JMP only)

ASL, LSR, ROL, ROR

Implied

Absolute

Zero Page

Absolute Indexed (X only)

Zero Page Indexed (X only)

Branch on Status Flag

Flag

Description

Branch if Set

Branch if Not Set

Clear

C

Carry -greater/equal

BCS

BCC

CLC

Z

Zero - equal

BEQ

BNE

-

V

Overflow - signed arithmetic

BVS

BVC

CLV

N

Negative - high bit

BMI

BPL

-