summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/cpu/vt61/vt61.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/cpu/vt61/vt61.h')
-rw-r--r--src/devices/cpu/vt61/vt61.h26
1 files changed, 25 insertions, 1 deletions
diff --git a/src/devices/cpu/vt61/vt61.h b/src/devices/cpu/vt61/vt61.h
index c2aa2d39f6b..971343fe095 100644
--- a/src/devices/cpu/vt61/vt61.h
+++ b/src/devices/cpu/vt61/vt61.h
@@ -13,7 +13,7 @@ public:
VT61_PC,
VT61_AC,
VT61_MAR, VT61_MALO, VT61_MAHI,
- VT61_MDR,
+ VT61_MD, VT61_MDR,
VT61_IR,
VT61_R0, VT61_R1, VT61_R2, VT61_R3,
VT61_R4, VT61_R5, VT61_R6, VT61_R7,
@@ -47,6 +47,26 @@ protected:
void state_string_export(const device_state_entry &entry, std::string &str) const override;
private:
+ enum class state : u8 {
+ T1, T2, T3, T4, T5, T6, T7, T8, T9, T10
+ };
+
+ enum class pc_mode : u8 {
+ CLR, INC, LD
+ };
+
+ enum pv_flags : u8 {
+ CARRY_OUT = 1 << 0,
+ EQUAL = 1 << 1,
+ MDR_OF_OUT = 1 << 2
+ };
+
+ // instruction helpers
+ u8 get_db(u16 i);
+ bool branch_mux(u8 cond);
+ void operate_t5(u16 i);
+ void operate_t8(u16 i);
+
// address spaces
address_space_config m_program_config;
address_space_config m_memory_config;
@@ -56,9 +76,13 @@ private:
memory_access< 6, 0, 0, ENDIANNESS_LITTLE>::cache m_idr_cache;
// processor state
+ state m_time_state;
u16 m_pc;
+ pc_mode m_pc_mode;
+ u8 m_pv_flags;
u8 m_ac;
u16 m_mar;
+ u8 m_md; // memory output
u8 m_mdr;
u8 m_ir;
u8 m_sp[16]; // scratchpad memory