summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author DavidHaywood <28625134+DavidHaywood@users.noreply.github.com>2018-10-28 18:17:24 +0000
committer DavidHaywood <28625134+DavidHaywood@users.noreply.github.com>2018-10-28 18:17:24 +0000
commit6a5ae54913b06228c2534f282ed179373f283619 (patch)
treeb704e0a2e552b9fd180379ae078668147a59d046
parent20c81f524b48d545ddbba9071e6b971b23060c83 (diff)
allow i2cmem to work with nostalgia games (page support causes hangs)
-rw-r--r--src/mame/drivers/xavix.cpp42
-rw-r--r--src/mame/includes/xavix.h7
2 files changed, 33 insertions, 16 deletions
diff --git a/src/mame/drivers/xavix.cpp b/src/mame/drivers/xavix.cpp
index 34fcb313409..8c3b047954d 100644
--- a/src/mame/drivers/xavix.cpp
+++ b/src/mame/drivers/xavix.cpp
@@ -786,10 +786,18 @@ MACHINE_CONFIG_START(xavix_state::xavix)
// sound is PCM
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(xavix_state::xavix_i2c)
+MACHINE_CONFIG_START(xavix_state::xavix_i2c_24lc04)
xavix(config);
- I2CMEM(config, "i2cmem", 0).set_page_size(16).set_data_size(0x200);
+ // according to http://ww1.microchip.com/downloads/en/devicedoc/21708k.pdf 'the master transmits up to 16 data bytes' however this breaks the Nostalgia games
+ // of note Galplus Phalanx on Namco Nostalgia 2, which will hang between stages unable to properly access the device, but with no page support it doesn't hang and scores save
+ I2CMEM(config, "i2cmem", 0)/*.set_page_size(16)*/.set_data_size(0x200); // 24LC04 on Nostalgia games, 24C04 on others
+MACHINE_CONFIG_END
+
+MACHINE_CONFIG_START(xavix_state::xavix_i2c_24c08)
+ xavix(config);
+
+ I2CMEM(config, "i2cmem", 0)/*.set_page_size(16)*/.set_data_size(0x400); // 24C08 (Excite Fishing DX)
MACHINE_CONFIG_END
MACHINE_CONFIG_START(xavix_state::xavixp)
@@ -817,10 +825,16 @@ MACHINE_CONFIG_START(xavix_state::xavix2000)
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(xavix_state::xavix2000_i2c)
+MACHINE_CONFIG_START(xavix_state::xavix2000_i2c_24c04)
+ xavix2000(config);
+
+ I2CMEM(config, "i2cmem", 0).set_page_size(16).set_data_size(0x200); // 24C04
+MACHINE_CONFIG_END
+
+MACHINE_CONFIG_START(xavix_state::xavix2000_i2c_24c02)
xavix2000(config);
- I2CMEM(config, "i2cmem", 0).set_page_size(16).set_data_size(0x200);
+ I2CMEM(config, "i2cmem", 0).set_page_size(16).set_data_size(0x100); // 24C02
MACHINE_CONFIG_END
void xavix_state::init_xavix()
@@ -977,13 +991,13 @@ ROM_END
/* Standalone TV Games */
-CONS( 2006, taitons1, 0, 0, xavix_i2c, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Taito", "Let's! TV Play Classic - Taito Nostalgia 1", MACHINE_IS_SKELETON )
+CONS( 2006, taitons1, 0, 0, xavix_i2c_24lc04, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Taito", "Let's! TV Play Classic - Taito Nostalgia 1", MACHINE_IS_SKELETON )
-CONS( 2006, taitons2, 0, 0, xavix_i2c, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Taito", "Let's! TV Play Classic - Taito Nostalgia 2", MACHINE_IS_SKELETON )
+CONS( 2006, taitons2, 0, 0, xavix_i2c_24lc04, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Taito", "Let's! TV Play Classic - Taito Nostalgia 2", MACHINE_IS_SKELETON )
-CONS( 2006, namcons1, 0, 0, xavix_i2c, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Namco", "Let's! TV Play Classic - Namco Nostalgia 1", MACHINE_IS_SKELETON )
+CONS( 2006, namcons1, 0, 0, xavix_i2c_24lc04, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Namco", "Let's! TV Play Classic - Namco Nostalgia 1", MACHINE_IS_SKELETON )
-CONS( 2006, namcons2, 0, 0, xavix_i2c, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Namco", "Let's! TV Play Classic - Namco Nostalgia 2", MACHINE_IS_SKELETON )
+CONS( 2006, namcons2, 0, 0, xavix_i2c_24lc04, namcons2, xavix_state, init_xavix, "Bandai / SSD Company LTD / Namco", "Let's! TV Play Classic - Namco Nostalgia 2", MACHINE_IS_SKELETON )
CONS( 2000, rad_ping, 0, 0, xavix, xavix, xavix_state, init_xavix, "Radica / SSD Company LTD / Simmer Technology", "Play TV Ping Pong", MACHINE_IS_SKELETON ) // "Simmer Technology" is also known as "Hummer Technology Co., Ltd"
@@ -1011,7 +1025,7 @@ CONS( 200?, rad_fb, 0, 0, xavix, xavix, xavix_state, init_xavix
CONS( 200?, rad_rh, 0, 0, xavix, rad_rh, xavix_state, init_xavix, "Radioa / Fisher-Price / SSD Company LTD", "Play TV Rescue Heroes", MACHINE_IS_SKELETON)
-CONS( 200?, epo_efdx, 0, 0, xavix_i2c, xavix, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Fishing DX (Japan)", MACHINE_IS_SKELETON)
+CONS( 200?, epo_efdx, 0, 0, xavix_i2c_24c08, xavix, xavix_state, init_xavix, "Epoch / SSD Company LTD", "Excite Fishing DX (Japan)", MACHINE_IS_SKELETON)
CONS( 200?, has_wamg, 0, 0, xavix, xavix, xavix_state, init_xavix, "Hasbro / Milton Bradley / SSD Company LTD", "TV Wild Adventure Mini Golf", MACHINE_IS_SKELETON)
@@ -1056,9 +1070,9 @@ ROM_START( drgqst )
ROM_END
-CONS( 2004, xavtenni, 0, 0, xavix2000_i2c, xavix, xavix_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_IS_SKELETON )
+CONS( 2004, xavtenni, 0, 0, xavix2000_i2c_24c04, xavix, xavix_state, init_xavix, "SSD Company LTD", "XaviX Tennis (XaviXPORT)", MACHINE_IS_SKELETON )
-CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_IS_SKELETON )
-CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_IS_SKELETON )
-CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c, ttv_mx, xavix_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IS_SKELETON )
-CONS( 2003, drgqst, 0, 0, xavix2000_i2c, xavix, xavix_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_IS_SKELETON )
+CONS( 2005, ttv_sw, 0, 0, xavix2000_i2c_24c02, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "Star Wars Saga Edition - Lightsaber Battle Game", MACHINE_IS_SKELETON )
+CONS( 2005, ttv_lotr, 0, 0, xavix2000_i2c_24c02, xavix, xavix_state, init_xavix, "Tiger / SSD Company LTD", "Lord Of The Rings - Warrior of Middle-Earth", MACHINE_IS_SKELETON )
+CONS( 2005, ttv_mx, 0, 0, xavix2000_i2c_24c04, ttv_mx, xavix_state, init_xavix, "Tiger / SSD Company LTD", "MX Dirt Rebel", MACHINE_IS_SKELETON )
+CONS( 2003, drgqst, 0, 0, xavix2000_i2c_24c02, xavix, xavix_state, init_xavix, "Square Enix / SSD Company LTD", "Kenshin Dragon Quest: Yomigaerishi Densetsu no Ken", MACHINE_IS_SKELETON )
diff --git a/src/mame/includes/xavix.h b/src/mame/includes/xavix.h
index 9f8b5e45c32..f73d3381c22 100644
--- a/src/mame/includes/xavix.h
+++ b/src/mame/includes/xavix.h
@@ -49,8 +49,11 @@ public:
void xavixp(machine_config &config);
void xavix2000(machine_config &config);
- void xavix_i2c(machine_config &config);
- void xavix2000_i2c(machine_config &config);
+ void xavix_i2c_24lc04(machine_config &config);
+ void xavix_i2c_24c08(machine_config &config);
+
+ void xavix2000_i2c_24c04(machine_config &config);
+ void xavix2000_i2c_24c02(machine_config &config);
void init_xavix();