读书人

电顺手机通过基站获取gps

发布时间: 2012-09-01 09:33:02 作者: rapoo

电信手机通过基站获取gps

TelephonyManager manager = (TelephonyManager)getSystemService(Context.TELEPHONY_SERVICE);CdmaCellLocation cdma = (CdmaCellLocation) manager.getCellLocation();int latint = cdma.getBaseStationLatitude();int longint = cdma.getBaseStationLongitude();double lat = ((double) latint)/14400.0;double lon = ((double)longint)/14400.0;

读书人网 >移动开发

热点推荐