mirror of
https://github.com/holub/mame
synced 2025-06-07 05:13:46 +03:00
sega/model3.cpp: system port 8 is just an irq check strobe
* fix spikeout/spikeofe bootup
This commit is contained in:
parent
ec14ab6887
commit
5f591fb5f8
@ -30,7 +30,7 @@
|
|||||||
vs2 - works
|
vs2 - works
|
||||||
harley - works
|
harley - works
|
||||||
skichamp - boots after skipping the drive board errors, massive slowdowns
|
skichamp - boots after skipping the drive board errors, massive slowdowns
|
||||||
srally2 - works
|
srally2 - works, uses JTAG patch, draws no polygon if coin is inserted at Sega logo
|
||||||
srally2p/srally2pa/sraly2dx - needs specific JTAG patch / bypass
|
srally2p/srally2pa/sraly2dx - needs specific JTAG patch / bypass
|
||||||
von2/von2a/von2o/von254g - works
|
von2/von2a/von2o/von254g - works
|
||||||
fvipers2 - crashes after player selection
|
fvipers2 - crashes after player selection
|
||||||
@ -1520,33 +1520,13 @@ void model3_state::model3_sys_w(offs_t offset, uint64_t data, uint64_t mem_mask)
|
|||||||
else logerror("m3_sys: unknown mask on IRQen write\n");
|
else logerror("m3_sys: unknown mask on IRQen write\n");
|
||||||
break;
|
break;
|
||||||
case 0x18/8:
|
case 0x18/8:
|
||||||
if ((mem_mask & 0xff000000) == 0xff000000) // int ACK with bits in REVERSE ORDER from the other registers (Seeeee-gaaaa!)
|
if ((mem_mask & 0xff000000) == 0xff000000)
|
||||||
{ // may also be a secondary enable based on behavior of e.g. magtruck VBL handler
|
{
|
||||||
// uint32_t old_irq = m_irq_state;
|
// check irq status only
|
||||||
uint8_t ack = (data>>24)&0xff, realack;
|
// - spikeout/spikeofe cares about this;
|
||||||
int i;
|
// - vs215o implies that the value written doesn't really matter
|
||||||
|
// (writes the full range of 0-0xff), classifying this as a strobe only
|
||||||
switch (ack)
|
update_irq_state();
|
||||||
{
|
|
||||||
case 0xff: // no ack, do nothing
|
|
||||||
return;
|
|
||||||
|
|
||||||
default:
|
|
||||||
realack = 0xff; // default to all bits set, no clearing
|
|
||||||
for (i = 7; i >= 0; i--)
|
|
||||||
{
|
|
||||||
// if bit is clear, clear the bit on the opposite end
|
|
||||||
if (!(ack & (1<<i)))
|
|
||||||
{
|
|
||||||
realack &= ~(1<<(7-i));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// printf("%x to ack (realack %x)\n", ack, realack);
|
|
||||||
|
|
||||||
m_irq_state &= realack;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -6920,6 +6900,7 @@ void model3_state::init_dayto2pe()
|
|||||||
// rom[(0x64ca34^4)/4] = 0x60000000; // dec
|
// rom[(0x64ca34^4)/4] = 0x60000000; // dec
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: sound dies often without these patches, investigate
|
||||||
void model3_state::init_spikeout()
|
void model3_state::init_spikeout()
|
||||||
{
|
{
|
||||||
uint32_t *rom = (uint32_t*)memregion("user1")->base();
|
uint32_t *rom = (uint32_t*)memregion("user1")->base();
|
||||||
|
Loading…
Reference in New Issue
Block a user