This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrf connect active scan

Hi guys,

I'm wondering how can I set in android app to perform active scanning? so that it sends out scanning requests?

Thank you!

BR, Matej

Parents
  • Hi,

    You just start scanning. If a scannable device is found Android will automatically send Scan Request, get Scan Response and will deliver the merged adv data + scan response to the app. Some phones do this only once per scan for each scannable device found during a single scan, so if you want in addition rssi updates, or the device changes data over time, you have to stop and start scan every ~2 sec. But those were old devices, like Nexus 4 or Nexus 7. Nowadays Android requests scan responses each time it receive the scannable advertising packet.

    BR, Aleksander

Reply
  • Hi,

    You just start scanning. If a scannable device is found Android will automatically send Scan Request, get Scan Response and will deliver the merged adv data + scan response to the app. Some phones do this only once per scan for each scannable device found during a single scan, so if you want in addition rssi updates, or the device changes data over time, you have to stop and start scan every ~2 sec. But those were old devices, like Nexus 4 or Nexus 7. Nowadays Android requests scan responses each time it receive the scannable advertising packet.

    BR, Aleksander

Children
No Data
Related