This object is in archive! 

Live tracking not working in Locus Pro 2.8.7

tibor.jamecny shared this problem 11 years ago
Solved

On 5.2.2012 I updated Locus to the version 2.8.7. I`m using Live tracking function with freemap.sk as a backend server. My last position reported by the server is dated to 4.2.2012, which was done using older version of Locus. Since then, my position is not updated using Locus, despite the fact, that I`m using Locus daily.


When I manually (using Firefox on smartphone) request the tracking URL http://dev.freemap.sk/?lat=...&lon=.....=... , then my position reported by the server is correct:


ID Zariadenia75


IMEI (Sedenie)censored


Meno zariadeniaMiMiNoSGS2


Pozícia49.15164 / 18.68002


~ Pod studničky


Posl.záznam09.02.13 10:39


Rýchlosť0 km/h


Smer0


Statusmanualny test


09.02.13 10:39


So it must be a problem in Locus itself.

Replies (9)

photo
0

Hi Tibor


After a (first short) test, i can not confirm.

photo
0

Hello gynta,


still doesn`t work for me :(


Today, before the bike journey, I did:


1) started Locus


2) switched off automatic start of Live tracking (profile "freemap.sk")


3) stopped the running Live tracking (profile "freemap.sk")


4) terminated the Locus app


After a minute:


1) started Locus


2) opened window with Live tracking profiles


3) selected "freemap.sk" profile


4) window with the settings for this profile opened, but when I tap at the green "Play" icon, nothing happened (just the button selection changed, so my touch was registered by the Locus app). Usually the settings window is closed (in portrait mode), and I see the list of the profiles, where one profile is using red font => the active one.


5) while still in the settings window, I activated the "debug" function


6) afterwards it was possible to activate the profile "freemap.sk", and Live tracking was started (I saw the icon in the notification area).


7) after 10 minutes I got a beep, so Locus was aware of the fact, that it cannot send the request to the backend server.


After two beeps (about 20 minutes), I stopped the Live tracking profile "freemap.sk", made a copy of Live tracking profile to "freemap1.sk" (using built-in function "copy to"), added a slash at the end of the URL (http://dev.freemap.sk/), changed upload interval to 30seconds and activated (without any problem) this new profile. After 5 minutes, I got another beep, so this new profile was also not working.


When I try wget:


===========================================================


$ LC_ALL=C wget --server-response "http://dev.freemap.sk/?c=uls/loc&lat=..." -O -


--2013-02-10 15:38:23-- http://dev.freemap.sk/?c=uls/loc&lat=...


Resolving dev.freemap.sk (dev.freemap.sk)... 92.240.244.41


Connecting to dev.freemap.sk (dev.freemap.sk)|92.240.244.41|:80... connected.


HTTP request sent, awaiting response...


HTTP/1.0 200 OK


Date: Sun, 10 Feb 2013 14:38:23 GMT


Set-Cookie: PHPSESSID=o47784oh2udslm0f1tnosliia7; path=/; HttpOnly


Expires: Thu, 19 Nov 1981 08:52:00 GMT


Pragma: no-cache


Vary: User-Agent,Accept-Encoding


Content-Length: 0


Content-Type: text/html; charset=utf-8


Connection: keep-alive


Length: 0 [text/html]


Saving to: `STDOUT`


[ ] 0 --.-K/s in 0s


2013-02-10 15:38:23 (0.00 B/s) - written to stdout [0/0]


===========================================================


Then the backend server reports (see "test wget 2" + time):


===========================================================


ID Zariadenia75


IMEI (Sedenie)censored


Meno zariadeniaMiMiNoSGS2


Pozícia49.05164 / 18.58002


~ Kardošova Vieska


Posl.záznam10.02.13 15:38


Rýchlosť207 km/h


Smer180


Statustest wget 2


10.02.13 15:38


===========================================================


I will try to setup the Google Docs as "backend server" as you have described in the wiki, and test this profile tomorrow morning while driving to the work.

photo
0

If you want, you can also testing here: http://forum.locusmap.eu/viewtopic.ph...


let me know

photo
0

Alternative with the Google Docs works perfectly. It seems, that the existing Live tracking profiles are somehow corrupted. I willl create a new profile and try, if it works with freemap.sk or not.

photo
0

Is there any special characters in your string (url) or in any of your Var fields?

photo
0

Just one of the paremeter is "c = uls/loc" (in URL: "...&c=uls/loc&...."). But it was working before I upgraded to the version 2.8.7.

photo
0

Hello Tibore,


there should be only a one problem. Before update I had also some problems with updates over live tracking on gynta server. And I found in application that I wasn`t encoding url for request. So if I remember correctly, since 2.8.7, all parameters are encoded in UTF-8. Should this be a problem? Btw. you`re using GET or POST method?

photo
0

Hello Menion,


please check the UTF-8 conversion, it seems to me, that it is performed twice. This is output from wireshark:


=====================


GET /?lat=49.25147&lon=18.78025&alt=462.4&speed=0.3&...censored...&c=uls%252Floc&status=som%2Bv%2Bpohybe%2B1 HTTP/1.1rn


Accept-Charset: ISO-8859-2, utf-8rn


Accept-Encoding: gzip,deflatern


User-Agent: Locus/2.8.7 (Linux; U; Android; en-us)rn


Host: dev.freemap.skrn


Connection: Keep-Alivern


rn


=====================


1st conversion: / => %2f


2nd conversion % => %25


result: %252f


Also in the variable "status" should be %20 (space) and not %2b ("+" sign).


I hope, that now it is possible to fix the bug :)


Thank you and gynta for your support.


T.

photo
0

I damn, I`m stupid. ... I was looking on it few days ago and my though was "hmm, this is weird, I forget to encode result ... OK, so fix it" ... and here is result. In another function just before sending request I did it twice now. Thank you for perfect help. In next version if will be OK!

Replies have been locked on this page!