2

I try to make a Raspberry Pi 3B+ act as a BLE peripheral.

I downloaded latest version (5.50) of bluez stack here : https://git.kernel.org/pub/scm/bluetooth/bluez.git. I execute provided examples in /test/ directory.

When I run "example-advertisement" and "example-gatt-server" under root with python 2.7 or python 3.5, I can see the new BLE peripheral with Linux Mint, Win10, IOS and Android devices. However, although Linux, IOS and Win10 succeed in connecting and retrieving services and characteristics list, Android (4.4, 5.1 or 7.0) can't connect to the device.

I saw this topic : Bluetooth low energy gatt services not found on Android but I'm not using my own app for the moment. Even various BLE scanning applications we can find on Play Store don't manage to connect and retrieve service list.

Do someone have an idea ?

Thanks.

1

"Android" is a broad family of devices, each with different BT hardware and drivers, and as a result with different behavior and quirks. If you own a device from a major brand, searching or asking about this specific device will bring more relevant results than just searching or asking about "Andoroid 7.0".

Having said that, there is a couple of generic things you can try:

  • Disable WiFi while doing BT. A lot of BT problems come from radio interference between the two wireless protocols, or from the buggy dual-function radios unable to share a single antenna between WiFi and BT.

  • Collect btsnoop_hci.log as described here and check it for obvious anomalies. The firs thing I would try to understand is what protocols are able to get through between the Android device and the RPi.

  • Thank you for your anwser. I tested with various Android devices (4 phones and a tablet) so it's not device specific. Disabling the Wi-Fi doesn't help. I will try to get the log file you're talking about. – fdamien12 Jun 27 '19 at 14:08
  • @fdamien12 Meanwhile, have you seen this question? – Dmitry Grigoryev Jun 27 '19 at 14:10
  • Yes but it's not UART related : i just tried with another single board computer (Variscite DART-6UL, variscite.com/product/system-on-module-som/cortex-a7/…) and I get exactly the same behavior. – fdamien12 Jun 27 '19 at 14:38
0

For those who are interested in this issue, I give additional information here : https://superuser.com/questions/1453894/bluez-in-ble-peripheral-mode-android-cant-retrieve-services-list-ok-with-iph/1455666 but I give up, I didn't managed to get everything working.

Thanks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.