Experiments

Five things built to find out whether they could be. None is for sale, and each one says where the real engineering stops.

Can a 6502 be proven right, cycle by cycle?

6502Live

A cycle-accurate 6502 and 65C02 core in C#, and the machines built on it, each running in the browser and each checked by an automated test. The KIM-1 is first, then the BBC Micro and the NES. The journey is written up as it happens.

An illustration of the 6502 chip, not a photograph: a black 40-pin package marked 6502 with gold pins, hovering in a dark field of glowing green circuit traces, translucent geometric shards and drifting binary digits

Built with - 6502

  • C# on .NET 10
  • .NET compiled to WebAssembly ahead of time
  • Astro
  • Cloudflare Pages
  • Terraform
  • GitHub Actions

Inspect - 6502

  • Checked against Tom Harte's SingleStepTests, a record of every opcode's bus activity, so a failure names the cycle and the byte
  • Five variants in one core: the NMOS 6502, the NES's 2A03 and three 65C02s
  • The KIM-1 runs MOS Technology's original monitor ROM, checked by hash each time it is read, and a test types the User Manual's first program in on the keypad
  • Every figure on its status page comes from test output or a dated measurement, never typed by hand

LimitOnly the KIM-1 runs so far; the BBC Micro and the NES are planned, not built. Where the core knowingly differs from a reference, that is written down rather than hidden. The KIM-1's ROM is MOS Technology's, kept with its provenance because no licence from any holder was found.

Run the KIM-1 (external site)Source on GitHub (external site)

Can two machines still talk over sound?

modemLive

An acoustic modem simulator. Run it on two machines and they open a real Bell 103 connection over their sound cards, after a faithfully performed dial-up overture.

The modem.dbhq.uk hero: the word modem in glowing green over a dense green audio waveform, with the line "Hear the dial-up sound, live"

Built with - modem

  • Rust, no_std core
  • One crate, a terminal binary and a browser AudioWorklet
  • Cloudflare Pages and Workers KV
  • Terraform

Inspect - modem

  • The overture at real timings: 350 and 450 Hz dial tone, DTMF, double-ring ringback, and 2100 Hz ANSam with phase reversals every 450 ms
  • Bell 103 FSK at 300 baud carrying real bytes - 1270/1070 Hz originate, 2225/2025 Hz answer
  • Cross-validated against minimodem, so the waveform is checked rather than just heard
  • A status bar that shows DEMO MODE whenever the link is wired rather than acoustic

LimitThe screech everyone remembers is a 33.6k V.34 handshake, and this is not that. The overture is performed, the training after it is an impression because there is no channel to negotiate, and everything after CONNECT 300 is real.

Hear a call connect (external site)Source on GitHub (external site)

What does the web look like as a bulletin board?

bbsLive

Type a URL and it comes back as a 1992 board: numbered menus, ANSI colour, CP437, pictures redrawn as block art. The page is taken apart into a semantic model and rebuilt in 80 columns by 25 rows, because that is all a board had.

The bbs main menu as a 1992 bulletin board: numbered conferences for Hacker News, Wikipedia, BBC News and GitHub with story counts, a doors list, and a status panel showing time left and calls today, all in cyan and yellow on black

Built with - bbs

  • Rust compiled to WebAssembly
  • TypeScript, on a canvas
  • Cloudflare Pages
  • A Pages Function that relays bytes only

Inspect - bbs

  • A semantic model derived from the HTML the server sent, not from the layout
  • Navigation furniture, cookie banners and boilerplate thrown away rather than styled
  • Live conferences reading Hacker News, Wikipedia and GitHub
  • The relay never returns a screen - every glyph is decided in the core

LimitIt reproduces a board, not a page, so it is judged on being singular rather than on repeat value. An experiment, not a business.

Open the board (external site)Source on GitHub (external site)

Can a 1988 game's own rules be read back out of the disk?

rockfordLive

A C# reimplementation of Rockford: The Arcade Game, the 1988 MS-DOS Boulder Dash spin-off, reverse engineered from the original floppies. A port of the original's own simulation rather than a game that plays roughly like it: every rule cites the instruction it came from. The picture is the enhanced presentation's welcome screen, drawn from scratch rather than taken from the game.

The welcome screen of the enhanced presentation: a cheerful cartoon miner in a red-and-white striped top standing at the mouth of a cave, the word ROCKFORD carved into the rock above him with a VIP badge beside it, boulders and blue gems either side and a sunset behind

Built with - rockford

  • C# on .NET 10
  • Blazor WebAssembly, and a terminal front end
  • Python for the extractors
  • Cloudflare Pages

Inspect - rockford

  • A FAT12 extractor that reads the disk images without mtools or a loop mount, so the analysis is reproducible
  • The scan the original runs - 22 rows of 40 cells, dispatching on a cell byte through the executable's own handler table
  • Ten simulation steps a second, because the original waits six ticks of a 60 Hz interrupt
  • Every claim marked confirmed, inferred or unknown, with the unknowns listed rather than guessed at

Limit"Matches" here means matches the disassembly as read, not verified against a running game - there is no recorded differential replay yet. What is published is the research: both playable builds sit behind a password, and the repository stays private, because either would distribute the original's sprites and cave data.

Rockford and Boulder Dash are registered trademarks of BBG Entertainment GmbH, which holds the intellectual property today. This is an unofficial, non-commercial technical study, not affiliated with or endorsed by BBG Entertainment or First Star Software, and it distributes no game data.

Read the teardown (external site)

What can that USB-C cable actually do?

portmarkLive

USB-C connectors are identical and their capabilities are not. Windows negotiates all of it on every connection and then shows you almost none of it, so portmark reads it back out.

$ portmark --human

Adapter 0x343C:0x0000
  DisplayPort Alternate Mode: entered successfully
  Video        yes, DisplayPort is active through this adapter

Port 1
  Downstream facing port, over USB Power Delivery, drawing power,
  supply offers up to 65W, drawing 5V at 3A (15W).
  Negotiated   5V at 3A (15W)
  Supply offers
    - 5V at 3A (15W)
    - 20V at 3.25A (65W)

Built with - portmark

  • C# on .NET 10
  • One self-contained win-x64 executable
  • A console tool and a WPF tray app
  • Windows UCSI
  • GitHub Actions

Inspect - portmark

  • The negotiated Power Delivery contract, DisplayPort Alternate Mode and e-marker cable data
  • JSON with the raw bytes included, so you can redo the decoding yourself
  • Decoders tested against byte vectors captured from real hardware, so the suite passes with nothing plugged in

LimitNothing is ever inferred from the shape of a connector. Where your PC's controller does not report something, it says so and says why - "this PC's controller does not report cable information" rather than "this cable has no e-marker". It costs the tool some confident-sounding output, and that is the point.

Read your own ports (external site)Source on GitHub (external site)

How DBHQ builds the serious thingsWant a finding about your own estate?

Got something harder than this?

These were built to answer a question. If you have one that matters commercially, bring the workload and the constraints and DBHQ can scope the work around them.

I reply within 24 hours