diff --git a/src/rk65c02.h b/src/rk65c02.h index d2ac28b..803d59f 100644 --- a/src/rk65c02.h +++ b/src/rk65c02.h @@ -18,6 +18,12 @@ typedef enum { IABSOLUTEX } addressing_t; +typedef enum { + STOPPED, + RUNNIG, + STEPPING +} emu_state_t; + struct reg_state { uint8_t A; /* accumulator */ uint8_t X; /* index X */ @@ -48,6 +54,14 @@ struct instruction { typedef struct instruction instruction_t; +struct rk65c02emu { + emu_state_t state; + bus_t bus; + reg_state_t regs; +} + +typedef struct rk65c02emu rk65c02emu_t; + #define OP_BRK 0x00 #define OP_TSB_ZP 0x04 #define OP_JSR 0x20