servicesList property
Get services
- returns empty if discoverServices() has not been called or if your device does not have any services (rare)
Implementation
List<BluetoothService> get servicesList {
BmDiscoverServicesResult? result = FlutterBluePlus._knownServices[remoteId];
if (result == null) {
return [];
} else {
return result.services
.map((p) => BluetoothService.fromProto(p))
.where((p) => p.isPrimary)
.toList();
}
}