What profile can I use with CoreBluetooth?

…衆ロ難τιáo~ 提交于 2019-12-21 21:27:12

问题


I looking for informations about CoreBluetooth, I see iPhone4s/5 support Bluetooth 4.0 and Bluetooth LE.
Also, according to this note, I can use these profiles :

  1. Hands-Free Profile (HFP 1.6)
  2. Phone Book Access Profile (PBAP)
  3. Advanced Audio Distribution Profile (A2DP)
  4. Audio/Video Remote Control Profile (AVRCP 1.4)
  5. Personal Area Network Profile (PAN)
  6. Human Interface Device Profile (HID)
  7. Message Access Profile (MAP)

Can I have access to them using CoreBluetooth and, if so, how could I access to them ?


回答1:


You can't use any of the mentioned profiles if you want to communicate from the application. Core Bluetooth is meant for low energy,You can only implement GATT Profiles(like Heart Rate,Alert Notification) with BLE and BLE is for small data rates.You can only write or read characteristics to/from the device. In order to implement any of the mentioned profiles you require Serial Port Profile, which is supported only through MFi using External Accessory Framework.

GATT Profiles

http://developer.bluetooth.org/gatt/profiles/Pages/ProfilesHome.aspx

You can find External Accessory Framework documentation in the link below.

http://developer.apple.com/library/ios/#documentation/ExternalAccessory/Reference/ExternalAccessoryFrameworkReference/_index.html

MFi

https://developer.apple.com/programs/mfi/




回答2:


CoreBluetooth framework is for Bluetooth Low Energy. The note seems to be dealing with "classic" Bluetooth only (since you see "old" devices) . In that case, you'll have to use ExternalAccessory framework. Its two technologies quite different, as you could see by searching in Google or in different questions here in StackOverflow.
There is a sample from Apple dealing with ExternalAccessory framework : EADemo.



来源:https://stackoverflow.com/questions/13768599/what-profile-can-i-use-with-corebluetooth

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!