Notices


Reply
Thread Tools
Saturn's Avatar
Posts: 1,648 | Thanked: 2,122 times | Joined on Mar 2007 @ UNKLE's Never Never Land
#1
The Snuggle application (http://maemo.org/packages/view/snuggle/) uses the cell tower information to locate the geolocation coordinates.
It captures the CellID parameters (available from the connected GSM network) and by using Google APIs translates those to locate your position in a map.


In detail:
  • The application makes use of the CellID parameters extracted using the dbus call (seen it here, thanks BluesLee) and
  • Two Google APIs to lookup in the online cellid db, locate your position and show it in a map.

Usage description:

The user interface shows four buttons;
  • The "CellID" button, makes a dbus call to get the CellID information (requires a GSM connection).
  • The "Coordinates" button, makes an access to (the hidden) mmap Google API to get the latitude and longitude coordinates of the connected cell tower (requires a network connection).
  • The "Image" button, grabs from google maps an image of your location and opens a new window for the user to see it (requires a network connection).
  • The "Browser" button, opens the browser on googlemaps with the location coordinates found (requires a network connection).

When I get some time will create a wiki to give additional information on the usage, settings and implications.

The application is in extras-devel at the moment. Feel free to post comments and ideas for additions as well as any ideas for a better name


Future Plans:

Primary objective was to give a quick access at the location present.
In my opinion this has been accomplished in the version at extras-testing.

Next version (which is running on my device and needs some more work to be ready for upload) has in addition a daemon in the background logging silently the cells the device connects continuously. This part is ready and has been running for more than 2 weeks in my device without any significant power consumption.
All data are stored in a SQL DB. A configurable tracker will be available that grabs from a Google API the geolocation data for the Cell IDs recorded and updates the DB automatically on selected network connections and date/time settings.

An additional panel allows the user to grab from another Google API the locations between two dates and creates a KML file that can be directly uploaded in google maps and show the path/places visited. This part is missing the date/time selector but the rest of the code is ready.

Last edited by Saturn; 2011-06-25 at 10:31. Reason: added future plans
 

The Following 25 Users Say Thank You to Saturn For This Useful Post:
Posts: 152 | Thanked: 49 times | Joined on Dec 2009
#2
testing right now and nothing happens when i press "Coordinates"
"CellID" worked fine. How long does it take normally?
 
Saturn's Avatar
Posts: 1,648 | Thanked: 2,122 times | Joined on Mar 2007 @ UNKLE's Never Never Land
#3
Originally Posted by CrckMc View Post
testing right now and nothing happens when i press "Coordinates"
"CellID" worked fine. How long does it take normally?
In the next version will add some information banners on what is happening and if it wasn't possible to make a location match.

Do you have a network connection active?

If yes, can you run it from xterm and pm me with the messages you get?

Code:
/opt/locatefromcell/Locate_From_Cell
 
jd4200's Avatar
Posts: 451 | Thanked: 424 times | Joined on Apr 2010 @ England
#4
Tesing it, and it all seems to work fine for me.
Thanks!

Screeny:
 
Posts: 152 | Thanked: 49 times | Joined on Dec 2009
#5
Code:
 $ /opt/locatefromcell/Locate_From_Cell 
262 3 4666 37920
262 3 4666 61000
en
Traceback (most recent call last):
  File "/opt/locatefromcell/locatefromcell.py", line 210, in doGetLocation
  File "/opt/locatefromcell/locatefromcell.py", line 276, in get_location_by_cell
  File "/usr/lib/python2.5/struct.py", line 87, in unpack
    return o.unpack(s)
struct.error: unpack requires a string argument of length 25
this is the output in xterm and yes i have a network connection.
 

The Following User Says Thank You to CrckMc For This Useful Post:
Alfred's Avatar
Posts: 855 | Thanked: 612 times | Joined on Oct 2010 @ Germany
#6
Works really great and fast as ****. Thanks a lot, although there are some bugs. No portrait mode.
__________________
Reps are just one click away: Extras | Extras-Testing | Extras-Devel | My-Maemo | CSSU |
Transform your lock screen into a weather forecast Thanks button ================>
 
nicholes's Avatar
Posts: 1,103 | Thanked: 368 times | Joined on Oct 2010 @ india, indore
#7
Originally Posted by CrckMc View Post
testing right now and nothing happens when i press "Coordinates"
"CellID" worked fine. How long does it take normally?
same happened with me but i solved it
just go to settings>phone>network and change network mode by GSM and it worked for me! it did not work for me on 3G mode!!!!!
 
Saturn's Avatar
Posts: 1,648 | Thanked: 2,122 times | Joined on Mar 2007 @ UNKLE's Never Never Land
#8
Uploaded a new version (1.2-1) with better info and some small new features.

Changelog:
  • Added several information banners to show actions/failures.
  • Added an Edit Mode in the menu to manually enter the information.
  • Added some UI settings for correct display.
 

The Following User Says Thank You to Saturn For This Useful Post:
Saturn's Avatar
Posts: 1,648 | Thanked: 2,122 times | Joined on Mar 2007 @ UNKLE's Never Never Land
#9
Originally Posted by CrckMc View Post
Code:
 $ /opt/locatefromcell/Locate_From_Cell 
262 3 4666 37920
262 3 4666 61000
en
Traceback (most recent call last):
  File "/opt/locatefromcell/locatefromcell.py", line 210, in doGetLocation
  File "/opt/locatefromcell/locatefromcell.py", line 276, in get_location_by_cell
  File "/usr/lib/python2.5/struct.py", line 87, in unpack
    return o.unpack(s)
struct.error: unpack requires a string argument of length 25
this is the output in xterm and yes i have a network connection.
The cell tower info you show don't follow the expected values (in specific the Local Area Code).
Maybe I need to add some padding for cases like this in the code but I don't know really what is needed yet.

Thanks for the fail case.
 
Saturn's Avatar
Posts: 1,648 | Thanked: 2,122 times | Joined on Mar 2007 @ UNKLE's Never Never Land
#10
Originally Posted by Alfred View Post
Works really great and fast as ****. Thanks a lot, although there are some bugs. No portrait mode.
Thanks!
Yes it's fast (especially if the network is wifi) since the data are not much.
Including the image grabbed, it is still < 100 kB.

About the portrait mode, The application responds to the movement of the device (check the About window that works nicely). For the main window I haven't found any info on how to instruct the Qt Designer to produce a layout that works on both modes. my question is similar to that made here for example: http://maemo.org/community/maemo-dev...bfae7bae1bae1/

Any help appreciated.
 

The Following User Says Thank You to Saturn For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 08:11.