Personal attempt at creating a simple DMG GameBoy emulator from scratch.
- Support MBC1 or no MBC games
- Use A/Z for A/B, arrows keys to move, space for start and return for select
- Sound
- Display
- Rich debugging features
- Save states: F3 to save, F5 to load, F4 to change slots (5 slots available)
- F1 to show debugger
- F2 to activate breakpoints
- F9 to toggle execution/suspended mode
- F10 to load another game
- The Ultimate Game Boy talk at 33c3
- Why did I spend 1.5 months creating a Gameboy emulator?
- Z80 Family CPU User Manual
- Dooskington wiki about emulators
- Pan Docs
- Game Boy DMG original Boot ROM
- Game Boy Opcodes
- Game Boy Opcodes (other version)
Tested on Linux. Does not seem to compile as it is for Windows. Not tested at all for other OS. Should only require SDL2.
Contains submodules so clone with something like --recurse-submodules
make clean; make
Test with ./test
# | name | state |
---|---|---|
04 | halt_bug | ❌ |
05 | instr_timing | ✔️ |
07 | mem_timing-2 | ❔ |
08 | mem_timing | ❌ |
09 | oam_bug | ❔ |
# | name | state |
---|---|---|
01 | special | ✔️ |
02 | interrupts | ✔️ |
03 | op sp,hl | ✔️ |
04 | op r,imm | ✔️ |
05 | op rp | ✔️ |
06 | ld r,r | ✔️ |
07 | jr,jp,call,ret,rst | ✔️ |
08 | misc instrs | ✔️ |
09 | op r,r | ✔️ |
10 | bit ops | ✔️ |
11 | op a,(hl) | ✔️ |
# | name | state |
---|---|---|
01 | registers | ✔️ |
02 | len ctr | ✔️ |
03 | trigger | ✔️ |
04 | sweep | ✔️ |
05 | sweep details | ✔️ |
06 | overflow on trigger | ✔️ |
07 | len sweep period sync | ✔️ |
08 | len ctr during power | ✔️ |
09 | wave read while on | ❌ |
10 | wave trigger while on | ❌ |
11 | regs after power | ✔️ |
12 | wave write while on | ❌ |
- Implement Z80 instruction set
- [-] Implement interupts
- V-Blank
- LCD Stat
- Timer
- Serial
- Joypad
- Implement MMU
- Implement PPU
- Implement inputs
- Sound!
- Support all MBC
- MBC1
- Others