Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/111.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在运行时确定iOS设备是否支持蓝牙_Ios_Core Bluetooth - Fatal编程技术网

如何在运行时确定iOS设备是否支持蓝牙

如何在运行时确定iOS设备是否支持蓝牙,ios,core-bluetooth,Ios,Core Bluetooth,确定iOS设备是否支持蓝牙的正确方法是什么。有没有办法通过CoreBluetooth查询这个问题,或者您需要检查iOS版本和硬件ID才能找到答案。后者似乎不太可能,因为苹果不喜欢这些方法。是的,只需设置您的CBCentralManagerDelegate并等待centralmanagerdipdatestate:回调。如果状态为CBCentralManagerStateUnsupported,则当前设备不支持ble CBCentralManager状态不受支持->平台不支持 蓝牙低能耗中央/客户

确定iOS设备是否支持蓝牙的正确方法是什么。有没有办法通过CoreBluetooth查询这个问题,或者您需要检查iOS版本和硬件ID才能找到答案。后者似乎不太可能,因为苹果不喜欢这些方法。

是的,只需设置您的
CBCentralManagerDelegate
并等待
centralmanagerdipdatestate:
回调。如果状态为
CBCentralManagerStateUnsupported
,则当前设备不支持ble

CBCentralManager状态不受支持->平台不支持 蓝牙低能耗中央/客户端角色