带蓝牙的基于接近度的遥控钥匙安全设备:它是如何工作的

发布于 2024-12-10 10:50:49 字数 519 浏览 0 评论 0原文

我一直在阅读有关通过蓝牙的近距离安全设备的信息,但我想知道它在现实中是如何工作的。据我所读,有两种技术:

  1. 来自大师的持续扫描。中央设备每x分钟扫描一次目标设备。当目标进入范围时,它会返回 MAC 蓝牙地址和 RSSI。不利的一面是,不断进入可发现模式会耗尽电池电量,主设备也必须不断扫描设备。

  2. 已配对并连接。正如一些产品细节所示:“当您离开一定距离时,您的笔记本电脑会自行锁定,并在您进入范围后再次打开”。这意味着在配对和连接过程之后,当从设备超出范围或再次进入范围时,主设备可以获得信息。在蓝牙 4 中,将作为配置文件。

对于第二个选项,这是哪个功能?它是如何运作的?我的意思是,也许你可以编写一个序列号计数器,每次从机每x毫秒(android或ios)通过RFCOMM发送一个数据包时进行计数,但我不明白的是,当从机如何以透明的方式再次连接到主机时通常,两个蓝牙设备在超出彼此范围时会断开连接(因此您无法从同一蓝牙套接字 RFCOMM 连接再次发送信息)。

接近设备在现实中如何工作?你如何编码?

i have been reading about proximity security devices through bluetooth, but i am wondering how it works in reality. As far as i have been reading, there are two techniques:

  1. constant scanning from a master. The central device scans the target device every x minutes. When the target is into range, it gives back MAC bluetooth address and RSSI. The negative side is that being constantly into discoverable mode drains the battery, so does the master device that has to be constantly scanning for devices.

  2. Paired and connected. As some product details: "Your laptop locks itself down when you step a certain distance away, and opens again once you're in range". It means that after paring and connected processes, the master can have information when the slave device is out of range, or get inside range again. In bluetooth 4, is going to be even as a profile.

Regarding to the second option, which feature is this? how it works? i mean, maybe you can code a sequence number counter that counts everytime the slave sends a packet through RFCOMM every x milisecs (android or ios), but what i dont understand is how a slave can connect to master again in a transparent way, when normally two bluetooth devices disconnect when they are out of range each other (so you cant send information again from the same bluetooth socket RFCOMM connection).

How proximity devices works in reality? how can you code it?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

我也只是我 2024-12-17 10:50:49

蓝牙 4.0(BT 低功耗)与传统蓝牙完全不同。它是从头开始设计的,适合您描述的邻近配置文件等功能。基本上,计算机和遥控钥匙会创建一个连接,以较慢的间隔(例如每 5 秒一次)定期进行通信。当您超出范围时,连接会因超时而断开,并且 PC 知道密钥丢失了。 PC 端不受功率限制,因此当连接断开时,它可以持续或定期扫描密钥卡。遥控钥匙可以使用不频繁的广告数据包来广告其存在,这仅消耗少量的电力。

请注意,BT LE 中没有 RFCOMM。 Android 和其他 BT 堆栈目前缺乏 BT LE 支持,因为它太新了。只有少数设备实际使用 BT LE,因此目前很难获得大量真实信息。几年后,这个数字将会更大。新款 iPhone 4S 和新款 MacBook 配备了 4.0 BT 芯片,因此您很快就会得到更多使用。

Bluetooth 4.0 (BT Low Energy) is a whole other animal than traditional Bluetooth. It is designed from the ground up to be good at things like the Proximity profile you describe. Basically a computer and a fob create a connection to periodically communicate at a slow interval, say once every 5 seconds. When you go out of range the connection drops due to a timeout and the PC knows the fob is gone. The PC side isn't power constrained, so it can constantly or periodically scan for the fob when connections are dropped. The fob can advertise its presence using infrequent advertisement packets, which costs only a small amount of power.

Note that there is no RFCOMM in BT LE. Android and other BT stacks currently lack BT LE support because it is too new. Only a few devices exist which actually use BT LE, so getting much real info is hard right now. In a few years this will be much bigger. The new iPhone 4S and new macbooks have the 4.0 BT chips, so you can expect more usage soon.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文