summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author David Haywood <28625134+DavidHaywood@users.noreply.github.com>2020-01-25 11:17:10 +0000
committer Robert <Robbbert@users.noreply.github.com>2020-01-25 22:17:10 +1100
commit93c05f94d1dddfd757073acd15a519b846dbd27e (patch)
treebb42b239aa4460a89483222cc7902ef18ac71bfc
parent32da6fdbc7033a019d7cec16b13ac19876c178e1 (diff)
Plug and Play work (#6215)
* start looking at alt video modes used by elan hw sudoku (nw) * new NOT WORKING ---- Carl Edwards' Chase For Glory [Sean Riddle, TODO add credit] * new NOT WORKING ---- Golden Nugget Casino [Sean Riddle, TODO add credit] * new NOT WORKING ---- Sudoku Plug & Play TV Game (VT based) [Sean Riddle, TODO add credits] * notes / corrections as per Sean (nw)
-rw-r--r--src/mame/drivers/elan_eu3a05.cpp15
-rw-r--r--src/mame/drivers/nes_vt.cpp139
-rw-r--r--src/mame/drivers/spg2xx_senario.cpp1
-rw-r--r--src/mame/drivers/spg2xx_senario_poker.cpp2
-rw-r--r--src/mame/machine/elan_eu3a05commonsys.cpp5
-rw-r--r--src/mame/machine/elan_eu3a05commonsys.h4
-rw-r--r--src/mame/mame.lst5
-rw-r--r--src/mame/video/elan_eu3a05vid.cpp35
-rw-r--r--src/mame/video/elan_eu3a05vid.h6
9 files changed, 194 insertions, 18 deletions
diff --git a/src/mame/drivers/elan_eu3a05.cpp b/src/mame/drivers/elan_eu3a05.cpp
index 541bead1c4f..4a16685172b 100644
--- a/src/mame/drivers/elan_eu3a05.cpp
+++ b/src/mame/drivers/elan_eu3a05.cpp
@@ -545,6 +545,8 @@ void elan_eu3a05_state::elan_sudoku(machine_config& config)
{
elan_eu3a05(config);
m_maincpu->set_addrmap(AS_PROGRAM, &elan_eu3a05_state::elan_sudoku_map);
+ m_vid->set_is_sudoku();
+ m_sys->set_alt_timer(); // for Carl Edwards'
}
@@ -585,6 +587,17 @@ ROM_START( sudoelan )
ROM_RELOAD(0x300000,0x100000)
ROM_END
+ROM_START( carlecfg )
+ ROM_REGION( 0x400000, "maincpu", ROMREGION_ERASE00 )
+ ROM_LOAD( "carledwardsracing.bin", 0x00000, 0x100000, CRC(920f633e) SHA1(8460b77b9635a2484edab1111f35bbda74eb68e4) )
+ ROM_RELOAD(0x100000,0x100000)
+ ROM_RELOAD(0x200000,0x100000)
+ ROM_RELOAD(0x300000,0x100000)
+ROM_END
+
+
+
+
CONS( 2004, rad_sinv, 0, 0, elan_eu3a05, rad_sinv, elan_eu3a05_state, empty_init, "Radica (licensed from Taito)", "Space Invaders [Lunar Rescue, Colony 7, Qix, Phoenix] (Radica, Arcade Legends TV Game)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // "5 Taito games in 1"
@@ -594,3 +607,5 @@ CONS( 2004, rad_tetr, 0, 0, elan_eu3a05, rad_tetr, elan_eu3a05_state, empty_init
CONS( 2005, airblsjs, 0, 0, airblsjs, airblsjs, elan_eu3a05_state, empty_init, "Advance Bright Ltd", "Air-Blaster Joystick (AB1500, PAL)", MACHINE_NOT_WORKING )
CONS( 2006, sudoelan, 0, 0, elan_sudoku, sudoku, elan_eu3a05_state, empty_init, "Senario / All in 1 Products Ltd", "Ultimate Sudoku TV Edition 3-in-1", MACHINE_NOT_WORKING )
+
+CONS( 200?, carlecfg, 0, 0, elan_sudoku, sudoku, elan_eu3a05_state, empty_init, "Excalibur", "Carl Edwards' Chase For Glory", MACHINE_NOT_WORKING )
diff --git a/src/mame/drivers/nes_vt.cpp b/src/mame/drivers/nes_vt.cpp
index fd90d5bcef0..dee3020696b 100644
--- a/src/mame/drivers/nes_vt.cpp
+++ b/src/mame/drivers/nes_vt.cpp
@@ -449,6 +449,30 @@ private:
required_ioport m_io1;
};
+class nes_vt_majgnc_state : public nes_vt_state
+{
+public:
+ nes_vt_majgnc_state(const machine_config& mconfig, device_type type, const char* tag) :
+ nes_vt_state(mconfig, type, tag),
+ m_io0(*this,"IO0"),
+ m_io1(*this,"IO1")
+ { }
+
+ void nes_vt_majgnc(machine_config& config);
+
+protected:
+
+private:
+ DECLARE_READ8_MEMBER(in0_r);
+ DECLARE_READ8_MEMBER(in1_r);
+ DECLARE_WRITE8_MEMBER(in0_w);
+
+ void nes_vt_majgnc_map(address_map& map);
+
+ required_ioport m_io0;
+ required_ioport m_io1;
+};
+
@@ -1207,12 +1231,19 @@ void nes_vt_state::scrambled_8000_w(address_space& space, uint16_t offset, uint8
//MMC3 compat
if((addr < 0xA000) && !(addr & 0x01)) {
+
+ logerror("scrambled_8000_w (%04x) %02x (banking)\n", offset+0x8000, data );
+
+
// Bank select
m_8000_addr_latch = data & 0x07;
// Bank config
m_410x[0x05] = data & ~(1 << 5);
update_banks();
} else if((addr < 0xA000) && (addr & 0x01)) {
+
+ logerror("scrambled_8000_w (%04x) %02x (other scrambled stuff)\n", offset+0x8000, data );
+
switch(m_410x[0x05] & 0x07) {
case 0x00:
m_ppu->set_201x_reg(m_8000_scramble[0], data);
@@ -1552,6 +1583,20 @@ WRITE8_MEMBER(nes_vt_sudoku_state::in0_w)
{
}
+READ8_MEMBER(nes_vt_majgnc_state::in0_r)
+{
+ return 0x00;// machine().rand();
+}
+
+READ8_MEMBER(nes_vt_majgnc_state::in1_r)
+{
+ return 0x00;// machine().rand();
+}
+
+WRITE8_MEMBER(nes_vt_majgnc_state::in0_w)
+{
+}
+
void nes_vt_state::nes_vt_map(address_map &map)
{
map(0x0000, 0x07ff).ram();
@@ -1602,6 +1647,16 @@ void nes_vt_sudoku_state::nes_vt_sudoku_map(address_map& map)
map(0x4017, 0x4017).r(FUNC(nes_vt_sudoku_state::in1_r));
}
+void nes_vt_majgnc_state::nes_vt_majgnc_map(address_map& map)
+{
+ nes_vt_map(map);
+
+ map(0x4014, 0x4014).w(FUNC(nes_vt_majgnc_state::vt_dma_w));
+
+ map(0x4016, 0x4016).rw(FUNC(nes_vt_majgnc_state::in0_r),FUNC(nes_vt_majgnc_state::in0_w));
+ map(0x4017, 0x4017).r(FUNC(nes_vt_majgnc_state::in1_r));
+}
+
/* Some later VT models have more RAM */
void nes_vt_state::nes_vt_xx_map(address_map &map)
{
@@ -1836,11 +1891,16 @@ void nes_vt_ablpinb_state::nes_vt_ablpinb(machine_config &config)
void nes_vt_sudoku_state::nes_vt_sudoku(machine_config &config)
{
nes_vt_base(config);
-
- // override for controllers
m_maincpu->set_addrmap(AS_PROGRAM, &nes_vt_sudoku_state::nes_vt_sudoku_map);
}
+void nes_vt_majgnc_state::nes_vt_majgnc(machine_config &config)
+{
+ nes_vt_base(config);
+ m_maincpu->set_addrmap(AS_PROGRAM, &nes_vt_majgnc_state::nes_vt_majgnc_map);
+ m_ppu->set_palette_mode(PAL_MODE_NEW_VG);
+}
+
void nes_vt_state::nes_vt(machine_config &config)
{
nes_vt_base(config);
@@ -2031,6 +2091,60 @@ static INPUT_PORTS_START( sudoku )
PORT_START("IO1")
INPUT_PORTS_END
+static INPUT_PORTS_START( majgnc )
+ PORT_START("IO0")
+ PORT_DIPNAME( 0x01, 0x01, "0" )
+ PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+
+ PORT_START("IO1")
+ PORT_DIPNAME( 0x01, 0x01, "1" )
+ PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x02, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x04, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x08, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x10, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x40, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+ PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) )
+ PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
+ PORT_DIPSETTING( 0x00, DEF_STR( On ) )
+INPUT_PORTS_END
+
void nes_vt_sudoku_state::init_sudoku()
{
u8 *src = memregion("mainrom")->base();
@@ -2105,7 +2219,7 @@ ROM_START( vtboxing )
ROM_LOAD( "rom.bin", 0x00000, 0x80000, CRC(c115b1af) SHA1(82106e1c11c3279c5d8731c112f713fa3f290125) )
ROM_END
-ROM_START( sudokuv )
+ROM_START( papsudok )
ROM_REGION( 0x80000, "mainrom", 0 )
ROM_LOAD( "sudoku2.bin", 0x00000, 0x80000, CRC(d1ffcc1e) SHA1(2010e60933a08d0b9271ef37f338758aacba6d2d) )
ROM_END
@@ -2323,6 +2437,17 @@ ROM_START( majkon )
ROM_LOAD( "konamicollectorsseries.bin", 0x00000, 0x100000, CRC(47505e51) SHA1(3bfb05d7cfa2bb4c115335f0383fa4aa59db0b28) )
ROM_END
+ROM_START( majgnc )
+ ROM_REGION( 0x200000, "mainrom", ROMREGION_ERASEFF )
+ ROM_LOAD( "majescogoldennuggetcasino_st29w800at_002000d7.bin", 0x00000, 0x100000, CRC(1a156a9d) SHA1(08be4079dd68c9cf05bb92e11a3da4f092d7cfea) )
+ROM_END
+
+ROM_START( sudopptv )
+ ROM_REGION( 0x80000, "mainrom", ROMREGION_ERASEFF )
+ ROM_LOAD( "sudokupnptvgame_29lv400tc_000422b9.bin", 0x00000, 0x80000, CRC(722cc36d) SHA1(1f6d1f57478cf175a36722b39c52eded4b669f81) )
+ROM_END
+
+
ROM_START( ablping )
ROM_REGION( 0x200000, "mainrom", 0 )
ROM_LOAD( "abl_pingpong.bin", 0x00000, 0x200000, CRC(b31de1fb) SHA1(94e8afb2315ba1fa0892191c8e1832391e401c70) )
@@ -2450,9 +2575,9 @@ CONS( 200?, vtboxing, 0, 0, nes_vt, nes_vt, nes_vt_state, empty_init, "VRT
CONS( 2005, ablpinb, 0, 0, nes_vt_ablpinb, ablpinb, nes_vt_ablpinb_state, empty_init, "Advance Bright Ltd", "Pinball (P8002, ABL TV Game)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND )
-// Black pad marked 'SUDOKU' with tails on the S and U characters looping over the logo
+// Black pad marked 'SUDOKU' with tails on the S and U characters looping over the logo. Box says "Plug and Play Sudoku"
// Has 2 sets of 4 buttons in circular 'direction pad' layouts (on the left for directions, on the right for functions) and 9 red numbered buttons with red power LED on left of them, and reset button on right
-CONS( 200?, sudokuv, 0, 0, nes_vt_sudoku, sudoku, nes_vt_sudoku_state, init_sudoku, "<unknown>", "Plug and Play Sudoku (VT based)", MACHINE_NOT_WORKING )
+CONS( 200?, papsudok, 0, 0, nes_vt_sudoku, sudoku, nes_vt_sudoku_state, init_sudoku, "<unknown>", "Plug and Play Sudoku (VT based?)", MACHINE_NOT_WORKING )
// should be VT03 based
@@ -2466,6 +2591,10 @@ CONS( 2006, vgtablet, 0, 0, nes_vt_vg, nes_vt, nes_vt_hh_state, empty_i
// There is a 2004 Majesco Frogger "TV game" that appears to contain the same version of Frogger as above but with no other games, so probably fits here.
CONS( 2004, majkon, 0, 0, nes_vt_vg_baddma, nes_vt, nes_vt_hh_state, empty_init, "Majesco (licensed from Konami)", "Konami Collector's Series Arcade Advanced", MACHINE_NOT_WORKING ) // raster timing is broken for Frogger, palette issues
+CONS( 200?, majgnc, 0, 0, nes_vt_majgnc, majgnc, nes_vt_majgnc_state, empty_init, "Majesco", "Golden Nugget Casino", MACHINE_NOT_WORKING )
+
+// small black unit, dpad on left, 4 buttons (A,B,X,Y) on right, Start/Reset/Select in middle, unit text "Sudoku Plug & Play TV Game"
+CONS( 200?, sudopptv, 0, 0, nes_vt_majgnc, majgnc, nes_vt_majgnc_state, empty_init, "<unknown>", "Sudoku Plug & Play TV Game (VT based)", MACHINE_NOT_WORKING )
// this is VT09 based
// it boots, most games correct, but palette issues in some games still (usually they appear greyscale)
diff --git a/src/mame/drivers/spg2xx_senario.cpp b/src/mame/drivers/spg2xx_senario.cpp
index f4d670b15d2..237631325d9 100644
--- a/src/mame/drivers/spg2xx_senario.cpp
+++ b/src/mame/drivers/spg2xx_senario.cpp
@@ -296,6 +296,7 @@ ROM_START( senpmate )
ROM_REGION16_BE( 0x800000, "flash", ROMREGION_ERASE00 )
ROM_LOAD16_WORD_SWAP( "perfectmate.bin", 0x000000, 0x200000, CRC(fa7f8ca0) SHA1(fcc78f8efb183e9c65545eb502da475225253a94) )
// Perfect Mate's COB also had a sticker: 7DC1 16M 050822. The 2MB file I dumped sums to 7DC1
+ // The Perfect Mate checksum in the ROM header matches the sum of bytes from 0x10 to the end.
ROM_END
ROM_START( sencosmo )
diff --git a/src/mame/drivers/spg2xx_senario_poker.cpp b/src/mame/drivers/spg2xx_senario_poker.cpp
index 7d6a62623ae..ea2a090d845 100644
--- a/src/mame/drivers/spg2xx_senario_poker.cpp
+++ b/src/mame/drivers/spg2xx_senario_poker.cpp
@@ -682,7 +682,7 @@ void sentx6p_state::sentx6p(machine_config &config)
ROM_START( sentx6p )
ROM_REGION( 0x800000, "maincpu", ROMREGION_ERASE00 )
- ROM_LOAD16_WORD_SWAP( "vsmaxxtexasholdem.bin", 0x000000, 0x400000, CRC(00180abb) SHA1(c2af28f64bfdfc9d671bb84561f8a916bc907176) )
+ ROM_LOAD16_WORD_SWAP( "vsmaxxtexasholdem.bin", 0x000000, 0x200000, CRC(d9d7ea1d) SHA1(ae531958d6074ea2034910f53e043d5fa10eaf8c) )
ROM_END
ROM_START( sentx6puk )
diff --git a/src/mame/machine/elan_eu3a05commonsys.cpp b/src/mame/machine/elan_eu3a05commonsys.cpp
index b4695f5e5b8..bb85fba04b7 100644
--- a/src/mame/machine/elan_eu3a05commonsys.cpp
+++ b/src/mame/machine/elan_eu3a05commonsys.cpp
@@ -174,7 +174,8 @@ elan_eu3a05commonsys_device::elan_eu3a05commonsys_device(const machine_config &m
m_cpu(*this, finder_base::DUMMY_TAG),
m_bank(*this, finder_base::DUMMY_TAG),
m_is_pal(false),
- m_allow_timer_irq(true)
+ m_allow_timer_irq(true),
+ m_whichtimer(0)
{
}
@@ -236,7 +237,7 @@ void elan_eu3a05commonsys_device::device_timer(emu_timer &timer, device_timer_id
// rad_bb3 unmasks the interrupt, but the jumps use pointers in RAM, which haven't been set up at the time
// of unmasking, so we need to find some kind of global enable / disable, or timer enable.
if (m_allow_timer_irq)
- generate_custom_interrupt(0);
+ generate_custom_interrupt(m_whichtimer);
break;
}
}
diff --git a/src/mame/machine/elan_eu3a05commonsys.h b/src/mame/machine/elan_eu3a05commonsys.h
index 5980701d0a0..2a622d9972b 100644
--- a/src/mame/machine/elan_eu3a05commonsys.h
+++ b/src/mame/machine/elan_eu3a05commonsys.h
@@ -25,6 +25,8 @@ public:
DECLARE_READ8_MEMBER(nmi_vector_r);
DECLARE_READ8_MEMBER(irq_vector_r);
+ void set_alt_timer() { m_whichtimer = 1; }
+
protected:
// device-level overrides
virtual void device_start() override;
@@ -62,7 +64,7 @@ private:
emu_timer *m_unk_timer;
static const device_timer_id TIMER_UNK = 0;
-
+ int m_whichtimer;
};
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index 61c326af953..791485e60e1 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -12887,6 +12887,7 @@ rad_sinv
rad_tetr
airblsjs
sudoelan
+carlecfg
@source:electra.cpp
avenger // (c) 1975 Electra
@@ -31272,7 +31273,7 @@ vtpinball // From V.R. Technology VT SDK
vtsndtest // From V.R. Technology VT SDK
vtboxing // From V.R. Technology VT SDK
ablpinb
-sudokuv
+papsudok
mc_dgear
dgun2500
dgun2561
@@ -31309,6 +31310,8 @@ gprnrs16
ddrdismx // (c) 2006 Majesco / Konami [(c) 2001 Disney on title screen]
ddrstraw // (c) 2006 Majesco / Konami
majkon
+majgnc
+sudopptv
ablping
vgpocket
vgpmini
diff --git a/src/mame/video/elan_eu3a05vid.cpp b/src/mame/video/elan_eu3a05vid.cpp
index 31b4c054f33..689f4b14a9b 100644
--- a/src/mame/video/elan_eu3a05vid.cpp
+++ b/src/mame/video/elan_eu3a05vid.cpp
@@ -8,12 +8,15 @@ DEFINE_DEVICE_TYPE(ELAN_EU3A05_VID, elan_eu3a05vid_device, "elan_eu3a05vid", "El
// tilemaps start at 0x0600 in mainram, sprites at 0x3e00, unlike eu3a14 these could be fixed addresses
-elan_eu3a05vid_device::elan_eu3a05vid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : elan_eu3a05commonvid_device(mconfig, ELAN_EU3A05_VID, tag, owner, clock),
+elan_eu3a05vid_device::elan_eu3a05vid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ elan_eu3a05commonvid_device(mconfig, ELAN_EU3A05_VID, tag, owner, clock),
device_memory_interface(mconfig, *this),
m_cpu(*this, finder_base::DUMMY_TAG),
m_bank(*this, finder_base::DUMMY_TAG),
- m_space_config("regs", ENDIANNESS_NATIVE, 8, 5, 0, address_map_constructor(FUNC(elan_eu3a05vid_device::map), this))
+ m_space_config("regs", ENDIANNESS_NATIVE, 8, 5, 0, address_map_constructor(FUNC(elan_eu3a05vid_device::map), this)),
+ m_bytes_per_tile_entry(4),
+ m_vrambase(0x600),
+ m_spritebase(0x3e00)
{
}
@@ -72,12 +75,20 @@ void elan_eu3a05vid_device::device_reset()
for (int i=0;i<2;i++)
m_splitpos[i] = 0x00;
+
+}
+
+void elan_eu3a05vid_device::set_is_sudoku()
+{
+ m_bytes_per_tile_entry = 2;
+ m_vrambase = 0x200;
+ m_spritebase = 0x1000;
}
uint8_t elan_eu3a05vid_device::read_spriteram(int offset)
{
address_space& cpuspace = m_cpu->space(AS_PROGRAM);
- int realoffset = offset+0x3e00;
+ int realoffset = offset+m_spritebase;
if (realoffset < 0x4000)
{
return cpuspace.read_byte(realoffset);
@@ -90,7 +101,7 @@ uint8_t elan_eu3a05vid_device::read_spriteram(int offset)
uint8_t elan_eu3a05vid_device::read_vram(int offset)
{
address_space& cpuspace = m_cpu->space(AS_PROGRAM);
- int realoffset = offset+0x0600;
+ int realoffset = offset+m_vrambase;
if (realoffset < 0x4000)
{
return cpuspace.read_byte(realoffset);
@@ -259,12 +270,20 @@ void elan_eu3a05vid_device::draw_sprites(screen_device &screen, bitmap_ind16 &bi
// a hacky mess for now
bool elan_eu3a05vid_device::get_tile_data(int base, int drawpri, int& tile, int &attr, int &unk2)
{
- tile = read_vram(base * 4) + (read_vram((base * 4) + 1) << 8);
+ tile = read_vram(base * m_bytes_per_tile_entry) + (read_vram((base * m_bytes_per_tile_entry) + 1) << 8);
// these seem to be the basically the same as attr/unk2 in the sprites, which also make
// very little sense.
- attr = read_vram((base * 4) + 2);
- unk2 = read_vram((base * 4) + 3);
+ if (m_bytes_per_tile_entry == 4)
+ {
+ attr = read_vram((base * m_bytes_per_tile_entry) + 2);
+ unk2 = read_vram((base * m_bytes_per_tile_entry) + 3);
+ }
+ else
+ {
+ attr = 0;
+ unk2 = 0;
+ }
/* hack for phoenix title screens.. the have attr set to 0x3f which change the colour bank in ways we don't want
and also by our interpretation of 0x0f bits sets the tiles to priority over sprites (although in this case
diff --git a/src/mame/video/elan_eu3a05vid.h b/src/mame/video/elan_eu3a05vid.h
index 00332fe63ad..9c8d82a888f 100644
--- a/src/mame/video/elan_eu3a05vid.h
+++ b/src/mame/video/elan_eu3a05vid.h
@@ -20,6 +20,8 @@ public:
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ void set_is_sudoku();
+
protected:
// device-level overrides
virtual void device_start() override;
@@ -75,6 +77,10 @@ private:
DECLARE_READ8_MEMBER(read_unmapped);
DECLARE_WRITE8_MEMBER(write_unmapped);
+
+ int m_bytes_per_tile_entry;
+ int m_vrambase;
+ int m_spritebase;
};
DECLARE_DEVICE_TYPE(ELAN_EU3A05_VID, elan_eu3a05vid_device)