PPUADDR with Y increment? (MMC3)

Discuss emulation of the Nintendo Entertainment System and Famicom.

Moderator: Moderators

Post Reply
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

PPUADDR with Y increment? (MMC3)

Post by Zepper »

Technically, is possible to increment Y on PPU cycle 256 during a write to $2006? I have an unfixable problem with MMC3 IRQs - the game Kick Master has a waving title screen. I can fix it if I delay the IRQ by 2 PPU cycles, but the MMC3 tests are broken.
User avatar
Bregalad
Posts: 8056
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: PPUADDR with Y increment? (MMC3)

Post by Bregalad »

I do not understand your question. This increment happens automatically, assuming redering is on. So of course this is "possible".
User avatar
tokumaru
Posts: 12427
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: PPUADDR with Y increment? (MMC3)

Post by tokumaru »

I'm not sure what the question is either... Are you talking about manually clocking the MMC3's scanline counter by manipulating $2006?
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by Zepper »

There's a conflict between increasing Y at 256th and writting to $2006. If Y is clocked after the write, the background is waving. Else, it's fine.
User avatar
zeroone
Posts: 939
Joined: Mon Dec 29, 2014 1:46 pm
Location: New York, NY
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by zeroone »

Zepper wrote:There's a conflict between increasing Y at 256th and writting to $2006. If Y is clocked after the write, the background is waving. Else, it's fine.
That sounds very similar to the Battletoads stage 2 freezing issue.
User avatar
Disch
Posts: 1848
Joined: Wed Nov 10, 2004 6:47 pm

Re: PPUADDR with Y increment? (MMC3)

Post by Disch »

Zepper:

Can you guess what I'm going to say? :wink:

Tracelogs!

Let's see a trace of a frame with screwed-up lines, with scanline&cycle marked, and NMI/IRQ marked. Then we can see where your window to write is and why the game is writing outside that window.
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by Zepper »

Disch wrote:Zepper:

Can you guess what I'm going to say? :wink:
Can you guess what I am going to reply? ^_^;;

Remember of the problem with sprite zero hits? You saw the tracelogs and said "the sprite zero hit is off by 1". Well, if I fix this "off by 1", the test ROMs are broken too.
So, it's the same. But okay, I'll post the tracelogs soon.
User avatar
Bregalad
Posts: 8056
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: PPUADDR with Y increment? (MMC3)

Post by Bregalad »

I don't understand the problem. Time your code so that your write always fall before the increment, or always fall after the increment, and your BG won't be shaking. It's a matter of adding or removing a few nops. No big deal.
User avatar
tokumaru
Posts: 12427
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: PPUADDR with Y increment? (MMC3)

Post by tokumaru »

Bregalad wrote:It's a matter of adding or removing a few nops. No big deal.
Except Zepper is coding an emulator, not an NES program. :wink:

Apparently, adjusting the emulator to accommodate some games makes it fail some accuracy tests.
User avatar
zeroone
Posts: 939
Joined: Mon Dec 29, 2014 1:46 pm
Location: New York, NY
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by zeroone »

Is there a way to deterministically synchronize game states between RockNES and Nintendulator to enable a comparison between the logs cycle-by-cycle?
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by Zepper »

zeroone wrote:
Zepper wrote:There's a conflict between increasing Y at 256th and writting to $2006. If Y is clocked after the write, the background is waving. Else, it's fine.
That sounds very similar to the Battletoads stage 2 freezing issue.
Well... perhaps. I'm unsure about Battletoads.
Regarding Nintendulator, no.... it's not necessary. Even converting its savestate file to RockNES format won't help too.
User avatar
zeroone
Posts: 939
Joined: Mon Dec 29, 2014 1:46 pm
Location: New York, NY
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by zeroone »

Zepper wrote:Regarding Nintendulator, no.... it's not necessary. Even converting its savestate file to RockNES format won't help too.
If you managed to do it, you could discover exactly why RockNES does not behave correctly.
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: PPUADDR with Y increment? (MMC3)

Post by Zepper »

zeroone wrote:
Zepper wrote:Regarding Nintendulator, no.... it's not necessary. Even converting its savestate file to RockNES format won't help too.
If you managed to do it, you could discover exactly why RockNES does not behave correctly.
AFAIK, such log does not bring the helpful information I need, but only a complete CPU disassembling.
Post Reply