⚔️ Joust · Admin & Dev Reference

Prototype firmware v2 on M5Stack ATOM Matrix. This is the field cheat-sheet plus the build/tuning notes.

Running a round

Button gesture grammar (single button)

GestureWhoAction
Tap ×1playerStatus blink (safe no-op)
Hold 1.2s (in OUT)playerAcknowledge, then start next round
Hold 1.2s (while strobing)playerAcknowledge elimination (only after 1s of forced strobe)
Tap ×2, then hold 10sadminMark THIS unit OUT mid-round. No LED feedback during the hold, so players can't discover it.

Live tuning (dashboard or serial)

Open the live dashboard (the deployed React console at joust.nyc, or run bun dev and open localhost:3000) in desktop Chrome/Edge, click Connect, pick the USB serial port. Watch movement, threshold, and the meter live; drag the sliders to tune. Or type these over any serial monitor at 115200:
CmdEffect
fInject a synthetic strike (tests the real detector)
aArm now (skip grace)
rReset round
kAcknowledge elimination
oMark this unit out
tRun the built-in self-test (still safe / moving / knock / drop)
S2.0Set movement threshold to 2.0g
J0Set jerk gate (0 = off, any movement counts)
E1 / E0Enable / disable escalation

How elimination is detected

It's a keep-still game: a player is out when the controller's dynamic movement hitPk ≥ threshold (default ~2g). Any real acceleration counts (a jostle, flinch, walk, or drop), plus a free-fall branch so a drop always registers. Gravity is tracked and subtracted, so holding at any angle is fine as long as you hold still. The jerk gate is OFF by default; enable it only if you want to require a sharp jolt and ignore slow pushes.
More sensitive: lower the threshold Ignore slow pushes: raise the jerk gate ±16g sensor, 500Hz

Config defaults (game_config.h)

KnobDefaultMeaning
movement threshold2.0 gHow much movement gets you out (main knob)
jerk gate0 (off)Require a sharp jolt; off = any movement counts
escalationoffOptional: threshold ramps down over time
free-fall0.4 g / 60 msA drop eliminates even before impact
grace5 sNo detection at round start
ack hold1.2 sHold to acknowledge / reset
strobe minimum1.0 sForced strobe before ack honored
LED brightness cap20/255Heat and battery current

Tune these on real bodies at your chosen mount point before the bulk order. They are all in one file.

Hardware & bulk buy

Before buying 20–30 units: the current ATOM Matrix v1.1 ships a Bosch BMI270 IMU, while this prototype has the older MPU6886. The firmware fully drives MPU6886 and cleanly shows an amber X (never a fake hit) on a BMI270. Add BMI270 support and re-tune thresholds on one v1.1 unit first.
Recommended controller (~$23/unit): Waterproofing (none are IP-rated): clear silicone/TPU pouch or a small clear dome over the LED face, plus conformal coating on the board and a sealed USB port. Bench-test dry first.
Runtime: 200mAh base ≈ 2–3h; a 2000mAh USB-C bank on an armband ≈ all day.

Roadmap (deferred, not in this prototype)

One firmware, one board file to port. Full source and the live dashboard ship alongside this page.