summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/cpu/tms1000/tms1k_base.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/cpu/tms1000/tms1k_base.cpp')
-rw-r--r--src/devices/cpu/tms1000/tms1k_base.cpp19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/devices/cpu/tms1000/tms1k_base.cpp b/src/devices/cpu/tms1000/tms1k_base.cpp
index 3f14dba6c5e..432e43e0d7b 100644
--- a/src/devices/cpu/tms1000/tms1k_base.cpp
+++ b/src/devices/cpu/tms1000/tms1k_base.cpp
@@ -90,9 +90,6 @@ tms1k_base_device::tms1k_base_device(const machine_config &mconfig, device_type
, m_write_o(*this)
, m_write_r(*this)
, m_power_off(*this)
- , m_read_ctl(*this)
- , m_write_ctl(*this)
- , m_write_pdc(*this)
{
}
@@ -134,9 +131,6 @@ void tms1k_base_device::device_start()
m_write_o.resolve_safe();
m_write_r.resolve_safe();
m_power_off.resolve_safe();
- m_read_ctl.resolve_safe(0);
- m_write_ctl.resolve_safe();
- m_write_pdc.resolve_safe();
// zerofill
m_pc = 0;
@@ -153,6 +147,7 @@ void tms1k_base_device::device_start()
m_r = 0;
m_o = 0;
m_o_index = 0;
+ m_halt_pin = false;
m_cki_bus = 0;
m_c4 = 0;
m_p = 0;
@@ -192,6 +187,7 @@ void tms1k_base_device::device_start()
save_item(NAME(m_r));
save_item(NAME(m_o));
save_item(NAME(m_o_index));
+ save_item(NAME(m_halt_pin));
save_item(NAME(m_cki_bus));
save_item(NAME(m_c4));
save_item(NAME(m_p));
@@ -301,7 +297,7 @@ void tms1k_base_device::read_opcode()
{
debugger_instruction_hook(m_rom_address);
m_opcode = m_program->read_byte(m_rom_address);
- m_c4 = bitswap<4>(m_opcode,0,1,2,3); // opcode operand is bitswapped for most opcodes
+ m_c4 = bitswap<8>(m_opcode,7,6,5,4,0,1,2,3) & 0xf; // opcode operand is bitswapped for most opcodes
m_fixed = m_fixed_decode[m_opcode];
m_micro = m_micro_decode[m_opcode];
@@ -315,6 +311,15 @@ void tms1k_base_device::read_opcode()
// i/o handling
//-------------------------------------------------
+void tms1k_base_device::execute_set_input(int line, int state)
+{
+ if (line != TMS1XXX_INPUT_LINE_HALT)
+ return;
+
+ // HALT pin (CMOS only)
+ m_halt_pin = bool(state);
+}
+
void tms1k_base_device::write_o_output(u8 index)
{
// a hardcoded table is supported if the output pla is unknown