Overview
A Game Boy (DMG-01) emulator written in Rust, focusing on accurate emulation and educational purposes. This project is both a learning experience in systems programming and a practical implementation of hardware emulation concepts. I hope to also blog the process of building this project, so check back for more.
Key Achievements
Core Implementation
- Implemented fundamental CPU components including registers, program counter, and stack pointer
- Successfully executed basic arithmetic and control flow instructions
- Developed memory bus with address space mapping capabilities
Instruction Set Progress
- Core arithmetic operations (
ADD, SUB, INC, DEC) - Control flow instructions (
JP, CALL, RET, HALT, NOP) - Stack operations (
PUSH, POP) - Memory operations (partial
LD instruction support)
Technical Architecture
CPU Implementation
- 8-bit register implementation
- Program counter and stack pointer management
- Instruction decoding and execution pipeline
- Clock cycle accuracy focus
Memory Management
- Memory address space mapping (0x0000 - 0xFFFF)
- RAM and VRAM access implementation
- Memory bank controller groundwork
Development Practices
Testing Strategy
- Integration with Blargg’s test ROMs
- Unit tests for CPU operations
- Memory access validation
- Instruction timing verification
Current Development Status
Implemented Features
- Basic CPU architecture
- Core instruction set fundamentals
- Memory bus framework
- Basic address space mapping
In-Progress Features
- Expanding CPU instruction set
- Memory controller improvements
- ROM loading capabilities
- Interrupt handling system
Future Roadmap
Short-term Goals
- Complete basic instruction set implementation
- Pass Blargg’s CPU test ROMs
- Implement timer system
- Add interrupt handling
Long-term Goals
- Graphics processing unit (PPU) implementation
- Audio processing unit (APU) support
- Game Boy Color compatibility
- Save state functionality
- Debugger interface
Technical Resources
Documentation
Test Suites
Learning Outcomes
- Deeper understanding of CPU architecture and the Game Boy instruction set
- Reading technical documentation including reference manuals
- Memory management concepts
- Systems programming with bit operations