简体   繁体   English

获取BLE IOS外围设备的UUID,而不是服务UUID

[英]Get UUID of BLE IOS Peripheral, not service UUID

how is it possible to fetch the UUID from Peripheral side. 如何从外围设备端获取UUID。 Not the service UUIDs out of the advertising package. 不是广告包装中的服务UUID。

Lets see it from the central side: 让我们从中央看:

- (void)centralManager:(CBCentralManager *)central
 didDiscoverPeripheral:(CBPeripheral *)peripheral
     advertisementData:(NSDictionary *)advertisementData
                  RSSI:(NSNumber *)RSSI

What I need is the UUID out of peripheral.identifier , not the ones included in the advertisementData . 我需要的是UUID出peripheral.identifier ,不包括的那些advertisementData I can fetch them from the central side, but I need to do this also from the peripheral side. 我可以从中央获取它们,但是我也需要从外围获取。

I don't think there is a way do get UUID from CBPeripheralManager side. 我认为没有办法从CBPeripheralManager端获取UUID。

Since this UUID is hard coded in Bluetooth chip,and people barely change their iPhone's Bluetooth chip,this method would be used to track down user ,which is versus to Apple's intend. 由于此UUID在蓝牙芯片中进行了硬编码,并且人们几乎不需要更换iPhone的蓝牙芯片,因此该方法将用于跟踪用户,这与Apple的意图相反。

Apple banned UDID in iOS 5,banned MAC address in iOS 6. 苹果在iOS 5中禁止UDID,在iOS 6中禁止MAC地址。

So there is no reason Apple gave you access to Bluetooth UUID when Apple add CBPeripheralManager in iOS 6. 因此,当苹果在iOS 6中添加CBPeripheralManager时,苹果没有理由让您访问蓝牙UUID。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM