BizHawk icon indicating copy to clipboard operation
BizHawk copied to clipboard

[NesHawk] Pass TakuikaNinja's FDS-Mirroring-Test

Open TakuikaNinja opened this issue 9 months ago • 2 comments

Summary

I recently helped discover some previously undocumented behaviour on the FDS. Bit 3 of $4030 reads return the value from bit 3 of $4025, which is the nametable arrangement/mirroring mode. I wrote a test program to verify the behaviour, and it fails on BizHawk's NesHawk core (and presumably SubNesHawk as well). Mesen2 and Nestopia have since implemented the behaviour.

NESdev forum post: https://forums.nesdev.org/viewtopic.php?p=300488#p300488 Test program source code: https://github.com/TakuikaNinja/FDS-Mirroring-Test

Repro

  1. Load the following test program: https://forums.nesdev.org/download/file.php?id=28216
  2. Test fails for $4030.D3 R.

Host env.

  • BizHawk 2.10; EndeavourOS on 6.13.8-zen1-1-zen

Screenshots

NesHawk: Image

Original hardware (Twin Famicom):

Image

TakuikaNinja avatar Apr 01 '25 10:04 TakuikaNinja

Update: I've since discovered a new behaviour, where $4023.D0=0 writes effectively reset the nametable arrangement/mirroring. Please use the latest version of the test program when resolving this issue. (Other $4023 behaviours will be discussed in a new issue)

https://github.com/TakuikaNinja/FDS-Mirroring-Test/releases/tag/v1.1

Image

TakuikaNinja avatar Nov 18 '25 08:11 TakuikaNinja

We can rename this issue "[NesHawk] Pass TakuikaNinja's FDS testrom" if you want.

Speaking of: I recently expanded our testrom framework to support SMS. I wanted to do NES, but until now I've had a strict rule of only running testroms that I could build from source, and I had trouble with the toolchain for building NES roms (cc65 or NESasm). That's an entirely self-imposed rule though, nothing in this codebase requires it, and in fact the roms can be provided manually without using my from-source CI at all.

YoshiRulz avatar Nov 18 '25 08:11 YoshiRulz