Before you go on reading please note that this is a very low level technical question. I am recreating the NES in hardware using pure HDL. I have a question regarding access to the PPU's object attribute memory (OAM) via $2003 and $2004. There is very conflicting information on these registers from various documentation sources. For example:
- 2C02 Tech Reference by Brady Taylor states register $2004 is read/write and either a read or a write will increment the address stored in $2003.
-
http://nesdevwiki.org/wiki/NES_PPU states register $2004 is read/write but _only_ writes will increment the address in $2003.
- Still other documentation (e.g. NEStech by Jeremy Chadwick) states that $2004 is write-only and cannot be read from at all!
- I tested some code in NEStopia and it clearly increments the address in $2003 only on writes and _not_ on reads.
- I tested the same code in VirtuaNES and it clearly increments on writes and reads!
- I tested the same code on the FCEUX and JNES emulators and I don't think they even allow you to read from sprite RAM as far as I can tell.
Seeing as how there are so many different implementations in the software emulator world I'm beginning to wonder if there are any games out there that actually care about this. Haha.
But does anyone *KNOW* what a real NES does to $2003 when reading from $2004? Or have a way that they can test it on a real NES for me to find out?? I would like my NES implementation to be as accurate as possible. If I don't get any responses then I will go with the way that NEStopia implements it (i.e. increment $2003 on writes but not on reads).
THANKS IN ADVANCE!!
