Skip to content
gunkslab

Guides

Run and add bench programs

Build a bench program, flash it onto a board and watch its output, and add a new one. What each program does is in the reference.

Build

With nothing installed but a container runtime, from the repo’s top folder:

scripts/bench build      # every program
scripts/bench list       # what's here

The same pinned toolchain as the firmware (espressif32 6.5.0, Arduino core 2.0.14), in the same container image.

Flash and watch

A container can’t reach the USB port, so this needs PlatformIO on this machine, as for flashing the firmware, installed as Install says for your OS. Plug the board in, then from bench/:

pio run -e ps-pwm -t upload      # build + flash
pio device monitor               # its output, 115200 baud; Ctrl-C to stop

The firmware README’s notes on a missing port and an upload stuck at “Connecting…” hold here too.

Add one

  1. A folder under src/ with a main.cpp, its header comment saying what it tests, how it’s wired, and what it prints.
  2. An [env:<name>] in platformio.ini: extends = bench and build_src_filter = +<name/>, and its own lib_deps at exact versions if it needs a library.
  3. A row in the table in docs/reference/bench.md.