Malcolm Chen | 360e1f9 | 2019-10-02 11:38:13 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2019 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | package android.hardware.radio@1.5; |
| 18 | |
| 19 | import @1.4::IRadio; |
sqian | f1850bf | 2019-11-12 18:26:30 -0800 | [diff] [blame] | 20 | import @1.5::AccessNetwork; |
| 21 | import @1.5::SignalThresholdInfo; |
Malcolm Chen | 360e1f9 | 2019-10-02 11:38:13 -0700 | [diff] [blame] | 22 | |
| 23 | /** |
| 24 | * This interface is used by telephony and telecom to talk to cellular radio. |
| 25 | * All the functions have minimum one parameter: |
| 26 | * serial: which corresponds to serial no. of request. Serial numbers must only be memorized for the |
| 27 | * duration of a method call. If clients provide colliding serials (including passing the same |
| 28 | * serial to different methods), multiple responses (one for each method call) must still be served. |
| 29 | * setResponseFunctions must work with @1.5::IRadioResponse and @1.5::IRadioIndication. |
| 30 | */ |
| 31 | interface IRadio extends @1.4::IRadio { |
sqian | f1850bf | 2019-11-12 18:26:30 -0800 | [diff] [blame] | 32 | |
| 33 | /** |
| 34 | * Sets the signal strength reporting criteria. |
| 35 | * |
| 36 | * The resulting reporting rules are the AND of all the supplied criteria. For each RAN |
| 37 | * The hysteresisDb and thresholds apply to only the following measured quantities: |
| 38 | * -GERAN - RSSI |
| 39 | * -CDMA2000 - RSSI |
| 40 | * -UTRAN - RSCP |
| 41 | * -EUTRAN - RSRP/RSRQ/RSSNR |
| 42 | * -NGRAN - SSRSRP/SSRSRQ/SSSINR |
| 43 | * |
| 44 | * Note: Reporting criteria must be individually set for each RAN. For any unset reporting |
| 45 | * criteria, the value is implementation-defined. |
| 46 | * |
| 47 | * Response callback is |
| 48 | * IRadioResponse.setSignalStrengthReportingCriteriaResponse_1_5() |
| 49 | * |
| 50 | * @param serial Serial number of request. |
| 51 | * @param signalThresholdInfo Signal threshold info including the threshold values, |
| 52 | * hysteresisDb, and hysteresisMs. See @1.5::SignalThresholdInfo |
| 53 | * for details. |
| 54 | * @param accessNetwork The type of network for which to apply these thresholds. |
| 55 | */ |
| 56 | oneway setSignalStrengthReportingCriteria_1_5(int32_t serial, |
| 57 | SignalThresholdInfo signalThresholdInfo, AccessNetwork accessNetwork); |
Malcolm Chen | fb6d624 | 2019-11-12 19:03:12 -0800 | [diff] [blame] | 58 | |
| 59 | /** |
| 60 | * Enable or disable UiccApplications on the SIM. If disabled: |
| 61 | * - Modem will not register on any network. |
| 62 | * - SIM must be PRESENT, and the IccId of the SIM must still be accessible. |
| 63 | * - The corresponding modem stack is still functional, e.g. able to make emergency calls or |
| 64 | * do network scan. |
| 65 | * By default if this API is not called, the uiccApplications must be enabled automatically. |
| 66 | * It must work for both single SIM and DSDS cases for UX consistency. |
| 67 | * The preference is per SIM, and must be remembered over power cycle, modem reboot, or SIM |
| 68 | * insertion / unplug. |
| 69 | * |
| 70 | * @param serial: Serial number of request. |
| 71 | * @param enable: true if to enable uiccApplications, false to disable. |
| 72 | |
| 73 | * Response callback is IRadioResponse.enableUiccApplicationsResponse() |
| 74 | */ |
| 75 | oneway enableUiccApplications(int32_t serial, bool enable); |
| 76 | |
| 77 | /** |
| 78 | * Whether uiccApplications are enabled, or disabled. |
| 79 | * |
| 80 | * By default uiccApplications must be enabled, unless enableUiccApplications() with enable |
| 81 | * being false is called. |
| 82 | * |
| 83 | * @param serial Serial number of request. |
| 84 | * |
| 85 | * Response callback is IRadioResponse.areUiccApplicationsEnabledResponse() |
| 86 | */ |
| 87 | oneway areUiccApplicationsEnabled(int32_t serial); |
| 88 | |
| 89 | /** |
| 90 | * Query whether disabling and enabling UiccApplications functionality is supported. If not, |
| 91 | * calling enableUiccApplications with a different value will return |
| 92 | * RadioError:REQUEST_NOT_SUPPORTED. |
| 93 | * |
| 94 | * @param serial Serial number of request. |
| 95 | * |
| 96 | * Response callback is IRadioResponse.canToggleUiccApplicationsEnablementResponse() |
| 97 | */ |
| 98 | oneway canToggleUiccApplicationsEnablement(int32_t serial); |
Malcolm Chen | 360e1f9 | 2019-10-02 11:38:13 -0700 | [diff] [blame] | 99 | }; |