gps

How to reduce iPhone battery consumption while using GPS

孤街浪徒 提交于 2019-12-23 02:47:08
问题 I am using GPS to actually monitor if I have entered a regions (radius 100 m). I am using a hybrid of significantLocationChange s and hardware GPS, startUpdatingLocation . As significantLocationChanges are not as accurate as I require I am using them only to check if I have entered a outer circle of X m. Then I use hardware GPS to check if the user enters an inner circle (100m). The problem with it is that battery is getting drained pretty quickly, can anyone help me out. 回答1: I was concerned

Android FusedLocation's SettingsApi does not work more than once

喜夏-厌秋 提交于 2019-12-23 02:41:15
问题 FusedLocation has a wonderful API to check if the user has enabled all the relevant settings to obtain location. I followed the documentation https://developers.google.com/android/reference/com/google/android/gms/location/SettingsApi to fire up the SettingsApi. My code to check user's setting is as below private void checkLocationSetting() { if (mLocationSettingsRequest == null) { mLocationSettingsRequest = new LocationSettingsRequest.Builder() .addLocationRequest(mLocationRequest)

GPS tracking system for find each other in a close area - Android

核能气质少年 提交于 2019-12-23 02:34:50
问题 I am developing an android application which should has the capability of finding each other in a close area. I've posted a question which describes all the requirements. Please look at (Android : GPS tracking system for find each other in a close area) I am using a service but I don't know how to run this service periodically (once in 15 mins or so ). And also I have no clear idea about how to send the location of devices to the server and how to fetch locations of friend's device. Here is

Simulate Low and Hight Gps Accuracy

爷,独闯天下 提交于 2019-12-23 02:20:09
问题 I did a .gpx file to simulate a route on IOS simulator, now i wanna simulate the horizontal accuracy how I can do this? as follow is an excerpt of my .gpx file: <?xml version="1.0"?> <gpx> <wpt lat="-23.772830" lon="-46.689820"/> //how add horizontal accuracy 7 meters for example <wpt lat="-23.774450" lon="-46.692570"/> //and here horizontal accuracy of 2 metters for example <wpt lat="-23.773450" lon="-46.693530"/> //and here 19 meters </gpx> if I run all gps points return horizontal accuracy

Convert HEX to ASCII, data from GPS tracker

吃可爱长大的小学妹 提交于 2019-12-23 01:52:30
问题 I have just bought a GPS Tracker, it can send SMS to cellphone just fine. It also supports reporting to a server via GPRS. I have setup the device to contact my own server on port 8123, it's a FreeBSD server and i have checked that i recieve packets on that port. I successfully have setup a listener server written in PHP, and i can receive data from the device. But how do i convert the partial HEX data to something usefull (ASCII)? Example data string: $$^@T^@E Y'^WÿU210104.000,A,5534.4079,N

Android: Synchronize Timestamps of Sensors and GPS

喜夏-厌秋 提交于 2019-12-23 01:16:37
问题 Is there a way to synchronize the timestamps in values meassured by Sensors (e.g. acceleration) ( SensorEvent.timestamp ) and GPS ( Location.getTime() ). SensorEvent.timestamp are the nanoseconds since the device has been booted (local time). Location.getTime() are the miliseconds since1970 (global time). One solution I had in mind was to calculate the offset between the local time and the global (GPS) time. But the problem is, that the time in Location is the time when the GPS-message

Calculate speed between two location points in Android

做~自己de王妃 提交于 2019-12-22 18:25:04
问题 This seems like it should be simple enough, but I can't seem to get a clear example of how to calculate my speed using Android's Location Services. All I want to do is calculate my speed based on my previous and current GPS position. getSpeed() doesn't work, because it needs to be set at some point using setSpeed(). So is there any sample code out there that I can run in Eclipse against my Android emulator running a GPX file, that will show me my pace in any measure (meters, feet, miles, etc.

iPhone GPS Accuracy - Reading Changes eventhough Device is stationary

牧云@^-^@ 提交于 2019-12-22 18:17:55
问题 I am working on an app that is meant to calculate the distance traveled from starting point to end. i have done all things to get the changing coordinates and measure the distance between this co-ordinates. Now the real problem is even though if I keep my iPhone stationary after few seconds the GPS readings shows deviation and CLLocationDistance tells me that I had moved few 100 meters whereas I haven't moved a bit also. Is there anything I can do increase the precision of my app ?? Thanks in

How to compare 2 location positions

ⅰ亾dé卋堺 提交于 2019-12-22 18:12:53
问题 I have an App with a TextView that finds your location and when you move, the value in TextView changes. I want to know what can I do in order to register the first location and then look for the location 5 min after. For example: min 0 LAT 000000 LONG 000000 ( SAVE IT ) min 5 LAT 1111111 LONG 111111 if min0 == min 5 ... To sum up, I want to compare 2 strings (lat & long at the beginning) and lat & long after 5 minutes. Any suggestion will be appreciated. 回答1: This Link should serve your

Determining if user is driving using gps

浪子不回头ぞ 提交于 2019-12-22 16:45:33
问题 Is there a way in Android to somehow use the GPS to determine if the user is driving (e.g. if the user is moving faster then say, 10 mph)? What would be even better is if there was an intent I could receive whenever the user is moving faster then 10 mph or under 10 mph, but I think I'm pushing my luck with that one. Any help would be appreciated. 回答1: You probably want to set up some AsyncTask (background thread) with a call back function of your preference, which will be called when the