morebyt

How computers really work

I build emulators, operating systems and compilers from scratch in C++, and film every step. Follow one build and you'll know what your own code is doing underneath.

Mohammad Reza Bayat

Mohammad Reza Bayat
C++ engineer. I make Morebyt.

Line drawing of a CHIP-8 computer Front view of a small 1970s computer: a monitor showing a game of Pong on a 64 by 32 pixel screen, sitting on a base with a 16-key hexadecimal keypad. 123C456D789EA0BF 64 px 32 px CPU + 4 KB memory 16 keys, 0 to F
Fig. 1: a CHIP-8 computer, front view. We build one in C++ in the series below.

Build a CHIP-8 emulator in C++

A whole computer in about 1,000 lines: memory, a CPU, a screen and a keyboard. Each episode adds one part and answers one question.

  1. Episode 1How do zeros and ones actually run a program?
  2. Episode 2How does computer memory actually work?
  3. Episode 3How did old games draw pixels? The XOR trick
  4. Episode 4How does a computer read keys, keep time and roll dice?
  5. Episode 5How does a CPU actually work? Fetch, decode, execute

The full playlist on YouTube. Everything else I build is on the projects page.

What we build next

One machine at a time, from the bottom up. Each build is a series you can follow from an empty folder.

No.BuildStatusWhen
01CHIP-8 emulatorFilming nowNov 2026
02A tiny operating system that bootsNextFrom Feb 2027
03Your own memory allocator (malloc)PlannedJul 2027
04A small compilerPlannedAug 2027

Learning C++ for a job?

The C++ Roadmap 2027: what to learn in order, what to skip, and where the jobs really are. Read it on the site, or get the one-page checklist by email.

Read the roadmap

Need help with C++?

I review C++ code, track down slow or crashing programs, mentor learners and run workshops for teams.

See how I can help