Skip to content

MD/JS: JavaScript Worker for Atari ST

Latest

Choose a tag to compare

@neilrackett neilrackett released this 20 Nov 12:13

Microfirmware for the SidecarTridge Multi-device by Neil Rackett

Introduction

MD/JS turns your SidecarT into a persistent JavaScript Worker for the Atari ST, enabling you to:

  • Upload JavaScript source from your ST
  • Call named functions with JSON arguments
  • Use ES5.1, ES6/2015 and most ES2020 features
  • Load text or JSON files using fetch()
  • Read JSON results

What's new in v1.1.1

  • MD/JS answers your ST as soon as it boots: the worker now starts before WiFi connects. A slow WiFi connection used to make the ST report "JavaScript Worker not detected" at boot (seen on an Atari TT).
  • fetch() no longer stalls until it times out on a response bigger than about 5.8 KB.
  • fetch() gives the server's status and statusText, and ok is true only for a 2xx status, as in a browser. A 404 used to come back as ok: true, status: 200.
  • fetch() no longer cuts a path longer than 127 characters short.
  • DHCP leases are renewed while MD/JS is running.
  • MD/JS runs in Hatari on your computer with EmuMD, WiFi included.

The demo apps and example JS files are unchanged from v1.1.0. See the changelog for the full list.

Examples

Want to see MD/JS in action? Simply install the microfirmware, open the cartridge icon on your ST's desktop (lower case c drive) and run MDJSDEMO.PRG.

Plus, we've made 2 great demo apps for you to try:

MD/JS Code

A simple IDE you can use to create, edit and run JavaScript on your Atari ST!

mdjs-code

Pong Battle: ST vs JS

A self-playing Pong demo that pits your ST against MD/JS on your SidecarT!

STJSPONG

Installation

🎉 MD/JS is now available in the official SidecarTridge Multi-device catalogue! 🎉

  1. Install MD/JS using your SidecarT's web interface.
  2. Download MDJSCODE.PRG and STJSPONG.TOS demo apps and example JS files below and save them to a floppy or hard disk.
  3. Enjoy!

Manual installation

  1. Download the files below.
  2. Copy the .uf2 and .json files to the /apps folder of your SidecarT's microSD card.
  3. On the Booster screen, press ESC for the app list and select the MD/JS app.
  4. To return to Booster, turn on your ST while holding the SELECT button on your SidecarT.

You'll know if the microfirmware is working because you'll see "MD/JS: JavaScript Worker is ready" on your ST's screen as it boots.