em-debug MCP Server
Provides debugging and inspection capabilities for ARM Cortex-M microcontrollers (M0 through M55), including execution control, memory inspection, live CoreSight AP access, peripheral bringup, and ARMv7-M crash diagnostics via supported hardware probes.
Provides debugging support for RISC-V RV32/RV64 targets through supported hardware probes, enabling unified execution control and memory inspection alongside ARM Cortex-M targets.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@em-debug MCP ServerConnect to my STM32 target and decode why it crashed"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
EM-Debug
Next-Generation Embedded Debugger Suite Built on probe-rs
A unified, zero-toolchain debugging solution: Full-featured VS Code extension for humans + 37 MCP tools for AI agents.
🌟 Highlights
Zero-Toolchain Setup: Powered by an automatic cross-platform
probe-rsbinary resolver (ProbeRsBinaryManager). No external GDB, OpenOCD, Python, or proprietary vendor drivers required.Single-Connection Session Hub: Eliminates the classic USB probe exclusivity conflict (
Device is busy). Human developers in VS Code and AI Agents over MCP share the exact same hardware session.37 Production-Grade MCP Tools: Full suite inherited and upgraded from cortex-debug-mcp, providing execution control, memory inspection, live CoreSight AP access, and firmware-free peripheral bringup.
Intelligent Crash Diagnostics: Native ARMv7-M
capture_faulttool decodesEXC_RETURN, stacked exception frames, and SCB fault status registers (CFSR, HFSR, MMFAR, BFAR) to pinpoint the exact crash source line in milliseconds.Dual-Mode Operation:
Collaborative Mode: Embedded within the VS Code extension host; F5 debug sessions are instantly queryable by connected AI agents.
Headless Mode: Standalone CLI runtime (
npx @em-debug/mcp-server) for automated CI/CD and terminal agents.
Broad Hardware Support: First-class support for ARM Cortex-M (M0 through M55) and RISC-V (RV32/RV64) via J-Link, CMSIS-DAP/DAPLink, ST-Link (v2/v3), FTDI, and ESP32 USB-JTAG.
Related MCP server: dbgprobe-mcp-server
🏗️ Architecture
+-----------------------------------+
| Target Board (MCU) |
| (ARM Cortex-M / RISC-V) |
+-----------------+-----------------+
| SWD / JTAG
+-----------------+-----------------+
| Hardware Probe (J-Link / DAP) |
+-----------------+-----------------+
| USB (Exclusive Owner)
+-----------------+-----------------+
| probe-rs dap-server |
+-----------------+-----------------+
| DAP JSON-RPC
+-----------------+-----------------+
| Session Hub (Single State Hub) |
+--------+-----------------+--------+
| |
Internal DAP | | MCP JSON-RPC
v v
+-------------------+ +-------------------+
| VS Code Extension| | MCP Server |
| - SVD Tree View | | - Streamable HTTP|
| - RTT Terminal | | - stdio proxy |
| - Debug Adapter | | - 37 AI Tools |
+-------------------+ +-------------------+🚀 Quick Start
1. Prerequisites
Node.js
>= 20.0.0pnpm
>= 9.0.0
2. Build from Source
git clone https://github.com/RoadToSea/em-probe.git
cd em-debug
pnpm install
pnpm build
pnpm test3. Launching the Headless MCP Server
Streamable HTTP (Default: http://127.0.0.1:7580/mcp)
node packages/mcp-server/bin/em-debug-mcp.js --port=7580Stdio Mode (for Claude Code, Cursor, etc.)
node packages/mcp-server/bin/em-debug-mcp.js --stdio🔌 Connecting AI Agents
Claude Code CLI
Add to your ~/.claude.json or project configuration:
{
"mcpServers": {
"em-debug": {
"command": "node",
"args": ["D:/Vscode/code/em-debug/packages/mcp-server/bin/em-debug-mcp.js", "--stdio"]
}
}
}Cursor / Windsurf / Antigravity (Streamable HTTP)
Connect to the loopback HTTP endpoint when the VS Code extension or headless server is running:
{
"mcpServers": {
"em-debug": {
"url": "http://127.0.0.1:7580/mcp"
}
}
}📦 Package Workspace Structure
Package | Directory | Description |
| Core probe-rs binary resolution, DAP protocol client, and session management hub. | |
| CMSIS-SVD XML model parser with peripheral inheritance and bitfield decoder. | |
| Standalone and embedded MCP server exposing 37 embedded debugging tools. | |
| VS Code frontend extension hosting the DAP proxy, SVD TreeView, and RTT terminal. |
📖 Documentation
📐 DESIGN.md — Comprehensive architecture design specification and protocol contracts.
🗺️ docs/ARCHITECTURE.md — Architectural component mapping and sequence flows.
🔬 docs/PROBE_RS_ANALYSIS.md — In-depth comparison with official probe-rs ecosystem and design pattern adoption.
🛠️ docs/TOOLS.md — Complete reference manual for all 37 MCP tools with schemas and examples.
💻 docs/DEVELOPMENT.md — Local development environment setup and extension packaging.
🤝 CONTRIBUTING.md — Contribution guidelines and pull request process.
📜 CHANGELOG.md — Project release history and upgrade notices.
📄 License
This project is licensed under the MIT License.
This server cannot be deployed
Maintenance
Related MCP Connectors
Live browser debugging for AI assistants — DOM, console, network via MCP.
Run, build, and validate firmware on virtual hardware from your AI agent. Hardware knowledge corpus.
Shared debugging memory for AI coding agents
Persistent memory, hybrid search and a goal graph for AI agents, over stdio or remote HTTP.
Related MCP Servers
- AlicenseAqualityAmaintenanceEnables AI agents to perform step-through debugging of Python, JavaScript/Node.js, and Rust programs using the Debug Adapter Protocol, with support for breakpoints, variable inspection, and stack traces.29184MIT
- AlicenseAqualityCmaintenanceStateful MCP server for driving debug probes (J-Link) to flash, debug, and inspect embedded targets. Enables AI agents to perform flash, memory, breakpoint, and ELF/SVD-aware operations conversationally.4110MIT
- AlicenseNot gradedqualityCmaintenanceMCP server for embedded debugging based on probe-rs, providing 22 tools for ARM Cortex-M and RISC-V microcontrollers, including connection, memory operations, breakpoints, flash programming, and RTT communication.2MIT

sbl-debuggerofficial
AlicenseNot gradedqualityDmaintenanceEnables AI assistants to debug ARM Cortex-M targets via GDB and OpenOCD, supporting attach, breakpoints, stepping, register/memory inspection, and SVD peripheral decoding.MIT