简体   繁体   English

Android (Things) GATT 服务器停止广告

[英]Android (Things) GATT server stops advertising

I'm developing an Android Things app (Dev Preview 6.1, Raspberry Pi) with a GATT server.我正在使用 GATT 服务器开发 Android Things 应用程序(Dev Preview 6.1,Raspberry Pi)。 When a connected client app disconnects, my device has stopped advertising.当连接的客户端应用程序断开连接时,我的设备已停止投放广告。 However, the custom client app (out of my control) is written in such a way that it needs to disconnect between reads/writes, then reconnect.但是,自定义客户端应用程序(不受我控制)的编写方式需要在读取/写入之间断开连接,然后重新连接。

I know that I can restart advertising upon disconnect, but since it has a new (pseudo-)MAC address, the client can't automatically reconnect.我知道我可以在断开连接时重新启动广告,但由于它有一个新的(伪)MAC 地址,客户端无法自动重新连接。

FWIW, I see the same behavior in this sample (& using nRF Connect as a test clinet):https://github.com/androidthings/sample-bluetooth-le-gattserver FWIW,我在此示例中看到了相同的行为(并使用 nRF Connect 作为测试客户端):https ://github.com/androidthings/sample-bluetooth-le-gattserver

Is there way to keep the GATT server advertising in this case?在这种情况下,有没有办法让 GATT 服务器保持广告? Or can I specify the advertised device address so that I can keep it consistent across advertisements?或者我可以指定广告的设备地址,以便我可以在广告中保持一致?

事实证明这是 Android Things 中的一个已知错误: https : //issuetracker.google.com/issues/70269277

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM