STM32 AutoDebug Universal Kit CLI

A closed loop for STM32: the agent builds in Keil, flashes the board, reads serial output and finds the crashing line.

  • 61 ★ on the repository
  • Last commit
  • MIT
CLI

Broad access

Why this level

  • The kit flashes a real board over SWD and runs Keil builds, and a faulty firmware can damage the connected hardware.
All reasons and checks

taocosmo-dev/stm32_autodebug_universal_kit

Install

Manual install

git clone https://github.com/TaoCosmo-Dev/STM32_AutoDebug_Universal_Kit.git

The first step of the README install section; then `setup_env.bat` is run.

Access and checks

How we review

Broad accessThe tool can change data, run commands or handle secrets.

  • The kit flashes a real board over SWD and runs Keil builds, and a faulty firmware can damage the connected hardware.

This is third-party code. Review the repository files before installing.

What it does

The command set gives an AI agent feedback while developing for STM32. It runs the Keil UV4 build from the command line and parses the log down to file and line, flashes the board over SWD, reads a pass token from the serial port and, after a hardware fault, finds the source line from fault registers. Firmware counts as passing when the build has 0 errors, flashing succeeded and the port printed the success token. The `setup_env` wizard installs dependencies and copies the skill into the Claude Code, Cursor, Codex CLI and Gemini CLI directories. A failure fingerprint shows whether the previous edit worked, and when fixing stalls the engine stops and calls a human.

Who it is for. Embedded developers on STM32 and Keil tired of building, flashing and relaying results to the agent by hand.

Good fit when

  • The agent writes a DHT11 sensor driver and the build must return errors with file and line.
  • The board falls into HardFault and the cause has to be traced from registers to a code line.
  • You must confirm the code actually runs on the chip rather than merely builds.
  • A Keil project is edited by the agent: adding a source, include paths and macros without launching uVision.

Not a fit when

  • The project uses IAR, CMake/GCC or PlatformIO: only Keil is supported.
  • Work on macOS or Linux is needed: only Windows is supported.
  • No ST-Link, DAP-Link or CMSIS-DAP debugger is available: without it the board cannot be flashed or a fault read.

Example request

I need to read DHT11 temperature, print it to the serial port and blink the LED once a second. Build, flash and verify on the board.

Limitations

Windows, Keil MDK5, Python 3.10 or newer, a debugger with SWD and an already building Keil project are required: the kit creates no new projects (since 2.3.0). A USB-UART is advisable, otherwise token-based verification is unavailable. Chip support packs of 10 to 60 MB download at the first flash, and dependencies install from the Tsinghua mirror. The documentation is in Chinese. Firmware must print the success token over the port or the verdict is incomplete. An MCP server with 10 tools is optional.

How to disable. Delete the kit directory and the skill from `~/.agents/skills` and `~/.claude/skills`. If you injected it into a project, remove `run_autodebug.py`, the `autodebug` directory and `autodebug.config.yaml` from the project.

FAQ

How do I install the kit?

Run `git clone https://github.com/TaoCosmo-Dev/STM32_AutoDebug_Universal_Kit.git`, then double-click `setup_env.bat`. The wizard installs dependencies and the agent skill.

How do I know it is ready?

The self-check prints the Keil UV4 path, the detected debugger and the port. A `NOT FOUND` line, an empty debugger or port means something is missing.

Do I need to edit configs?

No. The Keil path, debugger type and port number are detected automatically, and an unavailable configured path is replaced by the detected one.

Can I skip MCP?

Yes. The command line works by default, while `mcp_server.py` with 10 tools is optional.

What counts as success?

Three conditions at once: a build without errors, completed flashing and the success token on the port.

Discussion

No questions or reviews yet.

CLI tools

auto-embedded gives firmware projects five stages, a pin and DMA lock and a task log so the agent stops guessing.

CLIBroad access262Repository stars

24 skills for microcontroller firmware: build, flash, GDB debugging, UART, Modbus, CAN, logic analyzers and static analysis

SkillBroad access1.1KRepository stars

ESP32 Workbench gives an agent 11 skills and 13 MCP tools for ESP32 firmware: pins, panics, build logs, partitions.

PluginExtended access82Repository stars

Claude Code skills and a Raspberry Pi testbench: the agent writes ESP32 firmware, flashes the board and tests it on hardware

SkillBroad access286Repository stars

A debugger with no IDE: an agent sets breakpoints, steps through code and inspects variables in ten languages

MCP serverBroad access188Repository stars

LabWired Core runs firmware on a virtual copy of a real chip and gives an agent UART and GPIO traces plus an exit code.

CLIExtended access189Repository stars

README in short

The documentation describes the split of work: a human supplies hardware parameters and wiring, the agent writes code and runs the loop, and the kit turns each step into a command with an exit code.

README badge

Report a problem