FirmwareMaestro Docs
fwm CLI Agent

Installing the fwm CLI

Install the FirmwareMaestro terminal-based AI agent on macOS, Linux, or Windows, and walk through your first build-and-flash.

The fwm CLI is the FirmwareMaestro REPL — an AI agent that lives in your terminal and works directly inside your nRF Connect SDK projects. The installer drops a single fwm binary into ~/.fwm (or %USERPROFILE%\.fwm on Windows) and adds it to your PATH.

Install via the install script

curl -fsSL https://firmwaremaestro.com/install.sh | sh

Open PowerShell and run:

irm https://firmwaremaestro.com/install.ps1 | iex

The script installs fwm.exe to %USERPROFILE%\.fwm and updates your user PATH.

Install options

The install script honors two environment variables:

VariablePurpose
FWM_INSTALLInstall directory for the fwm binary (default ~/.fwm).
FWM_VERSIONPin to a specific version tag (e.g. v0.5.0); defaults to latest.
FWM_VERSION=v0.5.0 curl -fsSL https://firmwaremaestro.com/install.sh | sh

Verify

fwm --version    # → fwm 0.5.0
fwm --help       # → lists agent, update, completions

If the command is not found, restart your terminal so the updated PATH takes effect.

Upgrade in place

fwm update

Re-runs the installer and overwrites the existing binary.

Walkthrough

Install

curl -fsSL https://firmwaremaestro.com/install.sh | sh

Launch the REPL

fwm agent

You'll land in a full-screen TUI with a conversation pane, an input box, and a status bar showing the current mode. See Keybindings for the keyboard reference.

Authenticate

Inside the REPL:

/login

This opens your browser, completes sign-in, and saves your token to ~/.fwm/config.toml.

If the browser doesn't open automatically, the REPL prints the auth URL — open it manually in any browser.

Scaffold a project

/init --target nrf52840 --name my-ble-app

Generates a complete nRF Connect SDK + Zephyr project with the right CMakeLists.txt, prj.conf, and boards/<board>.overlay — all wired up so /build works out of the box. See /init for all options (Rust, C++, FreeRTOS, --from-docs, …).

Build and flash

/build      # auto-detects west, cargo, cmake, idf.py, or pio
/flash      # auto-detects west flash, nrfutil, nrfjprog, probe-rs, …

Ask the agent

Why is my UART not receiving data?

The agent reads your code, cross-references the datasheet, and explains what's wrong. Switch to plan mode for bigger changes:

/plan
Add a SPI driver for the LIS2DH12 accelerometer

Where to go next

On this page