Open source · 6502 / NES SoC

Put childhood
back into a chip. From emulator to silicon

A NES emulator you can play today, and an open-source 6502 chip growing its own CPU, PPU, APU and bus. It is also a trainer aircraft: rehearse the XiangShan-style lockstep verification, CI gates and backend flow on a chip small enough to finish.

6 open-source ROMs
28 PASS RTL regression
SHA match RTL frame ≡ NEMU
55 nm tapeout target
GAME 01 · FALLING
FALLING title frame rendered by the NEMU emulator Click to play
NEMU · SOFTWARE REFERENCE SHA 41e8…5a33
01Quickstart

Play first. Then build the chip.

Play instantly in your browser below — the same GEM6502 core, compiled to WebAssembly. Or build it locally: a Mac or Linux machine, three commands, about two minutes. Six MIT-licensed ROMs are included.

Play now · WebAssembly

The same 6502 core, right in this tab.

GEM6502 · ~30 KB wasm · 60 fps · no install

State
Loading
Game
—
FPS
—
Frames
—
CPU cycles
—
Audio
needs a click

Arrows / WASD move · Z or Space jump · X B · Enter Start · P pause · R reset. Click the screen once to give the emulator keyboard focus.

Desktop · nesearch

Want the full search-and-download toolbox?

nesearch aggregates seven catalogs, downloads and verifies ROMs, then launches them in the bundled GEM6502 or NEMU. CLI and local Web UI included.

v0.2.0 · 1.2 MB · SHA-256 47c79733…
~2 min · first build ~1 min
  1. Get the code 6 ROMs included

    All you need is Git. The games and their licences live in roms/.

    shell
    $ git clone https://github.com/OneDayOneApp/Open6502.git
    $ cd Open6502
  2. Build the emulator SDL2 + clang

    Install SDL2, then build NEMU's 6502 frontend. Works on Apple Silicon and Intel.

    shell
    $ brew install sdl2
    $ make -C NEMU m6502_defconfig
    $ make -C NEMU -j8
  3. Play Press V to start

    FALLING is a vertical platformer. Press V to start, WASD to move, Space to jump.

    shell
    $ ./roms/play.sh falling

On Windows, use WSL2 and follow the Linux steps. Full keymap, headless screenshots and RTL frame capture are in Docs · Quickstart.

What you need

  • OSmacOS 13+ / Ubuntu 22.04+
  • RAM4 GB is enough
  • Dependenciesclang · make · SDL2
  • Networkfirst clone only
  • GPUanything that opens an SDL window

Your keyboard is a 1P pad

Move WASD
A / jump SpaceZ
B X
Select / Start CV
Quit Esc

Player 2 uses the arrow keys, , . and / '.

First-run checklist

0 / 3
02Games

Six games. All open source.

Everything ships in roms/ — clone and play. Hover or focus a card for a live capture. These are homebrew ROMs, each under its own MIT licence.

About ROMs: no commercial ROMs are included or linked. All six games are MIT-licensed; the licence texts are in roms/LICENSES. Super Mario Bros. and other commercial games are not in the repo, and compatibility is not guaranteed.
Out of games? Find more with nesearch.

A C++20 tool in the same repo. It aggregates GitHub homebrew, Homebrew Hub, PDRoms and Internet Archive, supports resumable downloads and SHA-256 checks, and can launch GEM6502 or NEMU.

Explore nesearch ↗
03Status

Honestly, here's where it stands.

Numbers from the last verification (2026-11-22). This is not a finished chip — but every “passed” has reproducible evidence, and every “not yet” is listed too.

Verified · 2026-11-22 Evidence-based · no marketing math
28 PASS
RTL unit / integration tests
6 games
Open-source ROMs playable
1 frame
Byte-identical RTL vs NEMU
0x3469
RTL Klaus end PC
NEMUsoftware reference 90%
RTL SoCSystemVerilog 60%
FPGAboard validation 10%
55 nm ASIClong-term target 5%

Works today

  • Play all six open-source games in NEMU, including two MMC3 titles
  • RTL CPU passes the Klaus functional test, ending at PC=0x3469
  • RTL renders the FALLING title frame with the same SHA-256 as NEMU
  • START enters gameplay; $00=1 is stable and the palette is retained
  • NEMU/RTL final-state, PC trace and ALU/stack DiffTest pass
  • Lean 4 formal model: 151-opcode decode ≡ RTL dispatch, 19 instruction refinement proofs, 4-program Lean↔RTL co-simulation

Not yet

  • RTL PPU is not cycle-exact: no full fetch/shift pipeline or exact sprite evaluation
  • DMC bus arbitration and CPU DMA alignment are incomplete
  • No FPGA bitstream and no board validation
  • No multi-game lockstep DiffTest; compatibility is partial
  • Formal refinement covers 19 of 151 instructions; IRQ/NMI entry and reset are not yet proven
  • No commercial-ROM compatibility guarantee
Full verification matrix, golden hashes and repro commands live in the docs. Verification →
04Parity

One frame. Two worlds.

On one side the NEMU software reference; on the other the SystemVerilog RTL. Drag the divider — you can't see a difference. That's the point.

NEMU is REF; RTL is DUT. Same ROM, same frame, same 256×240 NTSC image. RTL's SHA-256 is identical to NEMU's. That means the chain from CPU fetch to PPU pixels agrees — at least for this frame.

RTL / DUT 41e8ebc137e3b8ede2f0adf915956fb9454346e9454e358c6dad2ee5a58f5a33
NEMU / REF 41e8ebc137e3b8ede2f0adf915956fb9454346e9454e358c6dad2ee5a58f5a33
CPU Klaus PASS · PC=0x3469
DiffTest Final state · PC trace · ALU/stack PASS
FALLING title frame rendered by NEMU
FALLING title frame rendered by the RTL SoC
NEMU / REF RTL / DUT
← drag the divider → 256 × 240 · pixel-identical
05Architecture

One NES, twelve modules.

A single 21.477272 MHz clock with enable phases for CPU, PPU and APU — no multi-clock CDC. Every peripheral exposes observable bus events for DiffTest against NEMU.

Open6502 SoC block diagram The CPU connects through the system bus to the PPU, WRAM, APU, cartridge mapper and IO. The PPU outputs RGB444 video; clocks and reset generate the phase enables; the debug bridge sends events to the NEMU reference model. OPEN6502_TOP · SOC BLOCK DIAGRAM NTSC · SINGLE CLOCK + ENABLES CLOCKS / RESET 21.477272 MHz · ÷12 · ÷4 · ÷24 clk_en phases 6502 CPU 2A03 profile · official ISA NMI IRQ DMA STALL SYSTEM BUS address decode · OAM DMA · arbitration CPU / PPU / APU 2C02 PPU 341 × 262 · per-dot pixels VRAM 2K OAM 256 PAL 32 BG fetch · sprites · scroll · NMI VIDEO RGB444 VGA / HDMI address / data / control 2 KB WRAM four-way mirror $0000–$1FFF CPU read/write · no wait 2A03 APU + DMC 2× pulse · triangle · noise 44.1 kHz σΔ / PCM CARTRIDGE / MAPPER PRG · CHR · mirroring · IRQ 0 1 2 3 4 7 I/O OAM DMA 2 controllers dbg DBG / DIFFTEST BRIDGE CPU · BUS · PPU · APU events → NEMU REF (simulation only; FPGA exports summaries / hashes)
single clock + enables CPU / PPU / APU / Mapper DiffTest observable 12 RTL modules

Clock domains

clk_21m21.477272 MHz
cpu_en1.789773 MHz
ppu_en5.369318 MHz
aud_en44.1 kHz

Address map

$0000–$1FFF2KB WRAM ×4
$2000–$3FFFPPU registers
$4000–$4017APU / DMA / pad
$8000–$FFFFcartridge PRG

Top-level ports

input  clk_21m, rst_n;
output vid_pclk, vid_de;
output vid_hsync, vid_vsync;
output [11:0] vid_rgb;
output aud_valid;
output signed [15:0] aud_sample;
input  [7:0] joy1, joy2;
// cart bus + dbg event
Full block diagram, clock and port definitions, and module boundaries. Docs · Architecture →
06Silicon

From a million gates, to 1.5 mm².

These are Yosys generic-cell estimates, not silicon area. They say one thing: the CPU is small, the PPU is the elephant. Next step: replace the PPU register arrays with BRAM / SRAM.

1,021,421
Yosys generic cells
975,919 cells
PPU alone: 95.5% of area
1.2–2.0 mm²
Planned 55nm die after SRAM + PPU refactor
$0.3–0.7
Unit cost at volume (planning estimate)

Generic-cell area split

YOSYS 0.60 · -flatten -noabc · per-module sum
PPU · 975,919 WRAM · 37,003 Remaining modules · 8,499
Generic cells ≠ FPGA LUTs ≠ ASIC µm². Full top-level flatten did not finish within 600 s; the table is a per-module sum. No timing closure, BRAM mapping or standard-cell mapping yet.
Per-module area, PPU breakdown and cost assumptions. Docs · Synthesis & area →
07Roadmap

Four gates. No skipping.

A later stage may not hide a failure in an earlier one. This is both the roadmap and the acceptance rule: NEMU → RTL → FPGA → 55nm ASIC.

01 · NEMU

Software reference

Prove the game runs correctly first. Six ROMs playable, CPU Klaus PASS, screenshots reproducible.

status WORKING · 90%
02 · RTL

SystemVerilog SoC

28 tests, Klaus PASS, golden frame SHA match, START frame rendered. Missing cycle accuracy.

status PROTOTYPE · 60%
03 · FPGA

First light on a board

Needs full synthesis, BRAM inference, timing constraints, VGA/HDMI and audio, plus board bring-up.

status NEXT · 10%
04 · 55 nm

An open, verifiable chip

55nm standard cells and SRAM, DFT/scan, timing/power, DRC/LVS, package and shuttle.

status PLANNING · 5%
Exit criteria, current blockers and next work for every stage. Full roadmap ↗
08Contribute

It needs more than a star.

This project spans software, RTL, FPGA and ASIC. If any layer stalls, 55nm never happens. If you only know one slice, that's enough.

09FAQ

The unpleasant truths, up front.

The questions visitors ask most, answered without polish. Deeper fixes are in the docs' Troubleshooting section.

Can I play in the browser?
Yes. The demo on this page is the GEM6502 core compiled to WebAssembly, with the six open-source ROMs. NEMU and the RTL SoC remain local programs; RTL frames are captured through Verilator. The site only runs the reference-model side and does not pretend to offer online RTL. Commercial ROMs are neither bundled nor promised.
Do you support commercial ROMs like Super Mario Bros.?
Not bundled, not linked. Compatibility is still improving, and no commercial ROM is promised to work. Only use ROMs you legally own.
Why is there no FPGA bitstream yet?
Full synthesis, BRAM mapping, timing constraints and board bring-up are not done. The PPU currently expands CHR/VRAM/OAM/palette into flip-flops, which won't fit a board; storage must move to BRAM and sprite scanning must become sequential first.
When is the 55nm tapeout?
No date. It's a long-term goal; this is a functional prototype. The roadmap requires FPGA validation before timing, DFT, DRC/LVS and a shuttle. The root licence isn't even published.
Should I start with NEMU or RTL?
Want to play or verify behaviour: start with NEMU. Want to build a chip: start with RTL and docs/open6502-chip/. Just want a fast C model: GEM6502 — but note it's still a legacy instruction-driven model, not a complete chip timing platform.
What's the licence? Can I reuse it?
No root licence yet. The six ROMs are MIT, and brand assets are in docs/images/. Until the maintainers publish the root licence and contribution terms, don't assume the code is redistributable; read CONTRIBUTING.md first.
Next step

Play a round, or read the code.

Both roads lead to the same chip. The only difference is where you enter.