nesemu/cpu/op.h

21 lines
536 B
C

#include "../include/cpu.h"
#ifndef CPU_OP_H
#define CPU_OP_H
// The number associated with each op code is the matching line of the ALU op code.
// Based on the table here: https://www.nesdev.org/wiki/CPU_unofficial_opcodes
enum op_code_base {
OP_CODE_BASE_ORA = 0x00,
OP_CODE_BASE_AND = 0x20,
OP_CODE_BASE_EOR = 0x40,
OP_CODE_BASE_ADC = 0x60,
OP_CODE_BASE_STA = 0x80,
OP_CODE_BASE_LDA = 0xa0,
OP_CODE_BASE_CMP = 0xc0,
OP_CODE_BASE_SBC = 0xe0
};
void process_op_code(System *system, byte op);
#endif