Explorar el Código

Fix status register saved on interrupt

v2
Nathaniel Walizer hace 3 meses
padre
commit
708a6d9831
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. +1
    -1
      src/f6502.c

+ 1
- 1
src/f6502.c Ver fichero

@@ -434,7 +434,7 @@ static inline int f6502_interrupt(f6502_Core* core,
uint16_t addr) {
PUSH16(core, core->registers.S, core->registers.PC);
PUSH(core, core->registers.S,
core->registers.P & ~f6502_Status_B);
(core->registers.P & ~f6502_Status_B) | f6502_Status_1);
SET(core->registers.P, f6502_Status_I);
core->registers.PC = f6502_read16(&core->memory, addr);
return 7;


Cargando…
Cancelar
Guardar