Skip to content

Add command line tools#54

Merged
colemancda merged 22 commits into
masterfrom
feature/tools
Jul 18, 2026
Merged

Add command line tools#54
colemancda merged 22 commits into
masterfrom
feature/tools

Conversation

@colemancda

@colemancda colemancda commented Jul 18, 2026

Copy link
Copy Markdown
Member

Summary

Adds five executable targets for interacting with Bluetooth controllers on Linux, built on the existing HCI, L2CAP, and GATT support:

  • hcitool — list controllers (dev), classic inquiry (inq), and Low Energy scanning (lescan) with advertised local name decoding.
  • hciconfig — print controller information (list) and bring controllers up or down over the existing ioctl wrappers.
  • gatttool — GATT client for LE peripherals: discover primary services and characteristics, read and write characteristic values by handle or UUID, and subscribe to notifications and indications.
  • gattserver — advertises a configurable local name and serves a demo GATT database (Device Information and Battery services), re-listening after each disconnect.
  • beacon — advertise as an iBeacon (ibeacon) and stop advertising (stop).

Adds swift-argument-parser as a dependency for the new executable targets only; the BluetoothLinux library itself is unchanged.

Test plan

  • swift build succeeds with no warnings in the new targets
  • Existing test suite passes (40 tests)
  • Argument parsing verified for all subcommands via --help
  • Runtime behavior requires Linux with a Bluetooth adapter and root privileges

@colemancda
colemancda merged commit 4cc79c9 into master Jul 18, 2026
1 check passed
@colemancda
colemancda deleted the feature/tools branch July 18, 2026 04:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant