mirror of
https://github.com/MoleskiCoder/EightBitNet.git
synced 2025-01-09 07:34:13 +00:00
Correct Z80 halt interrupt bug.
Signed-off-by: Adrian Conlon <Adrian.conlon@gmail.com>
This commit is contained in:
parent
0dd6f1025f
commit
364d79fde9
12
Z80/Z80.cs
12
Z80/Z80.cs
@ -258,7 +258,11 @@ namespace EightBit
|
||||
protected override void HandleINT()
|
||||
{
|
||||
base.HandleINT();
|
||||
this.RaiseHALT();
|
||||
if (this.Halted)
|
||||
{
|
||||
this.Proceed();
|
||||
}
|
||||
|
||||
if (this.IFF1)
|
||||
{
|
||||
this.DisableInterrupts();
|
||||
@ -1392,7 +1396,11 @@ namespace EightBit
|
||||
private void HandleNMI()
|
||||
{
|
||||
this.RaiseNMI();
|
||||
this.RaiseHALT();
|
||||
if (this.Halted)
|
||||
{
|
||||
this.Proceed();
|
||||
}
|
||||
|
||||
this.IFF1 = false;
|
||||
this.Restart(0x66);
|
||||
this.Tick(13);
|
||||
|
Loading…
Reference in New Issue
Block a user