← Back to blog
LearningOct 2026 · 2 min read

Our arcade machine, now in the browser too

Janis Arnold
Janis Arnold
Developer
Our arcade machine, now in the browser too

Since the school project ended, our mini arcade machine just sits in a cupboard, and the only person who can play it is whoever has it at the moment. I wanted you to be able to try it here too. Not as a remake, but with exactly the code that runs on the real device.

Mini ArcadeTry it yourselfThe machine's original code runs live in your browser, with joystick, buttons and sound. Play
Play

The real code instead of a remake

Rewriting Snake and Space Invaders in JavaScript would have been easier. But then it wouldn't be our machine anymore, just a browser remake.

Luckily there's MicroPython for WebAssembly, the same interpreter as on the Raspberry Pi Pico, just for the browser. With it, the menu, the games and the settings run right in your browser.

The browser runs the same code as the machine. Only the hardware is replaced.

What had to be replaced

All that's missing is the hardware. Buttons and sound go through a small machine module of my own: the website reports which buttons are pressed and gets the audio data back. I rebuilt the C module that drives the LEDs on the Pico in Python. The website reads the finished frame straight from memory and draws it as an LED panel on a canvas.

The biggest problem was a single line: while True:. On the Pico the main loop runs forever, and in the browser that would freeze the page. With a generator, the loop now pauses briefly after every pass, and the browser nudges it on with every frame. On the Pico nothing changes.

High scores and settings are saved in your browser, so they're still there after a reload.

Fast, even on a phone

The whole arcade part is just under 1 MB and only loads once someone presses "Play". The rest of the website doesn't notice any of it.

The cabinet was made in Claude Design, modelled on our real plywood one, and I built everything with Claude Code. On a phone you play with your fingers, on a computer with the keyboard or in fullscreen. And the code only exists once: the arcade repository is included in the website as a Git submodule.

What I like most is that it really is our machine running here. With the same menus, the same games and the same little quirks.

  • MicroPython
  • WebAssembly
  • Nuxt
  • Vue
  • Canvas
  • Web Audio
  • Claude Design
  • Claude Code