Skip to content
This repository has been archived by the owner on Nov 2, 2018. It is now read-only.

Not clear how to enable location tracking #28

Open
brantje opened this issue Sep 9, 2014 · 12 comments
Open

Not clear how to enable location tracking #28

brantje opened this issue Sep 9, 2014 · 12 comments

Comments

@brantje
Copy link
Contributor

brantje commented Sep 9, 2014

Now, it is not clear how an user can enable device tracking.
We might add an ? icon in the 'Location tracking settings' popup.
What do you think @jancborchardt

@jancborchardt
Copy link
Contributor

Yup, including a link to GPSlogger / OSMand as well. (and something for iOS)

@brantje
Copy link
Contributor Author

brantje commented Sep 9, 2014

For iOS, i have no clue. Don't have an iphone, neither have friends.
So that needs to come from someone who has.

@dgeo
Copy link

dgeo commented Nov 10, 2014

What is the URL to use ?

@DJaeger
Copy link
Contributor

DJaeger commented Jun 2, 2015

Have looked at the source code and it seems to be for OsmAnd:

http://YourAddressToOwnCloud/index.php/apps/maps/api/1.0/location/update?hash=YourDeviceHash&lat={0}&lon={1}&timestamp={2}&hdop={3}&altitude={4}&speed={5}

You have to change YourAddressToOwnCloud to somethink like example.com/owncloud
and YourDeviceHash to the Hash you generated from the gear-menu in the maps-app.

I will test it on the way to home.

@DJaeger
Copy link
Contributor

DJaeger commented Jun 5, 2015

I have created an PR to fix an issue with Osmand: #40
With that it should work like expected and the above mentioned adress.

For GPSLogger you can use the following working address:
http://YourAddressToOwnCloud/index.php/apps/maps/api/1.0/location/update?hash=YourDeviceHash&lat=%LAT&lon=%LON&timestamp=%TIME&hdop=%ACC&altitude=%ALT&speed=%SPD

Also here:
You have to change YourAddressToOwnCloud to somethink like example.com/owncloud
and YourDeviceHash to the Hash you generated from the gear-menu in the maps-app.

@DJaeger
Copy link
Contributor

DJaeger commented Jun 5, 2015

Just to know:
For GPSLogger to use with this feature you need the current version, that is not available in F-Droid.
It works with location services at hight and low accuracy and also in the background (only background service and app closed).

Osmand works also with the current version from F-Droid.
But it requires one of the folloing scenarios to work:

  • run in foreground (app open) with location services using WLAN, Cells and/or GPS
  • run in the background (only background service and app closed) but only if GPS is activated

@jas4711
Copy link

jas4711 commented Aug 11, 2015

There is a new app called "Self-Hosted GPS Tracker" in F-Droid that appears to be able to do the right thing -- use this as the URL:

https://foo.example.org/owncloud/index.php/apps/maps/api/1.0/location/update?hash=YourDeviceHash

and it will append the lat=LAT&lon=LON string.

However the app will send start/stop pings to that URL which ends up in the database as NULL values for lat/long. Not ideal, but close.

@DJaeger
Copy link
Contributor

DJaeger commented Aug 11, 2015

I have seen this app too and have the check, how to work with this, on my todo.
I also want to create some kind of documentation for location tracking.

@clinique
Copy link

Is maps reputed to work with the current 8.2.1 ? I currently can not manage to define devices (they are created but table populated with null values) neither to successfully call /location/update URL.

@DJaeger
Copy link
Contributor

DJaeger commented Dec 15, 2015

I have now looked into "Self-Hosted GPS Tracker".
It is not able to submit hdop, altitude and speed, so they would stay empty.
The timestamp is also only submitted with param "t".

@clinique:
I have not checked with 8.2.1 until now.
Which version of the maps app do you use?
Which app with which version do you use to submit the location?

@clinique
Copy link

@DJaeger : I took the master version on GitHub. I'm using Owntracks along with a custom node-red to HTTP Get on maps api - but with no success. I tried directly the URL in a browser, this gives me an error stating "to many redirections". I also have errors in owncloud :

{"reqId":"RDN3OPgktV0DealUL5jl","remoteAddr":"81.61.137.133","app":"PHP","message":"Undefined index: ADR at /usr/share/owncloud/apps/maps/controller/pagecontroller.php#111","level":3,"time":"2015-12-14T08:25:34+00:00"}
{"reqId":"RDN3OPgktV0DealUL5jl","remoteAddr":"81.61.137.133","app":"PHP","message":"Attempt to assign property of non-object at /usr/share/owncloud/apps/maps/controller/pagecontroller.php#195","level":3,"time":"2015-12-14T08:25:34+00:00"}

@jancborchardt
Copy link
Contributor

Setting to 0.2 for now. :) Anyone is welcome to work on this and improve the Maps app

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants