R8 is a CHIP-8 emulator written in Rust.
It has two modes of operation
- using sdl2 and egui. With an small GUI for debugging, control the emulator speed and step cycle by cicle, loading roms and assembling source code.
- using crossterm to make a simple TUI.
On windows:
- rustup
On Linux:
- rustup
- sdl2 (only for sdl2-gui)
- libgtk3 (only for sdl2-gui)
Follow the instructions on the Rust website.
git clone https://github.com/CarlosEduardoL/R8
cd R8
cargo run --release --features "sdl2-gui" --bin r8-sdl2
cd R8
cargo run --release --features "tui-gui" --bin r8-tui
CHIP-8 is an interpreted programming language that was used to create games for some home computers in the 1970s and 1980s. It has a simple instruction set and graphics system, and it can run on various platforms with minimal changes.
- All opcodes are implemented
- The display works
- The keyboard works
- The timers work
- The sound works
- The debugger works
- The GUI works
- The roms drag and drop works
- Use default system file explorer to load roms
- The assembler works
- You can load a plain text assembler file and run it
- You can use a slider to change the speed of the emulator
- TUI works
- Add a Wasm version
- Add a disassembler
- Add the posibility to save/load state
I used the following sources to learn about CHIP-8 and implement the emulator: