A game cartridge is a removable NES game medium containing program data, graphics data, and optional memory hardware. It gives the console access to ROM and can extend the system with additional RAM, VRAM, or battery-backed RAM. section 1.2 section 5.1
A cartridge can provide several kinds of storage and hardware:
- Program and data space, supplied as fixed or bank-switched ROM; up to 32K is available at one time. section 1.2
- Pattern-table storage for tile and sprite graphics, commonly an 8K cartridge section that may be ROM or writable RAM. section 1.2
- Optional working RAM, extra VRAM, or battery-backed RAM for saving progress. section 1.2
NES software must follow a cartridge structure so the console recognizes it as a valid title. Assembly segments place code or data into corresponding ROM or RAM areas, while RAM values can be written but disappear when power is removed. section 5.1
Bank switching for larger games
Early cartridges were limited to 16K or 32K of game-code ROM and 8K of pattern ROM. Mapper chips let larger cartridges swap memory banks into the NES's 64K address space. Writing to mapper-controlled memory locations selects the active PRG ROM or CHR ROM bank. section 16.2.1
Figure 1.4 NES architecture
Use the NES architecture diagram to connect cartridge memory with the CPU, PPU, internal RAM, and graphics storage. section 1.2
Figure 16.1 Standard NES cartridge memory layout
Use the standard cartridge memory layout to identify the usual PRG ROM and CHR ROM regions. section 16.2.1
