Skip to content

🎮 A CHIP-8 interpreter (and virtual machine) written in C++ with SDL2 and WebAssembly

Notifications You must be signed in to change notification settings

digitsensitive/chip8-wasm

Repository files navigation

A CHIP-8 interpreter (and virtual machine) written in C++17 with SDL2 and WebAssembly

This project was created to deal with the creation of an interpreter in more detail and to use WebAssembly for the first time.

I have documented and described the development of the project in detail on the following article on Medium.

Have fun reading through and coding!

Prerequisites

Installation

  • Download the submodules with git submodule update --init
  • Create the build folder with mkdir build
  • Navigate to the build folder with cd build
  • Run emcmake cmake .. and make
  • Start the localhost in the root folder with yarn http

Code formatter

Use of ClangFormat. The style options are defined in the .clang-format file. For more details have a look at the official Style Options.

Emscripten Compiler

The Emscripten Compiler Frontend (em++ für C++) is used to call the Emscripten compiler from the command line. For more details about the arguments look at the official Emscripten Compiler Frontend Reference

To do list

  • Setup basic repository (C++, WebAssembly)
  • Setup basic VSCode configuration (C++, Clang)
  • Medium: Write history section
  • CHIP-8: Add memory
  • CHIP-8: Add registers
  • CHIP-8: Add stack
  • Medium: Write references section
  • CHIP-8: Add delay and sound registers
  • CHIP-8: Add program counter (PC)
  • CHIP-8: Add input (keypad)
  • CHIP-8: Add display
  • CHIP-8: Add fontset
  • CHIP-8: Add instructions
  • Public Folder: Add roms
  • Medium: Write instructions section
  • Add Prettier to package.json with prettier configuration file
  • [] Write disassembler (https://aimechanics.tech/2020/09/03/chip8-emulation-rom-disassembler)
  • [] Read the following ressource: http://vanbeveren.byethost13.com/stuff/CHIP8.pdf?i=1

About

🎮 A CHIP-8 interpreter (and virtual machine) written in C++ with SDL2 and WebAssembly

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages