BleDevice class
- Available extensions
Constructors
Properties
-
connectionState
→ Future<
BleConnectionState> -
Returns connection state of the device.
All platforms will return
Connected/Disconnectedstates.AndroidandApplecan also returnConnecting/Disconnectingstates.no setter -
connectionStream
→ Stream<
bool> -
Available on BleDevice, provided by the BleDeviceExtension extension
A stream of bool that emits connection status changes for the device.no setter - deviceId ↔ String
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
-
isConnected
→ Future<
bool> -
Available on BleDevice, provided by the BleDeviceExtension extension
Checks if the device is currently connected.no setter - isSystemDevice ↔ bool?
-
getter/setter pair
- manufacturerData → Uint8List?
-
no setter
-
manufacturerDataList
↔ List<
ManufacturerData> -
getter/setter pair
- name ↔ String?
-
getter/setter pair
- paired ↔ bool?
-
getter/setter pair
-
pairingStateStream
→ Stream<
bool> -
Available on BleDevice, provided by the BleDeviceExtension extension
A stream of bool that emits pairing status changes for the device.no setter - rawName ↔ String?
-
getter/setter pair
- receivesAdvertisements → bool
-
On web, it returns true if the web browser supports receiving advertisements from this device.
The rest of the platforms will always return true.
no setter
- rssi ↔ int?
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
services
↔ List<
String> -
List of services advertised by the device.
getter/setter pair
Methods
-
connect(
) → Future< void> -
Available on BleDevice, provided by the BleDeviceExtension extension
Connects to the device. -
disconnect(
) → Future< void> -
Available on BleDevice, provided by the BleDeviceExtension extension
Disconnects from the device. -
discoverServices(
) → Future< List< BleService> > -
Available on BleDevice, provided by the BleDeviceExtension extension
Discovers the services offered by the device. -
getCharacteristic(
String characteristic, {required String service, bool preferCached = true}) → Future< BleCharacteristic> -
Available on BleDevice, provided by the BleDeviceExtension extension
Retrieves a specific characteristic from a service. -
getService(
String service, {bool preferCached = true}) → Future< BleService> -
Available on BleDevice, provided by the BleDeviceExtension extension
Retrieves a specific service. -
isPaired(
{BleCommand? pairingCommand, Duration? connectionTimeout}) → Future< bool?> -
Available on BleDevice, provided by the BleDeviceExtension extension
Check if a device is paired. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
pair(
{BleCommand? pairingCommand, Duration? connectionTimeout}) → Future< void> -
Available on BleDevice, provided by the BleDeviceExtension extension
Pair a device. -
requestMtu(
int expectedMtu) → Future< int> -
Available on BleDevice, provided by the BleDeviceExtension extension
Requests a specific MTU (Maximum Transmission Unit) size for the connection. -
toString(
) → String -
A string representation of this object.
override
-
unpair(
) → Future< void> -
Available on BleDevice, provided by the BleDeviceExtension extension
Unpair a device.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited