Skip to content

About

An Android app in Java for recording and reviewing GPS trails with Google Maps, Fused Location Provider, and SQLite.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

14 Commits

Folders and files

Repository files navigation

Android Trail Tracker

An Android app for recording and reviewing GPS trails with Google Maps and local storage.

Overview

Android Trail Tracker is a Java application that records location points during a trail, stores them locally, and displays saved routes on a map. A trail and its points are stored as related records in SQLite.

Features

  • Record location updates with the Fused Location Provider
  • Display recorded routes with the Google Maps SDK
  • Store trails and their location points in SQLite
  • Review, rename, and delete saved trails
  • Show distance, duration, and speed information
  • Switch between map display modes

Tech Stack

  • Java and Android
  • Google Maps SDK
  • Fused Location Provider
  • SQLite
  • Android Views, Material Components, and Gradle

Getting Started

  1. Install Android Studio and open this repository.
  2. Allow Gradle to sync the project.
  3. Create a Google Maps API key with the Maps SDK for Android enabled.
  4. Add the key to the root local.properties file:
    MAPS_API_KEY=your_key_here
    This file is ignored by Git. Do not commit a real key; restrict it to the Android app and Maps SDK for Android.
  5. Run the app on an emulator with Google Play services or on a compatible Android device.

The project includes the Gradle wrapper (gradlew and gradlew.bat).

Permissions

The app requests fine and coarse location permissions. Trail recording depends on the user granting location access and enabling device location services.

Data Model

  • Trilha stores trail metadata such as name, start and end times, speed, and distance.
  • PontoTrilha stores latitude, longitude, and timestamp values associated with a trail.
  • TrilhaDBHelper manages the SQLite database and the one-to-many relationship between trails and points.

Tests

The repository contains Android Studio starter tests under app/src/test/ and an instrumented database migration test under app/src/androidTest/. The migration test upgrades a version 1 database and checks that trails and points are preserved, lookup indexes are created, and deleting a trail removes its points.

Run the instrumented tests on a connected Android device or emulator with ./gradlew connectedDebugAndroidTest (or gradlew.bat connectedDebugAndroidTest on Windows).

Current Limitations

  • The Maps API key must be configured locally.
  • Route recording and map interactions do not yet have automated end-to-end coverage.

Project Status and License

This is a personal academic project, not a commercial product. No license has been specified.

Author

Anísio Oliveira (@Lugarty)

About

An Android app in Java for recording and reviewing GPS trails with Google Maps, Fused Location Provider, and SQLite.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages