The slowest Game Boy emulator.
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 
 
 
 
Zack Marvel e388031796 Fix button bug il y a 1 mois
notes Thoughts on implementing a debugger il y a 2 ans
scripts Pretty functional debugger, still trying to figure out wh il y a 1 mois
slowboy Fix button bug il y a 1 mois
test_roms Pretty functional debugger, still trying to figure out wh il y a 1 mois
tests Pretty functional debugger, still trying to figure out wh il y a 1 mois
.gitignore Ignore a bunch of junk in my working directory il y a 1 an
.travis.yml change directory back to project root after building SDL2 il y a 2 ans
LICENSE Initial commit il y a 5 ans
README.md Pretty functional debugger, still trying to figure out wh il y a 1 mois
coverage coverage helper script il y a 1 an
ctags ctags helper script il y a 1 an
regs.txt Actually playing with an implementation of a CPU. Also added some notes. il y a 4 ans
setup.py Move Pillow to development deps; add pytest to development deps il y a 2 ans

README.md

slowboy

slowboy aims to be the slowest Gameboy emulator. Just kidding---but the goal of this project isn’t to create a fast emulator, since those already exist. The goal is twofold: can a reasonably performant Gameboy emulator be build in Python, and can it serve as an easy-to-read codebase for others who want to emulate this system?

TODO

  • Audio
  • Handle different bank controller configurations

See notes/performance.md for some thoughts on speeding up the emulator.

An eventual goal is improving the debugger---see notes/debugging.md.

Test ROMs

  • Test interrupts

Installation

If you install this emulator, it probably won’t play very many games. Here are some things you could do:

  • Try running games and create an issue if they don’t run, especially if it crashes.
  • Try running or writing the test “games” in test_roms/ and create an issue if they don’t work or crash on your system.

If hacking on it is what you’re interested in, please forge ahead!

Development

Dependencies

This program uses SDL2 for graphics, and eventually the unit tests will require some of the SDL2 data structures. Currently, it requires at least libsdl2 version 2.0.5 or greater. I’d like to eventually relax the requirement to at most 2.0.2 to support Debian 8 and Ubuntu 16.04.

On the following distributions, the SDL2 package is too old, so you’ll need to build it from source:

  • Debian 8 (2.0.2)
  • Ubuntu 14.04 (2.0.2) and 16.04 (2.0.4)

I develop on Linux---these Linux distributions package at least libsdl2 version 2.0.5:

  • Debian 9: libsdl2-2.0-0 (2.0.5)
  • Ubuntu 18.04: libsdl2-2.0-0 (2.0.8)
  • CentOS 7: SDL2 (2.0.8, from EPEL---install epel-release)

Installation

After cloning the repository, you can install the project for development with

$ pip install --editable .\[dev\]

You can run the tests from the root of the project with

$ pytest

Additionally, if you have coverage installed, you can use that:

$ coverage run --source slowboy -m unittest discover tests
$ coverage html

Known Issues

Running the unit tests with pytest on my system causes a segfault for some reason. The workaround is just running the tests with unittest:

$ python -m unittest discover tests