NES: remove vs system cruft that never worked and i never followed up on
This commit is contained in:
parent
dac80789e6
commit
e88691152d
|
@ -29,10 +29,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
public bool SoundOn = true;
|
||||
int sprdma_countdown;
|
||||
bool _irq_apu; //various irq signals that get merged to the cpu irq pin
|
||||
/// <summary>if true, use VS. system arrangement of $4016..$4020</summary>
|
||||
bool vs_io = false;
|
||||
bool vs_coin1;
|
||||
bool vs_coin2;
|
||||
/// <summary>clock speed of the main cpu in hz</summary>
|
||||
public int cpuclockrate { get; private set; }
|
||||
|
||||
|
@ -192,15 +188,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
cpuclockrate = 1789773;
|
||||
cpu_sequence = cpu_sequence_NTSC;
|
||||
break;
|
||||
// there's no official name for these in bootgod, not sure what we should use
|
||||
//case "PC10"://TODO
|
||||
case "VS":
|
||||
apu = new APU(this, apu, false);
|
||||
ppu.region = PPU.Region.RGB;
|
||||
cpuclockrate = 1789773;
|
||||
cpu_sequence = cpu_sequence_NTSC;
|
||||
vs_io = true;
|
||||
break;
|
||||
// this is in bootgod, but not used at all
|
||||
case "Dendy":
|
||||
apu = new APU(this, apu, false);
|
||||
|
@ -267,13 +254,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
if (Controller["FDS Insert " + i])
|
||||
b.InsertSide(i);
|
||||
}
|
||||
if (vs_io)
|
||||
{
|
||||
if (Controller["VS Coin 1"])
|
||||
vs_coin1 = true;
|
||||
if (Controller["VS Coin 2"])
|
||||
vs_coin2 = true;
|
||||
}
|
||||
|
||||
ppu.FrameAdvance();
|
||||
if (lagged)
|
||||
|
@ -399,12 +379,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
case 0x4016:
|
||||
ports[0].Write(val & 1);
|
||||
ports[1].Write(val & 1);
|
||||
if (vs_io && board is Mapper099)
|
||||
{
|
||||
// happily, there aren't any other "VS exceptions" like this
|
||||
var b = board as Mapper099;
|
||||
b.Signal4016(val >> 2 & 1);
|
||||
}
|
||||
break;
|
||||
case 0x4017: apu.WriteReg(addr, val); break;
|
||||
default:
|
||||
|
@ -431,44 +405,9 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
lagged = false;
|
||||
byte ret;
|
||||
if (addr == 0x4016)
|
||||
ret = ports[vs_io ? 1 : 0].Read(peek);
|
||||
ret = ports[0].Read(peek);
|
||||
else
|
||||
ret = ports[vs_io ? 0 : 1].Read(peek);
|
||||
if (vs_io)
|
||||
{
|
||||
if (addr == 0x4016)
|
||||
{
|
||||
// clear bits 2-6
|
||||
ret &= 0x83;
|
||||
if (false) // service switch
|
||||
ret |= 0x04;
|
||||
if (false) // DIP1
|
||||
ret |= 0x08;
|
||||
if (false) // DIP2
|
||||
ret |= 0x10;
|
||||
if (vs_coin1)
|
||||
ret |= 0x20;
|
||||
if (vs_coin2)
|
||||
ret |= 0x40;
|
||||
}
|
||||
else
|
||||
{
|
||||
// clear bits 2-7
|
||||
ret &= 0x03;
|
||||
if (false) // DIP3
|
||||
ret |= 0x04;
|
||||
if (false) // DIP4
|
||||
ret |= 0x08;
|
||||
if (false) // DIP5
|
||||
ret |= 0x10;
|
||||
if (false) // DIP6
|
||||
ret |= 0x20;
|
||||
if (false) // DIP7
|
||||
ret |= 0x40;
|
||||
if (false) // DIP8
|
||||
ret |= 0x80;
|
||||
}
|
||||
}
|
||||
ret = ports[1].Read(peek);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -658,12 +597,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
}
|
||||
else if (addr < 0x6000)
|
||||
{
|
||||
if (vs_io && addr == 0x4020 && (value & 1) != 0)
|
||||
{
|
||||
// acknowledge coin insertion
|
||||
vs_coin1 = false;
|
||||
vs_coin2 = false;
|
||||
}
|
||||
board.WriteEXP(addr - 0x4000, value);
|
||||
}
|
||||
else if (addr < 0x8000)
|
||||
|
|
|
@ -32,11 +32,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
CoreComm.UsesDriveLed = true;
|
||||
b.SetDriveLightCallback((val) => CoreComm.DriveLED = val);
|
||||
}
|
||||
if (vs_io)
|
||||
{
|
||||
ControllerDefinition.BoolButtons.Add("VS Coin 1");
|
||||
ControllerDefinition.BoolButtons.Add("VS Coin 2");
|
||||
}
|
||||
}
|
||||
|
||||
private NES()
|
||||
|
@ -817,11 +812,6 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
ser.Sync("cpu_step", ref cpu_step);
|
||||
ser.Sync("cpu_stepcounter", ref cpu_stepcounter);
|
||||
ser.Sync("cpu_deadcounter", ref cpu_deadcounter);
|
||||
if (vs_io)
|
||||
{
|
||||
ser.Sync("vs_coin1", ref vs_coin1);
|
||||
ser.Sync("vs_coin2", ref vs_coin2);
|
||||
}
|
||||
ser.BeginSection("Board");
|
||||
board.SyncState(ser);
|
||||
if (board is NESBoardBase && !((NESBoardBase)board).SyncStateFlag)
|
||||
|
|
Loading…
Reference in New Issue