From e3c5a3153036a22586fcd70a18f94421833a77a0 Mon Sep 17 00:00:00 2001 From: hap Date: Tue, 28 Jan 2025 14:28:32 +0100 Subject: [PATCH] mole: reduce unrealistic 6502 clock --- src/mame/misc/mole.cpp | 24 ++++++++---------------- src/mame/misc/ssingles.cpp | 5 ++--- src/mame/misc/sstrangr.cpp | 3 +-- src/mame/taito/taito_b.cpp | 10 +++------- 4 files changed, 14 insertions(+), 28 deletions(-) diff --git a/src/mame/misc/mole.cpp b/src/mame/misc/mole.cpp index 6a1e913aed7..8b4fb2ee8c9 100644 --- a/src/mame/misc/mole.cpp +++ b/src/mame/misc/mole.cpp @@ -50,8 +50,10 @@ ******************************************************************************/ #include "emu.h" + #include "cpu/m6502/m6502.h" #include "sound/ay8910.h" + #include "emupal.h" #include "screen.h" #include "speaker.h" @@ -71,13 +73,16 @@ public: void mole(machine_config &config); +protected: + virtual void video_start() override ATTR_COLD; + private: required_device m_maincpu; required_device m_gfxdecode; /* video-related */ tilemap_t *m_bg_tilemap = nullptr; - int m_tile_bank = 0; + uint8_t m_tile_bank = 0; /* memory */ uint16_t m_tileram[0x400]; @@ -88,9 +93,6 @@ private: void mole_flipscreen_w(uint8_t data); uint8_t mole_protection_r(offs_t offset); TILE_GET_INFO_MEMBER(get_bg_tile_info); - virtual void machine_start() override ATTR_COLD; - virtual void machine_reset() override ATTR_COLD; - virtual void video_start() override ATTR_COLD; uint32_t screen_update_mole(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); void mole_map(address_map &map) ATTR_COLD; }; @@ -115,6 +117,7 @@ void mole_state::video_start() m_bg_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(mole_state::get_bg_tile_info)), TILEMAP_SCAN_ROWS, 8, 8, 40, 25); save_item(NAME(m_tileram)); + save_item(NAME(m_tile_bank)); } void mole_state::mole_tileram_w(offs_t offset, uint8_t data) @@ -145,7 +148,6 @@ uint32_t mole_state::screen_update_mole(screen_device &screen, bitmap_ind16 &bit } - /************************************* * * Memory handlers @@ -316,20 +318,10 @@ GFXDECODE_END * *************************************/ -void mole_state::machine_start() -{ - save_item(NAME(m_tile_bank)); -} - -void mole_state::machine_reset() -{ - m_tile_bank = 0; -} - void mole_state::mole(machine_config &config) { /* basic machine hardware */ - M6502(config, m_maincpu, 4000000); // ??? + M6502(config, m_maincpu, 2000000); // ??? m_maincpu->set_addrmap(AS_PROGRAM, &mole_state::mole_map); m_maincpu->set_vblank_int("screen", FUNC(mole_state::irq0_line_assert)); diff --git a/src/mame/misc/ssingles.cpp b/src/mame/misc/ssingles.cpp index 9300eee32b8..82e0cc74e1b 100644 --- a/src/mame/misc/ssingles.cpp +++ b/src/mame/misc/ssingles.cpp @@ -15,14 +15,14 @@ TODO: - atamanot: needs a trojan, in order to understand how the protection really works. - colors (missing PROM(s) ?) - - samples (at least two of unused ROMs contains samples (unkn. format , ADPCM ?) + - samples (at least two of unused ROMs contains samples (unkn. format, ADPCM ?) - dips (one is tested in game (difficulty related?), another 2 are tested at start) Unknown reads/writes: - AY i/o ports (writes) - mem $c000, $c001 = protection device ? if tests fails, game crashes (problems with stack - skipped code with "pop af") - i/o port $8 = data read used for $e command arg for one of AY chips (volume? - could be a sample player (based on volume changes?) - - i/o port $1a = 1 or 0, rarely accessed, related to crt writes + - i/o port $1a = 1 or 0, rarely accessed, related to crt writes ================================================================== @@ -580,7 +580,6 @@ void ssingles_state::ssingles(machine_config &config) SPEAKER(config, "mono").front_center(); AY8910(config, "ay1", 1'500'000).add_route(ALL_OUTPUTS, "mono", 0.5); // ? MHz - AY8910(config, "ay2", 1'500'000).add_route(ALL_OUTPUTS, "mono", 0.5); // ? MHz } diff --git a/src/mame/misc/sstrangr.cpp b/src/mame/misc/sstrangr.cpp index bb15b2f37f4..07e65169f0d 100644 --- a/src/mame/misc/sstrangr.cpp +++ b/src/mame/misc/sstrangr.cpp @@ -8,7 +8,6 @@ /* */ /*******************************************************/ - /* ******************************************************** @@ -570,7 +569,7 @@ void sstrangr_state::sstrangr(machine_config &config) // video hardware screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); - screen.set_size(32*8, 262); // vert size is a guess, taken from mw8080bw + screen.set_size(32*8, 262); // vert size is a guess, taken from mw8080bw screen.set_visarea(0*8, 32*8-1, 4*8, 32*8-1); screen.set_refresh_hz(60); screen.set_screen_update(FUNC(sstrangr_state::screen_update_sstrangr)); diff --git a/src/mame/taito/taito_b.cpp b/src/mame/taito/taito_b.cpp index 3a00e697b1c..27599230cd6 100644 --- a/src/mame/taito/taito_b.cpp +++ b/src/mame/taito/taito_b.cpp @@ -3709,13 +3709,9 @@ GAME( 1994, bublbust, pbobble, pbobble, pbobble, taitob_state, init_taito_b, GAME( 1994, spacedx, 0, spacedx, pbobble, taitob_state, init_taito_b, ROT0, "Taito Corporation", "Space Invaders DX (US, v2.1)", MACHINE_SUPPORTS_SAVE ) GAME( 1994, spacedxj, spacedx, spacedx, pbobble, taitob_state, init_taito_b, ROT0, "Taito Corporation", "Space Invaders DX (Japan, v2.1)", MACHINE_SUPPORTS_SAVE ) GAME( 1994, spacedxo, spacedx, spacedxo, spacedxo, taitob_state, init_taito_b, ROT0, "Taito Corporation", "Space Invaders DX (Japan, v2.0)", MACHINE_SUPPORTS_SAVE ) -/* - Sonic Blast Man is a ticket dispensing game. - (Japanese version however does not dispense them, only US does - try the "sbm_patch" in the machine_config). - It is a bit different from other games running on this system, - in that it has a punching pad that player needs to punch to hit - the enemy. -*/ + +// Sonic Blast Man is a ticket dispensing game. (Japanese version however does not dispense them, only US does - try the "sbm_patch" in the machine_config). +// It is a bit different from other games running on this system, in that it has a punching pad that player needs to punch to hit the enemy. GAME( 1990, sbm, 0, sbm, sbm, taitob_state, init_taito_b, ROT0, "Taito Corporation", "Sonic Blast Man (US)", MACHINE_SUPPORTS_SAVE | MACHINE_MECHANICAL ) GAME( 1990, sbmj, sbm, sbm, sbmj, taitob_state, init_taito_b, ROT0, "Taito Corporation", "Sonic Blast Man (Japan)", MACHINE_SUPPORTS_SAVE | MACHINE_MECHANICAL ) GAME( 1994, realpunc, 0, realpunc, realpunc, taitob_c_state, init_taito_b, ROT0, "Taito Corporation Japan", "Real Puncher (World, v2.12O)", MACHINE_SUPPORTS_SAVE | MACHINE_MECHANICAL )