@override Future<bool> stopScan() async { var res = await methodChannel.invokeMethod<bool>("stopDiscovery"); if (_deviceDiscoveryStream != null) { _deviceDiscoveryStream = null; } return res!; }