readManufacturer method

Future<String> readManufacturer()

Implementation

Future<String> readManufacturer() async {
  final bleService = await getBleService();
  final manufacturerCharacteristic = bleService.characteristics.firstWhere(
    (char) => char.uuid.str == ViamBluetoothUUIDs.manufacturerUUID,
    orElse: () => throw Exception('manufacturerCharacteristic not found'),
  );

  final manufacturerBytes = await manufacturerCharacteristic.read();
  return utf8.decode(manufacturerBytes);
}