diff options
Diffstat (limited to 'src/devices/cpu/h6280/h6280.cpp')
-rw-r--r-- | src/devices/cpu/h6280/h6280.cpp | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/src/devices/cpu/h6280/h6280.cpp b/src/devices/cpu/h6280/h6280.cpp index 96ecb18534d..7bb01c3f6d5 100644 --- a/src/devices/cpu/h6280/h6280.cpp +++ b/src/devices/cpu/h6280/h6280.cpp @@ -113,7 +113,6 @@ #include "emu.h" #include "h6280.h" #include "6280dasm.h" -#include "debugger.h" /* 6280 flags */ enum @@ -173,7 +172,7 @@ h6280_device::h6280_device(const machine_config &mconfig, const char *tag, devic , device_mixer_interface(mconfig, *this, 2) , m_program_config("program", ENDIANNESS_LITTLE, 8, 21, 0, 16, 0, address_map_constructor(FUNC(h6280_device::internal_map), this)) , m_io_config("io", ENDIANNESS_LITTLE, 8, 2) - , m_port_in_cb(*this) + , m_port_in_cb(*this, 0) , m_port_out_cb(*this) , m_psg(*this, "psg") , m_timer_scale(1) @@ -239,9 +238,6 @@ void h6280_device::device_add_mconfig(machine_config &config) void h6280_device::device_start() { - m_port_in_cb.resolve(); - m_port_out_cb.resolve_safe(); - // register our state for the debugger state_add(STATE_GENPC, "GENPC", m_pc.w.l).noshow(); state_add(STATE_GENPCBASE, "CURPC", m_pc.w.l).noshow(); @@ -414,14 +410,14 @@ inline void h6280_device::check_and_take_irq_lines() if ( m_irq_state[0] != CLEAR_LINE && !(m_irq_mask & 0x2) ) { + standard_irq_callback(0, PCW); do_interrupt(H6280_IRQ1_VEC); - standard_irq_callback(0); } else if ( m_irq_state[1] != CLEAR_LINE && !(m_irq_mask & 0x1) ) { + standard_irq_callback(1, PCW); do_interrupt(H6280_IRQ2_VEC); - standard_irq_callback(1); } } } @@ -2583,7 +2579,7 @@ void h6280_device::timer_w(offs_t offset, uint8_t data) uint8_t h6280_device::port_r() { - if (!m_port_in_cb.isnull()) + if (!m_port_in_cb.isunset()) return m_port_in_cb(); else return m_io_buffer; @@ -2607,8 +2603,9 @@ void h6280_device::psg_w(offs_t offset, uint8_t data) m_psg->c6280_w(offset, data); } -bool h6280_device::memory_translate(int spacenum, int intention, offs_t &address) +bool h6280_device::memory_translate(int spacenum, int intention, offs_t &address, address_space *&target_space) { + target_space = &space(spacenum); if (spacenum == AS_PROGRAM) address = translated(address); |