Minimum GPS trip / tracker #278

Closed
opened 2019-12-28 19:15:30 +01:00 by swentel · 8 comments
swentel commented 2019-12-28 19:15:30 +01:00 (Migrated from github.com)

Add a minimum tracker

  • a tracker menu item (configurable in settings to enable it), menu item is called 'GPS tracker'
  • clicking on it lists the tracks which were saved
  • a 'start track' button (like the 'write new post' button) to start a new tracker with some settings
    • name of the track
    • poll every x seconds/minute(s) with a minimum of 30 seconds, max 5 minutes?
  • when started, it goes into background, with a menu item action to stop tracking
  • tracks are stored in a local db
  • tracks can then be send to an endpoint, auto delete when posted (configurable, if not auto delete, a dedicated local delete button)
    • http method = POST
    • probably json, seems more convenient (even though form encoded would work as well, but it would have to be numeric arrays)
    • endpoint:
      • micropub: h=track, name for the title of the track and 'points' is an array of lat/lon or GeoUri's? authentication is just like any other micropub call (would be new proposal for extension, or do we have something like this already?) https://indieweb.org/trip is a good startpoint too.
      • custom configurable endpoint ? not sure about authentication
        • support for both should be relatively easy
  • nice to have: draw a saved track on a map

Looking at https://indieweb.org/trip , the trip post kind can probably be used.

@dshanske feedback/suggestions welcome! I'm going to work on this the whole week as I've got more or less nothing else to do :)
@kisik21 feedback welcome as well - I don't necessarily want to write a competitor of your thing, I want something myself like this as well, but, important, start out minimal!

Add a minimum tracker - a tracker menu item (configurable in settings to enable it), menu item is called 'GPS tracker' - clicking on it lists the tracks which were saved - a 'start track' button (like the 'write new post' button) to start a new tracker with some settings - name of the track - poll every x seconds/minute(s) with a minimum of 30 seconds, max 5 minutes? - when started, it goes into background, with a menu item action to stop tracking - tracks are stored in a local db - tracks can then be send to an endpoint, auto delete when posted (configurable, if not auto delete, a dedicated local delete button) - http method = POST - probably json, seems more convenient (even though form encoded would work as well, but it would have to be numeric arrays) - endpoint: - micropub: h=track, name for the title of the track and 'points' is an array of lat/lon or GeoUri's? authentication is just like any other micropub call (would be new proposal for extension, or do we have something like this already?) https://indieweb.org/trip is a good startpoint too. - custom configurable endpoint ? not sure about authentication - support for both should be relatively easy - nice to have: draw a saved track on a map Looking at https://indieweb.org/trip , the trip post kind can probably be used. @dshanske feedback/suggestions welcome! I'm going to work on this the whole week as I've got more or less nothing else to do :) @kisik21 feedback welcome as well - I don't necessarily want to write a competitor of your thing, I want something myself like this as well, but, important, start out minimal!
dshanske commented 2019-12-28 20:22:56 +01:00 (Migrated from github.com)

How about a geouri for each point?

How about a geouri for each point?
dshanske commented 2019-12-28 21:06:39 +01:00 (Migrated from github.com)

Also, ability to feed in data from alternate sources.. something you know I do... could you do this by intent? So my same tasker code could trigger this?

Also, ability to feed in data from alternate sources.. something you know I do... could you do this by intent? So my same tasker code could trigger this?
swentel commented 2019-12-28 21:22:49 +01:00 (Migrated from github.com)

so,

  • the array (in summary renamed to 'points') would be just a list of geouri's? Works for me as I have a parser for it already in Drupal, and I guess you too. A form encoded post could still work then, but I'd make the arrays numeric so the order can be easily determined.

Regarding feed: what exactly does the tasker code do? Does it send points? Would it trigger starting a new trip?

I also added 'name' to the summary for the title of the track/trip.

so, - the array (in summary renamed to 'points') would be just a list of geouri's? Works for me as I have a parser for it already in Drupal, and I guess you too. A form encoded post could still work then, but I'd make the arrays numeric so the order can be easily determined. Regarding feed: what exactly does the tasker code do? Does it send points? Would it trigger starting a new trip? I also added 'name' to the summary for the title of the track/trip.
dshanske commented 2019-12-28 21:38:44 +01:00 (Migrated from github.com)

It converts locations derived from airplane wifi to the compass API format.. https://github.com/aaronpk/compass

It converts locations derived from airplane wifi to the compass API format.. https://github.com/aaronpk/compass
swentel commented 2019-12-29 12:55:58 +01:00 (Migrated from github.com)

Stumbled upon https://indieweb.org/trip , that probably makes more sense in terms of properties. I almost have the logger ready in the app, will try out a first post after it.

Stumbled upon https://indieweb.org/trip , that probably makes more sense in terms of properties. I almost have the logger ready in the app, will try out a first post after it.
vikanezrimaya commented 2019-12-29 14:42:59 +01:00 (Migrated from github.com)

if gapps are installed you can use Google Play's Location services to get a function called back when device receives location data, this could save budget phone owners like me some juice.

if gapps are installed you can use Google Play's Location services to get a function called back when device receives location data, this could save budget phone owners like me some juice.
swentel commented 2019-12-30 20:52:38 +01:00 (Migrated from github.com)

First trip done, see https://twitter.com/swentel/status/1211734731391406081
Currently posts to the micropub endpoint: name and route ( = array of geo uri's)

Next up

  • better defaults and a nicer route preview (althought that's still nice to have).
  • more properties from the trip proposal (https://indieweb.org/trip).
  • will expand probably with content images too (because why not, I have that anyway)

Uses any provider enabled on the phone (wifi, cell, gps - depending on what's enabled at that moment, but at least one should be available of course).

First trip done, see https://twitter.com/swentel/status/1211734731391406081 Currently posts to the micropub endpoint: name and route ( = array of geo uri's) Next up - better defaults and a nicer route preview (althought that's still nice to have). - more properties from the trip proposal (https://indieweb.org/trip). - will expand probably with content images too (because why not, I have that anyway) Uses any provider enabled on the phone (wifi, cell, gps - depending on what's enabled at that moment, but at least one should be available of course).
swentel commented 2020-01-06 12:12:57 +01:00 (Migrated from github.com)

pushed in a release, please read https://github.com/swentel/indigenous-android/issues/282 carefully for bugs or improvements

pushed in a release, please read https://github.com/swentel/indigenous-android/issues/282 carefully for bugs or improvements
This discussion has been locked. Commenting is limited to contributors.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
inhji/indiepass-android#278
No description provided.