aspose file tools*
The moose likes Android and the fly likes unable to get gps coordinates in my app on mobile Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » Android
Bookmark "unable to get gps coordinates in my app on mobile" Watch "unable to get gps coordinates in my app on mobile" New topic
Author

unable to get gps coordinates in my app on mobile

Suzzane Pinto
Ranch Hand

Joined: Feb 10, 2012
Posts: 214
hi,
iam trying to get the gps coordinates on my mobile.
in the avd iam able to get the coordinates with the help of emulator control but fail to do that in real device...
i have refered this link
http://www.firstdroid.com/2010/04/29/android-development-using-gps-to-get-current-location-2/

i dont why iam not able to do in real device
any suggestion would be helpful
thankyou
Mohan Prasath
Ranch Hand

Joined: Jul 25, 2011
Posts: 38

Kindly try the following steps and give it another try,
1. Generate a new keystore when exporting your app as an apk. (You can do this while exporting your app)
2. Also generate a new Android Map API key with MD5 checksum.

Let me know of your results.

With regards,
Mohan Prasath
Tim Moores
Rancher

Joined: Sep 21, 2011
Posts: 2408
I'm not sure what the Android Map API key Mohan mentioned is supposed to be, but the things to check are: a) does the manifest have the proper permission (fine location), b) is GPS turned on on the device, c) are there any exceptions in the logcat output, d) can the device fix GPS location in other apps (like Google Maps or MapDroid)?
Suzzane Pinto
Ranch Hand

Joined: Feb 10, 2012
Posts: 214
hi..
i would like to know if i could get the gps coordinates of an image captured???
and if yes how can i achieve that??
please suggest
Tim Moores
Rancher

Joined: Sep 21, 2011
Posts: 2408
Those are generally written as EXIF metadata in JPEGs; see http://rsbweb.nih.gov/ij/plugins/exif-reader.html for some code. Other file formats probably have similar facilities.

But if the picture is taken by your app, then you can just query the GPS directly. Probably a lot simpler than extracting that data from an image.
Suzzane Pinto
Ranch Hand

Joined: Feb 10, 2012
Posts: 214
hi i want to start the camera with gps enabled would could then capture the image with gps coorinates
Tim Moores
Rancher

Joined: Sep 21, 2011
Posts: 2408
Then my previous comment fully applies.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: unable to get gps coordinates in my app on mobile