Skip to content

akelsh/mono-gb

Repository files navigation

Mono-GB

Gameboy Games Showcase

Mono-GB is a relatively cycle-accurate Gameboy color emulator built in modern C++. Despite the name, the emulator fully supports both DMG and CGB games in full color.

This is a hobby project with the main goal being to understand the intricacies of low-level system design.

Features

The following is a list of fully implemented features:

  • Backwards compatibility with the original Gameboy.
  • Machine Cycle accurate CPU.
  • Dual-speed support
  • Support for MBC1, MBC2, MBC3, and MBC5.
  • DMG colorization.
  • Dot accurate PPU sprite & BG pipelines.
  • Phase-based instruction execution.

This project is still a work in progress. The following is a list of features I am planning on implementing:

  • Audio support.
  • T-state based instruction execution.
  • A fully functional debugger.

Tests

The accuracy of a gameboy emulator is usually determined by test ROMs that are created using the real hardware.

The following is a list of the ROM tests that Mono GB passes:

Build

Mono-GB uses CMake presets for building. Ensure you have CMake (3.21+), Ninja, and a C++23 compatible compiler installed.

Unix-like (Linux/macOS)

To build for release:

# Configure the project
cmake --preset unixlike-gcc-release

# Build the project
cmake --build out/build/unixlike-gcc-release

Windows (MSVC)

To build for release:

# Configure the project
cmake --preset windows-msvc-release-user-mode

# Build the project
cmake --build out/build/windows-msvc-release-user-mode

Running

After building, the executable can be found in the src directory within the build folder.

# Unix-like
./out/build/unixlike-gcc-release/src/mono_gb

# Windows
./out/build/windows-msvc-release-user-mode/src/RelWithDebInfo/mono_gb.exe

Credits

Resources:

Showcase Games:

Tests:

UI

About

A relatively cycle-accurate Gameboy color emulator built in modern C++

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors