GPS tracking in Background - Trick



  • Hello,

    As you know to track your activity there is the application Activity Tracker : https://open-store.io/app/activitytracker.cwayne18
    Unfortunately due to the Utouch security policy, GPS signal is not accessible when the screen is off or app is in background, that why the original developer force the screen to stay on, reducing significantly the battery life with no benefit.
    Issue is tracked there : https://github.com/ubports/ubuntu-touch/issues/1067

    In order to extend life of the phone for some long activities, i've made a wrapper of the test_gps command.
    It requires to be launched from a terminal with it "Prevent app suspension" activated in Tweak app.

    The GPS Utouch tracker is available there : https://framagit.org/ernesst/gps-utouch-tracker, still not polished yet.
    Just download the folder, place it somewhere in your homefolder.
    To start it, go to the folder and launch it with sudo ./GPS_tracking.py

    It will start to track your activity, to stop it just go back to the terminal and hit the virtual key "Ctrl+c" and it will create a gpx file.

    To visualize this file, you can import it in Activity Tracker.

    Enjoy.



  • @ernest So you mean this script will run even when the screen is locked and closed?
    If yes, then this is really cool and I would definitely try it.
    It would be cool if it works with some kinda of a UI so you can still check from time to time your location in the map 😉



  • @kugiigi yes it does, screen off and or terminal in background


Log in to reply