You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
DebugForge is an MCP server that connects Lauterbach TRACE32 debuggers to AI agents.
It gives Claude Code, Codex, Qwen and other AI agents direct access to your hardware debugger
— enabling them to autonomously read target state, locate software bugs, and drive the fix-debug cycle end-to-end.
Supports both local and remote (WinRM/SSH) TRACE32 environments.
Highlights
47 MCP Tools — Full TRACE32 access for AI agents: execution control, breakpoints, memory, registers, variables, symbols, and more
Autonomous Debugging — AI agents can independently connect to your target, reproduce issues, locate root causes, and suggest fixes
Local + Remote — Debug locally or connect to a remote Windows TRACE32 via WinRM/SSH with full file transfer support
Project-Aware — Configure once via debugforge.toml, your AI agent automatically knows your ELF paths, flash scripts, and TRACE32 setup
Real Hardware — Battle-tested on TC397 TriCore via USB. Your AI agent controls actual silicon, not a simulator
Advanced Breakpoints — Conditional, data watchpoints, hit-count, task-specific, action triggers, and temporary breakpoints
Deep Inspection — AI agents can read call stacks with locals, expand structs, view disassembly, inspect peripherals
Any MCP Agent — Works with Claude Code, Codex CLI, Qwen, or any MCP-compatible AI assistant
Zero Lock-in — MIT licensed, open source, no vendor dependencies beyond TRACE32 itself
# 4. Configure your project
cp debugforge.toml.example debugforge.toml
# Edit debugforge.toml with your paths and connection settings# 5. Start TRACE32 with API port enabled, then ask your AI agent:# "Connect to TRACE32, load the firmware, find why the system crashes at boot"
Installation
Prerequisites
Requirement
Details
Python
3.10 or higher
TRACE32
PowerView running with Remote API enabled
PYRCL
lauterbach-trace32-rcl package from your TRACE32 installation
Step 1: Install DebugForge
pip install debugforge
Or install from source:
git clone https://github.com/YangPan2020/debugforge.git
cd debugforge
pip install -e .
Step 2: Install TRACE32 Python Library
The PYRCL wheel is bundled with your TRACE32 installation:
Get connection status, TRACE32 version, and system state
get_project_config
Get the loaded project configuration (paths, scripts, settings)
Execution Control
Tool
Description
go
Start/continue program execution
step
Single-step execution (into, over, or out)
halt
Stop program execution
reset
Reset the target CPU
get_state
Get current CPU execution state
get_source_location
Get current source file and line
get_current_function
Get name of currently executing function
get_run_stats
Combined run/halt statistics
Breakpoints
Tool
Description
set_breakpoint
Set a program/read/write/readwrite breakpoint
list_breakpoints
List all active breakpoints
delete_breakpoint
Delete a breakpoint
clear_all_breakpoints
Delete all breakpoints at once
toggle_breakpoint
Enable/disable a breakpoint without deleting
Advanced Breakpoints
Tool
Description
set_conditional_breakpoint
Breakpoint with HLL condition (e.g., i > 100)
set_data_breakpoint
Trigger on memory access with optional value match
set_count_breakpoint
Stop after N-th hit (loop debugging)
set_task_breakpoint
Trigger only for a specific OS task/thread
set_action_breakpoint
Execute a TRACE32 command on hit
set_temporary_breakpoint
Auto-deletes after first hit
Memory
Tool
Description
read_memory
Read target memory (hex dump format)
write_memory
Write data to target memory
read_memory_cached
Read through CPU data cache
read_memory_physical
Read bypassing cache
Registers
Tool
Description
read_register
Read a single CPU register
read_registers
Read multiple registers at once
write_register
Write a value to a CPU register
Variables
Tool
Description
read_variable
Read a C/C++ variable by symbol name
write_variable
Write a value to a C/C++ variable
var_view
View a variable/struct/array with full expansion
Symbols
Tool
Description
symbol_by_name
Look up symbol address by name
symbol_by_address
Look up symbol name by address
Commands & Scripting
Tool
Description
execute_command
Execute any TRACE32 PRACTICE command
run_practice
Run a PRACTICE (.cmm) script with timeout
evaluate
Evaluate a TRACE32 expression or function
Debug Views
Tool
Description
get_callstack
Get call stack with function names
get_locals
Get call stack with all local variables per frame
get_data_dump
Formatted memory dump (hex + ASCII)
get_register_view
Full register view with all flags
get_window
Get text content of any TRACE32 window command
Multicore
Tool
Description
select_core
Switch debugger focus to a specific core
get_chip_info
Get chip stepping and configuration
get_all_cores_state
Get execution state of all cores
sync_cores
Synchronized Go/Break/Step across cores
On-chip Trace (MCDS)
Tool
Description
trace_start
Configure and start trace recording
trace_stop
Stop trace recording
trace_list
Display trace buffer contents
trace_clear
Clear trace buffer
trace_set_trigger
Set trace start/stop triggers
System Configuration
Tool
Description
set_reset_behavior
Configure reset handling
set_cache_read
Enable/disable cache-aware reads
set_peripheral_suspend
Suspend peripherals on halt
load_symbol_file
Load ELF debug symbols
get_system_options
Get all system option settings
Usage Examples
Basic Debug Session
You: "Connect to TRACE32 and help me find why the system crashes after boot"
AI Agent workflow:
1. get_project_config() → learns your ELF path and scripts
2. connect() → connects to TRACE32
3. run_practice("flash.cmm") → flashes firmware
4. set_breakpoint("main")
5. go() → runs to main
6. step("over") → steps through code
7. get_callstack() → analyzes the call stack
8. read_variable("error_code") → checks variables
→ "Found it: error_code = -1 because init_hardware() fails at line 84"
Remote Debug Session
You: "Connect to the remote TRACE32 on Windows and debug the TC397 board"
AI Agent workflow:
1. get_project_config() → detects remote mode, gets WinRM credentials
2. connect(node="192.168.1.100") → connects via PYRCL over network
3. run_practice("tc39x_flash.cmm") → flashes via remote TRACE32
4. go() → halt() → get_callstack()
→ Debugging the remote target as if it were local