I created the Listener and requested updates (see code below), but for
some reason I'm not being notified. The method onStatusChanged() is
being called instead, firstly with STATUS set to
TEMPORARILY_UNAVAILABLE, then when I send the first GPS coordinate via
DDMS, the method is called again with
Running example:
package com.layout.test;
import android.app.Activity;
import android.content.Context;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.util.Log;
import android.view.Menu;
Use Geocoder, the newly class introduced in 1.0 SDK.
Its helps in reverse geocodeing( i.e getting address from lat/lon)
http://code.google.com/android/reference/android/location/Geocoder.html
Thanks,
Shibbs
On Oct 17, 2:12 pm, Matthias [EMAIL PROTECTED] wrote:
Well, in other words, this whole
Well, in other words, this whole location manager thing is pretty
broken in Android 1.0?
From what I've read and experienced myself so far, it's pretty much
like this:
1) LocationManager cannot be subclassed anymore, instead you use the
debug bridge to send location fixes. Unfortunately, this
Will you please provide any running example?
On Oct 2, 7:34 pm, Ludwig [EMAIL PROTECTED] wrote:
The getLastKnownLocation() only returns in my experience valid locations if
there is elsewhere something that has subscribed to location updates, with
something like this:
public void
In SDK 1.0 the LocationManager is always reporting the gps provider
as disabled:
LocationManager lm = this.getSystemService(Context.LOCATION_SERVICE);
boolean gpsEnabled =
lm.isProviderEnabled(LocationManager.GPS_PROVIDER);
// gpsEnabled == false
According to the Javadocs this value implies
In SDK 1.0 the LocationManager is always reporting the gps provider
as disabled:
LocationManager lm = this.getSystemService(Context.LOCATION_SERVICE);
boolean gpsEnabled =
lm.isProviderEnabled(LocationManager.GPS_PROVIDER);
// gpsEnabled == false
According to the Javadocs this value implies
Guillaume,
I understand that i need to mock the the current location in the
emulator, but my question is what api calls do i make to get the lat/
lon that i put in DDMS. I cannot find any documentations related to
that in android's documentation.
On Sep 28, 4:53 am, Guillaume Perrot [EMAIL
for those who are looking for solutions for this same question, here's
what I have, seems to work well with
For telnet: telnet localhost 5554
geo fix lat lon
this.locationManager = (LocationManager)
getSystemService(Context.LOCATION_SERVICE);
Location myLocation =
And you have to manually simulate your location using telnet or DDMS
controls in Eclipse (the latter only works if your OS is in english
locale).
For telnet: telnet localhost 5554
geo fix 2 40
On 28 sep, 04:05, Mark Murphy [EMAIL PROTECTED] wrote:
zl25drexel wrote:
Hi, sorry i am sure this
zl25drexel wrote:
Hi, sorry i am sure this had been asked before, how do i find out my
current lat/lon using the location API?
You can't, per se.
You can call getLastKnownLocation() to return, well, the last known
location, but that may be null (if there have been no locations recorded
for
11 matches
Mail list logo