[英]Is it possible to transfer data between two BLE devices?
I want to use a BLE dongle on my Mac/PC and use the serial port to send numeric data to an app that I developed on my Nexus 7. 我想在Mac / PC上使用BLE加密狗,并使用串行端口将数字数据发送到在Nexus 7上开发的应用程序。
Is this possible? 这可能吗?
I assume they are both central so it wont work? 我认为他们都是中心,所以行不通吗? Do I need a third BLE device? 我需要第三个BLE设备吗?
Yes, it is possible for sending and receiving short pieces of data known as "attributes" over a BLE link. 是的,可以通过BLE链接发送和接收称为“属性”的短数据。 All current Low Energy application profiles are based on GATT. 当前所有的低能耗应用程序配置文件均基于GATT。
Your Mac and your Nexus are both dual mode devices, meaning they can act as both central and peripheral. Mac和Nexus均为双模式设备,这意味着它们既可以用作中央设备,也可以用作外围设备。 You can set your Nexus 7 as a peripheral, advertise from it, and then connect to it through your Mac which is acting as a central. 您可以将Nexus 7设置为外围设备,从中进行宣传,然后通过充当中央设备的Mac与之连接。 Once the connection is established your Nexus 7 can host a GATT server and your Mac can perform GATT client operations to read/write data. 建立连接后,您的Nexus 7就可以托管GATT服务器,而Mac可以执行GATT客户端操作来读取/写入数据。
There is a relevant question here:- Is it possible to connect iOS and android device using Bluetooth? 这里有一个相关的问题:- 是否可以通过蓝牙连接iOS和Android设备?
I hope this helps. 我希望这有帮助。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.