atari2600-wasm
atari2600-wasm copied to clipboard
Status register flags
Your generated code for N and Z flag handling is incorrect.
The Z flag should be set if result == 0 after truncating to 8 bits.
The N flag is almost always a copy of bit 7 of the result. I see you have this for some instructions, but not for example with ADC
, where it's certainly true.