Skip to content

shinyorg/kmlrecorder

Repository files navigation

Shiny KML Recorder

Shiny KML Recorder

A .NET MAUI mobile application for iOS and Android that records GPS coordinates and exports them as KML or GeoJSON files. Track your trips with check-in/check-out sessions, monitor battery and GPS data, and deliver exports via email, Azure Blob Storage, system share, or local storage. Also supports Apple CarPlay and Android Auto for hands-free recording control.

Features

GPS Tracking

  • Real-time GPS listening with high-accuracy requests via Shiny.Locations
  • Records latitude, longitude, accuracy, speed (m/s & km/h), and timestamp for each reading
  • Android foreground service notification keeps recording active in the background

Trip Management

  • Check-in starts a new trip session (generates a unique WorkId)
  • Check-out ends the current session
  • All GPS pings are grouped by trip
  • Export filtering by individual trip or all trips at once
  • Trip labels display start time, end time, and point count

Export Formats

  • KML 2.2 — Document structure with styled point placemarks (circle icons, labels) and a track LineString showing the route. Point descriptions include accuracy, speed, battery level, and timestamp.
  • GeoJSON — FeatureCollection with Point features and a LineString track. Properties include timestamp, accuracy, speed, battery level, battery status, and energy saver state.

Export Delivery Methods

  • Local — Save the exported file to the device
  • Email — Attach the file to an email using the platform email service
  • Share — Open the system share dialog
  • Azure Blob Storage — Upload via PUT request with a SAS token (auto-detects content type)

Battery & System Monitoring

  • Tracks battery level, charge state (Charging / Discharging / Not Charging / Full / Unknown), and energy saver status alongside every GPS reading
  • GPS permission status displayed on the main screen

Settings Persistence

  • Selected trip, export format, delivery method, Azure credentials, and email settings are saved to app preferences and persist across restarts

CarPlay & Android Auto

  • Apple CarPlay — Grid template with a Start/Stop recording button; updates live as recording state changes
  • Android Auto — Pane template with a Start/Stop action button via AndroidX Car App library

iOS Home Screen Widget

  • Interactive medium widget — Displays current tracking status (Recording / Stopped) with elapsed time
  • One-tap toggle — Start or stop a recording session directly from the home screen
  • State shared between the app and widget via App Groups (group.org.shinylib.kmlrecorder)
  • Widget timeline automatically refreshes when tracking state changes

Android Home Screen Widget

  • Medium widget — Displays current tracking status (Recording / Stopped) with elapsed time
  • One-tap toggle — Tap the play/pause button to open the app and toggle tracking
  • Widget automatically refreshes when tracking state changes

Apple Watch Companion App

  • Native SwiftUI watchOS app — Shows current tracking status with elapsed time
  • Check In / Check Out button — Toggle tracking directly from your wrist
  • Communicates with iPhone app in real-time via WatchConnectivity
  • Status updates pushed automatically when tracking state changes on the phone

Pages

Page Description
Main GPS recording control — Check-in / Check-out toggle, session status, GPS permission state, navigation to Logs & Settings
Logs Displays all recorded GPS points with timestamps, coordinates, accuracy, battery level, and energy saver status
Export Shows GPS point count, export status summary, Export Now button, and Open Export Folder
Export Settings Configure trip selection, export format (KML / GeoJSON), delivery method, Azure Blob credentials, and email settings; includes a Reset option

Third-Party Libraries

Package Version Description Documentation
CommunityToolkit.Mvvm 8.4.0 MVVM source generators and helpers ([ObservableProperty], [RelayCommand]) Docs
Microsoft.Maui.Controls 10.0.30 .NET MAUI UI framework Docs
Microsoft.Extensions.Logging.Debug 10.0.0 Debug output logging provider Docs
Sentry.Maui 6.1.0 Error tracking and performance monitoring Docs
Shiny.Hosting.Maui 4.0.0-beta-0095 Shiny platform hosting for MAUI Docs
Shiny.Locations 4.0.0-beta-0095 GPS manager, readings, and location requests Docs
Shiny.Maui.Shell 2.0.0 Shell navigation and source-generated route mapping Docs
Shiny.Extensions.DependencyInjection 1.3.1 Attribute-driven DI registration with source generators Docs
Shiny.Reflector 1.7.1 AOT-compliant source-generated reflection utilities Docs
sqlite-net-pcl 1.10.196-beta Lightweight SQLite ORM for .NET Docs
SQLitePCLRaw.bundle_e_sqlite3 3.0.2 Native SQLite provider (Android) Docs
Xamarin.AndroidX.Car.App.App 1.7.0.2 Android Auto Car App UI library Docs
Xamarin.AndroidX.Lifecycle.LiveData.Core 2.10.0.1 AndroidX lifecycle-aware LiveData components Docs

Platform Requirements

  • iOS: iOS 16.0+
  • Android: API 26+ (Android 8.0)
  • watchOS: watchOS 10.0+
  • App ID: org.shiny.kmlrecord

CarPlay Setup

  1. Enable the Driving Task CarPlay capability for your App ID (org.shiny.kmlrecord) in the Apple Developer Portal
  2. The project includes CarPlaySceneDelegate and the required Info.plist scene manifest configuration
  3. Custom entitlements for com.apple.developer.carplay-driving-task are set in the .csproj

iOS Widget Setup

  1. Enable the App Groups capability for your App ID in the Apple Developer Portal and add group.org.shinylib.kmlrecorder
  2. The widget extension is a native Swift/SwiftUI project located in WidgetExtension/
  3. The .csproj includes MSBuild targets that build the widget extension and bundle it automatically during iOS builds
  4. The widget uses the kmlrecorder://toggle URL scheme to open the app and toggle tracking

watchOS App Setup

  1. The watchOS companion app is a native SwiftUI project located in WatchApp/
  2. The .csproj includes an MSBuild target that builds the watchOS app during iOS builds
  3. The iPhone app starts a WCSession in the AppDelegate to handle messages from the watch
  4. The watch app bundle identifier must be org.shiny.kmlrecorder.watchapp with companion app identifier org.shiny.kmlrecorder

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Contributors