Skip to content

Latest commit

 

History

History
47 lines (31 loc) · 996 Bytes

File metadata and controls

47 lines (31 loc) · 996 Bytes

CHIP-8 Emulator

This is a good first project for learning low-level system architecture and graphics. This CHIP-8 emulator is written in C++ using the SDL2 library to handle the screen.

Emulator Screenshot Emulator Screenshot

This project simulates the CHIP-8 system. It acts like a very old computer that can run simple games like Pong, Tetris, and Space Invaders.

Building this, I learned basics of:

  • Fetch-Decode-Execute Cycle
  • Memory Management
  • Graphics Rendering
  • Bitwise Operations inside a system

Controls

The original CHIP-8 had a weird keypad. I mapped it to the left side of the keyboard:

| 1 2 3 4 | | Q W E R | | A S D F | | Z X C V |

How to Run

For Ubuntu linux,

  1. Install SDL2 using following command
    sudo apt-get install libsdl2-dev
  1. Compile the code
    g++ main.cpp -o chip8 -lSDL2
  1. Run the game(or any other ROM file of your choice)
  ./chip8 30 10 roms/Brix.ch8