{"id":50134418,"url":"https://github.com/justincampbell/bfctl","last_synced_at":"2026-05-23T21:00:58.116Z","repository":{"id":356171545,"uuid":"1231240514","full_name":"justincampbell/bfctl","owner":"justincampbell","description":"Betaflight CLI (like an actual CLI not the Chrome one)","archived":false,"fork":false,"pushed_at":"2026-05-06T23:11:22.000Z","size":50,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-07T00:18:42.898Z","etag":null,"topics":["betaflight","cli","drone","flight-controller","fpv","golang","msp","quadcopter"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justincampbell.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-06T19:15:19.000Z","updated_at":"2026-05-06T23:11:26.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/justincampbell/bfctl","commit_stats":null,"previous_names":["justincampbell/bfctl"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/justincampbell/bfctl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justincampbell%2Fbfctl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justincampbell%2Fbfctl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justincampbell%2Fbfctl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justincampbell%2Fbfctl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justincampbell","download_url":"https://codeload.github.com/justincampbell/bfctl/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justincampbell%2Fbfctl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33412082,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-23T18:09:33.147Z","status":"ssl_error","status_checked_at":"2026-05-23T18:09:31.380Z","response_time":53,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["betaflight","cli","drone","flight-controller","fpv","golang","msp","quadcopter"],"created_at":"2026-05-23T21:00:35.267Z","updated_at":"2026-05-23T21:00:58.099Z","avatar_url":"https://github.com/justincampbell.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bfctl\n\nA CLI for talking to a [Betaflight](https://github.com/betaflight/betaflight) flight controller over USB.\n\n`bfctl` does what the web Configurator's \"Save to file\" button does, but from a terminal. Designed for humans and AI coding agents: stdout is data, stderr is chatter, exit codes are stable, `--json` where it makes sense.\n\n## Installation\n\n```sh\nbrew install justincampbell/tap/bfctl       # Homebrew\ngo install github.com/justincampbell/bfctl@latest   # Go\n```\n\nOr grab a binary from [GitHub Releases](https://github.com/justincampbell/bfctl/releases).\n\n## Usage\n\nPlug the FC in via USB and run:\n\n```sh\nbfctl backup                   # save full config (Configurator-style filename)\nbfctl backup --out my.txt      # …to a specific file path\nbfctl backup --out -           # …to stdout\nbfctl restore backup.txt       # replay a backup file (reboots after save)\n\nbfctl info                     # FC metadata (board, MCU, firmware, craft)\nbfctl info --json              # …as JSON\nbfctl ports                    # list detected FCs\nbfctl craft                    # print lowercase craft name only\n\nbfctl diff                     # non-default settings\nbfctl dump                     # every setting, including defaults\nbfctl get craft_name           # one setting\nbfctl set pilot_name = Maverick   # write + save (reboots)\nbfctl exec status              # send any CLI command verbatim\nbfctl cli                      # interactive REPL (history, tab completion)\n\nbfctl msp                      # scan supported MSP codes\nbfctl msp boxnames             # query one code (by name or number)\n```\n\nPass `--port` if more than one FC is plugged in.\n\n## Safety: `bfctl msp` scans\n\nThe scan skips a denylist of every \"in message\" MSP writer in range. Betaflight doesn't bounds-check `sbufReadU8`, so a 0-byte payload to a writer can silently corrupt config — and `MSP_SET_OSD_CANVAS` (188) has bricked an FC outright (DFU re-flash to recover). A scan can't read anything useful from a writer anyway. Single-code queries like `bfctl msp 188` bypass the denylist for opt-in research.\n\n`bfctl msp` requires the FC to be in MSP mode (freshly booted). If you've run `bfctl set` / `bfctl exec` / `bfctl cli` since power-up, power-cycle before running MSP queries.\n\n## Exit codes\n\n| Code | Meaning |\n|------|---------|\n| 0 | Success |\n| 1 | Generic error |\n| 2 | Usage error |\n| 3 | No Betaflight FC found |\n| 4 | More than one FC found (use `--port`) |\n| 5 | Port already in use (Chrome / Configurator likely holding it) |\n| 6 | Requested key not present (`get`, `craft`) |\n\n## Troubleshooting\n\n`no data` from the FC is usually a stale Chrome WebSerial lock from the web Configurator tab. Quit Chrome and retry.\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustincampbell%2Fbfctl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustincampbell%2Fbfctl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustincampbell%2Fbfctl/lists"}