Search found 5 matches

by radicant
Thu Aug 11, 2022 6:47 pm
Forum: NESemdev
Topic: PPU timing problem with Donkey Kong (SOLVED)
Replies: 6
Views: 577

Re: PPU timing problem with Donkey Kong

Wow, can you see the problem? typedef union { u16 raw; struct { u8 coarseX : 5; u8 coarseY : 5; u8 nametableX : 1; u8 nametableY : 1; u8 fineYScroll : 3; u8 _ : 1; }; } PPUScrollRegister; The bitfields need to be u16... 20210401_harold_fb-358955159.jpg
by radicant
Thu Aug 11, 2022 6:07 pm
Forum: NESemdev
Topic: PPU timing problem with Donkey Kong (SOLVED)
Replies: 6
Views: 577

Re: PPU timing problem with Donkey Kong

I've implemented the name tables as one big 2048 byte chunk. The data in them is correct because I can read and build the sprites directly (no PPU emulation) and the screen is right. Things go wrong once I start emulating the PPU clock cycles. I found one dumb issue that surprisingly didn't change t...
by radicant
Wed Aug 10, 2022 7:20 pm
Forum: NESemdev
Topic: PPU timing problem with Donkey Kong (SOLVED)
Replies: 6
Views: 577

PPU timing problem with Donkey Kong (SOLVED)

My CPU code passes nestest.nes and if I do direct lookups in the pattern table then the DK loading screen and demo screen backgrounds are exactly right. However, moving on to implementing the frame timing diagram on the wiki results in stuff like this: Screen Shot 2022-08-09 at 10.38.05 PM.png I tri...
by radicant
Wed Aug 03, 2022 4:03 pm
Forum: NESemdev
Topic: Wrong palette on a few Donkey Kong squares (SOLVED)
Replies: 2
Views: 339

Re: Wrong palette on a few Donkey Kong squares

Yes, thank you! I wasn't applying the bits to four tiles. I failed at fancy bitwise math so I resorted to a lut :)
by radicant
Wed Aug 03, 2022 12:58 pm
Forum: NESemdev
Topic: Wrong palette on a few Donkey Kong squares (SOLVED)
Replies: 2
Views: 339

Wrong palette on a few Donkey Kong squares (SOLVED)

dk-blue.png As you can see, things look good except for a 2x4 region on the right side of DK and a 1x10 region on the score. For the DK glitch at least, my attribute lookup, $22, is the same as Mesen except Mesen picks palette 2 for all four tiles instead of only the left tiles. That doesn't seem r...