About Breaknes

Gate-level NES / Famicom / Dendy emulation — the emulator part of the breaks chip-reversing project

Breaknes is an NES/Famicom/Dendy emulator at the gate level. The chips are not emulated “by behavior”: the logic circuits reconstructed from the real dies are duplicated in C++, so the emulated 6502 behaves the same way the real one does — same gates, same flip-flops, same buses, same quirks.

What is inside

The repository contains the emulator itself, gate-level chip simulators, a data-driven cartridge PCB simulator, the converted cartridge database, unit tests, and a set of tools. The emulator has two front-ends that share the native core: a managed WinForms application and an SDL2 port that builds on Windows and Linux.

Repository structure

FolderWhat’s inside
Breaknes/The emulator itself: managed GUI (Breaknes/Breaknes), SDL2 port (Breaknes/BreaknesSDL), and the native core BreaksCore shared by both.
Chips/Gate-level simulators of the chips: M6502Core (6502), APUSim (2A03/2A07 CPU+audio), PPUSim (2C02 PPU), MMC1.
CartPcb/Functional simulation of cartridge PCBs. A board is data — a JSON document with components and wiring, not C++ code.
Common/Shared code: BaseLogicLib (logic primitives), BaseBoardLib (motherboard components: LS139, LS373, SRAM, RomChip…), JsonLib, SharpTools (C# debugger controls).
IO/I/O devices: NES/Famicom/Dendy controllers, virtual controllers, CD4021, UM6582.
Nescartdb/The converted nescartdb database (JSON) — identifies a cartridge by the CRC32 of its PRG/CHR dumps.
Tools/Utilities (assembler, debugger GUI, PPU/APU players, demos…).
UnitTest/Unit tests for the chips and cores.
Wiki/Design documentation — partially republished on this site.

Simulation components

Tools

ToolWhat it does
BreakasmThe simplest possible 6502 assembler (C++ + Python port).
BreaksDebugGUI to inspect the 6502 core: signals, registers, memory, disassembly.
PPUPlayerReplays PPU register dumps recorded in the emulator.
APUPlayerReplays APU register dumps recorded in the emulator.
PpuPumpkin / ApuPumpkinSpeed profiling demos for PPUSim / APUSim.
SlooowPlaaayerPlays audio captured from slow sources.
SignalPlotDemo, FurryPlotDemo, InfernoColormapDemos of the custom WinForms controls.
DumpRegdump / NescartdbConvertPython scripts: regdump dump / nescartdb XML→JSON conversion.

Building

Windows: VS2026 — open Breaknes.sln and build. .NET 6.0 Desktop runtime is required. For a minimal build use the SDL2 port (Breaknes/BreaknesSDL).

Linux: typical CMake flow (cmake .. + make in a build/ folder), produces the SDL2 binary.

Source: Readme.md, Wiki/Readme.md · this page is part of the docs site.