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

# Find out why firmware crashes

> Run the firmware, read the status and captured UART, and ask about board-specific gotchas.

The firmware fails on the virtual board, and you need the run status, the captured UART, and the gotchas Chiplab already knows for that board.

## What you'll do

<Steps>
  <Step title="Run on the virtual board">
    Your agent uploads the ELF and runs it on the board model, with the UARTs to capture. Only those UARTs are written into the output.
  </Step>

  <Step title="Read the captured output and run status">
    `run` returns a `run_id` immediately. Your agent waits for the job and reads the status: `running`, `succeeded`, or `failed`. `stdout` is the captured UART output.
  </Step>

  <Step title="Ask about chip-specific gotchas">
    Ask Chiplab about the gotchas for that board. `ask` takes a natural-language question and returns chip-specific gotchas and validated fixes from real runs.
  </Step>

  <Step title="Fix and run again">
    Change the firmware, build the ELF again, and run it on the same board.
  </Step>
</Steps>

## Ask your agent

```text theme={null}
Run this ELF on the STM32F4 Discovery, capture usart2, and tell me the run status and what it printed. Then tell me the chip-specific gotchas for that board.
```

## What you get back

You get a status and `stdout` for the UARTs you captured. When the status is `failed`, the response includes an error string, and `ask` returns a plain-text answer with the gotchas for that board.

## Next

<CardGroup cols={2}>
  <Card title="run" icon="play" href="/tools/run">Execute an ELF on a virtual board and read the UART.</Card>
  <Card title="ask" icon="message" href="/tools/ask">Look up boards, tools, and chip-specific gotchas.</Card>
</CardGroup>


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