Skip to content

secondsun/chip8

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CHIP 8 by secondsun

A TDD Chip-8 implementation designed to teach how to write an "emulator" from scratch.

You Tube Demo

Welcome

Chip-8 is a was created in the 1970s by Joseph Weisbecker to run games on the 8-bit computers of the day. Chip-8 includes an assembly language, an interpreter, and the runtime. There is a community around the platform which has created several games, and it has also expanded the platform to include newer features. However, this project focuses on just the "vanilla" Chip-8 from the 1970s.

This project focuses on implementing the Chip8 interpreter in a test driven manner. You don't need any experience in writing emulators, but understanding Hexedecimal notation and binary operators are important.

The master branch of this project is a stubbed out TDD project. The working branch has my finished project.

Prerequisites

You need to have Java 8 and Maven installed. You can confirm it is working by running :

mvn clean install

You should maven attempt to run the project and fail because the tests do not pass. Implementing these tests and thus Chip8 is part of th exercise.

Code overview

Our tests are in the test directory. They are grouped into logical categories to to work through. Feel free to add more tests if you don't feel comfortable with your code or want to see more how it works.

There are a few helper classes for outputting audio, loading roms, displaying graphics, and handling input.

Finally, the Chip8 class has a few parameters initialized but is otherwise empty. This is the class file you will implement.

Let's Code

The project is broken up into eight sections :

Additionally you may want to review other documents on CHIP8 from the web. My reference for writing this project was Mastering CHIP-8 by Matthew Mikolay and the CHIP-8 Wikipedia article.

Exec

When you are finished you can run Chip8 in a Swing window

mvn exec:java  -Dexec.mainClass="net.saga.console.chip8.SwingMain"

Find some roms online and run them in your emulator.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages