universal_bluetooth_classic library
A Flutter plugin for discovering, pairing, and managing Bluetooth Classic accessories, Bluetooth HID devices, and Apple External Accessory sessions.
Use the UniversalBluetooth class as the single entry point for all platforms.
Classes
- AndroidSdpConfig
- The Bluetooth SDP record used to register the Android HID device app.
- BluetoothConnectionEvent
- Describes a connection state change of a Bluetooth device.
- BluetoothDevice
- A discovered or paired Bluetooth device.
- EAAccessory
- MacSdpConfig
- The Bluetooth SDP record published by the macOS host.
- ReportReply
- SdpConfig
- Platform-specific configuration for UniversalBluetooth.setupSdp.
- UniversalBluetooth
- The main API for discovering, pairing, and connecting to Bluetooth Classic accessories and Apple External Accessory devices.
- UniversalBluetoothCallbacks
- The inbound events a UniversalBluetoothInterface implementation reports.
- UniversalBluetoothInterface
- Platform interface for UniversalBluetooth.
Enums
- BluetoothConnectionSource
- The source that triggered a connection state change.
- BluetoothConnectionState
- The connection state of a Bluetooth device.
- BluetoothTransport
- The Bluetooth Classic transport used to reach a device.
- DeviceClass
- The class of a Bluetooth device.
- DeviceType
- The type of a Bluetooth device.
- ReportType
Constants
- sppServiceUuid → const String
- The well-known Serial Port Profile (SPP) service UUID.
Typedefs
- BluetoothDeviceCallback = void Function(BluetoothDevice device)
- Callback for device discovery and removal events.
- ConnectionChangeCallback = void Function(BluetoothConnectionEvent event)
- Callback for connection state changes.
- DataCallback = void Function(String identifier, Uint8List data)
- Callback for data received from a connected device.
- GetReportCallback = ReportReply? Function(String deviceId, ReportType type, int bufferSize)
- Callback for HID get-report requests.
- SdpServiceRegistrationUpdateCallback = void Function(bool registered)
- Callback for SDP service registration status changes.