N flag depends on bit 15

This commit is contained in:
folkert van heusden 2024-04-01 15:48:29 +02:00
parent 7fd5b507d5
commit ee26b46dda
Signed by untrusted user who does not match committer: folkert
GPG key ID: 6B6455EDFEED3BD1

View file

@ -285,7 +285,7 @@ def op00_66_mtpi(cpu, inst, opsize=2):
targetspace = (cpu.mmu.DSPACE, cpu.mmu.ISPACE)[opsize - 1]
w = cpu.stackpop()
cpu.psw_n = w & cpu.MASK16
cpu.psw_n = w & cpu.SIGN16
cpu.psw_z = (w == 0)
cpu.psw_v = 0