Skip to content

miguel-nascimento/chip-8

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chip-8

A simple CHIP-8 emulator written in Rust and compiled to WebAssembly.

It passes all the test from Timendus CHIP-8 test suite and it works with PONG too.

Why its flickering?

It's due to the way CHIP-8 handles the draw operation. It draws the sprites with XOR, so if a pixel is already on, it will be turned off. This is why the flickering happens.

Lack of sound effects.

CHIP-8 doesnt have a good sound system, so I decided to not implement it.

Usage

cd wasm/web
python3 -m http.server

Then open your browser at http://localhost:8000/ and you should see the emulator running.

Wasm build

In case you want to build the wasm module again, you can do it with the following commands:

cd wasm
wasm-pack build --target web
mv ./pkg/wasm_bg.wasm ./web
mv ./pkg/wasm.js ./web

More info

Good reading:

About

Chip 8 emulator written in Rust 🕹️

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published