A terminal port of Street Racer (Atari 2600, 1977) — original by Larry Kaplan. Runs entirely in your Linux terminal. No GUI. No dependencies beyond a C compiler and
aplay.
Street Racer was one of the Atari 2600 launch titles. You drive a car up a single lane, dodging oncoming traffic. Hold fire to accelerate. Don't crash.
This port runs in a standard Linux terminal using ANSI true-colour escape codes and raw terminal input. The sprite data, crash sprite, and speed accumulator algorithm were all reverse-engineered directly from the original 2600 ROM — the same bytes that ran on the hardware in 1977 are rendering your car today.
- Linux
- Terminal with true-colour support (most modern terminal emulators: Alacritty, Kitty, GNOME Terminal, iTerm2 etc.)
- Terminal window of at least 160 × 48 characters
aplayfor sound — part ofalsa-utils, usually already installed:Sound is optional — the game runs silently ifsudo apt install alsa-utils # Debian/Ubuntu sudo pacman -S alsa-utils # Archaplayis absent.
gcc -O2 -o strtrcr strtrcr.c
./strtrcrNo Makefile, no CMake, no dependencies. One file, one command.
| Key | Action |
|---|---|
← → |
Steer |
f or Space |
Accelerate |
q |
Quit |
Hold accelerate to build speed. Release to decelerate. The speed curve is taken directly from the original 6502 assembly — same accumulator, same right-shift formula, just scaled for a modern frame rate.
The port started with a full disassembly of the 2600 ROM (Street_Racer_NA.a26, 2048 bytes). Key findings:
- Sprites — the car graphics live in a table at ROM address
$F79A. Eight variants, one per game mode. The player car, crash car, and enemy car are all drawn directly from that table. - Crash sprite — sprite variant 6 from the table: rear wheels intact (
$C3), front destroyed asymmetrically. Physically accurate — the front takes the hit. - Speed algorithm — zero-page variable
$9E,Xaccumulates ±1 per frame (±SPEED_STEPscaled for 15fps). Per-frame movement delta =max(1, speed >> 4), giving 1–7 rows per frame. Same formula as the original 6502 code at$FC7B(fourLSRinstructions). - Rendering — ANSI true-colour background blocks (
\033[48;2;R;G;Bm), one terminal cell = one sprite pixel × 2 character widths. - Sound — raw 8-bit PCM piped to
aplay. Engine: 25%-duty square wave, pitch 40–280 Hz proportional tospeed_acc. Crash: white noise burst. Score: 880 Hz chirp.
- Single-player only (original supports up to 4 via driving controllers)
- Keyboard input instead of driving controllers
- One enemy car on screen
- No game variation selection (difficulty, game modes)
- Approximate sound (TIA chip emulation would require far more)
Port: hyprc0w (2026) Original game: Larry Kaplan, Atari, 1977
If you enjoyed this, you can buy me a coffee.
