我无法弄清问题是什么。当我不调用getPrefsGPS()方法时,代码工作正常。
GeoCoding the Location的方法在两天前工作,但突然停止显示任何城市名称......再次不知道为什么! 这是我的代码
import java.io.IOException;
import java.util.List;
import java.util.Locale;
import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.location.Address;
import android.location.Geocoder;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.util.Log;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.animation.ScaleAnimation;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.TextView;
public class GPS extends Activity {
TextView tvlat;
TextView tvlong;
TextView tvloc;
Button weather;
Long PrefsRefreshPeriod = (long) 900000.0;
SharedPreferences sp;
SharedPreferences.Editor sd;
String city = "New Delhi, India";
LocationManager lm;
LocationListener listener;
RelativeLayout settingLayout;
Context _context;
@Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.gps);
_context = this;
tvlat = (TextView) findViewById(R.id.tvlat);
tvlong = (TextView) findViewById(R.id.tvlong);
tvloc = (TextView) findViewById(R.id.tvloc);
sp = this.getSharedPreferences("GPS", 0);
sd = sp.edit();
weather = (Button) findViewById(R.id.getweatherfromgps);
weather.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Intent i = new Intent(GPS.this, weather.class);
i.putExtra("city", city);
startActivity(i);
}
});
getPrefsGPS();
settingLayout = (RelativeLayout) findViewById(R.id.settingLayout);
lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE);
listener = new myLocationListener();
if (lm.isProviderEnabled(LocationManager.GPS_PROVIDER)) {
lm.requestLocationUpdates(LocationManager.GPS_PROVIDER, 0, 0,
listener);
} else if (lm.isProviderEnabled(LocationManager.NETWORK_PROVIDER)) {
lm.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 0, 0,
listener);
} else {
tvloc.setText("Not getting anything!");
}
}
public String ConvertPointToLocation(double pointlat, double pointlog) {
String address = "";
String locality = "";
Geocoder geoCoder = new Geocoder(this, Locale.getDefault());
if (Geocoder.isPresent()) {
try {
List<Address> addresses = geoCoder.getFromLocation(pointlat,
pointlog, 1);
if (addresses.size() > 0) {
for (int index = 0; index < addresses.get(0)
.getMaxAddressLineIndex(); index++)
address += addresses.get(0).getAddressLine(index) + " ";
}
locality = addresses.get(0).getLocality() + ","
+ addresses.get(0).getCountryName();
} catch (IOException e) {
e.printStackTrace();
}
} else {
address = "Geocoder not available!";
}
return locality;
}
public String ReverseGeocoding(Double lat, Double lon) {
String address = "";
getReverseGeocoding coder = new getReverseGeocoding(lat, lon);
address = coder.getAddress1() + " " + coder.getAddress2() + " "
+ coder.getCity() + " " + coder.getCountry();
return address;
}
class myLocationListener implements LocationListener {
@SuppressWarnings("unused")
@Override
public void onLocationChanged(Location arg0) {
if (arg0 != null) {
Double lat = arg0.getLatitude();
Double longi = arg0.getLongitude();
tvlat.setText(Double.toString(lat));
tvlong.setText(Double.toString(longi));
String loc1 = ReverseGeocoding(lat, longi);
String loc2 = ConvertPointToLocation(lat, longi);
city = (loc1.length() > loc2.length()) ? loc1 : loc2;
savePrefsGPS(lat, longi, city);
if (loc1 != null && loc1 != "" && loc2 != null && loc2 != "")
tvloc.setText("HTTP = " + loc1 + "\nGeoCoder = " + loc2);
else
tvloc.setText("Its a null");
}
lm.removeUpdates(listener);
}
@Override
public void onProviderDisabled(String arg0) {
// TODO Auto-generated method stub
tvloc.setText("Please Enable Network!");
}
@Override
public void onProviderEnabled(String arg0) {
// TODO Auto-generated method stub
tvloc.setText("Searching for location!");
}
@Override
public void onStatusChanged(String arg0, int arg1, Bundle arg2) {
// TODO Auto-generated method stub
tvloc.setText("Status Changed!");
}
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// TODO Auto-generated method stub
ImageView settings = (ImageView) findViewById(R.id.ivset);
settings.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View arg0) {
// TODO Auto-generated method stub
String user = "Admin";
String pass = "";
Intent intent = new Intent(GPS.this, Second.class);
intent.putExtra("username", user);
intent.putExtra("password", pass);
startActivity(intent);
}
});
return super.onCreateOptionsMenu(menu);
}
@Override
public boolean onPrepareOptionsMenu(Menu menu) {
// TODO Auto-generated method stub
if (settingLayout.getVisibility() == RelativeLayout.INVISIBLE) {
settingLayout.setVisibility(RelativeLayout.VISIBLE);
ScaleAnimation scale = new ScaleAnimation((float) 1.0, (float) 1.0,
(float) 1.0, (float) 1.0);
scale.setFillBefore(true);
scale.setDuration(500);
settingLayout.startAnimation(scale);
return super.onPrepareOptionsMenu(menu);
} else
return false;
}
@Override
public void onBackPressed() {
// TODO Auto-generated method stub
if (settingLayout.getVisibility() == RelativeLayout.VISIBLE) {
settingLayout.setVisibility(RelativeLayout.INVISIBLE);
ScaleAnimation scale = new ScaleAnimation((float) 0.0, (float) 0.0,
(float) 0.0, (float) 0.0);
scale.setFillBefore(false);
scale.setDuration(500);
settingLayout.startAnimation(scale);
} else {
super.onBackPressed();
}
}
public void savePrefsGPS(Double latitude, Double longitude, String city) {
saveData sd = new saveData(_context, "GPS");
sd.saveDoublePrefs("Latitude", latitude);
sd.saveDoublePrefs("Longitude", longitude);
sd.saveStringPrefs("City", city);
sd.saveLongPrefs("Time", System.currentTimeMillis());
sd.saveLongPrefs("RefreshPeriod", PrefsRefreshPeriod);
}
public void getPrefsGPS() {
Double lat = Double.longBitsToDouble(sp.getLong("Latitude", (Long) null));
Double lon = Double.longBitsToDouble(sp.getLong("Longitude", (Long) null));
Long period = sp.getLong("RefreshPeriod", (Long) null);
Long time = sp.getLong("Time",(Long) null);
String city1 = sp.getString("City", "New Delhi,IN");
Log.e("banana", "data retrieved!");
Long currentTime = System.currentTimeMillis();
if ((currentTime - time) < period) {
tvlat.setText("" + lat);
tvlong.setText("" + lon);
tvloc.setText("Last Location : " + city1);
city = city1;
}
}
}
Logcat日志
06-27 11:14:17.938: I/ActivityManager(290): START u0 {cmp=com.ritesh.weatherme/.GPS} from pid 784
06-27 11:14:17.938: W/WindowManager(290): Failure taking screenshot for (164x273) to layer 21010
06-27 11:14:18.088: I/Choreographer(784): Skipped 33 frames! The application may be doing too much work on its main thread.
06-27 11:14:18.578: D/dalvikvm(784): GC_CONCURRENT freed 165K, 11% free 2698K/3008K, paused 74ms+20ms, total 251ms
06-27 11:14:18.578: D/dalvikvm(784): WAIT_FOR_CONCURRENT_GC blocked 18ms
06-27 11:14:18.828: D/AndroidRuntime(784): Shutting down VM
06-27 11:14:18.828: W/dalvikvm(784): threadid=1: thread exiting with uncaught exception (group=0x40a71930)
06-27 11:14:18.842: E/AndroidRuntime(784): FATAL EXCEPTION: main
06-27 11:14:18.842: E/AndroidRuntime(784): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ritesh.weatherme/com.ritesh.weatherme.GPS}: java.lang.NullPointerException
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2180)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2230)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread.access$600(ActivityThread.java:141)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1234)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.os.Handler.dispatchMessage(Handler.java:99)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.os.Looper.loop(Looper.java:137)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread.main(ActivityThread.java:5041)
06-27 11:14:18.842: E/AndroidRuntime(784): at java.lang.reflect.Method.invokeNative(Native Method)
06-27 11:14:18.842: E/AndroidRuntime(784): at java.lang.reflect.Method.invoke(Method.java:511)
06-27 11:14:18.842: E/AndroidRuntime(784): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
06-27 11:14:18.842: E/AndroidRuntime(784): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
06-27 11:14:18.842: E/AndroidRuntime(784): at dalvik.system.NativeStart.main(Native Method)
06-27 11:14:18.842: E/AndroidRuntime(784): Caused by: java.lang.NullPointerException
06-27 11:14:18.842: E/AndroidRuntime(784): at com.ritesh.weatherme.GPS.getPrefsGPS(GPS.java:251)
06-27 11:14:18.842: E/AndroidRuntime(784): at com.ritesh.weatherme.GPS.onCreate(GPS.java:72)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.Activity.performCreate(Activity.java:5104)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1080)
06-27 11:14:18.842: E/AndroidRuntime(784): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2144)
06-27 11:14:18.842: E/AndroidRuntime(784): ... 11 more
06-27 11:14:18.888: W/ActivityManager(290): Force finishing activity com.ritesh.weatherme/.GPS
06-27 11:14:18.918: W/ActivityManager(290): Force finishing activity com.ritesh.weatherme/.Second
06-27 11:14:19.368: D/dalvikvm(290): GC_FOR_ALLOC freed 185K, 19% free 5460K/6712K, paused 164ms, total 168ms
06-27 11:14:19.368: I/dalvikvm-heap(290): Grow heap (frag case) to 5.743MB for 281896-byte allocation
06-27 11:14:19.538: D/dalvikvm(290): GC_FOR_ALLOC freed 6K, 19% free 5728K/6988K, paused 165ms, total 165ms
06-27 11:14:19.538: I/Choreographer(290): Skipped 43 frames! The application may be doing too much work on its main thread.
06-27 11:14:19.817: W/ActivityManager(290): Activity pause timeout for ActivityRecord{40e9f0e0 u0 com.ritesh.weatherme/.GPS}
06-27 11:14:20.047: I/Choreographer(412): Skipped 36 frames! The application may be doing too much work on its main thread.
06-27 11:14:20.077: I/Choreographer(290): Skipped 45 frames! The application may be doing too much work on its main thread.
06-27 11:14:20.128: E/SurfaceFlinger(37): ro.sf.lcd_density must be defined as a build property
06-27 11:14:20.267: E/SurfaceFlinger(37): ro.sf.lcd_density must be defined as a build property
06-27 11:14:20.527: I/ARMAssembler(37): generated scanline__00000077:03515104_00008001_00000000 [113 ipp] (134 ins) at [0x4098a6c0:0x4098a8d8] in 2072849 ns
06-27 11:14:20.857: I/Choreographer(290): Skipped 57 frames! The application may be doing too much work on its main thread.
06-27 11:14:31.284: W/ActivityManager(290): Activity destroy timeout for ActivityRecord{40ecc818 u0 com.ritesh.weatherme/.Second}
06-27 11:14:31.288: W/ActivityManager(290): Activity destroy timeout for ActivityRecord{40e9f0e0 u0 com.ritesh.weatherme/.GPS}
06-27 11:14:32.398: D/ExchangeService(611): Received deviceId from Email app: null
06-27 11:14:32.398: D/ExchangeService(611): !!! deviceId unknown; stopping self and retrying
06-27 11:14:37.488: D/ExchangeService(611): !!! EAS ExchangeService, onStartCommand, startingUp = false, running = false
06-27 11:14:37.497: W/ActivityManager(290): Unable to start service Intent { act=com.android.email.ACCOUNT_INTENT } U=0: not found
06-27 11:14:37.497: D/ExchangeService(611): !!! Email application not found; stopping self
06-27 11:14:37.517: W/ActivityManager(290): Unable to start service Intent { act=com.android.email.ACCOUNT_INTENT } U=0: not found
06-27 11:14:37.548: E/ActivityThread(611): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2d000 that was originally bound here
06-27 11:14:37.548: E/ActivityThread(611): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2d000 that was originally bound here
06-27 11:14:37.548: E/ActivityThread(611): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-27 11:14:37.548: E/ActivityThread(611): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-27 11:14:37.548: E/ActivityThread(611): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-27 11:14:37.548: E/ActivityThread(611): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-27 11:14:37.548: E/ActivityThread(611): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-27 11:14:37.548: E/ActivityThread(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-27 11:14:37.548: E/ActivityThread(611): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-27 11:14:37.548: E/ActivityThread(611): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-27 11:14:37.548: E/ActivityThread(611): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-27 11:14:37.548: E/ActivityThread(611): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-27 11:14:37.548: E/ActivityThread(611): at java.lang.Thread.run(Thread.java:856)
06-27 11:14:37.698: E/StrictMode(611): null
06-27 11:14:37.698: E/StrictMode(611): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2d000 that was originally bound here
06-27 11:14:37.698: E/StrictMode(611): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-27 11:14:37.698: E/StrictMode(611): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-27 11:14:37.698: E/StrictMode(611): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-27 11:14:37.698: E/StrictMode(611): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-27 11:14:37.698: E/StrictMode(611): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-27 11:14:37.698: E/StrictMode(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-27 11:14:37.698: E/StrictMode(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-27 11:14:37.698: E/StrictMode(611): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
06-27 11:14:37.698: E/StrictMode(611): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
06-27 11:14:37.698: E/StrictMode(611): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
06-27 11:14:37.698: E/StrictMode(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-27 11:14:37.698: E/StrictMode(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-27 11:14:37.698: E/StrictMode(611): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-27 11:14:37.698: E/StrictMode(611): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-27 11:14:37.698: E/StrictMode(611): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-27 11:14:37.698: E/StrictMode(611): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-27 11:14:37.698: E/StrictMode(611): at java.lang.Thread.run(Thread.java:856)
06-27 11:14:37.698: W/ActivityManager(290): Unbind failed: could not find connection for android.os.BinderProxy@40d932f8
06-27 11:14:37.727: E/ActivityThread(611): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2cc38 that was originally bound here
06-27 11:14:37.727: E/ActivityThread(611): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2cc38 that was originally bound here
06-27 11:14:37.727: E/ActivityThread(611): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-27 11:14:37.727: E/ActivityThread(611): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-27 11:14:37.727: E/ActivityThread(611): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-27 11:14:37.727: E/ActivityThread(611): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-27 11:14:37.727: E/ActivityThread(611): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-27 11:14:37.727: E/ActivityThread(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-27 11:14:37.727: E/ActivityThread(611): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-27 11:14:37.727: E/ActivityThread(611): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-27 11:14:37.727: E/ActivityThread(611): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-27 11:14:37.727: E/ActivityThread(611): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-27 11:14:37.727: E/ActivityThread(611): at java.lang.Thread.run(Thread.java:856)
06-27 11:14:37.827: E/StrictMode(611): null
06-27 11:14:37.827: E/StrictMode(611): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d2cc38 that was originally bound here
06-27 11:14:37.827: E/StrictMode(611): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-27 11:14:37.827: E/StrictMode(611): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-27 11:14:37.827: E/StrictMode(611): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-27 11:14:37.827: E/StrictMode(611): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-27 11:14:37.827: E/StrictMode(611): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-27 11:14:37.827: E/StrictMode(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-27 11:14:37.827: E/StrictMode(611): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-27 11:14:37.827: E/StrictMode(611): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
06-27 11:14:37.827: E/StrictMode(611): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
06-27 11:14:37.827: E/StrictMode(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-27 11:14:37.827: E/StrictMode(611): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-27 11:14:37.827: E/StrictMode(611): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-27 11:14:37.827: E/StrictMode(611): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-27 11:14:37.827: E/StrictMode(611): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-27 11:14:37.827: E/StrictMode(611): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-27 11:14:37.827: E/StrictMode(611): at java.lang.Thread.run(Thread.java:856)
06-27 11:14:37.847: D/dalvikvm(611): GC_CONCURRENT freed 384K, 18% free 2477K/3004K, paused 72ms+80ms, total 275ms
06-27 11:14:37.847: W/ActivityManager(290): Unbind failed: could not find connection for android.os.BinderProxy@40f56dd0'