XIAO SAMD21G18 - upload hex without Arduino IDE

Hello, I’m new with two XIAO SAMD21G18 boards.

I created a small program that displays some parameters (CPU load, CPU temp, free&used memory) on SSH1106 OLED display.

I plan to use XIAO boards in small computer cases. Uploading via the Arduino IDE runs smoothly.

How can my customer upload in future new version of hex file to XIAO SAMD21 without Arduino IDE? I’ve ST Link v2. It’s possible to program without the arduino IDE?

Wiki-related content indicates that it is possible to upload programs via Jlink, not quite sure if STLink is feasible.

If you have multiple Xiao SAMD boards, you can use one as SWD debugger to reflash the bricked ones. The software is OpenOCD.

Follow the full procedure from The $5 programmer-debugger