Replace USB serial/HID with Bluetooth Low Energy
Move all communication from USB to BLE. The device now advertises as "Claude Controller" and acts as both a BLE HID keyboard (for touch gestures) and a GATT data server (for usage updates from the daemon). - Add NimBLE-Arduino BLE module with custom GATT service + HID keyboard - Add third screen (Bluetooth) with connection status, MAC, reset button - Rewrite daemon in bash using bluetoothctl/busctl for BLE GATT writes - Add screenshot capture via LVGL snapshot over serial - Remove TinyUSB mode — normal pio upload works again - Update README with BLE architecture, screenshots, gesture docs Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
930055170f
commit
10b8052bcc
+12
-9
@@ -11,10 +11,10 @@ echo ""
|
||||
|
||||
# Check dependencies
|
||||
echo "[1/3] Checking dependencies..."
|
||||
for cmd in curl stty inotifywait; do
|
||||
for cmd in curl awk bluetoothctl busctl; do
|
||||
command -v "$cmd" >/dev/null || { echo "Error: $cmd is required but not installed"; exit 1; }
|
||||
done
|
||||
echo " All dependencies found (curl, python3, stty)"
|
||||
echo " All dependencies found"
|
||||
echo ""
|
||||
|
||||
# Install systemd user service with resolved path
|
||||
@@ -24,7 +24,7 @@ DAEMON_BIN="$SCRIPT_DIR/daemon/$SERVICE_NAME.sh"
|
||||
sed "s|DAEMON_PATH|${DAEMON_BIN}|g" "$SERVICE_FILE" > "$USER_SERVICE_DIR/$SERVICE_NAME.service"
|
||||
systemctl --user daemon-reload
|
||||
|
||||
# Enable (service starts automatically when device is plugged in)
|
||||
# Enable service
|
||||
echo "[3/3] Enabling service..."
|
||||
systemctl --user enable "$SERVICE_NAME"
|
||||
|
||||
@@ -32,7 +32,15 @@ echo ""
|
||||
echo "=== Done! ==="
|
||||
echo ""
|
||||
echo "The daemon will now start automatically when you log in"
|
||||
echo "and the SC01 Plus is connected via USB."
|
||||
echo "and connect to the SC01 Plus over Bluetooth Low Energy."
|
||||
echo ""
|
||||
echo "First-time Bluetooth pairing:"
|
||||
echo " 1. Power on the SC01 Plus"
|
||||
echo " 2. Run: bluetoothctl scan le"
|
||||
echo " 3. Find 'Claude Controller' and note the MAC address"
|
||||
echo " 4. Run: bluetoothctl pair <MAC>"
|
||||
echo " 5. Run: bluetoothctl trust <MAC>"
|
||||
echo " 6. Start the daemon: systemctl --user start $SERVICE_NAME"
|
||||
echo ""
|
||||
echo "Useful commands:"
|
||||
echo " systemctl --user status $SERVICE_NAME # check status"
|
||||
@@ -40,8 +48,3 @@ echo " journalctl --user -u $SERVICE_NAME -f # view logs"
|
||||
echo " systemctl --user restart $SERVICE_NAME # restart"
|
||||
echo " systemctl --user stop $SERVICE_NAME # stop"
|
||||
echo ""
|
||||
echo "To uninstall:"
|
||||
echo " systemctl --user stop $SERVICE_NAME"
|
||||
echo " systemctl --user disable $SERVICE_NAME"
|
||||
echo " rm $USER_SERVICE_DIR/$SERVICE_NAME.service"
|
||||
echo " systemctl --user daemon-reload"
|
||||
|
||||
Reference in New Issue
Block a user