Find Eddystone Beacons using Nearby Google API

孤街醉人 提交于 2019-11-29 12:46:52

Check the following...

  • Set a callback on the response to subscribe and call startResolutionForResult on the Status object if the Status was APP_NOT_OPTED_IN . See github example

  • Make sure you've enabled the Nearby API in the Developer Console for your app. Step 3 here

  • Use Strategy.BLE_ONLY in the call to subscribe

  • Finally, if none of these help, try a stand-alone BLE scanning app just to make sure the beacon is actually broadcasting.

If you want to post a more complete code sample, one of our engineers can take a look

(I work on the Nearby API)

Another idea: Make sure that the API key in your manifest is from the same Google Developers Console project that you used when you attached your data to the beacons. Beacon attachments are private to the project that created them.

Another suggestion for anyone else reading this question who is having problems connecting. Lifted from another answer:

This may sound like an odd thing - but try turning you wifi on and off. A lot of cheaper devices are really bad with bluetooth and fail to connect, but for some reason turning wifi off and on fixes it for a while.

I was having a similar problem - everything in my code was correct but not detecting beacons. I even tried with the manufacturers app, and theirs also couldn't detect the beacon (but their iPhone version did). I turned my wifi off, then back on again and the manufacturers app worked and so did mine.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!