bf.
Betaflight from the command line.
bf configures Betaflight flight controllers over USB, or the Betaflight simulator. It covers what the Configurator does, and answers in plain text for you or stable JSON for scripts and AI agents.
What you get
Every tab, as a command
Setup, ports, receiver, modes, motors, PID, rates and filters, failsafe, OSD, VTX, LEDs, blackbox, presets, backups and firmware: bf pid get, bf osd set, bf modes set and so on.
Safe by default
Every change is checked before it's written, read back after, and saved. --dry-run everywhere, confirmation for anything destructive, and no writes while armed.
Made for AI agents
Stable JSON and exit codes, plus two skills that teach an agent to back up first, preview changes and ask before motor tests. Ask "why won't my quad arm?" and let it look.
Config as a file
Describe the settings you want in a small YAML file. bf config apply changes only what differs, so running it twice changes nothing.
Quick start
Needs Node.js 22 or newer. No install needed:
npx @rotordeck/bf status # arming flags, active modes, profiles npx @rotordeck/bf config backup -o my-quad.txt # always back up first npx @rotordeck/bf pid set roll.p=48 --dry-run # preview a change npx @rotordeck/bf receiver live --watch # watch sticks and switches
Or install the bf command with npm install -g @rotordeck/bf. On Linux your user needs access to the serial port (group uucp or dialout).
With Claude Code
The Rotordeck skills teach Claude Code how to run bf and how Betaflight setups work. In Claude Code:
/plugin marketplace add rotordeck/skills /plugin install betaflight@rotordeck-skills
Then ask, for example: "set up my ELRS receiver on UART2 and put ARM on AUX1" or "update to the latest stable firmware and keep my settings".
Honest limits
- Version 0.1, early. Tested against the Betaflight simulator and one real flight controller (a BETAFPV G473 board): reading, writing, backup and restore, presets, reboot and blackbox download.
- Firmware flashing over DFU and UART is built and unit-tested, but not yet tried on real hardware. Try it on a spare board first.
- Not covered yet: Autotune, cloud backups and shell completion.
- Motor commands need
--confirm-props-removed. Take the props off.
Community & licence
Questions or ideas? Join the Discord or open an issue on GitHub. bf is free software under the GNU AGPL v3. It runs on your computer and talks only to your flight controller, plus the Betaflight build and preset servers when you ask for firmware or presets.
More free tools in the Toy Box.