> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Monitor and debug

> Choose the observation that explains a firmware or hardware problem, open your tool's guide, and connect bench instruments in the Inlay Monitor.

Start from the symptom, choose the observation that can confirm or rule out a cause, then open the guide for the tool on your bench. Most observations appear in the Inlay Monitor, which keeps serial output, plots, debugger output, and instrument captures beside your code and chat. It's a panel in VS Code, or a browser view opened from the terminal UI with `/monitor`.

For a full investigation from reproduction to regression check, follow [Debugging and RCA](/docs/solutions/debugging-and-rca.md).

## Choose the evidence

| You want to | Open |
| - | - |
| See boot output and logs, or send console commands | [UART](/docs/debug-mode/uart.md), [SEGGER RTT](/docs/debug-mode/rtt.md), [ITM/SWO](/docs/debug-mode/itm-swo.md), or [XMOS xSCOPE](/docs/debug-mode/xscope.md). [Serial transports](/docs/debug-mode/serial-transports.md) compares them. |
| Find where the firmware hangs or faults: stack, memory, and peripheral registers | [GDB](/docs/debug-mode/gdb.md) and [registers](/docs/debug-mode/registers.md) |
| See which code ran before a fault, or which lines a test covered | [Coverage and trace](/docs/debug-mode/coverage-and-trace.md) |
| Measure current and energy during a workload | [Power analyzer](/docs/debug-mode/power-analyzer.md) |
| Check digital edges and decode a protocol | [Logic analyzer](/docs/debug-mode/logic-analyzer.md) |
| View analog waveforms and take signal measurements | [Oscilloscope](/docs/debug-mode/oscilloscope.md) |
| Sweep a frequency range and find RF peaks | [Spectrum analyzer](/docs/debug-mode/spectrum-analyzer.md) |
| Read CAN frames and decode their signals | [CAN](/docs/debug-mode/can.md) |
| Plot live numeric signals and calculated channels | [Plots](/docs/core-concepts/plot.md) |
| Inspect BLE advertisements, services, and notifications | [Bluetooth](/docs/debug-mode/bluetooth.md) |
| See the network traffic a board sends and receives | [Network packets](/docs/debug-mode/packets.md) |
| Repeat a check or a measurement as a script | [Hardware scripts](/docs/debug-mode/hardware-scripts.md) |
| Keep related readings and controls in one reusable view | [Dashboards](/docs/core-concepts/dashboards.md) |
| Rule out a cause that one instrument can't isolate | [Combine observations](/docs/debug-mode/combined-workflows.md) |

In a capture request, name the instrument, the physical channels, the duration, and the result you expect.

## Open your tool's guide

Each integration has its own setup, usage, and troubleshooting page. Choose by the tool connected to your board or computer:

| Tool type | Guides |
| - | - |
| Serial | [UART](/docs/debug-mode/uart.md), [SEGGER RTT](/docs/debug-mode/rtt.md), [ITM/SWO](/docs/debug-mode/itm-swo.md), [XMOS xSCOPE](/docs/debug-mode/xscope.md) |
| CAN adapters | [SLCAN](/docs/debug-mode/slcan.md), [mjbots fdcanusb](/docs/debug-mode/fdcanusb.md) |
| Debuggers | [SEGGER J-Link](/docs/debug-mode/jlink.md), [OpenOCD](/docs/debug-mode/openocd.md), [TI CCS and XDS](/docs/debug-mode/ccs.md), [XMOS xTAG and xgdb](/docs/debug-mode/xmos-debugging.md) |
| Logic analyzers | [Saleae Logic](/docs/debug-mode/saleae.md), [Digilent WaveForms](/docs/debug-mode/digilent.md), [DSLogic](/docs/debug-mode/dslogic.md) |
| Oscilloscopes | [PicoScope](/docs/debug-mode/picoscope.md), [SCPI oscilloscopes](/docs/debug-mode/scpi-oscilloscopes.md), [Siglent](/docs/debug-mode/siglent.md), [Digilent WaveForms](/docs/debug-mode/digilent.md) |
| Spectrum analyzer | [Siglent SSA3015X Plus](/docs/debug-mode/spectrum-analyzer.md) |
| Power instruments | [Nordic PPK2](/docs/debug-mode/ppk2.md), [Joulescope](/docs/debug-mode/joulescope.md). Digilent's supply and analog measurement features are on the [Digilent](/docs/debug-mode/digilent.md) page. |
| Trace and simulation | [SEGGER J-Trace](/docs/debug-mode/jtrace.md), [XMOS xsim](/docs/debug-mode/xsim.md). The RTT, ITM, and xSCOPE guides cover event-recording prerequisites. |
| Wireless | [Bluetooth Low Energy](/docs/debug-mode/bluetooth.md) |
| Network packet capture | [Network packets](/docs/debug-mode/packets.md), with Wireshark and TShark |
| Programming and remote hardware | [Flashing firmware](/docs/debug-mode/flashing.md), [probe-rs](/docs/debug-mode/probe-rs.md), [AURIX ADS and Flasher](/docs/debug-mode/aurix.md) on Windows, [benches](/docs/integrations/benches.md) |

A detected instrument or a catalog listing doesn't mean every operation is supported. Check the tool's guide for model-specific limits before you rely on a capture or output function.

## Start an investigation

1. Open the project whose source and firmware build match the target.
2. In VS Code, run **Inlay: Open Inlay Monitor** from the Command Palette. The Monitor opens in the Panel as **Inlay Monitor**. In the terminal UI, run `/monitor`.
3. Ask Inlay to check the connected hardware, and finish any setup it reports. For bench instruments, you can also [connect from the Monitor](#connect-a-bench-instrument).
4. Describe the symptom and any target state you need to preserve.

```text theme={"theme":"css-variables"}
The device stopped logging when the radio started. Read the existing UART
history, then attach with GDB without programming or resetting the target.
```

**Act** mode covers builds, flashing, serial monitoring, [hardware scripts](/docs/debug-mode/hardware-scripts.md), and instrument measurements. Switch to **Debug** mode with `/debug` when Inlay needs to start a debug server and inspect a paused target. See [Agent modes](/docs/core-concepts/modes.md).

## Work with Monitor tabs

Each Monitor tab shows one view, such as a serial port, a plot, an instrument, or a dashboard. A tab has its own toolbar. On serial and instrument tabs, the toolbar starts with a chip that shows the selected port or device: select it to choose another one or change its settings.

* Select **+** (**New tab**) to open a new tab. Search for an instrument or view, or type a LAN address. Results are grouped under **On the bench**, **Views**, **Saved plots**, and **Dashboards**.
* The **Views** group opens **Serial Monitor**, **Plot**, **Logic Analyzer**, **Oscilloscope**, **Spectrum Analyzer**, **Power**, **Trace**, **Coverage**, **Debug Output**, **Packets**, **Sim IO**, and **Bluetooth** tabs. See [Open the Monitor](/docs/integrations/vscode-extension.md#open-the-monitor) for what each view shows.
* Double-click a tab, or select it and press F2, to rename it. Drag a tab to an edge of the Monitor to split the panel.
* When the tabs don't fit, use the **All tabs** menu at the end of the tab bar to switch between them.

The Monitor holds up to 10 tabs. Close one before opening another when **+** is unavailable.

To read a serial port, see [Open a Serial Monitor tab](/docs/debug-mode/serial-transports.md#open-a-serial-monitor-tab). To use an oscilloscope, logic analyzer, power analyzer, or spectrum analyzer, continue with the next section.

## Connect a bench instrument

Oscilloscopes, the spectrum analyzer, power analyzers, and Saleae, Digilent, and PicoScope MSO logic analyzers connect from the Monitor. Their **Oscilloscope**, **Spectrum Analyzer**, **Power**, and **Logic Analyzer** tabs share the same controls: a device chip at the start of the toolbar, which lists detected and saved instruments, and a **⋯** (**Device actions**) menu.

**1. Open a new tab**

In the Monitor, select **+**. The **On the bench** group lists the instruments Inlay detects, with each one's type, address, and status. Instruments that already have a tab are hidden until you search for them; selecting one then switches to its tab.

**2. Choose the instrument**

Select an instrument to open a tab bound to it.

For a LAN instrument that isn't listed, type its address in the search field, such as `192.168.1.20` or `192.168.1.20:5025`, and select **Connect to 192.168.1.20**. Inlay probes the address and opens the matching tab. If nothing responds, the tab shows **No instrument answered**. In an **Oscilloscope** or **Spectrum Analyzer** tab, you can also choose **Enter address…** from the device chip. Power and logic analyzers connect over USB.

**3. Set up the instrument**

If the instrument needs software first, select **Set up & connect**. Selecting it approves setup. Inlay installs what that instrument needs, shows progress in the toolbar, and then connects.

The device chip shows the instrument's status:

| Status | Meaning | What to do |
| - | - | - |
| **Detected** | Inlay found the instrument, but it needs software before it can connect. The new tab's list shows **Needs setup**. | Select **Set up & connect**, or choose **Set up** from the **Device actions** menu. If Python is missing, the menu also offers **Get Python**. |
| **Setting up** | Inlay is installing the instrument's dependencies. | Wait for the progress message in the toolbar to finish. |
| **Ready** | Setup is complete. | A tab bound to the instrument connects automatically. Otherwise, select **Connect**. |
| **Connected** | This tab holds the instrument connection. | Choose **Disconnect** from the **Device actions** menu to release it. |
| **Disconnected** | A saved instrument isn't reachable now. | Plug it in or power it on, then choose **Rescan devices** from the **Device actions** menu. |
| **Unsupported** | Inlay recognized the instrument, but the model isn't supported. | Check the tool's guide for supported models. |
| **Error** | Inlay found the instrument but couldn't reach it or finish setup. | Read the reason in the toolbar, fix it, then connect again. |

The **Device actions** menu also has **Rename device** to name the instrument, **Rescan devices** to search again, and **Forget device** to remove a saved instrument that isn't currently detected. When an instrument needs software from its vendor, the menu links to it.

When a chat is using the hardware, the toolbar shows **In use by** and the chat's name. Select it to see who holds the hardware.

After you approve setup once, Inlay sets up other instruments of the same family automatically, such as a second PPK2. It remembers each instrument's name, address, and tab settings for the next session.

The LAN instrument connected in a Monitor tab is also the default for [hardware scripts](/docs/debug-mode/hardware-scripts.md). For example, `scope_connect()` or `spectrum_connect()` called without an address uses it.

## Test one hypothesis

```text theme={"theme":"css-variables"}
Check whether SDA rises too slowly. Capture SDA on scope channel 1 at the
current I2C speed, report the rise time, and compare it with the bus requirement.
```

Save the original capture before changing settings. After a fix, repeat the original condition and compare the results.

Use a [hardware script](/docs/debug-mode/hardware-scripts.md) for a repeatable sequence, or [combine observations](/docs/debug-mode/combined-workflows.md) when one instrument can't separate the causes.

## Preserve the target

> [!WARNING]
>
> A normal GDB connection can program and reset the board. Bounded J-Trace instruction and coverage captures also reset and run it. When the existing fault or RAM state matters, review the [attachment precautions](/docs/debug-mode/gdb.md#attach-to-a-running-target) before opening a new debugger connection.

State restrictions in your request, such as "do not reset," "do not transmit on CAN," or "keep the supply below 3.3 V." If another session is using the board, run `/hardware-queue` to see which session holds it.

## Use the terminal UI

The terminal UI supports the same investigations and saved results. Run `/monitor` to open the Monitor in a browser on the computer that runs Inlay, with the same serial, plot, instrument, and dashboard tabs that VS Code shows. The page is served on `127.0.0.1`, so it's reachable only from that computer. `/serial` toggles a serial sidebar inside the terminal UI; see [Use the terminal UI](/docs/debug-mode/serial-transports.md#use-the-terminal-ui) for what it can do. Plots of serial and capture data also appear inline in the conversation. See [Use Inlay in the terminal](/docs/cli/overview.md#open-the-monitor-and-schematic-viewer-in-a-browser).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.