summaryrefslogtreecommitdiffstats
path: root/src/mame/drivers/hh_ucom4.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/hh_ucom4.cpp')
-rw-r--r--src/mame/drivers/hh_ucom4.cpp253
1 files changed, 145 insertions, 108 deletions
diff --git a/src/mame/drivers/hh_ucom4.cpp b/src/mame/drivers/hh_ucom4.cpp
index fc75f7a5a98..408df17b279 100644
--- a/src/mame/drivers/hh_ucom4.cpp
+++ b/src/mame/drivers/hh_ucom4.cpp
@@ -122,12 +122,12 @@ protected:
optional_ioport_array<6> m_inputs; // max 6
// misc common
- u8 m_port[9]; // MCU port A-I write data (optional)
- u8 m_int; // MCU INT pin state
- u16 m_inp_mux; // multiplexed inputs mask
+ u8 m_port[9] = { }; // MCU port A-I write data (optional)
+ u8 m_int = 0; // MCU INT pin state
+ u16 m_inp_mux = 0; // multiplexed inputs mask
- u32 m_grid; // VFD current row data
- u32 m_plate; // VFD current column data
+ u32 m_grid = 0; // VFD current row data
+ u32 m_plate = 0; // VFD current column data
u8 read_inputs(int columns);
void refresh_interrupts(void);
@@ -152,13 +152,6 @@ protected:
void hh_ucom4_state::machine_start()
{
- // zerofill
- memset(m_port, 0, sizeof(m_port));
- m_int = 0;
- m_inp_mux = 0;
- m_grid = 0;
- m_plate = 0;
-
// register for savestates
save_item(NAME(m_port));
save_item(NAME(m_int));
@@ -255,11 +248,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void ufombs(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
void speaker_w(u8 data);
- void ufombs(machine_config &config);
};
// handlers
@@ -312,7 +307,7 @@ INPUT_PORTS_END
void ufombs_state::ufombs(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -324,7 +319,7 @@ void ufombs_state::ufombs(machine_config &config)
m_maincpu->write_h().set(FUNC(ufombs_state::grid_w));
m_maincpu->write_i().set(FUNC(ufombs_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(243, 1080);
@@ -332,7 +327,7 @@ void ufombs_state::ufombs(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 10);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
static const double speaker_levels[] = { 0.0, 1.0, -1.0, 0.0 };
@@ -377,11 +372,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void ssfball(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
u8 input_b_r();
- void ssfball(machine_config &config);
};
// handlers
@@ -468,7 +465,7 @@ INPUT_PORTS_END
void ssfball_state::ssfball(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.3");
m_maincpu->read_b().set(FUNC(ssfball_state::input_b_r));
@@ -480,7 +477,7 @@ void ssfball_state::ssfball(machine_config &config)
m_maincpu->write_h().set(FUNC(ssfball_state::plate_w));
m_maincpu->write_i().set(FUNC(ssfball_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 482);
@@ -488,7 +485,7 @@ void ssfball_state::ssfball(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 16);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
static const double speaker_levels[] = { 0.0, 1.0, -1.0, 0.0 };
@@ -538,11 +535,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void bmsoccer(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
u8 input_a_r();
- void bmsoccer(machine_config &config);
};
// handlers
@@ -615,7 +614,7 @@ INPUT_PORTS_END
void bmsoccer_state::bmsoccer(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set(FUNC(bmsoccer_state::input_a_r));
m_maincpu->read_b().set_ioport("IN.2");
@@ -627,7 +626,7 @@ void bmsoccer_state::bmsoccer(machine_config &config)
m_maincpu->write_h().set(FUNC(bmsoccer_state::plate_w));
m_maincpu->write_i().set(FUNC(bmsoccer_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(271, 1080);
@@ -635,7 +634,7 @@ void bmsoccer_state::bmsoccer(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 16);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -671,11 +670,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void bmsafari(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
void speaker_w(u8 data);
- void bmsafari(machine_config &config);
};
// handlers
@@ -733,7 +734,7 @@ INPUT_PORTS_END
void bmsafari_state::bmsafari(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -744,7 +745,7 @@ void bmsafari_state::bmsafari(machine_config &config)
m_maincpu->write_h().set(FUNC(bmsafari_state::plate_w));
m_maincpu->write_i().set(FUNC(bmsafari_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(248, 1080);
@@ -752,7 +753,7 @@ void bmsafari_state::bmsafari(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 10);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -791,11 +792,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void splasfgt(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
u8 input_b_r();
- void splasfgt(machine_config &config);
};
// handlers
@@ -891,7 +894,7 @@ INPUT_PORTS_END
void splasfgt_state::splasfgt(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.4");
m_maincpu->read_b().set(FUNC(splasfgt_state::input_b_r));
@@ -903,7 +906,7 @@ void splasfgt_state::splasfgt(machine_config &config)
m_maincpu->write_h().set(FUNC(splasfgt_state::grid_w));
m_maincpu->write_i().set(FUNC(splasfgt_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 476);
@@ -911,7 +914,7 @@ void splasfgt_state::splasfgt(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 16);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
static const double speaker_levels[] = { 0.0, 1.0, -1.0, 0.0 };
@@ -953,10 +956,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void bcclimbr(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void bcclimbr(machine_config &config);
};
// handlers
@@ -1006,7 +1011,7 @@ INPUT_PORTS_END
void bcclimbr_state::bcclimbr(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1018,7 +1023,7 @@ void bcclimbr_state::bcclimbr(machine_config &config)
m_maincpu->write_h().set(FUNC(bcclimbr_state::grid_w));
m_maincpu->write_i().set(FUNC(bcclimbr_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(310, 1080);
@@ -1026,7 +1031,7 @@ void bcclimbr_state::bcclimbr(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(6, 20);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1068,11 +1073,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void tactix(machine_config &config);
+
+private:
void leds_w(offs_t offset, u8 data);
void speaker_w(u8 data);
void input_w(offs_t offset, u8 data);
u8 input_r();
- void tactix(machine_config &config);
};
// handlers
@@ -1139,7 +1146,7 @@ INPUT_PORTS_END
void tactix_state::tactix(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D557L(config, m_maincpu, 200000); // approximation
m_maincpu->read_a().set(FUNC(tactix_state::input_r));
m_maincpu->write_c().set(FUNC(tactix_state::input_w));
@@ -1148,11 +1155,11 @@ void tactix_state::tactix(machine_config &config)
m_maincpu->write_f().set(FUNC(tactix_state::leds_w));
m_maincpu->write_g().set(FUNC(tactix_state::speaker_w));
- /* video hardware */
+ // video hardware
PWM_DISPLAY(config, m_display).set_size(4, 4);
config.set_default_layout(layout_tactix);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1187,15 +1194,17 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void ctntune(machine_config &config);
+
// start button powers unit back on
DECLARE_INPUT_CHANGED_MEMBER(start_button) { m_maincpu->set_input_line(INPUT_LINE_RESET, CLEAR_LINE); }
+private:
void update_display();
void _7seg_w(offs_t offset, u8 data);
void speaker_w(u8 data);
void input_w(offs_t offset, u8 data);
u8 input_r();
- void ctntune(machine_config &config);
};
// handlers
@@ -1279,7 +1288,7 @@ INPUT_PORTS_END
void ctntune_state::ctntune(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D557L(config, m_maincpu, 200000); // approximation
m_maincpu->read_a().set(FUNC(ctntune_state::input_r));
m_maincpu->write_c().set(FUNC(ctntune_state::input_w));
@@ -1288,12 +1297,12 @@ void ctntune_state::ctntune(machine_config &config)
m_maincpu->write_f().set(FUNC(ctntune_state::_7seg_w));
m_maincpu->write_g().set(FUNC(ctntune_state::speaker_w));
- /* video hardware */
+ // video hardware
PWM_DISPLAY(config, m_display).set_size(1, 7+2);
m_display->set_segmask(1, 0x7f);
config.set_default_layout(layout_ctntune);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1330,10 +1339,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void invspace(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void invspace(machine_config &config);
};
// handlers
@@ -1382,7 +1393,7 @@ INPUT_PORTS_END
void invspace_state::invspace(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1394,7 +1405,7 @@ void invspace_state::invspace(machine_config &config)
m_maincpu->write_h().set(FUNC(invspace_state::plate_w));
m_maincpu->write_i().set(FUNC(invspace_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(289, 1080);
@@ -1402,7 +1413,7 @@ void invspace_state::invspace(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 19);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1442,10 +1453,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void efball(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void efball(machine_config &config);
};
// handlers
@@ -1508,7 +1521,7 @@ INPUT_PORTS_END
void efball_state::efball(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1520,11 +1533,11 @@ void efball_state::efball(machine_config &config)
m_maincpu->write_h().set(FUNC(efball_state::grid_w));
m_maincpu->write_i().set(FUNC(efball_state::plate_w));
- /* video hardware */
+ // video hardware
PWM_DISPLAY(config, m_display).set_size(10, 11);
config.set_default_layout(layout_efball);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1563,11 +1576,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void galaxy2b(machine_config &config);
+ void galaxy2(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void galaxy2b(machine_config &config);
- void galaxy2(machine_config &config);
};
// handlers
@@ -1616,7 +1631,7 @@ INPUT_PORTS_END
void galaxy2_state::galaxy2(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1628,7 +1643,7 @@ void galaxy2_state::galaxy2(machine_config &config)
m_maincpu->write_h().set(FUNC(galaxy2_state::plate_w));
m_maincpu->write_i().set(FUNC(galaxy2_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(304, 1080);
@@ -1636,7 +1651,7 @@ void galaxy2_state::galaxy2(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(10, 15);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1646,7 +1661,7 @@ void galaxy2_state::galaxy2b(machine_config &config)
{
galaxy2(config);
- /* video hardware */
+ // video hardware
screen_device *screen = subdevice<screen_device>("screen");
screen->set_size(306, 1080);
screen->set_visarea_full();
@@ -1695,10 +1710,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void astrocmd(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void astrocmd(machine_config &config);
};
// handlers
@@ -1754,7 +1771,7 @@ INPUT_PORTS_END
void astrocmd_state::astrocmd(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1766,7 +1783,7 @@ void astrocmd_state::astrocmd(machine_config &config)
m_maincpu->write_h().set(FUNC(astrocmd_state::plate_w));
m_maincpu->write_i().set(FUNC(astrocmd_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 525);
@@ -1774,7 +1791,7 @@ void astrocmd_state::astrocmd(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 17);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1815,10 +1832,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void edracula(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void edracula(machine_config &config);
};
// handlers
@@ -1866,7 +1885,7 @@ INPUT_PORTS_END
void edracula_state::edracula(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -1878,7 +1897,7 @@ void edracula_state::edracula(machine_config &config)
m_maincpu->write_h().set(FUNC(edracula_state::plate_w));
m_maincpu->write_i().set(FUNC(edracula_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 526);
@@ -1886,7 +1905,7 @@ void edracula_state::edracula(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(8, 18);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -1922,11 +1941,13 @@ public:
m_lcd(*this, "lcd")
{ }
+ void mcompgin(machine_config &config);
+
+private:
required_device<hlcd0530_device> m_lcd;
void lcd_output_w(offs_t offset, u32 data);
void lcd_w(u8 data);
- void mcompgin(machine_config &config);
};
// handlers
@@ -1964,13 +1985,13 @@ INPUT_PORTS_END
void mcompgin_state::mcompgin(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D650(config, m_maincpu, 400_kHz_XTAL); // TDK FCR400K
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
m_maincpu->write_e().set(FUNC(mcompgin_state::lcd_w));
- /* video hardware */
+ // video hardware
HLCD0530(config, m_lcd, 500); // C=0.01uF
m_lcd->write_cols().set(FUNC(mcompgin_state::lcd_output_w));
@@ -1978,7 +1999,7 @@ void mcompgin_state::mcompgin(machine_config &config)
config.set_default_layout(layout_mcompgin);
- /* no sound! */
+ // no sound!
}
// roms
@@ -2008,11 +2029,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void mvbfree(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
void speaker_w(u8 data);
- void mvbfree(machine_config &config);
};
// handlers
@@ -2070,7 +2093,7 @@ INPUT_PORTS_END
void mvbfree_state::mvbfree(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -2082,11 +2105,11 @@ void mvbfree_state::mvbfree(machine_config &config)
m_maincpu->write_h().set(FUNC(mvbfree_state::grid_w));
m_maincpu->write_i().set(FUNC(mvbfree_state::speaker_w));
- /* video hardware */
+ // video hardware
PWM_DISPLAY(config, m_display).set_size(14, 10);
config.set_default_layout(layout_mvbfree);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2127,11 +2150,13 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void grobot9(machine_config &config);
+
+private:
void lamps_w(offs_t offset, u8 data);
void speaker_w(u8 data);
void input_w(u8 data);
u8 input_r();
- void grobot9(machine_config &config);
};
// handlers
@@ -2197,7 +2222,7 @@ INPUT_PORTS_END
void grobot9_state::grobot9(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D557L(config, m_maincpu, 160000); // approximation
m_maincpu->read_a().set(FUNC(grobot9_state::input_r));
m_maincpu->write_c().set(FUNC(grobot9_state::input_w));
@@ -2205,11 +2230,11 @@ void grobot9_state::grobot9(machine_config &config)
m_maincpu->write_e().set(FUNC(grobot9_state::lamps_w));
m_maincpu->write_f().set(FUNC(grobot9_state::lamps_w));
- /* video hardware */
+ // video hardware
PWM_DISPLAY(config, m_display).set_size(1, 9);
config.set_default_layout(layout_grobot9);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2246,10 +2271,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void tccombat(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void tccombat(machine_config &config);
};
// handlers
@@ -2295,7 +2322,7 @@ INPUT_PORTS_END
void tccombat_state::tccombat(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 400000); // approximation
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->write_c().set(FUNC(tccombat_state::grid_w));
@@ -2306,7 +2333,7 @@ void tccombat_state::tccombat(machine_config &config)
m_maincpu->write_h().set(FUNC(tccombat_state::plate_w));
m_maincpu->write_i().set(FUNC(tccombat_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(300, 1080);
@@ -2314,7 +2341,7 @@ void tccombat_state::tccombat(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 20);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2356,18 +2383,20 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
- void update_display();
- void grid_w(offs_t offset, u8 data);
- void plate_w(offs_t offset, u8 data);
- void port_e_w(u8 data);
- u8 input_r(offs_t offset);
+ void tmtennis(machine_config &config);
- void set_clock();
DECLARE_INPUT_CHANGED_MEMBER(difficulty_switch) { set_clock(); }
- void tmtennis(machine_config &config);
protected:
virtual void machine_reset() override;
+
+private:
+ void set_clock();
+ void update_display();
+ void grid_w(offs_t offset, u8 data);
+ void plate_w(offs_t offset, u8 data);
+ void port_e_w(u8 data);
+ u8 input_r(offs_t offset);
};
void tmtennis_state::machine_reset()
@@ -2463,7 +2492,7 @@ INPUT_PORTS_END
void tmtennis_state::tmtennis(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D552(config, m_maincpu, 360000); // see set_clock
m_maincpu->read_a().set(FUNC(tmtennis_state::input_r));
m_maincpu->read_b().set(FUNC(tmtennis_state::input_r));
@@ -2475,7 +2504,7 @@ void tmtennis_state::tmtennis(machine_config &config)
m_maincpu->write_h().set(FUNC(tmtennis_state::grid_w));
m_maincpu->write_i().set(FUNC(tmtennis_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 417);
@@ -2484,7 +2513,7 @@ void tmtennis_state::tmtennis(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(12, 12);
config.set_default_layout(layout_tmtennis);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2530,10 +2559,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void tmpacman(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void tmpacman(machine_config &config);
};
// handlers
@@ -2583,7 +2614,7 @@ INPUT_PORTS_END
void tmpacman_state::tmpacman(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 430_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -2595,7 +2626,7 @@ void tmpacman_state::tmpacman(machine_config &config)
m_maincpu->write_h().set(FUNC(tmpacman_state::plate_w));
m_maincpu->write_i().set(FUNC(tmpacman_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 508);
@@ -2603,7 +2634,7 @@ void tmpacman_state::tmpacman(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(8, 19);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2645,10 +2676,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void tmscramb(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void tmscramb(machine_config &config);
};
// handlers
@@ -2696,7 +2729,7 @@ INPUT_PORTS_END
void tmscramb_state::tmscramb(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->read_b().set_ioport("IN.1");
@@ -2708,7 +2741,7 @@ void tmscramb_state::tmscramb(machine_config &config)
m_maincpu->write_h().set(FUNC(tmscramb_state::plate_w));
m_maincpu->write_i().set(FUNC(tmscramb_state::grid_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 556);
@@ -2716,7 +2749,7 @@ void tmscramb_state::tmscramb(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(10, 17);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2757,10 +2790,12 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void tcaveman(machine_config &config);
+
+private:
void update_display();
void grid_w(offs_t offset, u8 data);
void plate_w(offs_t offset, u8 data);
- void tcaveman(machine_config &config);
};
// handlers
@@ -2806,7 +2841,7 @@ INPUT_PORTS_END
void tcaveman_state::tcaveman(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set_ioport("IN.0");
m_maincpu->write_c().set(FUNC(tcaveman_state::grid_w));
@@ -2817,7 +2852,7 @@ void tcaveman_state::tcaveman(machine_config &config)
m_maincpu->write_h().set(FUNC(tcaveman_state::plate_w));
m_maincpu->write_i().set(FUNC(tcaveman_state::plate_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(1920, 559);
@@ -2825,7 +2860,7 @@ void tcaveman_state::tcaveman(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(8, 19);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);
@@ -2867,9 +2902,11 @@ public:
hh_ucom4_state(mconfig, type, tag)
{ }
+ void alnchase(machine_config &config);
+
+private:
void output_w(offs_t offset, u8 data);
u8 input_r();
- void alnchase(machine_config &config);
};
// handlers
@@ -2948,7 +2985,7 @@ INPUT_PORTS_END
void alnchase_state::alnchase(machine_config &config)
{
- /* basic machine hardware */
+ // basic machine hardware
NEC_D553(config, m_maincpu, 400_kHz_XTAL);
m_maincpu->read_a().set(FUNC(alnchase_state::input_r));
m_maincpu->read_b().set_ioport("IN.2");
@@ -2960,7 +2997,7 @@ void alnchase_state::alnchase(machine_config &config)
m_maincpu->write_h().set(FUNC(alnchase_state::output_w));
m_maincpu->write_i().set(FUNC(alnchase_state::output_w));
- /* video hardware */
+ // video hardware
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_SVG));
screen.set_refresh_hz(60);
screen.set_size(365, 1080);
@@ -2968,7 +3005,7 @@ void alnchase_state::alnchase(machine_config &config)
PWM_DISPLAY(config, m_display).set_size(9, 17);
- /* sound hardware */
+ // sound hardware
SPEAKER(config, "mono").front_center();
SPEAKER_SOUND(config, m_speaker);
m_speaker->add_route(ALL_OUTPUTS, "mono", 0.25);