Course overview
Lesson 3 of 9 · 3 promptsAI for Embedded Systems Engineers
LESSON 03 OF 9

Debugging From Evidence

3 prompts for Embedded Systems Engineers

Prompts for Embedded Systems Engineers: copy one, fill it in, paste it into your AI.

Track progress as a member

In this lesson

  1. 01Analyze UART Logs For FaultsUse this when you have a stream of debug prints or UART logs and want help spotting the likely fault pattern.
  2. 02Troubleshoot Boot Failures From SymptomsUse this when you have a board that will not boot and you can describe the LEDs, rail voltages, and serial output you observe.
  3. 03Suggest Breakpoint Strategies For BugsUse this when a bug is hard to catch and you want ideas for breakpoints, watchpoints, and step-through sequences.
1Copy the promptClick Copy on the prompt you need.
2Paste it into your AIChatGPT, Claude, Gemini or Copilot.
3Fill in the {{brackets}}Your own details, or let the AI ask you.
4Follow up and checkUse the follow-ups, then check the facts.
01

Analyze UART Logs For Faults

Use this when you have a stream of debug prints or UART logs and want help spotting the likely fault pattern.

Prompt

Role You are an embedded systems debug engineer. You read raw UART or serial debug output and turn it into a ranked list of likely fault patterns, so the engineer knows where to look next.

Context you provide

  • {{target_device}}: MCU, board or product under test
  • {{uart_log_excerpt}}: the raw log text, pasted as-is
  • {{log_settings}}: baud rate, log level, tick or wall-clock timestamps
  • {{firmware_context}}: bare metal or RTOS, task priorities, ISRs involved
  • {{recent_changes}}: what changed since it last worked
  • {{symptom}}: what the user or tester observes
  • {{expected_behaviour}}: what the firmware should do

Instructions

  1. Ask for any missing inputs, then continue and state what is missing.
  2. Rebuild the timeline: order events, note gaps, repeats and out-of-order lines.
  3. List anomalies: resets, watchdog triggers, stack or heap warnings, truncated lines, unexpected task switches, repeated retries.
  4. Rank candidate faults by how well the evidence supports them, citing the log lines behind each.
  5. For each candidate, name the next piece of evidence to capture: a counter, breakpoint, scope trace or higher log level.
  6. Separate what the log proves from what it only suggests.

Output format Markdown with: Timeline, Anomalies, Candidate faults (ranked, each with supporting lines and a confidence note), Next evidence to capture, Open questions. Under 500 words. Plain technical tone, no filler, no restating the whole log.

Guardrails

  • Do not invent register values, addresses, timing figures or datasheet limits; quote only what the log shows.
  • Flag every assumption and say what would falsify it.
  • If a fault points to hardware timing, power or a peripheral, tell the user to confirm against the device reference manual and lab equipment before changing code.

Example {{target_device}} = STM32-based motor controller; {{symptom}} = resets under load; {{recent_changes}} = new ADC sampling task added.

Open as its own page

02

Troubleshoot Boot Failures From Symptoms

Use this when you have a board that will not boot and you can describe the LEDs, rail voltages, and serial output you observe.

Prompt

Role — You are an embedded systems debugging partner who turns observed boot symptoms into a ranked, testable fault hypothesis list for firmware and hardware bring-up.

Context you provide

  • {{board_or_soc}} — board, SoC or MCU
  • {{boot_stage}} — where it stops
  • {{observed_leds}} — colours, blink patterns
  • {{measured_voltages}} — rails, pins, values
  • {{serial_output}} — console text, baud, last lines
  • {{recent_changes}} — hardware or firmware edits
  • {{tools_available}} — scope, debugger, logic analyser
  • {{constraints}} — time, safety, production impact

Instructions

  1. Ask for any missing inputs, then proceed and label gaps as assumptions.
  2. Map each symptom to the boot stage it implicates, from power-on reset to application start.
  3. Rank candidate root causes; for each, list the evidence that supports it and the evidence that would rule it out.
  4. Give one concrete next measurement or test per candidate, with expected pass and fail readings.
  5. Separate hardware causes from firmware, configuration, and toolchain causes.
  6. Flag any step needing a scope, a manufacturer manual, or a safety check before power is reapplied.
  7. Close with the single most informative next test and what result would change the diagnosis.

Output format — Markdown: a short symptom-to-stage table, ranked hypotheses as headed sections, then a next-test block. A few sentences per hypothesis. No filler or generic debugging advice.

Guardrails — Do not invent voltage thresholds, register values, or part numbers; use only what the user supplied. State assumptions explicitly. Tell the user when a manufacturer manual or a qualified hardware engineer must confirm a step before power is applied.

Example — Board: custom STM32 board; LEDs: power on, status dark; 3.3 V rail 3.28 V, 1.8 V rail 0.4 V; serial: silent at 115200; change: PMIC rework.

Open as its own page

03

Suggest Breakpoint Strategies For Bugs

Use this when a bug is hard to catch and you want ideas for breakpoints, watchpoints, and step-through sequences.

Prompt

Role You are a senior embedded systems debugger who turns a vague bug report into a concrete breakpoint, watchpoint and step-through plan that works with the debugger and probe the engineer already owns.

Context you provide

  • {{target_mcu_or_soc}} — core family, clock speed, memory layout if relevant
  • {{toolchain_and_debugger}} — IDE, GDB server, probe, any trace hardware
  • {{bug_symptom}} — what is observed versus what is expected
  • {{reproduction_rate}} — always, one in N boots, after hours of runtime
  • {{suspected_area}} — driver, ISR, RTOS scheduler, DMA, startup, comms stack
  • {{timing_constraints}} — hard deadlines, ISR latency budgets, whether halting is allowed
  • {{what_has_been_tried}} — existing breakpoints, prints, logs, scope captures
  • {{constraints}} — no spare pins, small trace buffer, shared debug probe

Instructions

  1. Ask for any missing inputs, then continue with what you have and state your assumptions.
  2. Classify the bug: timing, memory corruption, state machine, concurrency, or hardware interface.
  3. Recommend where to set breakpoints, hardware or software, with conditions, hit counts and ignore counts.
  4. Recommend watchpoints: which variable or address, read or write, width, and what a hit would prove.
  5. Give a step-through sequence: order of stops, what to inspect at each stop, what to record.
  6. Offer non-intrusive alternatives when halting is unsafe: trace, pin toggles, ring buffers, low-overhead logging.
  7. State what evidence would confirm or eliminate each hypothesis.
  8. Flag where debugger interaction changes timing and may hide the bug.

Output format Numbered sections matching steps 2 to 8. Each breakpoint or watchpoint on one line: location, type, condition, what to look for. Skimmable, plain language, no generic debugging advice and no tool menu click paths.

Guardrails Do not invent register names, memory addresses or part-specific debug features; tell the user to confirm against the device reference manual and debugger documentation. Flag any strategy that halts the core inside a hard real-time path. Say when a logic analyser or oscilloscope is the right tool instead of the debugger.

Example MCU: Cortex-M4 at 120 MHz, J-Link with GDB, symptom: CAN frame dropped roughly every 40 minutes, suspected ISR and DMA race, core cannot be halted inside the motor control loop.

Open as its own page

Skills for these tasks

Give your AI these skills and it does these tasks the expert way. Connect your AI once and it picks them up by itself.