isDeviceConnected method
检查设备是否已连接
Implementation
Future<bool> isDeviceConnected() async {
try {
final result = await _channel.invokeMethod<bool>('isDeviceConnected');
return result ?? false;
} on PlatformException {
return false;
}
}