mirror of
https://github.com/cmosher01/Epple-II.git
synced 2025-01-23 23:36:45 +00:00
improved handling of B status bit
This commit is contained in:
parent
c14603c74a
commit
25fde4d9d0
@ -1441,7 +1441,7 @@ void CPU::addr_NMI()
|
|||||||
case 4:
|
case 4:
|
||||||
address = push();
|
address = push();
|
||||||
p |= PMASK_I;
|
p |= PMASK_I;
|
||||||
p &= ~PMASK_B; // ???
|
p &= ~PMASK_B;
|
||||||
data = p;
|
data = p;
|
||||||
write();
|
write();
|
||||||
break;
|
break;
|
||||||
@ -1523,7 +1523,7 @@ void CPU::addr_IRQ()
|
|||||||
case 4:
|
case 4:
|
||||||
address = push();
|
address = push();
|
||||||
p |= PMASK_I;
|
p |= PMASK_I;
|
||||||
p &= ~PMASK_B; // ???
|
p &= ~PMASK_B;
|
||||||
data = p;
|
data = p;
|
||||||
write();
|
write();
|
||||||
break;
|
break;
|
||||||
@ -1937,7 +1937,7 @@ void CPU::PHA()
|
|||||||
|
|
||||||
void CPU::PHP()
|
void CPU::PHP()
|
||||||
{
|
{
|
||||||
this->data = p;
|
this->data = this->p | PMASK_B;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CPU::PLA()
|
void CPU::PLA()
|
||||||
@ -1950,6 +1950,7 @@ void CPU::PLP()
|
|||||||
{
|
{
|
||||||
this->p = this->data;
|
this->p = this->data;
|
||||||
this->p |= PMASK_M;
|
this->p |= PMASK_M;
|
||||||
|
this->p |= PMASK_B;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CPU::BRK()
|
void CPU::BRK()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user