diff --git a/scripts/target/mame/arcade.lua b/scripts/target/mame/arcade.lua index 44e7d5dd37e..7902a86ae4f 100644 --- a/scripts/target/mame/arcade.lua +++ b/scripts/target/mame/arcade.lua @@ -4693,11 +4693,8 @@ files { MAME_DIR .. "src/mame/drivers/s11.cpp", MAME_DIR .. "src/mame/includes/s11.h", MAME_DIR .. "src/mame/drivers/s11a.cpp", - MAME_DIR .. "src/mame/includes/s11a.h", MAME_DIR .. "src/mame/drivers/s11b.cpp", - MAME_DIR .. "src/mame/includes/s11b.h", MAME_DIR .. "src/mame/drivers/s11c.cpp", - MAME_DIR .. "src/mame/includes/s11c.h", MAME_DIR .. "src/mame/audio/pinsnd88.cpp", MAME_DIR .. "src/mame/audio/pinsnd88.h", MAME_DIR .. "src/mame/audio/s11c_bg.cpp", diff --git a/src/mame/drivers/s11a.cpp b/src/mame/drivers/s11a.cpp index d76670df158..27daaa3be04 100644 --- a/src/mame/drivers/s11a.cpp +++ b/src/mame/drivers/s11a.cpp @@ -23,7 +23,7 @@ Note: To start a game, certain switches need to be activated. You must first pr *****************************************************************************************/ #include "emu.h" -#include "includes/s11a.h" +#include "includes/s11.h" #include "cpu/m6809/m6809.h" #include "speaker.h" diff --git a/src/mame/drivers/s11b.cpp b/src/mame/drivers/s11b.cpp index d56ab229041..e8e23d23703 100644 --- a/src/mame/drivers/s11b.cpp +++ b/src/mame/drivers/s11b.cpp @@ -42,7 +42,7 @@ */ #include "emu.h" -#include "includes/s11b.h" +#include "includes/s11.h" #include "cpu/m6809/m6809.h" #include "speaker.h" diff --git a/src/mame/drivers/s11c.cpp b/src/mame/drivers/s11c.cpp index ec438e3d20f..33a9e3abfe6 100644 --- a/src/mame/drivers/s11c.cpp +++ b/src/mame/drivers/s11c.cpp @@ -5,7 +5,7 @@ */ #include "emu.h" -#include "includes/s11c.h" +#include "includes/s11.h" #include "cpu/m6809/m6809.h" #include "speaker.h" diff --git a/src/mame/includes/s11.h b/src/mame/includes/s11.h index 8bd831bcaf4..6f54d8f32e4 100644 --- a/src/mame/includes/s11.h +++ b/src/mame/includes/s11.h @@ -80,8 +80,8 @@ public: void dig0_w(uint8_t data); void dig1_w(uint8_t data); void lamp0_w(uint8_t data); - void lamp1_w(uint8_t data) { }; - void sol2_w(uint8_t data) { }; // solenoids 8-15 + void lamp1_w(uint8_t data) { } + void sol2_w(uint8_t data) { } // solenoids 8-15 void sol3_w(uint8_t data); // solenoids 0-7 void sound_w(uint8_t data); @@ -94,11 +94,11 @@ public: DECLARE_WRITE_LINE_MEMBER(pias_ca2_w); DECLARE_WRITE_LINE_MEMBER(pias_cb2_w); DECLARE_WRITE_LINE_MEMBER(pia21_ca2_w); - DECLARE_WRITE_LINE_MEMBER(pia21_cb2_w) { }; // enable solenoids - DECLARE_WRITE_LINE_MEMBER(pia24_cb2_w) { }; // dummy to stop error log filling up - DECLARE_WRITE_LINE_MEMBER(pia28_ca2_w) { }; // comma3&4 - DECLARE_WRITE_LINE_MEMBER(pia28_cb2_w) { }; // comma1&2 - DECLARE_WRITE_LINE_MEMBER(pia30_cb2_w) { }; // dummy to stop error log filling up + DECLARE_WRITE_LINE_MEMBER(pia21_cb2_w) { } // enable solenoids + DECLARE_WRITE_LINE_MEMBER(pia24_cb2_w) { } // dummy to stop error log filling up + DECLARE_WRITE_LINE_MEMBER(pia28_ca2_w) { } // comma3&4 + DECLARE_WRITE_LINE_MEMBER(pia28_cb2_w) { } // comma1&2 + DECLARE_WRITE_LINE_MEMBER(pia30_cb2_w) { } // dummy to stop error log filling up DECLARE_WRITE_LINE_MEMBER(pia_irq); DECLARE_WRITE_LINE_MEMBER(main_irq); @@ -163,4 +163,66 @@ private: bool m_pia_irq_active; }; + +class s11a_state : public s11_state +{ +public: + s11a_state(const machine_config &mconfig, device_type type, const char *tag) + : s11_state(mconfig, type, tag) + { } + + void s11a_base(machine_config &config); + void s11a(machine_config &config); + void s11a_obg(machine_config &config); + + void init_s11a(); + + void dig0_w(uint8_t data); +}; + + +class s11b_state : public s11a_state +{ +public: + s11b_state(const machine_config &mconfig, device_type type, const char *tag) + : s11a_state(mconfig, type, tag) + { } + + void s11b_base(machine_config &config); + void s11b(machine_config &config); + void s11b_jokerz(machine_config &config); + + void init_s11b(); + void init_s11b_invert(); + +protected: + virtual void machine_reset() override; + void set_invert(bool inv) { m_invert = inv; } + + void dig1_w(uint8_t data); + void pia2c_pa_w(uint8_t data); + void pia2c_pb_w(uint8_t data); + void pia34_pa_w(uint8_t data); + +private: + bool m_invert; // later System 11B games start expecting inverted data to the display LED segments. +}; + + +class s11c_state : public s11b_state +{ +public: + s11c_state(const machine_config &mconfig, device_type type, const char *tag) + : s11b_state(mconfig, type, tag) + { } + + void s11c(machine_config &config); + + void init_s11c(); + +protected: + virtual void machine_reset() override; +}; + + #endif // MAME_INCLUDES_S11_H diff --git a/src/mame/includes/s11a.h b/src/mame/includes/s11a.h deleted file mode 100644 index 61e9878dd75..00000000000 --- a/src/mame/includes/s11a.h +++ /dev/null @@ -1,30 +0,0 @@ -// license:BSD-3-Clause -// copyright-holders:Miodrag Milanovic -/* - * s11a.h - * - * Created on: 1/01/2013 - */ - -#ifndef MAME_INCLUDES_S11A_H -#define MAME_INCLUDES_S11A_H - -#include "includes/s11.h" - -class s11a_state : public s11_state -{ -public: - s11a_state(const machine_config &mconfig, device_type type, const char *tag) - : s11_state(mconfig, type, tag) - { } - - void s11a_base(machine_config &config); - void s11a(machine_config &config); - void s11a_obg(machine_config &config); - - void init_s11a(); - - void dig0_w(uint8_t data); -}; - -#endif // MAME_INCLUDES_S11A_H diff --git a/src/mame/includes/s11b.h b/src/mame/includes/s11b.h deleted file mode 100644 index 4436e812525..00000000000 --- a/src/mame/includes/s11b.h +++ /dev/null @@ -1,41 +0,0 @@ -// license:BSD-3-Clause -// copyright-holders:Miodrag Milanovic -/* - * s11b.h - * - * Created on: 1/01/2013 - */ - -#ifndef MAME_INCLUDES_S11B_H -#define MAME_INCLUDES_S11B_H - -#include "includes/s11a.h" - -class s11b_state : public s11a_state -{ -public: - s11b_state(const machine_config &mconfig, device_type type, const char *tag) - : s11a_state(mconfig, type, tag) - { } - - void s11b_base(machine_config &config); - void s11b(machine_config &config); - void s11b_jokerz(machine_config &config); - - void init_s11b(); - void init_s11b_invert(); - -protected: - virtual void machine_reset() override; - void set_invert(bool inv) { m_invert = inv; } - - void dig1_w(uint8_t data); - void pia2c_pa_w(uint8_t data); - void pia2c_pb_w(uint8_t data); - void pia34_pa_w(uint8_t data); - -private: - bool m_invert; // later System 11B games start expecting inverted data to the display LED segments. -}; - -#endif // MAME_INCLUDES_S11B_H diff --git a/src/mame/includes/s11c.h b/src/mame/includes/s11c.h deleted file mode 100644 index 6d7709c0b7c..00000000000 --- a/src/mame/includes/s11c.h +++ /dev/null @@ -1,30 +0,0 @@ -// license:BSD-3-Clause -// copyright-holders:Miodrag Milanovic -/* - * s11c.h - * - * Created on: 1/01/2013 - */ - -#ifndef MAME_INCLUDES_S11C_H -#define MAME_INCLUDES_S11C_H - -#include "includes/s11b.h" - -class s11c_state : public s11b_state -{ -public: - s11c_state(const machine_config &mconfig, device_type type, const char *tag) - : s11b_state(mconfig, type, tag) - { } - - void s11c(machine_config &config); - - void init_s11c(); - -protected: - virtual void machine_reset() override; -}; - - -#endif // MAME_INCLUDES_S11C_H