Skip to content

A very simple and naive implementation of a CHIP-8 interpreter in rust

Notifications You must be signed in to change notification settings

romgrelier/CHIP-8-rust-interpreter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

A CHIP-8 interpreter

This is a CHIP-8 interpreter I made to learn the RUST programming language and to learn more about compilation/(re)interpreter.

Usage

To use it, you just have to download this repo and run it with cargo and give it a CHIP-8 program to run.

'cargo run program.chip8'

A window will appear with the content of the screen, the CHIP-8 keypad is mapped to your keyboard from the keys 1, 2, 3, 4 and under.

How it works ?

All the 35 instructions are implemented through a CHIP-8 trait (instructions.rs) and implemented in a disassembler (disassembler.rs) to convert the input program into a more readable text format and in an intepreter for execution (interpreter.rs) on a cpu (cpu.rs). The cpu contains the registers, memory and screen and is modified during execution.

Libraries used

Sources

Guide to making a CHIP-8 emulator CHIP-8 virtual machine specification Chip-8

About

A very simple and naive implementation of a CHIP-8 interpreter in rust

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages