summaryrefslogtreecommitdiff
path: root/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpu.c')
-rw-r--r--cpu.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/cpu.c b/cpu.c
index 0bbbc75..edfe172 100644
--- a/cpu.c
+++ b/cpu.c
@@ -4,6 +4,8 @@
4#include <stdlib.h> 4#include <stdlib.h>
5#include <string.h> 5#include <string.h>
6 6
7#include "cpu.h"
8#include "opcodes.h"
7#include "rom.h" 9#include "rom.h"
8 10
9#define MAX(a, b) ((a > b) ? a : b) 11#define MAX(a, b) ((a > b) ? a : b)
@@ -52,22 +54,6 @@ struct registers regs = {0};
52 54
53struct Rom rom = {0}; 55struct Rom rom = {0};
54 56
55enum addressing_mode {
56 AM_ACC,
57 AM_IMPLICIT,
58 AM_IMM,
59 AM_ZP,
60 AM_ZP_X,
61 AM_ZP_Y,
62 AM_REL,
63 AM_ABS,
64 AM_ABS_X,
65 AM_ABS_Y,
66 AM_IND,
67 AM_IND_X,
68 AM_IND_Y,
69};
70
71/* 64K address space, 16bit words */ 57/* 64K address space, 16bit words */
72uint8_t memory[0x16000]; 58uint8_t memory[0x16000];
73 59