BLEScan not returning beacon name.

davettl
Posts: 1
Joined: Wed Jul 10, 2019 12:35 pm

BLEScan not returning beacon name.

Postby davettl » Wed Jul 10, 2019 12:45 pm

  1. class MyAdvertisedDeviceCallbacks : public BLEAdvertisedDeviceCallbacks
  2. {
  3.     void onResult(BLEAdvertisedDevice advertisedDevice)
  4.     {
  5.         printf("Name %s, Address %s, RSSI %d\n", advertisedDevice.getName().c_str(), advertisedDevice.getAddress().toString().c_str(), advertisedDevice.getRSSI());
  6.         //data = json.createNestedArray("dat");
  7.     }
  8. };
advertisedDevice.getName().c_str() returns an empty string after the first time a iBeacon is received. The beacon does have a name and my phone test app receives the name without any problems. advertisedDevice.toString().c_str() also omits the name. All other info is returned correctly

ytan86
Posts: 1
Joined: Thu Aug 15, 2019 3:02 am

Re: BLEScan not returning beacon name.

Postby ytan86 » Thu Aug 15, 2019 3:20 am

I suspect that I am facing the same problem. I am using SampleAsyncScan.cpp by nkolban, and the scan only returns BLE module information in the first scan, and not subsequent ones.

Issue mentioned here: https://github.com/nkolban/esp32-snippe ... -521498490

Who is online

Users browsing this forum: No registered users and 4 guests