Locus Map - forum

Content & Tools => Add-ons => Topic started by: ville_sml on October 27, 2012, 21:16:16

Title: GpsTrace
Post by: ville_sml on October 27, 2012, 21:16:16
I have created a new addon for locus - GpsTrace
https://play.google.com/store/apps/deta ... race4locus (https://play.google.com/store/apps/details?id=com.vsy.gpstrace4locus)
It works currently with gps transmitters. Addon enables to show transmitter position on locus. Addon sends sms to transmitter to query its location. Returning SMS is parsed and the transmitter location is updated on map.

Addon runs as a service on background, so locations of gps transmitters can be updated automatically.

The addon currently supports
Xexun tk-102 (tk-102 clone) gps transmitter
MPTP (old benefon sms protocol) gps transmitter
SMS send from locus
also addon can emulate MPTP gps transmitter.

Futher development include
OpenGts support over http and
pick gps transmitter phonenumber from contacts.
Title: Re: AddOn - GpsTrace
Post by: gynta on October 27, 2012, 21:30:11
slowly!  :)

- My dog has one of this transmitters on his pet collar.
- Locus send a SMS to my dog
- the transmitter send a SMS to my mobile
- Locus show me the position of my dog on the map.

right??
Title: Re: AddOn - GpsTrace
Post by: ville_sml on October 27, 2012, 21:38:49
That's correct, well atleast almost:

- Your dog has one of this transmitters on his pet collar.
- GpsTrace send a SMS to my dog
- the transmitter send a SMS to my mobile
- GpsTrace catches(if valid location sms) the incoming SMS and parse it
- Locus shows the position of your dog on the map.

GpsTrace can also act as gps transmitter, so you can attach your second phone to your dog's collar.
Hopefully in near future opengts support, so you can follow your dog without need to send SMS. Instead use internet connection.
Title: Re: AddOn - GpsTrace
Post by: gynta on October 27, 2012, 21:42:30
Quote from: "ville_sml"
- Your dog has one of this transmitters on his pet collar.
- GpsTrace send a SMS to my dog
hm, It will not take care of your dog - hehe
you mean my little puppy (If I had such)

anyway
nice
So i have to correct my translation now...  :mrgreen:
Title: Re: AddOn - GpsTrace
Post by: durian on October 28, 2012, 08:16:47
Quote from: "ville_sml"
GpsTrace can also act as gps transmitter, so you can attach your second phone to your dog's collar.
So I can use it to send my position from Locus to my telephone? Cool, than I can use it like the "Live Tracking" when there is no data connection available. I have an old telephone connected to an old Linux computer with "gammu" which can read the received SMSs and put them on a website or something.

-peter

edit: hmm, I guess I misunderstood? I thought the addon could send position periodically per SMS, but it looks I was wrong?
Title: Re: AddOn - GpsTrace
Post by: ville_sml on October 29, 2012, 07:55:10
Quote from: "durian"
edit: hmm, I guess I misunderstood? I thought the addon could send position periodically per SMS, but it looks I was wrong?

If you need automatic position send trough SMS, I can easily add this functionality to gps transmitter emulator code (approx. 5 lines of code).
Currently position can be polled by sending SMS to phone.
Title: Re: AddOn - GpsTrace
Post by: durian on October 29, 2012, 09:52:08
Quote from: "ville_sml"
If you need automatic position send trough SMS, I can easily add this functionality to gps transmitter emulator code (approx. 5 lines of code). Currently position can be polled by sending SMS to phone.
That would be cool!

-peter
Title: Re: AddOn - GpsTrace
Post by: nIgel on October 30, 2012, 12:48:31
Nice one. I made something like that for myself with Tasker, since my handicapped son likes to disappear. Is Leadtek 8m03 (ftp://ftp.leadtek.com.tw/gps/8m03/8M03_(A (http://ftp://ftp.leadtek.com.tw/gps/8m03/8M03_(A))E(generic)_UserManual02.pdf) supported?
(
Triggerword: where
Answer=nmea sequence like:$GPMRC,130700.094,A,A,4832.5933,N;00930.7490,E,1.58,124.38,201012,,,A*68
)
Title: Re: AddOn - GpsTrace
Post by: ville_sml on October 31, 2012, 15:58:34
Quote
Nice one. I made something like that for myself with Tasker, since my handicapped son likes to disappear. Is Leadtek 8m03 (ftp://ftp.leadtek.com.tw/gps/8m03/8M03_(A (http://ftp://ftp.leadtek.com.tw/gps/8m03/8M03_(A))E(generic)_UserManual02.pdf) supported?
(
Triggerword: where
Answer=nmea sequence like:$GPMRC,130700.094,A,A,4832.5933,N;00930.7490,E,1.58,124.38,201012,,,A*68
)

Test this version with leadtek 8m03, hopefully it works out of box.
This version also has MPTP emulator push support (for durian)
Title: Re: AddOn - GpsTrace
Post by: durian on October 31, 2012, 17:34:39
Quote from: "ville_sml"
Test this version with leadtek 8m03, hopefully it works out of box.
This version also has MPTP emulator push support (for durian)
Thanks! But I think I need a manual :-) not sure how set all the settings,

edit: maybe this is "spoiling" your add-on a bit, and it should be added to the normal live-tracking.

-peter
Title: Re: AddOn - GpsTrace
Post by: nIgel on November 02, 2012, 12:35:24
Thanks but maybe I'm too stupid to get this working.
My anticipation:
GPStrace4locus will send an SMS with: "where" without (") to the tracker.
How do i do that
I added a provider Leadtek 8m03 and set it on.
Questions:
1) Do I need to enable service and why.
2) Periodic Update sends periodic sms (only if service is enabled)?
3) Pull versus OK, what happens
4) How do I get that program to send the sms?
Title: Re: AddOn - GpsTrace
Post by: ville_sml on November 05, 2012, 08:44:02
Quote
1) Do I need to enable service and why.
2) Periodic Update sends periodic sms (only if service is enabled)?
3) Pull versus OK, what happens
4) How do I get that program to send the sms?


Ok. I really should start to write an user manual for this.
But anyhow, here is small guide to use it.

1) Enable service must be on. This way the will register itself as a service and stay alive. Also when the service is enabled the application can receive incoming SMS, otherwise it cannot catch any SMS.
2) Periodic update is used to get SMS update from gps device without user interaction.  In case of Leadtek when periodic update is used it will send "where" to gps transmitter at defined intervals.
3) Pull will send query sms, eg "where" to device, OK normally does nothing.
   But the execptions for OK button are:
    Service enabled and received gps locations in memory
    -> Locus start and show gps locations in locus
    And if you have locus running:
    Service enabled
    ok -> show received gps locations in locus
    Service disabled
     ok -> remove received gps locations in locus

4) - Create Leadtek device in settings.
    - Enable service
    - Press Pull
    - Wait for incoming gps location from leadtek
    - press OK

There is also one setting in preferences, Auto Send, if this is enabled. When locus is running the app will automatically show any incoming GPS Location in Locus.

edit
So is the leadtek protocol working?
Title: Re: AddOn - GpsTrace
Post by: nIgel on November 07, 2012, 11:29:23
Sorry had no time to look. Tested it now.
The coords are  about 13000km off.
Since I don't see the sms GPSTrace is analyzing I'm not sure what the error is.
In Locus it gives me as coords:
N3252°28.800 E 195°39.360
I send you a PM.
Title: Re: AddOn - GpsTrace
Post by: ville_sml on November 07, 2012, 15:03:56
Quote
The coords are about 13000km off.
Since I don't see the sms GPSTrace is analyzing I'm not sure what the error is.
In Locus it gives me as coords:
N3252°28.800 E 195°39.360

I fixed the problem, my mistake, I multiplied minutes by 60, when I should have divided.

Try this, it should work, I you can, test also the SOS button. It should show SOS next to name.
Title: Re: AddOn - GpsTrace
Post by: nIgel on November 07, 2012, 16:26:22
Thank You for that quick fix, now it is working fine!

I would suggest:
1) to give some more status messages, otherwise the user is confused about what GPSTrace4Locus is doing and is sending multiple sms to the locator (like I did):
After pressing pull:
Status message: sending sms to ...
                         waiting for sms from ...
2) During the waiting time but not longer than lets say 2min block the pull button to avoid that very impatient user get a bigger phonebill than necessary.
Title: Re: GpsTrace
Post by: Gorkde on January 19, 2014, 11:44:15
Hello,
I did try this Addon with my friend. I got an Galaxy S4, he an Desire Hd. I got the full Locus he the trial one.
Neither of the units is sending any SMS at all.
I did set up the Locus SMS receiver with each others number and activated it.
I did try to auto send and also manually pull.
What are we doing wrong?
Also I Do not really understand all options. There is a time to set up for auto pulling and there is (in the settings) another time Intervall as well as GPS distance. How do all of these work together?
And what are the SMS receiver besides Locus for?
From what I understand you can send from Locus to Locus as well.
Anyway while sending the App could never know if the SMS receiver is a GPS or mobile phone, therefore it should at least send ANY SMS, which it doesn't do!
Title: Re: GpsTrace
Post by: ville_sml on January 20, 2014, 19:25:28
Manual is needed, I grant you that.

If you want to send location from Locus to Locus Here what you need to do:

Open settings -> providers
Press [MENU] -> New

(1. Device that sends SMS: )
-Select MPTP sms emultor (Emulates gps transmitter)
-Name the provider (any will do)
-set the phone number of the other device
-[MENU]->Save

(2. Device that receives SMS: )
-Select MPTP SMS
-Name the provider (any will do)
- Set type (icon of the point displayed)
-set the phone number of the other device
-leave periodic support unchecked (emulator does not support)
-[MENU]->Save

Goto Main screen

Set enabled on both phones.
Pressing Pull on device 2. will send LOC? sms to device 1.
Device 1 responds with location data sms.

I discovered last week that the the locus SMS receiver is suffering unicode syndrom. It will not probably parse the sms sent from locus directly, as the format was "N DD°MM.MM' | E DD°MM.MM'". Problem is the degree symbol support varies between different devices. Next version will be better.

MPTP is Benefon Mobile Phone Telematics Protocol, quite well supported.

edit
I'm writing (slowly) a new version.
Suggestions and beta testers are welcome.

Title: Re: GpsTrace
Post by: Gorkde on January 20, 2014, 21:00:38
Yes, a manual is really needed

1) So if I understand correctly normally I would use Locus SMS Receiver but can't at the moment since it has a bug?

1a) I assume there must be another bug besides the parsing one you discovered since mine did not even try to send any SMS.

2) Is the setup you suggest working both ways? So if I set up both units that way, will both be able to pull each others location? That would be what I need.

3) The options in the settings where you can specify a time and a distance:
3a) Are they for auto-sending once time/moving distance has passed?
3b) Will they work with your suggested setup above?

4) OK, it seems I did now understand the auto-sending option in the settings (other than the 2 GPS ones below).
It means the gpstrace4locus App will "auto-send the received Coordinate to the Locus App on the same device" correct?
If so you should rename that so one can understand this. For example "Locus update interval" or similar.
I did assume this is something about auto-sending of the SMS to the other device.

5) did just try to setup as suggested but I can not enter any name for the Emulator. Seems to be a bug.

I can help testing in case you need some testing maybe.

Bzw. I would recommend clarifying the options by adding a help button to each screen instead writing a manual.

*** Mobil gesendet ***
Title: Re: GpsTrace
Post by: ville_sml on January 21, 2014, 17:07:38
1) If the locus sms receiver would work, then it would be possible to send location from locus by using share feature.

1a) The locusSMS is receive only

2) Setup should both ways, however the app can still leave the sms into inbox. It was not actually designed to work both ways,

3) In preferences the options are for internal gps, how often the gps on the phone should try to get location from satellites.
3a) No, they limit only how aggressive is the gps chip.
3b) The periodic uptate on main screen will to automatic updates on certain intervals. It is limited to 20 updates.

4) Auto send is very poorly named, I'm sorry for that. Most of the strings I have written were first in Finnish -> translated to English. It should say: Automatically show received points in Locus (No notification of received point).

5) Probably a bug. I will try to put a beta version to here, where is most of the bugs are fixed.

Title: Re: GpsTrace
Post by: Gorkde on February 09, 2014, 09:33:04
Hello,

Just did test your suggested setup. It's working both ways BUT:

1) You should add a timeout for sending SMS of for example 20 seconds where if you click Pull again he opens a Window like "SMS already sent, waiting for response, do you really want to send another? YES/NO-Button

2) My received Coordinate are 66.4 km east of where the other really is. So there should be a coordinate bug.


*** Mobil gesendet ***

Title: Re: GpsTrace
Post by: ville_sml on February 23, 2014, 15:33:16
Hello

I did some work and here is beta version of new gpstrace. There has been some major changes, so this version is beta. If you see any issues, please give me feedback.

Most important changes:
Fixed Unicode issue.
Fixed MPTP emulator coordinate offset.
Change to new locus api.

Title: Re: GpsTrace
Post by: Gorkde on February 23, 2014, 17:17:38
Thanks, will try soon, I met my buddy today, so it will probably take a week now. Will give you feedback asap.
Do We need to set it up as before or can Locus provider be used now?

*** Mobil gesendet ***

Title: Re: GpsTrace
Post by: ville_sml on February 23, 2014, 18:00:54
You can try both. The locus sms receiver should now also work.
Title: Re: GpsTrace
Post by: Gorkde on February 23, 2014, 18:25:11
OK, thx

*** Mobil gesendet ***

Title: Re: GpsTrace
Post by: gynta on February 23, 2014, 18:41:22
If you see any issues, please give me feedback.

about http://forum.locusmap.eu/index.php?topic=2498.msg26325#msg26325 : imiss updated "how to"

because there is no "new" in new apk

new apk / google play
(http://s29.postimg.org/nwrsvwfxf/new.jpg) (http://postimg.org/image/nwrsvwfxf/)   (http://s29.postimg.org/5v8ny3lwj/play.jpg) (http://postimg.org/image/5v8ny3lwj/)
Title: Re: GpsTrace
Post by: Gorkde on February 23, 2014, 18:57:59
Just did a quick test, I saw him about 100m east of his correct position, but this might be because incorrect GPS data. Need to test once he is here next week.

edit
That is just a prerelease as far as I know to allow us to use it until the final bugs are fixed
Title: Re: GpsTrace
Post by: ville_sml on February 23, 2014, 19:08:28
True. Release will be made to google play.

Here is the updated manual:


Press [MENU]-> providers
Press [MENU] -> New

(1. Device that sends SMS: )
-Select MPTP sms emultor (Emulates gps transmitter)
-Name the provider (any will do)
-set the phone number of the other device
-[MENU]->Save

(2. Device that receives SMS: )
-Select MPTP SMS
-Name the provider (any will do)
- Set type (icon of the point displayed)
-set the phone number of the other device
-leave periodic support unchecked (emulator does not support)
-[MENU]->Save
Title: Re: GpsTrace
Post by: gynta on February 23, 2014, 19:49:59
Here is the updated manual:
...
Press [MENU] -> New...
"there IS NO "New"
Title: Re: GpsTrace
Post by: ville_sml on February 23, 2014, 19:57:42
The button in upright bar are [points] [messages]
Messaging functionality is still under development.

Original function:

Open settings -> providers
Press [MENU] -> New

New version:

Press [MENU]-> providers
Press [MENU] -> New

In order to create new provider:
Press phones menu button in main screen to invoke menu in lower part of screen.
From there select Providers.
Title: Re: GpsTrace
Post by: Gorkde on February 23, 2014, 20:23:42
There is a new button but you have to press the phones menu button once the little Window is open. Took me some time to find that as well.

Bzw...  Do I have to press show each time now? Is the data not submitted to Locus automatically?

*** Mobil gesendet ***

Title: Re: GpsTrace
Post by: ta-ka on February 24, 2014, 14:22:15
Thank you for the beta version. I report an issue on Locus SMS receiver.
The first image shows a coordinate on device A and it was sent to device B by SMS.
The second image shows the location shown by Gpstrace4Locus on device B.
Looking at coordinate, longitude and latitude are opposite (not exactly).

(http://s29.postimg.org/nx2n6qk6r/device_a.jpg) (http://postimg.org/image/nx2n6qk6r/)(http://s12.postimg.org/b3eh9qm09/device_b.jpg) (http://postimg.org/image/b3eh9qm09/)
Title: Re: GpsTrace
Post by: gynta on February 24, 2014, 22:24:20
Here is the updated manual:
...
(1. Device that sends SMS: )
...
(2. Device that receives SMS: )

?ähem
both send AND receives SMS

pull:
Dev1 ask(send) SMS to Dev2 (Dev2 receive from Dev1) - Dev2 answered (send) SMS (so Dev1 receive from Dev2)

confused ;)
Title: Re: GpsTrace
Post by: ville_sml on March 02, 2014, 18:38:50
Here is newer version of gpstrace

Fixed the locus sms, Had the lat lon inverted.
Now you can also pick the number from contacts.
Title: Re: GpsTrace
Post by: ta-ka on March 03, 2014, 18:36:21
Fixed the locus sms, Had the lat lon inverted.
Thank you for the fix. I confirmed it works fine now.

Quote
Now you can also pick the number from contacts.
This is good improvement. :)

I report small two problems about icons.
1) The size of side panel isons changes bigger.
   How to reproduce:
   - add Gpstrace4locus icons to side panel as shown in image1. Here, Icon size is good.
   - Main menu > More > scroll down until ADD-ONS are shown on display. Then, icons becomes bigger (image2).
2) As shown in the image3, icon's black and white color are opposite.

(http://s11.postimg.org/ugo95yj6n/image1.jpg) (http://postimg.org/image/ugo95yj6n/) (http://s18.postimg.org/it5gnk1ut/image2.jpg) (http://postimg.org/image/it5gnk1ut/) (http://s10.postimg.org/ej66nfrmt/image3.jpg) (http://postimg.org/image/ej66nfrmt/)
Title: Re: GpsTrace
Post by: menion on March 03, 2014, 18:41:02
issue 1) is on Locus side, I'll try to improve it
Title: Re: GpsTrace
Post by: ta-ka on March 03, 2014, 19:39:51
issue 1) is on Locus side, I'll try to improve it
Thanks!
Title: Re: GpsTrace
Post by: vldd on March 05, 2014, 11:45:44
I'm trying the latest beta with added HTTP support, but cannot get the coordinates to Locus.
I created a simple file on public accessible URL with .json extension with following content.
It's my first time experience with geoJSON file format, so I guess I'm doing something wrong.

Code: [Select]
{"type":"FeatureCollection",
    "features":[
        {"type":"Feature",
            "properties":{
                "type":"BluePin",
                "name":"Point_40",
                "time":1393756377,
                "id":"81""
                }
            ,"geometry":{
                "type":"Point",
                "coordinates":[23.022,40.00]
            }
        }
    ]
}
Title: Re: GpsTrace
Post by: ville_sml on March 16, 2014, 12:00:09
On the line:
Quote
"id":"81""
is one quote (") too many
Title: Re: GpsTrace
Post by: Gorkde on March 23, 2014, 10:08:12
Tried with latest version MPTP
My friend is still shown 1.1km east of where we bith are.

Must be still a bug there. Can you have a look?
(http://img.tapatalk.com/d/14/03/23/ryga4y6a.jpg)
Title: Re: GpsTrace
Post by: richard.malone on June 11, 2014, 20:16:16
Would it be possible to make our own device syntax?  For example I ordered a TK-102 online but instead a clone was delivered.  The only difference is that on this one the command to send positions is fix030s005n rather than t030s005n so it doesn't work with gpstrace - really annoying.

Great software otherwise, I love the emulator. 

Rich
Title: Re: GpsTrace
Post by: ville_sml on June 18, 2014, 16:30:46
I was already thinking of that. I will have to investigate how make it flexible. Maybe some xml file.

Title: Re: GpsTrace
Post by: spaul on October 01, 2014, 09:14:28
hello,
I beg you to excuse my English because I'm not an expert.
I am seriously interested in Locus, because I am a long distance runner and I would like my wife to have access to my real position on Locus.
Therefore I am interested in your addon.
The only problem is that I would jog lightweight and long with an old phone that does not have much memory. So I look for a solution that would pass only through the transmission of SMS. I tested MPTPInformer, but I get nowhere set.
Currently I use real time gps tracker, but it uses the 3G networks and other ...
Conntriez you an opportunity to have a sms ultra thin client that sends Locus?
Title: Re: GpsTrace
Post by: cnchip on March 21, 2015, 14:39:07
I was already thinking of that. I will have to investigate how make it flexible. Maybe some xml file.

This is a very great add-ons, thank you very much.
However no any update since last year ?
Because I can not use it .
(http://s14.postimg.org/y1vogmoe5/Screenshot_2015_03_21_21_28_10.jpg) (http://postimg.org/image/y1vogmoe5/)

This is 0.9.1
Thank you very much.
Title: Re: GpsTrace
Post by: ville_sml on March 23, 2015, 06:02:20
Hi cnchip

I will look into this and fix it. I have made some big changes, including full support for custom gps transmitters. (XML configuration of settings, query message and reply parsing)

Title: Re: GpsTrace
Post by: Gorkde on March 23, 2015, 07:00:54
I can't use it since years as well, since as I posted already the coordinates are off

At least when using as I did whith that sms sending
Title: Re: GpsTrace
Post by: alf on April 03, 2016, 11:16:51
Hello

Thanks for sharing this application.

I loaded it on my two phones, both running Locus Pro.

I tried to understand how to use one of the phones as SMS transmitter and the other one as the receiver of the positions sent by the first one.

I tried several of the options of GPSTrace with no success.

Is there any form of guide or manual describing how to achieve this ?

Thanks and regards