Comment by tasty_freeze

2 days ago

Knowing nothing about your code, I'd suggest checking if the code uses the DAA instruction. It is by far the trickiest thing to get right. Don't assume well behaved code -- what happens if A=0x5C and B=0xF4 and you execute "add b; daa"? That is, if you attempt to correct a sum which didn't start with valid decimal digits.

Interesting point, I'll take a look.

(The z80 emulation was the only thing I didn't write myself, though it does pass the standard test-programs I've not looked at how complex/complete their testing is.)