mirror of
https://github.com/rkujawa/rk65c02.git
synced 2025-03-03 14:29:23 +00:00
Add structs representing current emulator state.
This commit is contained in:
parent
d515954f44
commit
aa362b81fd
@ -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
|
||||
|
Loading…
x
Reference in New Issue
Block a user