I am trying to fix several CPU errors in my emulator but I am having trouble actually tracking them down. Using nestest I have found the errors, great, its opcode __, but what facet of opcode __? Are my flags wrong? Program counter error? Overlooked sign issues?
Does anyone have an idea as to where I might look to find more information for nestest errors?
For example:
I'm focusing on testing CMP absolute,X. I get 064h. I change some values around and get the flags seemingly right, I test again and now I get 061h. What happened? I see it testing the code, so I log it to get:
Code: Select all
A : 40
M : 40
Flags: 0 1 1
A : 40
M : 3f
Flags: 0 1 0
A : 40
M : 41
Flags: 1 0 0
A : 80
M : 0
Flags: 0 1 0
A : 80
M : 80
Flags: 0 1 1
A : 80
M : 81
Flags: 1 0 0
A : 80
M : 7f
Flags: 0 1 0
But I have other CPU issues I need to fix and i was hoping there would be a faster way with a more explained error code.