我使用此代码来获取GPS传感器数据。Android-gps监听器
mlocManager = (LocationManager) getSystemService(Context.LOCATION_SERVICE);
mlocListener = new MyLocationListener();
mlocManager.requestLocationUpdates(LocationManager.GPS_PROVIDER, 2000, 1, mlocListener);
为什么我的gps图标不断打开和关闭?
如果你的意思是图标的闪烁,那么我猜你的手机GPS-Sensor会搜索卫星。 – lhlmgr
程序正确返回位置和速度,但图标仍然闪烁。我认为时间= 2000年发生了一些事情,但我不完全清楚。 –