Home /Modules/cpu/ARCHITECTURE.md

ARCHITECTURE.md

lib/cpu/nintendo-nes/ARCHITECTURE.md · 49 line(s) · markdown

Nintendo NES (Ricoh 2A03 / 6502) Architecture

Topology

SLNESCPU

-> SLClock -> SLRegisterFile -> SLALU -> SLInstructionDecoder -> SLIOBus -> SLIOTiming -> SLInterruptController

Register section

The architectural register section is a accumulator / indexed register machine: 6502-class programmer model (A, X, Y, S, PC, P); Ricoh 2A03 integrates audio and DMA.

Internal latches and datapath elements are modeled only where their observable timing or behavior is useful.

Control section

The control side is represented as:

Datapath

registers -> internal bus/latches -> ALU -> register/memory destination

Address formation uses the architectural 16-bit address path.

Bus

The external interface exposes 16 address lines, a 8-bit data path, read/write control, clock/phase signals, and reset/interrupt controls. Each observable memory transaction is modeled as a bus event (see BUS.md).

Design principle

The SLeeLa representation is compositional: a Nintendo NES (Ricoh 2A03 / 6502) variant replaces only the couplers, I/O, timing, cache or opcode components that differ, rather than duplicating the whole CPU hierarchy.

Sources