getSerialNumberString method

Future<String?> getSerialNumberString({
  1. int max = 256,
})

Implementation

Future<String?> getSerialNumberString({int max = 256}) async {
  String? res = null;

  using((Arena arena) {
    var buffer = allocateWString(max, allocator: arena);
    int ret = _getSerialNumberString(this._device, buffer, max);
    if(ret == 0) { res = fromWString(buffer); }
  });

  return res;
}