From 8f0042a609ff6ee6fa0500e5c178fe1d1a482175 Mon Sep 17 00:00:00 2001 From: hap Date: Wed, 23 Mar 2022 23:08:13 +0100 Subject: [PATCH] Machines promoted to working ---------------------------------- Auto Race [hap, Sean Riddle] Missile Attack (Mattel) [hap, Sean Riddle] Football (Mattel) [hap, Sean Riddle] Baseball (Mattel) [hap, Sean Riddle] Gravity (Mattel) [hap, Sean Riddle] --- src/devices/cpu/b5000/b5000.cpp | 3 +- src/devices/cpu/b5000/b5000.h | 1 + src/devices/cpu/b5000/b5000op.cpp | 11 +- src/devices/cpu/b5000/b6000.cpp | 24 ++-- src/devices/cpu/b5000/b6000.h | 1 - src/devices/cpu/b5000/b6100.cpp | 4 +- src/mame/drivers/aci_ggm.cpp | 5 +- src/mame/drivers/hh_b5000.cpp | 232 ++++++++++++++++++++---------- src/mame/drivers/hh_pps41.cpp | 14 +- src/mame/layout/autorace.lay | 82 +++++++++++ src/mame/layout/cnfball.lay | 14 +- src/mame/layout/gravity.lay | 67 +++++++++ src/mame/layout/mbaseb.lay | 218 ++++++++++++++++++++++++++++ src/mame/layout/mfootb.lay | 164 +++++++++++++++++++++ src/mame/layout/mfootb2.lay | 26 ++-- src/mame/layout/microvision.lay | 2 +- src/mame/layout/misatk.lay | 120 ++++++++++++++++ src/mame/layout/tcfball.lay | 14 +- src/mame/layout/ttfball.lay | 14 +- 19 files changed, 871 insertions(+), 145 deletions(-) create mode 100644 src/mame/layout/autorace.lay create mode 100644 src/mame/layout/gravity.lay create mode 100644 src/mame/layout/mbaseb.lay create mode 100644 src/mame/layout/mfootb.lay create mode 100644 src/mame/layout/misatk.lay diff --git a/src/devices/cpu/b5000/b5000.cpp b/src/devices/cpu/b5000/b5000.cpp index f1f94120fef..f599b4dbd61 100644 --- a/src/devices/cpu/b5000/b5000.cpp +++ b/src/devices/cpu/b5000/b5000.cpp @@ -7,7 +7,8 @@ TODO: - only one device dumped (Rockwell 8R) and it doesn't work at all - is unmapped ram mirrored? (that goes for subdevices too) -- fix digit segment decoder, there should be a minus sign in it +- Fix digit segment decoder, it's not on a neat PLA. There should be a minus + sign in it, and more. */ diff --git a/src/devices/cpu/b5000/b5000.h b/src/devices/cpu/b5000/b5000.h index c22ce303202..87b9ed64758 100644 --- a/src/devices/cpu/b5000/b5000.h +++ b/src/devices/cpu/b5000/b5000.h @@ -69,6 +69,7 @@ protected: void ram_w(u8 data); void set_pc(u8 pu, u8 pl); void set_bu(u8 bu); + void seg_w(u16 seg); void op_illegal(); // opcode handlers diff --git a/src/devices/cpu/b5000/b5000op.cpp b/src/devices/cpu/b5000/b5000op.cpp index 257a716eed9..4c489a25383 100644 --- a/src/devices/cpu/b5000/b5000op.cpp +++ b/src/devices/cpu/b5000/b5000op.cpp @@ -33,6 +33,11 @@ void b5000_cpu_device::set_bu(u8 bu) m_bu_delay = true; } +void b5000_cpu_device::seg_w(u16 seg) +{ + m_write_seg(m_seg = seg); +} + void b5000_cpu_device::op_illegal() { logerror("unknown opcode $%02X at $%03X\n", m_op, m_prev_pc); @@ -260,8 +265,7 @@ void b5000_cpu_device::op_tc() void b5000_cpu_device::op_kseg() { // KSEG: reset segment outputs - m_seg = 0; - m_write_seg(0); + seg_w(0); } void b5000_cpu_device::op_atbz() @@ -315,8 +319,7 @@ void b5000_cpu_device::op_tkbs() // step 2: load segments from RAM case 2: // note: SEG0(DP) from C flag is delayed 2 cycles - m_seg |= decode_digit(ram_r()) << 1 | m_prev3_c; - m_write_seg(m_seg); + seg_w(m_seg | decode_digit(ram_r()) << 1 | m_prev3_c); m_tkbs_step = 0; return; diff --git a/src/devices/cpu/b5000/b6000.cpp b/src/devices/cpu/b5000/b6000.cpp index 0f68c2ca5e3..40c116b9553 100644 --- a/src/devices/cpu/b5000/b6000.cpp +++ b/src/devices/cpu/b5000/b6000.cpp @@ -8,7 +8,8 @@ MCU designed for Mattel's electronic games, I/O is a bit more versatile, and a speaker output was added. It was succeeded by B6100 with a larger ROM. TODO: -- confirm digit segment decoder (10, 11, 15 appear to be unused by the games) +- any other changed opcodes? +- confirm digit segment decoder (10, 11, 15 are unused by the games) */ @@ -47,11 +48,10 @@ void b6000_cpu_device::device_reset() m_ram_addr = 0; m_a = 0; m_c = 0; - m_seg = 0; // clear outputs + seg_w(0); m_write_str(0); - m_write_seg(0); m_write_spk(0); } @@ -65,7 +65,7 @@ u16 b6000_cpu_device::decode_digit(u8 data) 0x3f, 0x06, 0x5b, 0x4f, 0x66, 0x6d, 0x7d, 0x07, 0x7f, 0x6f, // ?, ?, none, F, G, ? - 0x64, 0x64, 0x00, 0x20, 0x40, 0x64 + 0, 0, 0x00, 0x20, 0x40, 0 }; return lut_segs[data & 0xf]; } @@ -75,13 +75,6 @@ u16 b6000_cpu_device::decode_digit(u8 data) // execute //------------------------------------------------- -void b6000_cpu_device::update_speaker() -{ - // carry flag outputs to SPK - if (m_c != m_prev_c) - m_write_spk(m_c); -} - void b6000_cpu_device::execute_one() { switch (m_op) @@ -93,8 +86,6 @@ void b6000_cpu_device::execute_one() // rest is same as B5000 default: b5000_cpu_device::execute_one(); break; } - - update_speaker(); } @@ -104,13 +95,14 @@ void b6000_cpu_device::execute_one() void b6000_cpu_device::op_tkbs() { - // TKBS: load segments (no TKB step) - m_seg |= decode_digit(ram_r()); - m_write_seg(m_seg); + // TKBS: load segments and speaker (no TKB step) + seg_w(m_seg | decode_digit(ram_r())); + m_write_spk(m_c); } void b6000_cpu_device::op_atbz() { // ATBZ: load strobe from A (no ATB step) m_write_str(1 << (m_a & 0xf)); + op_kseg(); } diff --git a/src/devices/cpu/b5000/b6000.h b/src/devices/cpu/b5000/b6000.h index 160f6e16c15..e13cb506dc6 100644 --- a/src/devices/cpu/b5000/b6000.h +++ b/src/devices/cpu/b5000/b6000.h @@ -52,7 +52,6 @@ protected: // device-level overrides virtual void device_reset() override; - void update_speaker(); virtual void execute_one() override; virtual u16 decode_digit(u8 data) override; diff --git a/src/devices/cpu/b5000/b6100.cpp b/src/devices/cpu/b5000/b6100.cpp index 87d4b51822c..8974c367879 100644 --- a/src/devices/cpu/b5000/b6100.cpp +++ b/src/devices/cpu/b5000/b6100.cpp @@ -130,7 +130,9 @@ void b6100_cpu_device::execute_one() break; // 0xfc } - update_speaker(); + // instead of with TKBS, carry flag directly outputs to SPK + if (m_c != m_prev_c) + m_write_spk(m_c); } bool b6100_cpu_device::op_canskip(u8 op) diff --git a/src/mame/drivers/aci_ggm.cpp b/src/mame/drivers/aci_ggm.cpp index d93fb38b4c3..011adfc976a 100644 --- a/src/mame/drivers/aci_ggm.cpp +++ b/src/mame/drivers/aci_ggm.cpp @@ -8,7 +8,7 @@ Applied Concepts Great Game Machine (GGM), electronic board game computer. Hardware notes: - 6502A 2MHz, SYP6522 VIA -- 2KB RAM(4*HM472114AP-2), no ROM on main PCB +- 2KB RAM(4*HM472114AP-2 or 1*M58725P), no ROM on main PCB - 2*74164 shift register, 3*6118P VFD driver - 8-digit 14seg VFD panel (same one as in Speak & Spell) - 5*4 keypad(unlabeled by default), 1-bit sound @@ -39,7 +39,6 @@ Other games: TODO: - it doesn't have nvram, it's a workaround for MAME forcing a hard reset when swapping in a new cartridge -- what's VIA PB0 for? game toggles it once per irq - confirm display AP segment, is it used anywhere? - verify cartridge pinout, right now assume A0-A15 (max known cart size is 24KB). Boris/Sargon cartridge is A0-A11 and 2 CS lines, Steinitz uses the whole range. @@ -237,7 +236,7 @@ void ggm_state::select_w(u8 data) void ggm_state::control_w(u8 data) { - // PB0: ? + // PB0: DC/DC converter, toggles once per IRQ (probably for VFD, not needed for emulation) // PB7: speaker out m_dac->write(BIT(data, 7)); diff --git a/src/mame/drivers/hh_b5000.cpp b/src/mame/drivers/hh_b5000.cpp index 2af5af20932..0ace5bca68d 100644 --- a/src/mame/drivers/hh_b5000.cpp +++ b/src/mame/drivers/hh_b5000.cpp @@ -26,9 +26,14 @@ TODO: #include "speaker.h" // internal artwork +#include "autorace.lh" +#include "gravity.lh" +#include "mbaseb.lh" +#include "mfootb.lh" +#include "misatk.lh" #include "rw18r.lh" -#include "hh_b5000_test.lh" // common test-layout - use external artwork +//#include "hh_b5000_test.lh" // common test-layout - use external artwork class hh_b5000_state : public driver_device @@ -42,6 +47,10 @@ public: m_inputs(*this, "IN.%u", 0) { } + DECLARE_INPUT_CHANGED_MEMBER(power_button); + template DECLARE_INPUT_CHANGED_MEMBER(switch_next) { if (newval) switch_change(Sel, param, true); } + template DECLARE_INPUT_CHANGED_MEMBER(switch_prev) { if (newval) switch_change(Sel, param, false); } + protected: virtual void machine_start() override; virtual void machine_reset() override; @@ -59,6 +68,7 @@ protected: u16 m_seg = 0; u8 read_inputs(int columns); + void switch_change(int sel, u32 mask, bool next); }; @@ -98,6 +108,27 @@ u8 hh_b5000_state::read_inputs(int columns) return ret; } +void hh_b5000_state::switch_change(int sel, u32 mask, bool next) +{ + // config switches (for direct control) + ioport_field *inp = m_inputs[sel]->field(mask); + + if (next && inp->has_next_setting()) + inp->select_next_setting(); + else if (!next && inp->has_previous_setting()) + inp->select_previous_setting(); +} + +INPUT_CHANGED_MEMBER(hh_b5000_state::power_button) +{ + // power button or switch + bool power = (param) ? (bool(param - 1)) : !newval; + + if (!power && m_display != nullptr) + m_display->clear(); + m_maincpu->set_input_line(INPUT_LINE_RESET, power ? CLEAR_LINE : ASSERT_LINE); +} + /*************************************************************************** @@ -110,13 +141,15 @@ namespace { /*************************************************************************** - Mattel Auto Race + Mattel Auto Race (model 9879) * B6000 MCU (label B6000CA, die label B6000-B) * 2-digit 7seg display, 21 other leds, 1-bit sound - This is Mattel's first handheld game. Hardware design (even the MCU) and - programming was done at Rockwell. A European version was released as - "Ski Slalom" (it's simply upside-down). + This is Mattel's first electronic handheld game, also the first CPU-based + handheld game overall. Hardware design (even the MCU) and programming + was done at Rockwell. + + A European version was released as "Ski Slalom", except it's upside-down. ***************************************************************************/ @@ -150,22 +183,31 @@ void autorace_state::write_seg(u16 data) static INPUT_PORTS_START( autorace ) PORT_START("IN.0") // KB - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_2) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_3) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_4) + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) // does not auto-center on real device + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) // " + PORT_CONFNAME( 0x0c, 0x0c, "Gear" ) + PORT_CONFSETTING( 0x0c, "1" ) + PORT_CONFSETTING( 0x04, "2" ) + PORT_CONFSETTING( 0x00, "3" ) + PORT_CONFSETTING( 0x08, "4" ) PORT_START("IN.1") // DIN - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_5) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_6) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_7) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_8) + PORT_CONFNAME( 0x01, 0x00, "Factory Test" ) + PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) + PORT_CONFSETTING( 0x01, DEF_STR( On ) ) + + PORT_START("POWER") // power switch + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START ) PORT_CHANGED_MEMBER(DEVICE_SELF, hh_b5000_state, power_button, 0) PORT_NAME("Start / Reset") + + PORT_START("SWITCH") // fake + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_CHANGED_MEMBER(DEVICE_SELF, hh_b5000_state, switch_prev<0>, 0x0c) PORT_NAME("Gear Switch Down") + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_CHANGED_MEMBER(DEVICE_SELF, hh_b5000_state, switch_next<0>, 0x0c) PORT_NAME("Gear Switch Up") INPUT_PORTS_END void autorace_state::autorace(machine_config &config) { // basic machine hardware - B6000(config, m_maincpu, 240000); // approximation + B6000(config, m_maincpu, 160000); // approximation m_maincpu->write_str().set(FUNC(autorace_state::write_str)); m_maincpu->write_seg().set(FUNC(autorace_state::write_seg)); m_maincpu->read_kb().set_ioport("IN.0"); @@ -174,7 +216,9 @@ void autorace_state::autorace(machine_config &config) // video hardware PWM_DISPLAY(config, m_display).set_size(9, 8); - config.set_default_layout(layout_hh_b5000_test); + m_display->set_segmask(0x180, 0x7f); + m_display->set_bri_levels(0.02, 0.2); // player led is brighter + config.set_default_layout(layout_autorace); // sound hardware SPEAKER(config, "mono").front_center(); @@ -194,14 +238,14 @@ ROM_END /*************************************************************************** - Mattel Missile Attack / Battlestar Galactica: Space Alert + Mattel Missile Attack (model 2048) / Battlestar Galactica: Space Alert (model 2448) * B6000 MCU (label B6001CA/EA, die label B6001) * 2-digit 7seg display, 21 other leds, 1-bit sound - The initial release was titled Missile Attack, it didn't sell well (Mattel - blamed it on NBC for not wanting to air their commercial). They changed - the title/setting and advertised an upcoming rerelease as "Flash Gordon", - but changed plans and named it "Battlestar Galactica: Space Alert". + The initial release was called Missile Attack, it didn't sell well (Mattel + blamed it on NBC for refusing to air their commercial). They changed the + title/setting and advertised an upcoming rerelease as "Flash Gordon", but + changed plans and named it "Battlestar Galactica: Space Alert". ***************************************************************************/ @@ -235,22 +279,24 @@ void misatk_state::write_seg(u16 data) static INPUT_PORTS_START( misatk ) PORT_START("IN.0") // KB - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_2) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_3) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_4) + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT ) // does not auto-center on real device + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT ) // " + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_START("IN.1") // DIN - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_5) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_6) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_7) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_8) + PORT_CONFNAME( 0x01, 0x00, "Factory Test" ) + PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) + PORT_CONFSETTING( 0x01, DEF_STR( On ) ) + + PORT_START("POWER") // power switch + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_START ) PORT_CHANGED_MEMBER(DEVICE_SELF, hh_b5000_state, power_button, 0) PORT_NAME("Arm / Off") INPUT_PORTS_END void misatk_state::misatk(machine_config &config) { // basic machine hardware - B6000(config, m_maincpu, 240000); // approximation + B6000(config, m_maincpu, 250000); // approximation m_maincpu->write_str().set(FUNC(misatk_state::write_str)); m_maincpu->write_seg().set(FUNC(misatk_state::write_seg)); m_maincpu->read_kb().set_ioport("IN.0"); @@ -259,7 +305,9 @@ void misatk_state::misatk(machine_config &config) // video hardware PWM_DISPLAY(config, m_display).set_size(9, 8); - config.set_default_layout(layout_hh_b5000_test); + m_display->set_segmask(0x180, 0x7f); + m_display->set_bri_levels(0.015, 0.15); // player led is brighter + config.set_default_layout(layout_misatk); // sound hardware SPEAKER(config, "mono").front_center(); @@ -279,8 +327,8 @@ ROM_END /*************************************************************************** - Mattel Football - * B6100 MCU (label B6100EB, die label B6100 A) + Mattel Football (model 2024) + * B6100 MCU (label B6100EB/-15, die label B6100 A) * 7-digit 7seg display, 27 other leds, 1-bit sound When Football II came out, they renamed this one to Football I. @@ -296,43 +344,59 @@ public: void mfootb(machine_config &config); + DECLARE_INPUT_CHANGED_MEMBER(score_button) { update_display(); } + private: + void update_display(); void write_str(u16 data); void write_seg(u16 data); }; // handlers +void mfootb_state::update_display() +{ + // 4th digit DP is from the SCORE button + u8 dp = (m_inputs[1]->read() & 2) ? 0x80 : 0; + m_display->matrix(m_str, (m_seg << 1 & 0x700) | dp | (m_seg & 0x7f)); +} + void mfootb_state::write_str(u16 data) { - m_display->write_my(data); + m_str = data; + update_display(); } void mfootb_state::write_seg(u16 data) { - m_display->write_mx(data); + m_seg = data; + update_display(); } // config static INPUT_PORTS_START( mfootb ) PORT_START("IN.0") // KB - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_2) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_3) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_4) + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN ) PORT_16WAY + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Forward") + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP ) PORT_16WAY + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Kick") PORT_START("IN.1") // DIN - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_5) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_6) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_7) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_8) + PORT_CONFNAME( 0x01, 0x01, DEF_STR( Difficulty ) ) + PORT_CONFSETTING( 0x01, "1" ) // PRO 1 + PORT_CONFSETTING( 0x00, "2" ) // PRO 2 + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_START2 ) PORT_NAME("Score") PORT_CHANGED_MEMBER(DEVICE_SELF, mfootb_state, score_button, 0) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Status") + PORT_CONFNAME( 0x08, 0x00, "Factory Test" ) + PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) + PORT_CONFSETTING( 0x08, DEF_STR( On ) ) INPUT_PORTS_END void mfootb_state::mfootb(machine_config &config) { // basic machine hardware - B6100(config, m_maincpu, 240000); // approximation + B6100(config, m_maincpu, 280000); // approximation m_maincpu->write_str().set(FUNC(mfootb_state::write_str)); m_maincpu->write_seg().set(FUNC(mfootb_state::write_seg)); m_maincpu->read_kb().set_ioport("IN.0"); @@ -340,8 +404,11 @@ void mfootb_state::mfootb(machine_config &config) m_maincpu->write_spk().set(m_speaker, FUNC(speaker_sound_device::level_w)); // video hardware - PWM_DISPLAY(config, m_display).set_size(9, 10); - config.set_default_layout(layout_hh_b5000_test); + PWM_DISPLAY(config, m_display).set_size(9, 11); + m_display->set_segmask(0x7f, 0x7f); + m_display->set_segmask(0x08, 0xff); // only one digit has DP + m_display->set_bri_levels(0.02, 0.2); // player led is brighter + config.set_default_layout(layout_mfootb); // sound hardware SPEAKER(config, "mono").front_center(); @@ -362,7 +429,7 @@ ROM_END /*************************************************************************** - Mattel Baseball + Mattel Baseball (model 2942) * B6100 MCU (label B6101-12, die label B6101 A) * 4-digit 7seg display, 28 other leds, 1-bit sound @@ -391,29 +458,33 @@ void mbaseb_state::write_str(u16 data) void mbaseb_state::write_seg(u16 data) { - m_display->write_mx(data); + m_display->write_mx(bitswap<10>(data,7,8,9,6,5,4,3,2,1,0)); } // config static INPUT_PORTS_START( mbaseb ) PORT_START("IN.0") // KB - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_2) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_3) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_4) + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON3 ) PORT_NAME("Pitch") + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_NAME("Hit") PORT_START("IN.1") // DIN - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_5) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_6) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_7) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_8) + PORT_CONFNAME( 0x01, 0x01, DEF_STR( Difficulty ) ) + PORT_CONFSETTING( 0x01, "1" ) // PRO 1 + PORT_CONFSETTING( 0x00, "2" ) // PRO 2 + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_START1 ) PORT_NAME("Score") + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON2 ) PORT_NAME("Run") + PORT_CONFNAME( 0x08, 0x00, "Factory Test" ) + PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) + PORT_CONFSETTING( 0x08, DEF_STR( On ) ) INPUT_PORTS_END void mbaseb_state::mbaseb(machine_config &config) { // basic machine hardware - B6100(config, m_maincpu, 240000); // approximation + B6100(config, m_maincpu, 280000); // approximation m_maincpu->write_str().set(FUNC(mbaseb_state::write_str)); m_maincpu->write_seg().set(FUNC(mbaseb_state::write_seg)); m_maincpu->read_kb().set_ioport("IN.0"); @@ -422,7 +493,9 @@ void mbaseb_state::mbaseb(machine_config &config) // video hardware PWM_DISPLAY(config, m_display).set_size(9, 10); - config.set_default_layout(layout_hh_b5000_test); + m_display->set_segmask(0x170, 0x7f); + m_display->set_segmask(0x110, 0xff); // 2 digits have DP + config.set_default_layout(layout_mbaseb); // sound hardware SPEAKER(config, "mono").front_center(); @@ -443,12 +516,17 @@ ROM_END /*************************************************************************** - Mattel Gravity + Mattel Gravity (model 8291) * B6100 MCU (label B6102-11, die label B6102 A) * 3-digit 7seg display, 27 other leds, 1-bit sound - It was advertised as "Catastrophe", but went unreleased. It got released - later as "Gravity", presumedly only for the European market. + It was advertised as "Catastrophe", but went unreleased. It got sold later + as "Gravity", with a less catastrophic setting. + + The game is basically 3 mini games in 1: + - Juggling (Rumbling Rocks in Catastrophe) + - Coin Drop (Quake Shock in Catastrophe) + - Docking (Meteorite Shower in Catstrophe) ***************************************************************************/ @@ -482,22 +560,21 @@ void gravity_state::write_seg(u16 data) static INPUT_PORTS_START( gravity ) PORT_START("IN.0") // KB - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_1) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_2) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_3) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_4) + PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON3 ) + PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON2 ) + PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON1 ) + PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED ) PORT_START("IN.1") // DIN - PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_5) - PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_6) - PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_7) - PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYPAD ) PORT_CODE(KEYCODE_8) + PORT_CONFNAME( 0x08, 0x00, "Factory Test" ) + PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) + PORT_CONFSETTING( 0x08, DEF_STR( On ) ) INPUT_PORTS_END void gravity_state::gravity(machine_config &config) { // basic machine hardware - B6100(config, m_maincpu, 240000); // approximation + B6100(config, m_maincpu, 250000); // approximation m_maincpu->write_str().set(FUNC(gravity_state::write_str)); m_maincpu->write_seg().set(FUNC(gravity_state::write_seg)); m_maincpu->read_kb().set_ioport("IN.0"); @@ -506,7 +583,8 @@ void gravity_state::gravity(machine_config &config) // video hardware PWM_DISPLAY(config, m_display).set_size(9, 10); - config.set_default_layout(layout_hh_b5000_test); + m_display->set_segmask(0x1c0, 0x7f); + config.set_default_layout(layout_gravity); // sound hardware SPEAKER(config, "mono").front_center(); @@ -528,7 +606,7 @@ ROM_END /*************************************************************************** Rockwell 8R, Rockwell 18R - * B5000 MCU (label B5000CC) + * B5000 MCU (label B5000CC, die label B5000) * 8-digit 7seg display This MCU was used in Rockwell 8R, 18R, and 9TR. It was also sold by @@ -610,7 +688,7 @@ INPUT_PORTS_END void rw18r_state::rw18r(machine_config &config) { // basic machine hardware - B5000(config, m_maincpu, 240000); // approximation + B5000(config, m_maincpu, 250000); // approximation m_maincpu->write_str().set(FUNC(rw18r_state::write_str)); m_maincpu->write_seg().set(FUNC(rw18r_state::write_seg)); m_maincpu->read_kb().set(FUNC(rw18r_state::read_kb)); @@ -640,10 +718,10 @@ ROM_END ***************************************************************************/ // YEAR NAME PARENT CMP MACHINE INPUT CLASS INIT COMPANY, FULLNAME, FLAGS -CONS( 1976, autorace, 0, 0, autorace, autorace, autorace_state, empty_init, "Mattel Electronics", "Auto Race", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) -CONS( 1977, misatk, 0, 0, misatk, misatk, misatk_state, empty_init, "Mattel Electronics", "Missile Attack (Mattel)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) -CONS( 1977, mfootb, 0, 0, mfootb, mfootb, mfootb_state, empty_init, "Mattel Electronics", "Football (Mattel)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) -CONS( 1978, mbaseb, 0, 0, mbaseb, mbaseb, mbaseb_state, empty_init, "Mattel Electronics", "Baseball (Mattel)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) -CONS( 1980, gravity, 0, 0, gravity, gravity, gravity_state, empty_init, "Mattel Electronics", "Gravity (Mattel)", MACHINE_SUPPORTS_SAVE | MACHINE_NOT_WORKING ) +CONS( 1976, autorace, 0, 0, autorace, autorace, autorace_state, empty_init, "Mattel Electronics", "Auto Race", MACHINE_SUPPORTS_SAVE ) +CONS( 1977, misatk, 0, 0, misatk, misatk, misatk_state, empty_init, "Mattel Electronics", "Missile Attack (Mattel)", MACHINE_SUPPORTS_SAVE ) +CONS( 1977, mfootb, 0, 0, mfootb, mfootb, mfootb_state, empty_init, "Mattel Electronics", "Football (Mattel)", MACHINE_SUPPORTS_SAVE ) +CONS( 1978, mbaseb, 0, 0, mbaseb, mbaseb, mbaseb_state, empty_init, "Mattel Electronics", "Baseball (Mattel)", MACHINE_SUPPORTS_SAVE ) +CONS( 1980, gravity, 0, 0, gravity, gravity, gravity_state, empty_init, "Mattel Electronics", "Gravity (Mattel)", MACHINE_SUPPORTS_SAVE ) COMP( 1975, rw18r, 0, 0, rw18r, rw18r, rw18r_state, empty_init, "Rockwell", "18R (Rockwell)", MACHINE_SUPPORTS_SAVE | MACHINE_NO_SOUND_HW | MACHINE_NOT_WORKING ) diff --git a/src/mame/drivers/hh_pps41.cpp b/src/mame/drivers/hh_pps41.cpp index 230f07b963d..2521f355b0d 100644 --- a/src/mame/drivers/hh_pps41.cpp +++ b/src/mame/drivers/hh_pps41.cpp @@ -675,7 +675,7 @@ private: void mfootb2_state::update_display() { - m_display->matrix(m_d, (m_r & 0x7f) | (m_d >> 4 & 0x80) | (m_r << 1 & 0x700)); + m_display->matrix(m_d, (m_r << 1 & 0x700) | (m_d >> 4 & 0x80) | (m_r & 0x7f)); } void mfootb2_state::write_d(u16 data) @@ -715,8 +715,8 @@ static INPUT_PORTS_START( mfootb2 ) PORT_START("IN.1") // DIO11 PORT_CONFNAME( 0x400, 0x000, DEF_STR( Difficulty ) ) - PORT_CONFSETTING( 0x000, "1" ) - PORT_CONFSETTING( 0x400, "2" ) + PORT_CONFSETTING( 0x000, "1" ) // PRO 1 + PORT_CONFSETTING( 0x400, "2" ) // PRO 2 INPUT_PORTS_END void mfootb2_state::mfootb2(machine_config &config) @@ -741,7 +741,7 @@ void mfootb2_state::mfootb2(machine_config &config) SPEAKER_SOUND(config, m_speaker); static const double speaker_levels[4] = { 0.0, 1.0, -1.0, 0.0 }; m_speaker->set_levels(4, speaker_levels); - m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25); + m_speaker->add_route(ALL_OUTPUTS, "mono", 0.125); } // roms @@ -903,7 +903,7 @@ void brainbaf_state::brainbaf(machine_config &config) SPEAKER_SOUND(config, m_speaker); static const double speaker_levels[4] = { 0.0, 1.0, -1.0, 0.0 }; m_speaker->set_levels(4, speaker_levels); - m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25); + m_speaker->add_route(ALL_OUTPUTS, "mono", 0.125); } // roms @@ -1081,7 +1081,7 @@ void horocomp_state::horocomp(machine_config &config) SPEAKER_SOUND(config, m_speaker); static const double speaker_levels[4] = { 0.0, 1.0, -1.0, 0.0 }; m_speaker->set_levels(4, speaker_levels); - m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25); + m_speaker->add_route(ALL_OUTPUTS, "mono", 0.125); } // roms @@ -1572,7 +1572,7 @@ void rdqa_state::rdqa(machine_config &config) SPEAKER_SOUND(config, m_speaker); static const double speaker_levels[4] = { 0.0, 1.0, -1.0, 0.0 }; m_speaker->set_levels(4, speaker_levels); - m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25); + m_speaker->add_route(ALL_OUTPUTS, "mono", 0.125); } // roms diff --git a/src/mame/layout/autorace.lay b/src/mame/layout/autorace.lay new file mode 100644 index 00000000000..a6a10810b55 --- /dev/null +++ b/src/mame/layout/autorace.lay @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/mame/layout/cnfball.lay b/src/mame/layout/cnfball.lay index dcf092b1784..7ad19139680 100644 --- a/src/mame/layout/cnfball.lay +++ b/src/mame/layout/cnfball.lay @@ -69,13 +69,13 @@ license:CC0 - - - - - - - + + + + + + + diff --git a/src/mame/layout/gravity.lay b/src/mame/layout/gravity.lay new file mode 100644 index 00000000000..ac244876af2 --- /dev/null +++ b/src/mame/layout/gravity.lay @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/mame/layout/mbaseb.lay b/src/mame/layout/mbaseb.lay new file mode 100644 index 00000000000..2cc709d2071 --- /dev/null +++ b/src/mame/layout/mbaseb.lay @@ -0,0 +1,218 @@ + + + + + + + + + + + ]]> + + + + + + ]]> + + + + + + ]]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/mame/layout/mfootb.lay b/src/mame/layout/mfootb.lay new file mode 100644 index 00000000000..023c19a7571 --- /dev/null +++ b/src/mame/layout/mfootb.lay @@ -0,0 +1,164 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/mame/layout/mfootb2.lay b/src/mame/layout/mfootb2.lay index c3a2042f0b1..30f39be73cf 100644 --- a/src/mame/layout/mfootb2.lay +++ b/src/mame/layout/mfootb2.lay @@ -12,27 +12,27 @@ license:CC0 - + - + - + - + - + - + @@ -64,13 +64,13 @@ license:CC0 - - - - - - - + + + + + + + diff --git a/src/mame/layout/microvision.lay b/src/mame/layout/microvision.lay index 571b5a8afb7..f9e00cb0310 100644 --- a/src/mame/layout/microvision.lay +++ b/src/mame/layout/microvision.lay @@ -37,7 +37,7 @@ license:CC0 - + diff --git a/src/mame/layout/misatk.lay b/src/mame/layout/misatk.lay new file mode 100644 index 00000000000..511615cee49 --- /dev/null +++ b/src/mame/layout/misatk.lay @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/mame/layout/tcfball.lay b/src/mame/layout/tcfball.lay index cb36316b5fc..654a0022cb7 100644 --- a/src/mame/layout/tcfball.lay +++ b/src/mame/layout/tcfball.lay @@ -69,13 +69,13 @@ license:CC0 - - - - - - - + + + + + + + diff --git a/src/mame/layout/ttfball.lay b/src/mame/layout/ttfball.lay index 14b16b7b2e6..0567d807788 100644 --- a/src/mame/layout/ttfball.lay +++ b/src/mame/layout/ttfball.lay @@ -69,13 +69,13 @@ license:CC0 - - - - - - - + + + + + + +