The BLEvolve application Asset Beacon requires rock-solid unique identification in order to function. Believe it or not, unique identification is one of the most common stumbling points for engineers beginning to work with the StickNFind API. Below I will lay out some guidelines that we have found during the development of Asset Beacon that we circulate internally:
1. Forget about the “Name” field.
StickNFinds API provides a “Name” field, as part of the LeSnfDevice object (this represents a single tag, in code); However, there is (from what we can tell…) no way to change this using the API. D’oh! So what you should do is….
2. Start using the “User Data” fields
There are 3 User data fields exposed by the API. These can be wrote after a connection to the tag is made. Which reminds me…
3. Pay attention to what can be done after a “scan” and what requires a “connect”
If you aren’t familiar, for now all you need to know is that a scan typically will take longer than a connect. This can have serious consequences for how you architect your solution. It typically takes us (with low interference) a few seconds to scan a few hundred tags, while connecting to 100 tags reliably en masse – while something we have done when required – will cause a much longer delay.
4. You may want to have a visual indication of connection state to the tags included in your app
This is mostly useful for testing and tweaking performance of the app. It is also useful to give users a better idea of when they can ring (turn on the lights and musical chime), write, and read temp and battery data from the tags.
5. You will need to Connect to a tag to ring, write, and read temp and battery data
Weigh this together with what I said above regarding the time it takes to scan vs connect.
Thanks for reading, and best of luck. If you at any time need a world-class consultancy for (paid per-project/install or hourly) consulting, please do not hesitate to contact us at BLEvolve – we have staff on call to answer your inquiry.