diff options
Diffstat (limited to 'src/mame/includes/metalmx.h')
-rw-r--r-- | src/mame/includes/metalmx.h | 53 |
1 files changed, 32 insertions, 21 deletions
diff --git a/src/mame/includes/metalmx.h b/src/mame/includes/metalmx.h index f9725703eca..ed8da93bc29 100644 --- a/src/mame/includes/metalmx.h +++ b/src/mame/includes/metalmx.h @@ -1,5 +1,10 @@ // license:BSD-3-Clause // copyright-holders:Philip Bennett +#ifndef MAME_INCLUDES_METALMX_H +#define MAME_INCLUDES_METALMX_H + +#pragma once + #include "audio/cage.h" #include "cpu/adsp2100/adsp2100.h" @@ -10,29 +15,23 @@ class metalmx_state : public driver_device { public: - metalmx_state(const machine_config &mconfig, device_type type, const char *tag) - : driver_device(mconfig, type, tag), - m_maincpu(*this, "maincpu"), - m_gsp(*this, "gsp"), - m_adsp(*this, "adsp"), - m_dsp32c_1(*this, "dsp32c_1"), - m_dsp32c_2(*this, "dsp32c_2"), - m_cage(*this, "cage"), + metalmx_state(const machine_config &mconfig, device_type type, const char *tag) : + driver_device(mconfig, type, tag), + m_maincpu(*this, "maincpu"), + m_gsp(*this, "gsp"), + m_adsp(*this, "adsp"), + m_dsp32c_1(*this, "dsp32c_1"), + m_dsp32c_2(*this, "dsp32c_2"), + m_cage(*this, "cage"), m_adsp_internal_program_ram(*this, "adsp_intprog"), m_gsp_dram(*this, "gsp_dram"), - m_gsp_vram(*this, "gsp_vram"){ } - - required_device<m68ec020_device> m_maincpu; - required_device<tms34020_device> m_gsp; - required_device<adsp2105_device> m_adsp; - required_device<dsp32c_device> m_dsp32c_1; - required_device<dsp32c_device> m_dsp32c_2; - required_device<atari_cage_device> m_cage; + m_gsp_vram(*this, "gsp_vram") + { } - required_shared_ptr<uint32_t> m_adsp_internal_program_ram; - required_shared_ptr<uint16_t> m_gsp_dram; - required_shared_ptr<uint16_t> m_gsp_vram; + DECLARE_DRIVER_INIT(metalmx); + void metalmx(machine_config &config); +protected: DECLARE_READ32_MEMBER(unk_r); DECLARE_READ32_MEMBER(watchdog_r); DECLARE_WRITE32_MEMBER(shifter_w); @@ -51,16 +50,28 @@ public: DECLARE_READ32_MEMBER(host_vram_r); DECLARE_WRITE32_MEMBER(host_vram_w); DECLARE_WRITE32_MEMBER(timer_w); - DECLARE_DRIVER_INIT(metalmx); DECLARE_WRITE8_MEMBER(cage_irq_callback); virtual void machine_reset() override; virtual void video_start() override; uint32_t screen_update_metalmx(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); - void metalmx(machine_config &config); void adsp_data_map(address_map &map); void adsp_program_map(address_map &map); void dsp32c_1_map(address_map &map); void dsp32c_2_map(address_map &map); void gsp_map(address_map &map); void main_map(address_map &map); + +private: + required_device<m68ec020_device> m_maincpu; + required_device<tms34020_device> m_gsp; + required_device<adsp2105_device> m_adsp; + required_device<dsp32c_device> m_dsp32c_1; + required_device<dsp32c_device> m_dsp32c_2; + required_device<atari_cage_device> m_cage; + + required_shared_ptr<uint32_t> m_adsp_internal_program_ram; + required_shared_ptr<uint16_t> m_gsp_dram; + required_shared_ptr<uint16_t> m_gsp_vram; }; + +#endif // MAME_INCLUDES_METALMX_H |