diff options
Diffstat (limited to 'src/devices/machine/k056230.h')
-rw-r--r-- | src/devices/machine/k056230.h | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/src/devices/machine/k056230.h b/src/devices/machine/k056230.h index 6c8ae121460..7df76c26e53 100644 --- a/src/devices/machine/k056230.h +++ b/src/devices/machine/k056230.h @@ -2,7 +2,7 @@ // copyright-holders:Fabio Priuli /*************************************************************************** - Konami 056230 + Konami 056230 LAN controller skeleton device ***************************************************************************/ @@ -15,35 +15,25 @@ class k056230_device : public device_t { public: // construction/destruction - template <typename T> - k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : k056230_device(mconfig, tag, owner, (uint32_t)0) - { - m_cpu.set_tag(std::forward<T>(cpu_tag)); - } + k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); - k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + auto irq_cb() { return m_irq_cb.bind(); } - void set_thunderh_hack(bool thunderh) { m_is_thunderh = thunderh; } + u32 ram_r(offs_t offset, u32 mem_mask = ~0); + void ram_w(offs_t offset, u32 data, u32 mem_mask = ~0); - DECLARE_READ32_MEMBER(lanc_ram_r); - DECLARE_WRITE32_MEMBER(lanc_ram_w); - - DECLARE_READ8_MEMBER(read); - DECLARE_WRITE8_MEMBER(write); - - TIMER_CALLBACK_MEMBER(network_irq_clear); + u8 regs_r(offs_t offset); + void regs_w(offs_t offset, u8 data); protected: // device-level overrides virtual void device_start() override; -private: - - bool m_is_thunderh; + memory_share_creator<u32> m_ram; - required_device<cpu_device> m_cpu; - uint32_t m_ram[0x2000]; + devcb_write_line m_irq_cb; + int m_irq_state; + u8 m_ctrl_reg; }; |