Github Example Project
This is an example project demonstrating how to use the Cintric Android SDK. You can also use this project to test the functionality of the Android SDK on your device.
This project will track you throughout the day and save location updates to a text file. You can then see everywhere you went on a map, and view the times that your location was updated.
Open the project from github and run it on your Android Device. You should see your current location appear on the map. Try leaving the example project on your phone for a couple days and see how well it works.Visit the GitHub project here.
Cintric SDK is an optimized Android Framework which tracks users locations in the background while using very little battery throughout the day.
Cintric's Android SDK can be integrated by following these steps:
- Create a Cintric developer account and get your SDK Key.
- Download the cintric.aar file and add it to your project as a module dependency
- Add google play services to your build.gradle
- Add your google play app id to your app's resources/values/strings.xml file
- Add the required code to your main activity, using your Cintric SDK Key and Secret.
Create a Cintric developer account and get your SDK Key
Head over to http://cintric.com/register and sign up. You can find your SDK Key and Secret under account settings.
Download the cintric.aar file and add it to your project as a module dependency.
Add the required code to your main activity, using your Cintric SDK Key and Secret.
To start Cintric, you must call:
Cintric.startCintricService(this, "YOUR-SDK-KEY", "YOUR-SECRET-KEY");
You should call this method in your Main Activity's
onCreate method. Or if you're targeting android 6.0+ call this method when you're ready to request location premissions.
If your app's targetSdkVersion is 23 or higher (Android 6.0), you must also implement this method:
Add google play services dependency to your app’s build.gradle file.
You also need appcompact dependency (which should be included by default).
If you have a gradle sync issue, make sure you are using the latest version of both google play and appcompact, or use the same version listed above.
Add your google play app id to your apps strings.xml file in the resources/values directory.
your-app-id with your google app id available at https://console.developers.google.com/
Optional: Location Callback
You can also implement
CintricEventHandler if you want callbacks for location updates.
The following code shows an example of a MainActivity which fully implements the Cintric SDK.
Some other things to note.
Minimum version for the AAR is Android API 14 (Ice Cream Sandwich).
Cintric will use the following permissions:
However, including these in your manifest is optional, because they will automatically be mereged in from the cintric.aar manifest file.
Cintric Android SDK 1.3.2
- Added function to sync a user custom id
Cintric Android SDK 1.3.0
- Bug fixes and optimizations
Cintric Android SDK 1.2.04
- Fixed a crash that may occur when not connected to a network
Cintric Android SDK 1.2.01
- Added Ad ID functionality
- Networking optimizations that prevent duplicate requests
Cintric Android SDK 1.1.04
- Improved Location Tracking
- Preformance Improvments
- Bug Fixs