Skip to content

bytecod3/6502-CPU-Emulator

Repository files navigation

6502 CPU Emulator

How to build

This project uses CMAKE build tool. Follow the steps below to build: Create a build directory with mkdir build

  1. cd build
  2. cmake .. - to generate necessary build files
  3. make - use the build tool generated by CMAKE to compile the project
  4. ./main - to run the app generated by make

Checking Endianness

If on Linux OS, open terminal and run:
lscpu | grep "Byte Order"

Debugging

You have to build the executable to include -g compile flag to enable debugging with GDB. Use this sequence of commands:

cd build cmake -DCMAKE_BUILD_TYPE=Debug .. make

To debug with GDB: gdb main
(gdb) b 43 - look at the source code and set a breakpoint at line 43 (gdb) run - to run the debugger (gdb) step - to step through the program

About

A basic 6502 CPU emulator

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published