Prep for the app suite: libble staging gate + README overview

Only stage libble/ into apps that include ble_central.h (so non-BLE apps
don't compile the central layer). Rewrite the README overview to list the
full app suite and note that everything except Battery Health needs the
custom firmware.
This commit is contained in:
2026-08-06 01:31:29 +01:00
parent c5b545f1db
commit 7c0e3894e1
2 changed files with 46 additions and 16 deletions
+41 -14
View File
@@ -1,21 +1,48 @@
# Flipper Zero BLE tools # Flipper Zero BLE tools
Two BLE apps for the Flipper Zero, sharing one central/GATT layer (`libble/`): A suite of BLE, sub-GHz and power tools for the Flipper Zero. The BLE apps
share one central/GATT layer (`libble/`).
* **BT Inspector** — a BLE scanner and GATT explorer, in the spirit of **Bluetooth (need the `build.sh` firmware)**
BTInspector for iOS: discover nearby Bluetooth Low Energy devices, see their
signal strength and everything they broadcast, then connect and inspect their
services and characteristics: read, write, subscribe, and log it all.
* **BLE HID Host** — connect to a Bluetooth keyboard or mouse and watch its
input reports decoded live (keys, modifiers, mouse buttons and movement).
> **Read this first.** This app cannot run on stock Flipper firmware. The * **BT Inspector** — BLE scanner and GATT explorer, in the spirit of
> Flipper's radio coprocessor ships with ST's "BLE Light" stack, which can only BTInspector for iOS: discover devices, decode everything they broadcast, then
> advertise (peripheral role). It cannot scan for or connect to other devices. connect and inspect/read/write/subscribe, and log it all.
> BT Inspector is therefore delivered as a **custom firmware build** that swaps * **BLE HID Host** — connect a Bluetooth keyboard or mouse and watch its input
> in ST's full BLE stack and exports the BLE command API to apps. The app itself reports decoded live.
> is a normal `.fap`. `build.sh` does all of this. * **BLE Sensor Dashboard** — connect a sensor and watch its known-service
> See [Why a custom firmware build](#why-a-custom-firmware-build). readings (battery, heart rate, temperature, humidity, pressure, ...) decoded
and updating live.
* **BLE Tracker Detector** — passively flag nearby item trackers (Apple Find
My / AirTag, Tile, Samsung SmartTag) with a "following you" warning.
* **BLE GATT Fuzzer** — enumerate a peripheral's whole GATT database, read every
readable value, and fuzz writable characteristics with boundary payloads,
logging every response. For authorised testing of devices you own.
* **BLE Beacon Toolkit** — broadcast an iBeacon or a raw advertising payload
with a chosen random MAC.
* **BLE GATT Server** — advertise the Flipper as a connectable serial GATT
peripheral and echo whatever a central writes.
**Sub-GHz (need the region unlock, on by default)**
* **Sub-GHz Scanner** — sweep RSSI across the full CC1101 range and log active
frequencies.
* **Sub-GHz Spectrum** — live spectrum bar graph and waterfall over a tunable
centre/span window.
**Tools**
* **Battery Health** — live fuel-gauge readings (voltage, current, temperature,
capacity, health, wear) with a voltage graph. Read-only.
> **Read this first.** These apps do not run on stock Flipper firmware. The
> Flipper's radio coprocessor ships with ST's "BLE Light" stack (advertise-only:
> it cannot scan or connect), and the sub-GHz region check blocks transmit
> off-region. They are delivered as a **custom firmware build** that swaps in
> ST's full BLE stack, exports the BLE command API to apps, and unlocks the
> sub-GHz region; the apps themselves are ordinary `.fap` files. `build.sh` does
> all of this. See [Why a custom firmware build](#why-a-custom-firmware-build).
> Battery Health is the only one that would also run on stock firmware.
## Features ## Features
+4 -1
View File
@@ -21,7 +21,7 @@
set -euo pipefail set -euo pipefail
HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" HERE="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
APPS=(bt_inspector ble_hid_host) # app dirs under $HERE, each staged with libble/ APPS=(bt_inspector ble_hid_host) # app dirs under $HERE; BLE apps staged with libble/
APP_SRC="$HERE/bt_inspector" # used only for the BLE_API=min symbol scan APP_SRC="$HERE/bt_inspector" # used only for the BLE_API=min symbol scan
FW_DIR="${FW_DIR:-$HERE/flipperzero-firmware}" FW_DIR="${FW_DIR:-$HERE/flipperzero-firmware}"
FW_TAG="${FW_TAG:-1.4.3}" FW_TAG="${FW_TAG:-1.4.3}"
@@ -119,7 +119,10 @@ mkdir -p applications_user
for app in "${APPS[@]}"; do for app in "${APPS[@]}"; do
rm -rf "applications_user/$app" rm -rf "applications_user/$app"
cp -r "$HERE/$app" "applications_user/$app" cp -r "$HERE/$app" "applications_user/$app"
# Only apps that include the shared header get the libble sources.
if grep -rql 'ble_central.h' "$HERE/$app"; then
cp "$HERE"/libble/*.c "$HERE"/libble/*.h "applications_user/$app/" cp "$HERE"/libble/*.c "$HERE"/libble/*.h "applications_user/$app/"
fi
done done
FBT_ARGS=( FBT_ARGS=(