Loading src/java/com/android/internal/telephony/RIL.java +14 −4 Original line number Diff line number Diff line Loading @@ -1134,6 +1134,15 @@ public class RIL extends BaseCommands implements CommandsInterface { if (RILJ_LOGD) riljLog(rr.serialString() + "> " + requestToString(rr.mRequest)); if (mRadioVersion.greaterOrEqual(RADIO_HAL_VERSION_1_4)) { android.hardware.radio.V1_4.IRadio radioProxy14 = (android.hardware.radio.V1_4.IRadio) radioProxy; try { radioProxy14.getSignalStrength_1_4(rr.mSerial); } catch (RemoteException | RuntimeException e) { handleRadioProxyExceptionForRR(rr, "getSignalStrength_1_4", e); } } else { try { radioProxy.getSignalStrength(rr.mSerial); } catch (RemoteException | RuntimeException e) { Loading @@ -1141,6 +1150,7 @@ public class RIL extends BaseCommands implements CommandsInterface { } } } } @Override public void getVoiceRegistrationState(Message result) { Loading src/java/com/android/internal/telephony/RadioIndication.java +17 −0 Original line number Diff line number Diff line Loading @@ -270,6 +270,23 @@ public class RadioIndication extends IRadioIndication.Stub { } } /** * Indicates the current signal strength of the camped or primary serving cell. */ public void currentSignalStrength_1_4(int indicationType, android.hardware.radio.V1_4.SignalStrength signalStrength) { mRil.processIndication(indicationType); SignalStrength ss = new SignalStrength(signalStrength); if (RIL.RILJ_LOGV) mRil.unsljLogvRet(RIL_UNSOL_SIGNAL_STRENGTH, ss); if (mRil.mSignalStrengthRegistrant != null) { mRil.mSignalStrengthRegistrant.notifyRegistrant(new AsyncResult(null, ss, null)); } } /** * Indicates current physical channel configuration. */ Loading src/java/com/android/internal/telephony/RadioResponse.java +23 −0 Original line number Diff line number Diff line Loading @@ -283,6 +283,15 @@ public class RadioResponse extends IRadioResponse.Stub { android.hardware.radio.V1_2.SignalStrength signalStrength) { responseSignalStrength_1_2(responseInfo, signalStrength); } /** * @param responseInfo Response info struct containing response type, serial no. and error * @param signalStrength Current signal strength of camped/connected cells */ public void getSignalStrengthResponse_1_4( RadioResponseInfo responseInfo, android.hardware.radio.V1_4.SignalStrength signalStrength) { responseSignalStrength_1_4(responseInfo, signalStrength); } /** * @param responseInfo Response info struct containing response type, serial no. and error Loading Loading @@ -1888,6 +1897,20 @@ public class RadioResponse extends IRadioResponse.Stub { } } private void responseSignalStrength_1_4( RadioResponseInfo responseInfo, android.hardware.radio.V1_4.SignalStrength signalStrength) { RILRequest rr = mRil.processResponse(responseInfo); if (rr != null) { SignalStrength ret = new SignalStrength(signalStrength); if (responseInfo.error == RadioError.NONE) { sendMessageResponse(rr.mResult, ret); } mRil.processResponseDone(rr, responseInfo, ret); } } private void responseSms(RadioResponseInfo responseInfo, SendSmsResult sms) { RILRequest rr = mRil.processResponse(responseInfo); Loading src/java/com/android/internal/telephony/test/SimulatedCommands.java +5 −2 Original line number Diff line number Diff line Loading @@ -35,6 +35,7 @@ import android.telephony.CellInfoGsm; import android.telephony.CellSignalStrengthCdma; import android.telephony.CellSignalStrengthGsm; import android.telephony.CellSignalStrengthLte; import android.telephony.CellSignalStrengthNr; import android.telephony.CellSignalStrengthTdscdma; import android.telephony.CellSignalStrengthWcdma; import android.telephony.IccOpenLogicalChannelResponse; Loading Loading @@ -880,7 +881,8 @@ public class SimulatedCommands extends BaseCommands new CellSignalStrengthGsm(20, 0, CellInfo.UNAVAILABLE), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); } resultSuccess(result, mSignalStrength); } Loading Loading @@ -2160,7 +2162,8 @@ public class SimulatedCommands extends BaseCommands new CellSignalStrengthGsm(20, 0, CellInfo.UNAVAILABLE), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); } if (mSignalStrengthRegistrant != null) { Loading tests/telephonytests/src/com/android/internal/telephony/ServiceStateTrackerTest.java +11 −5 Original line number Diff line number Diff line Loading @@ -68,6 +68,7 @@ import android.telephony.CellSignalStrength; import android.telephony.CellSignalStrengthCdma; import android.telephony.CellSignalStrengthGsm; import android.telephony.CellSignalStrengthLte; import android.telephony.CellSignalStrengthNr; import android.telephony.CellSignalStrengthTdscdma; import android.telephony.CellSignalStrengthWcdma; import android.telephony.INetworkService; Loading Loading @@ -508,7 +509,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(-53, 0, SignalStrength.INVALID), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading @@ -522,7 +524,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte( -110, -114, -5, 0, SignalStrength.INVALID, SignalStrength.INVALID)); -110, -114, -5, 0, SignalStrength.INVALID, SignalStrength.INVALID), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading @@ -535,7 +538,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading Loading @@ -566,7 +570,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { -5, /* rsrq */ 0, /* rssnr */ SignalStrength.INVALID, /* cqi */ SignalStrength.INVALID /* ta */)); SignalStrength.INVALID /* ta */), new CellSignalStrengthNr()); mBundle.putBoolean(CarrierConfigManager.KEY_USE_ONLY_RSRP_FOR_LTE_SIGNAL_BAR_BOOL, true); Loading Loading @@ -603,7 +608,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(), new CellSignalStrengthWcdma(-79, 0, -85, -5), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); mSimulatedCommands.setSignalStrength(ss); mSimulatedCommands.notifySignalStrength(); Loading Loading
src/java/com/android/internal/telephony/RIL.java +14 −4 Original line number Diff line number Diff line Loading @@ -1134,6 +1134,15 @@ public class RIL extends BaseCommands implements CommandsInterface { if (RILJ_LOGD) riljLog(rr.serialString() + "> " + requestToString(rr.mRequest)); if (mRadioVersion.greaterOrEqual(RADIO_HAL_VERSION_1_4)) { android.hardware.radio.V1_4.IRadio radioProxy14 = (android.hardware.radio.V1_4.IRadio) radioProxy; try { radioProxy14.getSignalStrength_1_4(rr.mSerial); } catch (RemoteException | RuntimeException e) { handleRadioProxyExceptionForRR(rr, "getSignalStrength_1_4", e); } } else { try { radioProxy.getSignalStrength(rr.mSerial); } catch (RemoteException | RuntimeException e) { Loading @@ -1141,6 +1150,7 @@ public class RIL extends BaseCommands implements CommandsInterface { } } } } @Override public void getVoiceRegistrationState(Message result) { Loading
src/java/com/android/internal/telephony/RadioIndication.java +17 −0 Original line number Diff line number Diff line Loading @@ -270,6 +270,23 @@ public class RadioIndication extends IRadioIndication.Stub { } } /** * Indicates the current signal strength of the camped or primary serving cell. */ public void currentSignalStrength_1_4(int indicationType, android.hardware.radio.V1_4.SignalStrength signalStrength) { mRil.processIndication(indicationType); SignalStrength ss = new SignalStrength(signalStrength); if (RIL.RILJ_LOGV) mRil.unsljLogvRet(RIL_UNSOL_SIGNAL_STRENGTH, ss); if (mRil.mSignalStrengthRegistrant != null) { mRil.mSignalStrengthRegistrant.notifyRegistrant(new AsyncResult(null, ss, null)); } } /** * Indicates current physical channel configuration. */ Loading
src/java/com/android/internal/telephony/RadioResponse.java +23 −0 Original line number Diff line number Diff line Loading @@ -283,6 +283,15 @@ public class RadioResponse extends IRadioResponse.Stub { android.hardware.radio.V1_2.SignalStrength signalStrength) { responseSignalStrength_1_2(responseInfo, signalStrength); } /** * @param responseInfo Response info struct containing response type, serial no. and error * @param signalStrength Current signal strength of camped/connected cells */ public void getSignalStrengthResponse_1_4( RadioResponseInfo responseInfo, android.hardware.radio.V1_4.SignalStrength signalStrength) { responseSignalStrength_1_4(responseInfo, signalStrength); } /** * @param responseInfo Response info struct containing response type, serial no. and error Loading Loading @@ -1888,6 +1897,20 @@ public class RadioResponse extends IRadioResponse.Stub { } } private void responseSignalStrength_1_4( RadioResponseInfo responseInfo, android.hardware.radio.V1_4.SignalStrength signalStrength) { RILRequest rr = mRil.processResponse(responseInfo); if (rr != null) { SignalStrength ret = new SignalStrength(signalStrength); if (responseInfo.error == RadioError.NONE) { sendMessageResponse(rr.mResult, ret); } mRil.processResponseDone(rr, responseInfo, ret); } } private void responseSms(RadioResponseInfo responseInfo, SendSmsResult sms) { RILRequest rr = mRil.processResponse(responseInfo); Loading
src/java/com/android/internal/telephony/test/SimulatedCommands.java +5 −2 Original line number Diff line number Diff line Loading @@ -35,6 +35,7 @@ import android.telephony.CellInfoGsm; import android.telephony.CellSignalStrengthCdma; import android.telephony.CellSignalStrengthGsm; import android.telephony.CellSignalStrengthLte; import android.telephony.CellSignalStrengthNr; import android.telephony.CellSignalStrengthTdscdma; import android.telephony.CellSignalStrengthWcdma; import android.telephony.IccOpenLogicalChannelResponse; Loading Loading @@ -880,7 +881,8 @@ public class SimulatedCommands extends BaseCommands new CellSignalStrengthGsm(20, 0, CellInfo.UNAVAILABLE), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); } resultSuccess(result, mSignalStrength); } Loading Loading @@ -2160,7 +2162,8 @@ public class SimulatedCommands extends BaseCommands new CellSignalStrengthGsm(20, 0, CellInfo.UNAVAILABLE), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); } if (mSignalStrengthRegistrant != null) { Loading
tests/telephonytests/src/com/android/internal/telephony/ServiceStateTrackerTest.java +11 −5 Original line number Diff line number Diff line Loading @@ -68,6 +68,7 @@ import android.telephony.CellSignalStrength; import android.telephony.CellSignalStrengthCdma; import android.telephony.CellSignalStrengthGsm; import android.telephony.CellSignalStrengthLte; import android.telephony.CellSignalStrengthNr; import android.telephony.CellSignalStrengthTdscdma; import android.telephony.CellSignalStrengthWcdma; import android.telephony.INetworkService; Loading Loading @@ -508,7 +509,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(-53, 0, SignalStrength.INVALID), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading @@ -522,7 +524,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte( -110, -114, -5, 0, SignalStrength.INVALID, SignalStrength.INVALID)); -110, -114, -5, 0, SignalStrength.INVALID, SignalStrength.INVALID), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading @@ -535,7 +538,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(), new CellSignalStrengthWcdma(), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); sendSignalStrength(ss); assertEquals(sst.getSignalStrength(), ss); Loading Loading @@ -566,7 +570,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { -5, /* rsrq */ 0, /* rssnr */ SignalStrength.INVALID, /* cqi */ SignalStrength.INVALID /* ta */)); SignalStrength.INVALID /* ta */), new CellSignalStrengthNr()); mBundle.putBoolean(CarrierConfigManager.KEY_USE_ONLY_RSRP_FOR_LTE_SIGNAL_BAR_BOOL, true); Loading Loading @@ -603,7 +608,8 @@ public class ServiceStateTrackerTest extends TelephonyTest { new CellSignalStrengthGsm(), new CellSignalStrengthWcdma(-79, 0, -85, -5), new CellSignalStrengthTdscdma(), new CellSignalStrengthLte()); new CellSignalStrengthLte(), new CellSignalStrengthNr()); mSimulatedCommands.setSignalStrength(ss); mSimulatedCommands.notifySignalStrength(); Loading