butane_dart_bluez 0.1.0 copy "butane_dart_bluez: ^0.1.0" to clipboard
butane_dart_bluez: ^0.1.0 copied to clipboard

Pure-Dart BlueZ/D-Bus backend for butane_dart (no Flutter).

butane_dart_bluez #

Pure-Dart BlueZ/D-Bus backend for butane_dart — BLE on Linux with no Flutter dependency.

ButaneDartBluez implements ButanePlatformInterface over BlueZ via the system D-Bus, so any Dart program on a Linux host with a BlueZ-managed adapter can act as a BLE central or peripheral. The Flutter Linux implementation (butane_bluez) delegates here; you only depend on this package directly for non-Flutter use.

Register the backend #

import 'package:butane_dart/butane_dart.dart';
import 'package:butane_dart_bluez/butane_dart_bluez.dart';

Future<void> main() async {
  ButanePlatformInterface.instance = ButaneDartBluez();
  final central = CentralManager(clientIdentifier: 'my-linux-cli');
  await for (final result in central.scan()) {
    print('${result.peripheral} ${result.rssi}');
  }
}

Requirements #

  • Linux with BlueZ ≥ 5 and a powered adapter.
  • D-Bus system-bus access for the running user.

License #

MIT — see LICENSE.

0
likes
140
points
48
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

Pure-Dart BlueZ/D-Bus backend for butane_dart (no Flutter).

Homepage
Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

bluez, butane_dart, dbus

More

Packages that depend on butane_dart_bluez