The -1 for verticalAccuracy
indicates that the altitude in the CLLocation
is not valid. You only get altitude with a 3D GPS position.
The 1414 for horizontalAccuracy
indicates that the horizontal (lat/lon) position could be up to 1414m off (this is just an estimated error). This is probably a location determined by cell tower triangulation or WiFi location data. GPS locations usually report 100m or better.
To get a higher accuracy location (300m or better) you need to set desiredAccuracy
and wait for the GPS receiver to lock onto at least 3 satellites (or 4 for a 3D fix). Until that happens CLLocationManager
will give you the best it has which is WiFi or Cell tower triangulation results.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…