蓝牙广播 [英] Bluetooth broadcasting

查看:213
本文介绍了蓝牙广播的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从使用蓝牙众多附近的设备一个设备广播数据。现在,我知道蓝牙广播存在,但使用Android的现有的API这可能吗?如果没有,是否有任何其他第三方提供的API在那里,它们能够呢?

I want to broadcast data from one device using Bluetooth to numerous nearby devices. Now, I know Bluetooth broadcasting exists, but is it possible using Android's existing API? If not, are there any other 3rd party APIs available out there which are capable of it?

有关蓝牙广播另一个问题:
你就可以开始听一个持续的广播并接收数据,即使你不听,因为广播已经开始?例如,让设备A是该广播,并且他超过5秒的过程中广播以下数据:

Another question regarding Bluetooth broadcasting: Can you start listening to an ongoing broadcast and receive data from it, even if you weren't listening since the broadcast has started? For example, let device A be the broadcaster, and he broadcasts the following data over the course of 5 seconds:

1 2 3 4 5 6 7 8 9 10

设备B在整个广播接收到的数据,他因此获得:

Device B received data throughout the entire broadcast, so he received:

1 2 3 4 5 6 7 8 9 10

器件C接收到开始听只有2秒后,当设备A正在播放 5 。他将获得其余的( 5 6 7 8 9 10 )如预期?

Device C received started listening only after 2 seconds, while device A was broadcasting 5. Will he receive the rest (5 6 7 8 9 10) as expected?

推荐答案

由于数据包没有蓝牙广播期间承认,对于以后出现,广播从节点(接收器)之间的主(发送方)没有区别并在那里从一开始,并没有收到任何报文从节点

As packets are not acknowledged during a Bluetooth broadcast, there is no distinction for the master (sender) between a slave node (receiver) that appears later in a broadcast and a slave node that was there from the beginning and didn't receive any packet.

所以,是的,装置C将从5如果蓝牙连接所有一般条件都满足,接收数据的新包了起来。

So, yes, the Device C will receive the new packets of data from 5 and up if all general conditions for a bluetooth link are met.

这篇关于蓝牙广播的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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