This page is a mirror of Tepples' nesdev forum mirror (URL TBD).
Last updated on Oct-18-2019 Download

MMC3 PRG/CHR Bankswitching

MMC3 PRG/CHR Bankswitching
by on (#52672)
Hi, I'm trying to do a "generic" library on neshla to abstract a little mapper bankswitching, it will support several mappers and you could use the same functions regardless what mapper you're using (if that operation is available on the mapper of course...)

Questions are:
1- If you switch PRG bank on one of the two banks that are fixed/bankswitched, when you switch from one mode to another, does the other bank switch to second-last bank?

2- Happens the same on CHR? if I have CHR and switch mode from 2kb 2kb 1k 1k 1k 1k to 1k 1k 1k 1k 2k 2k, do the graphics change?

Extra- FME-7 has 4 banks to switch?? being one in the prg-ram area?

PS: sorry if I don't express the question right in english.

by on (#52679)
The MMC3 has "registers" and "modes". When the mode changes, the value of the registers does not. All that changes is which memory area uses which register. Here is part of Disch's (I believe he wrote it) mapper document for MMC3.

CHR Setup:

               $0000   $0400   $0800   $0C00   $1000   $1400   $1800   $1C00
CHR Mode 0:  |     <R:0>     |     <R:1>     |  R:2  |  R:3  |  R:4  |  R:5  |
CHR Mode 1:  |  R:2  |  R:3  |  R:4  |  R:5  |     <R:0>     |     <R:1>     |

PRG Setup:

               $8000   $A000   $C000   $E000 
PRG Mode 0:  |  R:6  |  R:7  | { -2} | { -1} |
PRG Mode 1:  | { -2} |  R:7  |  R:6  | { -1} |

About FME-7, yes it has 4 PRG Banks. The first one is $6000 which can select between PRG-RAM or a ROM page using 6 bits. The top two bits are control related to if you use RAM or ROM.

   E = Enable RAM (0=disabled, 1=enabled)
   R = RAM/ROM select (0=ROM, 1=RAM)
   P = PRG page

by on (#52690)
So if I change CHR mode it will shwitch pattern tables?

Thanks for the info about FME-7 I readed about it later.

by on (#52705)
Yes it will. For example in Mode 0, Register 0 is used to determine was Pattern Table Data appears at $0000 to $07FF. But in Mode 1, Registers 2 and 3 are used to determine what Pattern Table data shows up at $0000 to $07FF. Can't be much clearer than that.