| /* |
| * Copyright (C) 2017 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| package android.hardware.radio@1.2; |
| |
| import @1.1::IRadio; |
| import @1.1::RadioAccessNetworks; |
| |
| /** |
| * This interface is used by telephony and telecom to talk to cellular radio. |
| * All the functions have minimum one parameter: |
| * serial: which corresponds to serial no. of request. Serial numbers must only be memorized for the |
| * duration of a method call. If clients provide colliding serials (including passing the same |
| * serial to different methods), multiple responses (one for each method call) must still be served. |
| * setResponseFunctions must work with @1.1::IRadioResponse and @1.1::IRadioIndication. |
| */ |
| interface IRadio extends @1.1::IRadio { |
| |
| /** |
| * Starts a network scan |
| * |
| * @param serial Serial number of request. |
| * @param request Defines the radio networks/bands/channels which need to be scanned. |
| * |
| * Response function is IRadioResponse.startNetworkScanResponse() |
| */ |
| oneway startNetworkScan_1_2(int32_t serial, NetworkScanRequest request); |
| |
| /** |
| * Sets the indication filter. |
| * |
| * Prevents the reporting of specified unsolicited indications from the radio. This is used |
| * for power saving in instances when those indications are not needed. If unset, defaults to |
| * @1.2::IndicationFilter:ALL. |
| * |
| * @param serial Serial number of request. |
| * @param indicationFilter 32-bit bitmap of IndicationFilter. Bits set to 1 indicate the |
| * indications are enabled. See @1.2::IndicationFilter for the definition of each bit. |
| * |
| * Response callback is IRadioResponse.setIndicationFilterResponse() |
| */ |
| oneway setIndicationFilter_1_2(int32_t serial, bitfield<IndicationFilter> indicationFilter); |
| |
| /** |
| * Sets the signal strength reporting criteria. |
| * |
| * The resulting reporting criteria are the AND of all the supplied criteria. |
| * |
| * Note: Reporting criteria must be individually set for each RAN. If unset, reporting criteria |
| * for that RAN are implementation-defined. |
| * |
| * Response callback is IRadioResponse.setSignalStrengthReportingCriteriaResponse(). |
| * |
| * @param serial Serial number of request. |
| * @param hysteresisMs A hysteresis time in milliseconds to prevent flapping. A value of 0 |
| * disables hysteresis. |
| * @param hysteresisDb An interval in dB defining the required magnitude change between reports. |
| * hysteresisDb must be smaller than the smallest threshold delta. An |
| * interval value of 0 disables hysteresis. |
| * @param thresholdsDbm A vector of trigger thresholds in dBm. A vector size of 0 disables the |
| * use of thresholds for reporting. |
| * @param ran The type of network for which to apply these thresholds. |
| */ |
| oneway setSignalStrengthReportingCriteria(int32_t serial, int32_t hysteresisMs, |
| int32_t hysteresisDb, vec<int32_t> thresholdsDbm, RadioAccessNetworks ran); |
| |
| /** |
| * Sets the link capacity reporting criteria. |
| * |
| * The resulting reporting criteria are the AND of all the supplied criteria. |
| * |
| * Note: Reporting criteria must be individually set for each RAN. If unset, reporting criteria |
| * for that RAN are implementation-defined. |
| * |
| * Response callback is IRadioResponse.setLinkCapacityReportingCriteriaResponse(). |
| * |
| * @param serial Serial number of request. |
| * @param hysteresisMs A hysteresis time in milliseconds to prevent flapping. A value of 0 |
| * disables hysteresis. |
| * @param hysteresisDlKbps An interval in kbps defining the required magnitude change between DL |
| * reports. hysteresisDlKbps must be smaller than the smallest threshold |
| * delta. A value of 0 disables hysteresis. |
| * @param hysteresisUlKbps An interval in kbps defining the required magnitude change between UL |
| * reports. hysteresisUlKbps must be smaller than the smallest threshold |
| * delta. A value of 0 disables hysteresis. |
| * @param thresholdsDownlinkKbps A vector of trigger thresholds in kbps for downlink reports. A |
| * vector size of 0 disables the use of DL thresholds for |
| * reporting. |
| * @param thresholdsUplinkKbps A vector of trigger thresholds in kbps for uplink reports. A |
| * vector size of 0 disables the use of UL thresholds for reporting. |
| * @param ran The type of network for which to apply these thresholds. |
| */ |
| oneway setLinkCapacityReportingCriteria(int32_t serial, int32_t hysteresisMs, |
| int32_t hysteresisDlKbps, int32_t hysteresisUlKbps, vec<int32_t> thresholdsDownlinkKbps, |
| vec<int32_t> thresholdsUplinkKbps, RadioAccessNetworks ran); |
| }; |