Android 安卓:获取附近所有的手机运营商及其信号强度
我想通过编程方式在Android上获取附近所有的手机运营商及其信号强度。Android 安卓:获取附近所有的手机运营商及其信号强度,android,telephony,Android,Telephony,我想通过编程方式在Android上获取附近所有的手机运营商及其信号强度。 使用PhoneStateListener,我能够获得我当前注册的载波的信号强度,但我没有找到找到附近其他载波的信号强度的方法。 我怎样才能做到这一点 Use this for getting cellular carrier name // Get System TELEPHONY service reference TelephonyManager telephonyManager = (TelephonyManage
使用
PhoneStateListener
,我能够获得我当前注册的载波的信号强度,但我没有找到找到附近其他载波的信号强度的方法。我怎样才能做到这一点
Use this for getting cellular carrier name
// Get System TELEPHONY service reference
TelephonyManager telephonyManager = (TelephonyManager) getBaseContext()
.getSystemService(Context.TELEPHONY_SERVICE);
// Get carrier name (Network Operator Name)
String carrierName = telephonyManager.getNetworkOperatorName();
For getting Signal Strength
TelephonyManager telephonyManager = (TelephonyManager)this.getSystemService(Context.TELEPHONY_SERVICE);`
CellInfoGsm cellinfogsm = (CellInfoGsm)telephonyManager.getAllCellInfo().get(0);
CellSignalStrengthGsm cellSignalStrengthGsm = cellinfogsm.getCellSignalStrength();
cellSignalStrengthGsm.getDbm();
希望对您有所帮助dup: