TheThief / CoroGB

CoroGB is an experimental gameboy emulator written in C++ w/ coroutines

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CoroGB

CoroGB is an experimental gameboy emulator written in C++ w/ coroutines

It is primarily developed for personal advancement, but is hopefully of interest.

Note

A boot rom must be provided! It should be named dmg_rom.bin and placed in the executable's directory (project root also works when running from Visual Studio)

Controls

Up / Down / Left / Right / Z / X / RShift / Enter

Numpad+ is speed up

Tests

Blargg's tests

Test mooneye-gb CoroGB
cpu instrs πŸ‘ β­•
dmg sound 2 ❌ ❌
instr timing πŸ‘ ❌
mem timing 2 πŸ‘ ❌
oam bug 2 ❌ ❌
halt bug πŸ‘

Notes:

  • cpu_instrs #2 fails on CoroGB due to not yet having implemented the timer
  • sound is unimplemented in CoroGB

Mooneye GB acceptance tests

Test mooneye-gb CoroGB
add sp e timing πŸ‘ πŸ‘
boot div dmgABCmgb ❌ ❌
boot hwio dmgABCmgb ❌ ❌
boot regs dmgABC πŸ‘ πŸ‘
call timing πŸ‘ πŸ‘
call timing2 πŸ‘ πŸ‘
call cc_timing πŸ‘ πŸ‘
call cc_timing2 πŸ‘ πŸ‘
di timing GS πŸ‘ πŸ‘
div timing πŸ‘ πŸ‘
ei sequence πŸ‘ πŸ‘
ei timing πŸ‘ πŸ‘
halt ime0 ei πŸ‘ πŸ‘
halt ime0 nointr_timing πŸ‘ πŸ‘
halt ime1 timing πŸ‘ ❌
halt ime1 timing2 GS πŸ‘ πŸ‘
if ie registers πŸ‘ πŸ‘
intr timing πŸ‘ πŸ‘
jp timing πŸ‘ πŸ‘
jp cc timing πŸ‘ πŸ‘
ld hl sp e timing πŸ‘ πŸ‘
oam dma_restart πŸ‘ πŸ‘
oam dma start πŸ‘ πŸ‘
oam dma timing πŸ‘ πŸ‘
pop timing πŸ‘ πŸ‘
push timing πŸ‘ πŸ‘
rapid di ei πŸ‘ πŸ‘
ret timing πŸ‘ πŸ‘
ret cc timing πŸ‘ πŸ‘
reti timing πŸ‘ πŸ‘
reti intr timing πŸ‘ πŸ‘
rst timing πŸ‘ πŸ‘

Notes:

  • boot_hwio-dmgABCmgb needs sound emulation
  • halt_ime1_timing needs timer

Bits (unusable bits in memory and registers)

Test mooneye-gb CoroGB
mem oam πŸ‘ πŸ‘
reg f πŸ‘ πŸ‘
unused_hwio GS πŸ‘ πŸ‘

Instructions

Test mooneye-gb CoroGB
daa πŸ‘ πŸ‘

Interrupt handling

Test mooneye-gb CoroGB
ie push πŸ‘ πŸ‘

OAM DMA

Test mooneye-gb CoroGB
basic πŸ‘ πŸ‘
reg_read πŸ‘ πŸ‘
sources dmgABCmgbS πŸ‘ πŸ‘

PPU

Test mooneye-gb CoroGB
hblank ly scx timing GS πŸ‘ ❌
intr 1 2 timing GS πŸ‘ πŸ‘
intr 2 0 timing πŸ‘ ❌
intr 2 mode0 timing πŸ‘ πŸ‘
intr 2 mode3 timing πŸ‘ πŸ‘
intr 2 oam ok timing πŸ‘ ❌
intr 2 mode0 timing sprites ❌ ❌
lcdon timing dmgABCmgbS ❌ ❌
lcdon write timing GS ❌ ❌
stat irq blocking ❌ πŸ‘
stat lyc onoff ❌ ❌
vblank stat intr GS πŸ‘ ❌

Notes:

  • Yes, CoroGB implements stat IRQ blocking!

Serial

Test mooneye-gb CoroGB
boot sclk align dmgABCmgb ❌ ❌

Notes:

  • Serial clock not implemented

Timer

Test mooneye-gb CoroGB
div write πŸ‘ ❌
rapid toggle πŸ‘ ❌
tim00 div trigger πŸ‘ ❌
tim00 πŸ‘ ❌
tim01 div trigger πŸ‘ ❌
tim01 πŸ‘ ❌
tim10 div trigger πŸ‘ ❌
tim10 πŸ‘ ❌
tim11 div trigger πŸ‘ ❌
tim11 πŸ‘ ❌
tima reload πŸ‘ ❌
tima write reloading πŸ‘ ❌
tma write reloading πŸ‘ ❌

Notes:

  • Timer not implemented

Mooneye GB emulator-only tests

MBC1

Test mooneye-gb CoroGB
bits ram en πŸ‘ πŸ‘
rom 512Kb πŸ‘ πŸ‘
rom 1Mb πŸ‘ πŸ‘
rom 2Mb πŸ‘ πŸ‘
rom 4Mb πŸ‘ πŸ‘
rom 8Mb πŸ‘ πŸ‘
rom 16Mb πŸ‘ πŸ‘
ram 64Kb πŸ‘ πŸ‘
ram 256Kb πŸ‘ πŸ‘
multicart rom 8Mb πŸ‘ πŸ‘

Notes:

  • Yes, CoroGB supports MBC1 multicart roms!

Mooneye GB manual tests

Test mooneye-gb CoroGB
sprite priority πŸ‘ πŸ‘

Mealybug tests

Test CoroGB
m3_wx_4_change ❌
m3_wx_4_change_sprites ❌
m3_wx_5_change ❌
m3_wx_6_change ❌
m2_win_en_toggle ❌
m3_bgp_change ❌
m3_bgp_change_sprites ❌
m3_lcdc_bg_en_change ❌
m3_lcdc_bg_en_change2 ❌
m3_lcdc_bg_map_change ❌
m3_lcdc_bg_map_change2 ❌
m3_lcdc_obj_en_change ❌
m3_lcdc_obj_en_change_variant ❌
m3_lcdc_obj_size_change ❌
m3_lcdc_obj_size_change_scx ❌
m3_lcdc_tile_sel_change ❌
m3_lcdc_tile_sel_change2 ❌
m3_lcdc_tile_sel_win_change ❌
m3_lcdc_tile_sel_win_change2 ❌
m3_lcdc_win_en_change_multiple ❌
m3_lcdc_win_en_change_multiple_wx ❌
m3_lcdc_win_map_change ❌
m3_lcdc_win_map_change2 ❌
m3_obp0_change ❌
m3_scx_high_5_bits ❌
m3_scx_high_5_bits_change2 ❌
m3_scx_low_3_bits ❌
m3_scy_change ❌
m3_scy_change2 ❌
m3_window_timing ❌
m3_window_timing_wx_0 ❌

Other tests

Test CoroGB
acid2 πŸ‘
dycptest2 ❌
lyc πŸ‘
opus5 πŸ‘
sprite_test_01 πŸ‘
wx_split πŸ‘
windows_overlap πŸ‘
window_y_trigger πŸ‘

About

CoroGB is an experimental gameboy emulator written in C++ w/ coroutines

License:Other


Languages

Language:C++ 98.3%Language:Assembly 0.9%Language:C 0.8%