Monday, January 21, 2008

Hack Free

I finally found the bug that was forcing me to add memory hacks to the driver in order for it to bypass the memory tests for each game.

The I8051 core library was basically firing the timers when they were sometimes not enabled. What this did was cause the timer interrupts to modify memory while the memory check subroutine was running. The memory check routine was writing specific values into memory and verifying that they read back the same value that was written. But with the timers updating memory at the same time, the memory check would not find the values it was expecting and therefore fail.

The fix should help slightly increase the responsiveness of the game code too. I believe the I8051 core has other areas to investigate, but this fix is a huge change for the driver.

With the fix in place, all memory hacks in the driver can be removed. This means any new clones that are added in the future should drop in nicely without any special memory modifications.

I will be submitting a new driver update in the near future with all the hacks removed.

No comments: