From b37f10cabe5cb049d4d947c1f2e009de73ae71fa Mon Sep 17 00:00:00 2001 From: David Haywood Date: Mon, 13 Oct 2025 19:48:44 +0100 Subject: [PATCH 01/53] added 3 sets --- src/mame/handheld/st2302u_bbl_spi.cpp | 24 ++++++++++++++++++++++++ src/mame/mame.lst | 3 +++ 2 files changed, 27 insertions(+) diff --git a/src/mame/handheld/st2302u_bbl_spi.cpp b/src/mame/handheld/st2302u_bbl_spi.cpp index 85bc0033c5cd9..e4e514b90259b 100644 --- a/src/mame/handheld/st2302u_bbl_spi.cpp +++ b/src/mame/handheld/st2302u_bbl_spi.cpp @@ -417,6 +417,13 @@ ROM_START(dphh8633) ROM_LOAD("25lq032.u2", 0x000000, 0x400000, CRC(45b8609a) SHA1(d03615a68465a1a365ba07db0b352424680d62d0) ) ROM_END +ROM_START(dphh8661) + INTERNAL_ROM_TYPE2 + + ROM_REGION(0x800000, "spi", ROMREGION_ERASEFF) + ROM_LOAD("p25d32h.u2", 0x000000, 0x400000, CRC(b91c1dfc) SHA1(97557d10174c74d40aba780398cb2de3974b2f24) ) +ROM_END + ROM_START(retro150) INTERNAL_ROM_TYPE2 @@ -438,6 +445,20 @@ ROM_START(pg118) ROM_LOAD("25vq32.bin", 0x000000, 0x400000, CRC(e99f1621) SHA1(f907c36a1a884d892331b7de294a8fd58f7bf9d5) ) ROM_END +ROM_START(ppg118) + INTERNAL_ROM_TYPE2 + + ROM_REGION(0x800000, "spi", ROMREGION_ERASEFF) + ROM_LOAD("25q32.u2", 0x000000, 0x400000, CRC(c96a30b8) SHA1(da2c41e57b852f3a6644a7cbd0d3740e1b0555dc) ) +ROM_END + +ROM_START(table108) + INTERNAL_ROM_TYPE2 + + ROM_REGION(0x800000, "spi", ROMREGION_ERASEFF) + ROM_LOAD("mx25q32.bin", 0x000000, 0x400000, CRC(3fcad3d6) SHA1(9e7b1ba2be174c9ef41eaa06f1537dbe14a695e0) ) +ROM_END + ROM_START(toumapet) INTERNAL_ROM_TYPE2 // still does't boot with this one, is it different internal ROM again, or just different mappings? @@ -485,8 +506,11 @@ CONS( 201?, retro150, 0, 0, bbl380_24mhz, bbl380, bbl380_state CONS( 201?, retro150a, retro150,0, bbl380_24mhz, bbl380, bbl380_state, empty_init, "Red5", "Retro Arcade Game Controller (150-in-1) (set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND ) // these are for the Japanese market, the ROM is the same between the Pocket Game and Game Computer but the form factor is different. CONS( 2019, pg118, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "Pocket Game / Game Computer", "Pocket Game 118-in-1 / Game Computer 118-in-1", MACHINE_NOT_WORKING ) +CONS( 201?, ppg118, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "", "PPG Play Portable Game 118 Games (HH-0046)", MACHINE_NOT_WORKING ) +CONS( 201?, table108, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "", "Table Game Classic 108-in-1 (KTFC-001B)", MACHINE_NOT_WORKING ) // it is unclear if dphh8633 refers to the case style, rather than the software, as the dphh8630 set was also noted as previously being found in an 8633 unit CONS( 201?, dphh8633, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "", "Digital Pocket Hand Held System 268-in-1 - Model 8633", MACHINE_NOT_WORKING ) +CONS( 2016, dphh8661, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "", "Digital Pocket Hand Held System 268-in-1 - Model 8661", MACHINE_NOT_WORKING ) // from PCP? (logo on back of console) 2016 date on PCB // also has the 0xE4 XOR, also doesn't currently boot, could be yet another internal ROM CONS( 2021, toumapet, 0, 0, bbl380, bbl380, bbl380_state, empty_init, "Shenzhen Shiji New Technology", "Tou ma Pet", MACHINE_NOT_WORKING ) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index e3c5ac8d24c9c..4a45b85c935de 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19444,14 +19444,17 @@ bbl380 dgun2953 dphh8630 dphh8633 +dphh8661 mc_cb203 pg118 +ppg118 qpet ragc153 retro150 retro150a rhhc152 supreme +table108 throwbck toumapet From 44edc4985e7a8fd80ac1608b31fc3f2b1aa4fe0a Mon Sep 17 00:00:00 2001 From: David Haywood Date: Mon, 13 Oct 2025 20:49:20 +0100 Subject: [PATCH 02/53] add another set --- .../{skeleton => handheld}/evolution_handheld.cpp | 14 ++++++++++++++ src/mame/mame.lst | 11 ++++++----- 2 files changed, 20 insertions(+), 5 deletions(-) rename src/mame/{skeleton => handheld}/evolution_handheld.cpp (81%) diff --git a/src/mame/skeleton/evolution_handheld.cpp b/src/mame/handheld/evolution_handheld.cpp similarity index 81% rename from src/mame/skeleton/evolution_handheld.cpp rename to src/mame/handheld/evolution_handheld.cpp index 8264907d8049e..a3ea1f43ecc16 100644 --- a/src/mame/skeleton/evolution_handheld.cpp +++ b/src/mame/handheld/evolution_handheld.cpp @@ -87,6 +87,18 @@ ROM_START( buttdtct ) ROM_LOAD( "25l64.ic4", 0x000000, 0x800000, CRC(a70a2b0d) SHA1(fe5517d58297b737f9b6f645f76bea2a5dae1eb6) ) ROM_END +ROM_START( pokexyqz ) + ROM_REGION( 0x1000000, "maincpu", 0 ) + ROM_LOAD( "mx25l12835f.u3", 0x000000, 0x1000000, CRC(98e86224) SHA1(63872b7fb8a4ebb3260e3fbded03a93ae5403948) ) + + ROM_REGION( 0x4200000, "nand", 0 ) + ROM_LOAD( "mx23j51243tc.u5", 0x000000, 0x4200000, CRC(2f2c6c0c) SHA1(b47dbd33909306aa882e4a3f246af3150de94837) ) + + ROM_REGION( 0x800, "i2cmem", 0 ) + ROM_LOAD( "24c16.u8", 0x000, 0x800, CRC(a607979b) SHA1(b06d0bac7844d571dd3cde9f2e0440b2555c3820) ) + + // also has an SD card slot (was empty) +ROM_END } // anonymous namespace @@ -97,3 +109,5 @@ CONS( 2018, smkatsum, 0, 0, evolhh, evolhh, evolution_handheldgame // おしりたんてい ププッとかいけつゲーム CONS( 2020, buttdtct, 0, 0, evolhh, evolhh, evolution_handheldgame_state, empty_init, "Tomy", "Oshiri Tantei - Puputto Kaiketsu Game (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) // from a pink 'for girls' unit, exists in other colours, software likely the same + +CONS( 2015, pokexyqz, 0, 0, evolhh, evolhh, evolution_handheldgame_state, empty_init, "Takara Tomy", "Pokemon Encyclopedia Z Pokemon XY Quiz Game Rotom (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 4a45b85c935de..c68ae5c7de06f 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19464,6 +19464,12 @@ chesskng @source:handheld/dbridgec.cpp dbridgec +@source:handheld/evolution_handheld.cpp +buttdtct +evolhh +pokexyqz +smkatsum + @source:handheld/gameking.cpp gamekin3 gameking @@ -43542,11 +43548,6 @@ eurocom2 microtrol waveterm -@source:skeleton/evolution_handheld.cpp -buttdtct -evolhh -smkatsum - @source:skeleton/extrema_m27sv.cpp multgmxl From 912be0dc3c300211f71e89f4fa710ea65741246a Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 14 Oct 2025 15:58:46 +0100 Subject: [PATCH 03/53] add inmotion --- src/mame/mame.lst | 1 + src/mame/tvgames/spg2xx_wiwi.cpp | 56 ++++++++++++++++++++++++++------ 2 files changed, 47 insertions(+), 10 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index c68ae5c7de06f..337f08ef499a1 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47416,6 +47416,7 @@ ddmmeg12 ddmsup foxsport guitrbus +inmotion lexifit marc101 marc250 diff --git a/src/mame/tvgames/spg2xx_wiwi.cpp b/src/mame/tvgames/spg2xx_wiwi.cpp index 96a3c02b9c7bd..ea566216a439f 100644 --- a/src/mame/tvgames/spg2xx_wiwi.cpp +++ b/src/mame/tvgames/spg2xx_wiwi.cpp @@ -30,9 +30,12 @@ class spg2xx_game_wiwi18_state : public spg2xx_game_state void init_wiwi18(); protected: + void machine_reset() override ATTR_COLD; private: void portb_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; + + uint8_t m_numbanks; }; class spg2xx_game_marc101_state : public spg2xx_game_state @@ -121,6 +124,13 @@ class spg2xx_game_marc250_state : public spg2xx_game_marc101_state emu_timer *m_pulse_timer2 = nullptr; }; +void spg2xx_game_wiwi18_state::machine_reset() +{ + spg2xx_game_state::machine_reset(); + int len = memregion("maincpu")->bytes(); + m_numbanks = len / 0x800000; +} + TIMER_CALLBACK_MEMBER(spg2xx_game_marc101_state::toggle_tick) { m_toggle = !m_toggle; @@ -697,15 +707,30 @@ INPUT_PORTS_END void spg2xx_game_wiwi18_state::init_wiwi18() { - // workaround for security checks on startup - + // workaround for checks on startup, probably needs timer readback on port bits in core? uint16_t* rom = (uint16_t*)memregion("maincpu")->base(); - if (rom[0x1ca259]==0x4e04) rom[0x1ca259] = 0xf165; // wiwi18 - if (rom[0x1355a4]==0x4e04) rom[0x1355a4] = 0xf165; // foxsport + int len = memregion("maincpu")->bytes(); + + uint16_t ident2[6] = { 0x92c3, 0x9902, 0x42c4, 0x4e04, 0xee01, 0xee00 }; + + for (int i = 0; i < (len / 2) - 6; i++) + { + bool found = true; + for (int j = 0; j < 6; j++) + { + uint16_t cmp1 = ident2[j]; + uint16_t cmp2 = rom[i + j]; - if (rom[0x362e1c]==0x4e04) rom[0x362e1c] = 0xf165; // lexifit - if (rom[0x4c7f4d]==0x4e04) rom[0x4c7f4d] = 0xf165; // lexifit (2nd bank) + if (cmp1 != cmp2) + found = false; + } + if (found) + { + logerror("found problematic code at %08x\n", i + 3); + rom[i + 3] = 0xf165; + } + } } void spg2xx_game_wiwi18_state::portb_w(offs_t offset, uint16_t data, uint16_t mem_mask) @@ -728,12 +753,14 @@ void spg2xx_game_wiwi18_state::portb_w(offs_t offset, uint16_t data, uint16_t me (mem_mask & 0x0002) ? ((data & 0x0002) ? '1' : '0') : 'x', (mem_mask & 0x0001) ? ((data & 0x0001) ? '1' : '0') : 'x'); + // bankswitch code runs in RAM, but on startup game accesses here (with direction bits set in a way that we can't mask) + // so we have this hack to only bank if we're executing from RAM if (m_maincpu->pc() < 0x2000) { - if ((data & 0x0003) == 0x0000) - switch_bank(1); - else - switch_bank(0); + int bank = data & 0x3; + bank ^= 3; + + switch_bank(bank & (m_numbanks-1)); } } @@ -958,6 +985,11 @@ ROM_START( lexifit ) ROM_LOAD16_WORD_SWAP( "lexibook_tv_fitness_center.bin", 0x000000, 0x1000000, CRC(38021230) SHA1(2b949d723a475bfac23d9da4d1a30ea71b332ccb) ) ROM_END +ROM_START( inmotion ) + ROM_REGION( 0x2000000, "maincpu", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "mx26l25722mc.bin", 0x000000, 0x2000000, CRC(81125997) SHA1(824607a3665b1351bccf27de4885a26ca86b40a5) ) +ROM_END + ROM_START( marc101 ) ROM_REGION( 0x4000000, "maincpu", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "m489.u6", 0x0000000, 0x4000000, CRC(0a01695f) SHA1(1a13c5eb9dffdc91fc68a98e8f35bd8a019a8373) ) @@ -1002,6 +1034,10 @@ CONS( 2009, lexifit, 0, 0, rad_skat, lexifit, spg2xx_game_wiwi18_state, CONS( 200?, foxsport, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "Excalibur Electronics", "Fox Sports 7 in 1 Sports Games Plug n' Play", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) +// doesn't really have 198 games, closer to 20, with duplicates starting on different levels +// as with the above sets, inputs aren't currently hooked up, menu can be used by modifying 0x100f in RAM (it's 0x1010 for wiwi18) +CONS( 200?, inmotion, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "Grafix", "IN Motion - Motion Controlled Video Games Console (Hot Game 198 in 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) + // thtere is another 'Drahtlose Spielekonsole 48-in-1' with '11 hyper sports games' (including Running) which are clearly SunPlus and would fit here, with the 37 non-hyper sports games presumably again being a NES/Famiclone cart CONS( 2014, marc101, 0, 0, marc101, m489, spg2xx_game_marc101_state, empty_init, "Millennium 2000 GmbH", "Millennium Arcade 101 (M489) (Game Station 2 101-in-1)", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) From 3995764fcb9da76f8687ccd1b00b349ab369fd53 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 19:52:52 +0100 Subject: [PATCH 04/53] added D9 --- src/mame/mame.lst | 1 + src/mame/nintendo/nes_vt369_vtunknown.cpp | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 337f08ef499a1..6cd5c574364d7 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -35730,6 +35730,7 @@ typo240 240in1ar a6plus d12power +d9_500 denv150 dgun2561 dgun2572 diff --git a/src/mame/nintendo/nes_vt369_vtunknown.cpp b/src/mame/nintendo/nes_vt369_vtunknown.cpp index 52145ea589f67..c279b1199f65a 100644 --- a/src/mame/nintendo/nes_vt369_vtunknown.cpp +++ b/src/mame/nintendo/nes_vt369_vtunknown.cpp @@ -1094,6 +1094,10 @@ ROM_START( d12power ) ROM_LOAD( "25q128.u2", 0x00000, 0x1000000, CRC(02650ad4) SHA1(ca346409e11732d97b892c356fc5da61dc16ab01) ) ROM_END +ROM_START( d9_500 ) + ROM_REGION( 0x1000000, "mainrom", 0 ) + ROM_LOAD( "w25q128jv.u3", 0x00000, 0x1000000, CRC(66b137ce) SHA1(699ffaaf086bdb2001b0c4323b1e098f2dd3f885) ) +ROM_END ROM_START( dgun2572 ) ROM_REGION( 0x2000000, "mainrom", 0 ) // extra pins on subboard not marked @@ -1370,6 +1374,9 @@ CONS( 201?, gon100, 0, 0, vt36x_4mb, vt369, vt36x_state, empty_init, CONS( 201?, d12power, 0, 0, vt36x_16mb, vt369, vt36x_state, empty_init, "SZDiiER", "Power - Charging and playing games (D12) (416-in-1)", MACHINE_IMPERFECT_GRAPHICS ) +// Super Chinese backgrounds don't show properly at least, sold as 'D9' but PCB has D-10D-V1.1 21-8-30 on it +CONS( 2021, d9_500, 0, 0, vt36x_16mb, vt369, vt36x_state, empty_init, "", "D9 500 in 1 Handheld Game Console", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS ) + // GB-50 console supports loading games from SD card (not emulated), main ROM is QSPI flash // Games loaded from SD card are loaded into the QSPI flash at 0x800000 - dump is from a clean factory console // PCB is marked "389" so possibly VT389 but VT369 string in a debug message in firmware From 96f6b5bd57ba4c62e973dd55dca86d5123f2f1b4 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 20:11:39 +0100 Subject: [PATCH 05/53] adde Yule Yuan Electronic Pet --- src/mame/handheld/yuleyuan.cpp | 72 ++++++++++++++++++++++++++++++++++ src/mame/mame.lst | 3 ++ 2 files changed, 75 insertions(+) create mode 100644 src/mame/handheld/yuleyuan.cpp diff --git a/src/mame/handheld/yuleyuan.cpp b/src/mame/handheld/yuleyuan.cpp new file mode 100644 index 0000000000000..82c9ff468a4fb --- /dev/null +++ b/src/mame/handheld/yuleyuan.cpp @@ -0,0 +1,72 @@ +// license:BSD-3-Clause +// copyright-holders: + +// TODO: code is scrambled/encrypted, put this where it belongs after descrambling +// (probably a GeneralPlus) + +#include "emu.h" + +#include "screen.h" +#include "speaker.h" + + +namespace { + +class yuleyuan_state : public driver_device +{ +public: + yuleyuan_state(const machine_config &mconfig, device_type type, const char *tag) : + driver_device(mconfig, type, tag), + m_screen(*this, "screen") + { + } + + void yuleyuan(machine_config &config) ATTR_COLD; + +protected: + virtual void machine_start() override ATTR_COLD; + +private: + u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + + required_device m_screen; +}; + +u32 yuleyuan_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) +{ + return 0; +} + +void yuleyuan_state::machine_start() +{ +} + + +static INPUT_PORTS_START(yuleyuan) +INPUT_PORTS_END + + +void yuleyuan_state::yuleyuan(machine_config &config) +{ + // unknown CPU (encrypted) + + // wrong, just so it's clear this has a screen + SCREEN(config, m_screen, SCREEN_TYPE_LCD); + m_screen->set_refresh_hz(60); + m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(0)); + m_screen->set_size(160, 128); + m_screen->set_visarea(0, 160 - 1, 0, 128 - 1); + m_screen->set_screen_update(FUNC(yuleyuan_state::screen_update)); + + SPEAKER(config, "speaker").front_center(); +} + + +ROM_START( yuleyuan ) + ROM_REGION( 0x1000000, "spi", 0 ) + ROM_LOAD( "25l128.bin", 0x0000000, 0x1000000, CRC(51ab49e2) SHA1(ecad532d27efea55031ffd31ac4479c9c4eceae6) ) +ROM_END + +} // anonymous namespace + +GAME( 2022, yuleyuan, 0, yuleyuan, yuleyuan, yuleyuan_state, empty_init, ROT0, "Yule Yuan", "Yule Yuan Electronic Pet", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 6cd5c574364d7..cc9b087743c8a 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19994,6 +19994,9 @@ vegaplus @source:handheld/wildfire.cpp wildfire +@source:handheld/yuleyuan.cpp +yuleyuan + @source:hds/hds200.cpp hds200 From 5e7eb386a0b2666d2704cb78c7611dedd94eeb36 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 21:35:52 +0100 Subject: [PATCH 06/53] added Pokemon Peaceful Place My Pad (Japan) --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index cc9b087743c8a..d7786313b35b9 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47091,6 +47091,7 @@ neopad pdcm2 pocketmp pocketmr +pokepeac rotom2 saikyopc smatomo diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index d6c2c3f603953..d8890c853e7db 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -297,6 +297,11 @@ ROM_START( dmnslayg ) ROM_LOAD( "tc58nvg0s3hta00_with_spare.u3", 0x0000, 0x8800000, CRC(a9402fdb) SHA1(0809a8da176f65efc2926131ba0259278d3c644d) ) ROM_END +ROM_START( pokepeac ) + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "tc58nvg0s3hta00.u2", 0x0000, 0x8800000, CRC(bdd128b8) SHA1(412eeb83649ea499e4e6ce3c447f0c177d8bc0ce) ) +ROM_END + ROM_START( anpanm19 ) ROM_REGION( 0x1000000, "spi", ROMREGION_ERASE00 ) ROM_LOAD( "25l1280.u3", 0x0000, 0x1000000, CRC(7932fb3e) SHA1(a381eeba5357fe71e4d6081b9b91b57e5705f7f1) ) @@ -484,6 +489,11 @@ CONS( 202?, ardancem, 0, 0, gpl32612, gpl32612, generalplus_g // 鬼滅の刃 全集中パッド(グリーン) CONS( 2021, dmnslayg, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init880, "Bandai", "Demon Slayer: Kimetsu no Yaiba Zenshuuchuu Pad (green ver.) (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// unknown (uses a glob) GPNandTag2 header +CONS( 201?, pokepeac, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init880, "Takara Tomy", "Pokemon Peaceful Place My Pad (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) + + + /* PCB is marked as M2-SPG48-GPG35-V30 2009-08-11 SoC appears to be From c7c2fb914a80d13aff73e07c16bb2cf6e5848e57 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 21:47:00 +0100 Subject: [PATCH 07/53] 2 laptop type things --- src/mame/mame.lst | 2 ++ src/mame/tvgames/generalplus_gpl32612.cpp | 17 +++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index d7786313b35b9..fba87ee723f7a 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47077,6 +47077,8 @@ airobo anpanm19 arcadege ardancem +bandplap +bandslap chiikpc dmnslayg intrtvg diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index d8890c853e7db..05debb10cbd77 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -312,6 +312,16 @@ ROM_START( smatomo ) ROM_LOAD( "mx25l3206e.ic3", 0x0000, 0x400000, CRC(fb4d1684) SHA1(98cecd7ead52118028cb3a1de71cb3528cd81be5) ) ROM_END +ROM_START( bandslap ) + ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) + ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(659f1b0f) SHA1(f3b287589cbcde5201249ea390ec7c51bd23de4c) ) +ROM_END + +ROM_START( bandplap ) + ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) + ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(f85c388d) SHA1(59e30b51e2d6598881eb64edc027e0e27756631f) ) +ROM_END + ROM_START( tamameet ) ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) ROM_LOAD( "25q64.u3", 0x0000, 0x800000, CRC(f15507f8) SHA1(356cb1bd68169eb747898325eacfd7590dbe9f9c) ) @@ -478,6 +488,13 @@ CONS( 2019, anpanm19, 0, 0, gpl32612, gpl32612, generalplus_g // unknown (uses a glob) has GPspispi header, ARM based, SPI ROM CONS( 201?, smatomo, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Smatomo (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// unknown (uses a glob) has GPspispi header, ARM based, SPI ROM +CONS( 2014, bandplap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney Princess 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) + +// unknown (uses a glob) has GPspispi header, ARM based, SPI ROM +CONS( 2014, bandslap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) + + // company is called 深圳市飞讯互动科技有限公司 // very generic packaging, boots from SPI, has game data on SD card (mostly NES games) CONS( 202?, intrtvg, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Shen Zhen Shi Fei Xun Hu Dong Technology", "Interactive Game Console (Model B608, YRPRSODF)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From b5a6ea318ad2cef7744b184a8d93b5a181f2a9fa Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 22:25:52 +0100 Subject: [PATCH 08/53] added dinopc --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index fba87ee723f7a..6e2db6bce29a8 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47080,6 +47080,7 @@ ardancem bandplap bandslap chiikpc +dinopc dmnslayg intrtvg jak_swbstrik diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 05debb10cbd77..7b0370118d207 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -408,7 +408,13 @@ ROM_START( sumikpc ) ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, CRC(3187a2cc) SHA1(166719b0cd45d7d6b5523ed528b64afac2fb58b7) ) ROM_END +ROM_START( dinopc ) + ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + ROM_REGION( 0x11000000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "tc58nbg1s3hta00.nfrom1", 0x0000, 0x11000000, CRC(c7ec0903) SHA1(c33a723a7967043a6560a002a33cdb33d0c1f207) ) +ROM_END @@ -550,6 +556,9 @@ CONS( 2020, saikyopc, 0, 0, gpl32612, gpl32612, generalplu // マウスできせかえ! すみっコぐらしパソコンプラス CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi PC Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // from a unit with purple top +// uses GPL32600A +CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) + // ディズニー&ディズニー/ピクサーキャラクターズ できた!がいっぱい ドリームトイパッド CONS( 2020, tmydistb, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Tomy", "Disney & Disney/Pixar Characters Dekita! ga Ippai Dream Toy Pad (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From e54721109539552ee6693b5723b9bc447cf56465 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 23:20:11 +0100 Subject: [PATCH 09/53] add Mouse de Kisekae! Sumikko Gurashi PC (Japan) --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 6e2db6bce29a8..92c51a6b5fb26 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47099,6 +47099,7 @@ rotom2 saikyopc smatomo sumikpc +sumikpcp tamameet tmydistb zippity diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 7b0370118d207..f36cf2c984ae8 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -399,15 +399,24 @@ ROM_START( neopad ) ROM_LOAD( "tc58nvg0s3hta00.u2", 0x0000, 0x8800000, CRC(3b8f8c48) SHA1(1995d443c1ce8e44c9256c994e1f91eb5857b80c) ) ROM_END - ROM_START( sumikpc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, CRC(87aac4dd) SHA1(81991e5904adf0dacb489f2477507e7797146bc8) ) +ROM_END + +ROM_START( sumikpcp ) + ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, CRC(3187a2cc) SHA1(166719b0cd45d7d6b5523ed528b64afac2fb58b7) ) ROM_END + + ROM_START( dinopc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? @@ -554,7 +563,9 @@ CONS( 2020, saikyopc, 0, 0, gpl32612, gpl32612, generalplu // uses GPL32600A // マウスできせかえ! すみっコぐらしパソコンプラス -CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi PC Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // from a unit with purple top +CONS( 2019, sumikpcp, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi PC Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // from a unit with purple top, white base +// there are code changes between these 2 sets, but there also look to be some bits that might be incorrectly flipped on one or both of them +CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // from a unit with blue top, white base // uses GPL32600A CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From 7ee999ea2fdda387103d6cd62421c428ab8911f5 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 23:30:54 +0100 Subject: [PATCH 10/53] mark both of these as bad, as the dumps show different flipped bits in each --- src/mame/tvgames/generalplus_gpl32612.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index f36cf2c984ae8..4a5afb603032d 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -403,20 +403,19 @@ ROM_START( sumikpc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? - ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) - ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, CRC(87aac4dd) SHA1(81991e5904adf0dacb489f2477507e7797146bc8) ) + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) // clearly has some flipped bits compared to sumikpcp, but also seems to be different revision + ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, BAD_DUMP CRC(87aac4dd) SHA1(81991e5904adf0dacb489f2477507e7797146bc8) ) ROM_END ROM_START( sumikpcp ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? - ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) - ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, CRC(3187a2cc) SHA1(166719b0cd45d7d6b5523ed528b64afac2fb58b7) ) + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) // clearly has some flipped bits compared to sumikpc, but also seems to be different revision + ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, BAD_DUMP CRC(3187a2cc) SHA1(166719b0cd45d7d6b5523ed528b64afac2fb58b7) ) ROM_END - ROM_START( dinopc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? From a2471833c1a04a920a9be2739774e992feda5c94 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 23:41:43 +0100 Subject: [PATCH 11/53] added Mouse de Kisekae! Sumikko Gurashi Premium Plus (Japan) --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 92c51a6b5fb26..72646cbd7b944 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47100,6 +47100,7 @@ saikyopc smatomo sumikpc sumikpcp +sumipc21 tamameet tmydistb zippity diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 4a5afb603032d..0d14c3e944fac 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -415,6 +415,13 @@ ROM_START( sumikpcp ) ROM_LOAD( "tc58nvg0s3hta00.nfrom1", 0x0000, 0x8800000, BAD_DUMP CRC(3187a2cc) SHA1(166719b0cd45d7d6b5523ed528b64afac2fb58b7) ) ROM_END +ROM_START( sumipc21 ) + ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + + ROM_REGION( 0x8800000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "tc58nvg0s3hta00.nfrom201", 0x0000, 0x8800000, CRC(be124e78) SHA1(088d94a9cb5d028c73643b35f613dccbece1a6ca) ) +ROM_END ROM_START( dinopc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) @@ -566,6 +573,10 @@ CONS( 2019, sumikpcp, 0, 0, gpl32612, gpl32612, generalpl // there are code changes between these 2 sets, but there also look to be some bits that might be incorrectly flipped on one or both of them CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // from a unit with blue top, white base +// uses a glob +CONS( 2021, sumipc21, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi Premium Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // white top, blue base + + // uses GPL32600A CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From 2292bd867c18fd3f1358064d847472edca4bf65b Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 15 Oct 2025 23:55:42 +0100 Subject: [PATCH 12/53] another set --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 72646cbd7b944..b7b9811740375 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47097,6 +47097,7 @@ pocketmr pokepeac rotom2 saikyopc +segdis16 smatomo sumikpc sumikpcp diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 0d14c3e944fac..e936cf3257f26 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -423,6 +423,18 @@ ROM_START( sumipc21 ) ROM_LOAD( "tc58nvg0s3hta00.nfrom201", 0x0000, 0x8800000, CRC(be124e78) SHA1(088d94a9cb5d028c73643b35f613dccbece1a6ca) ) ROM_END +ROM_START( segdis16 ) + ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + + ROM_REGION( 0x10800000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "mx30lf2g18ac.nfrom", 0x0000, 0x10800000, CRC(87905c80) SHA1(79081934082e163163c06dc11362d8cf4e858bcf) ) + + DISK_REGION( "sdcard" ) // 8GB SD Card (might just be user data) + DISK_IMAGE( "segdis16", 0, SHA1(63cf1290c8ed78355b96b4e23885d11d7e2bd25d) ) +ROM_END + + ROM_START( dinopc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? @@ -576,6 +588,10 @@ CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalpl // uses a glob CONS( 2021, sumipc21, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi Premium Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // white top, blue base +// uses GPL32611 +CONS( 2016, segdis16, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Disney PC 2016 (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // white top, blue base + + // uses GPL32600A CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From 2ee4bce4ad007b05fa102fe5f8626e4902f45e38 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 00:24:14 +0100 Subject: [PATCH 13/53] I think this was this instead --- src/mame/tvgames/generalplus_gpl32612.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index e936cf3257f26..c0dd8b12672c4 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -589,9 +589,8 @@ CONS( 2019, sumikpc, 0, 0, gpl32612, gpl32612, generalpl CONS( 2021, sumipc21, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Kisekae! Sumikko Gurashi Premium Plus (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // white top, blue base // uses GPL32611 -CONS( 2016, segdis16, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Disney PC 2016 (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // white top, blue base - - +// ディズニーキャラクターズ マジカルパッド ~ガールズレッスン~ +CONS( 2016, segdis16, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Disney Characters Magical Pad -Girls Lesson- (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // uses GPL32600A CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From 392d4dd7f62e87128f475a17d66178d4eb30da6c Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 01:16:24 +0100 Subject: [PATCH 14/53] one more --- src/mame/mame.lst | 1 + src/mame/sega/megadriv_firecore.cpp | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index b7b9811740375..23a6707efcddf 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -40588,6 +40588,7 @@ mympac mympaca mypac mypaca +mysf2 mysinv reactmd sarc110 diff --git a/src/mame/sega/megadriv_firecore.cpp b/src/mame/sega/megadriv_firecore.cpp index ea39861b528ad..a735ce01617c4 100644 --- a/src/mame/sega/megadriv_firecore.cpp +++ b/src/mame/sega/megadriv_firecore.cpp @@ -254,6 +254,10 @@ ROM_START( mysinv ) ROM_IGNORE(0x100) ROM_END +ROM_START( mysf2 ) + ROM_REGION( 0x1000000, "maincpu", 0 ) + ROM_LOAD16_WORD_SWAP( "s29gl128.u2", 0x000000, 0x1000000, CRC(7938a212) SHA1(306cffd048fb271fa26cd2f61cbd2c3a94116292) ) +ROM_END /* @@ -430,7 +434,7 @@ void megadriv_firecore_state::init_dcat() void megadriv_firecore_state::init_mdhh100() { m_romsize = memregion("maincpu")->bytes(); - m_externalbank = 0x7800000; + m_externalbank = m_romsize-0x800000; init_megadriv(); } @@ -462,6 +466,8 @@ CONS( 2021, mygalaga, mygalag, 0, megadriv_firecore_3button_ntsc, mympac, meg CONS( 2021, mysinv, 0, 0, megadriv_firecore_3button_ntsc, mympac, megadriv_firecore_state, init_megadriv, "dreamGEAR", "My Arcade Space Invaders (DGUNL-7006, Pocket Player Pro)", MACHINE_NOT_WORKING | ROT90 ) +CONS( 2021, mysf2, 0, 0, megadriv_firecore_6button_ntsc, msi_6button, megadriv_firecore_state, init_mdhh100, "dreamGEAR", "My Arcade Street Fighter II (DGUNL-4184, Nano Player Pro)", MACHINE_NOT_WORKING ) + CONS( 2012, atgame40, 0, 0, megadriv_firecore_3button_pal, firecore_3button, megadriv_firecore_state, init_atgame40, "AtGames", "40 Bonus Games in 1 (AtGames)", MACHINE_NOT_WORKING) CONS( 2021, matet, 0, 0, megadriv_firecore_3button_ntsc, firecore_3button, megadriv_firecore_state, init_megadriv, "dreamGEAR", "My Arcade Tetris (DGUNL-7028, Pocket Player Pro)", MACHINE_NOT_WORKING) From 7164d025e6a7e2fa41fbbecd6fa86bd5f8a25561 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 14:36:47 +0100 Subject: [PATCH 15/53] this is an L, not a 1 --- src/mame/tvgames/generalplus_gpl32612.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index c0dd8b12672c4..936d40dd1596b 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -567,7 +567,7 @@ CONS( 200?, arcadege, 0, 0, gpl32612, gpl32612, generalplu // 学習おうえんAI★ミラクルロボ CONS( 2020, airobo, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init840, "Benesse Corporation", "Gakushuu Ouen AI Miracle Robo", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -// uses GPE13101A +// uses GPEL3101A // たまごっち みーつ (there appear to be many units in this series, ROM data could differ, this was from a light blue 'hearts and rainbows' themed unit with no subtitles) CONS( 2018, tamameet, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Tamagotchi Meets (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From acaefd7a509b590c5a884d8b32f2f20c4694cf15 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 17:00:04 +0100 Subject: [PATCH 16/53] note about what SoC probably is here --- src/mame/tvgames/generalplus_gpl_unknown.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mame/tvgames/generalplus_gpl_unknown.cpp b/src/mame/tvgames/generalplus_gpl_unknown.cpp index 3dbbc581cfde4..3a1dc5f999c69 100644 --- a/src/mame/tvgames/generalplus_gpl_unknown.cpp +++ b/src/mame/tvgames/generalplus_gpl_unknown.cpp @@ -1,6 +1,8 @@ // license:BSD-3-Clause // copyright-holders:David Haywood +// seems to be a GPCE4 series SunPlus CPU, GPCE4064A is a close match + /* NOTES: From 8a1c34c6232b5978ff061052406d8090fbefa644 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 17:14:53 +0100 Subject: [PATCH 17/53] update comment --- src/mame/tvgames/generalplus_gpl_unknown.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mame/tvgames/generalplus_gpl_unknown.cpp b/src/mame/tvgames/generalplus_gpl_unknown.cpp index 3a1dc5f999c69..4dc135e0e612f 100644 --- a/src/mame/tvgames/generalplus_gpl_unknown.cpp +++ b/src/mame/tvgames/generalplus_gpl_unknown.cpp @@ -1,7 +1,9 @@ // license:BSD-3-Clause // copyright-holders:David Haywood -// seems to be a GPCE4 series SunPlus CPU, GPCE4064A is a close match +// seems to be a GPCExxx series SunPlus CPU +// GPCE200A seems very likely for the Super Impulse titles +// but GPCE4064A is a close match /* NOTES: From c06e7dd78e4b41f723b95d27fd9dcdf661d70478 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 21:39:24 +0100 Subject: [PATCH 18/53] move tamameet out of gpl32612.cpp and into a gpel31xx file, as this chip is unrelated to the gpl326xx series --- src/mame/handheld/generalplus_gpel31xx.cpp | 84 ++++++++++++++++++++ src/mame/mame.lst | 4 +- src/mame/tvgames/generalplus_gpl32612.cpp | 9 --- src/mame/tvgames/generalplus_gpl_unknown.cpp | 4 +- 4 files changed, 89 insertions(+), 12 deletions(-) create mode 100644 src/mame/handheld/generalplus_gpel31xx.cpp diff --git a/src/mame/handheld/generalplus_gpel31xx.cpp b/src/mame/handheld/generalplus_gpel31xx.cpp new file mode 100644 index 0000000000000..861b25b88899d --- /dev/null +++ b/src/mame/handheld/generalplus_gpel31xx.cpp @@ -0,0 +1,84 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood + +// GPEL31xx chips can have OTP ROM + +#include "emu.h" + +#include "cpu/arm7/arm7.h" + +#include "screen.h" +#include "speaker.h" + +namespace { + +class generalplus_gpel31xx_game_state : public driver_device +{ +public: + generalplus_gpel31xx_game_state(const machine_config &mconfig, device_type type, const char *tag) : + driver_device(mconfig, type, tag), + m_maincpu(*this, "maincpu"), + m_screen(*this, "screen") + { } + + void gpel31xx(machine_config &config) ATTR_COLD; + +protected: + virtual void machine_start() override ATTR_COLD; + virtual void machine_reset() override ATTR_COLD; + + void arm_map(address_map &map) ATTR_COLD; + + required_device m_maincpu; + required_device m_screen; + + uint32_t screen_update_gpel31xx(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + +private: +}; + +uint32_t generalplus_gpel31xx_game_state::screen_update_gpel31xx(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) +{ + return 0; +} + +void generalplus_gpel31xx_game_state::arm_map(address_map &map) +{ +} + +void generalplus_gpel31xx_game_state::machine_start() +{ +} + +void generalplus_gpel31xx_game_state::machine_reset() +{ +} + + +static INPUT_PORTS_START( gpel31xx ) +INPUT_PORTS_END + +void generalplus_gpel31xx_game_state::gpel31xx(machine_config &config) +{ + ARM7(config, m_maincpu, 96'000'000); + m_maincpu->set_addrmap(AS_PROGRAM, &generalplus_gpel31xx_game_state::arm_map); + + SCREEN(config, m_screen, SCREEN_TYPE_LCD); + m_screen->set_refresh_hz(60); + m_screen->set_size(320, 262); + m_screen->set_visarea(0, 320-1, 0, 240-1); + m_screen->set_screen_update(FUNC(generalplus_gpel31xx_game_state::screen_update_gpel31xx)); + + SPEAKER(config, "speaker", 2).front(); +} + +ROM_START( tamameet ) + ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) + ROM_LOAD( "25q64.u3", 0x0000, 0x800000, CRC(f15507f8) SHA1(356cb1bd68169eb747898325eacfd7590dbe9f9c) ) +ROM_END + +} // anonymous namespace + +// uses GPEL3101A +// たまごっち みーつ (there appear to be many units in this series, ROM data could differ, this was from a light blue 'hearts and rainbows' themed unit with no subtitles) +CONS( 2018, tamameet, 0, 0, gpel31xx, gpel31xx, generalplus_gpel31xx_game_state, empty_init, "Bandai", "Tamagotchi Meets (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 23a6707efcddf..0d4e97c3c8bef 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19477,6 +19477,9 @@ gameking @source:handheld/gmaster.cpp gmaster +@source:handheld/generalplus_gpel31xx.cpp +tamameet + @source:handheld/hh_cop400.cpp bshipg comparca @@ -47103,7 +47106,6 @@ smatomo sumikpc sumikpcp sumipc21 -tamameet tmydistb zippity zippityuk diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 936d40dd1596b..8b20c919be6be 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -322,11 +322,6 @@ ROM_START( bandplap ) ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(f85c388d) SHA1(59e30b51e2d6598881eb64edc027e0e27756631f) ) ROM_END -ROM_START( tamameet ) - ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) - ROM_LOAD( "25q64.u3", 0x0000, 0x800000, CRC(f15507f8) SHA1(356cb1bd68169eb747898325eacfd7590dbe9f9c) ) -ROM_END - ROM_START( chiikpc ) ROM_REGION( 0x1000000, "spi", ROMREGION_ERASE00 ) ROM_LOAD( "25l12833f.u6", 0x0000, 0x1000000, CRC(bde74209) SHA1(8a91554ae653f4ed54fd354049c32b545e4d359d) ) @@ -567,10 +562,6 @@ CONS( 200?, arcadege, 0, 0, gpl32612, gpl32612, generalplu // 学習おうえんAI★ミラクルロボ CONS( 2020, airobo, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init840, "Benesse Corporation", "Gakushuu Ouen AI Miracle Robo", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -// uses GPEL3101A -// たまごっち みーつ (there appear to be many units in this series, ROM data could differ, this was from a light blue 'hearts and rainbows' themed unit with no subtitles) -CONS( 2018, tamameet, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Tamagotchi Meets (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) - // uses a glob CPU // ちいかわラーニングパソコン CONS( 2021, chiikpc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Chiikawa Learning PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) diff --git a/src/mame/tvgames/generalplus_gpl_unknown.cpp b/src/mame/tvgames/generalplus_gpl_unknown.cpp index 4dc135e0e612f..36c7e61556f7a 100644 --- a/src/mame/tvgames/generalplus_gpl_unknown.cpp +++ b/src/mame/tvgames/generalplus_gpl_unknown.cpp @@ -2,8 +2,8 @@ // copyright-holders:David Haywood // seems to be a GPCExxx series SunPlus CPU -// GPCE200A seems very likely for the Super Impulse titles -// but GPCE4064A is a close match +// GPCE4064A seems very likely for the Super Impulse titles +// but GPCE200A is a close match /* NOTES: From 1ebe8b56f5f580c117f45bb775b267286c5a8e42 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 22:30:31 +0100 Subject: [PATCH 19/53] move a few bits based on research --- .../generalplus_gpcexxxx.cpp} | 0 src/mame/mame.lst | 16 ++++++++-------- src/mame/tvgames/generalplus_gp327902.cpp | 8 ++++---- src/mame/tvgames/generalplus_gpl32612.cpp | 5 ++++- 4 files changed, 16 insertions(+), 13 deletions(-) rename src/mame/{tvgames/generalplus_gpl_unknown.cpp => handheld/generalplus_gpcexxxx.cpp} (100%) diff --git a/src/mame/tvgames/generalplus_gpl_unknown.cpp b/src/mame/handheld/generalplus_gpcexxxx.cpp similarity index 100% rename from src/mame/tvgames/generalplus_gpl_unknown.cpp rename to src/mame/handheld/generalplus_gpcexxxx.cpp diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 0d4e97c3c8bef..9103c6a2235b4 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19477,6 +19477,14 @@ gameking @source:handheld/gmaster.cpp gmaster +@source:handheld/generalplus_gpcexxxx.cpp +mapacman +parcade +siddr +tagalaga +taspinv +taturtf + @source:handheld/generalplus_gpel31xx.cpp tamameet @@ -47110,14 +47118,6 @@ tmydistb zippity zippityuk -@source:tvgames/generalplus_gpl_unknown.cpp -mapacman -parcade -siddr -tagalaga -taspinv -taturtf - @source:tvgames/generalplus_gpm453x_nand.cpp leapland leappawp diff --git a/src/mame/tvgames/generalplus_gp327902.cpp b/src/mame/tvgames/generalplus_gp327902.cpp index 633ba10f39d28..70886c6fa2bbd 100644 --- a/src/mame/tvgames/generalplus_gp327902.cpp +++ b/src/mame/tvgames/generalplus_gp327902.cpp @@ -82,10 +82,10 @@ void generalplus_gp327902_game_state::arm_map(address_map &map) { map(0x00000000, 0x001fffff).ram(); // 16M-bit internal SDRAM - map(0xc0020070, 0xc0020073).r(FUNC(generalplus_gp327902_game_state::c0020070_unk_r)); - map(0xc0060000, 0xc0060003).w(FUNC(generalplus_gp327902_game_state::c0060000_unk_w)); - map(0xc008000c, 0xc008000f).r(FUNC(generalplus_gp327902_game_state::c008000c_unk_r)); - map(0xd000003c, 0xd000003f).r(FUNC(generalplus_gp327902_game_state::d000003c_unk_r)); + map(0xc0020070, 0xc0020073).r(FUNC(generalplus_gp327902_game_state::c0020070_unk_r)); // P_TIMERD_UPCOUNT + map(0xc0060000, 0xc0060003).w(FUNC(generalplus_gp327902_game_state::c0060000_unk_w)); // P_UART_DATA + map(0xc008000c, 0xc008000f).r(FUNC(generalplus_gp327902_game_state::c008000c_unk_r)); // P_SPI_RX_STATUS + map(0xd000003c, 0xd000003f).r(FUNC(generalplus_gp327902_game_state::d000003c_unk_r)); // P_SYSTEM_POWER_STATE map(0xf8000000, 0xf80003ff).ram(); // writes pointers used by exceptions (including IRQs) here } diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 8b20c919be6be..c4e9cef747b04 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -505,9 +505,11 @@ CONS( 2013, kidizmp, 0, 0, gpl32612, gpl32612, generalplus_g // seems to be older tech, just glob + ROM, assuming it's a GP32 series based on above and due to having ARM code CONS( 201?, kidizmb, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "VTech", "Kidizoom (Germany, blue camera)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// uses GPL32610 CONS( 2019, pocketmp, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init880, "Takara Tomy", "Pocket Monsters PC", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // ポケモン図鑑 スマホロトム +// uses a glob CONS( 2019, pocketmr, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init880, "Takara Tomy", "Pokemon Zukan - Sumaho Rotom (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // uses GPL32610 - 「それいけ!アンパンマン」スポーツ育脳マット @@ -524,6 +526,7 @@ CONS( 2014, bandslap, 0, 0, gpl32612, gpl32612, generalplus_g // company is called 深圳市飞讯互动科技有限公司 +// surface details erased on SoC for both of these // very generic packaging, boots from SPI, has game data on SD card (mostly NES games) CONS( 202?, intrtvg, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Shen Zhen Shi Fei Xun Hu Dong Technology", "Interactive Game Console (Model B608, YRPRSODF)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // also very generic packaging, similar SD card content to above, including NES games, but with some extra music/videos for the dance part @@ -549,7 +552,7 @@ MD481P (could be a rebranded GPL32 series, ROM has GPNand header) there is also a -GPY0201A +GPY0201A "Power management ASIC" */ From dc954a68b503c3141c08b0994aa3b133d6af68cb Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 23:40:06 +0100 Subject: [PATCH 20/53] this seems to be the correct CPU type --- ...lus_gpcexxxx.cpp => generalplus_gpce4.cpp} | 142 +++++++++++++----- src/mame/mame.lst | 2 +- 2 files changed, 107 insertions(+), 37 deletions(-) rename src/mame/handheld/{generalplus_gpcexxxx.cpp => generalplus_gpce4.cpp} (88%) diff --git a/src/mame/handheld/generalplus_gpcexxxx.cpp b/src/mame/handheld/generalplus_gpce4.cpp similarity index 88% rename from src/mame/handheld/generalplus_gpcexxxx.cpp rename to src/mame/handheld/generalplus_gpce4.cpp index 36c7e61556f7a..5601c82096904 100644 --- a/src/mame/handheld/generalplus_gpcexxxx.cpp +++ b/src/mame/handheld/generalplus_gpce4.cpp @@ -472,42 +472,112 @@ void generalplus_gpl_unknown_state::map(address_map &map) map(0x000000, 0x000fff).ram(); // RAM //map(0x001000, 0x0017ff).ram(); // acts like open bus? - //map(0x003000, 0x003fff).ram(); // system regs - map(0x003001, 0x003001).rw(FUNC(generalplus_gpl_unknown_state::reg3001_r), FUNC(generalplus_gpl_unknown_state::reg3001_w)); - map(0x003002, 0x003002).rw(FUNC(generalplus_gpl_unknown_state::reg3002_r), FUNC(generalplus_gpl_unknown_state::reg3002_w)); - map(0x003003, 0x003003).rw(FUNC(generalplus_gpl_unknown_state::reg3003_r), FUNC(generalplus_gpl_unknown_state::reg3003_w)); - map(0x003004, 0x003004).r(FUNC(generalplus_gpl_unknown_state::reg3004_r)); // input from here is acted upon - map(0x003005, 0x003005).rw(FUNC(generalplus_gpl_unknown_state::reg3005_r), FUNC(generalplus_gpl_unknown_state::reg3005_w)); - map(0x003006, 0x003006).r(FUNC(generalplus_gpl_unknown_state::reg3006_r)); - map(0x003007, 0x003007).r(FUNC(generalplus_gpl_unknown_state::reg3007_r)); - - map(0x00300f, 0x00300f).r(FUNC(generalplus_gpl_unknown_state::reg300f_r)); - - map(0x003016, 0x003016).r(FUNC(generalplus_gpl_unknown_state::reg3016_r)); - - map(0x003034, 0x003034).w(FUNC(generalplus_gpl_unknown_state::reg3034_w)); - - map(0x003041, 0x003041).w(FUNC(generalplus_gpl_unknown_state::reg3041_audiodac_w)); - - map(0x003050, 0x003050).rw(FUNC(generalplus_gpl_unknown_state::reg3050_r), FUNC(generalplus_gpl_unknown_state::reg3050_w)); - map(0x003051, 0x003051).w(FUNC(generalplus_gpl_unknown_state::reg3051_w)); - map(0x003052, 0x003052).r(FUNC(generalplus_gpl_unknown_state::reg3052_r)); - map(0x003053, 0x003053).r(FUNC(generalplus_gpl_unknown_state::reg3053_r)); - - map(0x003090, 0x003090).r(FUNC(generalplus_gpl_unknown_state::reg3090_r)); - map(0x003091, 0x003091).r(FUNC(generalplus_gpl_unknown_state::reg3091_r)); - map(0x003092, 0x003092).w(FUNC(generalplus_gpl_unknown_state::reg3092_lcd_w)); - map(0x003094, 0x003094).r(FUNC(generalplus_gpl_unknown_state::reg3094_r)); // potential interesting - map(0x003095, 0x003095).r(FUNC(generalplus_gpl_unknown_state::reg3095_r)); // mostly a status flag - - map(0x0030e0, 0x0030e0).w(FUNC(generalplus_gpl_unknown_state::reg30e0_w)); - map(0x0030e1, 0x0030e1).w(FUNC(generalplus_gpl_unknown_state::reg30e1_w)); - map(0x0030e2, 0x0030e2).w(FUNC(generalplus_gpl_unknown_state::reg30e2_w)); - map(0x0030e3, 0x0030e3).w(FUNC(generalplus_gpl_unknown_state::reg30e3_w)); - map(0x0030e4, 0x0030e4).r(FUNC(generalplus_gpl_unknown_state::reg30e4_r)); // potentially interesting (must not return 0x0000 or 'flash error') - map(0x0030e5, 0x0030e5).r(FUNC(generalplus_gpl_unknown_state::reg30e5_r)); // potentially interesting (also status flag) - - map(0x004000, 0x00bfff).rom().region("maincpu", 0x0000); + // 3000 - IOA_Data + map(0x003001, 0x003001).rw(FUNC(generalplus_gpl_unknown_state::reg3001_r), FUNC(generalplus_gpl_unknown_state::reg3001_w)); // IOA_Buffer + map(0x003002, 0x003002).rw(FUNC(generalplus_gpl_unknown_state::reg3002_r), FUNC(generalplus_gpl_unknown_state::reg3002_w)); // IOA_Dir + map(0x003003, 0x003003).rw(FUNC(generalplus_gpl_unknown_state::reg3003_r), FUNC(generalplus_gpl_unknown_state::reg3003_w)); // IOA_Attrib + map(0x003004, 0x003004).r(FUNC(generalplus_gpl_unknown_state::reg3004_r)); // IOB_Data - input from here is acted upon + map(0x003005, 0x003005).rw(FUNC(generalplus_gpl_unknown_state::reg3005_r), FUNC(generalplus_gpl_unknown_state::reg3005_w)); // IOB_Buffer + map(0x003006, 0x003006).r(FUNC(generalplus_gpl_unknown_state::reg3006_r)); // IOB_Dir + map(0x003007, 0x003007).r(FUNC(generalplus_gpl_unknown_state::reg3007_r)); // IOB_Attrib + // 3008 - IOC_Data + // 3009 - IOC_Buffer + // 300a - IOC_Dir + // 300b - IOC_Attrib + // 300c - IOA_WakeUp_Mask + // 300d - IOB_WakeUp_Mask + // 300e - IOC_WakeUp_Mask + map(0x00300f, 0x00300f).r(FUNC(generalplus_gpl_unknown_state::reg300f_r)); // IO_Ctrl + + // 3010 - TimerA_Data + // 3011 - TimerA_CNTR + // 3012 - TimerB_Data + // 3013 - TimerB_CNTR + // 3014 - TimerC_Data + // 3015 - TimerC_CNTR + map(0x003016, 0x003016).r(FUNC(generalplus_gpl_unknown_state::reg3016_r)); // 3016 - Timer_Ctrl + + // 3020 - PWM0_Ctrl + // 3021 - PWM1_Ctrl + // 3022 - PWM2_Ctrl + // 3023 - PWM3_Ctrl + + // 3030 - System_Clock + // 3031 - System_Reset + // 3032 - Reset_LVD_Ctrl + // 3033 - Timebase_Clear + map(0x003034, 0x003034).w(FUNC(generalplus_gpl_unknown_state::reg3034_w)); // Watchdog_Clear + // 3035 - Wait_Ctrl + // 3036 - System_Sleep + + // 3039 - Cache_Ctrl + // 303a - Cache_Hit_Rate + // 303b - Stack_INT_Level + + // 3040 - DAC_Ctrl + map(0x003041, 0x003041).w(FUNC(generalplus_gpl_unknown_state::reg3041_audiodac_w)); // DAC_CH1_Data + // 3042 - DAC_CH2_Data + // 3043 - PPAMCtrl + + map(0x003050, 0x003050).rw(FUNC(generalplus_gpl_unknown_state::reg3050_r), FUNC(generalplus_gpl_unknown_state::reg3050_w)); // INT_Ctrl + map(0x003051, 0x003051).w(FUNC(generalplus_gpl_unknown_state::reg3051_w)); // INT_Status + map(0x003052, 0x003052).r(FUNC(generalplus_gpl_unknown_state::reg3052_r)); // FIQ_SEL + map(0x003053, 0x003053).r(FUNC(generalplus_gpl_unknown_state::reg3053_r)); // INT2_Ctrl + // 3054 - INT2_Status + // 3055 - FIQ2_SEL + + // 3070 - ADC_Ctrl + // 3071 - ADC_Data + // 3072 - ADC_LineIn_BitCtrl + // 3073 - ADC_PGA_Ctrl + // 3074 - ADC_FIFO_Ctrl + + map(0x003090, 0x003090).r(FUNC(generalplus_gpl_unknown_state::reg3090_r)); // SPI2_Ctrl + map(0x003091, 0x003091).r(FUNC(generalplus_gpl_unknown_state::reg3091_r)); // SPI2_TXStatus + map(0x003092, 0x003092).w(FUNC(generalplus_gpl_unknown_state::reg3092_lcd_w)); // SPI2_TXData + // 3093 - SPI2_RXStatus + map(0x003094, 0x003094).r(FUNC(generalplus_gpl_unknown_state::reg3094_r)); // SPI2_RXData - potential interesting + map(0x003095, 0x003095).r(FUNC(generalplus_gpl_unknown_state::reg3095_r)); // SPI2_Misc - mostly a status flag + + // 309a - SPI2_DMA_Start + // 309b - SPI2_DMA_BC + // 309c - SPI2_RX_DMA_ADDR + // 309d - SPI2_TX_DMA_ADDR + // 309e - SPI2_DMA_INT_Ctrl + // 309f - SPI2_RX_ICE + + // 30b0 - BUF_ACTIVE + // 30b1 - LINK_BUF10 + // 30b2 - LINK_BUF32 + // 30b3 - LINK_BUF54 + + // 30d0 - CTS_Ctrl0 + // 30d1 - CTS_Ctrl1 + // 30d2 - CTS_TMADATA + // 30d3 - CTS_TMACNT + // 30d4 - CTS_TMBDATA + // 30d5 - CTS_TMBCNT + // 30d6 - CTS_CAPTMB + // 30d7 - CTS_MUTCTRL + + map(0x0030e0, 0x0030e0).w(FUNC(generalplus_gpl_unknown_state::reg30e0_w)); // SPI_Ctrl + map(0x0030e1, 0x0030e1).w(FUNC(generalplus_gpl_unknown_state::reg30e1_w)); // SPI_TXStatus + map(0x0030e2, 0x0030e2).w(FUNC(generalplus_gpl_unknown_state::reg30e2_w)); // SPI_TXData + map(0x0030e3, 0x0030e3).w(FUNC(generalplus_gpl_unknown_state::reg30e3_w)); // SPI_RXStatus + map(0x0030e4, 0x0030e4).r(FUNC(generalplus_gpl_unknown_state::reg30e4_r)); // SPI_RXData - potentially interesting (must not return 0x0000 or 'flash error') + map(0x0030e5, 0x0030e5).r(FUNC(generalplus_gpl_unknown_state::reg30e5_r)); // SPI_Misc - potentially interesting (also status flag) + // 30e6 - SPI_Man_Ctrl + // 30e7 - SPI_Auto_Ctrl + // 30e8 - SPI_PRGM_BC + // 30e9 - SPI_BANK + // 30ea - SPI_DMA_Start + // 30eb - SPI_DMA_BC + // 30ec - SPI_RX_DMA_ADDR + // 30ed - SPI_TX_DMA_ADDR + // 30ee - SPI_DMA_INT_Ctrl + // 30ef - SPI_RX_ICE + + map(0x004000, 0x00bfff).rom().region("maincpu", 0x0000); // 0x4000 - 0x47ff is 'test program' map(0x00c000, 0x00ffff).rom().region("maincpu", 0x0000); map(0x200000, 0x3fffff).rom().region("spi", 0x0000); // has direct access to SPI ROM diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 9103c6a2235b4..d631244830b62 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19477,7 +19477,7 @@ gameking @source:handheld/gmaster.cpp gmaster -@source:handheld/generalplus_gpcexxxx.cpp +@source:handheld/generalplus_gpce4.cpp mapacman parcade siddr From 1d32fa49c461fe3bd97ac93749b7bd1ba882e28b Mon Sep 17 00:00:00 2001 From: David Haywood Date: Thu, 16 Oct 2025 23:57:03 +0100 Subject: [PATCH 21/53] more notes --- src/mame/handheld/generalplus_gpce4.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/mame/handheld/generalplus_gpce4.cpp b/src/mame/handheld/generalplus_gpce4.cpp index 5601c82096904..4d98d4fac5394 100644 --- a/src/mame/handheld/generalplus_gpce4.cpp +++ b/src/mame/handheld/generalplus_gpce4.cpp @@ -2,8 +2,10 @@ // copyright-holders:David Haywood // seems to be a GPCExxx series SunPlus CPU -// GPCE4064A seems very likely for the Super Impulse titles -// but GPCE200A is a close match +// GPCE4064 series seems very likely for the Super Impulse titles +// +// GPCE4P064B is an OTP part with support for 30Kbyte OTP ROM (+2Kbyte 'test' area) which matches mapacman +// it also lacks Port C, which appears to be unused here /* NOTES: @@ -470,7 +472,7 @@ uint16_t generalplus_gpl_unknown_state::reg3095_r(offs_t offset) void generalplus_gpl_unknown_state::map(address_map &map) { map(0x000000, 0x000fff).ram(); // RAM - //map(0x001000, 0x0017ff).ram(); // acts like open bus? + //map(0x001000, 0x0017ff).ram(); // Cache area, can be configured as RAM instead // 3000 - IOA_Data map(0x003001, 0x003001).rw(FUNC(generalplus_gpl_unknown_state::reg3001_r), FUNC(generalplus_gpl_unknown_state::reg3001_w)); // IOA_Buffer @@ -632,7 +634,7 @@ TIMER_DEVICE_CALLBACK_MEMBER( generalplus_gpl_unknown_state::timer3 ) void generalplus_gpl_unknown_state::generalplus_gpl_unknown(machine_config &config) { - UNSP_20(config, m_maincpu, 96000000); // internal ROM uses unsp2.0 opcodes, unknown clock + UNSP_20(config, m_maincpu, 96000000); // internal ROM uses unsp2.0 opcodes, should be 48MHz but glitches (due to timer hookups?) m_maincpu->set_addrmap(AS_PROGRAM, &generalplus_gpl_unknown_state::map); m_maincpu->set_vectorbase(0x4010); // there is also a set of vectors for what looks to be a burn-in test at 4000, maybe external pin selects? From 66c8e2395271b2b67eec7123aead0bf7d9d35d6a Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 01:23:31 +0100 Subject: [PATCH 22/53] further SoC documentation work to help identify where new sets belong etc. --- .../machine/generalplus_gpl16250soc.cpp | 352 ++++++++++++++++-- src/devices/machine/generalplus_gpl16250soc.h | 10 +- src/mame/mame.lst | 2 +- ...pi_direct.cpp => generalplus_gpl951xx.cpp} | 2 +- 4 files changed, 322 insertions(+), 44 deletions(-) rename src/mame/tvgames/{generalplus_gpl16250_spi_direct.cpp => generalplus_gpl951xx.cpp} (99%) diff --git a/src/devices/machine/generalplus_gpl16250soc.cpp b/src/devices/machine/generalplus_gpl16250soc.cpp index fc62bb544754b..7db78e2799abe 100644 --- a/src/devices/machine/generalplus_gpl16250soc.cpp +++ b/src/devices/machine/generalplus_gpl16250soc.cpp @@ -75,27 +75,27 @@ generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &m } -void generalplus_gpspi_direct_device::ramwrite_w(offs_t offset, uint16_t data) +void generalplus_gpl951xx_device::ramwrite_w(offs_t offset, uint16_t data) { m_mainram[offset] = data; } -uint16_t generalplus_gpspi_direct_device::ramread_r(offs_t offset) +uint16_t generalplus_gpl951xx_device::ramread_r(offs_t offset) { return m_mainram[offset]; } -uint16_t generalplus_gpspi_direct_device::spi_direct_7b40_r() +uint16_t generalplus_gpl951xx_device::spi_direct_7b40_r() { return 0xffff; // doesn't care for now } -uint16_t generalplus_gpspi_direct_device::spi_direct_79f5_r() +uint16_t generalplus_gpl951xx_device::spi_direct_79f5_r() { return 0xffff; // hangs if returning 0 } -uint16_t generalplus_gpspi_direct_device::spi_direct_7b46_r() +uint16_t generalplus_gpl951xx_device::spi_direct_7b46_r() { int i = machine().rand(); @@ -103,19 +103,19 @@ uint16_t generalplus_gpspi_direct_device::spi_direct_7b46_r() else return 0x02; } -uint16_t generalplus_gpspi_direct_device::spi_direct_79f4_r() +uint16_t generalplus_gpl951xx_device::spi_direct_79f4_r() { // status bits? return machine().rand(); } -uint16_t generalplus_gpspi_direct_device::spi_direct_7af0_r() +uint16_t generalplus_gpl951xx_device::spi_direct_7af0_r() { return m_7af0; } -void generalplus_gpspi_direct_device::spi_direct_7af0_w(uint16_t data) +void generalplus_gpl951xx_device::spi_direct_7af0_w(uint16_t data) { // words read from ROM are written here during the checksum routine in RAM, and must // be shifted for the checksum to pass. @@ -123,64 +123,342 @@ void generalplus_gpspi_direct_device::spi_direct_7af0_w(uint16_t data) } -uint16_t generalplus_gpspi_direct_device::spi_direct_78e8_r() +uint16_t generalplus_gpl951xx_device::spi_direct_78e8_r() { return machine().rand(); } -void generalplus_gpspi_direct_device::device_start() +void generalplus_gpl951xx_device::device_start() { sunplus_gcm394_base_device::device_start(); save_item(NAME(m_7af0)); } -void generalplus_gpspi_direct_device::device_reset() +void generalplus_gpl951xx_device::device_reset() { sunplus_gcm394_base_device::device_reset(); m_7af0 = 0; } -void generalplus_gpspi_direct_device::spi_direct_78e8_w(uint16_t data) +void generalplus_gpl951xx_device::spi_direct_78e8_w(uint16_t data) { logerror("%s: spi_direct_78e8_w %04x\n", machine().describe_context(), data); } -void generalplus_gpspi_direct_device::gpspi_direct_internal_map(address_map& map) +void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) { sunplus_gcm394_base_device::base_internal_map(map); - map(0x000000, 0x0027ff).rw(FUNC(generalplus_gpspi_direct_device::ramread_r), FUNC(generalplus_gpspi_direct_device::ramwrite_w)); + map(0x000000, 0x0027ff).rw(FUNC(generalplus_gpl951xx_device::ramread_r), FUNC(generalplus_gpl951xx_device::ramwrite_w)); // TODO: RAM is only 0x2800 on this, like earlier SPG2xx models? unmap the extra from the base_internal_map? - map(0x00780b, 0x00780b).nopw(); - - map(0x0078e8, 0x0078e8).rw(FUNC(generalplus_gpspi_direct_device::spi_direct_78e8_r), FUNC(generalplus_gpspi_direct_device::spi_direct_78e8_w)); - - map(0x0079f4, 0x0079f4).r(FUNC(generalplus_gpspi_direct_device::spi_direct_79f4_r)); - map(0x0079f5, 0x0079f5).r(FUNC(generalplus_gpspi_direct_device::spi_direct_79f5_r)); - - map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpspi_direct_device::spi_direct_7af0_r), FUNC(generalplus_gpspi_direct_device::spi_direct_7af0_w)); - - map(0x007b40, 0x007b40).r(FUNC(generalplus_gpspi_direct_device::spi_direct_7b40_r)); -// map(0x007b46, 0x007b46).r(FUNC(generalplus_gpspi_direct_device::spi_direct_7b46_r)); - map(0x007b40, 0x007b40).nopw(); - map(0x007b41, 0x007b41).nopw(); - map(0x007b42, 0x007b42).nopw(); - - map(0x007b46, 0x007b46).ram(); // values must be written and read from here, but is there any transformation? - map(0x007b47, 0x007b47).nopw(); - map(0x007b48, 0x007b48).nopw(); - - map(0x007b49, 0x007b49).ram(); + // 7800 - BodyID + // 7801 - unused + // 7802 - PwrKey_State + // 7803 - SYS_CTRL + // 7804 - CLK_Ctrl0 + // 7805 - CLK_Ctrl1 + // 7806 - Reset_Flag + // 7807 - Clock_Ctrl + // 7808 - LVR_Ctrl + // 7809 - PM_Ctrl + // 780a - Watchdog_Ctrl + map(0x00780b, 0x00780b).nopw(); // Watchdog_Clear + // 780c - WAIT + // 780d - HALT + // 780e - unused + // 780f - Power_State + // 7810 - BankSwitch + // 7811 - unused + // 7812 - unused + // 7813 - unused + // 7814 - unused + // 7815 - unused + // 7816 - unused + // 7817 - PLL_Sel + // 7818 - PLLWaitCLK + // 7819 - Cache_Ctrl + // 781a - Cache_HitRate + // 781b - unused + // 781c - unused + // 781d - unused + // 781e - unused + // 781f - SYS_Misc + + // 7825 - Unexpect_Flag + + // 7830 - CHECKSUM0_LB + // 7831 - CHECKSUM1_LB + // 7832 - CHECKSUM0_HB + // 7833 - CHECKSUM1_HB + // + // 7848 - ECC_LPRL_HB + // 7849 - ECC_LPRH_HB + // 784a - ECC_CPR_HB + // 784b - ECC_LPR_CKL_HB + // 784c - ECC_LPR_CKH_HB + // 784d - ECC_CPCKR_HB + // 784e - ECC_ERR0_HB + // 784f - ECC_ERR1_HB + + // 7850 - NF_Ctrl + // 7851 - NF_CMD + // 7852 - NF_AddrL + // 7853 - NF_AddrH + // 7854 - NF_Data + // 7855 - NF_INT_Ctrl + // 7856 - unused or BCH_Control + // 7857 - ECC_Ctrl + // 7858 - ECC_LPRL_LB or BCH_Error + // 7859 - ECC_LPRH_LB or BCH_Parity0 + // 785a - ECC_CPR_LB or BCH_Parity1 + // 785b - ECC_LPR_CKL_LB or BCH_Parity2 + // 785c - ECC_LPR_CKH_LB or BCH_Parity3 + // 785d - ECC_CPCKR_LB or BCH_Parity4 + // 785e - ECC_ERR0_LB or BCH_Parity5 + // 785f - ECC_ERR1_LB or BCH_Parity6 + + // 7860 - IOA_Data + // 7861 - IOA_Buffer + // 7862 - IOA_Dir + // 7863 - IOA_Attrib + // 7864 - IOA_Drv + // 7865 - IOA_Mux + // 7866 - IOA_Latch + // 7867 - IOA_KeyEN + + // 7868 - IOB_Data + // 7869 - IOB_Buffer + // 786a - IOB_Dir + // 786b - IOB_Attrib + // 786c - IOB_Drv + // 786d - IOB_Mux + // 786e - IOB_Latch + // 786f - IOB_KeyEN + + // 7870 - IOC_Data + // 7871 - IOC_Buffer + // 7872 - IOC_Dir + // 7873 - IOC_Attrib + // 7874 - IOC_Drv + // 7875 - IOC_Mux + // 7876 - IOC_Latch + // 7877 - IOC_KeyEN + + // 7878 - IOD_Data + // 7879 - IOD_Buffer + // 787a - IOD_Dir + // 787b - IOD_Attrib + // 787c - IOD_Drv + // 787d - IOD_Mux + + // 7880 - IOE_Data + // 7881 - IOE_Buffer + // 7882 - IOE_Dir + // 7883 - IOE_Attrib + // 7884 - IOE_Drv + // 7885 - IOE_Mux + // 7886 - IOE_Latch + // 7877 - IOE_KeyEN + + // 7888 - IOF_Data + // 7889 - IOF_Buffer + // 788a - IOF_Dir + // 788b - IOF_Attrib + // 788c - IOF_Drv + // 788d - IOF_Mux + // 788e - IOF_Latch + // 788f - IOF_KeyEN + + // 78a0 - INT_Status1 + // 78a1 - INT_Status2 + // 78a2 - INT_Status3 + // 78a3 - INT_Priority1 + // 78a4 - INT_Priority2 + // 78a5 - INT_Priority3 + // 78a6 - MINT_Ctrl + // 78a7 - IOAB_KCIEN + // 78a8 - IOC_KCIEN + // 78a9 - IOE_KCIEN + // 78aa - IOF_KCIEN + // 78ab - IOAB_KCIFC + // 78ac - IOC_ KCIFC + // 78ad - IOE_ KCIFC + // 78ae - IOF_ KCIFC + + // 78b0 - TimeBaseA_Ctrl + // 78b1 - TimeBaseB_Ctrl + // 78b2 - TimeBaseC_Ctrl + + // 78b8 - TimeBase_Reset + + // 78c0 - I2C_Ctrl + // 78c1 - I2C_Status + // 78c2 - I2C_Address + // 78c3 - I2C_Data + // 78c4 - I2C_Debounce + // 78c5 - I2C_Clk + // 78c6 - I2C_MISC + + // 78e0 - TimerG_Ctrl + // 78e1 + // 78e2 - TimerG_Preload + // 78e3 + // 78e4 - TimerG_UpCount + // 78e5 + // 78e6 + // 78e7 + map(0x0078e8, 0x0078e8).rw(FUNC(generalplus_gpl951xx_device::spi_direct_78e8_r), FUNC(generalplus_gpl951xx_device::spi_direct_78e8_w)); // TimerH_Ctrl + // 78e9 + // 78ea - TimerH_Preload + // 78eb + // 78ec - TimerH_UpCount + // 78ed + // 78ee + // 78ef + + // 78f0 - CHA_Ctrl + // 78f1 - CHA_Data + // 78f2 - CHA_FIFO + // 78f3 + // 78f4 + // 78f5 + // 78f6 + // 78f7 + // 78f8 - CHB_Ctrl + // 78f9 - CHB_Data + // 78fa - CHB_FIFO + // 78fb + // 78fc + // 78fd + // 78fe + // 78ff + + // 7900 - UART_Data + // 7901 - UART_RXStatus + // 7902 - UAR_Ctrl + // 7903 - UART_BaudRate + // 7904 - UART_Status + // 7905 - UART_FIFO + // 7906 - UART_TXDelay + + // 7920 - SPI1_Ctrl + // 7921 - SPI1_TXStatus + // 7922 - SPI1_TXData + // 7923 - SPI1_RXStatus + // 7924 - SPI1_RXData + // 7925 - SPI1_Misc + + // 7940 - SPI0_Ctrl + // 7941 - SPI0_TXStatus + // 7942 - SPI0_TXData + // 7943 - SPI0_RXStatus + // 7944 - SPI0_RXData + // 7945 - SPI0_Misc + + // 79a0 - ADC_Setup + // 79a1 - MADC_Ctrl + // 79a2 - MADC_Data + // 79a3 - ASADC_Ctrl + // 79a4 - ASDAC_Data + // 79a5 + // 79a6 - ADC_LineCH_En + // 79a7 - ADC_SH_Wait + + // 79b0 - MICADC_Setup + // 79b1 - MICGAIN_Ctrl + // 79b2 + // 79b3 - ASMICADC_Ctrl + // 79b4 - ASMICDAC_Data + // 79b5 - MICAGC_UpThres + // 79b6 + // 79b7 - MICADC_SH_WAIT + // 79b8 - MICADC_DataMAX + // 79b9 - MICADC_DataMIN + // 79ba - MICADC_FLAG + // 79bb - MICADC_GAIN + // 79bc - MICAGC_Ctrl + // 79bd - MICAGC_Time + // 79be - MICAGC_Enable + // 79bf - MICAGC_Status + + // 79f0 - RTC_Ctrl + // 79f1 - RTC_Addr + // 79f2 - RTC_WriteData + // 79f3 - RTC_Request + map(0x0079f4, 0x0079f4).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f4_r)); // RTC_Ready + map(0x0079f5, 0x0079f5).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f5_r)); // RTC_ReadData + // 79f6 + // 79f7 + // 79f8 + // 79fa + // 79fb - RTC_ClkDiv + + // 7a00 - TimerA_Ctr + // 7a01 - TimerA_CCPB_Ctrl + // 7a02 - TimerA_Preload + // 7a03 - TimerA_CCPB_Reg + // 7a04 - TimerA_UpCount + + // 7a08 - TimerB_Ctrl + // 7a09 - TimerB_CCPB_Ctrl + // 7a0a - TimerB_Preload + // 7a0b - TimerB_CCPB_Reg + // 7a0c - TimerB_UpCount + + // 7a10 - TimerC_Ctrl + // 7a11 - TimerC_CCPB_Ctrl + // 7a12 - TimerC_Preload + // 7a13 - TimerC_CCPB_Reg + // 7a14 - TimerC_UpCount + + // 7a18 - TimerD_Ctrl + // 7a19 - TimerD_CCPB_Ctrl + // 7a1a - TimerD_Preload + // 7a1b - TimerD_CCPB_Reg + // 7a1c - TimerD_UpCount + + // 7a20 - TimerE_Ctrl + // 7a21 - TimerF_Ctrl + // 7a22 - TimerE_CCPB_Ctrl + // 7a23 - TimerF_CCPB_Ctrl + // 7a24 - TimerE_Preload + // 7a25 - TimerF_Preload + // 7a26 - TimerEF_CCPB4_Reg + // 7a27 - TimerEF_CCPB5_Reg + // 7a28 - TimerEF_CCPB6_Reg + // 7a29 - TimerEF_CCPB7_Reg + // 7a2a - TimerE_UpCount + // 7a2b - TimerF_UpCount + // 7a2c - TimerEF_CCPB_Se + + // 7a40 - USBD_Config + // 7a41 - USBD_Function + // 7a42 - USBD_PMR + + map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpl951xx_device::spi_direct_7af0_r), FUNC(generalplus_gpl951xx_device::spi_direct_7af0_w)); + + map(0x007b40, 0x007b40).r(FUNC(generalplus_gpl951xx_device::spi_direct_7b40_r)).nopw();; // SPIFC_Ctrl1 + map(0x007b41, 0x007b41).nopw(); // SPIFC_CMD + map(0x007b42, 0x007b42).nopw(); // SPIFC_PARA + // 7b43 - SPIFC_ADDRL + // 7b44 - SPIFC_ADDRH + // 7b45 - SPIFC_TX_Dat + map(0x007b46, 0x007b46).ram(); // SPIFC_RX_Data - values must be written and read from here, but is there any transformation? + map(0x007b47, 0x007b47).nopw(); // SPIFC_TX_BC + map(0x007b48, 0x007b48).nopw(); // SPIFC_RX_BC + map(0x007b49, 0x007b49).ram(); // SPIFC_TIMING + + // 7b4b - SPIFC_Ctrl2 map(0x009000, 0x3fffff).rom().region("spidirect", 0); } -DEFINE_DEVICE_TYPE(GP_SPI_DIRECT, generalplus_gpspi_direct_device, "gpac800spi_direct", "GeneralPlus GPL16250 (with direct SPI handling)") +DEFINE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device, "gpl951xx", "GeneralPlus GPL951xx") -generalplus_gpspi_direct_device::generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - sunplus_gcm394_base_device(mconfig, GP_SPI_DIRECT, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpspi_direct_device::gpspi_direct_internal_map), this)) +generalplus_gpl951xx_device::generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + sunplus_gcm394_base_device(mconfig, GPL951XX, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpl951xx_device::gpspi_direct_internal_map), this)) { } diff --git a/src/devices/machine/generalplus_gpl16250soc.h b/src/devices/machine/generalplus_gpl16250soc.h index 92f84c576790d..03a97bde7d259 100644 --- a/src/devices/machine/generalplus_gpl16250soc.h +++ b/src/devices/machine/generalplus_gpl16250soc.h @@ -447,12 +447,12 @@ class generalplus_gpspispi_device : public sunplus_gcm394_base_device uint16_t spi_unk_7943_r(); }; -class generalplus_gpspi_direct_device : public sunplus_gcm394_base_device +class generalplus_gpl951xx_device : public sunplus_gcm394_base_device { public: template - generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : - generalplus_gpspi_direct_device(mconfig, tag, owner, clock) + generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpl951xx_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward(screen_tag)); //m_csbase = 0x30000; @@ -460,7 +460,7 @@ class generalplus_gpspi_direct_device : public sunplus_gcm394_base_device m_csbase = 0xffffffff; } - generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); protected: void gpspi_direct_internal_map(address_map &map) ATTR_COLD; @@ -488,6 +488,6 @@ class generalplus_gpspi_direct_device : public sunplus_gcm394_base_device DECLARE_DEVICE_TYPE(GCM394, sunplus_gcm394_device) DECLARE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device) DECLARE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device) -DECLARE_DEVICE_TYPE(GP_SPI_DIRECT, generalplus_gpspi_direct_device) +DECLARE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device) #endif // MAME_MACHINE_GENERALPLUS_GPL16250SOC_H diff --git a/src/mame/mame.lst b/src/mame/mame.lst index d631244830b62..1c2a9f94dfa4f 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47058,7 +47058,7 @@ pokegac2y pokegach prailpls -@source:tvgames/generalplus_gpl16250_spi_direct.cpp +@source:tvgames/generalplus_gpl951xx.cpp fixitflx bfdigdug bfgalaga diff --git a/src/mame/tvgames/generalplus_gpl16250_spi_direct.cpp b/src/mame/tvgames/generalplus_gpl951xx.cpp similarity index 99% rename from src/mame/tvgames/generalplus_gpl16250_spi_direct.cpp rename to src/mame/tvgames/generalplus_gpl951xx.cpp index 2e119851e00d6..ba7706af94e35 100644 --- a/src/mame/tvgames/generalplus_gpl16250_spi_direct.cpp +++ b/src/mame/tvgames/generalplus_gpl951xx.cpp @@ -110,7 +110,7 @@ uint16_t generalplus_gpspi_direct_game_state::cs0_r(offs_t offset) void generalplus_gpspi_direct_game_state::generalplus_gpspi_direct(machine_config &config) { - GP_SPI_DIRECT(config, m_maincpu, 96000000/2, m_screen); + GPL951XX(config, m_maincpu, 96000000/2, m_screen); m_maincpu->porta_in().set(FUNC(generalplus_gpspi_direct_game_state::porta_r)); m_maincpu->portb_in().set(FUNC(generalplus_gpspi_direct_game_state::portb_r)); m_maincpu->portc_in().set(FUNC(generalplus_gpspi_direct_game_state::portc_r)); From 619cecaf0eb47fc40ae38ea7bef014c350800370 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 02:36:40 +0100 Subject: [PATCH 23/53] reorganize --- scripts/src/machine.lua | 10 +- ...50soc.cpp => generalplus_gpl16250_soc.cpp} | 390 +---------------- ...l16250soc.h => generalplus_gpl16250_soc.h} | 46 +- ...cpp => generalplus_gpl16250_soc_video.cpp} | 2 +- ...deo.h => generalplus_gpl16250_soc_video.h} | 6 +- .../machine/generalplus_gpl951xx_soc.cpp | 394 ++++++++++++++++++ .../machine/generalplus_gpl951xx_soc.h | 55 +++ src/mame/tvgames/generalplus_gpl16250.h | 2 +- src/mame/tvgames/generalplus_gpl16250_nand.h | 2 +- .../tvgames/generalplus_gpl16250_romram.h | 2 +- 10 files changed, 469 insertions(+), 440 deletions(-) rename src/devices/machine/{generalplus_gpl16250soc.cpp => generalplus_gpl16250_soc.cpp} (89%) rename src/devices/machine/{generalplus_gpl16250soc.h => generalplus_gpl16250_soc.h} (90%) rename src/devices/machine/{generalplus_gpl16250soc_video.cpp => generalplus_gpl16250_soc_video.cpp} (99%) rename src/devices/machine/{generalplus_gpl16250soc_video.h => generalplus_gpl16250_soc_video.h} (97%) create mode 100644 src/devices/machine/generalplus_gpl951xx_soc.cpp create mode 100644 src/devices/machine/generalplus_gpl951xx_soc.h diff --git a/scripts/src/machine.lua b/scripts/src/machine.lua index e8f35506cb887..e3e52b90e13a1 100644 --- a/scripts/src/machine.lua +++ b/scripts/src/machine.lua @@ -3457,10 +3457,12 @@ if (MACHINES["SPG2XX"]~=null) then MAME_DIR .. "src/devices/machine/spg110.h", MAME_DIR .. "src/devices/machine/spg110_video.cpp", MAME_DIR .. "src/devices/machine/spg110_video.h", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250soc.cpp", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250soc.h", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250soc_video.cpp", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250soc_video.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc_video.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc_video.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl951xx_soc.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl951xx_soc.h", MAME_DIR .. "src/devices/machine/spg_renderer.cpp", MAME_DIR .. "src/devices/machine/spg_renderer.h", } diff --git a/src/devices/machine/generalplus_gpl16250soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp similarity index 89% rename from src/devices/machine/generalplus_gpl16250soc.cpp rename to src/devices/machine/generalplus_gpl16250_soc.cpp index 7db78e2799abe..4151edea3283d 100644 --- a/src/devices/machine/generalplus_gpl16250soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -10,7 +10,7 @@ **********************************************************************/ #include "emu.h" -#include "generalplus_gpl16250soc.h" +#include "generalplus_gpl16250_soc.h" #define LOG_GCM394_SPI (1U << 5) @@ -75,394 +75,6 @@ generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &m } -void generalplus_gpl951xx_device::ramwrite_w(offs_t offset, uint16_t data) -{ - m_mainram[offset] = data; -} - -uint16_t generalplus_gpl951xx_device::ramread_r(offs_t offset) -{ - return m_mainram[offset]; -} - -uint16_t generalplus_gpl951xx_device::spi_direct_7b40_r() -{ - return 0xffff; // doesn't care for now -} - -uint16_t generalplus_gpl951xx_device::spi_direct_79f5_r() -{ - return 0xffff; // hangs if returning 0 -} - -uint16_t generalplus_gpl951xx_device::spi_direct_7b46_r() -{ - int i = machine().rand(); - - if (i & 1) return 0x01; - else return 0x02; -} - -uint16_t generalplus_gpl951xx_device::spi_direct_79f4_r() -{ - // status bits? - return machine().rand(); -} - - -uint16_t generalplus_gpl951xx_device::spi_direct_7af0_r() -{ - return m_7af0; -} - -void generalplus_gpl951xx_device::spi_direct_7af0_w(uint16_t data) -{ - // words read from ROM are written here during the checksum routine in RAM, and must - // be shifted for the checksum to pass. - m_7af0 = data >> 8; -} - - -uint16_t generalplus_gpl951xx_device::spi_direct_78e8_r() -{ - return machine().rand(); -} - -void generalplus_gpl951xx_device::device_start() -{ - sunplus_gcm394_base_device::device_start(); - save_item(NAME(m_7af0)); -} - -void generalplus_gpl951xx_device::device_reset() -{ - sunplus_gcm394_base_device::device_reset(); - m_7af0 = 0; -} - -void generalplus_gpl951xx_device::spi_direct_78e8_w(uint16_t data) -{ - logerror("%s: spi_direct_78e8_w %04x\n", machine().describe_context(), data); -} - -void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) -{ - sunplus_gcm394_base_device::base_internal_map(map); - - map(0x000000, 0x0027ff).rw(FUNC(generalplus_gpl951xx_device::ramread_r), FUNC(generalplus_gpl951xx_device::ramwrite_w)); - // TODO: RAM is only 0x2800 on this, like earlier SPG2xx models? unmap the extra from the base_internal_map? - - // 7800 - BodyID - // 7801 - unused - // 7802 - PwrKey_State - // 7803 - SYS_CTRL - // 7804 - CLK_Ctrl0 - // 7805 - CLK_Ctrl1 - // 7806 - Reset_Flag - // 7807 - Clock_Ctrl - // 7808 - LVR_Ctrl - // 7809 - PM_Ctrl - // 780a - Watchdog_Ctrl - map(0x00780b, 0x00780b).nopw(); // Watchdog_Clear - // 780c - WAIT - // 780d - HALT - // 780e - unused - // 780f - Power_State - // 7810 - BankSwitch - // 7811 - unused - // 7812 - unused - // 7813 - unused - // 7814 - unused - // 7815 - unused - // 7816 - unused - // 7817 - PLL_Sel - // 7818 - PLLWaitCLK - // 7819 - Cache_Ctrl - // 781a - Cache_HitRate - // 781b - unused - // 781c - unused - // 781d - unused - // 781e - unused - // 781f - SYS_Misc - - // 7825 - Unexpect_Flag - - // 7830 - CHECKSUM0_LB - // 7831 - CHECKSUM1_LB - // 7832 - CHECKSUM0_HB - // 7833 - CHECKSUM1_HB - // - // 7848 - ECC_LPRL_HB - // 7849 - ECC_LPRH_HB - // 784a - ECC_CPR_HB - // 784b - ECC_LPR_CKL_HB - // 784c - ECC_LPR_CKH_HB - // 784d - ECC_CPCKR_HB - // 784e - ECC_ERR0_HB - // 784f - ECC_ERR1_HB - - // 7850 - NF_Ctrl - // 7851 - NF_CMD - // 7852 - NF_AddrL - // 7853 - NF_AddrH - // 7854 - NF_Data - // 7855 - NF_INT_Ctrl - // 7856 - unused or BCH_Control - // 7857 - ECC_Ctrl - // 7858 - ECC_LPRL_LB or BCH_Error - // 7859 - ECC_LPRH_LB or BCH_Parity0 - // 785a - ECC_CPR_LB or BCH_Parity1 - // 785b - ECC_LPR_CKL_LB or BCH_Parity2 - // 785c - ECC_LPR_CKH_LB or BCH_Parity3 - // 785d - ECC_CPCKR_LB or BCH_Parity4 - // 785e - ECC_ERR0_LB or BCH_Parity5 - // 785f - ECC_ERR1_LB or BCH_Parity6 - - // 7860 - IOA_Data - // 7861 - IOA_Buffer - // 7862 - IOA_Dir - // 7863 - IOA_Attrib - // 7864 - IOA_Drv - // 7865 - IOA_Mux - // 7866 - IOA_Latch - // 7867 - IOA_KeyEN - - // 7868 - IOB_Data - // 7869 - IOB_Buffer - // 786a - IOB_Dir - // 786b - IOB_Attrib - // 786c - IOB_Drv - // 786d - IOB_Mux - // 786e - IOB_Latch - // 786f - IOB_KeyEN - - // 7870 - IOC_Data - // 7871 - IOC_Buffer - // 7872 - IOC_Dir - // 7873 - IOC_Attrib - // 7874 - IOC_Drv - // 7875 - IOC_Mux - // 7876 - IOC_Latch - // 7877 - IOC_KeyEN - - // 7878 - IOD_Data - // 7879 - IOD_Buffer - // 787a - IOD_Dir - // 787b - IOD_Attrib - // 787c - IOD_Drv - // 787d - IOD_Mux - - // 7880 - IOE_Data - // 7881 - IOE_Buffer - // 7882 - IOE_Dir - // 7883 - IOE_Attrib - // 7884 - IOE_Drv - // 7885 - IOE_Mux - // 7886 - IOE_Latch - // 7877 - IOE_KeyEN - - // 7888 - IOF_Data - // 7889 - IOF_Buffer - // 788a - IOF_Dir - // 788b - IOF_Attrib - // 788c - IOF_Drv - // 788d - IOF_Mux - // 788e - IOF_Latch - // 788f - IOF_KeyEN - - // 78a0 - INT_Status1 - // 78a1 - INT_Status2 - // 78a2 - INT_Status3 - // 78a3 - INT_Priority1 - // 78a4 - INT_Priority2 - // 78a5 - INT_Priority3 - // 78a6 - MINT_Ctrl - // 78a7 - IOAB_KCIEN - // 78a8 - IOC_KCIEN - // 78a9 - IOE_KCIEN - // 78aa - IOF_KCIEN - // 78ab - IOAB_KCIFC - // 78ac - IOC_ KCIFC - // 78ad - IOE_ KCIFC - // 78ae - IOF_ KCIFC - - // 78b0 - TimeBaseA_Ctrl - // 78b1 - TimeBaseB_Ctrl - // 78b2 - TimeBaseC_Ctrl - - // 78b8 - TimeBase_Reset - - // 78c0 - I2C_Ctrl - // 78c1 - I2C_Status - // 78c2 - I2C_Address - // 78c3 - I2C_Data - // 78c4 - I2C_Debounce - // 78c5 - I2C_Clk - // 78c6 - I2C_MISC - - // 78e0 - TimerG_Ctrl - // 78e1 - // 78e2 - TimerG_Preload - // 78e3 - // 78e4 - TimerG_UpCount - // 78e5 - // 78e6 - // 78e7 - map(0x0078e8, 0x0078e8).rw(FUNC(generalplus_gpl951xx_device::spi_direct_78e8_r), FUNC(generalplus_gpl951xx_device::spi_direct_78e8_w)); // TimerH_Ctrl - // 78e9 - // 78ea - TimerH_Preload - // 78eb - // 78ec - TimerH_UpCount - // 78ed - // 78ee - // 78ef - - // 78f0 - CHA_Ctrl - // 78f1 - CHA_Data - // 78f2 - CHA_FIFO - // 78f3 - // 78f4 - // 78f5 - // 78f6 - // 78f7 - // 78f8 - CHB_Ctrl - // 78f9 - CHB_Data - // 78fa - CHB_FIFO - // 78fb - // 78fc - // 78fd - // 78fe - // 78ff - - // 7900 - UART_Data - // 7901 - UART_RXStatus - // 7902 - UAR_Ctrl - // 7903 - UART_BaudRate - // 7904 - UART_Status - // 7905 - UART_FIFO - // 7906 - UART_TXDelay - - // 7920 - SPI1_Ctrl - // 7921 - SPI1_TXStatus - // 7922 - SPI1_TXData - // 7923 - SPI1_RXStatus - // 7924 - SPI1_RXData - // 7925 - SPI1_Misc - - // 7940 - SPI0_Ctrl - // 7941 - SPI0_TXStatus - // 7942 - SPI0_TXData - // 7943 - SPI0_RXStatus - // 7944 - SPI0_RXData - // 7945 - SPI0_Misc - - // 79a0 - ADC_Setup - // 79a1 - MADC_Ctrl - // 79a2 - MADC_Data - // 79a3 - ASADC_Ctrl - // 79a4 - ASDAC_Data - // 79a5 - // 79a6 - ADC_LineCH_En - // 79a7 - ADC_SH_Wait - - // 79b0 - MICADC_Setup - // 79b1 - MICGAIN_Ctrl - // 79b2 - // 79b3 - ASMICADC_Ctrl - // 79b4 - ASMICDAC_Data - // 79b5 - MICAGC_UpThres - // 79b6 - // 79b7 - MICADC_SH_WAIT - // 79b8 - MICADC_DataMAX - // 79b9 - MICADC_DataMIN - // 79ba - MICADC_FLAG - // 79bb - MICADC_GAIN - // 79bc - MICAGC_Ctrl - // 79bd - MICAGC_Time - // 79be - MICAGC_Enable - // 79bf - MICAGC_Status - - // 79f0 - RTC_Ctrl - // 79f1 - RTC_Addr - // 79f2 - RTC_WriteData - // 79f3 - RTC_Request - map(0x0079f4, 0x0079f4).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f4_r)); // RTC_Ready - map(0x0079f5, 0x0079f5).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f5_r)); // RTC_ReadData - // 79f6 - // 79f7 - // 79f8 - // 79fa - // 79fb - RTC_ClkDiv - - // 7a00 - TimerA_Ctr - // 7a01 - TimerA_CCPB_Ctrl - // 7a02 - TimerA_Preload - // 7a03 - TimerA_CCPB_Reg - // 7a04 - TimerA_UpCount - - // 7a08 - TimerB_Ctrl - // 7a09 - TimerB_CCPB_Ctrl - // 7a0a - TimerB_Preload - // 7a0b - TimerB_CCPB_Reg - // 7a0c - TimerB_UpCount - - // 7a10 - TimerC_Ctrl - // 7a11 - TimerC_CCPB_Ctrl - // 7a12 - TimerC_Preload - // 7a13 - TimerC_CCPB_Reg - // 7a14 - TimerC_UpCount - - // 7a18 - TimerD_Ctrl - // 7a19 - TimerD_CCPB_Ctrl - // 7a1a - TimerD_Preload - // 7a1b - TimerD_CCPB_Reg - // 7a1c - TimerD_UpCount - - // 7a20 - TimerE_Ctrl - // 7a21 - TimerF_Ctrl - // 7a22 - TimerE_CCPB_Ctrl - // 7a23 - TimerF_CCPB_Ctrl - // 7a24 - TimerE_Preload - // 7a25 - TimerF_Preload - // 7a26 - TimerEF_CCPB4_Reg - // 7a27 - TimerEF_CCPB5_Reg - // 7a28 - TimerEF_CCPB6_Reg - // 7a29 - TimerEF_CCPB7_Reg - // 7a2a - TimerE_UpCount - // 7a2b - TimerF_UpCount - // 7a2c - TimerEF_CCPB_Se - - // 7a40 - USBD_Config - // 7a41 - USBD_Function - // 7a42 - USBD_PMR - - map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpl951xx_device::spi_direct_7af0_r), FUNC(generalplus_gpl951xx_device::spi_direct_7af0_w)); - - map(0x007b40, 0x007b40).r(FUNC(generalplus_gpl951xx_device::spi_direct_7b40_r)).nopw();; // SPIFC_Ctrl1 - map(0x007b41, 0x007b41).nopw(); // SPIFC_CMD - map(0x007b42, 0x007b42).nopw(); // SPIFC_PARA - // 7b43 - SPIFC_ADDRL - // 7b44 - SPIFC_ADDRH - // 7b45 - SPIFC_TX_Dat - map(0x007b46, 0x007b46).ram(); // SPIFC_RX_Data - values must be written and read from here, but is there any transformation? - map(0x007b47, 0x007b47).nopw(); // SPIFC_TX_BC - map(0x007b48, 0x007b48).nopw(); // SPIFC_RX_BC - map(0x007b49, 0x007b49).ram(); // SPIFC_TIMING - - // 7b4b - SPIFC_Ctrl2 - - map(0x009000, 0x3fffff).rom().region("spidirect", 0); -} - - -DEFINE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device, "gpl951xx", "GeneralPlus GPL951xx") - -generalplus_gpl951xx_device::generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - sunplus_gcm394_base_device(mconfig, GPL951XX, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpl951xx_device::gpspi_direct_internal_map), this)) -{ -} - - void sunplus_gcm394_base_device::default_cs_callback(uint16_t cs0, uint16_t cs1, uint16_t cs2, uint16_t cs3, uint16_t cs4) diff --git a/src/devices/machine/generalplus_gpl16250soc.h b/src/devices/machine/generalplus_gpl16250_soc.h similarity index 90% rename from src/devices/machine/generalplus_gpl16250soc.h rename to src/devices/machine/generalplus_gpl16250_soc.h index 03a97bde7d259..ac5e50ec8904b 100644 --- a/src/devices/machine/generalplus_gpl16250soc.h +++ b/src/devices/machine/generalplus_gpl16250_soc.h @@ -6,15 +6,15 @@ **********************************************************************/ -#ifndef MAME_MACHINE_GENERALPLUS_GPL16250SOC_H -#define MAME_MACHINE_GENERALPLUS_GPL16250SOC_H +#ifndef MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H +#define MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H #pragma once #include "cpu/unsp/unsp.h" #include "screen.h" #include "emupal.h" -#include "generalplus_gpl16250soc_video.h" +#include "generalplus_gpl16250_soc_video.h" #include "spg2xx_audio.h" typedef device_delegate sunplus_gcm394_cs_callback_device; @@ -447,47 +447,13 @@ class generalplus_gpspispi_device : public sunplus_gcm394_base_device uint16_t spi_unk_7943_r(); }; -class generalplus_gpl951xx_device : public sunplus_gcm394_base_device -{ -public: - template - generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : - generalplus_gpl951xx_device(mconfig, tag, owner, clock) - { - m_screen.set_tag(std::forward(screen_tag)); - //m_csbase = 0x30000; - // TODO: is cs_space even used by this type? - m_csbase = 0xffffffff; - } - - generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - -protected: - void gpspi_direct_internal_map(address_map &map) ATTR_COLD; - - virtual void device_start() override ATTR_COLD; - virtual void device_reset() override ATTR_COLD; - -private: - uint16_t ramread_r(offs_t offset); - void ramwrite_w(offs_t offset, uint16_t data); - uint16_t spi_direct_7b40_r(); - uint16_t spi_direct_7b46_r(); - uint16_t spi_direct_7af0_r(); - void spi_direct_7af0_w(uint16_t data); - uint16_t spi_direct_79f5_r(); - uint16_t spi_direct_78e8_r(); - void spi_direct_78e8_w(uint16_t data); - uint16_t spi_direct_79f4_r(); - - uint16_t m_7af0; -}; DECLARE_DEVICE_TYPE(GCM394, sunplus_gcm394_device) DECLARE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device) DECLARE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device) -DECLARE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device) -#endif // MAME_MACHINE_GENERALPLUS_GPL16250SOC_H + + +#endif // MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H diff --git a/src/devices/machine/generalplus_gpl16250soc_video.cpp b/src/devices/machine/generalplus_gpl16250_soc_video.cpp similarity index 99% rename from src/devices/machine/generalplus_gpl16250soc_video.cpp rename to src/devices/machine/generalplus_gpl16250_soc_video.cpp index 5c05f545bf22d..8768b4ea3cf58 100644 --- a/src/devices/machine/generalplus_gpl16250soc_video.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc_video.cpp @@ -10,7 +10,7 @@ #include "emu.h" -#include "generalplus_gpl16250soc_video.h" +#include "generalplus_gpl16250_soc_video.h" DEFINE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device, "gcm394_video", "GeneralPlus GPL16250 System-on-a-Chip (Video)") diff --git a/src/devices/machine/generalplus_gpl16250soc_video.h b/src/devices/machine/generalplus_gpl16250_soc_video.h similarity index 97% rename from src/devices/machine/generalplus_gpl16250soc_video.h rename to src/devices/machine/generalplus_gpl16250_soc_video.h index f1086c5713b3a..68596c7eedd63 100644 --- a/src/devices/machine/generalplus_gpl16250soc_video.h +++ b/src/devices/machine/generalplus_gpl16250_soc_video.h @@ -6,8 +6,8 @@ **********************************************************************/ -#ifndef MAME_MACHINE_GENERALPLUS_GPL16250SOC_VIDEO_H -#define MAME_MACHINE_GENERALPLUS_GPL16250SOC_VIDEO_H +#ifndef MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H +#define MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H #pragma once @@ -259,4 +259,4 @@ class gcm394_video_device : public gcm394_base_video_device DECLARE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device) -#endif // MAME_MACHINE_GENERALPLUS_GPL16250SOC_VIDEO_H +#endif // MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H diff --git a/src/devices/machine/generalplus_gpl951xx_soc.cpp b/src/devices/machine/generalplus_gpl951xx_soc.cpp new file mode 100644 index 0000000000000..a20d8cc7c1b96 --- /dev/null +++ b/src/devices/machine/generalplus_gpl951xx_soc.cpp @@ -0,0 +1,394 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood + +#include "emu.h" +#include "generalplus_gpl951xx_soc.h" + + +void generalplus_gpl951xx_device::ramwrite_w(offs_t offset, uint16_t data) +{ + m_mainram[offset] = data; +} + +uint16_t generalplus_gpl951xx_device::ramread_r(offs_t offset) +{ + return m_mainram[offset]; +} + +uint16_t generalplus_gpl951xx_device::spi_direct_7b40_r() +{ + return 0xffff; // doesn't care for now +} + +uint16_t generalplus_gpl951xx_device::spi_direct_79f5_r() +{ + return 0xffff; // hangs if returning 0 +} + +uint16_t generalplus_gpl951xx_device::spi_direct_7b46_r() +{ + int i = machine().rand(); + + if (i & 1) return 0x01; + else return 0x02; +} + +uint16_t generalplus_gpl951xx_device::spi_direct_79f4_r() +{ + // status bits? + return machine().rand(); +} + + +uint16_t generalplus_gpl951xx_device::spi_direct_7af0_r() +{ + return m_7af0; +} + +void generalplus_gpl951xx_device::spi_direct_7af0_w(uint16_t data) +{ + // words read from ROM are written here during the checksum routine in RAM, and must + // be shifted for the checksum to pass. + m_7af0 = data >> 8; +} + + +uint16_t generalplus_gpl951xx_device::spi_direct_78e8_r() +{ + return machine().rand(); +} + +void generalplus_gpl951xx_device::device_start() +{ + sunplus_gcm394_base_device::device_start(); + save_item(NAME(m_7af0)); +} + +void generalplus_gpl951xx_device::device_reset() +{ + sunplus_gcm394_base_device::device_reset(); + m_7af0 = 0; +} + +void generalplus_gpl951xx_device::spi_direct_78e8_w(uint16_t data) +{ + logerror("%s: spi_direct_78e8_w %04x\n", machine().describe_context(), data); +} + +void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) +{ + sunplus_gcm394_base_device::base_internal_map(map); + + map(0x000000, 0x0027ff).rw(FUNC(generalplus_gpl951xx_device::ramread_r), FUNC(generalplus_gpl951xx_device::ramwrite_w)); + // TODO: RAM is only 0x2800 on this, like earlier SPG2xx models? unmap the extra from the base_internal_map? + + // 7800 - BodyID + // 7801 - unused + // 7802 - PwrKey_State + // 7803 - SYS_CTRL + // 7804 - CLK_Ctrl0 + // 7805 - CLK_Ctrl1 + // 7806 - Reset_Flag + // 7807 - Clock_Ctrl + // 7808 - LVR_Ctrl + // 7809 - PM_Ctrl + // 780a - Watchdog_Ctrl + map(0x00780b, 0x00780b).nopw(); // Watchdog_Clear + // 780c - WAIT + // 780d - HALT + // 780e - unused + // 780f - Power_State + // 7810 - BankSwitch + // 7811 - unused + // 7812 - unused + // 7813 - unused + // 7814 - unused + // 7815 - unused + // 7816 - unused + // 7817 - PLL_Sel + // 7818 - PLLWaitCLK + // 7819 - Cache_Ctrl + // 781a - Cache_HitRate + // 781b - unused + // 781c - unused + // 781d - unused + // 781e - unused + // 781f - SYS_Misc + + // 7825 - Unexpect_Flag + + // 7830 - CHECKSUM0_LB + // 7831 - CHECKSUM1_LB + // 7832 - CHECKSUM0_HB + // 7833 - CHECKSUM1_HB + // + // 7848 - ECC_LPRL_HB + // 7849 - ECC_LPRH_HB + // 784a - ECC_CPR_HB + // 784b - ECC_LPR_CKL_HB + // 784c - ECC_LPR_CKH_HB + // 784d - ECC_CPCKR_HB + // 784e - ECC_ERR0_HB + // 784f - ECC_ERR1_HB + + // 7850 - NF_Ctrl + // 7851 - NF_CMD + // 7852 - NF_AddrL + // 7853 - NF_AddrH + // 7854 - NF_Data + // 7855 - NF_INT_Ctrl + // 7856 - unused or BCH_Control + // 7857 - ECC_Ctrl + // 7858 - ECC_LPRL_LB or BCH_Error + // 7859 - ECC_LPRH_LB or BCH_Parity0 + // 785a - ECC_CPR_LB or BCH_Parity1 + // 785b - ECC_LPR_CKL_LB or BCH_Parity2 + // 785c - ECC_LPR_CKH_LB or BCH_Parity3 + // 785d - ECC_CPCKR_LB or BCH_Parity4 + // 785e - ECC_ERR0_LB or BCH_Parity5 + // 785f - ECC_ERR1_LB or BCH_Parity6 + + // 7860 - IOA_Data + // 7861 - IOA_Buffer + // 7862 - IOA_Dir + // 7863 - IOA_Attrib + // 7864 - IOA_Drv + // 7865 - IOA_Mux + // 7866 - IOA_Latch + // 7867 - IOA_KeyEN + + // 7868 - IOB_Data + // 7869 - IOB_Buffer + // 786a - IOB_Dir + // 786b - IOB_Attrib + // 786c - IOB_Drv + // 786d - IOB_Mux + // 786e - IOB_Latch + // 786f - IOB_KeyEN + + // 7870 - IOC_Data + // 7871 - IOC_Buffer + // 7872 - IOC_Dir + // 7873 - IOC_Attrib + // 7874 - IOC_Drv + // 7875 - IOC_Mux + // 7876 - IOC_Latch + // 7877 - IOC_KeyEN + + // 7878 - IOD_Data + // 7879 - IOD_Buffer + // 787a - IOD_Dir + // 787b - IOD_Attrib + // 787c - IOD_Drv + // 787d - IOD_Mux + + // 7880 - IOE_Data + // 7881 - IOE_Buffer + // 7882 - IOE_Dir + // 7883 - IOE_Attrib + // 7884 - IOE_Drv + // 7885 - IOE_Mux + // 7886 - IOE_Latch + // 7877 - IOE_KeyEN + + // 7888 - IOF_Data + // 7889 - IOF_Buffer + // 788a - IOF_Dir + // 788b - IOF_Attrib + // 788c - IOF_Drv + // 788d - IOF_Mux + // 788e - IOF_Latch + // 788f - IOF_KeyEN + + // 78a0 - INT_Status1 + // 78a1 - INT_Status2 + // 78a2 - INT_Status3 + // 78a3 - INT_Priority1 + // 78a4 - INT_Priority2 + // 78a5 - INT_Priority3 + // 78a6 - MINT_Ctrl + // 78a7 - IOAB_KCIEN + // 78a8 - IOC_KCIEN + // 78a9 - IOE_KCIEN + // 78aa - IOF_KCIEN + // 78ab - IOAB_KCIFC + // 78ac - IOC_ KCIFC + // 78ad - IOE_ KCIFC + // 78ae - IOF_ KCIFC + + // 78b0 - TimeBaseA_Ctrl + // 78b1 - TimeBaseB_Ctrl + // 78b2 - TimeBaseC_Ctrl + + // 78b8 - TimeBase_Reset + + // 78c0 - I2C_Ctrl + // 78c1 - I2C_Status + // 78c2 - I2C_Address + // 78c3 - I2C_Data + // 78c4 - I2C_Debounce + // 78c5 - I2C_Clk + // 78c6 - I2C_MISC + + // 78e0 - TimerG_Ctrl + // 78e1 + // 78e2 - TimerG_Preload + // 78e3 + // 78e4 - TimerG_UpCount + // 78e5 + // 78e6 + // 78e7 + map(0x0078e8, 0x0078e8).rw(FUNC(generalplus_gpl951xx_device::spi_direct_78e8_r), FUNC(generalplus_gpl951xx_device::spi_direct_78e8_w)); // TimerH_Ctrl + // 78e9 + // 78ea - TimerH_Preload + // 78eb + // 78ec - TimerH_UpCount + // 78ed + // 78ee + // 78ef + + // 78f0 - CHA_Ctrl + // 78f1 - CHA_Data + // 78f2 - CHA_FIFO + // 78f3 + // 78f4 + // 78f5 + // 78f6 + // 78f7 + // 78f8 - CHB_Ctrl + // 78f9 - CHB_Data + // 78fa - CHB_FIFO + // 78fb + // 78fc + // 78fd + // 78fe + // 78ff + + // 7900 - UART_Data + // 7901 - UART_RXStatus + // 7902 - UAR_Ctrl + // 7903 - UART_BaudRate + // 7904 - UART_Status + // 7905 - UART_FIFO + // 7906 - UART_TXDelay + + // 7920 - SPI1_Ctrl + // 7921 - SPI1_TXStatus + // 7922 - SPI1_TXData + // 7923 - SPI1_RXStatus + // 7924 - SPI1_RXData + // 7925 - SPI1_Misc + + // 7940 - SPI0_Ctrl + // 7941 - SPI0_TXStatus + // 7942 - SPI0_TXData + // 7943 - SPI0_RXStatus + // 7944 - SPI0_RXData + // 7945 - SPI0_Misc + + // 79a0 - ADC_Setup + // 79a1 - MADC_Ctrl + // 79a2 - MADC_Data + // 79a3 - ASADC_Ctrl + // 79a4 - ASDAC_Data + // 79a5 + // 79a6 - ADC_LineCH_En + // 79a7 - ADC_SH_Wait + + // 79b0 - MICADC_Setup + // 79b1 - MICGAIN_Ctrl + // 79b2 + // 79b3 - ASMICADC_Ctrl + // 79b4 - ASMICDAC_Data + // 79b5 - MICAGC_UpThres + // 79b6 + // 79b7 - MICADC_SH_WAIT + // 79b8 - MICADC_DataMAX + // 79b9 - MICADC_DataMIN + // 79ba - MICADC_FLAG + // 79bb - MICADC_GAIN + // 79bc - MICAGC_Ctrl + // 79bd - MICAGC_Time + // 79be - MICAGC_Enable + // 79bf - MICAGC_Status + + // 79f0 - RTC_Ctrl + // 79f1 - RTC_Addr + // 79f2 - RTC_WriteData + // 79f3 - RTC_Request + map(0x0079f4, 0x0079f4).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f4_r)); // RTC_Ready + map(0x0079f5, 0x0079f5).r(FUNC(generalplus_gpl951xx_device::spi_direct_79f5_r)); // RTC_ReadData + // 79f6 + // 79f7 + // 79f8 + // 79fa + // 79fb - RTC_ClkDiv + + // 7a00 - TimerA_Ctr + // 7a01 - TimerA_CCPB_Ctrl + // 7a02 - TimerA_Preload + // 7a03 - TimerA_CCPB_Reg + // 7a04 - TimerA_UpCount + + // 7a08 - TimerB_Ctrl + // 7a09 - TimerB_CCPB_Ctrl + // 7a0a - TimerB_Preload + // 7a0b - TimerB_CCPB_Reg + // 7a0c - TimerB_UpCount + + // 7a10 - TimerC_Ctrl + // 7a11 - TimerC_CCPB_Ctrl + // 7a12 - TimerC_Preload + // 7a13 - TimerC_CCPB_Reg + // 7a14 - TimerC_UpCount + + // 7a18 - TimerD_Ctrl + // 7a19 - TimerD_CCPB_Ctrl + // 7a1a - TimerD_Preload + // 7a1b - TimerD_CCPB_Reg + // 7a1c - TimerD_UpCount + + // 7a20 - TimerE_Ctrl + // 7a21 - TimerF_Ctrl + // 7a22 - TimerE_CCPB_Ctrl + // 7a23 - TimerF_CCPB_Ctrl + // 7a24 - TimerE_Preload + // 7a25 - TimerF_Preload + // 7a26 - TimerEF_CCPB4_Reg + // 7a27 - TimerEF_CCPB5_Reg + // 7a28 - TimerEF_CCPB6_Reg + // 7a29 - TimerEF_CCPB7_Reg + // 7a2a - TimerE_UpCount + // 7a2b - TimerF_UpCount + // 7a2c - TimerEF_CCPB_Se + + // 7a40 - USBD_Config + // 7a41 - USBD_Function + // 7a42 - USBD_PMR + + map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpl951xx_device::spi_direct_7af0_r), FUNC(generalplus_gpl951xx_device::spi_direct_7af0_w)); + + map(0x007b40, 0x007b40).r(FUNC(generalplus_gpl951xx_device::spi_direct_7b40_r)).nopw();; // SPIFC_Ctrl1 + map(0x007b41, 0x007b41).nopw(); // SPIFC_CMD + map(0x007b42, 0x007b42).nopw(); // SPIFC_PARA + // 7b43 - SPIFC_ADDRL + // 7b44 - SPIFC_ADDRH + // 7b45 - SPIFC_TX_Dat + map(0x007b46, 0x007b46).ram(); // SPIFC_RX_Data - values must be written and read from here, but is there any transformation? + map(0x007b47, 0x007b47).nopw(); // SPIFC_TX_BC + map(0x007b48, 0x007b48).nopw(); // SPIFC_RX_BC + map(0x007b49, 0x007b49).ram(); // SPIFC_TIMING + + // 7b4b - SPIFC_Ctrl2 + + map(0x009000, 0x3fffff).rom().region("spidirect", 0); +} + + +DEFINE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device, "gpl951xx", "GeneralPlus GPL951xx") + +generalplus_gpl951xx_device::generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + sunplus_gcm394_base_device(mconfig, GPL951XX, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpl951xx_device::gpspi_direct_internal_map), this)) +{ +} + diff --git a/src/devices/machine/generalplus_gpl951xx_soc.h b/src/devices/machine/generalplus_gpl951xx_soc.h new file mode 100644 index 0000000000000..0f69dfcd827a6 --- /dev/null +++ b/src/devices/machine/generalplus_gpl951xx_soc.h @@ -0,0 +1,55 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood + +#ifndef MAME_MACHINE_GENERALPLUS_GPL951XX_SOC_H +#define MAME_MACHINE_GENERALPLUS_GPL951XX_SOC_H + +#pragma once + +#include "cpu/unsp/unsp.h" +#include "screen.h" +#include "emupal.h" +#include "generalplus_gpl16250_soc_video.h" +#include "spg2xx_audio.h" + +#include "generalplus_gpl16250_soc.h" + +class generalplus_gpl951xx_device : public sunplus_gcm394_base_device +{ +public: + template + generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpl951xx_device(mconfig, tag, owner, clock) + { + m_screen.set_tag(std::forward(screen_tag)); + //m_csbase = 0x30000; + // TODO: is cs_space even used by this type? + m_csbase = 0xffffffff; + } + + generalplus_gpl951xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + +protected: + void gpspi_direct_internal_map(address_map &map) ATTR_COLD; + + virtual void device_start() override ATTR_COLD; + virtual void device_reset() override ATTR_COLD; + +private: + uint16_t ramread_r(offs_t offset); + void ramwrite_w(offs_t offset, uint16_t data); + uint16_t spi_direct_7b40_r(); + uint16_t spi_direct_7b46_r(); + uint16_t spi_direct_7af0_r(); + void spi_direct_7af0_w(uint16_t data); + uint16_t spi_direct_79f5_r(); + uint16_t spi_direct_78e8_r(); + void spi_direct_78e8_w(uint16_t data); + uint16_t spi_direct_79f4_r(); + + uint16_t m_7af0; +}; + +DECLARE_DEVICE_TYPE(GPL951XX, generalplus_gpl951xx_device) + +#endif // MAME_MACHINE_GENERALPLUS_GPL951XX_SOC_H diff --git a/src/mame/tvgames/generalplus_gpl16250.h b/src/mame/tvgames/generalplus_gpl16250.h index 9efaf7abb6d2a..1181bf5093855 100644 --- a/src/mame/tvgames/generalplus_gpl16250.h +++ b/src/mame/tvgames/generalplus_gpl16250.h @@ -9,7 +9,7 @@ #include "bus/generic/carts.h" #include "bus/generic/slot.h" -#include "machine/generalplus_gpl16250soc.h" +#include "machine/generalplus_gpl951xx_soc.h" #include "screen.h" #include "speaker.h" diff --git a/src/mame/tvgames/generalplus_gpl16250_nand.h b/src/mame/tvgames/generalplus_gpl16250_nand.h index a278892fc3701..647e36176a0a3 100644 --- a/src/mame/tvgames/generalplus_gpl16250_nand.h +++ b/src/mame/tvgames/generalplus_gpl16250_nand.h @@ -6,7 +6,7 @@ #pragma once #include "generalplus_gpl16250.h" -#include "machine/generalplus_gpl16250soc.h" +#include "machine/generalplus_gpl16250_soc.h" #include "generalplus_gpl16250_m.h" #include "bus/generic/slot.h" #include "bus/generic/carts.h" diff --git a/src/mame/tvgames/generalplus_gpl16250_romram.h b/src/mame/tvgames/generalplus_gpl16250_romram.h index 48df09c2dbc64..ca7ce96695c58 100644 --- a/src/mame/tvgames/generalplus_gpl16250_romram.h +++ b/src/mame/tvgames/generalplus_gpl16250_romram.h @@ -6,7 +6,7 @@ #pragma once #include "generalplus_gpl16250.h" -#include "machine/generalplus_gpl16250soc.h" +#include "machine/generalplus_gpl16250_soc.h" #include "generalplus_gpl16250_m.h" #include "bus/generic/slot.h" #include "bus/generic/carts.h" From 15b423856eedb0ef34037f61a7b893d142fe4775 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 03:39:26 +0100 Subject: [PATCH 24/53] gpl951xx valid registers --- .../machine/generalplus_gpl951xx_soc.cpp | 210 +++++++++++++++++- 1 file changed, 207 insertions(+), 3 deletions(-) diff --git a/src/devices/machine/generalplus_gpl951xx_soc.cpp b/src/devices/machine/generalplus_gpl951xx_soc.cpp index a20d8cc7c1b96..ead4db47d7e96 100644 --- a/src/devices/machine/generalplus_gpl951xx_soc.cpp +++ b/src/devices/machine/generalplus_gpl951xx_soc.cpp @@ -82,6 +82,117 @@ void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) map(0x000000, 0x0027ff).rw(FUNC(generalplus_gpl951xx_device::ramread_r), FUNC(generalplus_gpl951xx_device::ramwrite_w)); // TODO: RAM is only 0x2800 on this, like earlier SPG2xx models? unmap the extra from the base_internal_map? + // 7000 - Tx3_X_Position + // 7001 - Tx3_Y_Position + // 7002 - Tx3_X_Offset + // 7003 - Tx3_Y_Offset + // 7004 - Tx3_Attribute + // 7005 - Tx3_Control + // 7006 - Tx3_N_PTR + // 7007 - Tx3_A_PTR + + // 7010 - Tx1_X_Position + // 7011 - Tx1_Y_Position + // 7012 - Tx1_Attribute + // 7013 - Tx1_Control + // 7014 - Tx1_N_PTR + // 7015 - Tx1_A_PTR + // 7016 - Tx2_X_Position + // 7017 - Tx2_Y_Position + // 7018 - Tx2_Attribute + // 7019 - Tx2_Contro + // 701a - Tx2_N_PTR + // 701b - Tx2_A_PTR + // 701c - VComValue + // 701d - VComOffset + // 701e - VComStep + + // 7020 - Segment_Tx1 + // 7021 - Segment_Tx2 + // 7022 - Segment_sp + // 7023 - Segment_Tx3 + // + // 702a - Blending + // 702b - Segment_Tx1H + // 702c - Segment_Tx2H + // 702d - Segment_spH + // 702e - Segment_Tx3H + // + // 7030 - Fade_Control + // + // 703a - Palette_Control + // + // 7042 - SControl + // + // 7050 - TFT_Ctrl + // 7051 - TFT_V_Width + // 7052 - TFT_VSync_Setup + // 7053 - TFT_V_Start + // 7054 - TFT_V_End + // 7055 - TFT_H_Width + // 7056 - TFT_HSync_Setup + // 7057 - TFT_H_Start + // 7058 - TFT_H_End + // 7059 - TFT_RGB_Ctrl + // 705a - TFT_Status + // 705b - TFT_MemMode_WCmd + // 705c - TFT_MemMode_RCmd + // + // 705e - STN_PIC_SEG + // 705f - STN_Ctrl1 + // + // 7062 - TFT_INT_EN + // 7063 - TFT_INT_CLR + // 7064 - US_Ctrl + // 7065 - US_Hscaling + // 7066 - US_Vscaling + // 7067 - US_Width + // 7068 - US_Height + // 7069 - US_Hoffset + // 706a - US_Voffset + // + // 706c - TFT_V_Show_Start + // 706d - TFT_V_Show_End + // 706e - TFT_H_Show_Start + // 706f - TFT_H_Show_End + // + // 7070 - SPDMA_Source + // 7071 - SPDMA_Target + // 7072 - SPDMA_Number + // 7073 - HB_Ctrl + // 7074 - HB_GO + // + // 707d - BLD_Color + // + // 707e - PPU_RAM_BANK + // 707f - PPU_Enable + // + // 7080 - STN_SEG + // 7081 - STN_COM + // 7082 - STN_PIC_COM + // 7083 - STN_CPWait + // 7084 - STN_Ctrl2 + // 7085 - STN_GTG_SEG + // 7086 - STN_GTG_COM + // + // 70b4 - Tx1_N_PTRH + // 70b5 - Tx1_A_PTRH + // 70b6 - Tx2_N_PTRH + // 70b7 - Tx2_A_PTRH + // 70b8 - Tx3_N_PTRH + // 70b9 - Tx3_A_PTRH + // + // 70db - Free_Height + // 70dc - Free_Width + // + // 70e0 - Random0 (15-bit) + // 70e1 - Random1 (15-bit) + // + // 7100 to 71ff - Tx_Hvoffset + // 7200 to 72ff - HCMValue + // 7300 to 73ff - Palette (banked) + // 7400 to 74ff - Sprite Ram (banked) + // // 7800 - BodyID // 7801 - unused // 7802 - PwrKey_State @@ -365,8 +476,97 @@ void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) // 7a40 - USBD_Config // 7a41 - USBD_Function // 7a42 - USBD_PMR - - map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpl951xx_device::spi_direct_7af0_r), FUNC(generalplus_gpl951xx_device::spi_direct_7af0_w)); + // 7a43 - USBD_EP0Data + // 7a44 - USBD_BIData + // 7a45 - USBD_BOData + // 7a46 - USBD_INTINData + // 7a47 - USBD_EPEvent + // 7a48 - USBD_GLOINT + // 7a49 - USBD_INTEN + // 7a4a - USBD_INT + // 7a4b - USBD_SCI NTEN + // 7a4c - USBD_SCINT + // 7a4d - USBD_EPAutoSet + // 7a4e - USBD_EPSetStall + // 7a4f - USBD_EPBufClear + // 7a50 - USBD_EPEvntClear + // 7a51 - USBD_EP0WrtCount + // 7a52 - USBD_BOWrtCount + // 7a53 - USBD_EP0BufPointer + // 7a54 - USBD_BIBufPointer + // 7a55 - USBD_BOBufPointer + // 7a56 - USBD_EP0RTR + // 7a57 - USBD_EP0RR + // 7a58 - USBD_ EP0VR + // 7a59 - USBD_ EP0IR + // 7a5a - USBD_ EP0LR + // + // 7a60 - USBD_DMAWrtCountL + // 7a61 - USBD_DMAWrtCountH + // 7a62 - USBD_DMAAckL + // 7a63 - USBD_DMAAckH + // 7a64 - USBD_EPStall + // + // 7a67 - USBD_Device + // 7a68 - USBD_NullPkt + // 7a69 - USBD_DMAINT + // + // 7a6c - USBD_INTF + + // 7a80 - DMA_Ctrl0 + // 7a81 - DMA_SRC_AddrL0 + // 7a82 - DMA_TAR_AddrL0 + // 7a83 - DMA_TCountL0 + // 7a84 - DMA_SRC_AddrH0 + // 7a85 - DMA_TAR_AddrH0 + // 7a86 - DMA_TCountH0 + // 7a87 - DMA_MISC0 + // 7a88 - DMA_Ctrl1 + // 7a89 - DMA_SRC_AddrL1 + // 7a8a - DMA_TAR_AddrL1 + // 7a8b - DMA_TCountL1 + // 7a8c - DMA_SRC_AddrH1 + // 7a8d - DMA_TAR_AddrH1 + // 7a8e - DMA_TCountH1 + // 7a8f - DMA_MISC1 + // + // 7ab0 - DMA_SPRISize0 + // 7ab1 - DMA_SPRISize1 + // + // 7abd - DMA_LineLength + // 7abe - DMA_SS + // 7abf - DMA_INT + // + // 7ac0 - CTS_Ctrl1 + // 7ac1 - CTS_CH + // 7ac2 - CTS_DIV + // 7ac3 - CTS_CYCLE + // 7ac4 - CTS_Ctrl2 + // 7ac5 - CTS_Status + // 7ac6 - CTS_Ctrl3 + // + // 7ac8 - CTS_FIFOLevel + // 7ac9 - CTS_CNT + + map(0x007af0, 0x007af0).rw(FUNC(generalplus_gpl951xx_device::spi_direct_7af0_r), FUNC(generalplus_gpl951xx_device::spi_direct_7af0_w)); // Byte_Swap + // 7af1 - Nibble_Swap + // 7af2 - TwoBit_Swap + // 7af3 - Bit_Reverse + + // 7b20 - KS_Ctrl1 + // 7b21 - KS_Ctrl2 + // + // 7b28 - KS_Data0 + // 7b29 - KS_Data1 + // 7b2a - KS_Data2 + // 7b2b - KS_Data3 + // 7b2c - KS_Data4 + // 7b2d - KS_Data5 + // 7b2e - KS_Data6 + // 7b2f - KS_Data7 + // 7b30 - KS_Data8 + // 7b31 - KS_Data9 + // 7b32 - KS_Data10 map(0x007b40, 0x007b40).r(FUNC(generalplus_gpl951xx_device::spi_direct_7b40_r)).nopw();; // SPIFC_Ctrl1 map(0x007b41, 0x007b41).nopw(); // SPIFC_CMD @@ -379,7 +579,11 @@ void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) map(0x007b48, 0x007b48).nopw(); // SPIFC_RX_BC map(0x007b49, 0x007b49).ram(); // SPIFC_TIMING - // 7b4b - SPIFC_Ctrl2 + // 7b4b - SPIFC_Ctrl2 + + // 7b80 to 7b9f - Audio + // 7c00 to 7cff - Audio + // 7e00 to 7eff - Audio map(0x009000, 0x3fffff).rom().region("spidirect", 0); } From 94695ce37a9f0a9425fb8bf283307e677b2226d0 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 04:14:05 +0100 Subject: [PATCH 25/53] chip name notes --- src/devices/machine/generalplus_gpl16250_soc.cpp | 8 +++++--- src/devices/machine/generalplus_gpl951xx_soc.cpp | 2 ++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index 4151edea3283d..62b8f1aac1007 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -2,10 +2,12 @@ // copyright-holders:David Haywood /***************************************************************************** - SunPlus "GCM394" (based on die pictures) + GPL16220A - 320x240 output, 16K words internal RAM + GPL16230A - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support + GPL16240VA (GPAC500?) - adds 640x480 output + GPL16250VA (GPAC800?) - adds '3D' sprite mode, - Note, these are all the same chip but in different configurations so - should be tidied up and made to use callbacks + die is marked 'GCM394' on some chips **********************************************************************/ diff --git a/src/devices/machine/generalplus_gpl951xx_soc.cpp b/src/devices/machine/generalplus_gpl951xx_soc.cpp index ead4db47d7e96..98206f968c696 100644 --- a/src/devices/machine/generalplus_gpl951xx_soc.cpp +++ b/src/devices/machine/generalplus_gpl951xx_soc.cpp @@ -585,6 +585,8 @@ void generalplus_gpl951xx_device::gpspi_direct_internal_map(address_map& map) // 7c00 to 7cff - Audio // 7e00 to 7eff - Audio + // 8000 - 8fff internal boot ROM (same on all devices of the same type, not OTP) + map(0x009000, 0x3fffff).rom().region("spidirect", 0); } From f9518a4463a2e6f8eb132b6c96142da3777a212a Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 16:37:08 +0100 Subject: [PATCH 26/53] GPAC500 register list (for reference when trying to split this properly) --- .../machine/generalplus_gpl16250_soc.cpp | 318 +++++++++++++++++- 1 file changed, 316 insertions(+), 2 deletions(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index 62b8f1aac1007..c8d37e024ff56 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -3,12 +3,14 @@ /***************************************************************************** GPL16220A - 320x240 output, 16K words internal RAM - GPL16230A - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support - GPL16240VA (GPAC500?) - adds 640x480 output + GPL16230A (GPAC500?) - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support + GPL16240VA - adds 640x480 output GPL16250VA (GPAC800?) - adds '3D' sprite mode, die is marked 'GCM394' on some chips + The GPAC500 / GPAC800 might be slightly customized rather than direct rebadgings + **********************************************************************/ #include "emu.h" @@ -796,6 +798,318 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) } } +// GPAC500 register list + +// 7000 - Tx3_X_Position +// 7001 - Tx3_Y_Position +// 7002 - Tx3_X_Offset +// 7003 - Tx3_Y_Offset +// 7004 - Tx3_Attribute +// 7005 - Tx3_Control +// 7006 - Tx3_N_PTR +// 7007 - Tx3_A_PTR +// 7008 - Tx4_X_Position +// 7009 - Tx4_Y_Position +// 700a - Tx4_X_Offset +// 700b - Tx4_Y_Offset +// 700c - Tx4_Attribute +// 700d - Tx4_Control +// 700e - Tx4_N_PTR +// 700f - Tx4_A_PTR +// 7010 - Tx1_X_Position +// 7011 - Tx1_Y_Position +// 7012 - Tx1_Attribute +// 7013 - Tx1_Control +// 7014 - Tx1_N_PTR +// 7015 - Tx1_A_PTR +// 7016 - Tx2_X_Position +// 7017 - Tx2_Y_Position +// 7018 - Tx2_Attribute +// 7019 - Tx2_Control +// 701a - Tx2_N_PTR +// 701b - Tx2_A_PTR +// 701c - VComValue +// 701d - VComOffset +// 701e - VComStep +// 701f +// 7020 - Segment_Tx1 +// 7021 - Segment_Tx2 +// 7022 - Segment_sp +// 7023 - Segment_Tx3 +// 7024 - Segment_Tx4 +// 7025 +// 7026 +// 7027 +// 7028 - Tx4_Cosine +// 7029 - Tx4_Sine +// 702a - Blending +// 702b - Segment_Tx1H +// 702c - Segment_Tx2H +// 702d - Segment_spH +// 702e - Segment_Tx3H +// 702f - Segment_Tx4H +// 7030 - Fade_Control +// 7031 +// 7032 +// 7033 +// 7034 +// 7035 +// 7036 - IRQTMV +// 7037 - IRQTMH +// 7038 - Line_Counter +// 7039 - LightPen_Control +// 703a - Palette_Control +// 703b +// 703c +// 703d +// 703e - LPHPosition +// 703f - LPVPosition +// 7040 +// 7041 +// 7042 - SControl + +// 7062 - PPU_IRQ_EN +// 7063 - PPU_IRQ_Status + +// 7070 - SPDMA_Source +// 7071 - SPDMA_Target +// 7072 - SPDMA_Number +// 7073 - HB_Ctrl +// 7074 - HB_GO + +// 7078 - FBI_Addr +// 7079 - FBI_AddrH +// 707a - FBO_AddrL +// 707b - FBO_AddrH +// 707c - FB_PPU_GO +// 707d - BLD_Color +// 707e - PPU_RAM_Bank +// 707f - PPU_Enable + +// 70b0 - Tx1_AttributeH +// 70b1 - Tx2_AttributeH +// 70b2 - Tx3_AttributeH +// 70b3 - Tx4_AttributeH +// 70b4 - Tx1_N_PTRH +// 70b5 - Tx1_A_PTRH +// 70b6 - Tx2_N_PTRH +// 70b7 - Tx2_A_PTRH +// 70b8 - Tx3_N_PTRH +// 70b9 - Tx3_A_PTRH +// 70ba - Tx4_N_PTRH +// 70bb - Tx4_A_PTRH +// +// 70d8 - BLD_Enable + +// 70e0 - Random0 +// 70e1 - Random1 + +// 7100 to 71ff - Tx_Hvoffset +// 7200 to 72ff - HCMValue +// 7300 to 73ff - Palette0 / Palette1 / Palette2 / Palette3 (4 banks) +// 7400 to 77ff - Spriteram (2 banks) (one bank is 7400-77ff, other bank is 7400-74ff) + +// 7800 - BodyID + +// 7803 - SYS_CTRL +// 7804 - CLK_Ctrl0 +// 7805 - CLK_Ctrl1 +// 7806 - Reset_Flag +// 7807 - Clock_Ctrl +// 7808 - LVR_Ctrl +// 780a - Watchdog_Ctrl +// 780b - Watchdog_Clear +// 780c - WAIT +// 780d - HALT +// 780e - SLEEP +// 780f - Power_State + +// 7810 - BankSwitch_Ctrl + +// 7817 - PLLChange +// 7818 - PLLCLKWait +// 7819 - Cache_Ctrl +// 781a - Cache_HitRate + +// 781f - IO_SR_SMT + +// 7820 - MCS0_Ctrl +// 7821 - MCS1_Ctrl +// 7822 - MCS2_Ctrl +// 7823 - MCS3_Ctrl +// 7824 - MCS4_Ctrl +// 7825 - PSRAM_Ctrl +// 7826 - MCS_BYTE_SEL +// 7827 - MCS3_WETimingCtrl +// 7828 - MCS4_WETimingCtrl +// 7829 - MCS3_RDTimingCtrl +// 782a - MCS4_RDTimingCtrl +// 782b - MCS3_TimingCtrl +// 782c - MCS4_TimingCtrl +// 782d - RAW_WAR +// 782e - NOR_WHold + +// 7835 - MCS0_Page +// 7836 - MCS1_Page +// 7837 - MCS2_Page +// 7838 - MCS3_Page +// 7839 - MCS4_Page + +// 7840 - Mem_Ctrl +// 7841 - Addr_Ctrl + +// 787e - MCS_Drv +// 787f - MCS_Dly + +// 7888 - MEM_Drv +// 7889 - MEM_Dly0 +// 788a - MEM_Dly1 +// 788b - MEM_Dly2 +// 788c - MEM_Dly3 +// 788d - MEM_Dly4 +// 788e - MEM_Dly5 +// 788f - MEM_Dly6 + +// 78a0 - INT_Status1 +// 78a1 - INT_Status2 + +// 78a3 - INT_Status3 +// 78a4 - INT_Priority1 +// 78a5 - INT_Priority2 +// 78a6 - INT_Priority3 + +// 78a8 - MINT_Ctrl + +// 78b0 - TimeBaseA_Ctrl +// 78b1 - TimeBaseB_Ctrl +// 78b2 - TimeBaseC_Ctrl +// +// 78b8 - TimeBase_Reset + +// 78c0 - TimerA_Ctrl +// 78c1 - TimerA_CCCtrl +// 78c2 - TimerA_Preload +// 78c3 - TimerA_CCReg +// 78c4 - TimerA_UpCount + +// 78c8 - TimerB_Ctrl +// 78c9 - TimerB_CCCtrl +// 78ca - TimerB_Preload +// 78cb - TimerB_CCReg +// 78cc - TimerB_UpCount + +// 78d0 - TimerC_Ctrl +// 78d1 - TimerC_CCCtrl +// 78d2 - TimerC_Preload +// 78d3 - TimerC_CCReg +// 78d4 - TimerC_UpCount + +// 78d8 - TimerD_Ctrl +// 78da - TimerD_Preload +// 78dc - TimerD_UpCount + +// 78e0 - TimerE_Ctrl +// 78e2 - TimerE_Preload +// 78e4 - TimerE_UpCount +// +// 78e8 - TimerF_Ctrl +// 78ea - TimerF_Preload +// 78ec - TimerF_UpCount + +// 78f0 - CHA_Ctrl +// 78f1 - CHA_Data +// 78f2 - CHA_FIFO + +// 78f8 - CHB_Ctrl +// 78f9 - CHB_Data +// 78fa - CHB_FIFO +// 78fb - DAC_PGA + +// 78ff - IISEN + +// 7920 - Second +// 7921 - Minute +// 7922 - Hour +// 7924 - Alarm_Second +// 7925 - Alarm_Minute +// 7926 - Alarm_Hour + +// 7934 - RTC_Ctrl +// 7935 - RTC_INT_Status +// 7936 - RTC_INT_Ctrl +// 7937 - RTC_Busy + +// 7940 - SPI_Ctrl +// 7941 - SPI_TXStatus +// 7942 - SPI_TXData +// 7943 - SPI_RXStatus +// 7944 - SPI_RXData +// 7945 - SPI_Misc + +// 79a0 - DividendH +// 79a1 - Dividend +// 79a2 - DivisorH +// 79a3 - Divisor +// 79a4 - QuotientH +// 79a5 - Quotient +// 79a6 - RemainderH +// 79a7 - Remainder +// 79a8 - Divider_Status + +// 79e0 - SD2_DataTX +// 79e1 - SD2_DataRX +// 79e2 - SD2_CMD +// 79e3 - SD2_ArgL +// 79e4 - SD2_ArgH +// 79e5 - SD2_RespL +// 79e6 - SD2_RespH +// 79e7 - SD2_Status +// 79e8 - SD2_Ctrl +// 79e9 - SD2_BLKLEN +// 79ea - SD2_INT + +// 7a80 - DMA_Ctrl0 +// 7a81 - DMA_SRC_AddrL0 +// 7a82 - DMA_TAR_AddrL0 +// 7a83 - DMA_TCountL0 +// 7a84 - DMA_SRC_AddrH0 +// 7a85 - DMA_TAR_AddrH0 +// 7a86 - DMA_TCountH0 +// 7a87 - DMA_MISC0 +// 7a88 - DMA_Ctrl1 +// 7a89 - DMA_SRC_AddrL1 +// 7a8a - DMA_TAR_AddrL1 +// 7a8b - DMA_TCountL1 +// 7a8c - DMA_SRC_AddrH1 +// 7a8d - DMA_TAR_AddrH1 +// 7a8e - DMA_TCountH1 +// 7a8f - DMA_MISC1 + +// 7ab0 - DMA_SPRISIZE0 +// 7ab1 - DMA_SPRISIZE1 +// +// 7abd - DMA_LineLength +// 7abe - DMA_SS +// 7abf - DMA_INT +// +// 7af0 - Byte_Swap +// 7af1 - Nibble_Swap +// 7af2 - TwoBit_Swap +// 7af3 - Bit_Reverse +// +// 7b00 to 7b9f - sound channels 0-15 +// 7ba5 - SPU_CtrPW +// 7bb2 - SPU_CtrPWaveOutL +// 7bb3 - SPU_CtrPWaveOutR +// 7bb6 - SPU_CtrChToneRelease_H +// +// 7c00 - 7cff Sound +// 7e00 - 7eff Sound + + +// GPAC900 register list +// TODO: + void sunplus_gcm394_base_device::base_internal_map(address_map &map) { map(0x000000, 0x006fff).ram().share("mainram"); From 0fbcc058989cd18d745393ea9243171359abad60 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 16:47:50 +0100 Subject: [PATCH 27/53] note some other products in this family --- .../machine/generalplus_gpl16250_soc.cpp | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index c8d37e024ff56..a89a530c751d0 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -3,9 +3,17 @@ /***************************************************************************** GPL16220A - 320x240 output, 16K words internal RAM - GPL16230A (GPAC500?) - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support - GPL16240VA - adds 640x480 output - GPL16250VA (GPAC800?) - adds '3D' sprite mode, + GPL16230A (GPAC500A) - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support + GPL16240VA - adds 640x480 output (V = VGA support?) + GPL16250VA (GPAC800A) - adds '3D' sprite mode, + + there is also the 'B' series + these only have 12K words RAM? but have the extra maths unit at 0x79A0? + + GPL16218B + GPL16238B (this could be GPAC500B) + GPL16248VB + GPL16258VB (this could be GPAC800B) die is marked 'GCM394' on some chips @@ -798,7 +806,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) } } -// GPAC500 register list +// GPAC500B register list // 7000 - Tx3_X_Position // 7001 - Tx3_Y_Position @@ -1107,7 +1115,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7e00 - 7eff Sound -// GPAC900 register list +// GPAC800A register list // TODO: void sunplus_gcm394_base_device::base_internal_map(address_map &map) From f0ea261c35dffb52c2e62690ab6a5fc921645b87 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 18:22:30 +0100 Subject: [PATCH 28/53] missed a few --- .../machine/generalplus_gpl16250_soc.cpp | 37 +++++++++++++++++-- 1 file changed, 34 insertions(+), 3 deletions(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index a89a530c751d0..c43a6838c41f5 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -868,7 +868,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7039 - LightPen_Control // 703a - Palette_Control // 703b -// 703c +// 703c - TV_Control // 703d // 703e - LPHPosition // 703f - LPVPosition @@ -876,8 +876,29 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7041 // 7042 - SControl -// 7062 - PPU_IRQ_EN -// 7063 - PPU_IRQ_Status +// 7050 - TFT_Ctrl +// 7051 - TFT_V_Width or STN_COM_Clip +// 7052 - TFT_VSync_Setup +// 7053 - TFT_V_Start +// 7054 - TFT_V_End +// 7055 - TFT_H_Width +// 7056 - TFT_HSync_Setup +// 7057 - TFT_H_ Start +// 7058 - TFT_H_ End +// 7059 - TFT_RGB_Ctrl +// 705a - TFT_Status +// 705b - TFT_MemMode_WriteCMD +// 705c - TFT_MemMode_ReadCMD + +// 705f - STN_Ctrl1 + +// 7062 - PPU_IRQ_EN or TFT_INT_EN +// 7063 - PPU_IRQ_Status or TFT_INT_CLR + +// 706c - TFT_V_Show_Start +// 706d - TFT_V_Show_End +// 706e - TFT_H_Show_Start +// 706f - TFT_H_Show_End // 7070 - SPDMA_Source // 7071 - SPDMA_Target @@ -894,6 +915,16 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 707e - PPU_RAM_Bank // 707f - PPU_Enable +// 7080 - TV_Saturation or STN_SEG +// 7081 - TV_Hue or STN_COM +// 7082 - TV_Brightness or STN_PIC_COM +// 7083 - TV_Sharpness or STN_CPWAIT +// 7084 - TV_Y_Gain or STN_Ctrl2 +// 7085 - TV_Y_Delay or STN_GTG_SEG +// 7086 - TV_V_Position or STN_GTG_COM +// 7087 - TV_H_Position or STN_SEG_Clip +// 7088 - TV_VideoDAC +// // 70b0 - Tx1_AttributeH // 70b1 - Tx2_AttributeH // 70b2 - Tx3_AttributeH From d767eb228db8fa2a0648df5f3d918ede058eeb50 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 18:40:42 +0100 Subject: [PATCH 29/53] tidy notes a bit --- .../machine/generalplus_gpl16250_soc.cpp | 139 +++++++++++------- 1 file changed, 82 insertions(+), 57 deletions(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index c43a6838c41f5..2942c97ad16bd 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -839,15 +839,13 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 701c - VComValue // 701d - VComOffset // 701e - VComStep -// 701f +// // 7020 - Segment_Tx1 // 7021 - Segment_Tx2 // 7022 - Segment_sp // 7023 - Segment_Tx3 // 7024 - Segment_Tx4 -// 7025 -// 7026 -// 7027 +// // 7028 - Tx4_Cosine // 7029 - Tx4_Sine // 702a - Blending @@ -857,26 +855,21 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 702e - Segment_Tx3H // 702f - Segment_Tx4H // 7030 - Fade_Control -// 7031 -// 7032 -// 7033 -// 7034 -// 7035 +// // 7036 - IRQTMV // 7037 - IRQTMH // 7038 - Line_Counter // 7039 - LightPen_Control // 703a - Palette_Control -// 703b +// // 703c - TV_Control -// 703d +// // 703e - LPHPosition // 703f - LPVPosition -// 7040 -// 7041 +// // 7042 - SControl - -// 7050 - TFT_Ctrl +// +// 7050 - TFT_Ctrl (bit 0 is TFT enable, which presumable changes the mappings at 7062/7063 from PPU to TFT) // 7051 - TFT_V_Width or STN_COM_Clip // 7052 - TFT_VSync_Setup // 7053 - TFT_V_Start @@ -889,23 +882,23 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 705a - TFT_Status // 705b - TFT_MemMode_WriteCMD // 705c - TFT_MemMode_ReadCMD - -// 705f - STN_Ctrl1 - +// +// 705f - STN_Ctrl1 (bit 0 is STN enable, which presumably changes the mappings at 708x and 7051 from TV/TFT to STN regs) +// // 7062 - PPU_IRQ_EN or TFT_INT_EN // 7063 - PPU_IRQ_Status or TFT_INT_CLR - +// // 706c - TFT_V_Show_Start // 706d - TFT_V_Show_End // 706e - TFT_H_Show_Start // 706f - TFT_H_Show_End - +// // 7070 - SPDMA_Source // 7071 - SPDMA_Target // 7072 - SPDMA_Number // 7073 - HB_Ctrl // 7074 - HB_GO - +// // 7078 - FBI_Addr // 7079 - FBI_AddrH // 707a - FBO_AddrL @@ -914,7 +907,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 707d - BLD_Color // 707e - PPU_RAM_Bank // 707f - PPU_Enable - +// // 7080 - TV_Saturation or STN_SEG // 7081 - TV_Hue or STN_COM // 7082 - TV_Brightness or STN_PIC_COM @@ -939,17 +932,17 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 70bb - Tx4_A_PTRH // // 70d8 - BLD_Enable - +// // 70e0 - Random0 // 70e1 - Random1 - +// // 7100 to 71ff - Tx_Hvoffset // 7200 to 72ff - HCMValue // 7300 to 73ff - Palette0 / Palette1 / Palette2 / Palette3 (4 banks) // 7400 to 77ff - Spriteram (2 banks) (one bank is 7400-77ff, other bank is 7400-74ff) - +// // 7800 - BodyID - +// // 7803 - SYS_CTRL // 7804 - CLK_Ctrl0 // 7805 - CLK_Ctrl1 @@ -962,16 +955,16 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 780d - HALT // 780e - SLEEP // 780f - Power_State - +// // 7810 - BankSwitch_Ctrl - +// // 7817 - PLLChange // 7818 - PLLCLKWait // 7819 - Cache_Ctrl // 781a - Cache_HitRate - +// // 781f - IO_SR_SMT - +// // 7820 - MCS0_Ctrl // 7821 - MCS1_Ctrl // 7822 - MCS2_Ctrl @@ -987,19 +980,19 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 782c - MCS4_TimingCtrl // 782d - RAW_WAR // 782e - NOR_WHold - +// // 7835 - MCS0_Page // 7836 - MCS1_Page // 7837 - MCS2_Page // 7838 - MCS3_Page // 7839 - MCS4_Page - +// // 7840 - Mem_Ctrl // 7841 - Addr_Ctrl - +// // 787e - MCS_Drv // 787f - MCS_Dly - +// // 7888 - MEM_Drv // 7889 - MEM_Dly0 // 788a - MEM_Dly1 @@ -1008,45 +1001,45 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 788d - MEM_Dly4 // 788e - MEM_Dly5 // 788f - MEM_Dly6 - +// // 78a0 - INT_Status1 // 78a1 - INT_Status2 - +// // 78a3 - INT_Status3 // 78a4 - INT_Priority1 // 78a5 - INT_Priority2 // 78a6 - INT_Priority3 - +// // 78a8 - MINT_Ctrl - +// // 78b0 - TimeBaseA_Ctrl // 78b1 - TimeBaseB_Ctrl // 78b2 - TimeBaseC_Ctrl // // 78b8 - TimeBase_Reset - +// // 78c0 - TimerA_Ctrl // 78c1 - TimerA_CCCtrl // 78c2 - TimerA_Preload // 78c3 - TimerA_CCReg // 78c4 - TimerA_UpCount - +// // 78c8 - TimerB_Ctrl // 78c9 - TimerB_CCCtrl // 78ca - TimerB_Preload // 78cb - TimerB_CCReg // 78cc - TimerB_UpCount - +// // 78d0 - TimerC_Ctrl // 78d1 - TimerC_CCCtrl // 78d2 - TimerC_Preload // 78d3 - TimerC_CCReg // 78d4 - TimerC_UpCount - +// // 78d8 - TimerD_Ctrl // 78da - TimerD_Preload // 78dc - TimerD_UpCount - +// // 78e0 - TimerE_Ctrl // 78e2 - TimerE_Preload // 78e4 - TimerE_UpCount @@ -1054,37 +1047,37 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 78e8 - TimerF_Ctrl // 78ea - TimerF_Preload // 78ec - TimerF_UpCount - +// // 78f0 - CHA_Ctrl // 78f1 - CHA_Data // 78f2 - CHA_FIFO - +// // 78f8 - CHB_Ctrl // 78f9 - CHB_Data // 78fa - CHB_FIFO // 78fb - DAC_PGA - +// // 78ff - IISEN - +// // 7920 - Second // 7921 - Minute // 7922 - Hour // 7924 - Alarm_Second // 7925 - Alarm_Minute // 7926 - Alarm_Hour - +// // 7934 - RTC_Ctrl // 7935 - RTC_INT_Status // 7936 - RTC_INT_Ctrl // 7937 - RTC_Busy - +// // 7940 - SPI_Ctrl // 7941 - SPI_TXStatus // 7942 - SPI_TXData // 7943 - SPI_RXStatus // 7944 - SPI_RXData // 7945 - SPI_Misc - +// // 79a0 - DividendH // 79a1 - Dividend // 79a2 - DivisorH @@ -1094,7 +1087,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 79a6 - RemainderH // 79a7 - Remainder // 79a8 - Divider_Status - +// // 79e0 - SD2_DataTX // 79e1 - SD2_DataRX // 79e2 - SD2_CMD @@ -1106,7 +1099,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 79e8 - SD2_Ctrl // 79e9 - SD2_BLKLEN // 79ea - SD2_INT - +// // 7a80 - DMA_Ctrl0 // 7a81 - DMA_SRC_AddrL0 // 7a82 - DMA_TAR_AddrL0 @@ -1123,7 +1116,7 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7a8d - DMA_TAR_AddrH1 // 7a8e - DMA_TCountH1 // 7a8f - DMA_MISC1 - +// // 7ab0 - DMA_SPRISIZE0 // 7ab1 - DMA_SPRISIZE1 // @@ -1136,16 +1129,48 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7af2 - TwoBit_Swap // 7af3 - Bit_Reverse // -// 7b00 to 7b9f - sound channels 0-15 +// (Sound) +// 7b80 - Channel Enable +// 7b81 - Main volume +// 7b82 - Channel FIQ Enable +// 7b83 - Channel FIQ Status +// 7b84 - Beat base counter +// 7b85 - Beat counter +// 7b86 - Envelope interval select (Ch 3-0) +// 7b87 - Envelope interval select (Ch 7-4) +// 7b88 - Envelope interval select (Ch 11-8) +// 7b89 - Envelope interval select (Ch 15-12) +// 7b8a - Envelope fast ramp down +// 7b8b - Stop channel status +// +// 7b8d - Control Flags +// 7b8e - Compressor Control +// 7b8f - Channel status +// 7b90 - Left channel mixer input +// 7b91 - Right channel mixer input +// 7b92 - Left channel mixer output +// 7b93 - Right channel mixer output +// 7b94 - Channel Repeat Enable control +// 7b95 - Channel Env Mode +// 7b96 - Channel Tone Release Control +// 7b97 - Channel Env Irq Status +// 7b98 - Channel Pitch Bend Enable +// +// 7b9a - Attack/Release Time Control +// +// 7b9f - Wave Table Bank Address +// // 7ba5 - SPU_CtrPW +// // 7bb2 - SPU_CtrPWaveOutL // 7bb3 - SPU_CtrPWaveOutR +// // 7bb6 - SPU_CtrChToneRelease_H // -// 7c00 - 7cff Sound -// 7e00 - 7eff Sound - +// 7c00 - 7cff Sound Attribute +// 7e00 - 7eff Sound Phase +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // GPAC800A register list // TODO: From eb52fb438aec19834d5c76184e24fcc13b25871f Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 19:27:11 +0100 Subject: [PATCH 30/53] start documenting GPAC800 registers --- .../machine/generalplus_gpl16250_soc.cpp | 112 +++++++++++++++++- 1 file changed, 111 insertions(+), 1 deletion(-) diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl16250_soc.cpp index 2942c97ad16bd..89be506fd792f 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl16250_soc.cpp @@ -1172,7 +1172,117 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // GPAC800A register list -// TODO: +// +// 7000 - Tx3_X_Position +// 7001 - Tx3_Y_Position +// 7002 - Tx3_X_Offset +// 7003 - Tx3_Y_Offset +// 7004 - Tx3_Attribute +// 7005 - Tx3_Control +// 7006 - Tx3_N_PTR +// 7007 - Tx3_A_PTR +// 7008 - Tx4_X_Position +// 7009 - Tx4_Y_Position +// 700a - Tx4_X_Offset +// 700b - Tx4_Y_Offset +// 700c - Tx4_Attribute +// 700d - Tx4_Control +// 700e - Tx4_N_PTR +// 700f - Tx4_A_PTR +// 7010 - Tx1_X_Position +// 7011 - Tx1_Y_Position +// 7012 - Tx1_Attribute +// 7013 - Tx1_Control +// 7014 - Tx1_N_PTR +// 7015 - Tx1_A_PTR +// 7016 - Tx2_X_Position +// 7017 - Tx2_Y_Position +// 7018 - Tx2_Attribute +// 7019 - Tx2_Control +// 701a - Tx2_N_PTR +// 701b - Tx2_A_PTR +// 701c - VComValue +// 701d - VComOffset +// 701e - VComStep +// 701f +// 7020 - Segment_Tx1 +// 7021 - Segment_Tx2 +// 7022 - Segment_sp +// 7023 - Segment_Tx3 +// 7024 - Segment_Tx4 +// +// 7028 - Tx4_Cosine +// 7029 - Tx4_Sine +// 702a - Blending +// 702b - Segment_Tx1H +// 702c - Segment_Tx2H +// 702d - Segment_spH +// 702e - Segment_Tx3H +// 702f - Segment_Tx4H +// 7030 - Fade_Control +// +// 7036 - IRQTMV +// 7037 - IRQTMH +// 7038 - Line_Counter +// 7039 - LightPen_Control +// 703a - Palette_Control +// +// 703e - LPHPosition +// 703f - LPVPosition +// +// 7042 - SControl +// +// 7062 - PPU_IRQ_EN +// 7063 - PPU_IRQ_Status +// +// 7070 - SPDMA_Source +// 7071 - SPDMA_Target +// 7072 - SPDMA_Number +// +// 7078 - FBI_AddrL +// 7079 - FBI_AddrH +// 707a - FBO_AddrL +// 707b - FBO_AddrH +// 707c - FB_PPU_GO +// 707d - BLD_Color +// 707e - PPU_RAM_Bank +// 707f - PPU_Enable +// +// 7090 - TG_CTRL1 +// 7091 - TG_CTRL2 +// 7092 - TG_HLSTART +// 7093 - TG_HEND +// 7094 - TG_VL0START +// 7095 - MD_FBADDRL +// 7096 - TG_VEND +// 7097 - TG_HSTART +// 7098 - MD_RGBL +// 7099 - SEN_CTRL +// 709a - TG_BSUPPER +// 709b - TG_BSLOWER +// 709c - MD_RGBH +// 709d - MD_CR +// 709e - TG_FBSADDRL +// 709f - TG_FBSADDRH +// 70a0 - TG_VL1START +// 70a1 - TG_H_WIDTH +// 70a2 - TG_V_WIDTH +// 70a3 - TG_CUTSTART +// 70a4 - TG_CUTWIDTH +// 70a5 - TG_VSTART +// 70a6 - MD_FBADDRH +// 70a7 - TG_H_RATIO +// 70a8 - TG_V_RATIO +// +// 7100 to 71ff - Tx_Hvoffset (when PPU_RAM_BANK is 0) +// 7200 to 72ff - HCMValue (when PPU_RAM_BANK is 0) +// 7100 to 72ff - Tx3_Cos / Tx3_Sin (when PPU_RAM_BANK is 1) +// +// 7300 to 73ff - Palette0 / Palette1 / Palette2 / Palette3 (3 banks using PAL_RAM_SEL) +// +// 7400 to 77ff - Standard sprite list (when PPU_RAM_BANK is 0) +// 7400 to 74ff - Sprite0_Attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is disabled) +// 7400 to 77ff - 3D sprite attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is enabled) void sunplus_gcm394_base_device::base_internal_map(address_map &map) { From 1729375c2f6a3ea07174801ce59ffac44b1f58f5 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 21:30:35 +0100 Subject: [PATCH 31/53] rename some stuff --- scripts/src/machine.lua | 11 +++++----- ...0_soc.cpp => generalplus_gpl162xx_soc.cpp} | 22 ++++++++++++++++++- ...16250_soc.h => generalplus_gpl162xx_soc.h} | 2 +- ...cpp => generalplus_gpl162xx_soc_video.cpp} | 2 +- ...deo.h => generalplus_gpl162xx_soc_video.h} | 0 .../machine/generalplus_gpl951xx_soc.h | 8 +------ src/mame/tvgames/generalplus_gpl16250_nand.h | 2 +- .../tvgames/generalplus_gpl16250_romram.h | 2 +- 8 files changed, 32 insertions(+), 17 deletions(-) rename src/devices/machine/{generalplus_gpl16250_soc.cpp => generalplus_gpl162xx_soc.cpp} (99%) rename src/devices/machine/{generalplus_gpl16250_soc.h => generalplus_gpl162xx_soc.h} (99%) rename src/devices/machine/{generalplus_gpl16250_soc_video.cpp => generalplus_gpl162xx_soc_video.cpp} (99%) rename src/devices/machine/{generalplus_gpl16250_soc_video.h => generalplus_gpl162xx_soc_video.h} (100%) diff --git a/scripts/src/machine.lua b/scripts/src/machine.lua index e3e52b90e13a1..0408d52851586 100644 --- a/scripts/src/machine.lua +++ b/scripts/src/machine.lua @@ -3438,7 +3438,8 @@ end -- --@src/devices/machine/spg2xx.h,MACHINES["SPG2XX"] = true --@src/devices/machine/spg110.h,MACHINES["SPG2XX"] = true ---@src/devices/machine/generalplus_gpl16250soc.h,MACHINES["SPG2XX"] = true +--@src/devices/machine/generalplus_gpl162xx_soc.h,MACHINES["SPG2XX"] = true +--@src/devices/machine/generalplus_gpl951xx_soc.h,MACHINES["SPG2XX"] = true --------------------------------------------------- if (MACHINES["SPG2XX"]~=null) then @@ -3457,10 +3458,10 @@ if (MACHINES["SPG2XX"]~=null) then MAME_DIR .. "src/devices/machine/spg110.h", MAME_DIR .. "src/devices/machine/spg110_video.cpp", MAME_DIR .. "src/devices/machine/spg110_video.h", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc.cpp", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc.h", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc_video.cpp", - MAME_DIR .. "src/devices/machine/generalplus_gpl16250_soc_video.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc_video.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc_video.h", MAME_DIR .. "src/devices/machine/generalplus_gpl951xx_soc.cpp", MAME_DIR .. "src/devices/machine/generalplus_gpl951xx_soc.h", MAME_DIR .. "src/devices/machine/spg_renderer.cpp", diff --git a/src/devices/machine/generalplus_gpl16250_soc.cpp b/src/devices/machine/generalplus_gpl162xx_soc.cpp similarity index 99% rename from src/devices/machine/generalplus_gpl16250_soc.cpp rename to src/devices/machine/generalplus_gpl162xx_soc.cpp index 89be506fd792f..8edace59f607d 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.cpp +++ b/src/devices/machine/generalplus_gpl162xx_soc.cpp @@ -22,7 +22,7 @@ **********************************************************************/ #include "emu.h" -#include "generalplus_gpl16250_soc.h" +#include "generalplus_gpl162xx_soc.h" #define LOG_GCM394_SPI (1U << 5) @@ -1283,6 +1283,26 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7400 to 77ff - Standard sprite list (when PPU_RAM_BANK is 0) // 7400 to 74ff - Sprite0_Attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is disabled) // 7400 to 77ff - 3D sprite attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is enabled) +// +// 7800 - P_BodyID +// 7803 - P_SYS_CTRL +// 7804 - P_CLK_Ctrl0 +// 7805 - P_CLK_Ctrl1 +// 7806 - P_Reset_Flag +// 7807 - P_Clock_Ctrl +// 7808 - P_LVR_Ctrl +// 780a - P_Watchdog_Ctrl +// 780b - P_Watchdog_Clear +// 780c - P_WAIT +// 780d - P_HALT +// 780e - P_SLEEP +// 780f - P_Power_State + +// 7817 - P_PLLN +// 7818 - P_PLLWiatCLK +// 7819 - P_Cache_Ctrl +// 781a - P_Cache_HitRate +// 781f - P_IO_SR_SMT void sunplus_gcm394_base_device::base_internal_map(address_map &map) { diff --git a/src/devices/machine/generalplus_gpl16250_soc.h b/src/devices/machine/generalplus_gpl162xx_soc.h similarity index 99% rename from src/devices/machine/generalplus_gpl16250_soc.h rename to src/devices/machine/generalplus_gpl162xx_soc.h index ac5e50ec8904b..27784ccd78c69 100644 --- a/src/devices/machine/generalplus_gpl16250_soc.h +++ b/src/devices/machine/generalplus_gpl162xx_soc.h @@ -14,7 +14,7 @@ #include "cpu/unsp/unsp.h" #include "screen.h" #include "emupal.h" -#include "generalplus_gpl16250_soc_video.h" +#include "generalplus_gpl162xx_soc_video.h" #include "spg2xx_audio.h" typedef device_delegate sunplus_gcm394_cs_callback_device; diff --git a/src/devices/machine/generalplus_gpl16250_soc_video.cpp b/src/devices/machine/generalplus_gpl162xx_soc_video.cpp similarity index 99% rename from src/devices/machine/generalplus_gpl16250_soc_video.cpp rename to src/devices/machine/generalplus_gpl162xx_soc_video.cpp index 8768b4ea3cf58..cd136ab279fc9 100644 --- a/src/devices/machine/generalplus_gpl16250_soc_video.cpp +++ b/src/devices/machine/generalplus_gpl162xx_soc_video.cpp @@ -10,7 +10,7 @@ #include "emu.h" -#include "generalplus_gpl16250_soc_video.h" +#include "generalplus_gpl162xx_soc_video.h" DEFINE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device, "gcm394_video", "GeneralPlus GPL16250 System-on-a-Chip (Video)") diff --git a/src/devices/machine/generalplus_gpl16250_soc_video.h b/src/devices/machine/generalplus_gpl162xx_soc_video.h similarity index 100% rename from src/devices/machine/generalplus_gpl16250_soc_video.h rename to src/devices/machine/generalplus_gpl162xx_soc_video.h diff --git a/src/devices/machine/generalplus_gpl951xx_soc.h b/src/devices/machine/generalplus_gpl951xx_soc.h index 0f69dfcd827a6..1ebdb4a03e377 100644 --- a/src/devices/machine/generalplus_gpl951xx_soc.h +++ b/src/devices/machine/generalplus_gpl951xx_soc.h @@ -6,13 +6,7 @@ #pragma once -#include "cpu/unsp/unsp.h" -#include "screen.h" -#include "emupal.h" -#include "generalplus_gpl16250_soc_video.h" -#include "spg2xx_audio.h" - -#include "generalplus_gpl16250_soc.h" +#include "generalplus_gpl162xx_soc.h" class generalplus_gpl951xx_device : public sunplus_gcm394_base_device { diff --git a/src/mame/tvgames/generalplus_gpl16250_nand.h b/src/mame/tvgames/generalplus_gpl16250_nand.h index 647e36176a0a3..7673a8ef7e50c 100644 --- a/src/mame/tvgames/generalplus_gpl16250_nand.h +++ b/src/mame/tvgames/generalplus_gpl16250_nand.h @@ -6,7 +6,7 @@ #pragma once #include "generalplus_gpl16250.h" -#include "machine/generalplus_gpl16250_soc.h" +#include "machine/generalplus_gpl162xx_soc.h" #include "generalplus_gpl16250_m.h" #include "bus/generic/slot.h" #include "bus/generic/carts.h" diff --git a/src/mame/tvgames/generalplus_gpl16250_romram.h b/src/mame/tvgames/generalplus_gpl16250_romram.h index ca7ce96695c58..23ea05a9517ab 100644 --- a/src/mame/tvgames/generalplus_gpl16250_romram.h +++ b/src/mame/tvgames/generalplus_gpl16250_romram.h @@ -6,7 +6,7 @@ #pragma once #include "generalplus_gpl16250.h" -#include "machine/generalplus_gpl16250_soc.h" +#include "machine/generalplus_gpl162xx_soc.h" #include "generalplus_gpl16250_m.h" #include "bus/generic/slot.h" #include "bus/generic/carts.h" From 4c5eb4ff7171c90b6a310a469316e08d2fb1c631 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 21:50:32 +0100 Subject: [PATCH 32/53] move some stuff around --- scripts/src/machine.lua | 3 + .../machine/generalplus_gpl1625x_soc.cpp | 492 ++++++++++++++++++ .../machine/generalplus_gpl1625x_soc.h | 94 ++++ .../machine/generalplus_gpl162xx_soc.cpp | 489 +---------------- .../machine/generalplus_gpl162xx_soc.h | 80 --- src/mame/tvgames/generalplus_gpl16250.h | 1 + src/mame/tvgames/generalplus_gpl16250_nand.h | 2 +- 7 files changed, 593 insertions(+), 568 deletions(-) create mode 100644 src/devices/machine/generalplus_gpl1625x_soc.cpp create mode 100644 src/devices/machine/generalplus_gpl1625x_soc.h diff --git a/scripts/src/machine.lua b/scripts/src/machine.lua index 0408d52851586..3225a8cec3fda 100644 --- a/scripts/src/machine.lua +++ b/scripts/src/machine.lua @@ -3439,6 +3439,7 @@ end --@src/devices/machine/spg2xx.h,MACHINES["SPG2XX"] = true --@src/devices/machine/spg110.h,MACHINES["SPG2XX"] = true --@src/devices/machine/generalplus_gpl162xx_soc.h,MACHINES["SPG2XX"] = true +--@src/devices/machine/generalplus_gpl1625x_soc.h,MACHINES["SPG2XX"] = true --@src/devices/machine/generalplus_gpl951xx_soc.h,MACHINES["SPG2XX"] = true --------------------------------------------------- @@ -3460,6 +3461,8 @@ if (MACHINES["SPG2XX"]~=null) then MAME_DIR .. "src/devices/machine/spg110_video.h", MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc.cpp", MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc.h", + MAME_DIR .. "src/devices/machine/generalplus_gpl1625x_soc.cpp", + MAME_DIR .. "src/devices/machine/generalplus_gpl1625x_soc.h", MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc_video.cpp", MAME_DIR .. "src/devices/machine/generalplus_gpl162xx_soc_video.h", MAME_DIR .. "src/devices/machine/generalplus_gpl951xx_soc.cpp", diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp new file mode 100644 index 0000000000000..a53082c80e907 --- /dev/null +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -0,0 +1,492 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood + +#include "emu.h" +#include "generalplus_gpl1625x_soc.h" + +//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// GPAC800A register list +// +// 7000 - Tx3_X_Position +// 7001 - Tx3_Y_Position +// 7002 - Tx3_X_Offset +// 7003 - Tx3_Y_Offset +// 7004 - Tx3_Attribute +// 7005 - Tx3_Control +// 7006 - Tx3_N_PTR +// 7007 - Tx3_A_PTR +// 7008 - Tx4_X_Position +// 7009 - Tx4_Y_Position +// 700a - Tx4_X_Offset +// 700b - Tx4_Y_Offset +// 700c - Tx4_Attribute +// 700d - Tx4_Control +// 700e - Tx4_N_PTR +// 700f - Tx4_A_PTR +// 7010 - Tx1_X_Position +// 7011 - Tx1_Y_Position +// 7012 - Tx1_Attribute +// 7013 - Tx1_Control +// 7014 - Tx1_N_PTR +// 7015 - Tx1_A_PTR +// 7016 - Tx2_X_Position +// 7017 - Tx2_Y_Position +// 7018 - Tx2_Attribute +// 7019 - Tx2_Control +// 701a - Tx2_N_PTR +// 701b - Tx2_A_PTR +// 701c - VComValue +// 701d - VComOffset +// 701e - VComStep +// 701f +// 7020 - Segment_Tx1 +// 7021 - Segment_Tx2 +// 7022 - Segment_sp +// 7023 - Segment_Tx3 +// 7024 - Segment_Tx4 +// +// 7028 - Tx4_Cosine +// 7029 - Tx4_Sine +// 702a - Blending +// 702b - Segment_Tx1H +// 702c - Segment_Tx2H +// 702d - Segment_spH +// 702e - Segment_Tx3H +// 702f - Segment_Tx4H +// 7030 - Fade_Control +// +// 7036 - IRQTMV +// 7037 - IRQTMH +// 7038 - Line_Counter +// 7039 - LightPen_Control +// 703a - Palette_Control +// +// 703e - LPHPosition +// 703f - LPVPosition +// +// 7042 - SControl +// +// 7062 - PPU_IRQ_EN +// 7063 - PPU_IRQ_Status +// +// 7070 - SPDMA_Source +// 7071 - SPDMA_Target +// 7072 - SPDMA_Number +// +// 7078 - FBI_AddrL +// 7079 - FBI_AddrH +// 707a - FBO_AddrL +// 707b - FBO_AddrH +// 707c - FB_PPU_GO +// 707d - BLD_Color +// 707e - PPU_RAM_Bank +// 707f - PPU_Enable +// +// 7090 - TG_CTRL1 +// 7091 - TG_CTRL2 +// 7092 - TG_HLSTART +// 7093 - TG_HEND +// 7094 - TG_VL0START +// 7095 - MD_FBADDRL +// 7096 - TG_VEND +// 7097 - TG_HSTART +// 7098 - MD_RGBL +// 7099 - SEN_CTRL +// 709a - TG_BSUPPER +// 709b - TG_BSLOWER +// 709c - MD_RGBH +// 709d - MD_CR +// 709e - TG_FBSADDRL +// 709f - TG_FBSADDRH +// 70a0 - TG_VL1START +// 70a1 - TG_H_WIDTH +// 70a2 - TG_V_WIDTH +// 70a3 - TG_CUTSTART +// 70a4 - TG_CUTWIDTH +// 70a5 - TG_VSTART +// 70a6 - MD_FBADDRH +// 70a7 - TG_H_RATIO +// 70a8 - TG_V_RATIO +// +// 7100 to 71ff - Tx_Hvoffset (when PPU_RAM_BANK is 0) +// 7200 to 72ff - HCMValue (when PPU_RAM_BANK is 0) +// 7100 to 72ff - Tx3_Cos / Tx3_Sin (when PPU_RAM_BANK is 1) +// +// 7300 to 73ff - Palette0 / Palette1 / Palette2 / Palette3 (3 banks using PAL_RAM_SEL) +// +// 7400 to 77ff - Standard sprite list (when PPU_RAM_BANK is 0) +// 7400 to 74ff - Sprite0_Attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is disabled) +// 7400 to 77ff - 3D sprite attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is enabled) +// +// 7800 - P_BodyID +// 7803 - P_SYS_CTRL +// 7804 - P_CLK_Ctrl0 +// 7805 - P_CLK_Ctrl1 +// 7806 - P_Reset_Flag +// 7807 - P_Clock_Ctrl +// 7808 - P_LVR_Ctrl +// 780a - P_Watchdog_Ctrl +// 780b - P_Watchdog_Clear +// 780c - P_WAIT +// 780d - P_HALT +// 780e - P_SLEEP +// 780f - P_Power_State + +// 7817 - P_PLLN +// 7818 - P_PLLWiatCLK +// 7819 - P_Cache_Ctrl +// 781a - P_Cache_HitRate +// 781f - P_IO_SR_SMT + +DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL1625x System-on-a-Chip (with NAND handling)") +DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL1625x System-on-a-Chip (with SPI handling)") + +generalplus_gpac800_device::generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + sunplus_gcm394_base_device(mconfig, GPAC800, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpac800_device::gpac800_internal_map), this)) +{ +} + +generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + sunplus_gcm394_base_device(mconfig, GP_SPISPI, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpspispi_device::gpspispi_internal_map), this)) +{ +} + + +// GPR27P512A = C2 76 +// HY27UF081G2A = AD F1 80 1D +// H27U518S2C = AD 76 + +uint16_t generalplus_gpac800_device::nand_7854_r() +{ + // TODO: use actual NAND / Smart Media devices once this is better understood. + // The games have extensive checks on startup to determine the flash types, but then it appears that + // certain games (eg jak_tsm) will only function correctly with specific ones, even if the code + // continues regardless. Others will bail early if they don't get what they want. + + // I think some unSP core maths bugs are causing severe issues after the initial load for jak_tsm + // at the moment, possibly the same ones that are causing rendering issues in the jak_gtg bitmap + // test and seemingly incorrect road data for jak_car2, either that or the hookup here is very + // non-standard outside of the ident codes + + // real TSM code starts at 4c000 + + + //logerror("%s:sunplus_gcm394_base_device::nand_7854_r\n", machine().describe_context()); + + if (m_nandcommand == 0x90) // read ident + { + logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ IDENT byte %d\n", machine().describe_context(), m_curblockaddr); + + uint8_t data = 0x00; + + if (m_romtype == 0) + { + if (m_curblockaddr == 0) + data = 0xc2; + else + data = 0x76; + } + else if (m_romtype == 1) + { + if (m_curblockaddr == 0) + data = 0xad; + else if (m_curblockaddr == 1) + data = 0x76; + } + else + { + if (m_curblockaddr == 0) + data = 0xad; + else if (m_curblockaddr == 1) + data = 0xf1; + else if (m_curblockaddr == 2) + data = 0x80; + else if (m_curblockaddr == 3) + data = 0x1d; + } + + m_curblockaddr++; + + return data; + } + else if (m_nandcommand == 0x00 || m_nandcommand == 0x01 || m_nandcommand == 0x50) + { + //logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ DATA byte %d\n", machine().describe_context(), m_curblockaddr); + + uint8_t data = m_nand_read_cb(m_effectiveaddress + m_curblockaddr); + + m_curblockaddr++; + + return data; + } + else if (m_nandcommand == 0x70) // read status + { + logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ STATUS byte %d\n", machine().describe_context(), m_curblockaddr); + + return 0xffff; + } + else + { + logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ UNKNOWN byte %d\n", machine().describe_context(), m_curblockaddr); + return 0xffff; + } + + return 0x0000; +} + +// 7998 + +void generalplus_gpac800_device::nand_command_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_command_w %04x\n", machine().describe_context(), data); + m_nandcommand = data; +} + +void generalplus_gpac800_device::nand_addr_low_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_addr_low_w %04x\n", machine().describe_context(), data); + m_nand_addr_low = data; + m_curblockaddr = 0; +} + +void generalplus_gpac800_device::recalculate_calculate_effective_nand_address() +{ + uint8_t type = m_nand_7856 & 0xf; + uint8_t shift = 0; + uint32_t page_offset = 0; + + if (type == 7) + shift = 4; + else if (type == 11) + shift = 5; + + if (m_nandcommand == 0x01) + page_offset = 256; + else if (m_nandcommand == 0x50) + page_offset = 512; + + uint32_t nandaddress = (m_nand_addr_high << 16) | m_nand_addr_low; + + if (m_nand_7850 & 0x4000) + nandaddress *= 2; + + uint32_t page = type ? nandaddress : /*(m_nand_7850 & 0x4000) ?*/ nandaddress >> 8 /*: nandaddress >> 9*/; + m_effectiveaddress = (page * 528 + page_offset) << shift; + + logerror("%s: Requested address is %08x, translating to %08x\n", machine().describe_context(), nandaddress, m_effectiveaddress); +} + +void generalplus_gpac800_device::nand_addr_high_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_addr_high_w %04x\n", machine().describe_context(), data); + m_nand_addr_high = data; + + recalculate_calculate_effective_nand_address(); + + m_curblockaddr = 0; +} + +void generalplus_gpac800_device::nand_dma_ctrl_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_dma_ctrl_w(?) %04x\n", machine().describe_context(), data); + m_nand_dma_ctrl = data; +} + +uint16_t generalplus_gpac800_device::nand_7850_status_r() +{ + // 0x8000 = ready + return m_nand_7850 | 0x8000; +} + +void generalplus_gpac800_device::nand_7850_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_7850_w %04x\n", machine().describe_context(), data); + m_nand_7850 = data; +} + +void generalplus_gpac800_device::nand_7856_type_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_7856_type_w %04x\n", machine().describe_context(), data); + m_nand_7856 = data; + + recalculate_calculate_effective_nand_address(); + + m_curblockaddr = 0; +} + +void generalplus_gpac800_device::nand_7857_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_7857_w %04x\n", machine().describe_context(), data); + m_nand_7857 = data; +} + +void generalplus_gpac800_device::nand_785b_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_785b_w %04x\n", machine().describe_context(), data); + m_nand_785b = data; +} + +void generalplus_gpac800_device::nand_785c_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_785c_w %04x\n", machine().describe_context(), data); + m_nand_785c = data; +} + +void generalplus_gpac800_device::nand_785d_w(uint16_t data) +{ + logerror("%s:sunplus_gcm394_base_device::nand_785d_w %04x\n", machine().describe_context(), data); + m_nand_785d = data; +} + +// [:maincpu] ':maincpu' (00146D) jak_tsm +uint16_t generalplus_gpac800_device::nand_785e_r() +{ + return 0x0000; +} + +//[:maincpu] ':maincpu' (001490) jak_tsm +uint16_t generalplus_gpac800_device::nand_ecc_low_byte_error_flag_1_r() +{ + return 0x0000; +} + +/* +UNMAPPED reads writes + +jak_tsm uses these (all iniitalized near start) +unclear if these are specific to the GPAC800 type, or present in the older types + +[:maincpu] ':maincpu' (00043F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) +[:maincpu] ':maincpu' (000442):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0000) +[:maincpu] ':maincpu' (000445):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) +[:maincpu] ':maincpu' (000449):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) +[:maincpu] ':maincpu' (00044D):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0a57) +[:maincpu] ':maincpu' (000451):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) +[:maincpu] ':maincpu' (000454):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) +[:maincpu] ':maincpu' (000458):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x3011) +[:maincpu] ':maincpu' (00045B):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x0000) +[:maincpu] ':maincpu' (00045D):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x0000) +[:maincpu] ':maincpu' (00045F):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x0000) +[:maincpu] ':maincpu' (000461):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x0000) + +jak_car2 uses these + +[:maincpu] ':maincpu' (004056):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) +[:maincpu] ':maincpu' (004059):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) +[:maincpu] ':maincpu' (00405C):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0a57) +[:maincpu] ':maincpu' (00405F):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) +[:maincpu] ':maincpu' (004062):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) +[:maincpu] ':maincpu' (004065):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x3011) +[:maincpu] ':maincpu' (004069):sunplus_gcm394_base_device::unk_r @ 0x7880 +[:maincpu] ':maincpu' (00406F):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x1249) +[:maincpu] ':maincpu' (004071):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x1249) +[:maincpu] ':maincpu' (004073):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x1249) +[:maincpu] ':maincpu' (004075):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x1249) +[:maincpu] ':maincpu' (004088):sunplus_gcm394_base_device::unk_w @ 0x7841 (data 0x000f) +[:maincpu] ':maincpu' (00408F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) +[:maincpu] ':maincpu' (004092):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0002) + +[:maincpu] ':maincpu' (03000A):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x36db) +[:maincpu] ':maincpu' (03000C):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x36db) +[:maincpu] ':maincpu' (03000E):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x36db) +[:maincpu] ':maincpu' (030010):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x36db) +[:maincpu] ':maincpu' (030013):sunplus_gcm394_base_device::unk_w @ 0x787f (data 0x0010) +[:maincpu] ':maincpu' (03001D):sunplus_gcm394_base_device::unk_w @ 0x7804 (data 0x1c7f) +[:maincpu] ':maincpu' (030023):sunplus_gcm394_base_device::unk_w @ 0x7805 (data 0xcdf0) +[:maincpu] ':maincpu' (03E645):sunplus_gcm394_base_device::unk_w @ 0x7861 (data 0x1f66) +[:maincpu] ':maincpu' (03E64C):sunplus_gcm394_base_device::unk_w @ 0x786b (data 0x0000) +[:maincpu] ':maincpu' (03E64F):sunplus_gcm394_base_device::unk_w @ 0x7869 (data 0x0000) +[:maincpu] ':maincpu' (03E652):sunplus_gcm394_base_device::unk_w @ 0x786a (data 0x0000) +[:maincpu] ':maincpu' (03E65B):sunplus_gcm394_base_device::unk_w @ 0x7966 (data 0x0001) +[:maincpu] ':maincpu' (03CBD0):sunplus_gcm394_base_device::unk_w @ 0x7871 (data 0x0000) + +-- this one seems like a common alt type of DMA, used in both hw types as it polls 707c status before doing it +[:maincpu] ':maincpu' (03B4C7):sunplus_gcm394_base_device::unk_w @ 0x707c (data 0x0001) +-- also video / alt dma? +[:maincpu] ':maincpu' (068C15):sunplus_gcm394_base_device::unk_r @ 0x707e + +beambox sets things up with different values (ultimately stalls on some check, maybe seeprom?) + +[:maincpu] ':maincpu' (00043F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) +[:maincpu] ':maincpu' (000442):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0000) +[:maincpu] ':maincpu' (000445):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) +[:maincpu] ':maincpu' (000449):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) +[:maincpu] ':maincpu' (00044D):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0f58) +[:maincpu] ':maincpu' (000451):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) +[:maincpu] ':maincpu' (000454):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) +[:maincpu] ':maincpu' (000458):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x4011) +[:maincpu] ':maincpu' (00045C):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x2492) -- note pair of 4, but different values to above games +[:maincpu] ':maincpu' (00045E):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x2492) +[:maincpu] ':maincpu' (000460):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x2492) +[:maincpu] ':maincpu' (000462):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x2492) + +vbaby code is very differet, attempts to load NAND block manually, not with DMA + +*/ + + +// all tilemap registers etc. appear to be in the same place as the above system, including the 'extra' ones not on the earlier models +// so it's likely this is built on top of that just with NAND support +void generalplus_gpac800_device::gpac800_internal_map(address_map& map) +{ + sunplus_gcm394_base_device::base_internal_map(map); + + // 785x = NAND device + map(0x007850, 0x007850).rw(FUNC(generalplus_gpac800_device::nand_7850_status_r), FUNC(generalplus_gpac800_device::nand_7850_w)); // NAND Control Reg + map(0x007851, 0x007851).w(FUNC(generalplus_gpac800_device::nand_command_w)); // NAND Command Reg + map(0x007852, 0x007852).w(FUNC(generalplus_gpac800_device::nand_addr_low_w)); // NAND Low Address Reg + map(0x007853, 0x007853).w(FUNC(generalplus_gpac800_device::nand_addr_high_w)); // NAND High Address Reg + map(0x007854, 0x007854).r(FUNC(generalplus_gpac800_device::nand_7854_r)); // NAND Data Reg + map(0x007855, 0x007855).w(FUNC(generalplus_gpac800_device::nand_dma_ctrl_w)); // NAND DMA / INT Control + map(0x007856, 0x007856).w(FUNC(generalplus_gpac800_device::nand_7856_type_w)); // usually 0x0021? + map(0x007857, 0x007857).w(FUNC(generalplus_gpac800_device::nand_7857_w)); + + // most of these are likely ECC stuff for testing the ROM? + map(0x00785b, 0x00785b).w(FUNC(generalplus_gpac800_device::nand_785b_w)); + map(0x00785c, 0x00785c).w(FUNC(generalplus_gpac800_device::nand_785c_w)); + map(0x00785d, 0x00785d).w(FUNC(generalplus_gpac800_device::nand_785d_w)); + map(0x00785e, 0x00785e).r(FUNC(generalplus_gpac800_device::nand_785e_r)); // also ECC status related? + map(0x00785f, 0x00785f).r(FUNC(generalplus_gpac800_device::nand_ecc_low_byte_error_flag_1_r)); // ECC Low Byte Error Flag 1 (maybe) + + // 128kwords internal ROM + //map(0x08000, 0x0ffff).rom().region("internal", 0); // lower 32kwords of internal ROM is visible / shadowed depending on boot pins and register + map(0x08000, 0x0ffff).r(FUNC(generalplus_gpac800_device::internalrom_lower32_r)).nopw(); + map(0x10000, 0x27fff).rom().region("internal", 0x10000); // upper 96kwords of internal ROM is always visible + map(0x28000, 0x2ffff).noprw(); // reserved + // 0x30000+ is CS access + + map(0x030000, 0x1fffff).rw(FUNC(generalplus_gpac800_device::cs_space_r), FUNC(generalplus_gpac800_device::cs_space_w)); + map(0x200000, 0x3fffff).rw(FUNC(generalplus_gpac800_device::cs_bank_space_r), FUNC(generalplus_gpac800_device::cs_bank_space_w)); +} + +void generalplus_gpac800_device::device_reset() +{ + sunplus_gcm394_base_device::device_reset(); + + m_nand_addr_low = 0x0000; + m_nand_addr_high = 0x0000; + m_nand_dma_ctrl = 0x0000; + m_nand_7850 = 0x0000; + m_nand_785d = 0x0000; + m_nand_785c = 0x0000; + m_nand_785b = 0x0000; + m_nand_7856 = 0x0000; + m_nand_7857 = 0x0000; +} + + +uint16_t generalplus_gpspispi_device::spi_unk_7943_r() +{ + return 0x0007; +} + +void generalplus_gpspispi_device::gpspispi_internal_map(address_map& map) +{ + sunplus_gcm394_base_device::base_internal_map(map); + + map(0x007943, 0x007943).r(FUNC(generalplus_gpspispi_device::spi_unk_7943_r)); + + map(0x008000, 0x00ffff).rom().region("internal", 0); +} + + diff --git a/src/devices/machine/generalplus_gpl1625x_soc.h b/src/devices/machine/generalplus_gpl1625x_soc.h new file mode 100644 index 0000000000000..667641c0dbe6f --- /dev/null +++ b/src/devices/machine/generalplus_gpl1625x_soc.h @@ -0,0 +1,94 @@ +// license:BSD-3-Clause +// copyright-holders:David Haywood + +#ifndef MAME_MACHINE_GENERALPLUS_GPL1625X_SOC_H +#define MAME_MACHINE_GENERALPLUS_GPL1625X_SOC_H + +#pragma once + +#include "generalplus_gpl162xx_soc.h" + + +class generalplus_gpac800_device : public sunplus_gcm394_base_device +{ +public: + template + generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpac800_device(mconfig, tag, owner, clock) + { + m_screen.set_tag(std::forward(screen_tag)); + m_csbase = 0x30000; + } + + generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + +protected: + void gpac800_internal_map(address_map &map) ATTR_COLD; + + //virtual void device_start() override ATTR_COLD; + virtual void device_reset() override ATTR_COLD; + +private: + void recalculate_calculate_effective_nand_address(); + + uint16_t nand_7850_status_r(); + uint16_t nand_7854_r(); + void nand_dma_ctrl_w(uint16_t data); + void nand_7850_w(uint16_t data); + void nand_command_w(uint16_t data); + void nand_addr_low_w(uint16_t data); + void nand_addr_high_w(uint16_t data); + uint16_t nand_ecc_low_byte_error_flag_1_r(); + void nand_7856_type_w(uint16_t data); + void nand_7857_w(uint16_t data); + void nand_785b_w(uint16_t data); + void nand_785c_w(uint16_t data); + void nand_785d_w(uint16_t data); + uint16_t nand_785e_r(); + + uint16_t m_nandcommand; + + uint16_t m_nand_addr_low; + uint16_t m_nand_addr_high; + + uint16_t m_nand_dma_ctrl; + uint16_t m_nand_7850; + uint16_t m_nand_785d; + uint16_t m_nand_785c; + uint16_t m_nand_785b; + uint16_t m_nand_7856; + uint16_t m_nand_7857; + + int m_curblockaddr; + uint32_t m_effectiveaddress; +}; + + +class generalplus_gpspispi_device : public sunplus_gcm394_base_device +{ +public: + template + generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpspispi_device(mconfig, tag, owner, clock) + { + m_screen.set_tag(std::forward(screen_tag)); + m_csbase = 0x30000; + } + + generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + +protected: + void gpspispi_internal_map(address_map &map) ATTR_COLD; + + //virtual void device_start() override ATTR_COLD; + //virtual void device_reset() override ATTR_COLD; + +private: + uint16_t spi_unk_7943_r(); +}; + +DECLARE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device) +DECLARE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device) + + +#endif // MAME_MACHINE_GENERALPLUS_GPL1625X_SOC_H diff --git a/src/devices/machine/generalplus_gpl162xx_soc.cpp b/src/devices/machine/generalplus_gpl162xx_soc.cpp index 8edace59f607d..907723430823f 100644 --- a/src/devices/machine/generalplus_gpl162xx_soc.cpp +++ b/src/devices/machine/generalplus_gpl162xx_soc.cpp @@ -5,7 +5,7 @@ GPL16220A - 320x240 output, 16K words internal RAM GPL16230A (GPAC500A) - expands RAM to 28K words, adds SDRAM support, adds NAND Flash/ROM/OTP support, USB support GPL16240VA - adds 640x480 output (V = VGA support?) - GPL16250VA (GPAC800A) - adds '3D' sprite mode, + GPL16250VA (GPAC800A) - adds '3D' sprite mode (see generalplus_gpl1625x_soc.cpp) there is also the 'B' series these only have 12K words RAM? but have the extra maths unit at 0x79A0? @@ -13,7 +13,7 @@ GPL16218B GPL16238B (this could be GPAC500B) GPL16248VB - GPL16258VB (this could be GPAC800B) + GPL16258VB (this could be GPAC800B) (see generalplus_gpl1625x_soc.cpp) die is marked 'GCM394' on some chips @@ -71,21 +71,6 @@ sunplus_gcm394_device::sunplus_gcm394_device(const machine_config &mconfig, cons { } -DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL16250 System-on-a-Chip (with NAND handling)") - -generalplus_gpac800_device::generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - sunplus_gcm394_base_device(mconfig, GPAC800, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpac800_device::gpac800_internal_map), this)) -{ -} - - -DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL16250 (with SPI handling)") - -generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : - sunplus_gcm394_base_device(mconfig, GP_SPISPI, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpspispi_device::gpspispi_internal_map), this)) -{ -} - @@ -1170,139 +1155,6 @@ void sunplus_gcm394_base_device::unk_w(offs_t offset, uint16_t data) // 7c00 - 7cff Sound Attribute // 7e00 - 7eff Sound Phase -//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// GPAC800A register list -// -// 7000 - Tx3_X_Position -// 7001 - Tx3_Y_Position -// 7002 - Tx3_X_Offset -// 7003 - Tx3_Y_Offset -// 7004 - Tx3_Attribute -// 7005 - Tx3_Control -// 7006 - Tx3_N_PTR -// 7007 - Tx3_A_PTR -// 7008 - Tx4_X_Position -// 7009 - Tx4_Y_Position -// 700a - Tx4_X_Offset -// 700b - Tx4_Y_Offset -// 700c - Tx4_Attribute -// 700d - Tx4_Control -// 700e - Tx4_N_PTR -// 700f - Tx4_A_PTR -// 7010 - Tx1_X_Position -// 7011 - Tx1_Y_Position -// 7012 - Tx1_Attribute -// 7013 - Tx1_Control -// 7014 - Tx1_N_PTR -// 7015 - Tx1_A_PTR -// 7016 - Tx2_X_Position -// 7017 - Tx2_Y_Position -// 7018 - Tx2_Attribute -// 7019 - Tx2_Control -// 701a - Tx2_N_PTR -// 701b - Tx2_A_PTR -// 701c - VComValue -// 701d - VComOffset -// 701e - VComStep -// 701f -// 7020 - Segment_Tx1 -// 7021 - Segment_Tx2 -// 7022 - Segment_sp -// 7023 - Segment_Tx3 -// 7024 - Segment_Tx4 -// -// 7028 - Tx4_Cosine -// 7029 - Tx4_Sine -// 702a - Blending -// 702b - Segment_Tx1H -// 702c - Segment_Tx2H -// 702d - Segment_spH -// 702e - Segment_Tx3H -// 702f - Segment_Tx4H -// 7030 - Fade_Control -// -// 7036 - IRQTMV -// 7037 - IRQTMH -// 7038 - Line_Counter -// 7039 - LightPen_Control -// 703a - Palette_Control -// -// 703e - LPHPosition -// 703f - LPVPosition -// -// 7042 - SControl -// -// 7062 - PPU_IRQ_EN -// 7063 - PPU_IRQ_Status -// -// 7070 - SPDMA_Source -// 7071 - SPDMA_Target -// 7072 - SPDMA_Number -// -// 7078 - FBI_AddrL -// 7079 - FBI_AddrH -// 707a - FBO_AddrL -// 707b - FBO_AddrH -// 707c - FB_PPU_GO -// 707d - BLD_Color -// 707e - PPU_RAM_Bank -// 707f - PPU_Enable -// -// 7090 - TG_CTRL1 -// 7091 - TG_CTRL2 -// 7092 - TG_HLSTART -// 7093 - TG_HEND -// 7094 - TG_VL0START -// 7095 - MD_FBADDRL -// 7096 - TG_VEND -// 7097 - TG_HSTART -// 7098 - MD_RGBL -// 7099 - SEN_CTRL -// 709a - TG_BSUPPER -// 709b - TG_BSLOWER -// 709c - MD_RGBH -// 709d - MD_CR -// 709e - TG_FBSADDRL -// 709f - TG_FBSADDRH -// 70a0 - TG_VL1START -// 70a1 - TG_H_WIDTH -// 70a2 - TG_V_WIDTH -// 70a3 - TG_CUTSTART -// 70a4 - TG_CUTWIDTH -// 70a5 - TG_VSTART -// 70a6 - MD_FBADDRH -// 70a7 - TG_H_RATIO -// 70a8 - TG_V_RATIO -// -// 7100 to 71ff - Tx_Hvoffset (when PPU_RAM_BANK is 0) -// 7200 to 72ff - HCMValue (when PPU_RAM_BANK is 0) -// 7100 to 72ff - Tx3_Cos / Tx3_Sin (when PPU_RAM_BANK is 1) -// -// 7300 to 73ff - Palette0 / Palette1 / Palette2 / Palette3 (3 banks using PAL_RAM_SEL) -// -// 7400 to 77ff - Standard sprite list (when PPU_RAM_BANK is 0) -// 7400 to 74ff - Sprite0_Attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is disabled) -// 7400 to 77ff - 3D sprite attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is enabled) -// -// 7800 - P_BodyID -// 7803 - P_SYS_CTRL -// 7804 - P_CLK_Ctrl0 -// 7805 - P_CLK_Ctrl1 -// 7806 - P_Reset_Flag -// 7807 - P_Clock_Ctrl -// 7808 - P_LVR_Ctrl -// 780a - P_Watchdog_Ctrl -// 780b - P_Watchdog_Clear -// 780c - P_WAIT -// 780d - P_HALT -// 780e - P_SLEEP -// 780f - P_Power_State - -// 7817 - P_PLLN -// 7818 - P_PLLWiatCLK -// 7819 - P_Cache_Ctrl -// 781a - P_Cache_HitRate -// 781f - P_IO_SR_SMT void sunplus_gcm394_base_device::base_internal_map(address_map &map) { @@ -1645,329 +1497,6 @@ uint16_t sunplus_gcm394_base_device::internalrom_lower32_r(offs_t offset) } -// GPR27P512A = C2 76 -// HY27UF081G2A = AD F1 80 1D -// H27U518S2C = AD 76 - -uint16_t generalplus_gpac800_device::nand_7854_r() -{ - // TODO: use actual NAND / Smart Media devices once this is better understood. - // The games have extensive checks on startup to determine the flash types, but then it appears that - // certain games (eg jak_tsm) will only function correctly with specific ones, even if the code - // continues regardless. Others will bail early if they don't get what they want. - - // I think some unSP core maths bugs are causing severe issues after the initial load for jak_tsm - // at the moment, possibly the same ones that are causing rendering issues in the jak_gtg bitmap - // test and seemingly incorrect road data for jak_car2, either that or the hookup here is very - // non-standard outside of the ident codes - - // real TSM code starts at 4c000 - - - //logerror("%s:sunplus_gcm394_base_device::nand_7854_r\n", machine().describe_context()); - - if (m_nandcommand == 0x90) // read ident - { - logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ IDENT byte %d\n", machine().describe_context(), m_curblockaddr); - - uint8_t data = 0x00; - - if (m_romtype == 0) - { - if (m_curblockaddr == 0) - data = 0xc2; - else - data = 0x76; - } - else if (m_romtype == 1) - { - if (m_curblockaddr == 0) - data = 0xad; - else if (m_curblockaddr == 1) - data = 0x76; - } - else - { - if (m_curblockaddr == 0) - data = 0xad; - else if (m_curblockaddr == 1) - data = 0xf1; - else if (m_curblockaddr == 2) - data = 0x80; - else if (m_curblockaddr == 3) - data = 0x1d; - } - - m_curblockaddr++; - - return data; - } - else if (m_nandcommand == 0x00 || m_nandcommand == 0x01 || m_nandcommand == 0x50) - { - //logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ DATA byte %d\n", machine().describe_context(), m_curblockaddr); - - uint8_t data = m_nand_read_cb(m_effectiveaddress + m_curblockaddr); - - m_curblockaddr++; - - return data; - } - else if (m_nandcommand == 0x70) // read status - { - logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ STATUS byte %d\n", machine().describe_context(), m_curblockaddr); - - return 0xffff; - } - else - { - logerror("%s:sunplus_gcm394_base_device::nand_7854_r READ UNKNOWN byte %d\n", machine().describe_context(), m_curblockaddr); - return 0xffff; - } - - return 0x0000; -} - -// 7998 - -void generalplus_gpac800_device::nand_command_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_command_w %04x\n", machine().describe_context(), data); - m_nandcommand = data; -} - -void generalplus_gpac800_device::nand_addr_low_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_addr_low_w %04x\n", machine().describe_context(), data); - m_nand_addr_low = data; - m_curblockaddr = 0; -} - -void generalplus_gpac800_device::recalculate_calculate_effective_nand_address() -{ - uint8_t type = m_nand_7856 & 0xf; - uint8_t shift = 0; - uint32_t page_offset = 0; - - if (type == 7) - shift = 4; - else if (type == 11) - shift = 5; - - if (m_nandcommand == 0x01) - page_offset = 256; - else if (m_nandcommand == 0x50) - page_offset = 512; - - uint32_t nandaddress = (m_nand_addr_high << 16) | m_nand_addr_low; - - if (m_nand_7850 & 0x4000) - nandaddress *= 2; - - uint32_t page = type ? nandaddress : /*(m_nand_7850 & 0x4000) ?*/ nandaddress >> 8 /*: nandaddress >> 9*/; - m_effectiveaddress = (page * 528 + page_offset) << shift; - - logerror("%s: Requested address is %08x, translating to %08x\n", machine().describe_context(), nandaddress, m_effectiveaddress); -} - -void generalplus_gpac800_device::nand_addr_high_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_addr_high_w %04x\n", machine().describe_context(), data); - m_nand_addr_high = data; - - recalculate_calculate_effective_nand_address(); - - m_curblockaddr = 0; -} - -void generalplus_gpac800_device::nand_dma_ctrl_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_dma_ctrl_w(?) %04x\n", machine().describe_context(), data); - m_nand_dma_ctrl = data; -} - -uint16_t generalplus_gpac800_device::nand_7850_status_r() -{ - // 0x8000 = ready - return m_nand_7850 | 0x8000; -} - -void generalplus_gpac800_device::nand_7850_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_7850_w %04x\n", machine().describe_context(), data); - m_nand_7850 = data; -} - -void generalplus_gpac800_device::nand_7856_type_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_7856_type_w %04x\n", machine().describe_context(), data); - m_nand_7856 = data; - - recalculate_calculate_effective_nand_address(); - - m_curblockaddr = 0; -} - -void generalplus_gpac800_device::nand_7857_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_7857_w %04x\n", machine().describe_context(), data); - m_nand_7857 = data; -} - -void generalplus_gpac800_device::nand_785b_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_785b_w %04x\n", machine().describe_context(), data); - m_nand_785b = data; -} - -void generalplus_gpac800_device::nand_785c_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_785c_w %04x\n", machine().describe_context(), data); - m_nand_785c = data; -} - -void generalplus_gpac800_device::nand_785d_w(uint16_t data) -{ - logerror("%s:sunplus_gcm394_base_device::nand_785d_w %04x\n", machine().describe_context(), data); - m_nand_785d = data; -} - -// [:maincpu] ':maincpu' (00146D) jak_tsm -uint16_t generalplus_gpac800_device::nand_785e_r() -{ - return 0x0000; -} - -//[:maincpu] ':maincpu' (001490) jak_tsm -uint16_t generalplus_gpac800_device::nand_ecc_low_byte_error_flag_1_r() -{ - return 0x0000; -} - -/* -UNMAPPED reads writes - -jak_tsm uses these (all iniitalized near start) -unclear if these are specific to the GPAC800 type, or present in the older types - -[:maincpu] ':maincpu' (00043F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) -[:maincpu] ':maincpu' (000442):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0000) -[:maincpu] ':maincpu' (000445):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) -[:maincpu] ':maincpu' (000449):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) -[:maincpu] ':maincpu' (00044D):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0a57) -[:maincpu] ':maincpu' (000451):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) -[:maincpu] ':maincpu' (000454):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) -[:maincpu] ':maincpu' (000458):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x3011) -[:maincpu] ':maincpu' (00045B):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x0000) -[:maincpu] ':maincpu' (00045D):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x0000) -[:maincpu] ':maincpu' (00045F):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x0000) -[:maincpu] ':maincpu' (000461):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x0000) - -jak_car2 uses these - -[:maincpu] ':maincpu' (004056):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) -[:maincpu] ':maincpu' (004059):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) -[:maincpu] ':maincpu' (00405C):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0a57) -[:maincpu] ':maincpu' (00405F):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) -[:maincpu] ':maincpu' (004062):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) -[:maincpu] ':maincpu' (004065):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x3011) -[:maincpu] ':maincpu' (004069):sunplus_gcm394_base_device::unk_r @ 0x7880 -[:maincpu] ':maincpu' (00406F):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x1249) -[:maincpu] ':maincpu' (004071):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x1249) -[:maincpu] ':maincpu' (004073):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x1249) -[:maincpu] ':maincpu' (004075):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x1249) -[:maincpu] ':maincpu' (004088):sunplus_gcm394_base_device::unk_w @ 0x7841 (data 0x000f) -[:maincpu] ':maincpu' (00408F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) -[:maincpu] ':maincpu' (004092):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0002) - -[:maincpu] ':maincpu' (03000A):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x36db) -[:maincpu] ':maincpu' (03000C):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x36db) -[:maincpu] ':maincpu' (03000E):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x36db) -[:maincpu] ':maincpu' (030010):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x36db) -[:maincpu] ':maincpu' (030013):sunplus_gcm394_base_device::unk_w @ 0x787f (data 0x0010) -[:maincpu] ':maincpu' (03001D):sunplus_gcm394_base_device::unk_w @ 0x7804 (data 0x1c7f) -[:maincpu] ':maincpu' (030023):sunplus_gcm394_base_device::unk_w @ 0x7805 (data 0xcdf0) -[:maincpu] ':maincpu' (03E645):sunplus_gcm394_base_device::unk_w @ 0x7861 (data 0x1f66) -[:maincpu] ':maincpu' (03E64C):sunplus_gcm394_base_device::unk_w @ 0x786b (data 0x0000) -[:maincpu] ':maincpu' (03E64F):sunplus_gcm394_base_device::unk_w @ 0x7869 (data 0x0000) -[:maincpu] ':maincpu' (03E652):sunplus_gcm394_base_device::unk_w @ 0x786a (data 0x0000) -[:maincpu] ':maincpu' (03E65B):sunplus_gcm394_base_device::unk_w @ 0x7966 (data 0x0001) -[:maincpu] ':maincpu' (03CBD0):sunplus_gcm394_base_device::unk_w @ 0x7871 (data 0x0000) - --- this one seems like a common alt type of DMA, used in both hw types as it polls 707c status before doing it -[:maincpu] ':maincpu' (03B4C7):sunplus_gcm394_base_device::unk_w @ 0x707c (data 0x0001) --- also video / alt dma? -[:maincpu] ':maincpu' (068C15):sunplus_gcm394_base_device::unk_r @ 0x707e - -beambox sets things up with different values (ultimately stalls on some check, maybe seeprom?) - -[:maincpu] ':maincpu' (00043F):sunplus_gcm394_base_device::unk_w @ 0x780a (data 0x0000) -[:maincpu] ':maincpu' (000442):sunplus_gcm394_base_device::unk_w @ 0x7808 (data 0x0000) -[:maincpu] ':maincpu' (000445):sunplus_gcm394_base_device::unk_w @ 0x782f (data 0x0002) -[:maincpu] ':maincpu' (000449):sunplus_gcm394_base_device::unk_w @ 0x783d (data 0x05d9) -[:maincpu] ':maincpu' (00044D):sunplus_gcm394_base_device::unk_w @ 0x783c (data 0x0f58) -[:maincpu] ':maincpu' (000451):sunplus_gcm394_base_device::unk_w @ 0x783b (data 0x2400) -[:maincpu] ':maincpu' (000454):sunplus_gcm394_base_device::unk_w @ 0x783e (data 0x0002) -[:maincpu] ':maincpu' (000458):sunplus_gcm394_base_device::unk_w @ 0x783a (data 0x4011) -[:maincpu] ':maincpu' (00045C):sunplus_gcm394_base_device::unk_w @ 0x7874 (data 0x2492) -- note pair of 4, but different values to above games -[:maincpu] ':maincpu' (00045E):sunplus_gcm394_base_device::unk_w @ 0x787c (data 0x2492) -[:maincpu] ':maincpu' (000460):sunplus_gcm394_base_device::unk_w @ 0x7888 (data 0x2492) -[:maincpu] ':maincpu' (000462):sunplus_gcm394_base_device::unk_w @ 0x787e (data 0x2492) - -vbaby code is very differet, attempts to load NAND block manually, not with DMA - -*/ - - -// all tilemap registers etc. appear to be in the same place as the above system, including the 'extra' ones not on the earlier models -// so it's likely this is built on top of that just with NAND support -void generalplus_gpac800_device::gpac800_internal_map(address_map& map) -{ - sunplus_gcm394_base_device::base_internal_map(map); - - // 785x = NAND device - map(0x007850, 0x007850).rw(FUNC(generalplus_gpac800_device::nand_7850_status_r), FUNC(generalplus_gpac800_device::nand_7850_w)); // NAND Control Reg - map(0x007851, 0x007851).w(FUNC(generalplus_gpac800_device::nand_command_w)); // NAND Command Reg - map(0x007852, 0x007852).w(FUNC(generalplus_gpac800_device::nand_addr_low_w)); // NAND Low Address Reg - map(0x007853, 0x007853).w(FUNC(generalplus_gpac800_device::nand_addr_high_w)); // NAND High Address Reg - map(0x007854, 0x007854).r(FUNC(generalplus_gpac800_device::nand_7854_r)); // NAND Data Reg - map(0x007855, 0x007855).w(FUNC(generalplus_gpac800_device::nand_dma_ctrl_w)); // NAND DMA / INT Control - map(0x007856, 0x007856).w(FUNC(generalplus_gpac800_device::nand_7856_type_w)); // usually 0x0021? - map(0x007857, 0x007857).w(FUNC(generalplus_gpac800_device::nand_7857_w)); - - // most of these are likely ECC stuff for testing the ROM? - map(0x00785b, 0x00785b).w(FUNC(generalplus_gpac800_device::nand_785b_w)); - map(0x00785c, 0x00785c).w(FUNC(generalplus_gpac800_device::nand_785c_w)); - map(0x00785d, 0x00785d).w(FUNC(generalplus_gpac800_device::nand_785d_w)); - map(0x00785e, 0x00785e).r(FUNC(generalplus_gpac800_device::nand_785e_r)); // also ECC status related? - map(0x00785f, 0x00785f).r(FUNC(generalplus_gpac800_device::nand_ecc_low_byte_error_flag_1_r)); // ECC Low Byte Error Flag 1 (maybe) - - // 128kwords internal ROM - //map(0x08000, 0x0ffff).rom().region("internal", 0); // lower 32kwords of internal ROM is visible / shadowed depending on boot pins and register - map(0x08000, 0x0ffff).r(FUNC(generalplus_gpac800_device::internalrom_lower32_r)).nopw(); - map(0x10000, 0x27fff).rom().region("internal", 0x10000); // upper 96kwords of internal ROM is always visible - map(0x28000, 0x2ffff).noprw(); // reserved - // 0x30000+ is CS access - - map(0x030000, 0x1fffff).rw(FUNC(generalplus_gpac800_device::cs_space_r), FUNC(generalplus_gpac800_device::cs_space_w)); - map(0x200000, 0x3fffff).rw(FUNC(generalplus_gpac800_device::cs_bank_space_r), FUNC(generalplus_gpac800_device::cs_bank_space_w)); -} - - -uint16_t generalplus_gpspispi_device::spi_unk_7943_r() -{ - return 0x0007; -} - -void generalplus_gpspispi_device::gpspispi_internal_map(address_map& map) -{ - sunplus_gcm394_base_device::base_internal_map(map); - - map(0x007943, 0x007943).r(FUNC(generalplus_gpspispi_device::spi_unk_7943_r)); - - map(0x008000, 0x00ffff).rom().region("internal", 0); -} - - void sunplus_gcm394_base_device::device_start() { unsp_20_device::device_start(); @@ -2109,20 +1638,6 @@ void sunplus_gcm394_base_device::device_reset() m_spg_video->reset(); } -void generalplus_gpac800_device::device_reset() -{ - sunplus_gcm394_base_device::device_reset(); - - m_nand_addr_low = 0x0000; - m_nand_addr_high = 0x0000; - m_nand_dma_ctrl = 0x0000; - m_nand_7850 = 0x0000; - m_nand_785d = 0x0000; - m_nand_785c = 0x0000; - m_nand_785b = 0x0000; - m_nand_7856 = 0x0000; - m_nand_7857 = 0x0000; -} IRQ_CALLBACK_MEMBER(sunplus_gcm394_base_device::irq_vector_cb) { diff --git a/src/devices/machine/generalplus_gpl162xx_soc.h b/src/devices/machine/generalplus_gpl162xx_soc.h index 27784ccd78c69..e70801a05fb09 100644 --- a/src/devices/machine/generalplus_gpl162xx_soc.h +++ b/src/devices/machine/generalplus_gpl162xx_soc.h @@ -369,90 +369,10 @@ class sunplus_gcm394_device : public sunplus_gcm394_base_device }; -class generalplus_gpac800_device : public sunplus_gcm394_base_device -{ -public: - template - generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : - generalplus_gpac800_device(mconfig, tag, owner, clock) - { - m_screen.set_tag(std::forward(screen_tag)); - m_csbase = 0x30000; - } - - generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - -protected: - void gpac800_internal_map(address_map &map) ATTR_COLD; - - //virtual void device_start() override ATTR_COLD; - virtual void device_reset() override ATTR_COLD; - -private: - void recalculate_calculate_effective_nand_address(); - - uint16_t nand_7850_status_r(); - uint16_t nand_7854_r(); - void nand_dma_ctrl_w(uint16_t data); - void nand_7850_w(uint16_t data); - void nand_command_w(uint16_t data); - void nand_addr_low_w(uint16_t data); - void nand_addr_high_w(uint16_t data); - uint16_t nand_ecc_low_byte_error_flag_1_r(); - void nand_7856_type_w(uint16_t data); - void nand_7857_w(uint16_t data); - void nand_785b_w(uint16_t data); - void nand_785c_w(uint16_t data); - void nand_785d_w(uint16_t data); - uint16_t nand_785e_r(); - - uint16_t m_nandcommand; - - uint16_t m_nand_addr_low; - uint16_t m_nand_addr_high; - - uint16_t m_nand_dma_ctrl; - uint16_t m_nand_7850; - uint16_t m_nand_785d; - uint16_t m_nand_785c; - uint16_t m_nand_785b; - uint16_t m_nand_7856; - uint16_t m_nand_7857; - - int m_curblockaddr; - uint32_t m_effectiveaddress; -}; - - -class generalplus_gpspispi_device : public sunplus_gcm394_base_device -{ -public: - template - generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : - generalplus_gpspispi_device(mconfig, tag, owner, clock) - { - m_screen.set_tag(std::forward(screen_tag)); - m_csbase = 0x30000; - } - - generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - -protected: - void gpspispi_internal_map(address_map &map) ATTR_COLD; - - //virtual void device_start() override ATTR_COLD; - //virtual void device_reset() override ATTR_COLD; - -private: - uint16_t spi_unk_7943_r(); -}; - DECLARE_DEVICE_TYPE(GCM394, sunplus_gcm394_device) -DECLARE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device) -DECLARE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device) diff --git a/src/mame/tvgames/generalplus_gpl16250.h b/src/mame/tvgames/generalplus_gpl16250.h index 1181bf5093855..78cf7f3cf157b 100644 --- a/src/mame/tvgames/generalplus_gpl16250.h +++ b/src/mame/tvgames/generalplus_gpl16250.h @@ -10,6 +10,7 @@ #include "bus/generic/carts.h" #include "bus/generic/slot.h" #include "machine/generalplus_gpl951xx_soc.h" +#include "machine/generalplus_gpl1625x_soc.h" #include "screen.h" #include "speaker.h" diff --git a/src/mame/tvgames/generalplus_gpl16250_nand.h b/src/mame/tvgames/generalplus_gpl16250_nand.h index 7673a8ef7e50c..9ca1435409ad4 100644 --- a/src/mame/tvgames/generalplus_gpl16250_nand.h +++ b/src/mame/tvgames/generalplus_gpl16250_nand.h @@ -6,7 +6,7 @@ #pragma once #include "generalplus_gpl16250.h" -#include "machine/generalplus_gpl162xx_soc.h" +#include "machine/generalplus_gpl1625x_soc.h" #include "generalplus_gpl16250_m.h" #include "bus/generic/slot.h" #include "bus/generic/carts.h" From e572f27a50e2ca464fdaac532acbf5f87fbb5b25 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 22:31:36 +0100 Subject: [PATCH 33/53] more notes --- .../machine/generalplus_gpl1625x_soc.cpp | 127 +++++++++++++++--- 1 file changed, 106 insertions(+), 21 deletions(-) diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp index a53082c80e907..59ced24cc5461 100644 --- a/src/devices/machine/generalplus_gpl1625x_soc.cpp +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -61,14 +61,37 @@ // 7039 - LightPen_Control // 703a - Palette_Control // +// 703c - TV_Control +// // 703e - LPHPosition // 703f - LPVPosition // // 7042 - SControl +// +// 7050 - TFT_Ctrl +// 7051 - TFT_V_Width or STN_COM_Clip +// 7052 - TFT_VSync_Setup +// 7053 - TFT_V_Start +// 7054 - TFT_V_End +// 7055 - TFT_H_Width +// 7056 - TFT_HSync_Setup +// 7057 - TFT_H_ Start +// 7058 - TFT_H_ End +// 7059 - TFT_RGB_Ctrl +// 705a - TFT_Status +// 705b - TFT_MemMode_WriteCMD +// 705c - TFT_MemMode_ReadCMD +// +// 705f - STN_Ctrl1 // -// 7062 - PPU_IRQ_EN -// 7063 - PPU_IRQ_Status +// 7062 - PPU_IRQ_EN or TFT_INT_EN +// 7063 - PPU_IRQ_Status or TFT_INT_CLR // +// 706c - TFT_V_Show_Start +// 706d - TFT_V_Show_End +// 706e - TFT_H_Show_Start +// 706f - TFT_H_Show_End +// // 7070 - SPDMA_Source // 7071 - SPDMA_Target // 7072 - SPDMA_Number @@ -82,6 +105,16 @@ // 707e - PPU_RAM_Bank // 707f - PPU_Enable // +// 7080 - TV_Saturation or STN_SEG +// 7081 - TV_Hue or STN_COM +// 7082 - TV_Brightness or STN_PIC_COM +// 7083 - TV_Sharpness or STN_CPWAIT +// 7084 - TV_Y_Gain or STN_Ctrl2 +// 7085 - TV_Y_Delay or STN_GTG_SEG +// 7086 - TV_V_Position or STN_GTG_COM +// 7087 - TV_H_Position or STN_SEG_Clip +// 7088 - TV_VedioDAC +// // 7090 - TG_CTRL1 // 7091 - TG_CTRL2 // 7092 - TG_HLSTART @@ -107,6 +140,8 @@ // 70a6 - MD_FBADDRH // 70a7 - TG_H_RATIO // 70a8 - TG_V_RATIO +// 70a9 - MD_HPOS +// 70aa - MD_VPOS // // 7100 to 71ff - Tx_Hvoffset (when PPU_RAM_BANK is 0) // 7200 to 72ff - HCMValue (when PPU_RAM_BANK is 0) @@ -118,25 +153,75 @@ // 7400 to 74ff - Sprite0_Attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is disabled) // 7400 to 77ff - 3D sprite attribute list (when PPU_RAM_BANK is 1 and PPU_Enable bit 9 '3D' mode is enabled) // -// 7800 - P_BodyID -// 7803 - P_SYS_CTRL -// 7804 - P_CLK_Ctrl0 -// 7805 - P_CLK_Ctrl1 -// 7806 - P_Reset_Flag -// 7807 - P_Clock_Ctrl -// 7808 - P_LVR_Ctrl -// 780a - P_Watchdog_Ctrl -// 780b - P_Watchdog_Clear -// 780c - P_WAIT -// 780d - P_HALT -// 780e - P_SLEEP -// 780f - P_Power_State - -// 7817 - P_PLLN -// 7818 - P_PLLWiatCLK -// 7819 - P_Cache_Ctrl -// 781a - P_Cache_HitRate -// 781f - P_IO_SR_SMT +// 7800 - BodyID +// 7803 - SYS_CTRL +// 7804 - CLK_Ctrl0 +// 7805 - CLK_Ctrl1 +// 7806 - Reset_Flag +// 7807 - Clock_Ctrl +// 7808 - LVR_Ctrl +// 780a - Watchdog_Ctrl +// 780b - Watchdog_Clear +// 780c - WAIT +// 780d - HALT +// 780e - SLEEP +// 780f - Power_State + +// 7810 - BankSwitch_Ctrl + +// 7816 - MAPSEL +// 7817 - PLLN +// 7818 - PLLWiatCLK +// 7819 - Cache_Ctrl +// 781a - Cache_HitRate +// 781f - IO_SR_SMT + +// 7820 - MCS0_Ctrl +// 7821 - MCS1_Ctrl +// 7822 - MCS2_Ctrl +// 7823 - MCS3_Ctrl +// 7824 - MCS4_Ctrl +// 7825 - PSRAM_Ctrl +// 7826 - MCS_BYTE_SEL +// 7827 - MCS3_WETimingCtrl +// 7828 - MCS4_WETimingCtrl +// 7829 - MCS3_RDTimingCtrl +// 782a - MCS4_RDTimingCtrl +// 782b - MCS3_TimingCtrl +// 782c - MCS4_TimingCtrl +// 782d - RAW_WAR +// 782e - NOR_WHold +// 782f - SDRAM_EN + +// 7835 - MCS0_Page +// 7836 - MCS1_Page +// 7837 - MCS2_Page +// 7838 - MCS3_Page +// 7839 - MCS4_Page +// 783a - SDRAM_Ctrl0 +// 783b - SDRAM_Ctrl1 +// 783c - SDRAM_Timing +// 783d - SDRAM_CBRCYC +// 783e - SDRAM_MISC + +// 7840 - Mem_Ctrl +// 7841 - Addr_Ctrl + +// 7874 - SDRAM_Drv +// 7875 - SDRAM_Dly + +// 787e - MCS_Drv +// 787f - MCS_Dly + +// 7888 - MEM_Drv +// 7889 - MEM_Dly0 +// 788a - MEM_Dly1 +// 788b - MEM_Dly2 +// 788c - MEM_Dly3 +// 788d - MEM_Dly4 +// 788e - MEM_Dly5 +// 788f - MEM_Dly6 + DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL1625x System-on-a-Chip (with NAND handling)") DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL1625x System-on-a-Chip (with SPI handling)") From 89ec452731c734b77b5789e68a1a2bc381c4137a Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 23:35:46 +0100 Subject: [PATCH 34/53] more port notes --- .../machine/generalplus_gpl1625x_soc.cpp | 197 +++++++++++++++++- 1 file changed, 192 insertions(+), 5 deletions(-) diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp index 59ced24cc5461..5d8475e2a13eb 100644 --- a/src/devices/machine/generalplus_gpl1625x_soc.cpp +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -174,6 +174,7 @@ // 7818 - PLLWiatCLK // 7819 - Cache_Ctrl // 781a - Cache_HitRate +// // 781f - IO_SR_SMT // 7820 - MCS0_Ctrl @@ -193,6 +194,9 @@ // 782e - NOR_WHold // 782f - SDRAM_EN +// 7830 - CHECKSUM0_LB +// 7831 - CHECKSUM1_LB + // 7835 - MCS0_Page // 7836 - MCS1_Page // 7837 - MCS2_Page @@ -203,15 +207,65 @@ // 783c - SDRAM_Timing // 783d - SDRAM_CBRCYC // 783e - SDRAM_MISC - +// 783f - SDR_STATUS +// // 7840 - Mem_Ctrl // 7841 - Addr_Ctrl +// 784e - ECC_ERR0_HB (?) +// 784f - ECC_ERR1_HB (?) + +// 7850 - NF_Ctrl +// 7851 - NF_CMD +// 7852 - NF_AddrL +// 7853 - NF_AddrH +// 7854 - NF_Data +// 7855 - NF_INT_Ctrl + +// 7857 - ECC_Ctrl +// 7858 - ECC_LPRL_LB +// 7859 - ECC_LPRH_LB +// 785a - ECC_CPR_LB +// 785b - ECC_LPR_CKL_LB +// 785c - ECC_LPR_CKH_LB +// 785d - ECC_CPCKR_LB +// 785e - ECC_ERR0_LB +// 785f - ECC_ERR1_LB + +// 7860 - IOA_Data +// 7861 - IOA_Buffer +// 7862 - IOA_Dir +// 7863 - IOA_Attrib +// 7854 - IOA_Drv +// +// 7868 - IOB_Data +// 7869 - IOB_Buffer +// 786a - IOB_Dir +// 786b - IOB_Attrib +// 786c - IOB_Latch +// 786d - IOB_Drv +// +// 7870 - IOC_Data +// 7871 - IOC_Buffer +// 7872 - IOC_Dir +// 7873 - IOC_Attrib // 7874 - SDRAM_Drv -// 7875 - SDRAM_Dly - -// 787e - MCS_Drv -// 787f - MCS_Dly +// 7875 - IOC_Drv +// 7876 - SDRAM_Dly +// 7877 - IOC_Latch +// 7878 - IOD_Data +// 7879 - IOD_Buffer +// 787a - IOD_Dir +// 787b - IOD_Attrib +// 787c - IOD_Drv +// 787d - IOD_Dly +// 787e - CS_Drv / MCS_Drv +// 787f - CS_Dly / MCS_Dly +// 7880 - IOE_Data +// 7881 - IOE_Buffer +// 7882 - IOE_Dir +// 7883 - IOE_Attrib +// 7884 - IOE_Drv // 7888 - MEM_Drv // 7889 - MEM_Dly0 @@ -222,6 +276,139 @@ // 788e - MEM_Dly5 // 788f - MEM_Dly6 +// 78a0 - INT_Status1 +// 78a1 - INT_Status2 +// 78a3 - INT_Status3 + +// 78a4 - INT_Priority1 +// 78a5 - INT_Priority2 +// 78a6 - INT_Priority2 + +// 78a8 - MINT_Ctrl + +// 78b0 - TimeBaseA_Ctrl +// 78b1 - TimeBaseB_Ctr +// 78b2 - TimeBaseC_Ctrl + +// 78b8 - TimeBase_Reset + +// 78c0 - TimerA_Ctrl +// 78c1 - TimerA_CCCtrl +// 78c2 - TimerA_Preload +// 78c3 - TimerA_CCReg +// 78c4 - TimerA_UpCount + +// 78c8 - TimerB_Ctrl +// 78c9 - TimerB_CCCtrl +// 78ca - TimerB_Preload +// 78cb - TimerB_CCReg +// 78cc - TimerB_UpCount + +// 78d0 - TimerC_Ctrl +// 78d1 - TimerC_CCCtrl +// 78d2 - TimerC_Preload +// 78d3 - TimerC_CCReg +// 78d4 - TimerC_UpCount + +// 78d8 - TimerD_Ctrl +// 78da - TimerD_Preload +// 78dc - TimerD_UpCount + +// 78e0 - TimerE_Ctrl +// 78e2 - TimerE_Preload +// 78e4 - TimerE_UpCount +// 78e8 - TimerF_Ctrl +// 78ea - TimerF_Preload +// 78ec - TimerF_UpCount + +// 78f0 - CHA_Ctrl +// 78f1 - CHA_Data +// 78f2 - CHA_FIFO +// +// 78f8 - CHB_Ctrl +// 78f9 - CHB_Data +// 78fa - CHB_FIFO +// 78fb - DAC_PGA + +// 78ff - IISEN + +// 7900 - UART_Data +// 7901 - UART_RXStatus +// 7902 - UART_Ctrl +// 7903 - UART_BaudRate +// 7904 - UART_Status +// 7905 - UART_FIFO +// 7906 - UART_TXDLY +// 7907 - IrDA_BaudRate +// 7908 - IrDA_Ctrl +// 7909 - IrDA_LowPower + +// 7920 - Second +// 7921 - Minute +// 7922 - Hour + +// 7924 - Alarm_Second +// 7925 - Alarm_Minute +// 7926 - Alarm_Hour + +// 7934 - RTC_Ctrl +// 7935 - RTC_INT_Status +// 7936 - RTC_INT_Ctrl +// 7937 - RTC_Busy + +// 7940 - SPI_Ctrl +// 7941 - SPI_TXStatus +// 7942 - SPI_TXData +// 7943 - SPI_RXStatus +// 7944 - SPI_RXData +// 7945 - SPI_Misc + +// 7960 - ADC_Setup +// 7961 - MADC_Ctrl +// 7962 - MADC_Data +// 7963 - ASADC_Ctrl +// 7964 - ASDAC_Data + +// 7966 - USELINEIN +// 7967 - SH_WAIT + +// 79d0 - SD1_DataTX +// 79d1 - SD1_DataRX +// 79d2 - SD1_CMD +// 79d3 - SD1_ArgL +// 79d4 - SD1_ArgH +// 79d5 - SD1_RespL +// 79d6 - SD1_RespH +// 79d7 - SD1_Status +// 79d8 - SD1_Ctrl +// 79d9 - SD1_BLKLEN +// 79da - SD1_INT + +// 79e0 - SD2_DataTX +// 79e1 - SD2_DataRX +// 79e2 - SD2_CMD +// 79e3 - SD2_ArgL +// 79e4 - SD2_ArgH +// 79e5 - SD2_RespL +// 79e6 - SD2_RespH +// 79e7 - SD2_Status +// 79e8 - SD2_Ctrl +// 79e9 - SD2_BLKLEN +// 79ea - SD2_INT + +// 79f0 - CMA_R_Y_In +// 79f1 - CMA_G_U_In +// 79f2 - CMA_B_V_In +// 79f3 - CMA_Ctrl +// 79f4 - CMA_R_Y_Out +// 79f5 - CMA_G_U_Out +// 79f6 - CMA_B_V_Out + +// 7af0 - Byte_Swap +// 7af1 - Nibble_Swap +// 7af2 - TwoBit_Swap +// 7af3 - Bit_Reverse + DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL1625x System-on-a-Chip (with NAND handling)") DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL1625x System-on-a-Chip (with SPI handling)") From 948bc94416f11b6cf66ed7648285c2384c8250f6 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Fri, 17 Oct 2025 23:52:57 +0100 Subject: [PATCH 35/53] more register notes --- .../machine/generalplus_gpl1625x_soc.cpp | 86 +++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp index 5d8475e2a13eb..f7fcd13b8c538 100644 --- a/src/devices/machine/generalplus_gpl1625x_soc.cpp +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -404,6 +404,92 @@ // 79f5 - CMA_G_U_Out // 79f6 - CMA_B_V_Out +// 7a00 - USBH_Config +// 7a01 - USBH_TimeConfig +// 7a02 - USBH_Data +// 7a03 - USBH_Transfer +// 7a04 - USBH_DveAddr +// 7a05 - USBH_DveEP +// 7a06 - USBH_TXCount +// 7a07 - USBH_RXCount +// 7a08 - USBH_FIFOInPointer +// 7a09 - USBH_FIFOOutPointer +// 7a0a - USBH_AutoInByteCount +// 7a0b - USBH_AutoOutByteCount +// 7a0c - USBH_AutoTrans +// 7a0d - USBH_Status +// 7a0e - USBH_INT +// 7a0f - USBH_INTEN + +// 7a11 - USBH_SoftRST +// 7a12 - USBH_SOFTimer +// 7a13 - USBH_FrameNum +// +// 7a17 - USBH_INAckCount +// 7a18 - USBH_OutAckCount +// 7a19 - USBH_RSTAckCount + +// 7a1b - USBH_DReadback + +// 7a20 - USBH_SOF_BOND +// 7a21 - USBH_ISOConfig + +// 7a30 - USBD_Config +// 7a31 - USBD_Function +// 7a32 - USBD_PMR +// 7a33 - USBD_EP0Data +// 7a34 - USBD_BIData +// 7a35 - USBD_BOData +// 7a36 - USBD_INTINData +// 7a37 - USBD_EPEvent +// 7a38 - USBD_GLOINT +// 7a39 - USBD_INTEN +// 7a3a - USBD_INT +// 7a3b - USBD_SCI NTEN +// 7a3c - USBD_SCINT +// 7a3d - USBD_EPAutoSet +// 7a3e - USBD_EPSetStall +// 7a3f - USBD_EPBufClear +// 7a40 - USBD_EPEvntClear +// 7a41 - USBD_EP0WrtCount +// 7a42 - USBD_BOWrtCount +// 7a43 - USBD_EP0BufPointer +// 7a44 - USBD_BIBufPointer +// 7a45 - USBD_BOBufPointer +// 7a46 - USBD_EP0RTR +// 7a47 - USBD_EP0RR +// 7a48 - USBD_ EP0VR +// 7a49 - USBD_ EP0IR +// 7a4a - USBD_ EP0LR +// 7a4b - USBD_INTBufPointer +// 7a4c - USBD_INTF +// 7a4d - USBD_ALT +// 7a4e - USBD_ISOOData +// 7a4f - USBD_ISOIData +// 7a50 - USBD_DMAWrtCountL +// 7a51 - USBD_DMAWrtCountH +// 7a52 - USBD_DMAAck +// 7a53 - USBD_DMAAckH +// 7a54 - USBD_EPStall +// 7a55 - USBD_CALT +// 7a56 - USBD_MAXALT +// 7a57 - USBD_Device +// 7a58 - USBD_NullPkt +// 7a59 - USBD_DMAINT + +// 7a5b - USBD_MAXINT +// 7a5c - USBD_ISOEvent +// 7a5d - USBD_ISOINTE +// 7a5e - USBD_ISOINT +// 7a5f - USBD_ISOOWrtCount +// 7a60 - USBD_IOUTData +// 7a61 - USBD_IOUTEvent +// 7a62 - USBD_IOUTINTEN +// 7a63 - USBD_IOUTINT +// 7a64 - USBD_IOUTWrtCount +// 7a65 - USBD_ISOOBufPointer +// 7a66 - USBD_ISOIBufPointer + // 7af0 - Byte_Swap // 7af1 - Nibble_Swap // 7af2 - TwoBit_Swap From bd54c19afb234ce1c70addabec8cbbac52d1eb37 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Sat, 18 Oct 2025 00:53:10 +0100 Subject: [PATCH 36/53] document more --- .../machine/generalplus_gpl1625x_soc.cpp | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp index f7fcd13b8c538..efc54b954a847 100644 --- a/src/devices/machine/generalplus_gpl1625x_soc.cpp +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -490,6 +490,70 @@ // 7a65 - USBD_ISOOBufPointer // 7a66 - USBD_ISOIBufPointer +// 7a80 - DMA_Ctrl0 +// 7a81 - DMA_SRC_AddrL0 +// 7a82 - DMA_TAR_AddrL0 +// 7a83 - DMA_TCountL0 +// 7a84 - DMA_SRC_AddrH0 +// 7a85 - DMA_TAR_AddrH0 +// 7a86 - DMA_TCountH0 +// 7a87 - DMA_MISC0 +// 7a88 - DMA_Ctrl1 +// 7a89 - DMA_SRC_AddrL1 +// 7a8a - DMA_TAR_AddrL1 +// 7a8b - DMA_TCountL1 +// 7a8c - DMA_SRC_AddrH1 +// 7a8d - DMA_TAR_AddrH1 +// 7a8e - DMA_TCountH1 +// 7a8f - DMA_MISC1 +// 7a90 - DMA_Ctrl2 +// 7a91 - DMA_SRC_AddrL2 +// 7a92 - DMA_TAR_AddrL2 +// 7a93 - DMA_TCountL2 +// 7a94 - DMA_SRC_AddrH2 +// 7a95 - DMA_TAR_AddrH2 +// 7a96 - DMA_TCountH2 +// 7a97 - DMA_MISC2 +// 7a98 - DMA_Ctrl3 +// 7a99 - DMA_SRC_AddrL3 +// 7a9a - DMA_TAR_AddrL3 +// 7a9b - DMA_TCountL3 +// 7a9c - DMA_SRC_AddrH3 +// 7a9d - DMA_TAR_AddrH3 +// 7a9e - DMA_TCountH3 +// 7a9f - DMA_MISC3 +// +// 7ab0 - DMA_SPRISIZE0 +// 7ab1 - DMA_SPRISIZE1 +// 7ab2 - DMA_SPRISIZE2 +// 7ab3 - DMA_SPRISIZE3 +// +// 7abd - DMA_LineLength +// 7abe - DMA_SS +// 7abf - DMA_INT +// +// 7ac0 - KS_Ctrl1 +// 7ac1 - KS_Ctrl2 +// 7ac2 - KS_Addr +// 7ac3 - KS_Velocity +// +// 7ac8 - KS_Data0 +// 7ac9 - KS_Data1 +// 7aca - KS_Data2 +// 7acb - KS_Data3 +// 7acc - KS_Data4 +// 7acd - KS_Data5 +// 7ace - KS_Data6 +// 7acf - KS_Data7 +// 7ad0 - KS_Data8 +// 7ad1 - KS_Data9 +// 7ad2 - KS_Data10 +// +// 7ae0 - E-Fuse0 +// 7ae1 - E-Fuse1 +// 7ae2 - E-Fuse2 +// 7ae3 - E-Fuse3 +// // 7af0 - Byte_Swap // 7af1 - Nibble_Swap // 7af2 - TwoBit_Swap From 728db9fc37c379f38877024a7ff868f99ce0be0c Mon Sep 17 00:00:00 2001 From: David Haywood Date: Sat, 18 Oct 2025 03:30:41 +0100 Subject: [PATCH 37/53] fix include guards --- src/devices/machine/generalplus_gpl1625x_soc.cpp | 7 ++++++- src/devices/machine/generalplus_gpl162xx_soc.h | 6 +++--- src/devices/machine/generalplus_gpl162xx_soc_video.h | 6 +++--- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/src/devices/machine/generalplus_gpl1625x_soc.cpp b/src/devices/machine/generalplus_gpl1625x_soc.cpp index efc54b954a847..c94c7e7ea8eaf 100644 --- a/src/devices/machine/generalplus_gpl1625x_soc.cpp +++ b/src/devices/machine/generalplus_gpl1625x_soc.cpp @@ -558,7 +558,12 @@ // 7af1 - Nibble_Swap // 7af2 - TwoBit_Swap // 7af3 - Bit_Reverse - +// +// 7b80 to 7b9f Sound Channel 0-15 regs +// 7ba0 to 7bbf Sound Channel 16-31 regs +// +// 7c00 - 7dff Sound Attribute +// 7e00 - 7fff Sound Phase DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL1625x System-on-a-Chip (with NAND handling)") DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL1625x System-on-a-Chip (with SPI handling)") diff --git a/src/devices/machine/generalplus_gpl162xx_soc.h b/src/devices/machine/generalplus_gpl162xx_soc.h index e70801a05fb09..ed68b581e047e 100644 --- a/src/devices/machine/generalplus_gpl162xx_soc.h +++ b/src/devices/machine/generalplus_gpl162xx_soc.h @@ -6,8 +6,8 @@ **********************************************************************/ -#ifndef MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H -#define MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H +#ifndef MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_H +#define MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_H #pragma once @@ -376,4 +376,4 @@ DECLARE_DEVICE_TYPE(GCM394, sunplus_gcm394_device) -#endif // MAME_MACHINE_GENERALPLUS_GPL16250_SOC_H +#endif // MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_H diff --git a/src/devices/machine/generalplus_gpl162xx_soc_video.h b/src/devices/machine/generalplus_gpl162xx_soc_video.h index 68596c7eedd63..c836ec690356d 100644 --- a/src/devices/machine/generalplus_gpl162xx_soc_video.h +++ b/src/devices/machine/generalplus_gpl162xx_soc_video.h @@ -6,8 +6,8 @@ **********************************************************************/ -#ifndef MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H -#define MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H +#ifndef MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_VIDEO_H +#define MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_VIDEO_H #pragma once @@ -259,4 +259,4 @@ class gcm394_video_device : public gcm394_base_video_device DECLARE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device) -#endif // MAME_MACHINE_GENERALPLUS_GPL16250_SOC_VIDEO_H +#endif // MAME_MACHINE_GENERALPLUS_GPL162XX_SOC_VIDEO_H From aa4d3c64455685f993be6322ee08c7ee7f4636f5 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Sat, 18 Oct 2025 14:50:56 +0100 Subject: [PATCH 38/53] add one, boots to menu --- src/mame/mame.lst | 1 + src/mame/tvgames/spg2xx_wiwi.cpp | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 1c2a9f94dfa4f..7281234df7edb 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47434,6 +47434,7 @@ inmotion lexifit marc101 marc250 +wiii3spt wiwi18 @source:tvgames/spg2xx_zone.cpp diff --git a/src/mame/tvgames/spg2xx_wiwi.cpp b/src/mame/tvgames/spg2xx_wiwi.cpp index ea566216a439f..6c285a943de6d 100644 --- a/src/mame/tvgames/spg2xx_wiwi.cpp +++ b/src/mame/tvgames/spg2xx_wiwi.cpp @@ -990,6 +990,11 @@ ROM_START( inmotion ) ROM_LOAD16_WORD_SWAP( "mx26l25722mc.bin", 0x000000, 0x2000000, CRC(81125997) SHA1(824607a3665b1351bccf27de4885a26ca86b40a5) ) ROM_END +ROM_START( wiii3spt ) + ROM_REGION( 0x2000000, "maincpu", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "vii3_7.bin", 0x000000, 0x2000000, CRC(f9176352) SHA1(ec05432c6d5a94a3eba0ece74c3cf3feeada007f) ) +ROM_END + ROM_START( marc101 ) ROM_REGION( 0x4000000, "maincpu", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "m489.u6", 0x0000000, 0x4000000, CRC(0a01695f) SHA1(1a13c5eb9dffdc91fc68a98e8f35bd8a019a8373) ) @@ -1038,6 +1043,8 @@ CONS( 200?, foxsport, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, // as with the above sets, inputs aren't currently hooked up, menu can be used by modifying 0x100f in RAM (it's 0x1010 for wiwi18) CONS( 200?, inmotion, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "Grafix", "IN Motion - Motion Controlled Video Games Console (Hot Game 198 in 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) +CONS( 200?, wiii3spt, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "", "Wiii3 7-in1 Sports", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) + // thtere is another 'Drahtlose Spielekonsole 48-in-1' with '11 hyper sports games' (including Running) which are clearly SunPlus and would fit here, with the 37 non-hyper sports games presumably again being a NES/Famiclone cart CONS( 2014, marc101, 0, 0, marc101, m489, spg2xx_game_marc101_state, empty_init, "Millennium 2000 GmbH", "Millennium Arcade 101 (M489) (Game Station 2 101-in-1)", MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) From b099a365b1b46d9852089e598e903cd28538c837 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Sat, 18 Oct 2025 18:05:52 +0100 Subject: [PATCH 39/53] better metadata --- src/mame/tvgames/spg2xx_wiwi.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mame/tvgames/spg2xx_wiwi.cpp b/src/mame/tvgames/spg2xx_wiwi.cpp index 6c285a943de6d..a6902f3fa98c4 100644 --- a/src/mame/tvgames/spg2xx_wiwi.cpp +++ b/src/mame/tvgames/spg2xx_wiwi.cpp @@ -1043,7 +1043,7 @@ CONS( 200?, foxsport, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, // as with the above sets, inputs aren't currently hooked up, menu can be used by modifying 0x100f in RAM (it's 0x1010 for wiwi18) CONS( 200?, inmotion, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "Grafix", "IN Motion - Motion Controlled Video Games Console (Hot Game 198 in 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) -CONS( 200?, wiii3spt, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "", "Wiii3 7-in1 Sports", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) +CONS( 200?, wiii3spt, 0, 0, rad_skat, wiwi18, spg2xx_game_wiwi18_state, init_wiwi18, "BL", "Wiii3 TV Entertainment System (7-in-1 Sports)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND | MACHINE_IMPERFECT_GRAPHICS ) // thtere is another 'Drahtlose Spielekonsole 48-in-1' with '11 hyper sports games' (including Running) which are clearly SunPlus and would fit here, with the 37 non-hyper sports games presumably again being a NES/Famiclone cart From 6292a4dd6ecd46bc7a675d62014b0f38ea8d95a5 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 13:08:40 +0100 Subject: [PATCH 40/53] added Retro TV Game Console - Disney Cars - 300 Games (JG7800DC-1) --- src/mame/mame.lst | 1 + src/mame/nintendo/nes_vt369_vtunknown.cpp | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 7281234df7edb..bd148f6180707 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -35799,6 +35799,7 @@ rbbrite rd5_240 red5mam rtvgc300 +rtvgc300cr rtvgc300fz s10fake sealvt diff --git a/src/mame/nintendo/nes_vt369_vtunknown.cpp b/src/mame/nintendo/nes_vt369_vtunknown.cpp index c279b1199f65a..239b57753bce4 100644 --- a/src/mame/nintendo/nes_vt369_vtunknown.cpp +++ b/src/mame/nintendo/nes_vt369_vtunknown.cpp @@ -634,12 +634,17 @@ ROM_END ROM_START( rtvgc300fz ) ROM_REGION( 0x8000000, "mainrom", 0 ) - // some of the higher address lines might be swapped ROM_LOAD( "jg7800fz.bin", 0x00000, 0x4000000, CRC(c9d319d2) SHA1(9d0d1435b802f63ce11b94ce54d11f4065b324cc) ) VT3XX_INTERNAL_NO_SWAP // not verified for this set, used for testing ROM_END +ROM_START( rtvgc300cr ) + ROM_REGION( 0x8000000, "mainrom", 0 ) + ROM_LOAD( "jg7800dc-1.u6", 0x00000, 0x4000000, CRC(a21af365) SHA1(8af1370ccfd79c34de39d14c53438246519b16ba) ) + + VT3XX_INTERNAL_NO_SWAP // not verified for this set, used for testing +ROM_END ROM_START( dgun2561 ) // all games selectable ROM_REGION( 0x4000000, "mainrom", 0 ) @@ -1215,6 +1220,7 @@ CONS( 2012, dgun2561, 0, 0, vt36x_32mb_2banks_lexi, vt369, vt36x_state, empty // GB-NO13-Main-VT389-2 on PCBs - uses higher resolution mode (twice usual h-res?) CONS( 2016, rtvgc300, 0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - 300 Games", MACHINE_NOT_WORKING ) CONS( 2017, rtvgc300fz,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - Frozen - 300 Games", MACHINE_NOT_WORKING ) +CONS( 2017, rtvgc300cr,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - Disney Cars - 300 Games (JG7800DC-1)", MACHINE_NOT_WORKING ) /* The following are also confirmed to be NES/VT derived units, most having a standard set of games with a handful of lazy graphic mods thrown in to fit the unit theme @@ -1230,7 +1236,6 @@ CONS( 2017, rtvgc300fz,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, em Lexibook Console Colour - Barbie (units for use with TV) - Lexibook Retro TV Game Console (300 Games) - Cars Lexibook Retro TV Game Console (300 Games) - PJ Masks (more?) From 475896c4b981d74ee52dec7e7e4a756aed10b3fe Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 13:56:29 +0100 Subject: [PATCH 41/53] add some Sega Toys Pets (names to be confirmed) --- src/mame/mame.lst | 6 ++++ src/mame/tvgames/generalplus_gpl951xx.cpp | 40 +++++++++++++++++++++++ 2 files changed, 46 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index bd148f6180707..c1197e11d83ec 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47075,6 +47075,12 @@ punij1pk punij1pu punij2pk punirune +segapet1 +segapet1a +segapet2 +segapet2a +segapet3 +segapet3a smkcatch smkguras smkgurasa diff --git a/src/mame/tvgames/generalplus_gpl951xx.cpp b/src/mame/tvgames/generalplus_gpl951xx.cpp index ba7706af94e35..841c0a7081c01 100644 --- a/src/mame/tvgames/generalplus_gpl951xx.cpp +++ b/src/mame/tvgames/generalplus_gpl951xx.cpp @@ -266,6 +266,35 @@ ROM_START( dsgnpal ) ROM_LOAD16_WORD_SWAP( "gpr25l64.ic2", 0x0000, 0x800000, CRC(a1017ea8) SHA1(bd4b553ff71e763cd3fd726c49f5408eac3b7984) ) ROM_END +ROM_START( segapet1 ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "pink_gpr25l64.ic3", 0x0000, 0x800000, CRC(3bb709d1) SHA1(8a1b34d6cdd856685182d19b86c5cb68a006f816) ) +ROM_END + +ROM_START( segapet1a ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "yellow_gpr25l64.ic3", 0x0000, 0x800000, CRC(073218b8) SHA1(8501e69dc2b2cda9e4c289a14d6a16fe832e722c) ) +ROM_END + +ROM_START( segapet2 ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "purple_gpr25l64.ic3", 0x0000, 0x800000, CRC(e223eabf) SHA1(fa88173361af7f8cb7651bd7ccb73d7137eb6cf9) ) +ROM_END + +ROM_START( segapet2a ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "orange_gpr25l64.ic3", 0x0000, 0x800000, CRC(25605da6) SHA1(2733f30037551b2e5895efbb19ed953e81405141) ) +ROM_END + +ROM_START( segapet3 ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "pink_gpr25l64.ic3", 0x0000, 0x800000, CRC(4b60f556) SHA1(3487c7b42e1b818ac1fe3a9429320519574ca4ac) ) +ROM_END + +ROM_START( segapet3a ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "blue_gpr25l64.ic3", 0x0000, 0x800000, CRC(02a63c63) SHA1(54d8c1c52a30d7b2a21f69439d9ff2ef7b2a606b) ) +ROM_END void generalplus_gpspi_direct_game_state::init_fif() { @@ -326,3 +355,14 @@ CONS( 201?, smkgurasa, smkguras, 0, generalplus_gpspi_direct, bfmpac, generalplu // there seem to be different versions of this available, is the software the same? CONS( 201?, dsgnpal, 0, 0, generalplus_gpspi_direct, bfmpac, generalplus_gpspi_direct_game_state, empty_init, "Tomy", "Kiratto Pri-Chan Design Palette (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) + +// for these Sega Toys pets the clones might end up being duplicates with only different user data, however they might also have different factory default data for each colour +CONS( 2019, segapet1, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 1, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2019, segapet1a, segapet1, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 1, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) + +CONS( 2019, segapet2, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 2, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 2, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) + +// these ones have motors in the ears +CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) From e6935afb0f2a4a39f398fcb7aa93325907aebeb3 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 14:08:54 +0100 Subject: [PATCH 42/53] some more in the same driver --- src/mame/mame.lst | 2 ++ src/mame/tvgames/generalplus_gpl951xx.cpp | 13 +++++++++++++ 2 files changed, 15 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index c1197e11d83ec..869418cbe8d39 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47067,7 +47067,9 @@ bfmpac bfpacman bfspyhnt bftetris +bubltea dsgnpal +pokebala pokgoget punifrnd punij1m diff --git a/src/mame/tvgames/generalplus_gpl951xx.cpp b/src/mame/tvgames/generalplus_gpl951xx.cpp index 841c0a7081c01..af4d0a2036e83 100644 --- a/src/mame/tvgames/generalplus_gpl951xx.cpp +++ b/src/mame/tvgames/generalplus_gpl951xx.cpp @@ -246,6 +246,11 @@ ROM_START( pokgoget ) ROM_LOAD16_WORD_SWAP( "mx25l25645g.u1", 0x0000, 0x2000000, CRC(a76ae22f) SHA1(3fa5eeedb3fe343a7707d76710298377b22b0681) ) ROM_END +ROM_START( pokebala ) + ROM_REGION16_BE(0x2000000, "maincpu:spidirect", ROMREGION_ERASE00) + ROM_LOAD16_WORD_SWAP( "mx25l25645g.u4", 0x0000, 0x2000000, CRC(e35d434a) SHA1(74061831b25476ec8aa7dec5f9d64ff79b0db88e) ) +ROM_END + ROM_START( smkcatch ) ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "gpr25l64.u2", 0x0000, 0x800000, CRC(e2f52c4a) SHA1(f79862d27152cff8f96151c672d9762a3897a593) ) @@ -296,6 +301,11 @@ ROM_START( segapet3a ) ROM_LOAD16_WORD_SWAP( "blue_gpr25l64.ic3", 0x0000, 0x800000, CRC(02a63c63) SHA1(54d8c1c52a30d7b2a21f69439d9ff2ef7b2a606b) ) ROM_END +ROM_START( bubltea ) + ROM_REGION16_BE(0x800000, "maincpu:spidirect", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "gpr25l64.ic2", 0x0000, 0x800000, CRC(a6d73241) SHA1(bc67d932ffc83d91dc2d64f40bbce08c1e8b9f4e) ) +ROM_END + void generalplus_gpspi_direct_game_state::init_fif() { uint16_t* spirom16 = (uint16_t*)memregion("maincpu:spidirect")->base(); @@ -343,6 +353,7 @@ CONS(2021, punifrnd, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplu // Pocket Monsters ガチッとゲットだぜ! モンスターボールゴー! - Pocket Monsters is printed on the inner shell, but not the box? CONS(2021, pokgoget, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Takara Tomy", "Gachitto Get da ze! Monster Ball Go! (210406, Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS(2021, pokebala, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Takara Tomy", "Pokemon Ball (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) // 2020 (device) / 2021 (box) version of Sumikko Gurashi a cloud shaped device // Sumikko Gurashi - Sumikko Catch (すみっコぐらし すみっコキャッチ) @@ -366,3 +377,5 @@ CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalp // these ones have motors in the ears CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) + +CONS( 201?, bubltea, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Bandai", "Bubble Tea Pet", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) From 3684b72ad9364ae5e7b6c8e3db8109fd0d526a12 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 14:23:59 +0100 Subject: [PATCH 43/53] 2 more laptops --- src/mame/mame.lst | 2 ++ src/mame/tvgames/generalplus_gpl32612.cpp | 17 +++++++++++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 869418cbe8d39..3799e91bfe460 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47098,6 +47098,8 @@ airobo anpanm19 arcadege ardancem +bananlap +bandolap bandplap bandslap chiikpc diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index c4e9cef747b04..0ad2956caf834 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -322,6 +322,16 @@ ROM_START( bandplap ) ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(f85c388d) SHA1(59e30b51e2d6598881eb64edc027e0e27756631f) ) ROM_END +ROM_START( bananlap ) + ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) + ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(46441cd5) SHA1(da1891a21e23c60492719c2b953e453885fc1bde) ) +ROM_END + +ROM_START( bandolap ) + ROM_REGION( 0x800000, "spi", ROMREGION_ERASE00 ) + ROM_LOAD( "gpr25l64.u3", 0x0000, 0x800000, CRC(d9b1cb41) SHA1(03d550138973519522746298bce2865d85a5c4f2) ) +ROM_END + ROM_START( chiikpc ) ROM_REGION( 0x1000000, "spi", ROMREGION_ERASE00 ) ROM_LOAD( "25l12833f.u6", 0x0000, 0x1000000, CRC(bde74209) SHA1(8a91554ae653f4ed54fd354049c32b545e4d359d) ) @@ -518,12 +528,11 @@ CONS( 2019, anpanm19, 0, 0, gpl32612, gpl32612, generalplus_g // unknown (uses a glob) has GPspispi header, ARM based, SPI ROM CONS( 201?, smatomo, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Smatomo (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -// unknown (uses a glob) has GPspispi header, ARM based, SPI ROM +// (these all use the same PCB) - unknown SoC (uses a glob) has GPspispi header, ARM based, SPI ROM CONS( 2014, bandplap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney Princess 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) - -// unknown (uses a glob) has GPspispi header, ARM based, SPI ROM CONS( 2014, bandslap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) - +CONS( 2014, bananlap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Anpanman 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +CONS( 2014, bandolap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Doraemon 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // company is called 深圳市飞讯互动科技有限公司 // surface details erased on SoC for both of these From 2545a801ee2a5281bd2ad6f9d3d1a70b92932693 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 14:38:40 +0100 Subject: [PATCH 44/53] another VT handheld --- src/mame/mame.lst | 1 + src/mame/nintendo/nes_vt369_vtunknown.cpp | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 3799e91bfe460..f4e55b0052421 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -35813,6 +35813,7 @@ tup240 unk128vt unkra200 vibes240 +zl383 zonefusn @source:nintendo/nes_vt42xx.cpp diff --git a/src/mame/nintendo/nes_vt369_vtunknown.cpp b/src/mame/nintendo/nes_vt369_vtunknown.cpp index 239b57753bce4..03f016414dff1 100644 --- a/src/mame/nintendo/nes_vt369_vtunknown.cpp +++ b/src/mame/nintendo/nes_vt369_vtunknown.cpp @@ -136,6 +136,7 @@ class vt36x_state : public vt369_state void vt36x_altswap_16mb(machine_config& config); void vt36x_altswap_32mb_4banks_red5mam(machine_config& config); + void vt36x_vibesswap_8mb(machine_config& config); void vt36x_vibesswap_16mb(machine_config& config); void vt36x_gbox2020_16mb(machine_config& config); void vt36x_s10swap_8mb(machine_config& config); @@ -467,6 +468,12 @@ void vt36x_state::vt36x_vibesswap_16mb(machine_config &config) m_soc->set_addrmap(AS_PROGRAM, &vt36x_state::vt_external_space_map_16mbyte); } +void vt36x_state::vt36x_vibesswap_8mb(machine_config &config) +{ + vt36x_vibesswap_16mb(config); + m_soc->set_addrmap(AS_PROGRAM, &vt36x_state::vt_external_space_map_8mbyte); +} + void vt36x_state::vt36x_gbox2020_16mb(machine_config &config) { vt36x_swap_16mb(config); @@ -1104,6 +1111,11 @@ ROM_START( d9_500 ) ROM_LOAD( "w25q128jv.u3", 0x00000, 0x1000000, CRC(66b137ce) SHA1(699ffaaf086bdb2001b0c4323b1e098f2dd3f885) ) ROM_END +ROM_START( zl383 ) + ROM_REGION( 0x800000, "mainrom", 0 ) + ROM_LOAD( "s29gl064n90tfi04.u2", 0x00000, 0x800000, CRC(58e0011e) SHA1(38a3ed236f055b1a73cbb9582fc5ea151a296ba9) ) +ROM_END + ROM_START( dgun2572 ) ROM_REGION( 0x2000000, "mainrom", 0 ) // extra pins on subboard not marked ROM_LOAD( "dreamgearwgun.bin", 0x00000, 0x2000000, CRC(92b55c75) SHA1(c7b2319e304a4bf480b5dcd4f24af2e6ba834d0d) ) @@ -1289,6 +1301,8 @@ CONS( 202?, vibes240, 0, 0, vt36x_vibesswap_16mb, vt369, vt36x_state, em // boots and runs, but not all games have been tested CONS( 202?, t3_630, 0, 0, vt36x_vibesswap_16mb, vt369, vt36x_state, empty_init, "", "630 Games in 1 Handheld (T3)", MACHINE_NOT_WORKING ) +CONS( 202?, zl383, 0, 0, vt36x_vibesswap_8mb, vt369, vt36x_state, empty_init, "", "ZL-383 400-in-1 Handheld Console", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS ) + // has extra protection? CONS( 2018, rbbrite, 0, 0, vt369_unk_1mb, vt369, vt36x_state, empty_init, "Coleco", "Rainbow Brite (mini-arcade)", MACHINE_NOT_WORKING ) From 18ff90b7569a5dade702273c761a34320ff3f0c7 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 14:45:01 +0100 Subject: [PATCH 45/53] Spica Note --- src/mame/mame.lst | 1 + src/mame/tvgames/generalplus_gpl32612.cpp | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index f4e55b0052421..653e5cbbdfb8e 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -47123,6 +47123,7 @@ rotom2 saikyopc segdis16 smatomo +spicanot sumikpc sumikpcp sumipc21 diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 0ad2956caf834..20cd014a2db16 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -404,6 +404,14 @@ ROM_START( neopad ) ROM_LOAD( "tc58nvg0s3hta00.u2", 0x0000, 0x8800000, CRC(3b8f8c48) SHA1(1995d443c1ce8e44c9256c994e1f91eb5857b80c) ) ROM_END +ROM_START( spicanot ) + ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) + ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? + + ROM_REGION( 0x10800000, "nand", ROMREGION_ERASE00 ) + ROM_LOAD( "fs33nd02gs.nfrom201", 0x0000, 0x10800000, CRC(b7bff67c) SHA1(f2bc9c8937d62abfad3f91a1e4a3834d3687ea57) ) +ROM_END + ROM_START( sumikpc ) ROM_REGION16_BE( 0x40000, "maincpu:internal", ROMREGION_ERASE00 ) ROM_LOAD16_WORD_SWAP( "internal.rom", 0x00000, 0x40000, NO_DUMP ) // used as bootstrap only? @@ -611,3 +619,6 @@ CONS( 201?, rotom2, 0, 0, gpl32612, gpl32612, generalplu CONS( 201?, neopad, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init880, "Takara Tomy", "Shogakukan no Zukan NEO Pad - Ikimono-hen (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // a blue version exists with the subtitle Norimono + Kuraberu-hen (乗りもの+くらべる編). // another green version with 'DX' on the end of the title also exists + +// uses GPL32611 +CONS( 201?, spicanot, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, nand_init840, "Takara Tomy", "Spica Note (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) From c27c594b4ffbcc033784cf7efacc2e4e6105d15c Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 15:05:47 +0100 Subject: [PATCH 46/53] there are multiple Toumapet versions in different style casing, make a note of which one this came from --- src/mame/handheld/st2302u_bbl_spi.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mame/handheld/st2302u_bbl_spi.cpp b/src/mame/handheld/st2302u_bbl_spi.cpp index e4e514b90259b..09a0731e12f80 100644 --- a/src/mame/handheld/st2302u_bbl_spi.cpp +++ b/src/mame/handheld/st2302u_bbl_spi.cpp @@ -513,6 +513,7 @@ CONS( 201?, dphh8633, 0, 0, bbl380_menuprot, bbl380_prot, bbl3 CONS( 2016, dphh8661, 0, 0, bbl380_menuprot, bbl380_prot, bbl380_state, empty_init, "", "Digital Pocket Hand Held System 268-in-1 - Model 8661", MACHINE_NOT_WORKING ) // from PCP? (logo on back of console) 2016 date on PCB // also has the 0xE4 XOR, also doesn't currently boot, could be yet another internal ROM -CONS( 2021, toumapet, 0, 0, bbl380, bbl380, bbl380_state, empty_init, "Shenzhen Shiji New Technology", "Tou ma Pet", MACHINE_NOT_WORKING ) +// there are also OK-560 and OK-568 models which may have different ROM or be on different hardware +CONS( 2021, toumapet, 0, 0, bbl380, bbl380, bbl380_state, empty_init, "Shenzhen Shiji New Technology", "Tou ma Pet (OK-550)", MACHINE_NOT_WORKING ) CONS( 2020, qpet, 0, 0, bbl380, bbl380, bbl380_state, empty_init, "M&D", "Q Pet (2nd version)", MACHINE_NOT_WORKING ) From ca2c165d4ee7feee6548aa7c459fcf3e7ce0f66d Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 15:33:03 +0100 Subject: [PATCH 47/53] added a placeholder driver for Takara Tomy Orina Stylish+ to hold a Software List with the single dumped cartridge --- hash/orina_stylish_plus_cart.xml | 21 ++++++++ src/mame/mame.lst | 3 ++ src/mame/skeleton/orina_stylish_plus.cpp | 61 ++++++++++++++++++++++++ 3 files changed, 85 insertions(+) create mode 100644 hash/orina_stylish_plus_cart.xml create mode 100644 src/mame/skeleton/orina_stylish_plus.cpp diff --git a/hash/orina_stylish_plus_cart.xml b/hash/orina_stylish_plus_cart.xml new file mode 100644 index 0000000000000..cb3cca16e3dbc --- /dev/null +++ b/hash/orina_stylish_plus_cart.xml @@ -0,0 +1,21 @@ + + + + + + + + + Sumikko Gurashi + 2021 + Takara Tomy + + + + + + + + diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 653e5cbbdfb8e..3cc4839951549 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -43857,6 +43857,9 @@ c8002 @source:skeleton/optomaxv.cpp optomaxv +@source:skeleton/orinasp.cpp +orinasp + @source:skeleton/p8k.cpp p8000 p8000_16 diff --git a/src/mame/skeleton/orina_stylish_plus.cpp b/src/mame/skeleton/orina_stylish_plus.cpp new file mode 100644 index 0000000000000..b9c689008e678 --- /dev/null +++ b/src/mame/skeleton/orina_stylish_plus.cpp @@ -0,0 +1,61 @@ +// license:BSD-3-Clause +// copyright-holders: + +/* + This is a placeholder driver for the Orina Stylish Plus so that a + Software List for the cartridges can exist. + + Internal hardware of machine is currently unknown +*/ + +#include "emu.h" +#include "bus/generic/slot.h" +#include "bus/generic/carts.h" +#include "softlist_dev.h" + + +namespace { + +class orinasp_state : public driver_device +{ +public: + orinasp_state(const machine_config &mconfig, device_type type, const char *tag) : + driver_device(mconfig, type, tag), + m_cart(*this, "cartslot") + { } + + void orinasp(machine_config &config); +protected: + DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load); + optional_device m_cart; +}; + + +static INPUT_PORTS_START( orinasp ) +INPUT_PORTS_END + +DEVICE_IMAGE_LOAD_MEMBER(orinasp_state::cart_load) +{ + uint32_t size = m_cart->common_get_size("rom"); + m_cart->rom_alloc(size, GENERIC_ROM16_WIDTH, ENDIANNESS_LITTLE); + m_cart->common_load_rom(m_cart->get_rom_base(), size, "rom"); + return std::make_pair(std::error_condition(), std::string()); +} + +void orinasp_state::orinasp(machine_config &config) +{ + GENERIC_CARTSLOT(config, m_cart, generic_plain_slot, "orina_stylish_plus_cart"); + m_cart->set_width(GENERIC_ROM16_WIDTH); + m_cart->set_device_load(FUNC(orinasp_state::cart_load)); + m_cart->set_must_be_loaded(true); + + SOFTWARE_LIST(config, "cart_list").set_original("orina_stylish_plus_cart"); +} + +ROM_START( orinasp ) +ROM_END + +} // anonymous namespace + + +CONS( 2021, orinasp, 0, 0, orinasp, orinasp, orinasp_state, empty_init, "Takara Tomy", "Orina Stylish+ (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) From 93b07affd53f6ccb0eec60fd637cdf4abed38e45 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 16:33:07 +0100 Subject: [PATCH 48/53] another skeleton --- src/mame/handheld/gw35th.cpp | 80 ++++++++++++++++++++++++++++++++++++ src/mame/mame.lst | 3 ++ 2 files changed, 83 insertions(+) create mode 100644 src/mame/handheld/gw35th.cpp diff --git a/src/mame/handheld/gw35th.cpp b/src/mame/handheld/gw35th.cpp new file mode 100644 index 0000000000000..5208737b2f1f0 --- /dev/null +++ b/src/mame/handheld/gw35th.cpp @@ -0,0 +1,80 @@ +// license:BSD-3-Clause +// copyright-holders: + +#include "emu.h" + +#include "cpu/arm7/arm7.h" + +#include "screen.h" +#include "speaker.h" + + +namespace { + +class gw35th_state : public driver_device +{ +public: + gw35th_state(const machine_config &mconfig, device_type type, const char *tag) + : driver_device(mconfig, type, tag) + , m_maincpu(*this, "maincpu") + , m_screen(*this, "screen") + { } + + void gw35th(machine_config &config); + +protected: + virtual void machine_start() override ATTR_COLD; + virtual void machine_reset() override ATTR_COLD; + +private: + required_device m_maincpu; + required_device m_screen; + + uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); + + void arm_map(address_map &map) ATTR_COLD; +}; + +uint32_t gw35th_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) +{ + return 0; +} + +void gw35th_state::machine_start() +{ +} + +void gw35th_state::machine_reset() +{ +} + +static INPUT_PORTS_START( gw35th ) +INPUT_PORTS_END + + +void gw35th_state::arm_map(address_map &map) +{ +} + +void gw35th_state::gw35th(machine_config &config) +{ + ARM9(config, m_maincpu, 480000000); // STM32H780 + m_maincpu->set_addrmap(AS_PROGRAM, &gw35th_state::arm_map); + + SCREEN(config, m_screen, SCREEN_TYPE_RASTER); + m_screen->set_refresh_hz(60); + m_screen->set_size(320, 262); + m_screen->set_visarea(0, 320-1, 0, 240-1); + m_screen->set_screen_update(FUNC(gw35th_state::screen_update)); + + SPEAKER(config, "speaker", 2).front(); +} + +ROM_START( gwsmb35 ) + ROM_REGION( 0x100000, "maincpu", ROMREGION_ERASEFF ) + ROM_LOAD( "mx25u8035e.bin", 0x000000, 0x100000, CRC(e261a5bf) SHA1(4ce600f725f166e9f0dfd9e3b2f61ef95fa6383c) ) +ROM_END + +} // anonymous namespace + +CONS( 2020, gwsmb35, 0, 0, gw35th, gw35th, gw35th_state, empty_init, "Nintendo", "Game & Watch: Super Mario Bros. 35th Anniversary", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 3cc4839951549..852b2b6015f33 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19488,6 +19488,9 @@ taturtf @source:handheld/generalplus_gpel31xx.cpp tamameet +@source:handheld/gw35th.cpp +gwsmb35 + @source:handheld/hh_cop400.cpp bshipg comparca From e83b37790564609a85143da0a8ac533d4008c7c9 Mon Sep 17 00:00:00 2001 From: David Haywood Date: Tue, 21 Oct 2025 17:04:52 +0100 Subject: [PATCH 49/53] update years --- src/mame/tvgames/generalplus_gpl951xx.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/mame/tvgames/generalplus_gpl951xx.cpp b/src/mame/tvgames/generalplus_gpl951xx.cpp index af4d0a2036e83..9abb22e1b4e78 100644 --- a/src/mame/tvgames/generalplus_gpl951xx.cpp +++ b/src/mame/tvgames/generalplus_gpl951xx.cpp @@ -368,14 +368,15 @@ CONS( 201?, smkgurasa, smkguras, 0, generalplus_gpspi_direct, bfmpac, generalplu CONS( 201?, dsgnpal, 0, 0, generalplus_gpspi_direct, bfmpac, generalplus_gpspi_direct_game_state, empty_init, "Tomy", "Kiratto Pri-Chan Design Palette (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // for these Sega Toys pets the clones might end up being duplicates with only different user data, however they might also have different factory default data for each colour -CONS( 2019, segapet1, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 1, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2019, segapet1a, segapet1, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 1, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2018, segapet1, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2018 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2018, segapet1a, segapet1, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2018 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +// a 'DX' version also exists, unclear if it's different software or just different packaging with bonuses -CONS( 2019, segapet2, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 2, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 2, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2019, segapet2, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2019 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2019 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) // these ones have motors in the ears -CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (type 3, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2020 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2020 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) CONS( 201?, bubltea, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Bandai", "Bubble Tea Pet", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) From 3be6a4db7839deebfcfd90ab652c9a31e8d455ff Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 22 Oct 2025 01:58:16 +0100 Subject: [PATCH 50/53] improved metadata from AJR --- src/mame/handheld/yuleyuan.cpp | 3 ++- src/mame/tvgames/generalplus_gpl32612.cpp | 15 +++++++---- src/mame/tvgames/generalplus_gpl951xx.cpp | 32 +++++++++++++---------- 3 files changed, 30 insertions(+), 20 deletions(-) diff --git a/src/mame/handheld/yuleyuan.cpp b/src/mame/handheld/yuleyuan.cpp index 82c9ff468a4fb..1e37f0f87e1a9 100644 --- a/src/mame/handheld/yuleyuan.cpp +++ b/src/mame/handheld/yuleyuan.cpp @@ -69,4 +69,5 @@ ROM_END } // anonymous namespace -GAME( 2022, yuleyuan, 0, yuleyuan, yuleyuan, yuleyuan_state, empty_init, ROT0, "Yule Yuan", "Yule Yuan Electronic Pet", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) +// 星座电子宠物机 +GAME( 2022, yuleyuan, 0, yuleyuan, yuleyuan, yuleyuan_state, empty_init, ROT0, "Yule Yuan", "Xingzuo Dianzi Chongwu Ji", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) // dumped from yellow model diff --git a/src/mame/tvgames/generalplus_gpl32612.cpp b/src/mame/tvgames/generalplus_gpl32612.cpp index 20cd014a2db16..bf926acb8131b 100644 --- a/src/mame/tvgames/generalplus_gpl32612.cpp +++ b/src/mame/tvgames/generalplus_gpl32612.cpp @@ -537,10 +537,14 @@ CONS( 2019, anpanm19, 0, 0, gpl32612, gpl32612, generalplus_g CONS( 201?, smatomo, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Smatomo (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // (these all use the same PCB) - unknown SoC (uses a glob) has GPspispi header, ARM based, SPI ROM -CONS( 2014, bandplap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney Princess 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -CONS( 2014, bandslap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -CONS( 2014, bananlap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Anpanman 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) -CONS( 2014, bandolap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Doraemon 2014 Laptop (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// ディズニー&ディズニー/ピクサーキャラクターズ ワンダフルスイートパソコン +CONS( 2014, bandplap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney & Disney/Pixar Characters Wonderful Sweet PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// ディズニー&ディズニー/ピクサーキャラクターズ ワンダフルドリームパソコン +CONS( 2014, bandslap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Disney & Disney/Pixar Characters Wonderful Dream PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// あそんでまなべる!マウスでクリック!アンパンマンパソコン +CONS( 2014, bananlap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Asonde Manaberu! Mouse de Click! Anpanman PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// ドラえもんステップアップパソコン +CONS( 2014, bandolap, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Bandai", "Doraemon Step Up PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // company is called 深圳市飞讯互动科技有限公司 // surface details erased on SoC for both of these @@ -604,7 +608,8 @@ CONS( 2021, sumipc21, 0, 0, gpl32612, gpl32612, generalpl CONS( 2016, segdis16, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Disney Characters Magical Pad -Girls Lesson- (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // uses GPL32600A -CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Dinosaur PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) +// マウスでバトル!! 恐竜図鑑パソコン +CONS( 2020, dinopc, 0, 0, gpl32612, gpl32612, generalplus_gpl32612_game_state, empty_init, "Sega Toys", "Mouse de Battle!! Kyouryuu Zukan PC (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // ディズニー&ディズニー/ピクサーキャラクターズ できた!がいっぱい ドリームトイパッド diff --git a/src/mame/tvgames/generalplus_gpl951xx.cpp b/src/mame/tvgames/generalplus_gpl951xx.cpp index 9abb22e1b4e78..6935df025896b 100644 --- a/src/mame/tvgames/generalplus_gpl951xx.cpp +++ b/src/mame/tvgames/generalplus_gpl951xx.cpp @@ -352,8 +352,8 @@ CONS(2021, punifrnd, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplu // Pocket Monsters ガチッとゲットだぜ! モンスターボールゴー! - Pocket Monsters is printed on the inner shell, but not the box? CONS(2021, pokgoget, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Takara Tomy", "Gachitto Get da ze! Monster Ball Go! (210406, Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) - -CONS(2021, pokebala, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Takara Tomy", "Pokemon Ball (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +// ガチッとゲットだぜ! モンスターボール +CONS(2021, pokebala, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Takara Tomy", "Gachitto Get da ze! Monster Ball (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) // 2020 (device) / 2021 (box) version of Sumikko Gurashi a cloud shaped device // Sumikko Gurashi - Sumikko Catch (すみっコぐらし すみっコキャッチ) @@ -368,15 +368,19 @@ CONS( 201?, smkgurasa, smkguras, 0, generalplus_gpspi_direct, bfmpac, generalplu CONS( 201?, dsgnpal, 0, 0, generalplus_gpspi_direct, bfmpac, generalplus_gpspi_direct_game_state, empty_init, "Tomy", "Kiratto Pri-Chan Design Palette (Japan)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING) // for these Sega Toys pets the clones might end up being duplicates with only different user data, however they might also have different factory default data for each colour -CONS( 2018, segapet1, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2018 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2018, segapet1a, segapet1, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2018 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -// a 'DX' version also exists, unclear if it's different software or just different packaging with bonuses - -CONS( 2019, segapet2, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2019 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2019 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) - -// these ones have motors in the ears -CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2020 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) -CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Soft Pet Toy (2020 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) - -CONS( 201?, bubltea, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Bandai", "Bubble Tea Pet", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +// もっちりペット もっちまるず +CONS( 2018, segapet1, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchiri Pet Mocchimaruzu (2018 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2018, segapet1a, segapet1, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchiri Pet Mocchimaruzu (2018 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +// a 'DX' version (dated 2020) also exists, unclear if it's different software or just different packaging with bonuses + +// also もっちりペット もっちまるず +CONS( 2019, segapet2, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchiri Pet Mocchimaruzu (2019 version, set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2019, segapet2a, segapet2, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchiri Pet Mocchimaruzu (2019 version, set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) + +// these ones have motors in the ears and a more fluffy cover +// もっちふわペット もっちまるず +CONS( 2020, segapet3, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchifuwa Pet Mocchimaruzu (set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) +CONS( 2020, segapet3a, segapet3, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Sega Toys", "Mocchifuwa Pet Mocchimaruzu (set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) + +// まぜまぜミックス!ぷにタピちゃん +CONS( 201?, bubltea, 0, 0, generalplus_gpspi_direct, bfspyhnt, generalplus_gpspi_direct_game_state, empty_init, "Bandai", "Mazemaze Mix! Puni Tapi-chan (Japan)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_SOUND) From fa914efe7a0c9a55736f7dc5771a0d1b6086742c Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 22 Oct 2025 14:07:36 +0100 Subject: [PATCH 51/53] fix for validation --- src/mame/mame.lst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 746d12486d17f..90fd2c03ae133 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -43877,7 +43877,7 @@ c8002 @source:skeleton/optomaxv.cpp optomaxv -@source:skeleton/orinasp.cpp +@source:skeleton/orina_stylish_plus.cpp orinasp @source:skeleton/p8k.cpp From a07ae22dc5ab0232a7fe3bf1c9f55d455192598b Mon Sep 17 00:00:00 2001 From: David Haywood Date: Wed, 22 Oct 2025 19:33:12 +0100 Subject: [PATCH 52/53] add one more set --- src/mame/mame.lst | 1 + src/mame/nintendo/nes_vt369_vtunknown.cpp | 11 ++++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index 90fd2c03ae133..e0128f36019c0 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -35814,6 +35814,7 @@ red5mam rtvgc300 rtvgc300cr rtvgc300fz +rtvgc300pj s10fake sealvt supr200 diff --git a/src/mame/nintendo/nes_vt369_vtunknown.cpp b/src/mame/nintendo/nes_vt369_vtunknown.cpp index 03f016414dff1..391abaa1cf79b 100644 --- a/src/mame/nintendo/nes_vt369_vtunknown.cpp +++ b/src/mame/nintendo/nes_vt369_vtunknown.cpp @@ -653,6 +653,13 @@ ROM_START( rtvgc300cr ) VT3XX_INTERNAL_NO_SWAP // not verified for this set, used for testing ROM_END +ROM_START( rtvgc300pj ) + ROM_REGION( 0x8000000, "mainrom", 0 ) + ROM_LOAD( "jg7800pjm-1.u6", 0x00000, 0x4000000, CRC(ea472bf0) SHA1(2864d96da0ecf123f1b143aa53c7faab5ed121d2) ) + + VT3XX_INTERNAL_NO_SWAP // not verified for this set, used for testing +ROM_END + ROM_START( dgun2561 ) // all games selectable ROM_REGION( 0x4000000, "mainrom", 0 ) ROM_LOAD( "dgun2561.bin", 0x00000, 0x4000000, CRC(a6e627b4) SHA1(2667d2feb02de349387f9dcfa5418e7ed3afeef6) ) @@ -1233,6 +1240,7 @@ CONS( 2012, dgun2561, 0, 0, vt36x_32mb_2banks_lexi, vt369, vt36x_state, empty CONS( 2016, rtvgc300, 0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - 300 Games", MACHINE_NOT_WORKING ) CONS( 2017, rtvgc300fz,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - Frozen - 300 Games", MACHINE_NOT_WORKING ) CONS( 2017, rtvgc300cr,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - Disney Cars - 300 Games (JG7800DC-1)", MACHINE_NOT_WORKING ) +CONS( 2018, rtvgc300pj,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, empty_init, "Lexibook", "Retro TV Game Console - PJ Masks - 300 Games (JG7800PJM-1)", MACHINE_NOT_WORKING ) /* The following are also confirmed to be NES/VT derived units, most having a standard set of games with a handful of lazy graphic mods thrown in to fit the unit theme @@ -1247,9 +1255,6 @@ CONS( 2017, rtvgc300cr,0, 0, vt36x_32mb_2banks_lexi300, vt369, vt36x_state, em (Handheld units, but different form factor to Compact Cyber Arcade, charged via USB, different menus) Lexibook Console Colour - Barbie - (units for use with TV) - Lexibook Retro TV Game Console (300 Games) - PJ Masks - (more?) There are also updated 'Compact Cyber Arcade' branded units with a large + D-pad and internal battery / USB charger for From b41e636fb997fac8a0eb332848d54ec8100e915c Mon Sep 17 00:00:00 2001 From: Ivan Vangelista Date: Thu, 23 Oct 2025 06:18:16 +0200 Subject: [PATCH 53/53] mame.lst: preserve alphabetical order --- src/mame/mame.lst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mame/mame.lst b/src/mame/mame.lst index e0128f36019c0..746c5799cdf2b 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -19475,9 +19475,6 @@ smkatsum gamekin3 gameking -@source:handheld/gmaster.cpp -gmaster - @source:handheld/generalplus_gpce4.cpp mapacman parcade @@ -19489,6 +19486,9 @@ taturtf @source:handheld/generalplus_gpel31xx.cpp tamameet +@source:handheld/gmaster.cpp +gmaster + @source:handheld/gw35th.cpp gwsmb35