Reputation: 133
I have a requirement where I'm building an app for iOS and Android (currently in React Native) where I want to look for BLE devices in the background and based on the BLE Beacon encounter I'll call some APIs in the background.
Right now, my solution is more iOS-focused because I know if I get it working for iOS, Android will not be much of a problem.
For background scanning in the iOS, I need to specify the UUIDs (Going to keep UUIDs same accross all BLE devices) in the app so it knows what to look for.
Now the problem is I need to uniquely iddentify each beacon so I know where the user is. The corrosponding information for that beacon would be in our database (location, name of place, etc). I can not find an approporiate way to store such unique IDs in my beacon that I can get without a connection. I know there is some bits available to store custom information in advertising channel but I'm unable to find a practical example for it.
Someone suggested to store such infomration in the device name but I think it's not reliable and anyone can change it.
My questions would be is it actually possible to store such custom information? If yes, then how can I do that so it stays there even if I reset the device.
Upvotes: 8
Views: 124