Skip to content

CHIP-8 ​

chip8 runs CHIP-8 programs in a window on your desktop. CHIP-8 is a small virtual machine from the 1970s with a 64×32 black-and-white screen, a 16-key keypad and a one-tone beeper. It is the usual first project for people learning how emulators work.

What it does ​

  • Runs .ch8 ROMs in an SDL2 window, with keyboard input and a 440 Hz beep.
  • Lets you set the speed in instructions per second, separately from the 60 Hz timers.
  • Offers two quirk profiles: the original COSMAC VIP behaviour (the default) and a modern profile for ROMs written for later interpreters.
  • Includes a headless runner, chip8_run_rom, that runs a ROM without a window and prints the screen as text. The project's test suite is built on it.
  • Is tested by ROMs, not by eye. The interpreter passes the Timendus chip8-test-suite logo, opcode, flags, quirks and keypad tests.

Who it is for ​

  • Students who want a small, readable interpreter to run and study.
  • People who write CHIP-8 programs and want to check them against original VIP behaviour.
  • Anyone curious about the patterns the Game Boy emulator builds on.

What it does not do ​

chip8 runs classic CHIP-8 only. SUPER-CHIP and XO-CHIP extensions (high resolution, scrolling, colour planes), save states and custom colours are out of scope. The beep is a fixed 440 Hz square wave.

Platforms ​

Linux and Windows, on x64 and ARM64. You build it from source with CMake. See Install.

No ROMs are bundled. The beginner guide uses the free Timendus test ROMs, which a script in the repository downloads for you.

Next steps ​