Bfd debug executor

From Sonder4/STM32-BFD-Kit · View interactive version

Bfd debug executor is an AI agent skill from the GitHub repository Sonder4/STM32-BFD-Kit. Use when running direct J-Link command sequences for breakpoints, stepping, register reads, and one-shot debug actions on STM32 targets.

How to use this skill

Skill file

BFD Debug Executor

Self-Improvement Loop (Required)

Use this skill for fast, scriptable J-Link actions without a full GDB session.

Quick Start

  1. Run bootstrap profile first.
  2. Keep logs under logs/debug/.
  3. Use command-file based execution for reproducibility.

Core Commands

# 0) Bootstrap profile (required)
python3 ./.codex/skills/bfd-project-init/scripts/bootstrap.py --project-root . --mode check
# Break at main, run, and dump registers
JLinkExe -device "${STM32_DEVICE}" -if "${STM32_IF}" -speed "${STM32_SPEED_KHZ}" <<'EOF2' | tee logs/debug/debug_main.log
connect
h
bs main
go
wait
regs
exit
EOF2
# Recommended for multi-step sessions
cat > logs/debug/debug_cmd.jlink <<'EOF2'
connect
h
bs main
go
wait
regs
exit
EOF2
JLinkExe -device "${STM32_DEVICE}" -if "${STM32_IF}" -speed "${STM32_SPEED_KHZ}" -CommandFile logs/debug/debug_cmd.jlink | tee logs/debug/debug_cmd.log
pwsh -File ./.codex/skills/bfd-debug-executor/scripts/debug.ps1 -Breakpoint "main" -AfterHit "regs"

Workflow

  1. Run bootstrap profile.
  2. Connect and halt.
  3. Execute breakpoint/step/register commands.
  4. Save and report PC/LR/xPSR evidence.

Hard Rules

Scripts

Related Skills

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.