FORUMS
Remove All Ads from XDA

[APP][2.2+] Backitude - Server-side development

223 posts
Thanks Meter: 173
 
By backitude, Senior Member on 29th October 2013, 01:32 PM
Post Reply Email Thread
I am creating this thread to start an area for Backitude server side developers and for casual users looking to implement their own flavor of location history or Google Latitude, to come and chat, ask questions, and get information.

Backitude is an android application that allows users to track their device locations in a highly configurable and continuous manner. Location data can be stored locally as (KML, CSV) or posted to a custom server. Anyone can create their own server implementation for storing or sharing location data.

Currently, three users are sharing their implementations:
http://backitude.ascanwex.de/ ([email protected])
-and-
https://bitbucket.org/nparley/mylatitude/wiki/Home ([email protected])
-and-
http://www.backituders.com ([email protected])

Let me know if more exist you would like me to add to the list!
The Following 2 Users Say Thank You to backitude For This Useful Post: [ View ] Gift backitude Ad-Free
 
 
29th October 2013, 04:43 PM |#2  
Member
Flag Aarhus
Thanks Meter: 4
 
More
Quick hack for using Traccar as backend
Hi,

If you want to use Traccar as the backend, then you can quickly implement a server side fix in PHP that converts the HTTP POST from Backitude to the required HTTP GET request OsmAnd style that Traccar expects.

Requirements:
- HTTP server with PHP

Place a backitude.php file with this content on your Traccar server:
PHP Code:
<?                                                                                                                                                          
                                                                                                                                                            
$data
=$_POST;                                                                                                                                               
array_walk($data create_function('&$v,$k''$v = $k."=".$v ;'));                                                                                          
$url='http://127.0.0.1:5055?'.implode("&",$data);                                                                                                           
$response file_get_contents($url);.                                                                                                                       
echo 
"200 OK\n";                                                                                                                                            
                                                                                                                                                            
?>
Replace 127.0.0.1 with your Traccar server, if it's located on another host than the one you put the PHP code in.

Configure Backitude like this:

Server URL: http://<yourserveraddress>/backitude.php
Successfull response code: 200
Authentication: none
Custom field1: <enter your imei or the ID youre using in Traccar>
Latitude: lat
Longitude: lon
Accuracy: hdop
Speed: speed
Altitude: altitude
Direction Bearing: bearing
Location Timestamp (UTC): timestamp
TimeZone Offset: do not post/empty
Custom Field 1: id

Works for me! Thanks a lot for Backitude - the Traccar client is not nearly as reliable or battery friendly as Backitude.
30th October 2013, 07:29 PM |#3  
OP Senior Member
Thanks Meter: 173
 
More
Quote:
Originally Posted by wire103

Hi,

If you want to use Traccar as the backend, then you can quickly implement a server side fix in PHP that converts the HTTP POST from Backitude to the required HTTP GET request OsmAnd style that Traccar expects.

Requirements:
- HTTP server with PHP

Place a backitude.php file with this content on your Traccar server:

PHP Code:
<?                                                                                                                                                          
                                                                                                                                                            
$data
=$_POST;                                                                                                                                               
array_walk($data create_function('&$v,$k''$v = $k."=".$v ;'));                                                                                          
$url='http://127.0.0.1:5055?'.implode("&",$data);                                                                                                           
$response file_get_contents($url);.                                                                                                                       
echo 
"200 OK\n";                                                                                                                                            
                                                                                                                                                            
?>
Replace 127.0.0.1 with your Traccar server, if it's located on another host than the one you put the PHP code in.

Would this whole implementation be a lot simpler, if Backitude sent over a GET instead of a POST ?
30th October 2013, 10:11 PM |#4  
Member
Flag Aarhus
Thanks Meter: 4
 
More
Yes, a toggle switch between GET and POST would make your program directly compatible, if the user can set port number on the URL as well.

Sendt fra min GT-I9505 med Tapatalk
3rd November 2013, 01:33 AM |#5  
Junior Member
Thanks Meter: 9
 
More
To repost from the other thread:

I have finally got around to opening up my Google App Engine app code. It runs on the free quota on Google App Engine and so it does not require you to pay for a server. Also as it's your app you have control of your location data, and can delete it at any time by going into the Google App Engine settings for your app. You send your location to your app and it is recorded in a database. The app allows you to share your location with other people by creating a white list of allowed Google accounts. I have also made a history page which you can use to see your updates from each day. I can't add links but you should be able to find the code at bitbucket.org / nparley

No doubt there will be bugs which I have not found. If you find one please add an issue to on the bitbucket page. I will continue to add new features as I can but am open to requests, just add a feature requestion issue on bitbucket.

Cheers,
Neil
Attached Thumbnails
Click image for larger version

Name:	IMG_20131016_175900_350.jpg
Views:	425
Size:	53.3 KB
ID:	2367458  
The Following 2 Users Say Thank You to nparley For This Useful Post: [ View ] Gift nparley Ad-Free
3rd November 2013, 09:48 AM |#6  
Junior Member
Thanks Meter: 0
 
More
[B[/B][/B]
Quote:
Originally Posted by nparley

To repost from the other thread:

I have finally got around to opening up my Google App Engine app code. It runs on the free quota on Google App Engine and so it does not require you to pay for a server. Also as it's your app you have control of your location data, and can delete it at any time by going into the Google App Engine settings for your app. You send your location to your app and it is recorded in a database. The app allows you to share your location with other people by creating a white list of allowed Google accounts. I have also made a history page which you can use to see your updates from each day. I can't add links but you should be able to find the code at bitbucket.org / nparley

No doubt there will be bugs which I have not found. If you find one please add an issue to on the bitbucket page. I will continue to add new features as I can but am open to requests, just add a feature requestion issue on bitbucket.

Cheers,
Neil


ON WEB PAGE IT SHOWS ONLY "Hello world!"
3rd November 2013, 03:36 PM |#7  
Junior Member
Thanks Meter: 9
 
More
Quote:
Originally Posted by holysmoke001

[B[/B][/B]

ON WEB PAGE IT SHOWS ONLY "Hello world!"

Hi holysmoke001,

I am not quite sure what you are referring to,

Neil
3rd November 2013, 05:44 PM |#8  
Junior Member
Thanks Meter: 0
 
More
Quote:
Originally Posted by nparley

Hi holysmoke001,

I am not quite sure what you are referring to,

Neil

Hi Neil
I follow all your instructions for Setting up the app but when i go to yourapp(my app).appspot.com/
IT SHOWS ONLY "Hello world!" written on corner of the web page.
can you please upload detailed instructions step by step how to set up the app
3rd November 2013, 09:34 PM |#9  
Junior Member
Thanks Meter: 9
 
More
Quote:
Originally Posted by holysmoke001

Hi Neil
I follow all your instructions for Setting up the app but when i go to yourapp(my app).appspot.com/
IT SHOWS ONLY "Hello world!" written on corner of the web page.
can you please upload detailed instructions step by step how to set up the app

I assume you have done all the steps here? https://bitbucket.org/nparley/mylati...ki/Setup%20App Does your site say running if you go to here https://appengine.google.com/

---------- Post added at 09:34 PM ---------- Previous post was at 09:26 PM ----------

Quote:
Originally Posted by holysmoke001

Hi Neil
I follow all your instructions for Setting up the app but when i go to yourapp(my app).appspot.com/
IT SHOWS ONLY "Hello world!" written on corner of the web page.
can you please upload detailed instructions step by step how to set up the app

OK the problem could be this https://code.google.com/p/google-app...s/detail?id=40 i.e. the path is wrong and the app engine application launcher has created another default app.yaml and app.py file.
4th November 2013, 06:07 AM |#10  
Junior Member
Thanks Meter: 0
 
More
Quote:
Originally Posted by nparley

I assume you have done all the steps here? //bitbucket.org/nparley/mylatitude/wiki/Setup%20App Does your site say running if you go to here://appengine.google.com

---------- Post added at 09:34 PM ---------- Previous post was at 09:26 PM ----------



OK the problem could be this //code.google.com/p/google-app-engine-samples/issues/detail?id=40 i.e. the path is wrong and the app engine application launcher has created another default app.yaml and app.py file.

yes problem is same.Launcher is creating a new folder inside my project folder with a default main.py and app.yaml file.
my project folder is JMlatitude and i copied my client secret file in JMlatitude folder and edited the app.yaml file as JMlatitude.yaml but launcher is creating new folder (JMlatitude) inside project folder.pls help what to do
4th November 2013, 11:04 AM |#11  
P500Alive's Avatar
Junior Member
Thanks Meter: 3
 
More
Red face
Thanks Brian for the dedicated post.
This is how to get started with my service (www.backituders.com).
0) The service is free
1) Drop me an email to [email protected] backituders <Dot> com. You'll get a username pwd password back.
2) Start using backituders!

You can find more infos, expandoing docs and guides at www.backituders.com.

Backituders is meant as an API you can use to implement your own applications on. I provide the server and APIs to set and get positions, set alamers and alerts and so on. There is also a ready-to-use "draw my map" and "follow my device live" feature.
Will use this post as updates to the service are done.

- 20131031: display timestamps in RFC format, display speed
- 20131104: changed the icons on the map to reflect direction (8 main dir) when available.
- 20131104: sono disponibili istruzioni base in italiano.

Thanks any for testing.
Post Reply Subscribe to Thread

Tags
android, backitude, history, location, sharing

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes