diff options
author | Vas Crabb <vas@vastheman.com> | 2018-02-19 20:34:33 +1100 |
---|---|---|
committer | Vas Crabb <vas@vastheman.com> | 2018-02-19 20:34:33 +1100 |
commit | 8b1bc128e5568a713bc280d78623fcb3f7805b2a (patch) | |
tree | bc20f49cedae1f436469e6442cb3240b3882f37f /src/mame/drivers/tempest.cpp | |
parent | 1d31c19472f4c63955dcfba1f7e393bbe553afda (diff) |
backport lots of cleanup from WIP branch (nw)
Diffstat (limited to 'src/mame/drivers/tempest.cpp')
-rw-r--r-- | src/mame/drivers/tempest.cpp | 36 |
1 files changed, 20 insertions, 16 deletions
diff --git a/src/mame/drivers/tempest.cpp b/src/mame/drivers/tempest.cpp index df4a12e4777..5426037c77a 100644 --- a/src/mame/drivers/tempest.cpp +++ b/src/mame/drivers/tempest.cpp @@ -287,8 +287,8 @@ Note: Roms for Tempest Analog Vector-Generator PCB Assembly A037383-03 or A03738 #include "speaker.h" -#define MASTER_CLOCK (XTAL(12'096'000)) -#define CLOCK_3KHZ (MASTER_CLOCK / 4096) +static constexpr XTAL MASTER_CLOCK = 12.096_MHz_XTAL; +static constexpr XTAL CLOCK_3KHZ = MASTER_CLOCK / 4096; #define TEMPEST_KNOB_P1_TAG "KNOBP1" #define TEMPEST_KNOB_P2_TAG "KNOBP2" @@ -313,6 +313,24 @@ public: m_in2(*this, "IN2") { } + DECLARE_CUSTOM_INPUT_MEMBER(tempest_knob_r); + DECLARE_CUSTOM_INPUT_MEMBER(tempest_buttons_r); + DECLARE_CUSTOM_INPUT_MEMBER(clock_r); + void tempest(machine_config &config); + +protected: + DECLARE_WRITE8_MEMBER(wdclr_w); + DECLARE_WRITE8_MEMBER(tempest_led_w); + DECLARE_WRITE8_MEMBER(tempest_coin_w); + DECLARE_READ8_MEMBER(input_port_1_bit_r); + DECLARE_READ8_MEMBER(input_port_2_bit_r); + + DECLARE_READ8_MEMBER(rom_ae1f_r); + + virtual void machine_start() override; + void main_map(address_map &map); + +private: required_device<cpu_device> m_maincpu; required_device<mathbox_device> m_mathbox; required_device<watchdog_timer_device> m_watchdog; @@ -327,20 +345,6 @@ public: required_ioport m_in2; uint8_t m_player_select; - DECLARE_WRITE8_MEMBER(wdclr_w); - DECLARE_WRITE8_MEMBER(tempest_led_w); - DECLARE_WRITE8_MEMBER(tempest_coin_w); - DECLARE_CUSTOM_INPUT_MEMBER(tempest_knob_r); - DECLARE_CUSTOM_INPUT_MEMBER(tempest_buttons_r); - DECLARE_CUSTOM_INPUT_MEMBER(clock_r); - DECLARE_READ8_MEMBER(input_port_1_bit_r); - DECLARE_READ8_MEMBER(input_port_2_bit_r); - - DECLARE_READ8_MEMBER(rom_ae1f_r); - - virtual void machine_start() override; - void tempest(machine_config &config); - void main_map(address_map &map); }; |