The emulator requires SDL.
To run the emulator, clone the repo and inside the directory:
cargo run </path/to/game>
If you want to build the source, you can run:
cargo build --release
The output binary is located at target/release/chip8_rust
The speed the emulator runs can be increased/decreased with Up/Down arrow.
Escape will quit and Space will restart
Key mapping is as follows:
Chip8 Key Original Layout
1 | 2 | 3 | C |
4 | 5 | 6 | D |
7 | 8 | 9 | E |
A | 0 | B | F |
Mapped Key Layout
1 | 2 | 3 | 4 |
Q | W | E | R |
A | S | D | F |
Z | X | C | V |
- Main - main.rs
- Main Game Loop
- CPU - cpu.rs
- CPU Initialization
- Determine OPcode and execute instruction functions
- Load ROM into memory
- Load Fonts into memory
- Emulator Timers
- Instructions - instructions.rs
- functions for instruction execution used by CPU
- Subsystem - subsystem.rs
- SDL
- Display
- Audio
- Key input