CHIP-8 emulator for Windows & MacOS written in Rust
Game: "Space Invaders" by David Winter
You can get the emulator from the releases tab for 64-bit Windows and Intel Mac devices.
The release comes packaged with a few games. Many more are available to download from the CHIP-8 ROM archive and elsewhere on the internet as freeware. Select the game you'd like to play by editing the settings.yaml
file. All games are loaded from the roms
folder.
The CHIP-8 uses a hexadecimal keypad for input. These are mapped as such on a QWERTY keyboard:
CHIP-8 Computer
Hex Keypad Keyboard
.---.---.---.---. .---.---.---.---.
| 1 | 2 | 3 | C | | 1 | 2 | 3 | 4 |
.---.---.---.---. .---.---.---.---.
| 4 | 5 | 6 | D | | Q | W | E | R |
.---.---.---.---. -> .---.---.---.---.
| 7 | 8 | 9 | E | | A | S | D | F |
.---.---.---.---. .---.---.---.---.
| A | 0 | B | F | | Z | X | C | V |
.---.---.---.---. .---.---.---.---.
Each game uses it's own control scheme, so if you're unsure how a game works then play around with the keys to see what each one does.
I'm not a Rust expert. There are almost certainly more idiomatic approaches to implementation, so keep that in mind while reading the code.
- Technical reference: http://devernay.free.fr/hacks/chip8/C8TECH10.HTM
- Implementation guides: