summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/machine/tmp68301.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/machine/tmp68301.h')
-rw-r--r--src/devices/machine/tmp68301.h24
1 files changed, 7 insertions, 17 deletions
diff --git a/src/devices/machine/tmp68301.h b/src/devices/machine/tmp68301.h
index e019387802b..c350b9b0be6 100644
--- a/src/devices/machine/tmp68301.h
+++ b/src/devices/machine/tmp68301.h
@@ -16,27 +16,19 @@
-class tmp68301_device : public device_t,
- public device_memory_interface
+class tmp68301_device : public m68000_device
{
public:
tmp68301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
- template <typename T> void set_cputag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } // FIXME: M68000 ought to be a parent class, not an external object
auto in_parallel_callback() { return m_in_parallel_cb.bind(); }
auto out_parallel_callback() { return m_out_parallel_cb.bind(); }
- // Hardware Registers
- DECLARE_READ16_MEMBER( regs_r );
- DECLARE_WRITE16_MEMBER( regs_w );
-
// Interrupts
void external_interrupt_0();
void external_interrupt_1();
void external_interrupt_2();
- IRQ_CALLBACK_MEMBER(irq_callback);
-
private:
DECLARE_READ16_MEMBER(imr_r);
DECLARE_WRITE16_MEMBER(imr_w);
@@ -53,13 +45,18 @@ private:
DECLARE_READ8_MEMBER(icr_r);
DECLARE_WRITE8_MEMBER(icr_w);
+ // Hardware Registers
+ DECLARE_READ16_MEMBER( regs_r );
+ DECLARE_WRITE16_MEMBER( regs_w );
+
void tmp68301_regs(address_map &map);
+ IRQ_CALLBACK_MEMBER(irq_callback);
+
protected:
// device-level overrides
virtual void device_start() override;
virtual void device_reset() override;
- virtual space_config_vector memory_space_config() const override;
private:
TIMER_CALLBACK_MEMBER(timer_callback);
@@ -78,11 +75,6 @@ private:
static constexpr uint16_t TIMER1_IRQ = 1 << 9;
static constexpr uint16_t TIMER2_IRQ = 1 << 10;
- inline uint16_t read_word(offs_t address);
- inline void write_word(offs_t address, uint16_t data);
-
- required_device<m68000_base_device> m_cpu;
-
devcb_read16 m_in_parallel_cb;
devcb_write16 m_out_parallel_cb;
@@ -100,8 +92,6 @@ private:
uint16_t m_pdir;
uint16_t m_pdr;
uint8_t m_icr[10];
-
- const address_space_config m_space_config;
};
DECLARE_DEVICE_TYPE(TMP68301, tmp68301_device)