Hey there friends, as an exercise of something I always wanted to do even since I was a kid, and now that work is very slow, I decided to work on my own MSX1 emulator from scratch written in Rust.
I am using openMSX as the validation for my code and I just stumbled across something that happens and I don't quite understand.
If you see the openMSX debugger window on the linked video, the PC is at 0x0370 and the opcode at this location is 0x2C (INC L). At this point the flag Z is set to 1 (Z) and the value for register L is 0x03.
When I step over this instruction, all of a sudden the Z becomes 0 (NZ) and I can't understand why. On my emulator Z remains 0 (NZ) and I can't quite understand what's happening.
Does anyone have more insight on what's happening here?
Here's a link to the video in question, hopefully it makes sense:
https://www.dropbox.com/s/0iqyo9bbh8koovf/INC%20L%20-%20Z%20...
Thank you very much!