You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • Chances are you have so many advertising packets being received that it can't output the characters fast enough over BLE. Hence it not appearing to stop - it probably did stop but there was such a backlog it was taking ages.

    The sample code definitely does work, but just not if you have a lot of devices or devices that advertise quickly

    If you want to use setScan rather than findDevices, make sure you can handle the data fast enough - for instance by just writing everything into an array (arr[d.id]=d)

About

Avatar for Gordon @Gordon started