question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Scanning with Nexus 5x Bluetooth 4.2 failed

See original GitHub issue

Hi,

I’m trying to scan using a central Nexus 5x using this wonderful library, but in vain. No peripheral is detected.

The same app is working fine with phone like OnePlus One or Honor 5x. Using Sniffator or nRF Connect for Mobile on this Nexus, the peripheral is detected and discovered successfully.

I 've set LogLevel to Verbose, but I got any help.

Is there something known related with Bluetooth 4.2 or with Nexus 5x ? Is Sniffator using react-native-ble-plx or RxAndroidBle directly ? How can I get some more debug to investigate this issue ? I’m still using 0.6.3. Is there any hope that something goes better with 0.6.4 ? Any help would be greatly appreciated.

Thanks in advance. JeanClaude

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
jchirschycommented, Dec 1, 2017

Hello,

Finally, my Nexus 5 discovered successfully a test peripheral (Nordic). It seems to be related to Android Manifest which was not good enough for a pure Android stack : Enabling location was not necessary with other centrals I was using before (my bad).

Having modified Android Manifest, I was facing some weird caching issues apparently. Even an adb kill-server was not enough. Rebooting Mac and Nexus 5x, cleaning, rebuilding and enabling location was the right recipe.

I will try with the peripheral used in production next week. You’re awesome guys with your support…

0reactions
Cierpliwycommented, Nov 30, 2017

I found Nexus 5X in Polidea (Android 8.0.0):

I tested 3 options: manager.startDeviceScan(null, null, ...) - works as expected manager.startDeviceScan([""00e2f93e-3066-4e44-a1fc-83389d174d07""], null,...) - works as expected (16bit UUID) manager.startDeviceScan(["8e0f"], null, ...) - works as expected (128 bit UUID)

I didn’t test for 16bit UUIDs as we don’t have advertising devices with this type of UUID.

Before scanning by services make sure that your device really advertises them. They should be visible in device.serviceUUIDs property. If you can’t find them here but you are sure they should be present, please send me your raw advertisement data:

  • in react-native-ble-plx library go to android/src/main/java/com/polidea/reactnativeble/BleModule.java
  • put breakpoint in line 278 (for version 0.6.5)
  • send me value of rxBleScanResult.getScanRecord() of your device.
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Fix Bluetooth Pairing Problems - Techlicious
1. Make sure Bluetooth is turned on · 2. Determine which pairing process your device employs · 3. Turn on discoverable mode ·...
Read more >
Bluetooth crashes after sometime and never recovers (doing ...
Have your device do BLE scanning in an environment with few beacons transmitting BLE packets. Nexus 5 device will not be able to...
Read more >
ble.scan not working on Nexus 5 · Issue #232 - GitHub
I'm scanning without specify service UUID. I'm passing an empty array as parameter in scan calling. My code looks like this: $cordovaBLE.scan([] ...
Read more >
Android BLE scanning not parsing ScanRecord on some ...
My problem is the that on some devices the ScanResult.getDevice() or ScanResult.getScanRecord() both return null on some Android devices but ...
Read more >
Top 6 Ways to Fix Unable to Remove Bluetooth Device on ...
1. Try Removing Device in Airplane Mode · 2. Run Bluetooth Troubleshooter · 3. Check Windows Services · 4. Use Control Panel ·...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found