diff options
author | 2019-10-11 01:09:28 +1100 | |
---|---|---|
committer | 2019-10-11 01:09:28 +1100 | |
commit | bfe31049aaa427b8efdfebaa4f6cb9000118efa3 (patch) | |
tree | 4279289271d94201dbb64127c3623fbc8847053f | |
parent | cd546e66bb9a31ba0ea60c98232085b966564a8d (diff) |
mw8080.cpp: add explosion lamps to internal artwork for seawolf (nw)
other misc cleanup (nw)
-rw-r--r-- | src/devices/bus/amiga/keyboard/a1200.cpp | 16 | ||||
-rw-r--r-- | src/devices/bus/amiga/keyboard/a1200.h | 3 | ||||
-rw-r--r-- | src/devices/cpu/m6805/m68hc05.h | 10 | ||||
-rw-r--r-- | src/mame/drivers/galaxold.cpp | 2 | ||||
-rw-r--r-- | src/mame/drivers/stfight.cpp | 12 | ||||
-rw-r--r-- | src/mame/includes/qix.h | 6 | ||||
-rw-r--r-- | src/mame/layout/seawolf.lay | 157 | ||||
-rw-r--r-- | src/mame/machine/qix.cpp | 19 | ||||
-rw-r--r-- | src/mame/video/qix.cpp | 2 |
9 files changed, 126 insertions, 101 deletions
diff --git a/src/devices/bus/amiga/keyboard/a1200.cpp b/src/devices/bus/amiga/keyboard/a1200.cpp index 5534e07c15d..9067d932a4b 100644 --- a/src/devices/bus/amiga/keyboard/a1200.cpp +++ b/src/devices/bus/amiga/keyboard/a1200.cpp @@ -47,6 +47,8 @@ #include "a1200.h" #include "matrix.h" +#include "cpu/m6805/m68hc05.h" + //#define VERBOSE 1 #include "logmacro.h" @@ -171,13 +173,13 @@ WRITE_LINE_MEMBER(a1200_kbd_device::mpu_tcmp) void a1200_kbd_device::device_add_mconfig(machine_config &config) { - M68HC705C8A(config, m_mpu, XTAL(3'000'000)); - m_mpu->port_r<1>().set(FUNC(a1200_kbd_device::mpu_portb_r)); - m_mpu->port_r<3>().set_ioport("MOD"); - m_mpu->port_w<0>().set(FUNC(a1200_kbd_device::mpu_porta_w)); - m_mpu->port_w<1>().set(FUNC(a1200_kbd_device::mpu_portb_w)); - m_mpu->port_w<2>().set(FUNC(a1200_kbd_device::mpu_portc_w)); - m_mpu->tcmp().set(FUNC(a1200_kbd_device::mpu_tcmp)); + m68hc705c8a_device &mpu(M68HC705C8A(config, m_mpu, XTAL(3'000'000))); + mpu.portb_r().set(FUNC(a1200_kbd_device::mpu_portb_r)); + mpu.portd_r().set_ioport("MOD"); + mpu.porta_w().set(FUNC(a1200_kbd_device::mpu_porta_w)); + mpu.portb_w().set(FUNC(a1200_kbd_device::mpu_portb_w)); + mpu.portc_w().set(FUNC(a1200_kbd_device::mpu_portc_w)); + mpu.tcmp().set(FUNC(a1200_kbd_device::mpu_tcmp)); } tiny_rom_entry const *a1200_kbd_device::device_rom_region() const diff --git a/src/devices/bus/amiga/keyboard/a1200.h b/src/devices/bus/amiga/keyboard/a1200.h index ece885835ae..70df7caa0ae 100644 --- a/src/devices/bus/amiga/keyboard/a1200.h +++ b/src/devices/bus/amiga/keyboard/a1200.h @@ -11,7 +11,6 @@ #pragma once -#include "cpu/m6805/m68hc05.h" #include "keyboard.h" @@ -49,7 +48,7 @@ protected: private: required_ioport_array<15> m_rows; - required_device<m68hc705c8a_device> m_mpu; + required_device<cpu_device> m_mpu; u16 m_row_drive; bool m_host_kdat, m_mpu_kdat; diff --git a/src/devices/cpu/m6805/m68hc05.h b/src/devices/cpu/m6805/m68hc05.h index df051782fe8..a11abd9f3e8 100644 --- a/src/devices/cpu/m6805/m68hc05.h +++ b/src/devices/cpu/m6805/m68hc05.h @@ -32,8 +32,14 @@ class m68hc05_device : public m6805_base_device { public: // configuration helpers - template <std::size_t N> auto port_r() { return m_port_cb_r[N].bind(); } - template <std::size_t N> auto port_w() { return m_port_cb_w[N].bind(); } + auto porta_r() { return m_port_cb_r[0].bind(); } + auto portb_r() { return m_port_cb_r[1].bind(); } + auto portc_r() { return m_port_cb_r[2].bind(); } + auto portd_r() { return m_port_cb_r[3].bind(); } + auto porta_w() { return m_port_cb_w[0].bind(); } + auto portb_w() { return m_port_cb_w[1].bind(); } + auto portc_w() { return m_port_cb_w[2].bind(); } + auto portd_w() { return m_port_cb_w[3].bind(); } auto tcmp() { return m_tcmp_cb.bind(); } protected: diff --git a/src/mame/drivers/galaxold.cpp b/src/mame/drivers/galaxold.cpp index 61d91dfcedb..bdb42e3f42c 100644 --- a/src/mame/drivers/galaxold.cpp +++ b/src/mame/drivers/galaxold.cpp @@ -2518,7 +2518,7 @@ void galaxold_state::drivfrcg(machine_config &config) maincpu.set_addrmap(AS_PROGRAM, &galaxold_state::drivfrcg_program); maincpu.set_addrmap(AS_IO, &galaxold_state::drivfrcg_io); maincpu.set_vblank_int("screen", FUNC(galaxold_state::hunchbks_vh_interrupt)); - maincpu.sense_handler().set("screen", FUNC(screen_device::vblank)); + maincpu.sense_handler().set("screen", FUNC(screen_device::vblank)); // ??? /* video hardware */ SCREEN(config, m_screen, SCREEN_TYPE_RASTER); diff --git a/src/mame/drivers/stfight.cpp b/src/mame/drivers/stfight.cpp index b72e004eb4b..aced326840d 100644 --- a/src/mame/drivers/stfight.cpp +++ b/src/mame/drivers/stfight.cpp @@ -462,15 +462,15 @@ INPUT_PORTS_END void stfight_state::stfight_base(machine_config &config) { /* basic machine hardware */ - Z80(config, m_maincpu, XTAL(12'000'000) / 4); + Z80(config, m_maincpu, 12_MHz_XTAL / 4); m_maincpu->set_addrmap(AS_PROGRAM, &stfight_state::cpu1_map); m_maincpu->set_vblank_int("stfight_vid:screen", FUNC(stfight_state::stfight_vb_interrupt)); - Z80(config, m_audiocpu, XTAL(12'000'000) / 4); + Z80(config, m_audiocpu, 12_MHz_XTAL / 4); m_audiocpu->set_addrmap(AS_PROGRAM, &stfight_state::cpu2_map); m_audiocpu->set_periodic_int(FUNC(stfight_state::irq0_line_hold), attotime::from_hz(120)); - M68705P5(config, m_mcu, XTAL(12'000'000) / 4); + M68705P5(config, m_mcu, 12_MHz_XTAL / 4); m_mcu->portb_r().set(FUNC(stfight_state::stfight_68705_port_b_r)); m_mcu->porta_w().set(FUNC(stfight_state::stfight_68705_port_a_w)); m_mcu->portb_w().set(FUNC(stfight_state::stfight_68705_port_b_w)); @@ -484,19 +484,19 @@ void stfight_state::stfight_base(machine_config &config) SPEAKER(config, "mono").front_center(); // YM2203_PITCH_HACK - These should be clocked at 1.5Mhz (see TODO list) - ym2203_device &ym1(YM2203(config, "ym1", XTAL(12'000'000) / 8 * 3)); + ym2203_device &ym1(YM2203(config, "ym1", 12_MHz_XTAL / 8 * 3)); ym1.add_route(0, "mono", 0.15); ym1.add_route(1, "mono", 0.15); ym1.add_route(2, "mono", 0.15); ym1.add_route(3, "mono", 0.10); - ym2203_device &ym2(YM2203(config, "ym2", XTAL(12'000'000) / 8 * 3)); + ym2203_device &ym2(YM2203(config, "ym2", 12_MHz_XTAL / 8 * 3)); ym2.add_route(0, "mono", 0.15); ym2.add_route(1, "mono", 0.15); ym2.add_route(2, "mono", 0.15); ym2.add_route(3, "mono", 0.10); - MSM5205(config, m_msm, XTAL(384'000)); + MSM5205(config, m_msm, 384_kHz_XTAL); m_msm->vck_callback().set(FUNC(stfight_state::stfight_adpcm_int)); // Interrupt function m_msm->set_prescaler_selector(msm5205_device::S48_4B); // 8KHz, 4-bit m_msm->add_route(ALL_OUTPUTS, "mono", 0.50); diff --git a/src/mame/includes/qix.h b/src/mame/includes/qix.h index 3e01ce0af62..50dc529eee9 100644 --- a/src/mame/includes/qix.h +++ b/src/mame/includes/qix.h @@ -167,7 +167,6 @@ public: protected: virtual void machine_start() override; - virtual void machine_reset() override; private: DECLARE_READ8_MEMBER(coin_r); @@ -190,7 +189,8 @@ class zookeep_state : public qixmcu_state { public: zookeep_state(const machine_config &mconfig, device_type type, const char *tag) : - qixmcu_state(mconfig, type, tag) + qixmcu_state(mconfig, type, tag), + m_vidbank(*this, "bank1") { } void zookeep(machine_config &config); @@ -204,6 +204,8 @@ private: void main_map(address_map &map); void video_map(address_map &map); + + required_memory_bank m_vidbank; }; #endif // MAME_INCLUDES_QIX_H diff --git a/src/mame/layout/seawolf.lay b/src/mame/layout/seawolf.lay index ae60618816d..6b2defc7028 100644 --- a/src/mame/layout/seawolf.lay +++ b/src/mame/layout/seawolf.lay @@ -3,64 +3,33 @@ <element name="overlay"> <rect> - <bounds left="0" top="0" right="4" bottom="3" /> <color red="0.25" green="0.5" blue="1" /> </rect> </element> -<!-- define periscope lamps --> - - <element name="lamp_1" defstate="0"> + <element name="explamp" defstate="0"> <disk state="1"> - <color red="1.0" green="0.25" blue="0.10" /> - </disk> - <disk state="0"> - <color red="0.25" green="0.05" blue="0.0" /> + <color red="0.9" green="0.6" blue="0.2" /> </disk> - <text string="1"> - <color red="0.0" green="0.0" blue="0.0" /> - <bounds x="0" y="0.2" width="1" height="0.6" /> - </text> </element> - <element name="lamp_2" defstate="0"> - <disk state="1"> - <color red="1.0" green="0.25" blue="0.10" /> - </disk> - <disk state="0"> - <color red="0.25" green="0.05" blue="0.0" /> - </disk> - <text string="2"> - <color red="0.0" green="0.0" blue="0.0" /> - <bounds x="0" y="0.2" width="1" height="0.6" /> - </text> - </element> - - <element name="lamp_3" defstate="0"> - <disk state="1"> - <color red="1.0" green="0.25" blue="0.10" /> - </disk> - <disk state="0"> - <color red="0.25" green="0.05" blue="0.0" /> - </disk> - <text string="3"> - <color red="0.0" green="0.0" blue="0.0" /> - <bounds x="0" y="0.2" width="1" height="0.6" /> - </text> - </element> - - <element name="lamp_4" defstate="0"> - <disk state="1"> - <color red="1.0" green="0.25" blue="0.10" /> - </disk> - <disk state="0"> - <color red="0.25" green="0.05" blue="0.0" /> - </disk> - <text string="4"> - <color red="0.0" green="0.0" blue="0.0" /> - <bounds x="0" y="0.2" width="1" height="0.6" /> - </text> - </element> + <!-- define periscope lamps --> + + <repeat count="4"> + <param name="lampno" start="1" increment="1" /> + <element name="lamp_~lampno~" defstate="0"> + <disk state="1"> + <color red="1.0" green="0.25" blue="0.10" /> + </disk> + <disk state="0"> + <color red="0.25" green="0.05" blue="0.0" /> + </disk> + <text string="~lampno~"> + <color red="0.0" green="0.0" blue="0.0" /> + <bounds x="0" y="0.2" width="1" height="0.6" /> + </text> + </element> + </repeat> <element name="lamp_ready" defstate="0"> <disk state="1"> @@ -131,36 +100,84 @@ </element> -<!-- NOTE: does not include explosion lamps yet --> - - <view name="Lamps + Color Overlay"> + <view name="Lamps and Color Overlay"> <bounds left="0" top="-90" right="400" bottom="300" /> + <screen index="0"> <bounds left="0" top="0" right="400" bottom="300" /> </screen> - <overlay name="overlay" element="overlay"> + <element ref="overlay" blend="multiply"> <bounds left="0" top="0" right="400" bottom="300" /> - </overlay> - - <bezel name="TORP_LAMP_1" element="lamp_1"> + </element> + + <element name="EXP_LAMP_0" ref="explamp" blend="add"> + <bounds x="20.1" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_1" ref="explamp" blend="add"> + <bounds x="66.5" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_2" ref="explamp" blend="add"> + <bounds x="112.9" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_3" ref="explamp" blend="add"> + <bounds x="159.3" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_4" ref="explamp" blend="add"> + <bounds x="205.7" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_5" ref="explamp" blend="add"> + <bounds x="252.1" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_6" ref="explamp" blend="add"> + <bounds x="298.5" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_7" ref="explamp" blend="add"> + <bounds x="344.9" y="66.8" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_8" ref="explamp" blend="add"> + <bounds x="20.1" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_9" ref="explamp" blend="add"> + <bounds x="66.5" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_A" ref="explamp" blend="add"> + <bounds x="112.9" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_B" ref="explamp" blend="add"> + <bounds x="159.3" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_C" ref="explamp" blend="add"> + <bounds x="205.7" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_D" ref="explamp" blend="add"> + <bounds x="252.1" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_E" ref="explamp" blend="add"> + <bounds x="298.5" y="28.3" width="35" height="17.7" /> + </element> + <element name="EXP_LAMP_F" ref="explamp" blend="add"> + <bounds x="344.9" y="28.3" width="35" height="17.7" /> + </element> + + <element name="TORP_LAMP_4" ref="lamp_1"> <bounds x="117.5" y="-80" width="30" height="30" /> - </bezel> - <bezel name="TORP_LAMP_2" element="lamp_2"> + </element> + <element name="TORP_LAMP_3" ref="lamp_2"> <bounds x="162.5" y="-80" width="30" height="30" /> - </bezel> - <bezel name="TORP_LAMP_3" element="lamp_3"> + </element> + <element name="TORP_LAMP_2" ref="lamp_3"> <bounds x="207.5" y="-80" width="30" height="30" /> - </bezel> - <bezel name="TORP_LAMP_4" element="lamp_4"> + </element> + <element name="TORP_LAMP_1" ref="lamp_4"> <bounds x="252.5" y="-80" width="30" height="30" /> - </bezel> + </element> - <bezel name="READY_LAMP" element="lamp_ready"> + <element name="READY_LAMP" ref="lamp_ready"> <bounds x="117.5" y="-40" width="75" height="30" /> - </bezel> - <bezel name="RELOAD_LAMP" element="lamp_reload"> + </element> + <element name="RELOAD_LAMP" ref="lamp_reload"> <bounds x="207.5" y="-40" width="75" height="30" /> - </bezel> + </element> </view> @@ -168,9 +185,9 @@ <screen index="0"> <bounds left="0" top="0" right="400" bottom="300" /> </screen> - <overlay name="overlay" element="overlay"> + <element ref="overlay" blend="multiply"> <bounds left="0" top="0" right="400" bottom="300" /> - </overlay> + </element> </view> </mamelayout> diff --git a/src/mame/machine/qix.cpp b/src/mame/machine/qix.cpp index 8cc23584abf..3fe4f112a1a 100644 --- a/src/mame/machine/qix.cpp +++ b/src/mame/machine/qix.cpp @@ -21,15 +21,14 @@ void qixmcu_state::machine_start() { - /* set up save states */ - save_item(NAME(m_68705_porta_out)); - save_item(NAME(m_coinctrl)); -} + qix_state::machine_start(); -void qixmcu_state::machine_reset() -{ /* reset the coin counter register */ m_coinctrl = 0x00; + + /* set up save states */ + save_item(NAME(m_68705_porta_out)); + save_item(NAME(m_coinctrl)); } void zookeep_state::machine_start() @@ -37,9 +36,9 @@ void zookeep_state::machine_start() qixmcu_state::machine_start(); /* configure the banking */ - membank("bank1")->configure_entry(0, memregion("videocpu")->base() + 0xa000); - membank("bank1")->configure_entry(1, memregion("videocpu")->base() + 0x10000); - membank("bank1")->set_entry(0); + m_vidbank->configure_entry(0, memregion("videocpu")->base() + 0xa000); + m_vidbank->configure_entry(1, memregion("videocpu")->base() + 0x10000); + m_vidbank->set_entry(0); } /************************************* @@ -63,7 +62,7 @@ WRITE_LINE_MEMBER(qix_state::qix_vsync_changed) WRITE8_MEMBER(zookeep_state::bankswitch_w) { - membank("bank1")->set_entry((data >> 2) & 1); + m_vidbank->set_entry(BIT(data, 2)); /* not necessary, but technically correct */ qix_palettebank_w(space, offset, data); } diff --git a/src/mame/video/qix.cpp b/src/mame/video/qix.cpp index 8326e52278c..07d2af06ede 100644 --- a/src/mame/video/qix.cpp +++ b/src/mame/video/qix.cpp @@ -349,7 +349,7 @@ void zookeep_state::video_map(address_map &map) map(0x9800, 0x9800).mirror(0x03ff).readonly().share("scanline_latch"); map(0x9c00, 0x9c00).mirror(0x03fe).w(m_crtc, FUNC(mc6845_device::address_w)); map(0x9c01, 0x9c01).mirror(0x03fe).rw(m_crtc, FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); - map(0xa000, 0xbfff).bankr("bank1"); + map(0xa000, 0xbfff).bankr(m_vidbank); map(0xc000, 0xffff).rom(); } |