This is an Android application using Bluetooth low energy (BLE) beacons technology to provide proximity-based experiences for users.
Due to my interest in the "Internet of things" I decided to create this app usign Bluetooth 4.0 to detect nearby devices called Beacons. First of all, I got a Beacon device like this on Amazon. I used the software that was provided by the manufacturer to set it up.
A Beacon is a small device (approx 3cm x 5cm x 2cm) that constantly sends out radio signals to nearby smartphones and tablets, containing a small amount of data. Whilst beacons can have up to 70m range with no obstructions, this can drop significantly through walls which are made with metal or brick (though thin/stud walls have a much smaller effect). In addition to the potential range of BLE, most protocols also operate with three ranges of distance: far, near and immediate – and a device can do something different at each range.
As part of my Object Oriented Programming Assignment 3 for college I wanted to learn and demostrate how to code a more complex Android app using a programmable piece of hardware.
FindMe reminds you that you left something behind using a beacon that you can hang on you keychain or attach to things you think you might lose. Once you realize you lost something, you can use Bluetooth to help you locate them.
FindMe allows you to scan bluetooth devices and display the distance between your smartphone and the beacons. In order to show my understanding of how an Android app works using a Database I created a registration page and a login. Once you have logged in, you can track the beacons devices and find the one you own by its UUID. Each ibeacon has a set of identifying numbers. The UUID is a general device identifier. By clicking on your device you can see how far you are from it. This app calculates proximity based on the power level and signal strentgh of te beacon. If you enable the app to remind you when you are more than 10 meters away from you device FindMe will send a push notification to your mobile phone letting you know that you left something behind.
Programming this application involved mostly Java code and some xml. Most of the method used in this app are built-in Android's libraries. To use these methods properly you need to understand what they do and where to use them appropriately.
The application makes use of the Android Beacon Library (An Android library providing APIs to interact with Beacons). This Api makes it easier to communicate with BLE devices.
- Use of Android Libraries.
- Use of AltBeacons Library fro Android (Involved to learn this API documentation)
- Use of Online Database
- Forms validation (Login,Register)
- App Permissions: Internet connection and Bluetooth
- Use of extending classes and implementation of interfaces.
- Use of Bluetooth 4.0 technology
- Use of Relative Layout gives adaptability to different size screens.
- Use of the background thread to check Internet Connection.
- Use of handler to update UI items on the screen every 3 seconds.