jlink-mcp
Click on "Install 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., "@jlink-mcpread memory at 0x20000000"
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.
What is this?
jlink-mcp connects AI assistants (Claude, Copilot, etc.) to your embedded hardware via SEGGER J-Link debug probes using the Model Context Protocol.
Instead of manually typing J-Link commands, your AI assistant can:
Read registers and memory to understand device state
Flash firmware and reset devices
Stream RTT logs and search them by level/module/regex
Diagnose crashes by auto-decoding ARM Cortex-M fault registers
Control execution — halt, step, resume, breakpoints
Start GDB servers for full debugging sessions
Also supports OpenOCD (ST-Link, CMSIS-DAP, FTDI) and Black Magic Probe backends.
Related MCP server: jlink-mcp
Quick Start
Claude Desktop
Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"jlink": {
"command": "node",
"args": ["/path/to/jlink-mcp/out/mcp/standalone.js"],
"env": {
"JLINK_DEVICE": "nRF52840_XXAA"
}
}
}
}Claude Code
Add .mcp.json to your project root:
{
"mcpServers": {
"jlink": {
"command": "node",
"args": ["out/mcp/standalone.js"],
"cwd": "/path/to/jlink-mcp",
"env": {
"JLINK_DEVICE": "nRF52840_XXAA"
}
}
}
}VSCode Extension
Install the extension (requires VSCode 1.99+). It auto-registers the MCP server via the native vscode.lm API. Configure the device in settings:
jlinkMcp.jlink.device = "nRF52840_XXAA"Copilot Chat and Claude in VSCode will automatically discover all 31 tools.
From Source
git clone https://github.com/Klievan/jlink-mcp.git
cd jlink-mcp
npm install
npm run compile
JLINK_DEVICE=nRF52840_XXAA node out/mcp/standalone.jsTools (31)
Workflow Tools (start here)
Tool | Description |
| One-call setup. Starts GDB server + connects RTT + returns boot log. |
| Captures full device state: registers, fault status, stack dump, RTT output. |
| Auto-reads and decodes ARM Cortex-M fault registers (CFSR, HFSR, MMFAR, BFAR) with exception stack frame. |
Device Control
Tool | Description |
| Probe type, target CPU, compact register summary |
| Halt CPU |
| Resume CPU |
| Reset device (optionally halt after reset) |
| Single-step one instruction |
Memory & Registers
Tool | Description |
| Read memory at address (clean hex dump output) |
| Write 32-bit value to address |
| All CPU registers in compact format |
| Read specific register (PC, SP, R0-R12, etc.) |
Flash
Tool | Description |
| Flash .hex/.bin/.elf firmware to device |
| Erase entire flash |
Breakpoints
Tool | Description |
| Set hardware breakpoint at address |
| Clear all breakpoints |
GDB Server
Tool | Description |
| Start probe's GDB server |
| Stop GDB server + disconnect RTT |
| GDB server, RTT, and proxy status |
RTT (Real-Time Transfer)
Tool | Description |
| Connect to RTT telnet port |
| Disconnect from RTT |
| Read recent log lines (ANSI stripped, Zephyr format parsed) |
| Filter logs by level ( |
| Send data to device via RTT down-channel |
| Clear RTT buffer |
Telnet Proxy (Trice / Pigweed)
Tool | Description |
| Start TCP proxy that tees RTT for external detokenizers |
| Stop proxy |
| Proxy connection status |
| Read raw proxy buffer |
Advanced
Tool | Description |
| Execute raw probe commands |
| Current probe and server configuration |
Multi-Probe Support
jlink-mcp supports multiple debug probe backends through a common ProbeBackend abstraction:
Backend | Probe Hardware | Status | RTT Support |
J-Link | SEGGER J-Link, J-Link OB, J-Link EDU | Production | Yes |
OpenOCD | ST-Link, CMSIS-DAP, FTDI, J-Link (via OpenOCD) | Beta | No |
Black Magic Probe | BMP (built-in GDB server on serial) | Beta | No |
probe-rs | All probe-rs supported probes | Planned | Planned |
Selecting a Backend
# J-Link (default)
PROBE_TYPE=jlink JLINK_DEVICE=nRF52840_XXAA node out/mcp/standalone.js
# OpenOCD with ST-Link
PROBE_TYPE=openocd \
OPENOCD_INTERFACE=interface/stlink.cfg \
OPENOCD_TARGET=target/stm32f4x.cfg \
node out/mcp/standalone.js
# Black Magic Probe
PROBE_TYPE=blackmagic \
BMP_SERIAL_PORT=/dev/ttyACM0 \
node out/mcp/standalone.jsArchitecture
┌─────────────────────────────────────────────────────┐
│ MCP Client │
│ (Claude, Copilot, any MCP client) │
└──────────────────────┬──────────────────────────────┘
│ JSON-RPC over stdio
┌──────────────────────▼──────────────────────────────┐
│ jlink-mcp │
│ │
│ ┌──────────┐ ┌──────────┐ ┌───────────────────┐ │
│ │ 31 Tools │ │4 Resources│ │ 4 Prompts │ │
│ └────┬─────┘ └────┬─────┘ └───────┬───────────┘ │
│ │ │ │ │
│ ┌────▼──────────────▼────────────────▼───────────┐ │
│ │ ProbeBackend │ │
│ │ ┌─────────┐ ┌─────────┐ ┌──────────────────┐ │ │
│ │ │ J-Link │ │ OpenOCD │ │ Black Magic Probe│ │ │
│ │ └────┬────┘ └────┬────┘ └────────┬─────────┘ │ │
│ └───────┼───────────┼───────────────┼─────────────┘ │
│ │ │ │ │
│ ┌───────▼───┐ ┌─────▼────┐ ┌───────▼──────────┐ │
│ │ RTTClient │ │TelnetProxy│ │ ProcessManager │ │
│ └───────────┘ └──────────┘ └──────────────────┘ │
└─────────────────────────────────────────────────────┘
│
┌────────────▼────────────┐
│ Debug Probe (USB) │
│ → Target MCU (SWD/JTAG)│
└─────────────────────────┘Source Layout
src/
├── probe/
│ ├── backend.ts # ProbeBackend abstract class + shared utilities
│ ├── jlink.ts # SEGGER J-Link implementation
│ ├── openocd.ts # OpenOCD implementation
│ ├── blackmagic.ts # Black Magic Probe implementation
│ └── factory.ts # Probe creation from config
├── mcp/
│ ├── server.ts # MCP server (31 tools, 4 resources, 4 prompts)
│ └── standalone.ts # Standalone entry (stdio transport)
├── rtt/
│ └── rtt-client.ts # RTT client with ANSI stripping + Zephyr log parsing
├── telnet/
│ └── telnet-proxy.ts # TCP proxy for Trice/Pigweed detokenizer
├── utils/
│ ├── config.ts # VSCode settings / env var config
│ ├── logger.ts # Logging
│ └── process-manager.ts # Child process lifecycle
└── extension.ts # VSCode extension + MCP provider registrationDesign Decisions (LLM-Optimized)
This server was built by having an AI use it against real hardware, then fixing every friction point:
Output parsing strips 40+ lines of J-Link connection banners. Only data comes back.
Registers are compact:
Core: PC=0xBF54 SP=0x20062880 ...instead of 65 raw lines.FP registers only shown if non-zero (they're usually all zeros).
RTT output has ANSI escape codes stripped and Zephyr log format parsed into structured fields.
Composite tools (
start_debug_session,snapshot,diagnose_crash) replace multi-step workflows with single calls.Fault decoding is automatic — reads CFSR/HFSR/MMFAR/BFAR and explains each bit.
rtt_searchlets you find errors without reading the entire log.
Environment Variables
J-Link
Variable | Default | Description |
|
| Probe backend: |
|
| Target device (e.g., |
| Auto-detect | Path to SEGGER J-Link installation |
|
| Debug interface: |
|
| Connection speed in kHz |
| J-Link serial number (multi-probe) | |
|
| GDB server port |
|
| RTT telnet port |
OpenOCD
Variable | Default | Description |
|
| Path to openocd binary |
|
| Interface config file |
|
| Target config file |
|
| GDB server port |
|
| Telnet command port |
Black Magic Probe
Variable | Default | Description |
|
| Path to GDB binary |
|
| BMP serial port |
|
| Target index after scan |
Prerequisites
SEGGER J-Link Software installed (JLinkExe, JLinkGDBServer)
A J-Link debug probe connected to an ARM Cortex-M target
Node.js 18+
For other backends: OpenOCD or arm-none-eabi-gdb as appropriate.
Contributing
Adding a new probe backend:
Create
src/probe/yourprobe.tsimplementingProbeBackendAdd a case to
src/probe/factory.tsThat's it — all 31 MCP tools work automatically
License
MIT - see LICENSE
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI to directly control SEGGER J-Link embedded debug probes via the Model Context Protocol for debugging and firmware management. Users can perform tasks like reading registers, analyzing memory, flashing firmware, and tracking RTT logs using natural language commands.Last updated211MIT
- AlicenseAqualityCmaintenanceEnables AI assistants like Claude to directly debug microcontrollers via JLink, supporting breakpoints, single-step, memory/register access, variable inspection, RTT logging, and firmware flashing.Last updated253MIT
- AlicenseAqualityCmaintenanceEnables LLMs to interact with embedded devices by reading and writing Segger RTT data through a J-Link debugger.Last updated91MIT
- AlicenseAqualityDmaintenanceEnables AI tools to perform full-featured embedded microcontroller debugging via pyOCD and CMSIS-DAP probes, including probe management, flashing, breakpoints, register/memory access, fault analysis, and RTT communication.Last updated581MIT
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
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Klievan/jlink-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server