reznez 0.0.0

The high accuracy NES Emulator
Documentation
ROADMAP
Fix workram writes to work without manually coding it in each mapper.
Fix remaining issue with apu_test DMC basics.
Remove GetSpritePatternHack in ppu.rs.
Verify when the IRQ flag is supposed to be cleared. An update to the location of ClearIrq caused the apu_test jitter to have a different result.
       See newoutput: E24C  AND #$40                        A:10 X:00 Y:00 S:FD P:nv--dIzc V:242 H:117 Fr:4 Cycle:1

Wide pixels.
Move nestest over to new formatting system.
Disable OAMDATA writes (other than address increment) during rendering
Work out priorities for WorkRam vs registers. Why does WorkRam need to be explicitly written to by each mapper?
Move CPU bus into CpuMemory
Audio
Rename CycleAction to StepAction.
Bus Conflicts
Don't display bottom tiles of screen by default (see Aladdin junk tiles)
Separate attribute table from name table?
Proper encapsulation for PPU registers
Improve cycle accuracy of undocumented instructions
Open Bus for joysticks.
Other input devices.
Auto-mirror undersized CHR (for mapper 99 and maybe others).
Require PRG ROM and CHR ROM sizes in InitialLayout.
Don't require mappers to explicitly say that their mirroring comes from the cartridge?

FANCY NICE-TO-HAVES
APU frequency correction

UNTESTED
(Nothing known, but there is plenty)

BUGS
Holding down the arrow keys doesn't generate input quickly enough.
Gracefully handle bad CHR size? ((( Argus (J) [hM03][o2].nes ))) ((( Atlantis no Nazo (J) [hM03][b3].nes )))
Gracefully handle bad PRG size? ((( Boy and His Blob, A - Trouble on Blobolonia (U) [o5].nes )))
(Low priority) What should happen when BankIndex > bank_count when bank_count isn't a power of 2? Open bus?
Marble Madness: Bank-switching mid-scanline isn't working, text doesn't render.
Rollerblade Racer: Glitched status bar.
Wizards and Warriors 3: Bad scanlines at middle of screen. Sprite flickering.
Arkanoid: Extra sprite.
Tatakai no Banka: Flickering sprites.
Fire Emblem Gaiden: Blank screen.
Kaiketsu Yanchamaru 2: PRG bank switching bug leads to JAM.
Mission Impossible 2: JAMs. Need to mirror CHR ROM due to it being too short?
mmc5test: black screen.
Dragon Ball Dai Maou Fukkatsu: infinite loop.

IMPROVEMENTS TO PRG/CHR LAYOUTS
Validate up front all windows as bank size multiples.
Automatically add registers from every layout? Maybe not since certain layouts won't be used by certain boards.

FAILING TESTS
cpu_interrupts_v2

sprdma_and_dmc_dma
tvpassfail/tv

apu_mixer
dmc_dma_during_read4
dmc_tests
dpcmletterbox

MMC3
MMC5

PaddleTest3/PaddleTest

full_palette
full_nes_palette

Holy Diver Batman
	M1_P128K_C32K.nes
	M1_P512K_S32K.nes
	M1_P128K_C128K.nes
	M1_P128K_C32K_S8K.nes
	M1_P512K_S8K.nes
	M1_P128K_C128K_S8K.nes
	M1_P128K_C32K_W8K.nes
	M1_P128K_C128K_W8K.nes
	M1_P128K.nes
	M28_P512K.nes
	M118_P128K_C64K.nes 

---------------------GAMES------------------------------------
MAPPER 0
Cheetah Men II [b1] (Doesn't work on nestopia either. Wrong tiles are rendered during some intro screens, probably due to the game relying on certain RAM values being present at startup)

MAPPER 1
A Ressha de Ikou (https://www.nesdev.org/wiki/MMC1#SZROM)

MAPPER 3
Athletic World (Freezes on nestopia too. Freezes at the beginning of the Hurdles event)

MAPPER 4
Crystalis - Junk on scanline above status bar.

MAPPER 7
Aladdin - Corrupted sprites, gets stuck in a loop writing to PPUDATA, JAMs.

MAPPER 16
Akuma-kun - Makai no Wana - Incorrect CHR ROM banks for bottom part of screen.

MAPPER 18
Magic John - Two flickering pixels on right hand side during the intro. (Possible IRQ off-by-one timing.)

MAPPER 21
Wai Wai World 2 - Severe flickering (sprites aren't drawn in time?)
Ganbare Goemon Gaiden 2 - Partial bad pattern table on opening screen.

MAPPER 23
Tiny Toon Adventures - Status bar

MAPPER 66
Dragon Ball - Goku can't move to spots he should be able to.


MAPPER 71
Fantastic Adventures of Dizzy - Status bar jumps a scanline or two, some sprites flicker. Sprites over the character intros.
Fire Hawk: Can't move helicopter. Broken name table display. Need better DMC implementation.
Micro Machines: Junk scanlines through the middle. See wiki.

MAPPER 94
Senjou: Various including flickering.

MAPPER 152
Arkanoid 2: Top of opening screen zeroed out.
Ge ge ge no Kitarou 2: Game freezes.

MAPPER 180
Crazy Climber: Verify operation.

Total games implemented:
000: 247
001: 680
002: 270
003: 155
004: 599
007: 75
009: 11
010: 3
011: 34
013: 1
016: 15
018: 15
020: 0
021: 2
022: 2
023: 10
025: 6
032: 6
033: 9
034: 5
038: 0
039: 0
046: 0
064: 5
065: 3
066: 17
069: 15
070: 2
071: 16
075: 5
076: 1
078: 2
079: 16
086: 1
087: 10
088: 3
094: 1
101: 0
113: 0
133: 0
140: 3
145: 0
146: 0
148: 0
149: 0
152: 4
154: 1
177: 0
180: 1
206: 45
232: 5
240: 0
241: 0
2301 / 2447

To implement:
5:  25