Questions tagged [gps]

Abbreviation for Global Positioning System; a navigational system using satellite signals to fix the location of a radio receiver on or above the earth's surface. Also "GPS" refers to the radio receiver used to receive GPS signals.

Global Positioning System (GPS) is a space-based global navigation satellite system (GNSS) that provides reliable location and time information in all weather and at all times and anywhere on or near the Earth when and where there is an unobstructed line of sight to four or more GPS satellites.

It is freely accessible to anybody with a GPS receiver. Apple, Google, and other mobile providers have developed frameworks to deal with the location services calculated from GPS, WiFi or Cell Tower.

More information can be found at:

10257 questions
41
votes
6 answers

When do I need android.hardware.location.gps and android.hardware.location.network?

Google is informing by email of changes to the Android location permissions: We’re making a change on October 15th, 2016 that will affect apps targeting API version 21 (Android 5.0, Lollipop) or higher that use ACCESS_FINE_LOCATION but don't…
mattm
  • 5,851
  • 11
  • 47
  • 77
40
votes
9 answers

Geolocation API on the iPhone

Does anyone know whether the iPhone supports or will soon support the W3C Geolocation specification? I'm looking to build an app for mobile users, but rather than spend the time developing apps for every different platform (iPhone, Android, etc...),…
Codebeef
  • 43,508
  • 23
  • 86
  • 119
39
votes
4 answers

Detecting GPS on/off switch in Android phones

I would like to detect when the user changes the GPS settings on or off for an Android phone. Meaning when user switches GPS sattelite on/off or detection via access points etc.
Drejc
  • 14,196
  • 16
  • 71
  • 106
39
votes
12 answers

Fused location provider doesn't seem to use GPS receiver

Android 4.3 on Moto G, Android 4.4.2 on Nexus 7 2012, Android 4.4.2 on Nexus 5. Android Studio 0.4. I don't want to receive regular location updates, I just want an accurate location when the user presses a button. I have followed this example:…
cja
  • 9,512
  • 21
  • 75
  • 129
38
votes
2 answers

GPS Android - get positioning only once

Is there a way to access the GPS once instead of having a looper that constantly checks for location updates? In my scenario all I'm interested in is finding the current co-ordinates and not a continuous connection with the GPS satellite. Does…
progdoc
  • 589
  • 3
  • 11
  • 24
37
votes
9 answers

What's the best way to synchronize times to millisecond accuracy AND precision between machines?

From what I understand, the crystals on PC's are notorious for clock skew. If clocks are always skewing, what is the best way to synchronize clocks between machines with millisecond accuracy and precision? From what I've found, NTP and PTP are…
PiNoYBoY82
  • 1,618
  • 2
  • 14
  • 17
37
votes
4 answers

Ticks between Unix epoch and GPS epoch

What is the number of one second ticks between Unix time epoch (01 Jan 1970) and GPS time epoch (06 Jan 1980)? I have seen multiple answers from several sources on the web. One camp claims the answer is 315964800, the other claims it is 315964819. I…
kmort
  • 2,848
  • 2
  • 32
  • 54
36
votes
3 answers

Rotating an ImageView like a compass (with the "north pole" set elsewhere)

I'm stumped regarding how to implement a "personal compass", ie a compass that points to a specific bearing instead of the standard "north pole"... unfortunatly, my current attempt has come out wrong (doesn't point at the given bearing). It's also…
karllindmark
  • 6,031
  • 1
  • 26
  • 41
36
votes
6 answers

Open Settings app from another app programmatically in iPhone

I have to open settings app from my app if gps is not enabled in iPhone. I have used the following code. It works well in iOS simulator but it does not work in iPhone. May I know is there any problem in this code. if (![CLLocationManager…
Edward Sagayaraj
  • 471
  • 2
  • 5
  • 10
36
votes
9 answers

Reading the GPS data from the image returned by the camera in iOS iphone

I need to get the GPS coordinates of an image taken with the iOS device's camera. I do not care about the Camera Roll images, just the image taken with UIImagePickerControllerSourceTypeCamera. I've read many stackoverflow answers, like Get Exif data…
Paul Cezanne
  • 8,629
  • 7
  • 59
  • 90
35
votes
6 answers

How to stop location manager?

Don't know why, but sometimes LocationManager is still working also after closing application. I call startGPS() in onCreate-Methode in one Activity (only one, let me call it StartActivity). protected void startGPS(){ try { …
Tima
  • 12,765
  • 23
  • 82
  • 125
35
votes
9 answers

Adding distance to a GPS coordinate

I'm trying to generate some points at random distances away from a fixed point using GPS. How can I add distance in meters to a GPS coordinate? I've looked at UTM to GPS conversion but is there a simpler method to achieve this? I'm working on…
fgs
  • 353
  • 1
  • 3
  • 4
35
votes
3 answers

Change Location Mode to High Accuracy Programmatically Android

Is it possible to get the information on the location mode which the user has selected among the three modes under the location settings options i.e 1.Hight Accuracy 2.Battery Saving 3.GPS Only I want to programmatically check if user has selected…
ik024
  • 3,566
  • 7
  • 38
  • 61
35
votes
6 answers

How to get Android GPS location

Cheers, I'm trying to get the current GPS-Location via Android. I followed this Tutorial and Vogellas article aswell. Though it ain't working. When using LocationManager.NETWORK_PROVIDER I'm always getting a latitude of 51 and longitude of 9 - no…
Sebastian
  • 1,593
  • 4
  • 26
  • 41
34
votes
8 answers

Detecting whether a GPS coordinate falls within a polygon on a map

As stated in the title, the goal is to have a way for detecting whether a given GPS coordinate falls inside a polygon or not. The polygon itself can be either convex or concave. It's defined as a set of edge vectors and a known point within that…
Saul
  • 17,973
  • 8
  • 64
  • 88