Building a GameBoy emulator with Elixir and Scenic
summary
Builds a working but incomplete GameBoy emulator in Elixir + Scenic, boots Tetris ROM and renders frames by translating GameBoy tiles into textures. Implements CPU and MMU logic for roughly ~500 CPU instructions, 4 MHz emulation and uses a binary memory blob; performance is adequate but not fully cycle-accurate. Hits drawing limits in Scenic so created native texture API via NIFs to update pixels directly; HBlank/VBlank timing and some instruction bugs remain.
AI-written summary · about
chapters (13)
- 0:00The unexpected project
- 2:01Emulation goals and TDD
- 3:36Understanding the hardware
- 5:08CPU and memory implementation
- 7:35Booting and running instructions
- 10:41Graphics and tile rendering
- 12:21Introduction to Scenic UI
- 14:53Solving the rendering problem
- 17:54Optimizing with C NIFs
- 20:19Demo and debugging issues
- 23:46CRT timing and future work
- 25:43Conclusion and Q&A
- 27:43Technical details and debugging
related talks
40mBuilding a GameBoy emulator with Elixir and Scenic
18mEmulating the Nintendo Game Boy CPU with Elm
56mEmulating a Game Boy in .NET 6
10mState of Retro Gaming in Emacs
37mEmulators, Immutability, and Time Travel
18mWriting a Game Boy compiler in Forth
06mBattery-free GameBoy
39mThe Day I Reverse Engineered a Gameboy Advance Game
