6502 by dbhqGitHub

· All entries

The Atari VCS's page, its photographs, its registry row and the count

Task 14 of the Atari 2600 plan, done on 15 October 2026, after main was merged in and task 13’s review was folded in, both recorded in the task 13 entry. The entry is dated 14 October with the rest of the build. New: the photographs site/src/assets/photos/atari-2600.webp and atari-2600-four-switch.webp; site/src/lib/atari-2600.mjs; the tests site/tests/atari-2600.test.mjs, atari-2600-page.test.mjs and browser-check-atari-2600.test.mjs; the browser check site/scripts/browser-check-atari-2600.mjs; the fault probe tools/probes/atari-2600/page-faults.py. Changed: the registry’s atari-2600 row, the page template, machines.mjs (the build and the try-it check), pins.mjs (atari2600Roms()), the browser check’s driver, both workflows, the photographs’ README, the site’s README and DESIGN, the root README, docs/the-6502-family.md, the about page, AGENTS.md’s layout, two existing site tests, the test floor, and the game folder’s README, whose “is to run it on Start” is now “runs it”.

Step 7 of the task, marking the pull request ready, was not done: task 15 remains, and the controller decides when the pull request is ready.

The registry row

Field for field as the NES’s, with the values the plan gives: maker Atari, core nmos, status running, acceptance Atari2600AcceptanceTests, case true, and no models field (issue 129), so the registry’s rule that a cased machine claiming a model claims both views never stops it counting. cpu is “6507 at 1.19 MHz (NTSC), 1.18 MHz (PAL)”; atari-2600.test.mjs works both clocks out from Region.cs (ColourClockHz / 3) and checks the field against them, so the figures are not typed.

  • rights says what the spec’s rights pass found and the game’s folder records, and no more: no system ROM; commercial games load-your-own and never uploaded; the game, its author, the port of Gabriele Cirulli’s 2048, the MIT licence with both copyright lines quoted; our copy the author’s own build, unchanged, with its address, its commit and its SHA-256; the cartridge art not in the ROM and not shown; and where it is kept. The test checks each fact against the folder’s README and manifest, NOTICE.md and the pins.
  • notes names what is modelled and what is not. It names the boards without a count: a typed “nine” would be a figure (rule 5). The test reads the boards from Cartridge.cs’s table and checks the notes name each.
  • photos, below.

The registry row is the count: the home page’s “N of M” and its sentence on which machines run are computed from the registry, as before. The page test checks the count is one more than with the Atari 2600 not running, and that the home page’s template types no count.

One existing test changed for the name. figures-on-pages.test.mjs allows on the home page only numbers that come from the data. The running sentence now says “Atari 2600”, whose digits the test flagged. The name comes from the registry like the year and the clock, so the test now allows the numbers in a machine’s name as it allows those in its year, clock and notes; chosen over renaming the machine on the home page, which would make the sentence disagree with the registry. Task 14’s review found that this allowed the numbers in every machine’s name, so a typed number that happens to be in the name of a machine that does not run, such as the Atari 7800’s, would have passed. The test now allows the numbers in the names of running machines only, and a second test checks that the numbers in the other names stay disallowed. Shown on 15 October 2026 by planting “7800” in the built home page: the old test passed it, the new one fails it. The review proposed planting a typed 64, which cannot show it: on that day 64 was also one suite’s pass count in the results, so it is allowed anyway.

The photographs

The two Evan-Amos photographs the spec names, both from Wikimedia Commons. Each file page was read through the Commons API on 15 October 2026, its imageinfo and extmetadata and the page’s wikitext, before anything was fetched, and the licences are as the spec says: both {{PD-self}}, LicenseShortName “Public domain”, AttributionRequired false. The originals were fetched by hand into a new empty directory outside the repository; each one’s SHA-1 is the one Commons records. Both were opened and looked at, resized, and looked at again: each shows the console it is said to, on white, and nothing odd.

FileWhat it showsWhy
atari-2600.webp, from Atari-2600-Light-Sixer-FL.jpg, taken 22 November 2014The six-switch console from the front left: power, tv type, both difficulty switches, game select and game reset on the front panel, no joystickThe main photograph, in the page’s head: it shows every switch the panel has, the difficulty switches included
atari-2600-four-switch.webp, from Atari-2600-Wood-4Sw-Set.jpg, taken 28 February 2011The later four-switch wood veneer console of 1980 to 1982, as the file page dates it, with its standard joystickThe second, in the photographs section: it shows the joystick the page’s controls stand in for

One finding against the spec. The spec’s photograph line calls the first “the 1977 six-switch console”. The file page says the console is the “Light Sixer”, “the second 2600 model that featured six front switches”, so it is the later six-switch model, not the first of 1977. The caption says what the file page says; the spec, a record of 14 October, was not edited.

The files’ histories. The Light Sixer file’s first version, of 1 March 2012, was a different photograph under CC BY-SA 3.0; the current one replaced it on 22 November 2014 under {{PD-self}}, and is the one used. The four-switch file has five versions, all the photographer’s; the current one is of 16 February 2015.

The first caption, corrected in task 14’s review. It said the Light Sixer has six switches “on its front”, while the photographs’ README describes the panel raised at the back of the case; the caption and the README now both say “front panel”, the console’s own name for that panel.

Resized as the Electron’s was. cwebp is not on this box, so both were made with sharp 0.35.5 from site/node_modules, at the other photographs’ settings: 1600 pixels wide, WebP quality 82, no metadata. Neither was cropped. The four-switch original carries an Adobe RGB profile, which sharp converts to sRGB, as for electron.webp. Every figure, size and hash is in site/src/assets/photos/README.md, whose hash of each copy the registry test checks. used says nothing is traced or measured from either, as the Atari 2600 has no model yet.

One slip, recorded. The first request to the Commons API carried a contact email address in its User-Agent header, which should not have been sent; the requests after it carried the repository’s address instead.

The page

The panel task 13 built, mounted by src/pages/machines/[id].astro for atari-2600, with the bundled game and the download size read from the build. Around it, in the NES’s shape:

  • The run section says what the two regions are, that the machine starts as NTSC because a cartridge cannot say, that the page never changes the region by itself, that a change is at once with no restart, and that the TIA is run a colour clock at a time and needs a fast computer, linking the speed pass (issue 130). No speed is typed: the headroom line is the only one, and the page test fails on any typed multiple or rate.
  • How it is checked, a section the NES’s page does not have, because the plan asks the page to say that a trusted result is the behaviour of the one console the suite was checked on. It says which of the suite’s tests must pass and which are recorded, that a recorded test’s change fails the build, that the bundled game’s picture is checked pixel for pixel, that the suite was checked on one PAL console from Australia and the TIA varies between chips and models, that the suite’s photographs of that console’s screen are not compared yet (issue 162), and links the known differences. The page test checks the sentence and checks that docs/known-differences.md still records the one console.
  • Try it renders try-it.json: the steps, the controls with their keys from the page’s own key map, and the game’s credit with its licence linked. loadTryIt did not know atari-2600 and would have read its steps as the KIM-1’s keys (task 12’s journal); it now checks the file in the NES’s way, the controls against the console’s (ATARI_2600_CONTROLS), the licence’s address, and the game against its pin and hash.
  • What is not modelled: the parts the plan’s Global Constraints name, each with its issue (106, 108, 124 to 128 and 107), then the boards not modelled, one issue each (131 to 155), and the 3D models (129).
  • Whose game this is: the registry’s rights in full, the copy in the repository with its SHA-256, and the game’s folder and its licence linked.

The controls table reuses the NES’s .nes-pad-table class for its caption, the same markup for the same kind of table, rather than adding a rule the design test would also have to place.

The browser check

browser-check-atari-2600.mjs, called from browser-check.mjs after the Electron’s, in the NES’s shape. What it checks is in its header and in site/README.md. The decisions:

  • The recorded frame is reached through the page. For each region the check sets the region with the page’s radios and the colour switch with the page’s own button to the position expected-frames.json records for that region, then calls panel.vcs.stepTo(n) with that file’s count (task 13’s hook: let go of every input, keep the switches that stay, power off and on, run exactly n frames, paint). The canvas is cleared first, so a hook that does not paint fails. The expected hashes, counts and switches are read from the file, never copied.
  • The region switch is checked without a restart and for its colours. With the loop held, the radios go to PAL: the frame count must not move and the line must say there was no restart. Then the same frame count is run on PAL with NTSC’s switches: since the two regions differ only in the colours and the clock, it must be the same picture in PAL’s colours. On the rows both windows show, matched from each window’s first line, every colour must map to exactly one colour in the other, the same at every pixel, and at least one must change. Chosen over comparing two canvases for being different, which a restart or a wrong picture would also pass.
  • Playing through the page is judged against what the picture does by itself, because the title changes its colours every frame: fire (Space) must change far more pixels than the title does by itself in the same time, and joystick 1, on the game’s board, more than twice what the board does by itself; Reset must change it at all. The joystick goes left and then right, because a lone tile against an edge does not move one way (below). Reset is held on the panel’s button with the mouse, so the held-button path is the one used.
  • The test cartridge comes from the suite’s fork: harness/calibration_ntsc.a26 from dbhq-uk/missingno at the pinned commit, checked against the git blob hash in the pinned manifest, as Atari2600Suite.Read and the speed bench check theirs. It is kept in .testdata/ and never committed or published (rule 3).

Chrome is on this box after all, as Chrome for Testing. The brief said no Chrome is installed, and none is at /usr/bin/google-chrome, but Playwright’s own download of Chrome for Testing 153 for arm64 is in the user’s cache. With CHROME_PATH pointing at it, the Atari 2600’s section was run here alone (a scratch driver outside the repository that serves dist/ with the site’s headers, as browser-check.mjs does), on a build of the machine without AOT, on 15 October 2026, and passed: both regions’ recorded frames matched on the canvas, the switched region gave the same picture with its colours changed, fire, the joystick and Reset each changed the picture, the test cartridge went in and the two bad files were refused. Its first run failed one check, Reset, because the button was off the screen when the mouse pressed it; the check now scrolls to it first. The whole browser check, with every machine, runs only in CI, where the machines are built ahead of time. The speed the box gave is not recorded: no speed figure is taken from this box.

CI and the count

Both workflows gain the Atari 2600’s browser build: its own cache, keyed as the NES’s on its two projects, the core, Directory.Build.props, Pins.cs, the build script and the two libraries it reads, and machines/atari-2600/cartridges/, because the build publishes the game; atari-2600 in the step that names the machines to build; and npm run machines builds it too. The deploy’s check of served scripts already had the page’s two scripts (task 13’s review). The deploy’s floor of machine files rises from 40 to 49: the Atari 2600’s four runtime files, CoreLib, the core, the machine and its host, and its game; its build here gave 11 files.

The test floor. Measured on the development box on 15 October 2026 with cd site && npm test: 710 tests and one to-do, 699 passing and 10 failing only because this box does not build the other machines’ WebAssembly. So 709 for CI, which site/tests/floor.json now holds. Validate’s site step on the task’s commit, 819e657 (run 38701695283, 15 October 2026), counted pass=709 fail=0, which confirms it. Task 14’s review then added one test to figures-on-pages.test.mjs (above): measured the same way on 15 October 2026, 711 tests and one to-do, 700 passing and the same 10 failing for the same reason, so 710 for CI, which the floor now holds.

What the machine adds to CI, read from the same run’s logs, run 38701695283 on 819e657. That run failed at its end, on the browser check’s joystick check (below); the timings are of the parts it finished. Its ahead-of-time build, when its cache misses, took 66 seconds (07:57:50 to 07:58:56 in the machines job, which on this commit rebuilt every machine, because the build’s own library changed and is in every machine’s key); it published ten framework files and the game, 7,220,250 bytes of framework. When nothing it is keyed on changes, the cache restores it instead. Its section of the browser check took about 31 seconds (08:06:41 to 08:07:12), up to the failed check. On the fix’s commit, 01f3bc0, Validate passed (run 38703862104, 15 October 2026), and its Atari 2600 section of the browser check, every check passing, took about 25 seconds (08:19:25 to 08:19:50, from the page opening to the check’s last line, in the site job’s log). Its tests in the test job were already there before this task.

The first CI run of the browser check failed one check, as the brief allowed for. Every other part passed in CI as it had here, the recorded frames to the pixel in both regions among them, but joystick 1 left changed nothing: the new game’s one tile was already against the left edge there, where a move left does nothing, and here it had not been. The run on the box had not shown that a move can do nothing. The check now pushes the joystick left and then right, since one of the two must move a lone tile, and passed here again.

The fault pass

The fault pass ran on 15 October 2026 in a scratch copy outside the repository (python3 -I tools/probes/atari-2600/page-faults.py <scratch>), one fault at a time, building the site and running the tests that read what was broken. R faults are in the registry row, P in the page’s template, L in its library, M in machines.mjs and pins.mjs, D in the photographs’ README, and B in the browser check’s own comparisons.

FaultCaught by
R1 the row claims 3D modelsatari-2600-page.test.mjs (13), atari-2600.test.mjs (2), build.test.mjs (4), registry.test.mjs (1), the site build (1)
R2 the main photograph’s licence is not as Commons states itatari-2600-page.test.mjs (1)
R3 the clock typed, not Region.cs’satari-2600.test.mjs (1)
R4 the rights lose the second copyright lineatari-2600.test.mjs (1)
R5 the row is not runningatari-2600-page.test.mjs (13), atari-2600.test.mjs (1)
R6 the second photograph droppedatari-2600-page.test.mjs (13), atari-2600.test.mjs (1), build.test.mjs (4), registry.test.mjs (3), the site build (1)
P1 the page drops the one-console sentenceatari-2600-page.test.mjs (1)
P2 the credit does not link the licenceatari-2600-page.test.mjs (1)
P3 the game is said to be in roms/atari-2600-page.test.mjs (1)
P4 the boards not modelled are not listedatari-2600-page.test.mjs (1)
P5 the speed issue not linkedatari-2600-page.test.mjs (1), on the second run
P6 the panel is given no gameatari-2600-page.test.mjs (1)
L1 a left-out part’s issue is wrongatari-2600.test.mjs (1)
L2 one board dropped from the listatari-2600.test.mjs (1)
L3 the right fire button is joystick 1’satari-2600.test.mjs (1)
L4 the captures’ issue is not 162atari-2600.test.mjs (1)
M1 the game’s pin is the NES’s hashatari-2600-page.test.mjs (1), atari-2600.test.mjs (1), build.test.mjs (3), the site build (1)
M2 the try-it check takes any controlatari-2600.test.mjs (1)
M3 the try-it check reads no licence addressatari-2600.test.mjs (1)
M4 the machine built from the NES’s projectatari-2600.test.mjs (1), build-machines.test.mjs (1)
D1 the README’s hash of the main photograph’s copy is wrongregistry.test.mjs (1)
B1 the colour map is checked one way onlybrowser-check-atari-2600.test.mjs (1)
B2 the windows’ rows matched from row 0 bothbrowser-check-atari-2600.test.mjs (1)
B3 the test cartridge from another hostbrowser-check-atari-2600.test.mjs (1), mirrors.test.mjs (1)
B4 the test cartridge’s hash not checkedbrowser-check-atari-2600.test.mjs (1)

Every fault was caught. P5’s text was not found on the first run, because the probe named the wrong lines around it; with its text corrected it was run alone (... <scratch> P5) and caught. R1, R6 and M1 also stop the site’s build, so every page test fails with them.

The page’s tests were written after the code, in the author’s order of work; the fault pass is what shows they can fail.

Issues

Issue 129 has a comment: the row has no models field, so the 3D models are free to start after the merge.

Commands

All on 15 October 2026, on the development box, in the worktree:

  • The Commons API for each file, action=query&prop=imageinfo&iiprop=url|size|sha1|mime|extmetadata|timestamp|user|comment, its upload history, and each file page’s wikitext (action=raw); then curl of each original from upload.wikimedia.org into a new empty directory, and sha1sum and sha256sum of each.
  • node resize.cjs <out> <original> atari-2600.webp <original> atari-2600-four-switch.webp, a scratch script outside the repository run from site/, calling sharp as the README gives it.
  • node scripts/build-machines.mjs atari-2600 --interpreter, a local build without AOT, and npm test, as above.
  • CHROME_PATH=<Chrome for Testing> node <scratch driver> site, the Atari 2600’s browser check alone, as above.
  • python3 -I tools/probes/atari-2600/page-faults.py <scratch>, as above.
  • dotnet build -c Release: no warnings. dotnet test -c Release tests/Dbhq.Machines.Atari2600.Tests: every test passed.