CoreBluetooth 和 BluetoothManager,设备不是 BLE [英] CoreBluetooth and BluetoothManager, device is not BLE

查看:24
本文介绍了CoreBluetooth 和 BluetoothManager,设备不是 BLE的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

通过蓝牙连接和接收数据.

Connect and receive data via bluetooth.

我们正在为客户开发应用.这是一款通过蓝牙连接的婴儿玩具,我们在连接和传输数据时遇到问题.

We are developing an app for a client. It is a toy for babies that connects via bluetooth and we're having trouble connecting and transferring data.

经过我们所做的所有研究,我们找到了两个替代方案:CoreBluetooth 和 BluetoothManager.据我所知,CoreBluetooth 仅与低功耗蓝牙连接(我认为它是最新的蓝牙版本),因此我无法找到我客户的设备.使用第二个选项,BluetoothManager 我可以找到设备,但我无法传输数据.

After all the research we did, we found two alternatives: CoreBluetooth and BluetoothManager. As far as I know CoreBluetooth only connects with Bluetooth Low Energy (I think it is the latest bluetooth version) and with it I am not able to find my client's device. With the second option, BluetoothManager i can find the device but I can not transfer data.

这让我觉得我的客户端设备不是 BLE.考虑到CoreBluetooth 无法定位设备而只有BluetoothManager 可以定位,有没有办法与此设备连接和传输数据?

This makes me think that my client device is not BLE. Is there any way to connect and transfer data with this device, considering that CoreBluetooth doesn't locate the device and only BluetoothManager does?

您能否提供替代方法和/或示例来说明如何进行这种交流?如果您做不到,请告诉我,以便告诉我的客户.

Could you please provide alternatives and/or examples of how to make this communication? And if you can not do, let me know in order to tell my client.

推荐答案

与低版本蓝牙通信需要使用 ExternalAccessory 框架,但它是针对 MFi 设备的,所以我猜你需要签署 Apple MFi Program:https://developer.apple.com/programs/mfi/

To communicate with lower versions of Bluetooth you need to use ExternalAccessory framework, but it is for MFi devices, so I guess you need to sign to Apple MFi Program: https://developer.apple.com/programs/mfi/

这个答案描述了在 iOS 上使用蓝牙的可能方法:https://stackoverflow.com/a/16852224/4495995

This answer describes possible ways of working with Bluetooth on iOS: https://stackoverflow.com/a/16852224/4495995

这篇关于CoreBluetooth 和 BluetoothManager,设备不是 BLE的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆