move this too (nw)

This commit is contained in:
David Haywood 2013-07-19 15:50:28 +00:00
parent f6b13b94ba
commit 8bfd144df4
4 changed files with 43 additions and 34 deletions

View File

@ -241,38 +241,8 @@ READ32_MEMBER(deco_mlc_state::mlc_vram_r)
return m_mlc_vram[offset]&0xffff;
}
// there is more to this, it controls the runner on the attract screen before the title should appear at least
READ32_MEMBER(deco_mlc_state::stadhr96_prot_146_r)
{
/*
cpu #0 (PC=00041BD0): unmapped program memory dword write to 00708004 = 000F0000 & FFFFFFFF
cpu #0 (PC=00041BFC): unmapped program memory dword write to 0070F0C8 = 00028800 & FFFFFFFF
cpu #0 (PC=00041C08): unmapped program memory dword write to 0070F010 = 00081920 & FFFFFFFF
cpu #0 (PC=00041C14): unmapped program memory dword write to 0070F020 = 00040960 & FFFFFFFF
cpu #0 (PC=00041C20): unmapped program memory dword write to 0070F03C = 5A5A5A5A & FFFFFFFF
*/
offset<<=1;
if (offset==0x5c4)
return 0xaa55 << 16;
if (offset==0x7a4)
return 0x0001 << 16; // "2" makes OUT count to add by 2.
if (offset==0x53c)
return 0x0008 << 16;
if (offset==0x304)
return 0x0001 << 16; // Unknown, is either 0,1,2,3
printf("%08x: Read prot %08x\n", space.device().safe_pc(), offset);
return 0;
}
WRITE32_MEMBER(deco_mlc_state::stadhr96_prot_146_w)
{
printf("%08x: Write prot %04x %08x\n", space.device().safe_pc(), offset, data);
}
READ32_MEMBER( deco_mlc_state::mlc_spriteram_r )
{
UINT32 retdata = 0;
@ -325,7 +295,7 @@ static ADDRESS_MAP_START( decomlc_map, AS_PROGRAM, 32, deco_mlc_state )
AM_RANGE(0x044001c, 0x044001f) AM_READWRITE(mlc_44001c_r, mlc_44001c_w) AM_MIRROR(0xff000000)
AM_RANGE(0x0500000, 0x0500003) AM_WRITE(avengrs_eprom_w) AM_MIRROR(0xff000000)
AM_RANGE(0x0600000, 0x0600007) AM_DEVREADWRITE8("ymz", ymz280b_device, read, write, 0xff000000) AM_MIRROR(0xff000000)
AM_RANGE(0x070f000, 0x070ffff) AM_READWRITE(stadhr96_prot_146_r, stadhr96_prot_146_w) AM_MIRROR(0xff000000)
AM_RANGE(0x070f000, 0x070ffff) AM_DEVREADWRITE("ioprot", deco146_device, stadhr96_prot_146_r, stadhr96_prot_146_w) AM_MIRROR(0xff000000)
ADDRESS_MAP_END
/******************************************************************************/
@ -483,6 +453,8 @@ static MACHINE_CONFIG_START( mlc, deco_mlc_state )
MCFG_VIDEO_START_OVERRIDE(deco_mlc_state,mlc)
MCFG_DECO146_ADD("ioprot")
/* sound hardware */
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")

View File

@ -1,10 +1,12 @@
#include "machine/eeprom.h"
#include "machine/deco146.h"
class deco_mlc_state : public driver_device
{
public:
deco_mlc_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag),
m_deco146(*this, "ioprot"),
m_mlc_ram(*this, "mlc_ram"),
m_irq_ram(*this, "irq_ram"),
m_mlc_clip_ram(*this, "mlc_clip_ram"),
@ -12,6 +14,7 @@ public:
m_maincpu(*this, "maincpu"),
m_eeprom(*this, "eeprom") { }
optional_device<deco146_device> m_deco146;
required_shared_ptr<UINT32> m_mlc_ram;
required_shared_ptr<UINT32> m_irq_ram;
required_shared_ptr<UINT32> m_mlc_clip_ram;
@ -43,8 +46,6 @@ public:
DECLARE_READ32_MEMBER(mlc_scanline_r);
DECLARE_WRITE32_MEMBER(mlc_irq_w);
DECLARE_READ32_MEMBER(mlc_vram_r);
DECLARE_READ32_MEMBER(stadhr96_prot_146_r);
DECLARE_WRITE32_MEMBER(stadhr96_prot_146_w);
DECLARE_READ32_MEMBER(avengrgs_speedup_r);
DECLARE_WRITE32_MEMBER(avengrs_eprom_w);
DECLARE_READ32_MEMBER(mlc_spriteram_r);

View File

@ -1445,8 +1445,9 @@ void deco146_device::device_reset()
Robocop 2
Lemmings
Dragon Gun
Dragon Gun* is this really 146?
Captain America
Stadium Hero 96* not used for inputs, just some fixed return data based on the writes!
*****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************
@ -1525,6 +1526,38 @@ READ32_MEMBER(deco146_device::dragngun_prot_r)
}
READ32_MEMBER(deco146_device::stadhr96_prot_146_r)
{
/*
cpu #0 (PC=00041BD0): unmapped program memory dword write to 00708004 = 000F0000 & FFFFFFFF
cpu #0 (PC=00041BFC): unmapped program memory dword write to 0070F0C8 = 00028800 & FFFFFFFF
cpu #0 (PC=00041C08): unmapped program memory dword write to 0070F010 = 00081920 & FFFFFFFF
cpu #0 (PC=00041C14): unmapped program memory dword write to 0070F020 = 00040960 & FFFFFFFF
cpu #0 (PC=00041C20): unmapped program memory dword write to 0070F03C = 5A5A5A5A & FFFFFFFF
*/
offset<<=1;
if (offset==0x5c4)
return 0xaa55 << 16;
if (offset==0x7a4)
return 0x0001 << 16; // "2" makes OUT count to add by 2.
if (offset==0x53c)
return 0x0008 << 16;
if (offset==0x304)
return 0x0001 << 16; // Unknown, is either 0,1,2,3
printf("%08x: Read prot %08x\n", space.device().safe_pc(), offset);
return 0;
}
WRITE32_MEMBER(deco146_device::stadhr96_prot_146_w)
{
printf("%08x: Write prot %04x %08x\n", space.device().safe_pc(), offset, data);
}
/****************************************************************************************************
*****************************************************************************************************
*****************************************************************************************************

View File

@ -19,6 +19,8 @@ public:
DECLARE_READ32_MEMBER(captaven_prot_r);
DECLARE_READ16_MEMBER(lemmings_prot_r);
DECLARE_READ16_MEMBER(robocop2_prot_r);
DECLARE_READ32_MEMBER(stadhr96_prot_146_r);
DECLARE_WRITE32_MEMBER(stadhr96_prot_146_w);
protected:
virtual void device_config_complete();
virtual void device_start();
@ -69,6 +71,7 @@ DECLARE_READ16_HANDLER( deco16_146_nitroball_prot_r );
DECLARE_WRITE32_HANDLER( deco16_146_fghthist_prot_w );
DECLARE_WRITE16_HANDLER( deco16_146_nitroball_prot_w );
// legacy stuff
DECLARE_READ16_HANDLER( deco16_60_prot_r );
DECLARE_READ16_HANDLER( deco16_66_prot_r );