Pixel Forge is an emulator virtual machine designed to run Chip8 and Super-Chip ROMs.
NOTE: The MacOS executable does not yet work without modifications due to OpenGL compatibility issues
The release section of this repository contains pre-compiled binaries for macOS, Windows and Linux. Download the .zip file, extract it and run the executable to use to emulator.
NOTE: Users on MacOS need to change the OpenGL version from 4.6 to 4.1 to run the emulator due to compatibility issues
You can also compile the binary on your local machine with ease.
C++ 20 (or higher) CMake 3.11+ GLFW3
Run CMake to compile the binary
cmake -S . -B build
cmake --build build -j $(nproc)
The binary will be available in build/PixelForge
Double click on the binary or use the terminal to execute it ./PixelForge
The emulator starts with a black screen. Drag and drop any chip-8 or SCHIP game ROM into this window to start the emulator.
Chip-8 emulator keypad map:
| 1 | 2 | 3 | C |
|---|---|---|---|
| 4 | 5 | 6 | D |
| 7 | 8 | 9 | E |
| A | 0 | B | F |
Corresponding keyboard keys:
| 1 | 2 | 3 | 4 |
|---|---|---|---|
| Q | W | E | R |
| A | S | D | F |
| Z | X | C | V |
- Cross platform support: The executable can be compiled on linux, windows and macOS.
- Chip-8 extension support: The emulator supports ROMs from the original Chip-8, Super-Chip and XO Chip.
- Hardware quirks support: The hardware has been modeled for configurable hardware quirks.
- CPU Freuency: The emulator CPU runs at 700Hz, however that can be easily modified by the changing the
EMULATOR_FREQUENCYconstant ininclude/system.hh - Dynamic resolution scaling: The game can switch between a low resolution (
64x32) and high resolution (128x64) display modes.
- src/Processor: CPU instructions, fetch, decode, execute, call stack.
- src/IO: keypad state management.
- src/Memory: System RAM (4KB) load, store.
- src/Timer: Delay and Sound timer states, set, decrement
- src/Display: Pixel buffer of the screen, clear, scroll, etc.
- src/Util: Emulator window manager and ROM loader components
- Emulator window crashes on drag and drop hover in wayland compositors
- No sound
- AI was used for understanding the inner state of the emulator
- Completion of repetitive tasks (such as ISA definition)
- OpenGL state management and pixel texture buffer uploads