gps

Pointing to a specific location (compass) using an image instead of drawing

自闭症网瘾萝莉.ら 提交于 2019-12-08 14:02:59
问题 I'm using this code like a compass which point using the arrow to a specific location(Using GPS Values). This code is doing great except i want to replace drawing the arrow by an image of the arrow..but i don't know how. any help please?? @Override public void draw(Canvas canvas) { double angle = calculateAngle(currentLongitude, currentLatitude, targetLongitude, targetLatitude); //Correction; angle-=90; //Correction for azimuth angle-=azimuth; if((getContext() instanceof Activity) && (

Unity3D - Get smooth speed and acceleration with GPS data

倾然丶 夕夏残阳落幕 提交于 2019-12-08 13:43:29
I'm using Unity3D and I created simple distance, speed and acceleration calculator using latitude and longitude of last position. I'm calculating last distance, speed and acceleration in each GPS update (approximately once per second). But sometimes (2-3 second interval) latitude and longitude values changes rapidly (in clear weather and no obstacles). That's why speed and acceleration values gets unreal results. For example, at stable 40 km/h speed, speed value becomes 60 km/h and returns to 40 km/h within 2-3 second. I'm here to ask how can I avoid this inaccurate and rapid GPS data changes?

Android: I want to obtain location using GPS in the background for use with a directions tool in my app, how?

房东的猫 提交于 2019-12-08 13:42:30
问题 One of the activities for my company's app has a directions utility that allows the user to input their postcode, choose one of our offices, and Maps will route from the given postcode to one of our offices. Leaving the postcode field blank results in Maps defaulting to 'your location', however you need to click 'Go' in the Maps app for it to work, while providing a postcode will automatically do the routing without having to make that extra click. This is a small but necessary thing that

How can I determine if a GPS Coordinate is on or in an Ellipse?

青春壹個敷衍的年華 提交于 2019-12-08 13:28:54
问题 Ok, so I am still new to asking questions on Stack Overflow, so please be nice :) I have an issue that I have been trying to solve for a month now with failed results time and time again. I have found various questions somewhat similar to this, but nothing that has struck me as the definitive answer. The closest that I have found so far is this: Convert GPS coordinates to coordinate plane. In short, what I need is to know is if a GPS Coordinate is either on or inside an ellipse. KNOWNS: Width

Retrieving GPS coordinates not working when ran on a real android phone

余生颓废 提交于 2019-12-08 13:03:23
问题 My program should be able to: Change the map view Zoom in to the phone's current location Add a marker Display an alert of the Latitude and Longitude values When I use GPS_PROVIDER, functions 1-4 works in my emulator (because I manually feed it a latitude and longitude values). But when I created an apk file, 2-4 functions don't work. Here's my class. package com.locator.map; import java.text.DecimalFormat; import java.util.List; import android.app.AlertDialog; import android.content.Context;

Get GPS location from MLMediaObject on OS X

早过忘川 提交于 2019-12-08 12:44:06
问题 I'm getting started with the Media Library Framework on OS X, specifically with regard to accessing a user's Photos library. After a lot of wrangling I was able to get access to each photo as a MLMediaObject, but now I've hit a roadblock: How can I access the GPS location of the photo, from the MLMediaObject? This sort of information is easy to get from the old ALAssetsLibrary system, or from the Photos Framework on iOS, using a CLLocation property associated with the media object, but I can

How to speak current latitude,longitude text into speech

白昼怎懂夜的黑 提交于 2019-12-08 12:32:56
问题 I want to convert my current latitude,longitude text into speech.I have code for finding current latitude,longitude.But i initialize the TextToSpeech method inside Location class i got only latLongString.I couldn't get EX:your current location is lat=1.222,long=22.335. Here my Code: public class SpeakActivity extends Activity implements OnInitListener{ private TextToSpeech tts; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R

How to check the gps Tracking half hour once using Broadcast Receiver?

╄→гoц情女王★ 提交于 2019-12-08 12:09:02
问题 Hai am trying to get the gps location using BroadCast Receiver.its working fine,But i want to get the location every half hour once.i used **MINIMUM_TIME_BETWEEN_UPDATES ** 30mts .i got when latitude and longitude value changed update public class MainActivity extends Activity implements LocationListener { final DBAdapter1 db=new DBAdapter1(this); private ConnectivityReceiver receiver = null; private TextView txtNetworkInfo ; private static TextView latituteField; private static TextView

Get user current position with gps/network android MapView

ⅰ亾dé卋堺 提交于 2019-12-08 11:21:22
问题 Hello I've been using this guide to determine the locationof the user: http://developer.android.com/guide/topics/location/obtaining-user-location.html and my current code looks like this: LocationManager locationManager = (LocationManager) this.getSystemService(Context.LOCATION_SERVICE); LocationListener locationListener = new LocationListener() { public void onLocationChanged(Location location) { test = new GeoPoint((int)location.getLatitude()*1000000, (int)location.getAltitude()*1000000);

Android Services and Activities

∥☆過路亽.° 提交于 2019-12-08 11:12:37
问题 I have some questions about the Android service and activity lifecycles. Hope you guys can help me out. I have written an application that uses GPS location and stores them. It must monitor the GPS location updates constantly to work properly. Right now, it's all in one activity. So when you close the activity, you loose everything and can't continue monitor location updates. This is why I wanted to make a background service for the monitoring part. And I've been reading the Android Developer