The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2006 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 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 17 | #ifndef ANDROID_RIL_H |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 18 | #define ANDROID_RIL_H 1 |
| 19 | |
| 20 | #include <stdlib.h> |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 21 | #include <stdint.h> |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 22 | #include <telephony/ril_cdma_sms.h> |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 23 | #include <telephony/ril_nv_items.h> |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 24 | #include <telephony/ril_msim.h> |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 25 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 26 | #ifndef FEATURE_UNIT_TEST |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 27 | #include <sys/time.h> |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 28 | #endif /* !FEATURE_UNIT_TEST */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 29 | |
| 30 | #ifdef __cplusplus |
| 31 | extern "C" { |
| 32 | #endif |
| 33 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 34 | |
| 35 | #if defined(ANDROID_SIM_COUNT_2) |
| 36 | #define SIM_COUNT 2 |
| 37 | #elif defined(ANDROID_SIM_COUNT_3) |
| 38 | #define SIM_COUNT 3 |
| 39 | #elif defined(ANDROID_SIM_COUNT_4) |
| 40 | #define SIM_COUNT 4 |
| 41 | #else |
| 42 | #define SIM_COUNT 1 |
| 43 | #endif |
| 44 | |
| 45 | #ifndef ANDROID_MULTI_SIM |
| 46 | #define SIM_COUNT 1 |
| 47 | #endif |
| 48 | |
Sanket Padawe | 88cf6a5 | 2016-01-11 12:45:43 -0800 | [diff] [blame] | 49 | /* |
| 50 | * RIL version. |
| 51 | * Value of RIL_VERSION should not be changed in future. Here onwards, |
| 52 | * when a new change is supposed to be introduced which could involve new |
| 53 | * schemes added like Wakelocks, data structures added/updated, etc, we would |
| 54 | * just document RIL version associated with that change below. When OEM updates its |
| 55 | * RIL with those changes, they would return that new RIL version during RIL_REGISTER. |
| 56 | * We should make use of the returned version by vendor to identify appropriate scheme |
| 57 | * or data structure version to use. |
| 58 | * |
| 59 | * Documentation of RIL version and associated changes |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 60 | * RIL_VERSION = 12 : This version corresponds to updated data structures namely |
Sanket Padawe | 88cf6a5 | 2016-01-11 12:45:43 -0800 | [diff] [blame] | 61 | * RIL_Data_Call_Response_v11, RIL_SIM_IO_v6, RIL_CardStatus_v6, |
| 62 | * RIL_SimRefreshResponse_v7, RIL_CDMA_CallWaiting_v6, |
Sanket Padawe | 6ff9a87 | 2016-01-27 15:09:12 -0800 | [diff] [blame] | 63 | * RIL_LTE_SignalStrength_v8, RIL_SignalStrength_v10, RIL_CellIdentityGsm_v12 |
| 64 | * RIL_CellIdentityWcdma_v12, RIL_CellIdentityLte_v12,RIL_CellInfoGsm_v12, |
| 65 | * RIL_CellInfoWcdma_v12, RIL_CellInfoLte_v12, RIL_CellInfo_v12. |
Sanket Padawe | 88cf6a5 | 2016-01-11 12:45:43 -0800 | [diff] [blame] | 66 | * |
Sanket Padawe | 6ff9a87 | 2016-01-27 15:09:12 -0800 | [diff] [blame] | 67 | * RIL_VERSION = 13 : This version includes new wakelock semantics and as the first |
Robert Greenwalt | 27e99c5 | 2016-06-01 16:31:38 -0700 | [diff] [blame] | 68 | * strongly versioned version it enforces structure use. |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 69 | * |
Robert Greenwalt | 27e99c5 | 2016-06-01 16:31:38 -0700 | [diff] [blame] | 70 | * RIL_VERSION = 14 : New data structures are added, namely RIL_CarrierMatchType, |
| 71 | * RIL_Carrier, RIL_CarrierRestrictions and RIL_PCO_Data. |
| 72 | * New commands added: RIL_REQUEST_SET_CARRIER_RESTRICTIONS, |
Wileen Chiu | 718c0bf | 2017-01-04 11:37:19 -0800 | [diff] [blame] | 73 | * RIL_REQUEST_SET_CARRIER_RESTRICTIONS and RIL_UNSOL_PCO_DATA. |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 74 | * |
Wileen Chiu | 718c0bf | 2017-01-04 11:37:19 -0800 | [diff] [blame] | 75 | * RIL_VERSION = 15 : New commands added: |
| 76 | * RIL_REQUEST_SEND_DEVICE_STATE, |
| 77 | * RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER, |
pkanwar | c61837e | 2017-03-17 12:49:34 -0700 | [diff] [blame] | 78 | * RIL_REQUEST_SET_SIM_CARD_POWER, |
| 79 | * RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION, |
| 80 | * RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION |
Wileen Chiu | 718c0bf | 2017-01-04 11:37:19 -0800 | [diff] [blame] | 81 | * The new parameters for RIL_REQUEST_SETUP_DATA_CALL, |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 82 | * Updated data structures: RIL_DataProfileInfo_v15, RIL_InitialAttachApn_v15 |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 83 | * New data structure RIL_DataRegistrationStateResponse, |
| 84 | * RIL_VoiceRegistrationStateResponse same is |
| 85 | * used in RIL_REQUEST_DATA_REGISTRATION_STATE and |
| 86 | * RIL_REQUEST_VOICE_REGISTRATION_STATE respectively. |
Wileen Chiu | 410b756 | 2015-11-23 14:25:22 -0800 | [diff] [blame] | 87 | * New data structure RIL_OpenChannelParams. |
Sanket Padawe | 88cf6a5 | 2016-01-11 12:45:43 -0800 | [diff] [blame] | 88 | */ |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 89 | #define RIL_VERSION 12 |
| 90 | #define LAST_IMPRECISE_RIL_VERSION 12 // Better self-documented name |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 91 | #define RIL_VERSION_MIN 6 /* Minimum RIL_VERSION supported */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 92 | |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 93 | #define CDMA_ALPHA_INFO_BUFFER_LENGTH 64 |
| 94 | #define CDMA_NUMBER_INFO_BUFFER_LENGTH 81 |
| 95 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 96 | #define MAX_RILDS 3 |
Amit Mahajan | 7955c43 | 2017-03-28 11:17:55 -0700 | [diff] [blame] | 97 | #define MAX_SERVICE_NAME_LENGTH 6 |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 98 | #define MAX_CLIENT_ID_LENGTH 2 |
| 99 | #define MAX_DEBUG_SOCKET_NAME_LENGTH 12 |
| 100 | #define MAX_QEMU_PIPE_NAME_LENGTH 11 |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 101 | #define MAX_UUID_LENGTH 64 |
| 102 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 103 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 104 | typedef void * RIL_Token; |
| 105 | |
| 106 | typedef enum { |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 107 | RIL_SOCKET_1, |
| 108 | #if (SIM_COUNT >= 2) |
| 109 | RIL_SOCKET_2, |
| 110 | #if (SIM_COUNT >= 3) |
| 111 | RIL_SOCKET_3, |
| 112 | #endif |
| 113 | #if (SIM_COUNT >= 4) |
| 114 | RIL_SOCKET_4, |
| 115 | #endif |
| 116 | #endif |
| 117 | RIL_SOCKET_NUM |
| 118 | } RIL_SOCKET_ID; |
| 119 | |
| 120 | |
| 121 | typedef enum { |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 122 | RIL_E_SUCCESS = 0, |
| 123 | RIL_E_RADIO_NOT_AVAILABLE = 1, /* If radio did not start or is resetting */ |
| 124 | RIL_E_GENERIC_FAILURE = 2, |
| 125 | RIL_E_PASSWORD_INCORRECT = 3, /* for PIN/PIN2 methods only! */ |
| 126 | RIL_E_SIM_PIN2 = 4, /* Operation requires SIM PIN2 to be entered */ |
| 127 | RIL_E_SIM_PUK2 = 5, /* Operation requires SIM PIN2 to be entered */ |
| 128 | RIL_E_REQUEST_NOT_SUPPORTED = 6, |
| 129 | RIL_E_CANCELLED = 7, |
| 130 | RIL_E_OP_NOT_ALLOWED_DURING_VOICE_CALL = 8, /* data ops are not allowed during voice |
| 131 | call on a Class C GPRS device */ |
| 132 | RIL_E_OP_NOT_ALLOWED_BEFORE_REG_TO_NW = 9, /* data ops are not allowed before device |
| 133 | registers in network */ |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 134 | RIL_E_SMS_SEND_FAIL_RETRY = 10, /* fail to send sms and need retry */ |
| 135 | RIL_E_SIM_ABSENT = 11, /* fail to set the location where CDMA subscription |
| 136 | shall be retrieved because of SIM or RUIM |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 137 | card absent */ |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 138 | RIL_E_SUBSCRIPTION_NOT_AVAILABLE = 12, /* fail to find CDMA subscription from specified |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 139 | location */ |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 140 | RIL_E_MODE_NOT_SUPPORTED = 13, /* HW does not support preferred network type */ |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 141 | RIL_E_FDN_CHECK_FAILURE = 14, /* command failed because recipient is not on FDN list */ |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 142 | RIL_E_ILLEGAL_SIM_OR_ME = 15, /* network selection failed due to |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 143 | illegal SIM or ME */ |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 144 | RIL_E_MISSING_RESOURCE = 16, /* no logical channel available */ |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 145 | RIL_E_NO_SUCH_ELEMENT = 17, /* application not found on SIM */ |
| 146 | RIL_E_DIAL_MODIFIED_TO_USSD = 18, /* DIAL request modified to USSD */ |
| 147 | RIL_E_DIAL_MODIFIED_TO_SS = 19, /* DIAL request modified to SS */ |
| 148 | RIL_E_DIAL_MODIFIED_TO_DIAL = 20, /* DIAL request modified to DIAL with different |
| 149 | data */ |
| 150 | RIL_E_USSD_MODIFIED_TO_DIAL = 21, /* USSD request modified to DIAL */ |
| 151 | RIL_E_USSD_MODIFIED_TO_SS = 22, /* USSD request modified to SS */ |
| 152 | RIL_E_USSD_MODIFIED_TO_USSD = 23, /* USSD request modified to different USSD |
| 153 | request */ |
| 154 | RIL_E_SS_MODIFIED_TO_DIAL = 24, /* SS request modified to DIAL */ |
| 155 | RIL_E_SS_MODIFIED_TO_USSD = 25, /* SS request modified to USSD */ |
| 156 | RIL_E_SUBSCRIPTION_NOT_SUPPORTED = 26, /* Subscription not supported by RIL */ |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 157 | RIL_E_SS_MODIFIED_TO_SS = 27, /* SS request modified to different SS request */ |
Sooraj Sasindran | 7e333b3 | 2016-01-27 14:30:45 -0800 | [diff] [blame] | 158 | RIL_E_LCE_NOT_SUPPORTED = 36, /* LCE service not supported(36 in RILConstants.java) */ |
| 159 | RIL_E_NO_MEMORY = 37, /* Not sufficient memory to process the request */ |
Jayachandran C | b0cba83 | 2017-03-13 19:17:18 -0700 | [diff] [blame] | 160 | RIL_E_INTERNAL_ERR = 38, /* Modem hit unexpected error scenario while handling |
| 161 | this request */ |
Sooraj Sasindran | 7e333b3 | 2016-01-27 14:30:45 -0800 | [diff] [blame] | 162 | RIL_E_SYSTEM_ERR = 39, /* Hit platform or system error */ |
Jayachandran C | b0cba83 | 2017-03-13 19:17:18 -0700 | [diff] [blame] | 163 | RIL_E_MODEM_ERR = 40, /* Vendor RIL got unexpected or incorrect response |
| 164 | from modem for this request */ |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 165 | RIL_E_INVALID_STATE = 41, /* Unexpected request for the current state */ |
Sooraj Sasindran | 7e333b3 | 2016-01-27 14:30:45 -0800 | [diff] [blame] | 166 | RIL_E_NO_RESOURCES = 42, /* Not sufficient resource to process the request */ |
| 167 | RIL_E_SIM_ERR = 43, /* Received error from SIM card */ |
| 168 | RIL_E_INVALID_ARGUMENTS = 44, /* Received invalid arguments in request */ |
| 169 | RIL_E_INVALID_SIM_STATE = 45, /* Can not process the request in current SIM state */ |
| 170 | RIL_E_INVALID_MODEM_STATE = 46, /* Can not process the request in current Modem state */ |
| 171 | RIL_E_INVALID_CALL_ID = 47, /* Received invalid call id in request */ |
| 172 | RIL_E_NO_SMS_TO_ACK = 48, /* ACK received when there is no SMS to ack */ |
Nathan Harold | c97b284 | 2016-02-02 12:04:35 -0800 | [diff] [blame] | 173 | RIL_E_NETWORK_ERR = 49, /* Received error from network */ |
Sanket Padawe | 0106aed | 2016-02-09 09:56:31 -0800 | [diff] [blame] | 174 | RIL_E_REQUEST_RATE_LIMITED = 50, /* Operation denied due to overly-frequent requests */ |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 175 | RIL_E_SIM_BUSY = 51, /* SIM is busy */ |
| 176 | RIL_E_SIM_FULL = 52, /* The target EF is full */ |
| 177 | RIL_E_NETWORK_REJECT = 53, /* Request is rejected by network */ |
| 178 | RIL_E_OPERATION_NOT_ALLOWED = 54, /* Not allowed the request now */ |
| 179 | RIL_E_EMPTY_RECORD = 55, /* The request record is empty */ |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 180 | RIL_E_INVALID_SMS_FORMAT = 56, /* Invalid sms format */ |
| 181 | RIL_E_ENCODING_ERR = 57, /* Message not encoded properly */ |
| 182 | RIL_E_INVALID_SMSC_ADDRESS = 58, /* SMSC address specified is invalid */ |
| 183 | RIL_E_NO_SUCH_ENTRY = 59, /* No such entry present to perform the request */ |
| 184 | RIL_E_NETWORK_NOT_READY = 60, /* Network is not ready to perform the request */ |
| 185 | RIL_E_NOT_PROVISIONED = 61, /* Device doesnot have this value provisioned */ |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 186 | RIL_E_NO_SUBSCRIPTION = 62, /* Device doesnot have subscription */ |
| 187 | RIL_E_NO_NETWORK_FOUND = 63, /* Network cannot be found */ |
| 188 | RIL_E_DEVICE_IN_USE = 64, /* Operation cannot be performed because the device |
| 189 | is currently in use */ |
| 190 | RIL_E_ABORTED = 65, /* Operation aborted */ |
Sanket Padawe | f220dc5 | 2017-01-02 23:46:00 -0800 | [diff] [blame] | 191 | RIL_E_INVALID_RESPONSE = 66, /* Invalid response sent by vendor code */ |
Sanket Padawe | 0106aed | 2016-02-09 09:56:31 -0800 | [diff] [blame] | 192 | // OEM specific error codes. To be used by OEM when they don't want to reveal |
| 193 | // specific error codes which would be replaced by Generic failure. |
| 194 | RIL_E_OEM_ERROR_1 = 501, |
| 195 | RIL_E_OEM_ERROR_2 = 502, |
| 196 | RIL_E_OEM_ERROR_3 = 503, |
| 197 | RIL_E_OEM_ERROR_4 = 504, |
| 198 | RIL_E_OEM_ERROR_5 = 505, |
| 199 | RIL_E_OEM_ERROR_6 = 506, |
| 200 | RIL_E_OEM_ERROR_7 = 507, |
| 201 | RIL_E_OEM_ERROR_8 = 508, |
| 202 | RIL_E_OEM_ERROR_9 = 509, |
| 203 | RIL_E_OEM_ERROR_10 = 510, |
| 204 | RIL_E_OEM_ERROR_11 = 511, |
| 205 | RIL_E_OEM_ERROR_12 = 512, |
| 206 | RIL_E_OEM_ERROR_13 = 513, |
| 207 | RIL_E_OEM_ERROR_14 = 514, |
| 208 | RIL_E_OEM_ERROR_15 = 515, |
| 209 | RIL_E_OEM_ERROR_16 = 516, |
| 210 | RIL_E_OEM_ERROR_17 = 517, |
| 211 | RIL_E_OEM_ERROR_18 = 518, |
| 212 | RIL_E_OEM_ERROR_19 = 519, |
| 213 | RIL_E_OEM_ERROR_20 = 520, |
| 214 | RIL_E_OEM_ERROR_21 = 521, |
| 215 | RIL_E_OEM_ERROR_22 = 522, |
| 216 | RIL_E_OEM_ERROR_23 = 523, |
| 217 | RIL_E_OEM_ERROR_24 = 524, |
| 218 | RIL_E_OEM_ERROR_25 = 525 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 219 | } RIL_Errno; |
| 220 | |
| 221 | typedef enum { |
| 222 | RIL_CALL_ACTIVE = 0, |
| 223 | RIL_CALL_HOLDING = 1, |
| 224 | RIL_CALL_DIALING = 2, /* MO call only */ |
| 225 | RIL_CALL_ALERTING = 3, /* MO call only */ |
| 226 | RIL_CALL_INCOMING = 4, /* MT call only */ |
| 227 | RIL_CALL_WAITING = 5 /* MT call only */ |
| 228 | } RIL_CallState; |
| 229 | |
| 230 | typedef enum { |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 231 | RADIO_STATE_OFF = 0, /* Radio explictly powered off (eg CFUN=0) */ |
| 232 | RADIO_STATE_UNAVAILABLE = 1, /* Radio unavailable (eg, resetting or not booted) */ |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 233 | RADIO_STATE_ON = 10 /* Radio is on */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 234 | } RIL_RadioState; |
| 235 | |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 236 | typedef enum { |
| 237 | RADIO_TECH_UNKNOWN = 0, |
| 238 | RADIO_TECH_GPRS = 1, |
| 239 | RADIO_TECH_EDGE = 2, |
| 240 | RADIO_TECH_UMTS = 3, |
| 241 | RADIO_TECH_IS95A = 4, |
| 242 | RADIO_TECH_IS95B = 5, |
| 243 | RADIO_TECH_1xRTT = 6, |
| 244 | RADIO_TECH_EVDO_0 = 7, |
| 245 | RADIO_TECH_EVDO_A = 8, |
| 246 | RADIO_TECH_HSDPA = 9, |
| 247 | RADIO_TECH_HSUPA = 10, |
| 248 | RADIO_TECH_HSPA = 11, |
| 249 | RADIO_TECH_EVDO_B = 12, |
| 250 | RADIO_TECH_EHRPD = 13, |
Glenn Kasten | c941961 | 2011-02-02 17:44:18 -0800 | [diff] [blame] | 251 | RADIO_TECH_LTE = 14, |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 252 | RADIO_TECH_HSPAP = 15, // HSPA+ |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 253 | RADIO_TECH_GSM = 16, // Only supports voice |
Yashdev Singh | 3c8f37c | 2015-02-23 13:04:28 -0800 | [diff] [blame] | 254 | RADIO_TECH_TD_SCDMA = 17, |
Ajay Nambi | 6dbb43c | 2015-05-14 18:50:20 -0700 | [diff] [blame] | 255 | RADIO_TECH_IWLAN = 18, |
| 256 | RADIO_TECH_LTE_CA = 19 |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 257 | } RIL_RadioTechnology; |
| 258 | |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 259 | typedef enum { |
| 260 | RAF_UNKNOWN = (1 << RADIO_TECH_UNKNOWN), |
| 261 | RAF_GPRS = (1 << RADIO_TECH_GPRS), |
| 262 | RAF_EDGE = (1 << RADIO_TECH_EDGE), |
| 263 | RAF_UMTS = (1 << RADIO_TECH_UMTS), |
| 264 | RAF_IS95A = (1 << RADIO_TECH_IS95A), |
| 265 | RAF_IS95B = (1 << RADIO_TECH_IS95B), |
| 266 | RAF_1xRTT = (1 << RADIO_TECH_1xRTT), |
| 267 | RAF_EVDO_0 = (1 << RADIO_TECH_EVDO_0), |
| 268 | RAF_EVDO_A = (1 << RADIO_TECH_EVDO_A), |
| 269 | RAF_HSDPA = (1 << RADIO_TECH_HSDPA), |
| 270 | RAF_HSUPA = (1 << RADIO_TECH_HSUPA), |
| 271 | RAF_HSPA = (1 << RADIO_TECH_HSPA), |
| 272 | RAF_EVDO_B = (1 << RADIO_TECH_EVDO_B), |
| 273 | RAF_EHRPD = (1 << RADIO_TECH_EHRPD), |
| 274 | RAF_LTE = (1 << RADIO_TECH_LTE), |
| 275 | RAF_HSPAP = (1 << RADIO_TECH_HSPAP), |
| 276 | RAF_GSM = (1 << RADIO_TECH_GSM), |
| 277 | RAF_TD_SCDMA = (1 << RADIO_TECH_TD_SCDMA), |
Ajay Nambi | 6dbb43c | 2015-05-14 18:50:20 -0700 | [diff] [blame] | 278 | RAF_LTE_CA = (1 << RADIO_TECH_LTE_CA) |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 279 | } RIL_RadioAccessFamily; |
| 280 | |
| 281 | typedef enum { |
Nathan Harold | 92839f1 | 2016-02-12 10:02:28 -0800 | [diff] [blame] | 282 | BAND_MODE_UNSPECIFIED = 0, //"unspecified" (selected by baseband automatically) |
| 283 | BAND_MODE_EURO = 1, //"EURO band" (GSM-900 / DCS-1800 / WCDMA-IMT-2000) |
| 284 | BAND_MODE_USA = 2, //"US band" (GSM-850 / PCS-1900 / WCDMA-850 / WCDMA-PCS-1900) |
| 285 | BAND_MODE_JPN = 3, //"JPN band" (WCDMA-800 / WCDMA-IMT-2000) |
| 286 | BAND_MODE_AUS = 4, //"AUS band" (GSM-900 / DCS-1800 / WCDMA-850 / WCDMA-IMT-2000) |
| 287 | BAND_MODE_AUS_2 = 5, //"AUS band 2" (GSM-900 / DCS-1800 / WCDMA-850) |
| 288 | BAND_MODE_CELL_800 = 6, //"Cellular" (800-MHz Band) |
| 289 | BAND_MODE_PCS = 7, //"PCS" (1900-MHz Band) |
| 290 | BAND_MODE_JTACS = 8, //"Band Class 3" (JTACS Band) |
| 291 | BAND_MODE_KOREA_PCS = 9, //"Band Class 4" (Korean PCS Band) |
| 292 | BAND_MODE_5_450M = 10, //"Band Class 5" (450-MHz Band) |
| 293 | BAND_MODE_IMT2000 = 11, //"Band Class 6" (2-GMHz IMT2000 Band) |
| 294 | BAND_MODE_7_700M_2 = 12, //"Band Class 7" (Upper 700-MHz Band) |
| 295 | BAND_MODE_8_1800M = 13, //"Band Class 8" (1800-MHz Band) |
| 296 | BAND_MODE_9_900M = 14, //"Band Class 9" (900-MHz Band) |
| 297 | BAND_MODE_10_800M_2 = 15, //"Band Class 10" (Secondary 800-MHz Band) |
| 298 | BAND_MODE_EURO_PAMR_400M = 16, //"Band Class 11" (400-MHz European PAMR Band) |
| 299 | BAND_MODE_AWS = 17, //"Band Class 15" (AWS Band) |
| 300 | BAND_MODE_USA_2500M = 18 //"Band Class 16" (US 2.5-GHz Band) |
| 301 | } RIL_RadioBandMode; |
| 302 | |
| 303 | typedef enum { |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 304 | RC_PHASE_CONFIGURED = 0, // LM is configured is initial value and value after FINISH completes |
| 305 | RC_PHASE_START = 1, // START is sent before Apply and indicates that an APPLY will be |
| 306 | // forthcoming with these same parameters |
| 307 | RC_PHASE_APPLY = 2, // APPLY is sent after all LM's receive START and returned |
| 308 | // RIL_RadioCapability.status = 0, if any START's fail no |
| 309 | // APPLY will be sent |
| 310 | RC_PHASE_UNSOL_RSP = 3, // UNSOL_RSP is sent with RIL_UNSOL_RADIO_CAPABILITY |
| 311 | RC_PHASE_FINISH = 4 // FINISH is sent after all commands have completed. If an error |
| 312 | // occurs in any previous command the RIL_RadioAccessesFamily and |
Legler Wu | 8caf06f | 2014-10-29 14:02:14 +0800 | [diff] [blame] | 313 | // logicalModemUuid fields will be the prior configuration thus |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 314 | // restoring the configuration to the previous value. An error |
| 315 | // returned by this command will generally be ignored or may |
| 316 | // cause that logical modem to be removed from service. |
| 317 | } RadioCapabilityPhase; |
| 318 | |
| 319 | typedef enum { |
| 320 | RC_STATUS_NONE = 0, // This parameter has no meaning with RC_PHASE_START, |
| 321 | // RC_PHASE_APPLY |
| 322 | RC_STATUS_SUCCESS = 1, // Tell modem the action transaction of set radio |
| 323 | // capability was success with RC_PHASE_FINISH |
| 324 | RC_STATUS_FAIL = 2, // Tell modem the action transaction of set radio |
| 325 | // capability is fail with RC_PHASE_FINISH. |
| 326 | } RadioCapabilityStatus; |
| 327 | |
| 328 | #define RIL_RADIO_CAPABILITY_VERSION 1 |
| 329 | typedef struct { |
Legler Wu | 8caf06f | 2014-10-29 14:02:14 +0800 | [diff] [blame] | 330 | int version; // Version of structure, RIL_RADIO_CAPABILITY_VERSION |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 331 | int session; // Unique session value defined by framework returned in all "responses/unsol" |
| 332 | int phase; // CONFIGURED, START, APPLY, FINISH |
| 333 | int rat; // RIL_RadioAccessFamily for the radio |
| 334 | char logicalModemUuid[MAX_UUID_LENGTH]; // A UUID typically "com.xxxx.lmX where X is the logical modem. |
| 335 | int status; // Return status and an input parameter for RC_PHASE_FINISH |
| 336 | } RIL_RadioCapability; |
| 337 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 338 | // Do we want to split Data from Voice and the use |
| 339 | // RIL_RadioTechnology for get/setPreferredVoice/Data ? |
| 340 | typedef enum { |
| 341 | PREF_NET_TYPE_GSM_WCDMA = 0, /* GSM/WCDMA (WCDMA preferred) */ |
| 342 | PREF_NET_TYPE_GSM_ONLY = 1, /* GSM only */ |
| 343 | PREF_NET_TYPE_WCDMA = 2, /* WCDMA */ |
| 344 | PREF_NET_TYPE_GSM_WCDMA_AUTO = 3, /* GSM/WCDMA (auto mode, according to PRL) */ |
| 345 | PREF_NET_TYPE_CDMA_EVDO_AUTO = 4, /* CDMA and EvDo (auto mode, according to PRL) */ |
| 346 | PREF_NET_TYPE_CDMA_ONLY = 5, /* CDMA only */ |
| 347 | PREF_NET_TYPE_EVDO_ONLY = 6, /* EvDo only */ |
| 348 | PREF_NET_TYPE_GSM_WCDMA_CDMA_EVDO_AUTO = 7, /* GSM/WCDMA, CDMA, and EvDo (auto mode, according to PRL) */ |
| 349 | PREF_NET_TYPE_LTE_CDMA_EVDO = 8, /* LTE, CDMA and EvDo */ |
| 350 | PREF_NET_TYPE_LTE_GSM_WCDMA = 9, /* LTE, GSM/WCDMA */ |
| 351 | PREF_NET_TYPE_LTE_CMDA_EVDO_GSM_WCDMA = 10, /* LTE, CDMA, EvDo, GSM/WCDMA */ |
Uma Maheswari Ramalingam | 0e09487 | 2011-09-28 13:25:48 -0700 | [diff] [blame] | 352 | PREF_NET_TYPE_LTE_ONLY = 11, /* LTE only */ |
| 353 | PREF_NET_TYPE_LTE_WCDMA = 12 /* LTE/WCDMA */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 354 | } RIL_PreferredNetworkType; |
| 355 | |
| 356 | /* Source for cdma subscription */ |
| 357 | typedef enum { |
| 358 | CDMA_SUBSCRIPTION_SOURCE_RUIM_SIM = 0, |
| 359 | CDMA_SUBSCRIPTION_SOURCE_NV = 1 |
| 360 | } RIL_CdmaSubscriptionSource; |
| 361 | |
Wink Saville | 74fa388 | 2009-12-22 15:35:41 -0800 | [diff] [blame] | 362 | /* User-to-User signaling Info activation types derived from 3GPP 23.087 v8.0 */ |
| 363 | typedef enum { |
| 364 | RIL_UUS_TYPE1_IMPLICIT = 0, |
| 365 | RIL_UUS_TYPE1_REQUIRED = 1, |
| 366 | RIL_UUS_TYPE1_NOT_REQUIRED = 2, |
| 367 | RIL_UUS_TYPE2_REQUIRED = 3, |
| 368 | RIL_UUS_TYPE2_NOT_REQUIRED = 4, |
| 369 | RIL_UUS_TYPE3_REQUIRED = 5, |
| 370 | RIL_UUS_TYPE3_NOT_REQUIRED = 6 |
| 371 | } RIL_UUS_Type; |
| 372 | |
| 373 | /* User-to-User Signaling Information data coding schemes. Possible values for |
| 374 | * Octet 3 (Protocol Discriminator field) in the UUIE. The values have been |
| 375 | * specified in section 10.5.4.25 of 3GPP TS 24.008 */ |
| 376 | typedef enum { |
| 377 | RIL_UUS_DCS_USP = 0, /* User specified protocol */ |
| 378 | RIL_UUS_DCS_OSIHLP = 1, /* OSI higher layer protocol */ |
| 379 | RIL_UUS_DCS_X244 = 2, /* X.244 */ |
| 380 | RIL_UUS_DCS_RMCF = 3, /* Reserved for system mangement |
| 381 | convergence function */ |
| 382 | RIL_UUS_DCS_IA5c = 4 /* IA5 characters */ |
| 383 | } RIL_UUS_DCS; |
| 384 | |
| 385 | /* User-to-User Signaling Information defined in 3GPP 23.087 v8.0 |
| 386 | * This data is passed in RIL_ExtensionRecord and rec contains this |
| 387 | * structure when type is RIL_UUS_INFO_EXT_REC */ |
| 388 | typedef struct { |
| 389 | RIL_UUS_Type uusType; /* UUS Type */ |
| 390 | RIL_UUS_DCS uusDcs; /* UUS Data Coding Scheme */ |
| 391 | int uusLength; /* Length of UUS Data */ |
| 392 | char * uusData; /* UUS Data */ |
| 393 | } RIL_UUS_Info; |
| 394 | |
| 395 | /* CDMA Signal Information Record as defined in C.S0005 section 3.7.5.5 */ |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 396 | typedef struct { |
| 397 | char isPresent; /* non-zero if signal information record is present */ |
| 398 | char signalType; /* as defined 3.7.5.5-1 */ |
| 399 | char alertPitch; /* as defined 3.7.5.5-2 */ |
| 400 | char signal; /* as defined 3.7.5.5-3, 3.7.5.5-4 or 3.7.5.5-5 */ |
| 401 | } RIL_CDMA_SignalInfoRecord; |
| 402 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 403 | typedef struct { |
| 404 | RIL_CallState state; |
| 405 | int index; /* Connection Index for use with, eg, AT+CHLD */ |
| 406 | int toa; /* type of address, eg 145 = intl */ |
| 407 | char isMpty; /* nonzero if is mpty call */ |
| 408 | char isMT; /* nonzero if call is mobile terminated */ |
| 409 | char als; /* ALS line indicator if available |
| 410 | (0 = line 1) */ |
| 411 | char isVoice; /* nonzero if this is is a voice call */ |
| 412 | char isVoicePrivacy; /* nonzero if CDMA voice privacy mode is active */ |
| 413 | char * number; /* Remote party number */ |
| 414 | int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown 3=Payphone */ |
| 415 | char * name; /* Remote party name */ |
| 416 | int namePresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown 3=Payphone */ |
Wink Saville | 74fa388 | 2009-12-22 15:35:41 -0800 | [diff] [blame] | 417 | RIL_UUS_Info * uusInfo; /* NULL or Pointer to User-User Signaling Information */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 418 | } RIL_Call; |
| 419 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 420 | /* Deprecated, use RIL_Data_Call_Response_v6 */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 421 | typedef struct { |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 422 | int cid; /* Context ID, uniquely identifies this call */ |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 423 | int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */ |
Lorenzo Colitti | 4f81dcf | 2010-09-01 19:38:57 -0700 | [diff] [blame] | 424 | char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1. |
| 425 | For example, "IP", "IPV6", "IPV4V6", or "PPP". */ |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 426 | char * apn; /* ignored */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 427 | char * address; /* An address, e.g., "192.0.1.3" or "2001:db8::1". */ |
| 428 | } RIL_Data_Call_Response_v4; |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 429 | |
| 430 | /* |
| 431 | * Returned by RIL_REQUEST_SETUP_DATA_CALL, RIL_REQUEST_DATA_CALL_LIST |
| 432 | * and RIL_UNSOL_DATA_CALL_LIST_CHANGED, on error status != 0. |
| 433 | */ |
| 434 | typedef struct { |
| 435 | int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */ |
Kazuhiro Ondo | beb25b5 | 2011-06-17 16:26:45 -0500 | [diff] [blame] | 436 | int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry |
| 437 | back-off timer value RIL wants to override the one |
| 438 | pre-configured in FW. |
| 439 | The unit is miliseconds. |
| 440 | The value < 0 means no value is suggested. |
Kazuhiro Ondo | 1615758 | 2011-07-24 07:56:32 -0700 | [diff] [blame] | 441 | The value 0 means retry should be done ASAP. |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 442 | The value of INT_MAX(0x7fffffff) means no retry. */ |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 443 | int cid; /* Context ID, uniquely identifies this call */ |
| 444 | int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */ |
| 445 | char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1. |
| 446 | For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is |
| 447 | PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported |
| 448 | such as "IP" or "IPV6" */ |
| 449 | char * ifname; /* The network interface name */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 450 | char * addresses; /* A space-delimited list of addresses with optional "/" prefix length, |
| 451 | e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64". |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 452 | May not be empty, typically 1 IPv4 or 1 IPv6 or |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 453 | one of each. If the prefix length is absent the addresses |
| 454 | are assumed to be point to point with IPv4 having a prefix |
| 455 | length of 32 and IPv6 128. */ |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 456 | char * dnses; /* A space-delimited list of DNS server addresses, |
| 457 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 458 | May be empty. */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 459 | char * gateways; /* A space-delimited list of default gateway addresses, |
| 460 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 461 | May be empty in which case the addresses represent point |
| 462 | to point connections. */ |
| 463 | } RIL_Data_Call_Response_v6; |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 464 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 465 | typedef struct { |
| 466 | int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */ |
| 467 | int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry |
| 468 | back-off timer value RIL wants to override the one |
| 469 | pre-configured in FW. |
| 470 | The unit is miliseconds. |
| 471 | The value < 0 means no value is suggested. |
| 472 | The value 0 means retry should be done ASAP. |
| 473 | The value of INT_MAX(0x7fffffff) means no retry. */ |
| 474 | int cid; /* Context ID, uniquely identifies this call */ |
| 475 | int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */ |
| 476 | char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1. |
| 477 | For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is |
| 478 | PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported |
| 479 | such as "IP" or "IPV6" */ |
| 480 | char * ifname; /* The network interface name */ |
| 481 | char * addresses; /* A space-delimited list of addresses with optional "/" prefix length, |
| 482 | e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64". |
| 483 | May not be empty, typically 1 IPv4 or 1 IPv6 or |
| 484 | one of each. If the prefix length is absent the addresses |
| 485 | are assumed to be point to point with IPv4 having a prefix |
| 486 | length of 32 and IPv6 128. */ |
| 487 | char * dnses; /* A space-delimited list of DNS server addresses, |
| 488 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 489 | May be empty. */ |
| 490 | char * gateways; /* A space-delimited list of default gateway addresses, |
| 491 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 492 | May be empty in which case the addresses represent point |
| 493 | to point connections. */ |
| 494 | char * pcscf; /* the Proxy Call State Control Function address |
| 495 | via PCO(Protocol Configuration Option) for IMS client. */ |
Sukanya Rajkhowa | b44dda3 | 2014-06-02 14:03:44 -0700 | [diff] [blame] | 496 | } RIL_Data_Call_Response_v9; |
| 497 | |
| 498 | typedef struct { |
| 499 | int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */ |
| 500 | int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry |
| 501 | back-off timer value RIL wants to override the one |
| 502 | pre-configured in FW. |
| 503 | The unit is miliseconds. |
| 504 | The value < 0 means no value is suggested. |
| 505 | The value 0 means retry should be done ASAP. |
| 506 | The value of INT_MAX(0x7fffffff) means no retry. */ |
| 507 | int cid; /* Context ID, uniquely identifies this call */ |
| 508 | int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */ |
| 509 | char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1. |
| 510 | For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is |
| 511 | PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported |
| 512 | such as "IP" or "IPV6" */ |
| 513 | char * ifname; /* The network interface name */ |
| 514 | char * addresses; /* A space-delimited list of addresses with optional "/" prefix length, |
| 515 | e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64". |
| 516 | May not be empty, typically 1 IPv4 or 1 IPv6 or |
| 517 | one of each. If the prefix length is absent the addresses |
| 518 | are assumed to be point to point with IPv4 having a prefix |
| 519 | length of 32 and IPv6 128. */ |
| 520 | char * dnses; /* A space-delimited list of DNS server addresses, |
| 521 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 522 | May be empty. */ |
| 523 | char * gateways; /* A space-delimited list of default gateway addresses, |
| 524 | e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1". |
| 525 | May be empty in which case the addresses represent point |
| 526 | to point connections. */ |
| 527 | char * pcscf; /* the Proxy Call State Control Function address |
| 528 | via PCO(Protocol Configuration Option) for IMS client. */ |
| 529 | int mtu; /* MTU received from network |
| 530 | Value <= 0 means network has either not sent a value or |
| 531 | sent an invalid value */ |
| 532 | } RIL_Data_Call_Response_v11; |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 533 | |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 534 | typedef enum { |
| 535 | RADIO_TECH_3GPP = 1, /* 3GPP Technologies - GSM, WCDMA */ |
| 536 | RADIO_TECH_3GPP2 = 2 /* 3GPP2 Technologies - CDMA */ |
| 537 | } RIL_RadioTechnologyFamily; |
| 538 | |
| 539 | typedef struct { |
| 540 | RIL_RadioTechnologyFamily tech; |
| 541 | unsigned char retry; /* 0 == not retry, nonzero == retry */ |
| 542 | int messageRef; /* Valid field if retry is set to nonzero. |
| 543 | Contains messageRef from RIL_SMS_Response |
| 544 | corresponding to failed MO SMS. |
| 545 | */ |
| 546 | |
| 547 | union { |
| 548 | /* Valid field if tech is RADIO_TECH_3GPP2. See RIL_REQUEST_CDMA_SEND_SMS */ |
| 549 | RIL_CDMA_SMS_Message* cdmaMessage; |
| 550 | |
| 551 | /* Valid field if tech is RADIO_TECH_3GPP. See RIL_REQUEST_SEND_SMS */ |
Sanket Padawe | 05c2307 | 2016-08-08 15:42:17 -0700 | [diff] [blame] | 552 | char** gsmMessage; /* This is an array of pointers where pointers |
| 553 | are contiguous but elements pointed by those pointers |
| 554 | are not contiguous |
| 555 | */ |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 556 | } message; |
| 557 | } RIL_IMS_SMS_Message; |
| 558 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 559 | typedef struct { |
Tammo Spalink | 8e3a2ca | 2009-09-11 11:26:30 +0800 | [diff] [blame] | 560 | int messageRef; /* TP-Message-Reference for GSM, |
| 561 | and BearerData MessageId for CDMA |
| 562 | (See 3GPP2 C.S0015-B, v2.0, table 4.5-1). */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 563 | char *ackPDU; /* or NULL if n/a */ |
Jaikumar Ganesh | 920c78f | 2009-06-04 10:53:15 -0700 | [diff] [blame] | 564 | int errorCode; /* See 3GPP 27.005, 3.2.5 for GSM/UMTS, |
| 565 | 3GPP2 N.S0005 (IS-41C) Table 171 for CDMA, |
| 566 | -1 if unknown or not applicable*/ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 567 | } RIL_SMS_Response; |
| 568 | |
| 569 | /** Used by RIL_REQUEST_WRITE_SMS_TO_SIM */ |
| 570 | typedef struct { |
| 571 | int status; /* Status of message. See TS 27.005 3.1, "<stat>": */ |
| 572 | /* 0 = "REC UNREAD" */ |
| 573 | /* 1 = "REC READ" */ |
| 574 | /* 2 = "STO UNSENT" */ |
| 575 | /* 3 = "STO SENT" */ |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 576 | char * pdu; /* PDU of message to write, as an ASCII hex string less the SMSC address, |
| 577 | the TP-layer length is "strlen(pdu)/2". */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 578 | char * smsc; /* SMSC address in GSM BCD format prefixed by a length byte |
| 579 | (as expected by TS 27.005) or NULL for default SMSC */ |
| 580 | } RIL_SMS_WriteArgs; |
| 581 | |
| 582 | /** Used by RIL_REQUEST_DIAL */ |
| 583 | typedef struct { |
| 584 | char * address; |
| 585 | int clir; |
| 586 | /* (same as 'n' paremeter in TS 27.007 7.7 "+CLIR" |
| 587 | * clir == 0 on "use subscription default value" |
| 588 | * clir == 1 on "CLIR invocation" (restrict CLI presentation) |
| 589 | * clir == 2 on "CLIR suppression" (allow CLI presentation) |
| 590 | */ |
Wink Saville | 74fa388 | 2009-12-22 15:35:41 -0800 | [diff] [blame] | 591 | RIL_UUS_Info * uusInfo; /* NULL or Pointer to User-User Signaling Information */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 592 | } RIL_Dial; |
| 593 | |
| 594 | typedef struct { |
| 595 | int command; /* one of the commands listed for TS 27.007 +CRSM*/ |
| 596 | int fileid; /* EF id */ |
| 597 | char *path; /* "pathid" from TS 27.007 +CRSM command. |
| 598 | Path is in hex asciii format eg "7f205f70" |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 599 | Path must always be provided. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 600 | */ |
| 601 | int p1; |
| 602 | int p2; |
| 603 | int p3; |
| 604 | char *data; /* May be NULL*/ |
| 605 | char *pin2; /* May be NULL*/ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 606 | } RIL_SIM_IO_v5; |
| 607 | |
| 608 | typedef struct { |
| 609 | int command; /* one of the commands listed for TS 27.007 +CRSM*/ |
| 610 | int fileid; /* EF id */ |
| 611 | char *path; /* "pathid" from TS 27.007 +CRSM command. |
| 612 | Path is in hex asciii format eg "7f205f70" |
| 613 | Path must always be provided. |
| 614 | */ |
| 615 | int p1; |
| 616 | int p2; |
| 617 | int p3; |
| 618 | char *data; /* May be NULL*/ |
| 619 | char *pin2; /* May be NULL*/ |
| 620 | char *aidPtr; /* AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. */ |
| 621 | } RIL_SIM_IO_v6; |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 622 | |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 623 | /* Used by RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL and |
| 624 | * RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC. */ |
| 625 | typedef struct { |
| 626 | int sessionid; /* "sessionid" from TS 27.007 +CGLA command. Should be |
| 627 | ignored for +CSIM command. */ |
| 628 | |
| 629 | /* Following fields are used to derive the APDU ("command" and "length" |
| 630 | values in TS 27.007 +CSIM and +CGLA commands). */ |
| 631 | int cla; |
| 632 | int instruction; |
| 633 | int p1; |
| 634 | int p2; |
| 635 | int p3; /* A negative P3 implies a 4 byte APDU. */ |
| 636 | char *data; /* May be NULL. In hex string format. */ |
| 637 | } RIL_SIM_APDU; |
| 638 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 639 | typedef struct { |
| 640 | int sw1; |
| 641 | int sw2; |
Amit Mahajan | 2875bc2 | 2014-08-06 10:03:15 -0700 | [diff] [blame] | 642 | char *simResponse; /* In hex string format ([a-fA-F0-9]*), except for SIM_AUTHENTICATION |
| 643 | response for which it is in Base64 format, see 3GPP TS 31.102 7.1.2 */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 644 | } RIL_SIM_IO_Response; |
| 645 | |
| 646 | /* See also com.android.internal.telephony.gsm.CallForwardInfo */ |
| 647 | |
| 648 | typedef struct { |
| 649 | int status; /* |
| 650 | * For RIL_REQUEST_QUERY_CALL_FORWARD_STATUS |
| 651 | * status 1 = active, 0 = not active |
| 652 | * |
| 653 | * For RIL_REQUEST_SET_CALL_FORWARD: |
| 654 | * status is: |
| 655 | * 0 = disable |
| 656 | * 1 = enable |
| 657 | * 2 = interrogate |
| 658 | * 3 = registeration |
| 659 | * 4 = erasure |
| 660 | */ |
| 661 | |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 662 | int reason; /* from TS 27.007 7.11 "reason" */ |
| 663 | int serviceClass;/* From 27.007 +CCFC/+CLCK "class" |
| 664 | See table for Android mapping from |
| 665 | MMI service code |
| 666 | 0 means user doesn't input class */ |
| 667 | int toa; /* "type" from TS 27.007 7.11 */ |
| 668 | char * number; /* "number" from TS 27.007 7.11. May be NULL */ |
| 669 | int timeSeconds; /* for CF no reply only */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 670 | }RIL_CallForwardInfo; |
| 671 | |
| 672 | typedef struct { |
johnwang | e0ba6a9 | 2009-09-11 19:14:52 -0700 | [diff] [blame] | 673 | char * cid; /* Combination of LAC and Cell Id in 32 bits in GSM. |
| 674 | * Upper 16 bits is LAC and lower 16 bits |
| 675 | * is CID (as described in TS 27.005) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 676 | * Primary Scrambling Code (as described in TS 25.331) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 677 | * in 9 bits in UMTS |
johnwang | e0ba6a9 | 2009-09-11 19:14:52 -0700 | [diff] [blame] | 678 | * Valid values are hexadecimal 0x0000 - 0xffffffff. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 679 | */ |
johnwang | e0ba6a9 | 2009-09-11 19:14:52 -0700 | [diff] [blame] | 680 | int rssi; /* Received RSSI in GSM, |
| 681 | * Level index of CPICH Received Signal Code Power in UMTS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 682 | */ |
| 683 | } RIL_NeighboringCell; |
| 684 | |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 685 | typedef struct { |
| 686 | char lce_status; /* LCE service status: |
| 687 | * -1 = not supported; |
| 688 | * 0 = stopped; |
| 689 | * 1 = active. |
| 690 | */ |
| 691 | unsigned int actual_interval_ms; /* actual LCE reporting interval, |
| 692 | * meaningful only if LCEStatus = 1. |
| 693 | */ |
| 694 | } RIL_LceStatusInfo; |
| 695 | |
| 696 | typedef struct { |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 697 | unsigned int last_hop_capacity_kbps; /* last-hop cellular capacity: kilobits/second. */ |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 698 | unsigned char confidence_level; /* capacity estimate confidence: 0-100 */ |
| 699 | unsigned char lce_suspended; /* LCE report going to be suspended? (e.g., radio |
| 700 | * moves to inactive state or network type change) |
| 701 | * 1 = suspended; |
| 702 | * 0 = not suspended. |
| 703 | */ |
| 704 | } RIL_LceDataInfo; |
| 705 | |
Meng Wang | b4e3431 | 2016-05-12 14:54:36 -0700 | [diff] [blame] | 706 | typedef enum { |
| 707 | RIL_MATCH_ALL = 0, /* Apply to all carriers with the same mcc/mnc */ |
| 708 | RIL_MATCH_SPN = 1, /* Use SPN and mcc/mnc to identify the carrier */ |
| 709 | RIL_MATCH_IMSI_PREFIX = 2, /* Use IMSI prefix and mcc/mnc to identify the carrier */ |
| 710 | RIL_MATCH_GID1 = 3, /* Use GID1 and mcc/mnc to identify the carrier */ |
| 711 | RIL_MATCH_GID2 = 4, /* Use GID2 and mcc/mnc to identify the carrier */ |
| 712 | } RIL_CarrierMatchType; |
| 713 | |
| 714 | typedef struct { |
| 715 | const char * mcc; |
| 716 | const char * mnc; |
| 717 | RIL_CarrierMatchType match_type; /* Specify match type for the carrier. |
| 718 | * If it’s RIL_MATCH_ALL, match_data is null; |
| 719 | * otherwise, match_data is the value for the match type. |
| 720 | */ |
| 721 | const char * match_data; |
| 722 | } RIL_Carrier; |
| 723 | |
| 724 | typedef struct { |
| 725 | int32_t len_allowed_carriers; /* length of array allowed_carriers */ |
| 726 | int32_t len_excluded_carriers; /* length of array excluded_carriers */ |
| 727 | RIL_Carrier * allowed_carriers; /* whitelist for allowed carriers */ |
| 728 | RIL_Carrier * excluded_carriers; /* blacklist for explicitly excluded carriers |
| 729 | * which match allowed_carriers. Eg. allowed_carriers match |
| 730 | * mcc/mnc, excluded_carriers has same mcc/mnc and gid1 |
| 731 | * is ABCD. It means except the carrier whose gid1 is ABCD, |
| 732 | * all carriers with the same mcc/mnc are allowed. |
| 733 | */ |
| 734 | } RIL_CarrierRestrictions; |
| 735 | |
pkanwar | c61837e | 2017-03-17 12:49:34 -0700 | [diff] [blame] | 736 | typedef struct { |
| 737 | const uint8_t * carrierKey; /* Public Key from the Carrier used to encrypt the |
| 738 | * IMSI/IMPI. |
| 739 | */ |
| 740 | const char * KeyIdentifier; /* The keyIdentifier Attribute value pair that helps |
| 741 | * a server locate the private key to decrypt the |
| 742 | * permanent identity. |
| 743 | */ |
| 744 | } RIL_CarrierInfoForImsiEncryption; |
| 745 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 746 | /* See RIL_REQUEST_LAST_CALL_FAIL_CAUSE */ |
| 747 | typedef enum { |
Naveen Kalla | 1b3a6fe | 2010-04-21 16:44:37 -0700 | [diff] [blame] | 748 | CALL_FAIL_UNOBTAINABLE_NUMBER = 1, |
Sooraj Sasindran | d210279 | 2014-09-12 17:00:03 +0800 | [diff] [blame] | 749 | CALL_FAIL_NO_ROUTE_TO_DESTINATION = 3, |
| 750 | CALL_FAIL_CHANNEL_UNACCEPTABLE = 6, |
| 751 | CALL_FAIL_OPERATOR_DETERMINED_BARRING = 8, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 752 | CALL_FAIL_NORMAL = 16, |
| 753 | CALL_FAIL_BUSY = 17, |
Sooraj Sasindran | d210279 | 2014-09-12 17:00:03 +0800 | [diff] [blame] | 754 | CALL_FAIL_NO_USER_RESPONDING = 18, |
| 755 | CALL_FAIL_NO_ANSWER_FROM_USER = 19, |
| 756 | CALL_FAIL_CALL_REJECTED = 21, |
| 757 | CALL_FAIL_NUMBER_CHANGED = 22, |
| 758 | CALL_FAIL_PREEMPTION = 25, |
| 759 | CALL_FAIL_DESTINATION_OUT_OF_ORDER = 27, |
| 760 | CALL_FAIL_INVALID_NUMBER_FORMAT = 28, |
| 761 | CALL_FAIL_FACILITY_REJECTED = 29, |
| 762 | CALL_FAIL_RESP_TO_STATUS_ENQUIRY = 30, |
| 763 | CALL_FAIL_NORMAL_UNSPECIFIED = 31, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 764 | CALL_FAIL_CONGESTION = 34, |
Sooraj Sasindran | d210279 | 2014-09-12 17:00:03 +0800 | [diff] [blame] | 765 | CALL_FAIL_NETWORK_OUT_OF_ORDER = 38, |
| 766 | CALL_FAIL_TEMPORARY_FAILURE = 41, |
| 767 | CALL_FAIL_SWITCHING_EQUIPMENT_CONGESTION = 42, |
| 768 | CALL_FAIL_ACCESS_INFORMATION_DISCARDED = 43, |
| 769 | CALL_FAIL_REQUESTED_CIRCUIT_OR_CHANNEL_NOT_AVAILABLE = 44, |
| 770 | CALL_FAIL_RESOURCES_UNAVAILABLE_OR_UNSPECIFIED = 47, |
| 771 | CALL_FAIL_QOS_UNAVAILABLE = 49, |
| 772 | CALL_FAIL_REQUESTED_FACILITY_NOT_SUBSCRIBED = 50, |
| 773 | CALL_FAIL_INCOMING_CALLS_BARRED_WITHIN_CUG = 55, |
| 774 | CALL_FAIL_BEARER_CAPABILITY_NOT_AUTHORIZED = 57, |
| 775 | CALL_FAIL_BEARER_CAPABILITY_UNAVAILABLE = 58, |
| 776 | CALL_FAIL_SERVICE_OPTION_NOT_AVAILABLE = 63, |
| 777 | CALL_FAIL_BEARER_SERVICE_NOT_IMPLEMENTED = 65, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 778 | CALL_FAIL_ACM_LIMIT_EXCEEDED = 68, |
Sooraj Sasindran | d210279 | 2014-09-12 17:00:03 +0800 | [diff] [blame] | 779 | CALL_FAIL_REQUESTED_FACILITY_NOT_IMPLEMENTED = 69, |
| 780 | CALL_FAIL_ONLY_DIGITAL_INFORMATION_BEARER_AVAILABLE = 70, |
| 781 | CALL_FAIL_SERVICE_OR_OPTION_NOT_IMPLEMENTED = 79, |
| 782 | CALL_FAIL_INVALID_TRANSACTION_IDENTIFIER = 81, |
| 783 | CALL_FAIL_USER_NOT_MEMBER_OF_CUG = 87, |
| 784 | CALL_FAIL_INCOMPATIBLE_DESTINATION = 88, |
| 785 | CALL_FAIL_INVALID_TRANSIT_NW_SELECTION = 91, |
| 786 | CALL_FAIL_SEMANTICALLY_INCORRECT_MESSAGE = 95, |
| 787 | CALL_FAIL_INVALID_MANDATORY_INFORMATION = 96, |
| 788 | CALL_FAIL_MESSAGE_TYPE_NON_IMPLEMENTED = 97, |
| 789 | CALL_FAIL_MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 98, |
| 790 | CALL_FAIL_INFORMATION_ELEMENT_NON_EXISTENT = 99, |
| 791 | CALL_FAIL_CONDITIONAL_IE_ERROR = 100, |
| 792 | CALL_FAIL_MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 101, |
| 793 | CALL_FAIL_RECOVERY_ON_TIMER_EXPIRED = 102, |
| 794 | CALL_FAIL_PROTOCOL_ERROR_UNSPECIFIED = 111, |
| 795 | CALL_FAIL_INTERWORKING_UNSPECIFIED = 127, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 796 | CALL_FAIL_CALL_BARRED = 240, |
| 797 | CALL_FAIL_FDN_BLOCKED = 241, |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 798 | CALL_FAIL_IMSI_UNKNOWN_IN_VLR = 242, |
| 799 | CALL_FAIL_IMEI_NOT_ACCEPTED = 243, |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 800 | CALL_FAIL_DIAL_MODIFIED_TO_USSD = 244, /* STK Call Control */ |
| 801 | CALL_FAIL_DIAL_MODIFIED_TO_SS = 245, |
| 802 | CALL_FAIL_DIAL_MODIFIED_TO_DIAL = 246, |
Jayachandran C | cc2a202 | 2017-03-07 09:55:58 -0800 | [diff] [blame] | 803 | CALL_FAIL_RADIO_OFF = 247, /* Radio is OFF */ |
| 804 | CALL_FAIL_OUT_OF_SERVICE = 248, /* No cellular coverage */ |
| 805 | CALL_FAIL_NO_VALID_SIM = 249, /* No valid SIM is present */ |
| 806 | CALL_FAIL_RADIO_INTERNAL_ERROR = 250, /* Internal error at Modem */ |
| 807 | CALL_FAIL_NETWORK_RESP_TIMEOUT = 251, /* No response from network */ |
| 808 | CALL_FAIL_NETWORK_REJECT = 252, /* Explicit network reject */ |
| 809 | CALL_FAIL_RADIO_ACCESS_FAILURE = 253, /* RRC connection failure. Eg.RACH */ |
| 810 | CALL_FAIL_RADIO_LINK_FAILURE = 254, /* Radio Link Failure */ |
| 811 | CALL_FAIL_RADIO_LINK_LOST = 255, /* Radio link lost due to poor coverage */ |
| 812 | CALL_FAIL_RADIO_UPLINK_FAILURE = 256, /* Radio uplink failure */ |
| 813 | CALL_FAIL_RADIO_SETUP_FAILURE = 257, /* RRC connection setup failure */ |
| 814 | CALL_FAIL_RADIO_RELEASE_NORMAL = 258, /* RRC connection release, normal */ |
| 815 | CALL_FAIL_RADIO_RELEASE_ABNORMAL = 259, /* RRC connection release, abnormal */ |
| 816 | CALL_FAIL_ACCESS_CLASS_BLOCKED = 260, /* Access class barring */ |
| 817 | CALL_FAIL_NETWORK_DETACH = 261, /* Explicit network detach */ |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 818 | CALL_FAIL_CDMA_LOCKED_UNTIL_POWER_CYCLE = 1000, |
| 819 | CALL_FAIL_CDMA_DROP = 1001, |
| 820 | CALL_FAIL_CDMA_INTERCEPT = 1002, |
| 821 | CALL_FAIL_CDMA_REORDER = 1003, |
| 822 | CALL_FAIL_CDMA_SO_REJECT = 1004, |
| 823 | CALL_FAIL_CDMA_RETRY_ORDER = 1005, |
| 824 | CALL_FAIL_CDMA_ACCESS_FAILURE = 1006, |
| 825 | CALL_FAIL_CDMA_PREEMPTED = 1007, |
| 826 | CALL_FAIL_CDMA_NOT_EMERGENCY = 1008, /* For non-emergency number dialed |
| 827 | during emergency callback mode */ |
Naveen Kalla | 03c1edf | 2009-09-23 11:18:35 -0700 | [diff] [blame] | 828 | CALL_FAIL_CDMA_ACCESS_BLOCKED = 1009, /* CDMA network access probes blocked */ |
Jayachandran C | cc2a202 | 2017-03-07 09:55:58 -0800 | [diff] [blame] | 829 | |
| 830 | /* OEM specific error codes. Used to distinguish error from |
| 831 | * CALL_FAIL_ERROR_UNSPECIFIED and help assist debugging */ |
| 832 | CALL_FAIL_OEM_CAUSE_1 = 0xf001, |
| 833 | CALL_FAIL_OEM_CAUSE_2 = 0xf002, |
| 834 | CALL_FAIL_OEM_CAUSE_3 = 0xf003, |
| 835 | CALL_FAIL_OEM_CAUSE_4 = 0xf004, |
| 836 | CALL_FAIL_OEM_CAUSE_5 = 0xf005, |
| 837 | CALL_FAIL_OEM_CAUSE_6 = 0xf006, |
| 838 | CALL_FAIL_OEM_CAUSE_7 = 0xf007, |
| 839 | CALL_FAIL_OEM_CAUSE_8 = 0xf008, |
| 840 | CALL_FAIL_OEM_CAUSE_9 = 0xf009, |
| 841 | CALL_FAIL_OEM_CAUSE_10 = 0xf00a, |
| 842 | CALL_FAIL_OEM_CAUSE_11 = 0xf00b, |
| 843 | CALL_FAIL_OEM_CAUSE_12 = 0xf00c, |
| 844 | CALL_FAIL_OEM_CAUSE_13 = 0xf00d, |
| 845 | CALL_FAIL_OEM_CAUSE_14 = 0xf00e, |
| 846 | CALL_FAIL_OEM_CAUSE_15 = 0xf00f, |
| 847 | |
Sooraj Sasindran | d210279 | 2014-09-12 17:00:03 +0800 | [diff] [blame] | 848 | CALL_FAIL_ERROR_UNSPECIFIED = 0xffff /* This error will be deprecated soon, |
| 849 | vendor code should make sure to map error |
| 850 | code to specific error */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 851 | } RIL_LastCallFailCause; |
| 852 | |
Chao Liu | 548a81e | 2015-05-14 16:13:46 -0700 | [diff] [blame] | 853 | typedef struct { |
| 854 | RIL_LastCallFailCause cause_code; |
| 855 | char * vendor_cause; |
| 856 | } RIL_LastCallFailCauseInfo; |
| 857 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 858 | /* See RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 859 | typedef enum { |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 860 | PDP_FAIL_NONE = 0, /* No error, connection ok */ |
| 861 | |
| 862 | /* an integer cause code defined in TS 24.008 |
| 863 | section 6.1.3.1.3 or TS 24.301 Release 8+ Annex B. |
| 864 | If the implementation does not have access to the exact cause codes, |
| 865 | then it should return one of the following values, |
| 866 | as the UI layer needs to distinguish these |
| 867 | cases for error notification and potential retries. */ |
Jaikumar Ganesh | d6aa2e3 | 2009-05-04 11:09:46 -0700 | [diff] [blame] | 868 | PDP_FAIL_OPERATOR_BARRED = 0x08, /* no retry */ |
Sanket Padawe | ac308b9 | 2016-01-07 14:41:17 -0800 | [diff] [blame] | 869 | PDP_FAIL_NAS_SIGNALLING = 0x0E, |
| 870 | PDP_FAIL_LLC_SNDCP = 0x19, |
Jaikumar Ganesh | d6aa2e3 | 2009-05-04 11:09:46 -0700 | [diff] [blame] | 871 | PDP_FAIL_INSUFFICIENT_RESOURCES = 0x1A, |
| 872 | PDP_FAIL_MISSING_UKNOWN_APN = 0x1B, /* no retry */ |
| 873 | PDP_FAIL_UNKNOWN_PDP_ADDRESS_TYPE = 0x1C, /* no retry */ |
| 874 | PDP_FAIL_USER_AUTHENTICATION = 0x1D, /* no retry */ |
| 875 | PDP_FAIL_ACTIVATION_REJECT_GGSN = 0x1E, /* no retry */ |
| 876 | PDP_FAIL_ACTIVATION_REJECT_UNSPECIFIED = 0x1F, |
| 877 | PDP_FAIL_SERVICE_OPTION_NOT_SUPPORTED = 0x20, /* no retry */ |
| 878 | PDP_FAIL_SERVICE_OPTION_NOT_SUBSCRIBED = 0x21, /* no retry */ |
| 879 | PDP_FAIL_SERVICE_OPTION_OUT_OF_ORDER = 0x22, |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 880 | PDP_FAIL_NSAPI_IN_USE = 0x23, /* no retry */ |
Hui Wang | 11e8b23 | 2014-09-19 16:40:17 -0500 | [diff] [blame] | 881 | PDP_FAIL_REGULAR_DEACTIVATION = 0x24, /* possibly restart radio, |
| 882 | based on framework config */ |
Sanket Padawe | ac308b9 | 2016-01-07 14:41:17 -0800 | [diff] [blame] | 883 | PDP_FAIL_QOS_NOT_ACCEPTED = 0x25, |
| 884 | PDP_FAIL_NETWORK_FAILURE = 0x26, |
| 885 | PDP_FAIL_UMTS_REACTIVATION_REQ = 0x27, |
| 886 | PDP_FAIL_FEATURE_NOT_SUPP = 0x28, |
| 887 | PDP_FAIL_TFT_SEMANTIC_ERROR = 0x29, |
| 888 | PDP_FAIL_TFT_SYTAX_ERROR = 0x2A, |
| 889 | PDP_FAIL_UNKNOWN_PDP_CONTEXT = 0x2B, |
| 890 | PDP_FAIL_FILTER_SEMANTIC_ERROR = 0x2C, |
| 891 | PDP_FAIL_FILTER_SYTAX_ERROR = 0x2D, |
| 892 | PDP_FAIL_PDP_WITHOUT_ACTIVE_TFT = 0x2E, |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 893 | PDP_FAIL_ONLY_IPV4_ALLOWED = 0x32, /* no retry */ |
| 894 | PDP_FAIL_ONLY_IPV6_ALLOWED = 0x33, /* no retry */ |
| 895 | PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED = 0x34, |
Sanket Padawe | ac308b9 | 2016-01-07 14:41:17 -0800 | [diff] [blame] | 896 | PDP_FAIL_ESM_INFO_NOT_RECEIVED = 0x35, |
| 897 | PDP_FAIL_PDN_CONN_DOES_NOT_EXIST = 0x36, |
| 898 | PDP_FAIL_MULTI_CONN_TO_SAME_PDN_NOT_ALLOWED = 0x37, |
| 899 | PDP_FAIL_MAX_ACTIVE_PDP_CONTEXT_REACHED = 0x41, |
| 900 | PDP_FAIL_UNSUPPORTED_APN_IN_CURRENT_PLMN = 0x42, |
| 901 | PDP_FAIL_INVALID_TRANSACTION_ID = 0x51, |
| 902 | PDP_FAIL_MESSAGE_INCORRECT_SEMANTIC = 0x5F, |
| 903 | PDP_FAIL_INVALID_MANDATORY_INFO = 0x60, |
| 904 | PDP_FAIL_MESSAGE_TYPE_UNSUPPORTED = 0x61, |
| 905 | PDP_FAIL_MSG_TYPE_NONCOMPATIBLE_STATE = 0x62, |
| 906 | PDP_FAIL_UNKNOWN_INFO_ELEMENT = 0x63, |
| 907 | PDP_FAIL_CONDITIONAL_IE_ERROR = 0x64, |
| 908 | PDP_FAIL_MSG_AND_PROTOCOL_STATE_UNCOMPATIBLE = 0x65, |
| 909 | PDP_FAIL_PROTOCOL_ERRORS = 0x6F, /* no retry */ |
| 910 | PDP_FAIL_APN_TYPE_CONFLICT = 0x70, |
| 911 | PDP_FAIL_INVALID_PCSCF_ADDR = 0x71, |
| 912 | PDP_FAIL_INTERNAL_CALL_PREEMPT_BY_HIGH_PRIO_APN = 0x72, |
| 913 | PDP_FAIL_EMM_ACCESS_BARRED = 0x73, |
| 914 | PDP_FAIL_EMERGENCY_IFACE_ONLY = 0x74, |
| 915 | PDP_FAIL_IFACE_MISMATCH = 0x75, |
| 916 | PDP_FAIL_COMPANION_IFACE_IN_USE = 0x76, |
| 917 | PDP_FAIL_IP_ADDRESS_MISMATCH = 0x77, |
| 918 | PDP_FAIL_IFACE_AND_POL_FAMILY_MISMATCH = 0x78, |
| 919 | PDP_FAIL_EMM_ACCESS_BARRED_INFINITE_RETRY = 0x79, |
| 920 | PDP_FAIL_AUTH_FAILURE_ON_EMERGENCY_CALL = 0x7A, |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 921 | |
Sanket Padawe | 0106aed | 2016-02-09 09:56:31 -0800 | [diff] [blame] | 922 | // OEM specific error codes. To be used by OEMs when they don't want to |
| 923 | // reveal error code which would be replaced by PDP_FAIL_ERROR_UNSPECIFIED |
| 924 | PDP_FAIL_OEM_DCFAILCAUSE_1 = 0x1001, |
| 925 | PDP_FAIL_OEM_DCFAILCAUSE_2 = 0x1002, |
| 926 | PDP_FAIL_OEM_DCFAILCAUSE_3 = 0x1003, |
| 927 | PDP_FAIL_OEM_DCFAILCAUSE_4 = 0x1004, |
| 928 | PDP_FAIL_OEM_DCFAILCAUSE_5 = 0x1005, |
| 929 | PDP_FAIL_OEM_DCFAILCAUSE_6 = 0x1006, |
| 930 | PDP_FAIL_OEM_DCFAILCAUSE_7 = 0x1007, |
| 931 | PDP_FAIL_OEM_DCFAILCAUSE_8 = 0x1008, |
| 932 | PDP_FAIL_OEM_DCFAILCAUSE_9 = 0x1009, |
| 933 | PDP_FAIL_OEM_DCFAILCAUSE_10 = 0x100A, |
| 934 | PDP_FAIL_OEM_DCFAILCAUSE_11 = 0x100B, |
| 935 | PDP_FAIL_OEM_DCFAILCAUSE_12 = 0x100C, |
| 936 | PDP_FAIL_OEM_DCFAILCAUSE_13 = 0x100D, |
| 937 | PDP_FAIL_OEM_DCFAILCAUSE_14 = 0x100E, |
| 938 | PDP_FAIL_OEM_DCFAILCAUSE_15 = 0x100F, |
| 939 | |
Jaikumar Ganesh | d6aa2e3 | 2009-05-04 11:09:46 -0700 | [diff] [blame] | 940 | /* Not mentioned in the specification */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 941 | PDP_FAIL_VOICE_REGISTRATION_FAIL = -1, |
| 942 | PDP_FAIL_DATA_REGISTRATION_FAIL = -2, |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 943 | |
| 944 | /* reasons for data call drop - network/modem disconnect */ |
Wink Saville | 3492c6e | 2013-10-03 13:53:27 -0700 | [diff] [blame] | 945 | PDP_FAIL_SIGNAL_LOST = -3, |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 946 | PDP_FAIL_PREF_RADIO_TECH_CHANGED = -4,/* preferred technology has changed, should retry |
| 947 | with parameters appropriate for new technology */ |
| 948 | PDP_FAIL_RADIO_POWER_OFF = -5, /* data call was disconnected because radio was resetting, |
| 949 | powered off - no retry */ |
| 950 | PDP_FAIL_TETHERED_CALL_ACTIVE = -6, /* data call was disconnected by modem because tethered |
| 951 | mode was up on same APN/data profile - no retry until |
| 952 | tethered call is off */ |
| 953 | |
Sanket Padawe | ac308b9 | 2016-01-07 14:41:17 -0800 | [diff] [blame] | 954 | PDP_FAIL_ERROR_UNSPECIFIED = 0xffff, /* retry silently. Will be deprecated soon as |
| 955 | new error codes are added making this unnecessary */ |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 956 | } RIL_DataCallFailCause; |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 957 | |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 958 | /* See RIL_REQUEST_SETUP_DATA_CALL */ |
| 959 | typedef enum { |
| 960 | RIL_DATA_PROFILE_DEFAULT = 0, |
| 961 | RIL_DATA_PROFILE_TETHERED = 1, |
Hui Wang | 8d67962 | 2014-10-16 14:59:27 -0500 | [diff] [blame] | 962 | RIL_DATA_PROFILE_IMS = 2, |
| 963 | RIL_DATA_PROFILE_FOTA = 3, |
| 964 | RIL_DATA_PROFILE_CBS = 4, |
| 965 | RIL_DATA_PROFILE_OEM_BASE = 1000, /* Start of OEM-specific profiles */ |
| 966 | RIL_DATA_PROFILE_INVALID = 0xFFFFFFFF |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 967 | } RIL_DataProfile; |
| 968 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 969 | /* Used by RIL_UNSOL_SUPP_SVC_NOTIFICATION */ |
| 970 | typedef struct { |
| 971 | int notificationType; /* |
| 972 | * 0 = MO intermediate result code |
| 973 | * 1 = MT unsolicited result code |
| 974 | */ |
| 975 | int code; /* See 27.007 7.17 |
| 976 | "code1" for MO |
| 977 | "code2" for MT. */ |
| 978 | int index; /* CUG index. See 27.007 7.17. */ |
| 979 | int type; /* "type" from 27.007 7.17 (MT only). */ |
| 980 | char * number; /* "number" from 27.007 7.17 |
| 981 | (MT only, may be NULL). */ |
| 982 | } RIL_SuppSvcNotification; |
| 983 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 984 | #define RIL_CARD_MAX_APPS 8 |
| 985 | |
| 986 | typedef enum { |
Meng Wang | b4e3431 | 2016-05-12 14:54:36 -0700 | [diff] [blame] | 987 | RIL_CARDSTATE_ABSENT = 0, |
| 988 | RIL_CARDSTATE_PRESENT = 1, |
| 989 | RIL_CARDSTATE_ERROR = 2, |
| 990 | RIL_CARDSTATE_RESTRICTED = 3 /* card is present but not usable due to carrier restrictions.*/ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 991 | } RIL_CardState; |
| 992 | |
| 993 | typedef enum { |
| 994 | RIL_PERSOSUBSTATE_UNKNOWN = 0, /* initial state */ |
| 995 | RIL_PERSOSUBSTATE_IN_PROGRESS = 1, /* in between each lock transition */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 996 | RIL_PERSOSUBSTATE_READY = 2, /* when either SIM or RUIM Perso is finished |
| 997 | since each app can only have 1 active perso |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 998 | involved */ |
| 999 | RIL_PERSOSUBSTATE_SIM_NETWORK = 3, |
| 1000 | RIL_PERSOSUBSTATE_SIM_NETWORK_SUBSET = 4, |
| 1001 | RIL_PERSOSUBSTATE_SIM_CORPORATE = 5, |
| 1002 | RIL_PERSOSUBSTATE_SIM_SERVICE_PROVIDER = 6, |
| 1003 | RIL_PERSOSUBSTATE_SIM_SIM = 7, |
| 1004 | RIL_PERSOSUBSTATE_SIM_NETWORK_PUK = 8, /* The corresponding perso lock is blocked */ |
| 1005 | RIL_PERSOSUBSTATE_SIM_NETWORK_SUBSET_PUK = 9, |
| 1006 | RIL_PERSOSUBSTATE_SIM_CORPORATE_PUK = 10, |
| 1007 | RIL_PERSOSUBSTATE_SIM_SERVICE_PROVIDER_PUK = 11, |
| 1008 | RIL_PERSOSUBSTATE_SIM_SIM_PUK = 12, |
| 1009 | RIL_PERSOSUBSTATE_RUIM_NETWORK1 = 13, |
| 1010 | RIL_PERSOSUBSTATE_RUIM_NETWORK2 = 14, |
| 1011 | RIL_PERSOSUBSTATE_RUIM_HRPD = 15, |
| 1012 | RIL_PERSOSUBSTATE_RUIM_CORPORATE = 16, |
| 1013 | RIL_PERSOSUBSTATE_RUIM_SERVICE_PROVIDER = 17, |
| 1014 | RIL_PERSOSUBSTATE_RUIM_RUIM = 18, |
| 1015 | RIL_PERSOSUBSTATE_RUIM_NETWORK1_PUK = 19, /* The corresponding perso lock is blocked */ |
| 1016 | RIL_PERSOSUBSTATE_RUIM_NETWORK2_PUK = 20, |
| 1017 | RIL_PERSOSUBSTATE_RUIM_HRPD_PUK = 21, |
| 1018 | RIL_PERSOSUBSTATE_RUIM_CORPORATE_PUK = 22, |
| 1019 | RIL_PERSOSUBSTATE_RUIM_SERVICE_PROVIDER_PUK = 23, |
| 1020 | RIL_PERSOSUBSTATE_RUIM_RUIM_PUK = 24 |
| 1021 | } RIL_PersoSubstate; |
| 1022 | |
| 1023 | typedef enum { |
| 1024 | RIL_APPSTATE_UNKNOWN = 0, |
| 1025 | RIL_APPSTATE_DETECTED = 1, |
| 1026 | RIL_APPSTATE_PIN = 2, /* If PIN1 or UPin is required */ |
| 1027 | RIL_APPSTATE_PUK = 3, /* If PUK1 or Puk for UPin is required */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1028 | RIL_APPSTATE_SUBSCRIPTION_PERSO = 4, /* perso_substate should be look at |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1029 | when app_state is assigned to this value */ |
| 1030 | RIL_APPSTATE_READY = 5 |
| 1031 | } RIL_AppState; |
| 1032 | |
| 1033 | typedef enum { |
| 1034 | RIL_PINSTATE_UNKNOWN = 0, |
| 1035 | RIL_PINSTATE_ENABLED_NOT_VERIFIED = 1, |
| 1036 | RIL_PINSTATE_ENABLED_VERIFIED = 2, |
| 1037 | RIL_PINSTATE_DISABLED = 3, |
| 1038 | RIL_PINSTATE_ENABLED_BLOCKED = 4, |
| 1039 | RIL_PINSTATE_ENABLED_PERM_BLOCKED = 5 |
| 1040 | } RIL_PinState; |
| 1041 | |
| 1042 | typedef enum { |
| 1043 | RIL_APPTYPE_UNKNOWN = 0, |
| 1044 | RIL_APPTYPE_SIM = 1, |
| 1045 | RIL_APPTYPE_USIM = 2, |
| 1046 | RIL_APPTYPE_RUIM = 3, |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1047 | RIL_APPTYPE_CSIM = 4, |
| 1048 | RIL_APPTYPE_ISIM = 5 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1049 | } RIL_AppType; |
| 1050 | |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 1051 | /* |
| 1052 | * Please note that registration state UNKNOWN is |
| 1053 | * treated as "out of service" in the Android telephony. |
| 1054 | * Registration state REG_DENIED must be returned if Location Update |
| 1055 | * Reject (with cause 17 - Network Failure) is received |
| 1056 | * repeatedly from the network, to facilitate |
| 1057 | * "managed roaming" |
| 1058 | */ |
| 1059 | typedef enum { |
| 1060 | RIL_NOT_REG_AND_NOT_SEARCHING = 0, // Not registered, MT is not currently searching |
| 1061 | // a new operator to register |
| 1062 | RIL_REG_HOME = 1, // Registered, home network |
| 1063 | RIL_NOT_REG_AND_SEARCHING = 2, // Not registered, but MT is currently searching |
| 1064 | // a new operator to register |
| 1065 | RIL_REG_DENIED = 3, // Registration denied |
| 1066 | RIL_UNKNOWN = 4, // Unknown |
| 1067 | RIL_REG_ROAMING = 5, // Registered, roaming |
| 1068 | RIL_NOT_REG_AND_EMERGENCY_AVAILABLE_AND_NOT_SEARCHING = 10, // Same as |
| 1069 | // RIL_NOT_REG_AND_NOT_SEARCHING but indicates that |
| 1070 | // emergency calls are enabled. |
| 1071 | RIL_NOT_REG_AND_EMERGENCY_AVAILABLE_AND_SEARCHING = 12, // Same as RIL_NOT_REG_AND_SEARCHING |
| 1072 | // but indicates that |
| 1073 | // emergency calls are enabled. |
| 1074 | RIL_REG_DENIED_AND_EMERGENCY_AVAILABLE = 13, // Same as REG_DENIED but indicates that |
| 1075 | // emergency calls are enabled. |
| 1076 | RIL_UNKNOWN_AND_EMERGENCY_AVAILABLE = 14, // Same as UNKNOWN but indicates that |
| 1077 | // emergency calls are enabled. |
| 1078 | } RIL_RegState; |
| 1079 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1080 | typedef struct |
| 1081 | { |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1082 | RIL_AppType app_type; |
| 1083 | RIL_AppState app_state; |
| 1084 | RIL_PersoSubstate perso_substate; /* applicable only if app_state == |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1085 | RIL_APPSTATE_SUBSCRIPTION_PERSO */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1086 | char *aid_ptr; /* null terminated string, e.g., from 0xA0, 0x00 -> 0x41, |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1087 | 0x30, 0x30, 0x30 */ |
| 1088 | char *app_label_ptr; /* null terminated string */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1089 | int pin1_replaced; /* applicable to USIM, CSIM & ISIM */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1090 | RIL_PinState pin1; |
| 1091 | RIL_PinState pin2; |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1092 | } RIL_AppStatus; |
| 1093 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1094 | /* Deprecated, use RIL_CardStatus_v6 */ |
| 1095 | typedef struct |
| 1096 | { |
| 1097 | RIL_CardState card_state; |
| 1098 | RIL_PinState universal_pin_state; /* applicable to USIM and CSIM: RIL_PINSTATE_xxx */ |
| 1099 | int gsm_umts_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */ |
| 1100 | int cdma_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */ |
| 1101 | int num_applications; /* value <= RIL_CARD_MAX_APPS */ |
| 1102 | RIL_AppStatus applications[RIL_CARD_MAX_APPS]; |
| 1103 | } RIL_CardStatus_v5; |
| 1104 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1105 | typedef struct |
| 1106 | { |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1107 | RIL_CardState card_state; |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1108 | RIL_PinState universal_pin_state; /* applicable to USIM and CSIM: RIL_PINSTATE_xxx */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1109 | int gsm_umts_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */ |
| 1110 | int cdma_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */ |
| 1111 | int ims_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1112 | int num_applications; /* value <= RIL_CARD_MAX_APPS */ |
| 1113 | RIL_AppStatus applications[RIL_CARD_MAX_APPS]; |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1114 | } RIL_CardStatus_v6; |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1115 | |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 1116 | /** The result of a SIM refresh, returned in data[0] of RIL_UNSOL_SIM_REFRESH |
| 1117 | * or as part of RIL_SimRefreshResponse_v7 |
| 1118 | */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 1119 | typedef enum { |
| 1120 | /* A file on SIM has been updated. data[1] contains the EFID. */ |
| 1121 | SIM_FILE_UPDATE = 0, |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 1122 | /* SIM initialized. All files should be re-read. */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 1123 | SIM_INIT = 1, |
| 1124 | /* SIM reset. SIM power required, SIM may be locked and all files should be re-read. */ |
| 1125 | SIM_RESET = 2 |
| 1126 | } RIL_SimRefreshResult; |
| 1127 | |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 1128 | typedef struct { |
| 1129 | RIL_SimRefreshResult result; |
| 1130 | int ef_id; /* is the EFID of the updated file if the result is */ |
| 1131 | /* SIM_FILE_UPDATE or 0 for any other result. */ |
| 1132 | char * aid; /* is AID(application ID) of the card application */ |
| 1133 | /* See ETSI 102.221 8.1 and 101.220 4 */ |
| 1134 | /* For SIM_FILE_UPDATE result it can be set to AID of */ |
| 1135 | /* application in which updated EF resides or it can be */ |
| 1136 | /* NULL if EF is outside of an application. */ |
| 1137 | /* For SIM_INIT result this field is set to AID of */ |
| 1138 | /* application that caused REFRESH */ |
| 1139 | /* For SIM_RESET result it is NULL. */ |
| 1140 | } RIL_SimRefreshResponse_v7; |
| 1141 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1142 | /* Deprecated, use RIL_CDMA_CallWaiting_v6 */ |
| 1143 | typedef struct { |
| 1144 | char * number; /* Remote party number */ |
| 1145 | int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown */ |
| 1146 | char * name; /* Remote party name */ |
| 1147 | RIL_CDMA_SignalInfoRecord signalInfoRecord; |
| 1148 | } RIL_CDMA_CallWaiting_v5; |
| 1149 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1150 | typedef struct { |
| 1151 | char * number; /* Remote party number */ |
| 1152 | int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown */ |
| 1153 | char * name; /* Remote party name */ |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 1154 | RIL_CDMA_SignalInfoRecord signalInfoRecord; |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1155 | /* Number type/Number plan required to support International Call Waiting */ |
| 1156 | int number_type; /* 0=Unknown, 1=International, 2=National, |
| 1157 | 3=Network specific, 4=subscriber */ |
| 1158 | int number_plan; /* 0=Unknown, 1=ISDN, 3=Data, 4=Telex, 8=Nat'l, 9=Private */ |
| 1159 | } RIL_CDMA_CallWaiting_v6; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1160 | |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 1161 | /** |
| 1162 | * Which types of Cell Broadcast Message (CBM) are to be received by the ME |
| 1163 | * |
| 1164 | * uFromServiceID - uToServiceID defines a range of CBM message identifiers |
| 1165 | * whose value is 0x0000 - 0xFFFF as defined in TS 23.041 9.4.1.2.2 for GMS |
| 1166 | * and 9.4.4.2.2 for UMTS. All other values can be treated as empty |
| 1167 | * CBM message ID. |
| 1168 | * |
| 1169 | * uFromCodeScheme - uToCodeScheme defines a range of CBM data coding schemes |
| 1170 | * whose value is 0x00 - 0xFF as defined in TS 23.041 9.4.1.2.3 for GMS |
| 1171 | * and 9.4.4.2.3 for UMTS. |
| 1172 | * All other values can be treated as empty CBM data coding scheme. |
| 1173 | * |
| 1174 | * selected 0 means message types specified in <fromServiceId, toServiceId> |
| 1175 | * and <fromCodeScheme, toCodeScheme>are not accepted, while 1 means accepted. |
| 1176 | * |
| 1177 | * Used by RIL_REQUEST_GSM_GET_BROADCAST_CONFIG and |
| 1178 | * RIL_REQUEST_GSM_SET_BROADCAST_CONFIG. |
| 1179 | */ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1180 | typedef struct { |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 1181 | int fromServiceId; |
| 1182 | int toServiceId; |
| 1183 | int fromCodeScheme; |
| 1184 | int toCodeScheme; |
| 1185 | unsigned char selected; |
| 1186 | } RIL_GSM_BroadcastSmsConfigInfo; |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 1187 | |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 1188 | /* No restriction at all including voice/SMS/USSD/SS/AV64 and packet data. */ |
| 1189 | #define RIL_RESTRICTED_STATE_NONE 0x00 |
| 1190 | /* Block emergency call due to restriction. But allow all normal voice/SMS/USSD/SS/AV64. */ |
| 1191 | #define RIL_RESTRICTED_STATE_CS_EMERGENCY 0x01 |
| 1192 | /* Block all normal voice/SMS/USSD/SS/AV64 due to restriction. Only Emergency call allowed. */ |
| 1193 | #define RIL_RESTRICTED_STATE_CS_NORMAL 0x02 |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 1194 | /* Block all voice/SMS/USSD/SS/AV64 including emergency call due to restriction.*/ |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 1195 | #define RIL_RESTRICTED_STATE_CS_ALL 0x04 |
| 1196 | /* Block packet data access due to restriction. */ |
| 1197 | #define RIL_RESTRICTED_STATE_PS_ALL 0x10 |
| 1198 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1199 | /* The status for an OTASP/OTAPA session */ |
| 1200 | typedef enum { |
| 1201 | CDMA_OTA_PROVISION_STATUS_SPL_UNLOCKED, |
| 1202 | CDMA_OTA_PROVISION_STATUS_SPC_RETRIES_EXCEEDED, |
| 1203 | CDMA_OTA_PROVISION_STATUS_A_KEY_EXCHANGED, |
| 1204 | CDMA_OTA_PROVISION_STATUS_SSD_UPDATED, |
| 1205 | CDMA_OTA_PROVISION_STATUS_NAM_DOWNLOADED, |
| 1206 | CDMA_OTA_PROVISION_STATUS_MDN_DOWNLOADED, |
| 1207 | CDMA_OTA_PROVISION_STATUS_IMSI_DOWNLOADED, |
| 1208 | CDMA_OTA_PROVISION_STATUS_PRL_DOWNLOADED, |
| 1209 | CDMA_OTA_PROVISION_STATUS_COMMITTED, |
| 1210 | CDMA_OTA_PROVISION_STATUS_OTAPA_STARTED, |
| 1211 | CDMA_OTA_PROVISION_STATUS_OTAPA_STOPPED, |
| 1212 | CDMA_OTA_PROVISION_STATUS_OTAPA_ABORTED |
| 1213 | } RIL_CDMA_OTA_ProvisionStatus; |
| 1214 | |
| 1215 | typedef struct { |
| 1216 | int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */ |
| 1217 | int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */ |
| 1218 | } RIL_GW_SignalStrength; |
| 1219 | |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1220 | typedef struct { |
| 1221 | int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */ |
| 1222 | int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */ |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1223 | int timingAdvance; /* Timing Advance in bit periods. 1 bit period = 48/13 us. |
| 1224 | * INT_MAX denotes invalid value */ |
| 1225 | } RIL_GSM_SignalStrength_v12; |
| 1226 | |
| 1227 | typedef struct { |
| 1228 | int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */ |
| 1229 | int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */ |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1230 | } RIL_SignalStrengthWcdma; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1231 | |
| 1232 | typedef struct { |
| 1233 | int dbm; /* Valid values are positive integers. This value is the actual RSSI value |
| 1234 | * multiplied by -1. Example: If the actual RSSI is -75, then this response |
| 1235 | * value will be 75. |
| 1236 | */ |
| 1237 | int ecio; /* Valid values are positive integers. This value is the actual Ec/Io multiplied |
| 1238 | * by -10. Example: If the actual Ec/Io is -12.5 dB, then this response value |
| 1239 | * will be 125. |
| 1240 | */ |
| 1241 | } RIL_CDMA_SignalStrength; |
| 1242 | |
| 1243 | |
| 1244 | typedef struct { |
| 1245 | int dbm; /* Valid values are positive integers. This value is the actual RSSI value |
| 1246 | * multiplied by -1. Example: If the actual RSSI is -75, then this response |
| 1247 | * value will be 75. |
| 1248 | */ |
| 1249 | int ecio; /* Valid values are positive integers. This value is the actual Ec/Io multiplied |
| 1250 | * by -10. Example: If the actual Ec/Io is -12.5 dB, then this response value |
| 1251 | * will be 125. |
| 1252 | */ |
| 1253 | int signalNoiseRatio; /* Valid values are 0-8. 8 is the highest signal to noise ratio. */ |
| 1254 | } RIL_EVDO_SignalStrength; |
| 1255 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1256 | typedef struct { |
| 1257 | int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */ |
Wink Saville | 473adc9 | 2011-06-13 10:24:09 -0700 | [diff] [blame] | 1258 | int rsrp; /* The current Reference Signal Receive Power in dBm multipled by -1. |
| 1259 | * Range: 44 to 140 dBm |
| 1260 | * INT_MAX: 0x7FFFFFFF denotes invalid value. |
| 1261 | * Reference: 3GPP TS 36.133 9.1.4 */ |
| 1262 | int rsrq; /* The current Reference Signal Receive Quality in dB multiplied by -1. |
| 1263 | * Range: 20 to 3 dB. |
| 1264 | * INT_MAX: 0x7FFFFFFF denotes invalid value. |
| 1265 | * Reference: 3GPP TS 36.133 9.1.7 */ |
| 1266 | int rssnr; /* The current reference signal signal-to-noise ratio in 0.1 dB units. |
| 1267 | * Range: -200 to +300 (-200 = -20.0 dB, +300 = 30dB). |
| 1268 | * INT_MAX : 0x7FFFFFFF denotes invalid value. |
| 1269 | * Reference: 3GPP TS 36.101 8.1.1 */ |
| 1270 | int cqi; /* The current Channel Quality Indicator. |
| 1271 | * Range: 0 to 15. |
| 1272 | * INT_MAX : 0x7FFFFFFF denotes invalid value. |
| 1273 | * Reference: 3GPP TS 36.101 9.2, 9.3, A.4 */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1274 | } RIL_LTE_SignalStrength; |
| 1275 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1276 | typedef struct { |
| 1277 | int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */ |
| 1278 | int rsrp; /* The current Reference Signal Receive Power in dBm multipled by -1. |
| 1279 | * Range: 44 to 140 dBm |
| 1280 | * INT_MAX: 0x7FFFFFFF denotes invalid value. |
| 1281 | * Reference: 3GPP TS 36.133 9.1.4 */ |
| 1282 | int rsrq; /* The current Reference Signal Receive Quality in dB multiplied by -1. |
| 1283 | * Range: 20 to 3 dB. |
| 1284 | * INT_MAX: 0x7FFFFFFF denotes invalid value. |
| 1285 | * Reference: 3GPP TS 36.133 9.1.7 */ |
| 1286 | int rssnr; /* The current reference signal signal-to-noise ratio in 0.1 dB units. |
| 1287 | * Range: -200 to +300 (-200 = -20.0 dB, +300 = 30dB). |
| 1288 | * INT_MAX : 0x7FFFFFFF denotes invalid value. |
| 1289 | * Reference: 3GPP TS 36.101 8.1.1 */ |
| 1290 | int cqi; /* The current Channel Quality Indicator. |
| 1291 | * Range: 0 to 15. |
| 1292 | * INT_MAX : 0x7FFFFFFF denotes invalid value. |
| 1293 | * Reference: 3GPP TS 36.101 9.2, 9.3, A.4 */ |
| 1294 | int timingAdvance; /* timing advance in micro seconds for a one way trip from cell to device. |
| 1295 | * Approximate distance can be calculated using 300m/us * timingAdvance. |
| 1296 | * Range: 0 to 0x7FFFFFFE |
| 1297 | * INT_MAX : 0x7FFFFFFF denotes invalid value. |
| 1298 | * Reference: 3GPP 36.321 section 6.1.3.5 |
| 1299 | * also: http://www.cellular-planningoptimization.com/2010/02/timing-advance-with-calculation.html */ |
| 1300 | } RIL_LTE_SignalStrength_v8; |
| 1301 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1302 | typedef struct { |
| 1303 | int rscp; /* The Received Signal Code Power in dBm multipled by -1. |
| 1304 | * Range : 25 to 120 |
| 1305 | * INT_MAX: 0x7FFFFFFF denotes invalid value. |
| 1306 | * Reference: 3GPP TS 25.123, section 9.1.1.1 */ |
| 1307 | } RIL_TD_SCDMA_SignalStrength; |
| 1308 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1309 | /* Deprecated, use RIL_SignalStrength_v6 */ |
| 1310 | typedef struct { |
| 1311 | RIL_GW_SignalStrength GW_SignalStrength; |
| 1312 | RIL_CDMA_SignalStrength CDMA_SignalStrength; |
| 1313 | RIL_EVDO_SignalStrength EVDO_SignalStrength; |
| 1314 | } RIL_SignalStrength_v5; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1315 | |
| 1316 | typedef struct { |
| 1317 | RIL_GW_SignalStrength GW_SignalStrength; |
| 1318 | RIL_CDMA_SignalStrength CDMA_SignalStrength; |
| 1319 | RIL_EVDO_SignalStrength EVDO_SignalStrength; |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 1320 | RIL_LTE_SignalStrength LTE_SignalStrength; |
| 1321 | } RIL_SignalStrength_v6; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1322 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1323 | typedef struct { |
| 1324 | RIL_GW_SignalStrength GW_SignalStrength; |
| 1325 | RIL_CDMA_SignalStrength CDMA_SignalStrength; |
| 1326 | RIL_EVDO_SignalStrength EVDO_SignalStrength; |
| 1327 | RIL_LTE_SignalStrength_v8 LTE_SignalStrength; |
| 1328 | } RIL_SignalStrength_v8; |
| 1329 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1330 | typedef struct { |
| 1331 | RIL_GW_SignalStrength GW_SignalStrength; |
| 1332 | RIL_CDMA_SignalStrength CDMA_SignalStrength; |
| 1333 | RIL_EVDO_SignalStrength EVDO_SignalStrength; |
| 1334 | RIL_LTE_SignalStrength_v8 LTE_SignalStrength; |
| 1335 | RIL_TD_SCDMA_SignalStrength TD_SCDMA_SignalStrength; |
| 1336 | } RIL_SignalStrength_v10; |
| 1337 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1338 | typedef struct { |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1339 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1340 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1341 | int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */ |
| 1342 | int cid; /* 16-bit GSM Cell Identity described in TS 27.007, 0..65535, INT_MAX if unknown */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1343 | } RIL_CellIdentityGsm; |
| 1344 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1345 | typedef struct { |
| 1346 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1347 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1348 | int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */ |
| 1349 | int cid; /* 16-bit GSM Cell Identity described in TS 27.007, 0..65535, INT_MAX if unknown */ |
| 1350 | int arfcn; /* 16-bit GSM Absolute RF channel number, INT_MAX if unknown */ |
Nathan Harold | f3769da | 2016-05-05 12:19:39 -0700 | [diff] [blame] | 1351 | uint8_t bsic;/* 6-bit Base Station Identity Code, 0xFF if unknown */ |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1352 | } RIL_CellIdentityGsm_v12; |
| 1353 | |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1354 | typedef struct { |
| 1355 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1356 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1357 | int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */ |
| 1358 | int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */ |
| 1359 | int psc; /* 9-bit UMTS Primary Scrambling Code described in TS 25.331, 0..511, INT_MAX if unknown */ |
| 1360 | } RIL_CellIdentityWcdma; |
| 1361 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1362 | typedef struct { |
| 1363 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1364 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1365 | int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */ |
| 1366 | int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */ |
| 1367 | int psc; /* 9-bit UMTS Primary Scrambling Code described in TS 25.331, 0..511, INT_MAX if unknown */ |
| 1368 | int uarfcn; /* 16-bit UMTS Absolute RF Channel Number, INT_MAX if unknown */ |
| 1369 | } RIL_CellIdentityWcdma_v12; |
| 1370 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1371 | typedef struct { |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1372 | int networkId; /* Network Id 0..65535, INT_MAX if unknown */ |
| 1373 | int systemId; /* CDMA System Id 0..32767, INT_MAX if unknown */ |
| 1374 | int basestationId; /* Base Station Id 0..65535, INT_MAX if unknown */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1375 | int longitude; /* Longitude is a decimal number as specified in 3GPP2 C.S0005-A v6.0. |
| 1376 | * It is represented in units of 0.25 seconds and ranges from -2592000 |
| 1377 | * to 2592000, both values inclusive (corresponding to a range of -180 |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1378 | * to +180 degrees). INT_MAX if unknown */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1379 | |
| 1380 | int latitude; /* Latitude is a decimal number as specified in 3GPP2 C.S0005-A v6.0. |
| 1381 | * It is represented in units of 0.25 seconds and ranges from -1296000 |
| 1382 | * to 1296000, both values inclusive (corresponding to a range of -90 |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1383 | * to +90 degrees). INT_MAX if unknown */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1384 | } RIL_CellIdentityCdma; |
| 1385 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1386 | typedef struct { |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1387 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1388 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1389 | int ci; /* 28-bit Cell Identity described in TS ???, INT_MAX if unknown */ |
| 1390 | int pci; /* physical cell id 0..503, INT_MAX if unknown */ |
| 1391 | int tac; /* 16-bit tracking area code, INT_MAX if unknown */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1392 | } RIL_CellIdentityLte; |
| 1393 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1394 | typedef struct { |
| 1395 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1396 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1397 | int ci; /* 28-bit Cell Identity described in TS ???, INT_MAX if unknown */ |
| 1398 | int pci; /* physical cell id 0..503, INT_MAX if unknown */ |
| 1399 | int tac; /* 16-bit tracking area code, INT_MAX if unknown */ |
| 1400 | int earfcn; /* 18-bit LTE Absolute RC Channel Number, INT_MAX if unknown */ |
| 1401 | } RIL_CellIdentityLte_v12; |
| 1402 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1403 | typedef struct { |
| 1404 | int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */ |
| 1405 | int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */ |
| 1406 | int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */ |
| 1407 | int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */ |
| 1408 | int cpid; /* 8-bit Cell Parameters ID described in TS 25.331, 0..127, INT_MAX if unknown */ |
| 1409 | } RIL_CellIdentityTdscdma; |
| 1410 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1411 | typedef struct { |
| 1412 | RIL_CellIdentityGsm cellIdentityGsm; |
| 1413 | RIL_GW_SignalStrength signalStrengthGsm; |
| 1414 | } RIL_CellInfoGsm; |
| 1415 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1416 | typedef struct { |
| 1417 | RIL_CellIdentityGsm_v12 cellIdentityGsm; |
| 1418 | RIL_GSM_SignalStrength_v12 signalStrengthGsm; |
| 1419 | } RIL_CellInfoGsm_v12; |
| 1420 | |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1421 | typedef struct { |
| 1422 | RIL_CellIdentityWcdma cellIdentityWcdma; |
| 1423 | RIL_SignalStrengthWcdma signalStrengthWcdma; |
| 1424 | } RIL_CellInfoWcdma; |
| 1425 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1426 | typedef struct { |
| 1427 | RIL_CellIdentityWcdma_v12 cellIdentityWcdma; |
| 1428 | RIL_SignalStrengthWcdma signalStrengthWcdma; |
| 1429 | } RIL_CellInfoWcdma_v12; |
| 1430 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1431 | typedef struct { |
| 1432 | RIL_CellIdentityCdma cellIdentityCdma; |
| 1433 | RIL_CDMA_SignalStrength signalStrengthCdma; |
| 1434 | RIL_EVDO_SignalStrength signalStrengthEvdo; |
| 1435 | } RIL_CellInfoCdma; |
| 1436 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1437 | typedef struct { |
| 1438 | RIL_CellIdentityLte cellIdentityLte; |
| 1439 | RIL_LTE_SignalStrength_v8 signalStrengthLte; |
| 1440 | } RIL_CellInfoLte; |
| 1441 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1442 | typedef struct { |
| 1443 | RIL_CellIdentityLte_v12 cellIdentityLte; |
| 1444 | RIL_LTE_SignalStrength_v8 signalStrengthLte; |
| 1445 | } RIL_CellInfoLte_v12; |
| 1446 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1447 | typedef struct { |
| 1448 | RIL_CellIdentityTdscdma cellIdentityTdscdma; |
| 1449 | RIL_TD_SCDMA_SignalStrength signalStrengthTdscdma; |
| 1450 | } RIL_CellInfoTdscdma; |
| 1451 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1452 | // Must be the same as CellInfo.TYPE_XXX |
| 1453 | typedef enum { |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 1454 | RIL_CELL_INFO_TYPE_NONE = 0, /* indicates no cell information */ |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1455 | RIL_CELL_INFO_TYPE_GSM = 1, |
| 1456 | RIL_CELL_INFO_TYPE_CDMA = 2, |
| 1457 | RIL_CELL_INFO_TYPE_LTE = 3, |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1458 | RIL_CELL_INFO_TYPE_WCDMA = 4, |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1459 | RIL_CELL_INFO_TYPE_TD_SCDMA = 5 |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1460 | } RIL_CellInfoType; |
| 1461 | |
| 1462 | // Must be the same as CellInfo.TIMESTAMP_TYPE_XXX |
| 1463 | typedef enum { |
| 1464 | RIL_TIMESTAMP_TYPE_UNKNOWN = 0, |
| 1465 | RIL_TIMESTAMP_TYPE_ANTENNA = 1, |
| 1466 | RIL_TIMESTAMP_TYPE_MODEM = 2, |
| 1467 | RIL_TIMESTAMP_TYPE_OEM_RIL = 3, |
| 1468 | RIL_TIMESTAMP_TYPE_JAVA_RIL = 4, |
| 1469 | } RIL_TimeStampType; |
| 1470 | |
| 1471 | typedef struct { |
| 1472 | RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */ |
| 1473 | int registered; /* !0 if this cell is registered 0 if not registered */ |
| 1474 | RIL_TimeStampType timeStampType; /* type of time stamp represented by timeStamp */ |
| 1475 | uint64_t timeStamp; /* Time in nanos as returned by ril_nano_time */ |
| 1476 | union { |
| 1477 | RIL_CellInfoGsm gsm; |
| 1478 | RIL_CellInfoCdma cdma; |
| 1479 | RIL_CellInfoLte lte; |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 1480 | RIL_CellInfoWcdma wcdma; |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1481 | RIL_CellInfoTdscdma tdscdma; |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 1482 | } CellInfo; |
| 1483 | } RIL_CellInfo; |
| 1484 | |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 1485 | typedef struct { |
| 1486 | RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */ |
| 1487 | int registered; /* !0 if this cell is registered 0 if not registered */ |
| 1488 | RIL_TimeStampType timeStampType; /* type of time stamp represented by timeStamp */ |
| 1489 | uint64_t timeStamp; /* Time in nanos as returned by ril_nano_time */ |
| 1490 | union { |
| 1491 | RIL_CellInfoGsm_v12 gsm; |
| 1492 | RIL_CellInfoCdma cdma; |
| 1493 | RIL_CellInfoLte_v12 lte; |
| 1494 | RIL_CellInfoWcdma_v12 wcdma; |
| 1495 | RIL_CellInfoTdscdma tdscdma; |
| 1496 | } CellInfo; |
| 1497 | } RIL_CellInfo_v12; |
| 1498 | |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 1499 | typedef struct { |
| 1500 | RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */ |
| 1501 | union { |
| 1502 | RIL_CellIdentityGsm_v12 cellIdentityGsm; |
| 1503 | RIL_CellIdentityWcdma_v12 cellIdentityWcdma; |
| 1504 | RIL_CellIdentityLte_v12 cellIdentityLte; |
| 1505 | RIL_CellIdentityTdscdma cellIdentityTdscdma; |
| 1506 | RIL_CellIdentityCdma cellIdentityCdma; |
| 1507 | }; |
| 1508 | }RIL_CellIdentity_v16; |
| 1509 | |
| 1510 | typedef struct { |
| 1511 | RIL_RegState regState; // Valid reg states are RIL_NOT_REG_AND_NOT_SEARCHING, |
| 1512 | // REG_HOME, RIL_NOT_REG_AND_SEARCHING, REG_DENIED, |
| 1513 | // UNKNOWN, REG_ROAMING defined in RegState |
| 1514 | RIL_RadioTechnology rat; // indicates the available voice radio technology, |
| 1515 | // valid values as defined by RadioTechnology. |
| 1516 | int32_t cssSupported; // concurrent services support indicator. if |
| 1517 | // registered on a CDMA system. |
| 1518 | // 0 - Concurrent services not supported, |
| 1519 | // 1 - Concurrent services supported |
| 1520 | int32_t roamingIndicator; // TSB-58 Roaming Indicator if registered |
| 1521 | // on a CDMA or EVDO system or -1 if not. |
| 1522 | // Valid values are 0-255. |
| 1523 | int32_t systemIsInPrl; // indicates whether the current system is in the |
| 1524 | // PRL if registered on a CDMA or EVDO system or -1 if |
| 1525 | // not. 0=not in the PRL, 1=in the PRL |
| 1526 | int32_t defaultRoamingIndicator; // default Roaming Indicator from the PRL, |
| 1527 | // if registered on a CDMA or EVDO system or -1 if not. |
| 1528 | // Valid values are 0-255. |
| 1529 | int32_t reasonForDenial; // reasonForDenial if registration state is 3 |
| 1530 | // (Registration denied) this is an enumerated reason why |
| 1531 | // registration was denied. See 3GPP TS 24.008, |
| 1532 | // 10.5.3.6 and Annex G. |
| 1533 | // 0 - General |
| 1534 | // 1 - Authentication Failure |
| 1535 | // 2 - IMSI unknown in HLR |
| 1536 | // 3 - Illegal MS |
| 1537 | // 4 - Illegal ME |
| 1538 | // 5 - PLMN not allowed |
| 1539 | // 6 - Location area not allowed |
| 1540 | // 7 - Roaming not allowed |
| 1541 | // 8 - No Suitable Cells in this Location Area |
| 1542 | // 9 - Network failure |
| 1543 | // 10 - Persistent location update reject |
| 1544 | // 11 - PLMN not allowed |
| 1545 | // 12 - Location area not allowed |
| 1546 | // 13 - Roaming not allowed in this Location Area |
| 1547 | // 15 - No Suitable Cells in this Location Area |
| 1548 | // 17 - Network Failure |
| 1549 | // 20 - MAC Failure |
| 1550 | // 21 - Sync Failure |
| 1551 | // 22 - Congestion |
| 1552 | // 23 - GSM Authentication unacceptable |
| 1553 | // 25 - Not Authorized for this CSG |
| 1554 | // 32 - Service option not supported |
| 1555 | // 33 - Requested service option not subscribed |
| 1556 | // 34 - Service option temporarily out of order |
| 1557 | // 38 - Call cannot be identified |
| 1558 | // 48-63 - Retry upon entry into a new cell |
| 1559 | // 95 - Semantically incorrect message |
| 1560 | // 96 - Invalid mandatory information |
| 1561 | // 97 - Message type non-existent or not implemented |
| 1562 | // 98 - Message type not compatible with protocol state |
| 1563 | // 99 - Information element non-existent or |
| 1564 | // not implemented |
| 1565 | // 100 - Conditional IE error |
| 1566 | // 101 - Message not compatible with protocol state; |
| 1567 | RIL_CellIdentity_v16 cellIdentity; // current cell information |
| 1568 | }RIL_VoiceRegistrationStateResponse; |
| 1569 | |
| 1570 | |
| 1571 | typedef struct { |
| 1572 | RIL_RegState regState; // Valid reg states are RIL_NOT_REG_AND_NOT_SEARCHING, |
| 1573 | // REG_HOME, RIL_NOT_REG_AND_SEARCHING, REG_DENIED, |
| 1574 | // UNKNOWN, REG_ROAMING defined in RegState |
| 1575 | RIL_RadioTechnology rat; // indicates the available data radio technology, |
| 1576 | // valid values as defined by RadioTechnology. |
| 1577 | int32_t reasonDataDenied; // if registration state is 3 (Registration |
| 1578 | // denied) this is an enumerated reason why |
| 1579 | // registration was denied. See 3GPP TS 24.008, |
| 1580 | // Annex G.6 "Additional cause codes for GMM". |
| 1581 | // 7 == GPRS services not allowed |
| 1582 | // 8 == GPRS services and non-GPRS services not allowed |
| 1583 | // 9 == MS identity cannot be derived by the network |
| 1584 | // 10 == Implicitly detached |
| 1585 | // 14 == GPRS services not allowed in this PLMN |
| 1586 | // 16 == MSC temporarily not reachable |
| 1587 | // 40 == No PDP context activated |
| 1588 | int32_t maxDataCalls; // The maximum number of simultaneous Data Calls that |
| 1589 | // must be established using setupDataCall(). |
| 1590 | RIL_CellIdentity_v16 cellIdentity; // Current cell information |
| 1591 | }RIL_DataRegistrationStateResponse; |
| 1592 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1593 | /* Names of the CDMA info records (C.S0005 section 3.7.5) */ |
| 1594 | typedef enum { |
| 1595 | RIL_CDMA_DISPLAY_INFO_REC, |
| 1596 | RIL_CDMA_CALLED_PARTY_NUMBER_INFO_REC, |
| 1597 | RIL_CDMA_CALLING_PARTY_NUMBER_INFO_REC, |
| 1598 | RIL_CDMA_CONNECTED_NUMBER_INFO_REC, |
| 1599 | RIL_CDMA_SIGNAL_INFO_REC, |
| 1600 | RIL_CDMA_REDIRECTING_NUMBER_INFO_REC, |
| 1601 | RIL_CDMA_LINE_CONTROL_INFO_REC, |
| 1602 | RIL_CDMA_EXTENDED_DISPLAY_INFO_REC, |
| 1603 | RIL_CDMA_T53_CLIR_INFO_REC, |
| 1604 | RIL_CDMA_T53_RELEASE_INFO_REC, |
| 1605 | RIL_CDMA_T53_AUDIO_CONTROL_INFO_REC |
| 1606 | } RIL_CDMA_InfoRecName; |
| 1607 | |
| 1608 | /* Display Info Rec as defined in C.S0005 section 3.7.5.1 |
| 1609 | Extended Display Info Rec as defined in C.S0005 section 3.7.5.16 |
| 1610 | Note: the Extended Display info rec contains multiple records of the |
| 1611 | form: display_tag, display_len, and display_len occurrences of the |
| 1612 | chari field if the display_tag is not 10000000 or 10000001. |
| 1613 | To save space, the records are stored consecutively in a byte buffer. |
| 1614 | The display_tag, display_len and chari fields are all 1 byte. |
| 1615 | */ |
| 1616 | |
| 1617 | typedef struct { |
| 1618 | char alpha_len; |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 1619 | char alpha_buf[CDMA_ALPHA_INFO_BUFFER_LENGTH]; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1620 | } RIL_CDMA_DisplayInfoRecord; |
| 1621 | |
| 1622 | /* Called Party Number Info Rec as defined in C.S0005 section 3.7.5.2 |
| 1623 | Calling Party Number Info Rec as defined in C.S0005 section 3.7.5.3 |
| 1624 | Connected Number Info Rec as defined in C.S0005 section 3.7.5.4 |
| 1625 | */ |
| 1626 | |
| 1627 | typedef struct { |
| 1628 | char len; |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 1629 | char buf[CDMA_NUMBER_INFO_BUFFER_LENGTH]; |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 1630 | char number_type; |
| 1631 | char number_plan; |
| 1632 | char pi; |
| 1633 | char si; |
| 1634 | } RIL_CDMA_NumberInfoRecord; |
| 1635 | |
| 1636 | /* Redirecting Number Information Record as defined in C.S0005 section 3.7.5.11 */ |
| 1637 | typedef enum { |
| 1638 | RIL_REDIRECTING_REASON_UNKNOWN = 0, |
| 1639 | RIL_REDIRECTING_REASON_CALL_FORWARDING_BUSY = 1, |
| 1640 | RIL_REDIRECTING_REASON_CALL_FORWARDING_NO_REPLY = 2, |
| 1641 | RIL_REDIRECTING_REASON_CALLED_DTE_OUT_OF_ORDER = 9, |
| 1642 | RIL_REDIRECTING_REASON_CALL_FORWARDING_BY_THE_CALLED_DTE = 10, |
| 1643 | RIL_REDIRECTING_REASON_CALL_FORWARDING_UNCONDITIONAL = 15, |
| 1644 | RIL_REDIRECTING_REASON_RESERVED |
| 1645 | } RIL_CDMA_RedirectingReason; |
| 1646 | |
| 1647 | typedef struct { |
| 1648 | RIL_CDMA_NumberInfoRecord redirectingNumber; |
| 1649 | /* redirectingReason is set to RIL_REDIRECTING_REASON_UNKNOWN if not included */ |
| 1650 | RIL_CDMA_RedirectingReason redirectingReason; |
| 1651 | } RIL_CDMA_RedirectingNumberInfoRecord; |
| 1652 | |
| 1653 | /* Line Control Information Record as defined in C.S0005 section 3.7.5.15 */ |
| 1654 | typedef struct { |
| 1655 | char lineCtrlPolarityIncluded; |
| 1656 | char lineCtrlToggle; |
| 1657 | char lineCtrlReverse; |
| 1658 | char lineCtrlPowerDenial; |
| 1659 | } RIL_CDMA_LineControlInfoRecord; |
| 1660 | |
| 1661 | /* T53 CLIR Information Record */ |
| 1662 | typedef struct { |
| 1663 | char cause; |
| 1664 | } RIL_CDMA_T53_CLIRInfoRecord; |
| 1665 | |
| 1666 | /* T53 Audio Control Information Record */ |
| 1667 | typedef struct { |
| 1668 | char upLink; |
| 1669 | char downLink; |
| 1670 | } RIL_CDMA_T53_AudioControlInfoRecord; |
| 1671 | |
| 1672 | typedef struct { |
| 1673 | |
| 1674 | RIL_CDMA_InfoRecName name; |
| 1675 | |
| 1676 | union { |
| 1677 | /* Display and Extended Display Info Rec */ |
| 1678 | RIL_CDMA_DisplayInfoRecord display; |
| 1679 | |
| 1680 | /* Called Party Number, Calling Party Number, Connected Number Info Rec */ |
| 1681 | RIL_CDMA_NumberInfoRecord number; |
| 1682 | |
| 1683 | /* Signal Info Rec */ |
| 1684 | RIL_CDMA_SignalInfoRecord signal; |
| 1685 | |
| 1686 | /* Redirecting Number Info Rec */ |
| 1687 | RIL_CDMA_RedirectingNumberInfoRecord redir; |
| 1688 | |
| 1689 | /* Line Control Info Rec */ |
| 1690 | RIL_CDMA_LineControlInfoRecord lineCtrl; |
| 1691 | |
| 1692 | /* T53 CLIR Info Rec */ |
| 1693 | RIL_CDMA_T53_CLIRInfoRecord clir; |
| 1694 | |
| 1695 | /* T53 Audio Control Info Rec */ |
| 1696 | RIL_CDMA_T53_AudioControlInfoRecord audioCtrl; |
| 1697 | } rec; |
| 1698 | } RIL_CDMA_InformationRecord; |
| 1699 | |
| 1700 | #define RIL_CDMA_MAX_NUMBER_OF_INFO_RECS 10 |
| 1701 | |
| 1702 | typedef struct { |
| 1703 | char numberOfInfoRecs; |
| 1704 | RIL_CDMA_InformationRecord infoRec[RIL_CDMA_MAX_NUMBER_OF_INFO_RECS]; |
| 1705 | } RIL_CDMA_InformationRecords; |
| 1706 | |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 1707 | /* See RIL_REQUEST_NV_READ_ITEM */ |
| 1708 | typedef struct { |
| 1709 | RIL_NV_Item itemID; |
| 1710 | } RIL_NV_ReadItem; |
| 1711 | |
| 1712 | /* See RIL_REQUEST_NV_WRITE_ITEM */ |
| 1713 | typedef struct { |
| 1714 | RIL_NV_Item itemID; |
| 1715 | char * value; |
| 1716 | } RIL_NV_WriteItem; |
| 1717 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1718 | typedef enum { |
| 1719 | HANDOVER_STARTED = 0, |
| 1720 | HANDOVER_COMPLETED = 1, |
| 1721 | HANDOVER_FAILED = 2, |
| 1722 | HANDOVER_CANCELED = 3 |
| 1723 | } RIL_SrvccState; |
| 1724 | |
| 1725 | /* hardware configuration reported to RILJ. */ |
| 1726 | typedef enum { |
| 1727 | RIL_HARDWARE_CONFIG_MODEM = 0, |
| 1728 | RIL_HARDWARE_CONFIG_SIM = 1, |
| 1729 | } RIL_HardwareConfig_Type; |
| 1730 | |
| 1731 | typedef enum { |
| 1732 | RIL_HARDWARE_CONFIG_STATE_ENABLED = 0, |
| 1733 | RIL_HARDWARE_CONFIG_STATE_STANDBY = 1, |
| 1734 | RIL_HARDWARE_CONFIG_STATE_DISABLED = 2, |
| 1735 | } RIL_HardwareConfig_State; |
| 1736 | |
| 1737 | typedef struct { |
| 1738 | int rilModel; |
| 1739 | uint32_t rat; /* bitset - ref. RIL_RadioTechnology. */ |
| 1740 | int maxVoice; |
| 1741 | int maxData; |
| 1742 | int maxStandby; |
| 1743 | } RIL_HardwareConfig_Modem; |
| 1744 | |
| 1745 | typedef struct { |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 1746 | char modemUuid[MAX_UUID_LENGTH]; |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1747 | } RIL_HardwareConfig_Sim; |
| 1748 | |
| 1749 | typedef struct { |
| 1750 | RIL_HardwareConfig_Type type; |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 1751 | char uuid[MAX_UUID_LENGTH]; |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 1752 | RIL_HardwareConfig_State state; |
| 1753 | union { |
| 1754 | RIL_HardwareConfig_Modem modem; |
| 1755 | RIL_HardwareConfig_Sim sim; |
| 1756 | } cfg; |
| 1757 | } RIL_HardwareConfig; |
| 1758 | |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 1759 | typedef enum { |
| 1760 | SS_CFU, |
| 1761 | SS_CF_BUSY, |
| 1762 | SS_CF_NO_REPLY, |
| 1763 | SS_CF_NOT_REACHABLE, |
| 1764 | SS_CF_ALL, |
| 1765 | SS_CF_ALL_CONDITIONAL, |
| 1766 | SS_CLIP, |
| 1767 | SS_CLIR, |
| 1768 | SS_COLP, |
| 1769 | SS_COLR, |
| 1770 | SS_WAIT, |
| 1771 | SS_BAOC, |
| 1772 | SS_BAOIC, |
| 1773 | SS_BAOIC_EXC_HOME, |
| 1774 | SS_BAIC, |
| 1775 | SS_BAIC_ROAMING, |
| 1776 | SS_ALL_BARRING, |
| 1777 | SS_OUTGOING_BARRING, |
| 1778 | SS_INCOMING_BARRING |
| 1779 | } RIL_SsServiceType; |
| 1780 | |
| 1781 | typedef enum { |
| 1782 | SS_ACTIVATION, |
| 1783 | SS_DEACTIVATION, |
| 1784 | SS_INTERROGATION, |
| 1785 | SS_REGISTRATION, |
| 1786 | SS_ERASURE |
| 1787 | } RIL_SsRequestType; |
| 1788 | |
| 1789 | typedef enum { |
| 1790 | SS_ALL_TELE_AND_BEARER_SERVICES, |
| 1791 | SS_ALL_TELESEVICES, |
| 1792 | SS_TELEPHONY, |
| 1793 | SS_ALL_DATA_TELESERVICES, |
| 1794 | SS_SMS_SERVICES, |
| 1795 | SS_ALL_TELESERVICES_EXCEPT_SMS |
| 1796 | } RIL_SsTeleserviceType; |
| 1797 | |
| 1798 | #define SS_INFO_MAX 4 |
| 1799 | #define NUM_SERVICE_CLASSES 7 |
| 1800 | |
| 1801 | typedef struct { |
| 1802 | int numValidIndexes; /* This gives the number of valid values in cfInfo. |
| 1803 | For example if voice is forwarded to one number and data |
| 1804 | is forwarded to a different one then numValidIndexes will be |
| 1805 | 2 indicating total number of valid values in cfInfo. |
| 1806 | Similarly if all the services are forwarded to the same |
| 1807 | number then the value of numValidIndexes will be 1. */ |
| 1808 | |
| 1809 | RIL_CallForwardInfo cfInfo[NUM_SERVICE_CLASSES]; /* This is the response data |
| 1810 | for SS request to query call |
| 1811 | forward status. see |
| 1812 | RIL_REQUEST_QUERY_CALL_FORWARD_STATUS */ |
| 1813 | } RIL_CfData; |
| 1814 | |
| 1815 | typedef struct { |
| 1816 | RIL_SsServiceType serviceType; |
| 1817 | RIL_SsRequestType requestType; |
| 1818 | RIL_SsTeleserviceType teleserviceType; |
| 1819 | int serviceClass; |
| 1820 | RIL_Errno result; |
| 1821 | |
| 1822 | union { |
| 1823 | int ssInfo[SS_INFO_MAX]; /* This is the response data for most of the SS GET/SET |
| 1824 | RIL requests. E.g. RIL_REQUSET_GET_CLIR returns |
| 1825 | two ints, so first two values of ssInfo[] will be |
| 1826 | used for response if serviceType is SS_CLIR and |
| 1827 | requestType is SS_INTERROGATION */ |
| 1828 | |
| 1829 | RIL_CfData cfData; |
| 1830 | }; |
| 1831 | } RIL_StkCcUnsolSsResponse; |
| 1832 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 1833 | /** |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 1834 | * Data connection power state |
| 1835 | */ |
| 1836 | typedef enum { |
| 1837 | RIL_DC_POWER_STATE_LOW = 1, // Low power state |
| 1838 | RIL_DC_POWER_STATE_MEDIUM = 2, // Medium power state |
| 1839 | RIL_DC_POWER_STATE_HIGH = 3, // High power state |
| 1840 | RIL_DC_POWER_STATE_UNKNOWN = INT32_MAX // Unknown state |
| 1841 | } RIL_DcPowerStates; |
| 1842 | |
| 1843 | /** |
| 1844 | * Data connection real time info |
| 1845 | */ |
| 1846 | typedef struct { |
| 1847 | uint64_t time; // Time in nanos as returned by ril_nano_time |
| 1848 | RIL_DcPowerStates powerState; // Current power state |
| 1849 | } RIL_DcRtInfo; |
| 1850 | |
Amit Mahajan | c796e22 | 2014-08-13 16:54:01 +0000 | [diff] [blame] | 1851 | /** |
| 1852 | * Data profile to modem |
| 1853 | */ |
| 1854 | typedef struct { |
| 1855 | /* id of the data profile */ |
| 1856 | int profileId; |
| 1857 | /* the APN to connect to */ |
| 1858 | char* apn; |
| 1859 | /** one of the PDP_type values in TS 27.007 section 10.1.1. |
| 1860 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
| 1861 | */ |
| 1862 | char* protocol; |
| 1863 | /** authentication protocol used for this PDP context |
| 1864 | * (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) |
| 1865 | */ |
| 1866 | int authType; |
| 1867 | /* the username for APN, or NULL */ |
| 1868 | char* user; |
| 1869 | /* the password for APN, or NULL */ |
| 1870 | char* password; |
| 1871 | /* the profile type, TYPE_COMMON-0, TYPE_3GPP-1, TYPE_3GPP2-2 */ |
| 1872 | int type; |
| 1873 | /* the period in seconds to limit the maximum connections */ |
| 1874 | int maxConnsTime; |
| 1875 | /* the maximum connections during maxConnsTime */ |
| 1876 | int maxConns; |
| 1877 | /** the required wait time in seconds after a successful UE initiated |
| 1878 | * disconnect of a given PDN connection before the device can send |
| 1879 | * a new PDN connection request for that given PDN |
| 1880 | */ |
| 1881 | int waitTime; |
| 1882 | /* true to enable the profile, 0 to disable, 1 to enable */ |
| 1883 | int enabled; |
| 1884 | } RIL_DataProfileInfo; |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 1885 | |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 1886 | typedef struct { |
| 1887 | /* id of the data profile */ |
| 1888 | int profileId; |
| 1889 | /* the APN to connect to */ |
| 1890 | char* apn; |
| 1891 | /** one of the PDP_type values in TS 27.007 section 10.1.1. |
| 1892 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
| 1893 | */ |
| 1894 | char* protocol; |
| 1895 | /** one of the PDP_type values in TS 27.007 section 10.1.1 used on roaming network. |
| 1896 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
| 1897 | */ |
| 1898 | char *roamingProtocol; |
| 1899 | /** authentication protocol used for this PDP context |
| 1900 | * (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) |
| 1901 | */ |
| 1902 | int authType; |
| 1903 | /* the username for APN, or NULL */ |
| 1904 | char* user; |
| 1905 | /* the password for APN, or NULL */ |
| 1906 | char* password; |
| 1907 | /* the profile type, TYPE_COMMON-0, TYPE_3GPP-1, TYPE_3GPP2-2 */ |
| 1908 | int type; |
| 1909 | /* the period in seconds to limit the maximum connections */ |
| 1910 | int maxConnsTime; |
| 1911 | /* the maximum connections during maxConnsTime */ |
| 1912 | int maxConns; |
| 1913 | /** the required wait time in seconds after a successful UE initiated |
| 1914 | * disconnect of a given PDN connection before the device can send |
| 1915 | * a new PDN connection request for that given PDN |
| 1916 | */ |
| 1917 | int waitTime; |
| 1918 | /* true to enable the profile, 0 to disable, 1 to enable */ |
| 1919 | int enabled; |
| 1920 | /* supported APN types bitmask. See RIL_ApnTypes for the value of each bit. */ |
| 1921 | int supportedTypesBitmask; |
| 1922 | /** the bearer bitmask. See RIL_RadioAccessFamily for the value of each bit. */ |
| 1923 | int bearerBitmask; |
| 1924 | /** maximum transmission unit (MTU) size in bytes */ |
| 1925 | int mtu; |
| 1926 | /** the MVNO type: possible values are "imsi", "gid", "spn" */ |
| 1927 | char *mvnoType; |
| 1928 | /** MVNO match data. Can be anything defined by the carrier. For example, |
| 1929 | * SPN like: "A MOBILE", "BEN NL", etc... |
| 1930 | * IMSI like: "302720x94", "2060188", etc... |
| 1931 | * GID like: "4E", "33", etc... |
| 1932 | */ |
| 1933 | char *mvnoMatchData; |
| 1934 | } RIL_DataProfileInfo_v15; |
| 1935 | |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1936 | /* Tx Power Levels */ |
Prerepa Viswanadham | 7315749 | 2015-05-28 00:37:32 -0700 | [diff] [blame] | 1937 | #define RIL_NUM_TX_POWER_LEVELS 5 |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1938 | |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 1939 | /** |
| 1940 | * Aggregate modem activity information |
| 1941 | */ |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1942 | typedef struct { |
| 1943 | |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 1944 | /* total time (in ms) when modem is in a low power or |
| 1945 | * sleep state |
| 1946 | */ |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1947 | uint32_t sleep_mode_time_ms; |
| 1948 | |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 1949 | /* total time (in ms) when modem is awake but neither |
| 1950 | * the transmitter nor receiver are active/awake */ |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1951 | uint32_t idle_mode_time_ms; |
| 1952 | |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 1953 | /* total time (in ms) during which the transmitter is active/awake, |
| 1954 | * subdivided by manufacturer-defined device-specific |
| 1955 | * contiguous increasing ranges of transmit power between |
| 1956 | * 0 and the transmitter's maximum transmit power. |
| 1957 | */ |
Prerepa Viswanadham | 7315749 | 2015-05-28 00:37:32 -0700 | [diff] [blame] | 1958 | uint32_t tx_mode_time_ms[RIL_NUM_TX_POWER_LEVELS]; |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1959 | |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 1960 | /* total time (in ms) for which receiver is active/awake and |
| 1961 | * the transmitter is inactive */ |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 1962 | uint32_t rx_mode_time_ms; |
| 1963 | } RIL_ActivityStatsInfo; |
| 1964 | |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 1965 | typedef enum { |
| 1966 | RIL_APN_TYPE_UNKNOWN = 0x0, // Unknown |
| 1967 | RIL_APN_TYPE_DEFAULT = 0x1, // APN type for default data traffic |
| 1968 | RIL_APN_TYPE_MMS = 0x2, // APN type for MMS traffic |
| 1969 | RIL_APN_TYPE_SUPL = 0x4, // APN type for SUPL assisted GPS |
| 1970 | RIL_APN_TYPE_DUN = 0x8, // APN type for DUN traffic |
| 1971 | RIL_APN_TYPE_HIPRI = 0x10, // APN type for HiPri traffic |
| 1972 | RIL_APN_TYPE_FOTA = 0x20, // APN type for FOTA |
| 1973 | RIL_APN_TYPE_IMS = 0x40, // APN type for IMS |
| 1974 | RIL_APN_TYPE_CBS = 0x80, // APN type for CBS |
| 1975 | RIL_APN_TYPE_IA = 0x100, // APN type for IA Initial Attach APN |
| 1976 | RIL_APN_TYPE_EMERGENCY = 0x200, // APN type for Emergency PDN. This is not an IA apn, |
| 1977 | // but is used for access to carrier services in an |
| 1978 | // emergency call situation. |
| 1979 | RIL_APN_TYPE_ALL = 0xFFFFFFFF // All APN types |
| 1980 | } RIL_ApnTypes; |
| 1981 | |
| 1982 | typedef enum { |
| 1983 | RIL_DST_POWER_SAVE_MODE, // Device power save mode (provided by PowerManager) |
| 1984 | // Non-zero value indicates the device is in power save mode. |
| 1985 | RIL_DST_CHARGING_STATE, // Device charging state (provided by BatteryManager) |
| 1986 | // Non-zero value indicates the device is charging. |
| 1987 | RIL_DST_LOW_DATA_EXPECTED // Low data expected mode. Non-zero value indicates low data |
| 1988 | // traffic is expected, for example, when the device is idle |
| 1989 | // (e.g. not doing tethering in the background). Note |
| 1990 | // this doesn't mean no data is expected. |
| 1991 | } RIL_DeviceStateType; |
| 1992 | |
| 1993 | typedef enum { |
| 1994 | RIL_UR_SIGNAL_STRENGTH = 0x01, // When this bit is set, modem should always send the |
| 1995 | // signal strength update through |
| 1996 | // RIL_UNSOL_SIGNAL_STRENGTH, otherwise suppress it. |
| 1997 | RIL_UR_FULL_NETWORK_STATE = 0x02, // When this bit is set, modem should always send |
| 1998 | // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED |
| 1999 | // when any field in |
| 2000 | // RIL_REQUEST_VOICE_REGISTRATION_STATE or |
| 2001 | // RIL_REQUEST_DATA_REGISTRATION_STATE changes. When |
| 2002 | // this bit is not set, modem should suppress |
| 2003 | // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED |
| 2004 | // only when insignificant fields change |
| 2005 | // (e.g. cell info). |
| 2006 | // Modem should continue sending |
| 2007 | // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED |
| 2008 | // when significant fields are updated even when this |
| 2009 | // bit is not set. The following fields are |
| 2010 | // considered significant, registration state and |
| 2011 | // radio technology. |
| 2012 | RIL_UR_DATA_CALL_DORMANCY_CHANGED = 0x04 // When this bit is set, modem should send the data |
| 2013 | // call list changed unsolicited response |
| 2014 | // RIL_UNSOL_DATA_CALL_LIST_CHANGED whenever any |
| 2015 | // field in RIL_Data_Call_Response changes. |
| 2016 | // Otherwise modem should suppress the unsolicited |
| 2017 | // response when the only changed field is 'active' |
| 2018 | // (for data dormancy). For all other fields change, |
| 2019 | // modem should continue sending |
| 2020 | // RIL_UNSOL_DATA_CALL_LIST_CHANGED regardless this |
| 2021 | // bit is set or not. |
| 2022 | } RIL_UnsolicitedResponseFilter; |
| 2023 | |
Wileen Chiu | 410b756 | 2015-11-23 14:25:22 -0800 | [diff] [blame] | 2024 | typedef struct { |
| 2025 | char * aidPtr; /* AID value, See ETSI 102.221 and 101.220*/ |
| 2026 | int p2; /* P2 parameter (described in ISO 7816-4) |
| 2027 | P2Constants:NO_P2 if to be ignored */ |
| 2028 | } RIL_OpenChannelParams; |
| 2029 | |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 2030 | /** |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2031 | * RIL_REQUEST_GET_SIM_STATUS |
| 2032 | * |
| 2033 | * Requests status of the SIM interface and the SIM card |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2034 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2035 | * "data" is NULL |
| 2036 | * |
Wink Saville | fd72937 | 2011-02-22 16:19:39 -0800 | [diff] [blame] | 2037 | * "response" is const RIL_CardStatus_v6 * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2038 | * |
| 2039 | * Valid errors: |
| 2040 | * Must never fail |
| 2041 | */ |
| 2042 | #define RIL_REQUEST_GET_SIM_STATUS 1 |
| 2043 | |
| 2044 | /** |
| 2045 | * RIL_REQUEST_ENTER_SIM_PIN |
| 2046 | * |
John Wang | 309ac29 | 2009-07-30 14:53:23 -0700 | [diff] [blame] | 2047 | * Supplies SIM PIN. Only called if RIL_CardStatus has RIL_APPSTATE_PIN state |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2048 | * |
| 2049 | * "data" is const char ** |
| 2050 | * ((const char **)data)[0] is PIN value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2051 | * ((const char **)data)[1] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2052 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2053 | * "response" is int * |
| 2054 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2055 | * |
| 2056 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2057 | * |
| 2058 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2059 | * RADIO_NOT_AVAILABLE (radio resetting) |
| 2060 | * GENERIC_FAILURE |
| 2061 | * PASSWORD_INCORRECT |
| 2062 | */ |
| 2063 | |
| 2064 | #define RIL_REQUEST_ENTER_SIM_PIN 2 |
| 2065 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2066 | /** |
| 2067 | * RIL_REQUEST_ENTER_SIM_PUK |
| 2068 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2069 | * Supplies SIM PUK and new PIN. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2070 | * |
| 2071 | * "data" is const char ** |
| 2072 | * ((const char **)data)[0] is PUK value |
| 2073 | * ((const char **)data)[1] is new PIN value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2074 | * ((const char **)data)[2] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2075 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2076 | * "response" is int * |
| 2077 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2078 | * |
| 2079 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2080 | * |
| 2081 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2082 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2083 | * PASSWORD_INCORRECT |
| 2084 | * (PUK is invalid) |
| 2085 | */ |
| 2086 | |
| 2087 | #define RIL_REQUEST_ENTER_SIM_PUK 3 |
| 2088 | |
| 2089 | /** |
| 2090 | * RIL_REQUEST_ENTER_SIM_PIN2 |
| 2091 | * |
| 2092 | * Supplies SIM PIN2. Only called following operation where SIM_PIN2 was |
| 2093 | * returned as a a failure from a previous operation. |
| 2094 | * |
| 2095 | * "data" is const char ** |
| 2096 | * ((const char **)data)[0] is PIN2 value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2097 | * ((const char **)data)[1] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2098 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2099 | * "response" is int * |
| 2100 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2101 | * |
| 2102 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2103 | * |
| 2104 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2105 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2106 | * PASSWORD_INCORRECT |
| 2107 | */ |
| 2108 | |
| 2109 | #define RIL_REQUEST_ENTER_SIM_PIN2 4 |
| 2110 | |
| 2111 | /** |
| 2112 | * RIL_REQUEST_ENTER_SIM_PUK2 |
| 2113 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2114 | * Supplies SIM PUK2 and new PIN2. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2115 | * |
| 2116 | * "data" is const char ** |
| 2117 | * ((const char **)data)[0] is PUK2 value |
| 2118 | * ((const char **)data)[1] is new PIN2 value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2119 | * ((const char **)data)[2] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2120 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2121 | * "response" is int * |
| 2122 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2123 | * |
| 2124 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2125 | * |
| 2126 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2127 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2128 | * PASSWORD_INCORRECT |
| 2129 | * (PUK2 is invalid) |
| 2130 | */ |
| 2131 | |
| 2132 | #define RIL_REQUEST_ENTER_SIM_PUK2 5 |
| 2133 | |
| 2134 | /** |
| 2135 | * RIL_REQUEST_CHANGE_SIM_PIN |
| 2136 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2137 | * Supplies old SIM PIN and new PIN. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2138 | * |
| 2139 | * "data" is const char ** |
| 2140 | * ((const char **)data)[0] is old PIN value |
| 2141 | * ((const char **)data)[1] is new PIN value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2142 | * ((const char **)data)[2] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2143 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2144 | * "response" is int * |
| 2145 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2146 | * |
| 2147 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2148 | * |
| 2149 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2150 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2151 | * PASSWORD_INCORRECT |
| 2152 | * (old PIN is invalid) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2153 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2154 | */ |
| 2155 | |
| 2156 | #define RIL_REQUEST_CHANGE_SIM_PIN 6 |
| 2157 | |
| 2158 | |
| 2159 | /** |
| 2160 | * RIL_REQUEST_CHANGE_SIM_PIN2 |
| 2161 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2162 | * Supplies old SIM PIN2 and new PIN2. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2163 | * |
| 2164 | * "data" is const char ** |
| 2165 | * ((const char **)data)[0] is old PIN2 value |
| 2166 | * ((const char **)data)[1] is new PIN2 value |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2167 | * ((const char **)data)[2] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2168 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2169 | * "response" is int * |
| 2170 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2171 | * |
| 2172 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2173 | * |
| 2174 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2175 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2176 | * PASSWORD_INCORRECT |
| 2177 | * (old PIN2 is invalid) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2178 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2179 | */ |
| 2180 | |
| 2181 | #define RIL_REQUEST_CHANGE_SIM_PIN2 7 |
| 2182 | |
| 2183 | /** |
| 2184 | * RIL_REQUEST_ENTER_NETWORK_DEPERSONALIZATION |
| 2185 | * |
| 2186 | * Requests that network personlization be deactivated |
| 2187 | * |
| 2188 | * "data" is const char ** |
| 2189 | * ((const char **)(data))[0]] is network depersonlization code |
| 2190 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 2191 | * "response" is int * |
| 2192 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2193 | * |
| 2194 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2195 | * |
| 2196 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2197 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2198 | * PASSWORD_INCORRECT |
| 2199 | * (code is invalid) |
| 2200 | */ |
| 2201 | |
| 2202 | #define RIL_REQUEST_ENTER_NETWORK_DEPERSONALIZATION 8 |
| 2203 | |
| 2204 | /** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2205 | * RIL_REQUEST_GET_CURRENT_CALLS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2206 | * |
| 2207 | * Requests current call list |
| 2208 | * |
| 2209 | * "data" is NULL |
| 2210 | * |
| 2211 | * "response" must be a "const RIL_Call **" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2212 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2213 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2214 | * |
| 2215 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2216 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2217 | * NO_MEMORY |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2218 | * (request will be made again in a few hundred msec) |
| 2219 | */ |
| 2220 | |
| 2221 | #define RIL_REQUEST_GET_CURRENT_CALLS 9 |
| 2222 | |
| 2223 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2224 | /** |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2225 | * RIL_REQUEST_DIAL |
| 2226 | * |
| 2227 | * Initiate voice call |
| 2228 | * |
| 2229 | * "data" is const RIL_Dial * |
| 2230 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2231 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2232 | * This method is never used for supplementary service codes |
| 2233 | * |
| 2234 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2235 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2236 | * RADIO_NOT_AVAILABLE (radio resetting) |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2237 | * DIAL_MODIFIED_TO_USSD |
| 2238 | * DIAL_MODIFIED_TO_SS |
| 2239 | * DIAL_MODIFIED_TO_DIAL |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2240 | * INVALID_ARGUMENTS |
| 2241 | * NO_MEMORY |
| 2242 | * INVALID_STATE |
| 2243 | * NO_RESOURCES |
| 2244 | * INTERNAL_ERR |
| 2245 | * FDN_CHECK_FAILURE |
| 2246 | * MODEM_ERR |
| 2247 | * NO_SUBSCRIPTION |
| 2248 | * NO_NETWORK_FOUND |
| 2249 | * INVALID_CALL_ID |
| 2250 | * DEVICE_IN_USE |
| 2251 | * MODE_NOT_SUPPORTED |
| 2252 | * ABORTED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2253 | */ |
| 2254 | #define RIL_REQUEST_DIAL 10 |
| 2255 | |
| 2256 | /** |
| 2257 | * RIL_REQUEST_GET_IMSI |
| 2258 | * |
| 2259 | * Get the SIM IMSI |
| 2260 | * |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 2261 | * Only valid when radio state is "RADIO_STATE_ON" |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2262 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2263 | * "data" is const char ** |
| 2264 | * ((const char **)data)[0] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2265 | * "response" is a const char * containing the IMSI |
| 2266 | * |
| 2267 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2268 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2269 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2270 | */ |
| 2271 | |
| 2272 | #define RIL_REQUEST_GET_IMSI 11 |
| 2273 | |
| 2274 | /** |
| 2275 | * RIL_REQUEST_HANGUP |
| 2276 | * |
| 2277 | * Hang up a specific line (like AT+CHLD=1x) |
| 2278 | * |
John Wang | 06bae4b | 2010-11-18 16:37:09 -0800 | [diff] [blame] | 2279 | * After this HANGUP request returns, RIL should show the connection is NOT |
| 2280 | * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query. |
| 2281 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2282 | * "data" is an int * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2283 | * (int *)data)[0] contains Connection index (value of 'x' in CHLD above) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2284 | * |
| 2285 | * "response" is NULL |
| 2286 | * |
| 2287 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2288 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2289 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2290 | * INVALID_ARGUMENTS |
| 2291 | * NO_MEMORY |
| 2292 | * INVALID_STATE |
| 2293 | * MODEM_ERR |
| 2294 | * INTERNAL_ERR |
| 2295 | * NO_MEMORY |
| 2296 | * INVALID_CALL_ID |
| 2297 | * INVALID_ARGUMENTS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2298 | */ |
| 2299 | |
| 2300 | #define RIL_REQUEST_HANGUP 12 |
| 2301 | |
| 2302 | /** |
| 2303 | * RIL_REQUEST_HANGUP_WAITING_OR_BACKGROUND |
| 2304 | * |
| 2305 | * Hang up waiting or held (like AT+CHLD=0) |
| 2306 | * |
John Wang | 06bae4b | 2010-11-18 16:37:09 -0800 | [diff] [blame] | 2307 | * After this HANGUP request returns, RIL should show the connection is NOT |
| 2308 | * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query. |
| 2309 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2310 | * "data" is NULL |
| 2311 | * "response" is NULL |
| 2312 | * |
| 2313 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2314 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2315 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2316 | * INVALID_STATE |
| 2317 | * NO_MEMORY |
| 2318 | * MODEM_ERR |
| 2319 | * INTERNAL_ERR |
| 2320 | * NO_MEMORY |
| 2321 | * INVALID_CALL_ID |
| 2322 | * NO_RESOURCES |
| 2323 | * OPERATION_NOT_ALLOWED |
| 2324 | * INVALID_ARGUMENTS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2325 | */ |
| 2326 | |
| 2327 | #define RIL_REQUEST_HANGUP_WAITING_OR_BACKGROUND 13 |
| 2328 | |
| 2329 | /** |
| 2330 | * RIL_REQUEST_HANGUP_FOREGROUND_RESUME_BACKGROUND |
| 2331 | * |
| 2332 | * Hang up waiting or held (like AT+CHLD=1) |
| 2333 | * |
John Wang | 06bae4b | 2010-11-18 16:37:09 -0800 | [diff] [blame] | 2334 | * After this HANGUP request returns, RIL should show the connection is NOT |
| 2335 | * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query. |
| 2336 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2337 | * "data" is NULL |
| 2338 | * "response" is NULL |
| 2339 | * |
| 2340 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2341 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2342 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2343 | * INVALID_STATE |
| 2344 | * NO_MEMORY |
| 2345 | * MODEM_ERR |
| 2346 | * INTERNAL_ERR |
| 2347 | * INVALID_CALL_ID |
| 2348 | * OPERATION_NOT_ALLOWED |
| 2349 | * INVALID_ARGUMENTS |
| 2350 | * NO_RESOURCES |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2351 | */ |
| 2352 | |
| 2353 | #define RIL_REQUEST_HANGUP_FOREGROUND_RESUME_BACKGROUND 14 |
| 2354 | |
| 2355 | /** |
| 2356 | * RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE |
| 2357 | * |
| 2358 | * Switch waiting or holding call and active call (like AT+CHLD=2) |
| 2359 | * |
| 2360 | * State transitions should be is follows: |
| 2361 | * |
| 2362 | * If call 1 is waiting and call 2 is active, then if this re |
| 2363 | * |
| 2364 | * BEFORE AFTER |
| 2365 | * Call 1 Call 2 Call 1 Call 2 |
| 2366 | * ACTIVE HOLDING HOLDING ACTIVE |
| 2367 | * ACTIVE WAITING HOLDING ACTIVE |
| 2368 | * HOLDING WAITING HOLDING ACTIVE |
| 2369 | * ACTIVE IDLE HOLDING IDLE |
| 2370 | * IDLE IDLE IDLE IDLE |
| 2371 | * |
| 2372 | * "data" is NULL |
| 2373 | * "response" is NULL |
| 2374 | * |
| 2375 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2376 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2377 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2378 | * INVALID_STATE |
| 2379 | * NO_MEMORY |
| 2380 | * MODEM_ERR |
| 2381 | * INTERNAL_ERR |
| 2382 | * INVALID_STATE |
| 2383 | * INVALID_ARGUMENTS |
| 2384 | * INVALID_CALL_ID |
| 2385 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2386 | */ |
| 2387 | |
| 2388 | #define RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE 15 |
| 2389 | #define RIL_REQUEST_SWITCH_HOLDING_AND_ACTIVE 15 |
| 2390 | |
| 2391 | /** |
| 2392 | * RIL_REQUEST_CONFERENCE |
| 2393 | * |
| 2394 | * Conference holding and active (like AT+CHLD=3) |
| 2395 | |
| 2396 | * "data" is NULL |
| 2397 | * "response" is NULL |
| 2398 | * |
| 2399 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2400 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2401 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2402 | * NO_MEMORY |
| 2403 | * MODEM_ERR |
| 2404 | * INTERNAL_ERR |
| 2405 | * INVALID_STATE |
| 2406 | * INVALID_CALL_ID |
| 2407 | * INVALID_ARGUMENTS |
| 2408 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2409 | */ |
| 2410 | #define RIL_REQUEST_CONFERENCE 16 |
| 2411 | |
| 2412 | /** |
| 2413 | * RIL_REQUEST_UDUB |
| 2414 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2415 | * Send UDUB (user determined used busy) to ringing or |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2416 | * waiting call answer)(RIL_BasicRequest r); |
| 2417 | * |
| 2418 | * "data" is NULL |
| 2419 | * "response" is NULL |
| 2420 | * |
| 2421 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2422 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2423 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2424 | * INVALID_STATE |
| 2425 | * NO_RESOURCES |
| 2426 | * NO_MEMORY |
| 2427 | * MODEM_ERR |
| 2428 | * INTERNAL_ERR |
| 2429 | * INVALID_CALL_ID |
| 2430 | * OPERATION_NOT_ALLOWED |
| 2431 | * INVALID_ARGUMENTS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2432 | */ |
| 2433 | #define RIL_REQUEST_UDUB 17 |
| 2434 | |
| 2435 | /** |
| 2436 | * RIL_REQUEST_LAST_CALL_FAIL_CAUSE |
| 2437 | * |
| 2438 | * Requests the failure cause code for the most recently terminated call |
| 2439 | * |
| 2440 | * "data" is NULL |
Jayachandran C | cc2a202 | 2017-03-07 09:55:58 -0800 | [diff] [blame] | 2441 | * "response" is a const RIL_LastCallFailCauseInfo * |
| 2442 | * RIL_LastCallFailCauseInfo contains LastCallFailCause and vendor cause. |
| 2443 | * The vendor cause code must be used for debugging purpose only. |
| 2444 | * The implementation must return one of the values of LastCallFailCause |
| 2445 | * as mentioned below. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2446 | * |
Jayachandran C | cc2a202 | 2017-03-07 09:55:58 -0800 | [diff] [blame] | 2447 | * GSM failure reasons codes for the cause codes defined in TS 24.008 Annex H |
| 2448 | * where possible. |
| 2449 | * CDMA failure reasons codes for the possible call failure scenarios |
| 2450 | * described in the "CDMA IS-2000 Release A (C.S0005-A v6.0)" standard. |
| 2451 | * Any of the following reason codes if the call is failed or dropped due to reason |
| 2452 | * mentioned with in the braces. |
| 2453 | * |
| 2454 | * CALL_FAIL_RADIO_OFF (Radio is OFF) |
| 2455 | * CALL_FAIL_OUT_OF_SERVICE (No cell coverage) |
| 2456 | * CALL_FAIL_NO_VALID_SIM (No valid SIM) |
| 2457 | * CALL_FAIL_RADIO_INTERNAL_ERROR (Modem hit unexpected error scenario) |
| 2458 | * CALL_FAIL_NETWORK_RESP_TIMEOUT (No response from network) |
| 2459 | * CALL_FAIL_NETWORK_REJECT (Explicit network reject) |
| 2460 | * CALL_FAIL_RADIO_ACCESS_FAILURE (RRC connection failure. Eg.RACH) |
| 2461 | * CALL_FAIL_RADIO_LINK_FAILURE (Radio Link Failure) |
| 2462 | * CALL_FAIL_RADIO_LINK_LOST (Radio link lost due to poor coverage) |
| 2463 | * CALL_FAIL_RADIO_UPLINK_FAILURE (Radio uplink failure) |
| 2464 | * CALL_FAIL_RADIO_SETUP_FAILURE (RRC connection setup failure) |
| 2465 | * CALL_FAIL_RADIO_RELEASE_NORMAL (RRC connection release, normal) |
| 2466 | * CALL_FAIL_RADIO_RELEASE_ABNORMAL (RRC connection release, abnormal) |
| 2467 | * CALL_FAIL_ACCESS_CLASS_BLOCKED (Access class barring) |
| 2468 | * CALL_FAIL_NETWORK_DETACH (Explicit network detach) |
| 2469 | * |
| 2470 | * OEM causes (CALL_FAIL_OEM_CAUSE_XX) must be used for debug purpose only |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 2471 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2472 | * If the implementation does not have access to the exact cause codes, |
| 2473 | * then it should return one of the values listed in RIL_LastCallFailCause, |
| 2474 | * as the UI layer needs to distinguish these cases for tone generation or |
| 2475 | * error notification. |
| 2476 | * |
| 2477 | * Valid errors: |
| 2478 | * SUCCESS |
| 2479 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2480 | * NO_MEMORY |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2481 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2482 | * See also: RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2483 | */ |
| 2484 | #define RIL_REQUEST_LAST_CALL_FAIL_CAUSE 18 |
| 2485 | |
| 2486 | /** |
| 2487 | * RIL_REQUEST_SIGNAL_STRENGTH |
| 2488 | * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 2489 | * Requests current signal strength and associated information |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2490 | * |
| 2491 | * Must succeed if radio is on. |
| 2492 | * |
| 2493 | * "data" is NULL |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 2494 | * |
| 2495 | * "response" is a const RIL_SignalStrength * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2496 | * |
| 2497 | * Valid errors: |
| 2498 | * SUCCESS |
| 2499 | * RADIO_NOT_AVAILABLE |
| 2500 | */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2501 | #define RIL_REQUEST_SIGNAL_STRENGTH 19 |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 2502 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2503 | /** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2504 | * RIL_REQUEST_VOICE_REGISTRATION_STATE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2505 | * |
| 2506 | * Request current registration state |
| 2507 | * |
| 2508 | * "data" is NULL |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 2509 | * "response" is a const RIL_VoiceRegistrationStateResponse * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 2510 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2511 | * Valid errors: |
| 2512 | * SUCCESS |
| 2513 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2514 | */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2515 | #define RIL_REQUEST_VOICE_REGISTRATION_STATE 20 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2516 | |
| 2517 | /** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2518 | * RIL_REQUEST_DATA_REGISTRATION_STATE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2519 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2520 | * Request current DATA registration state |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2521 | * |
| 2522 | * "data" is NULL |
Sooraj Sasindran | d8db60c | 2016-11-30 18:36:03 -0800 | [diff] [blame] | 2523 | * "response" is a const RIL_DataRegistrationStateResponse * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2524 | * |
| 2525 | * Valid errors: |
| 2526 | * SUCCESS |
| 2527 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2528 | */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2529 | #define RIL_REQUEST_DATA_REGISTRATION_STATE 21 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2530 | |
| 2531 | /** |
| 2532 | * RIL_REQUEST_OPERATOR |
| 2533 | * |
| 2534 | * Request current operator ONS or EONS |
| 2535 | * |
| 2536 | * "data" is NULL |
| 2537 | * "response" is a "const char **" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2538 | * ((const char **)response)[0] is long alpha ONS or EONS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2539 | * or NULL if unregistered |
| 2540 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2541 | * ((const char **)response)[1] is short alpha ONS or EONS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2542 | * or NULL if unregistered |
| 2543 | * ((const char **)response)[2] is 5 or 6 digit numeric code (MCC + MNC) |
| 2544 | * or NULL if unregistered |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2545 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2546 | * Valid errors: |
| 2547 | * SUCCESS |
| 2548 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2549 | */ |
| 2550 | #define RIL_REQUEST_OPERATOR 22 |
| 2551 | |
| 2552 | /** |
| 2553 | * RIL_REQUEST_RADIO_POWER |
| 2554 | * |
| 2555 | * Toggle radio on and off (for "airplane" mode) |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 2556 | * If the radio is is turned off/on the radio modem subsystem |
| 2557 | * is expected return to an initialized state. For instance, |
| 2558 | * any voice and data calls will be terminated and all associated |
| 2559 | * lists emptied. |
| 2560 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2561 | * "data" is int * |
| 2562 | * ((int *)data)[0] is > 0 for "Radio On" |
| 2563 | * ((int *)data)[0] is == 0 for "Radio Off" |
| 2564 | * |
| 2565 | * "response" is NULL |
| 2566 | * |
| 2567 | * Turn radio on if "on" > 0 |
| 2568 | * Turn radio off if "on" == 0 |
| 2569 | * |
| 2570 | * Valid errors: |
| 2571 | * SUCCESS |
| 2572 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 2573 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2574 | */ |
| 2575 | #define RIL_REQUEST_RADIO_POWER 23 |
| 2576 | |
| 2577 | /** |
| 2578 | * RIL_REQUEST_DTMF |
| 2579 | * |
| 2580 | * Send a DTMF tone |
| 2581 | * |
| 2582 | * If the implementation is currently playing a tone requested via |
| 2583 | * RIL_REQUEST_DTMF_START, that tone should be cancelled and the new tone |
| 2584 | * should be played instead |
| 2585 | * |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 2586 | * "data" is a char * containing a single character with one of 12 values: 0-9,*,# |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2587 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2588 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2589 | * FIXME should this block/mute microphone? |
| 2590 | * How does this interact with local DTMF feedback? |
| 2591 | * |
| 2592 | * Valid errors: |
| 2593 | * SUCCESS |
| 2594 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2595 | * INVALID_ARGUMENTS |
| 2596 | * NO_RESOURCES |
| 2597 | * NO_MEMORY |
| 2598 | * MODEM_ERR |
| 2599 | * INTERNAL_ERR |
| 2600 | * INVALID_CALL_ID |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2601 | * |
| 2602 | * See also: RIL_REQUEST_DTMF_STOP, RIL_REQUEST_DTMF_START |
| 2603 | * |
| 2604 | */ |
| 2605 | #define RIL_REQUEST_DTMF 24 |
| 2606 | |
| 2607 | /** |
| 2608 | * RIL_REQUEST_SEND_SMS |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2609 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2610 | * Send an SMS message |
| 2611 | * |
| 2612 | * "data" is const char ** |
| 2613 | * ((const char **)data)[0] is SMSC address in GSM BCD format prefixed |
| 2614 | * by a length byte (as expected by TS 27.005) or NULL for default SMSC |
| 2615 | * ((const char **)data)[1] is SMS in PDU format as an ASCII hex string |
| 2616 | * less the SMSC address |
| 2617 | * TP-Layer-Length is be "strlen(((const char **)data)[1])/2" |
| 2618 | * |
| 2619 | * "response" is a const RIL_SMS_Response * |
| 2620 | * |
| 2621 | * Based on the return error, caller decides to resend if sending sms |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2622 | * fails. SMS_SEND_FAIL_RETRY means retry (i.e. error cause is 332) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2623 | * and GENERIC_FAILURE means no retry (i.e. error cause is 500) |
| 2624 | * |
| 2625 | * Valid errors: |
| 2626 | * SUCCESS |
| 2627 | * RADIO_NOT_AVAILABLE |
| 2628 | * SMS_SEND_FAIL_RETRY |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 2629 | * FDN_CHECK_FAILURE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 2630 | * NETWORK_REJECT |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 2631 | * INVALID_STATE |
| 2632 | * INVALID_ARGUMENTS |
| 2633 | * NO_MEMORY |
| 2634 | * REQUEST_RATE_LIMITED |
| 2635 | * INVALID_SMS_FORMAT |
| 2636 | * SYSTEM_ERR |
| 2637 | * ENCODING_ERR |
| 2638 | * INVALID_SMSC_ADDRESS |
| 2639 | * MODEM_ERR |
| 2640 | * NETWORK_ERR |
| 2641 | * MODE_NOT_SUPPORTED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2642 | * |
| 2643 | * FIXME how do we specify TP-Message-Reference if we need to resend? |
| 2644 | */ |
| 2645 | #define RIL_REQUEST_SEND_SMS 25 |
| 2646 | |
| 2647 | |
| 2648 | /** |
| 2649 | * RIL_REQUEST_SEND_SMS_EXPECT_MORE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2650 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2651 | * Send an SMS message. Identical to RIL_REQUEST_SEND_SMS, |
| 2652 | * except that more messages are expected to be sent soon. If possible, |
| 2653 | * keep SMS relay protocol link open (eg TS 27.005 AT+CMMS command) |
| 2654 | * |
| 2655 | * "data" is const char ** |
| 2656 | * ((const char **)data)[0] is SMSC address in GSM BCD format prefixed |
| 2657 | * by a length byte (as expected by TS 27.005) or NULL for default SMSC |
| 2658 | * ((const char **)data)[1] is SMS in PDU format as an ASCII hex string |
| 2659 | * less the SMSC address |
| 2660 | * TP-Layer-Length is be "strlen(((const char **)data)[1])/2" |
| 2661 | * |
| 2662 | * "response" is a const RIL_SMS_Response * |
| 2663 | * |
| 2664 | * Based on the return error, caller decides to resend if sending sms |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2665 | * fails. SMS_SEND_FAIL_RETRY means retry (i.e. error cause is 332) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2666 | * and GENERIC_FAILURE means no retry (i.e. error cause is 500) |
| 2667 | * |
| 2668 | * Valid errors: |
| 2669 | * SUCCESS |
| 2670 | * RADIO_NOT_AVAILABLE |
| 2671 | * SMS_SEND_FAIL_RETRY |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 2672 | * NETWORK_REJECT |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 2673 | * INVALID_STATE |
| 2674 | * INVALID_ARGUMENTS |
| 2675 | * NO_MEMORY |
| 2676 | * INVALID_SMS_FORMAT |
| 2677 | * SYSTEM_ERR |
| 2678 | * REQUEST_RATE_LIMITED |
| 2679 | * FDN_CHECK_FAILURE |
| 2680 | * MODEM_ERR |
| 2681 | * NETWORK_ERR |
| 2682 | * ENCODING_ERR |
| 2683 | * INVALID_SMSC_ADDRESS |
| 2684 | * MODE_NOT_SUPPORTED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2685 | * |
| 2686 | */ |
| 2687 | #define RIL_REQUEST_SEND_SMS_EXPECT_MORE 26 |
| 2688 | |
| 2689 | |
| 2690 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2691 | * RIL_REQUEST_SETUP_DATA_CALL |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2692 | * |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 2693 | * Setup a packet data connection. If RIL_Data_Call_Response_v6.status |
| 2694 | * return success it is added to the list of data calls and a |
| 2695 | * RIL_UNSOL_DATA_CALL_LIST_CHANGED is sent. The call remains in the |
| 2696 | * list until RIL_REQUEST_DEACTIVATE_DATA_CALL is issued or the |
| 2697 | * radio is powered off/on. This list is returned by RIL_REQUEST_DATA_CALL_LIST |
| 2698 | * and RIL_UNSOL_DATA_CALL_LIST_CHANGED. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2699 | * |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 2700 | * The RIL is expected to: |
| 2701 | * - Create one data call context. |
| 2702 | * - Create and configure a dedicated interface for the context |
| 2703 | * - The interface must be point to point. |
| 2704 | * - The interface is configured with one or more addresses and |
| 2705 | * is capable of sending and receiving packets. The prefix length |
| 2706 | * of the addresses must be /32 for IPv4 and /128 for IPv6. |
| 2707 | * - Must NOT change the linux routing table. |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2708 | * - Support up to RIL_REQUEST_DATA_REGISTRATION_STATE response[5] |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 2709 | * number of simultaneous data call contexts. |
| 2710 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2711 | * "data" is a const char ** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2712 | * ((const char **)data)[0] Radio technology to use: 0-CDMA, 1-GSM/UMTS, 2... |
| 2713 | * for values above 2 this is RIL_RadioTechnology + 2. |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 2714 | * ((const char **)data)[1] is a RIL_DataProfile (support is optional) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2715 | * ((const char **)data)[2] is the APN to connect to if radio technology is GSM/UMTS. This APN will |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2716 | * override the one in the profile. NULL indicates no APN overrride. |
| 2717 | * ((const char **)data)[3] is the username for APN, or NULL |
| 2718 | * ((const char **)data)[4] is the password for APN, or NULL |
Jaikumar Ganesh | 920c78f | 2009-06-04 10:53:15 -0700 | [diff] [blame] | 2719 | * ((const char **)data)[5] is the PAP / CHAP auth type. Values: |
| 2720 | * 0 => PAP and CHAP is never performed. |
| 2721 | * 1 => PAP may be performed; CHAP is never performed. |
| 2722 | * 2 => CHAP may be performed; PAP is never performed. |
| 2723 | * 3 => PAP / CHAP may be performed - baseband dependent. |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 2724 | * ((const char **)data)[6] is the non-roaming/home connection type to request. Must be one of the |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2725 | * PDP_type values in TS 27.007 section 10.1.1. |
Lorenzo Colitti | 4f81dcf | 2010-09-01 19:38:57 -0700 | [diff] [blame] | 2726 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 2727 | * ((const char **)data)[7] is the roaming connection type to request. Must be one of the |
| 2728 | * PDP_type values in TS 27.007 section 10.1.1. |
| 2729 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
| 2730 | * ((const char **)data)[8] is the bitmask of APN type in decimal string format. The |
| 2731 | * bitmask will encapsulate the following values: |
| 2732 | * ia,mms,agps,supl,hipri,fota,dun,ims,default. |
| 2733 | * ((const char **)data)[9] is the bearer bitmask in decimal string format. Each bit is a |
| 2734 | * RIL_RadioAccessFamily. "0" or NULL indicates all RATs. |
| 2735 | * ((const char **)data)[10] is the boolean in string format indicating the APN setting was |
| 2736 | * sent to the modem through RIL_REQUEST_SET_DATA_PROFILE earlier. |
| 2737 | * ((const char **)data)[11] is the mtu size in bytes of the mobile interface to which |
| 2738 | * the apn is connected. |
| 2739 | * ((const char **)data)[12] is the MVNO type: |
| 2740 | * possible values are "imsi", "gid", "spn". |
| 2741 | * ((const char **)data)[13] is MVNO match data in string. Can be anything defined by the carrier. |
| 2742 | * For example, |
| 2743 | * SPN like: "A MOBILE", "BEN NL", etc... |
| 2744 | * IMSI like: "302720x94", "2060188", etc... |
| 2745 | * GID like: "4E", "33", etc... |
| 2746 | * ((const char **)data)[14] is the boolean string indicating data roaming is allowed or not. "1" |
| 2747 | * indicates data roaming is enabled by the user, "0" indicates disabled. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2748 | * |
Sukanya Rajkhowa | b44dda3 | 2014-06-02 14:03:44 -0700 | [diff] [blame] | 2749 | * "response" is a RIL_Data_Call_Response_v11 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2750 | * |
| 2751 | * FIXME may need way to configure QoS settings |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 2752 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2753 | * Valid errors: |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 2754 | * SUCCESS should be returned on both success and failure of setup with |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 2755 | * the RIL_Data_Call_Response_v6.status containing the actual status. |
| 2756 | * For all other errors the RIL_Data_Call_Resonse_v6 is ignored. |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 2757 | * |
| 2758 | * Other errors could include: |
| 2759 | * RADIO_NOT_AVAILABLE, GENERIC_FAILURE, OP_NOT_ALLOWED_BEFORE_REG_TO_NW, |
| 2760 | * OP_NOT_ALLOWED_DURING_VOICE_CALL and REQUEST_NOT_SUPPORTED. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2761 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2762 | * See also: RIL_REQUEST_DEACTIVATE_DATA_CALL |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2763 | */ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 2764 | #define RIL_REQUEST_SETUP_DATA_CALL 27 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2765 | |
| 2766 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2767 | /** |
| 2768 | * RIL_REQUEST_SIM_IO |
| 2769 | * |
| 2770 | * Request SIM I/O operation. |
| 2771 | * This is similar to the TS 27.007 "restricted SIM" operation |
| 2772 | * where it assumes all of the EF selection will be done by the |
| 2773 | * callee. |
| 2774 | * |
Wink Saville | fd72937 | 2011-02-22 16:19:39 -0800 | [diff] [blame] | 2775 | * "data" is a const RIL_SIM_IO_v6 * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2776 | * Please note that RIL_SIM_IO has a "PIN2" field which may be NULL, |
| 2777 | * or may specify a PIN2 for operations that require a PIN2 (eg |
| 2778 | * updating FDN records) |
| 2779 | * |
| 2780 | * "response" is a const RIL_SIM_IO_Response * |
| 2781 | * |
| 2782 | * Arguments and responses that are unused for certain |
| 2783 | * values of "command" should be ignored or set to NULL |
| 2784 | * |
| 2785 | * Valid errors: |
| 2786 | * SUCCESS |
| 2787 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2788 | * SIM_PIN2 |
| 2789 | * SIM_PUK2 |
| 2790 | */ |
| 2791 | #define RIL_REQUEST_SIM_IO 28 |
| 2792 | |
| 2793 | /** |
| 2794 | * RIL_REQUEST_SEND_USSD |
| 2795 | * |
| 2796 | * Send a USSD message |
| 2797 | * |
| 2798 | * If a USSD session already exists, the message should be sent in the |
| 2799 | * context of that session. Otherwise, a new session should be created. |
| 2800 | * |
| 2801 | * The network reply should be reported via RIL_UNSOL_ON_USSD |
| 2802 | * |
| 2803 | * Only one USSD session may exist at a time, and the session is assumed |
| 2804 | * to exist until: |
| 2805 | * a) The android system invokes RIL_REQUEST_CANCEL_USSD |
| 2806 | * b) The implementation sends a RIL_UNSOL_ON_USSD with a type code |
| 2807 | * of "0" (USSD-Notify/no further action) or "2" (session terminated) |
| 2808 | * |
| 2809 | * "data" is a const char * containing the USSD request in UTF-8 format |
| 2810 | * "response" is NULL |
| 2811 | * |
| 2812 | * Valid errors: |
| 2813 | * SUCCESS |
| 2814 | * RADIO_NOT_AVAILABLE |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 2815 | * FDN_CHECK_FAILURE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2816 | * USSD_MODIFIED_TO_DIAL |
| 2817 | * USSD_MODIFIED_TO_SS |
| 2818 | * USSD_MODIFIED_TO_USSD |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 2819 | * SIM_BUSY |
| 2820 | * OPERATION_NOT_ALLOWED |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2821 | * INVALID_ARGUMENTS |
| 2822 | * NO_MEMORY |
| 2823 | * MODEM_ERR |
| 2824 | * INTERNAL_ERR |
| 2825 | * ABORTED |
| 2826 | * SYSTEM_ERR |
| 2827 | * INVALID_STATE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2828 | * |
| 2829 | * See also: RIL_REQUEST_CANCEL_USSD, RIL_UNSOL_ON_USSD |
| 2830 | */ |
| 2831 | |
| 2832 | #define RIL_REQUEST_SEND_USSD 29 |
| 2833 | |
| 2834 | /** |
| 2835 | * RIL_REQUEST_CANCEL_USSD |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2836 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2837 | * Cancel the current USSD session if one exists |
| 2838 | * |
| 2839 | * "data" is null |
| 2840 | * "response" is NULL |
| 2841 | * |
| 2842 | * Valid errors: |
| 2843 | * SUCCESS |
| 2844 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 2845 | * SIM_BUSY |
| 2846 | * OPERATION_NOT_ALLOWED |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2847 | * MODEM_ERR |
| 2848 | * INTERNAL_ERR |
| 2849 | * NO_MEMORY |
| 2850 | * INVALID_STATE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2851 | */ |
| 2852 | |
| 2853 | #define RIL_REQUEST_CANCEL_USSD 30 |
| 2854 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2855 | /** |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2856 | * RIL_REQUEST_GET_CLIR |
| 2857 | * |
| 2858 | * Gets current CLIR status |
| 2859 | * "data" is NULL |
| 2860 | * "response" is int * |
| 2861 | * ((int *)data)[0] is "n" parameter from TS 27.007 7.7 |
| 2862 | * ((int *)data)[1] is "m" parameter from TS 27.007 7.7 |
| 2863 | * |
| 2864 | * Valid errors: |
| 2865 | * SUCCESS |
| 2866 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2867 | * SS_MODIFIED_TO_DIAL |
| 2868 | * SS_MODIFIED_TO_USSD |
| 2869 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2870 | * NO_MEMORY |
| 2871 | * MODEM_ERR |
| 2872 | * INTERNAL_ERR |
| 2873 | * FDN_CHECK_FAILURE |
| 2874 | * SYSTEM_ERR |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2875 | */ |
| 2876 | #define RIL_REQUEST_GET_CLIR 31 |
| 2877 | |
| 2878 | /** |
| 2879 | * RIL_REQUEST_SET_CLIR |
| 2880 | * |
| 2881 | * "data" is int * |
| 2882 | * ((int *)data)[0] is "n" parameter from TS 27.007 7.7 |
| 2883 | * |
| 2884 | * "response" is NULL |
| 2885 | * |
| 2886 | * Valid errors: |
| 2887 | * SUCCESS |
| 2888 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2889 | * SS_MODIFIED_TO_DIAL |
| 2890 | * SS_MODIFIED_TO_USSD |
| 2891 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2892 | * INVALID_ARGUMENTS |
| 2893 | * SYSTEM_ERR |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2894 | */ |
| 2895 | #define RIL_REQUEST_SET_CLIR 32 |
| 2896 | |
| 2897 | /** |
| 2898 | * RIL_REQUEST_QUERY_CALL_FORWARD_STATUS |
| 2899 | * |
| 2900 | * "data" is const RIL_CallForwardInfo * |
| 2901 | * |
| 2902 | * "response" is const RIL_CallForwardInfo ** |
| 2903 | * "response" points to an array of RIL_CallForwardInfo *'s, one for |
| 2904 | * each distinct registered phone number. |
| 2905 | * |
| 2906 | * For example, if data is forwarded to +18005551212 and voice is forwarded |
| 2907 | * to +18005559999, then two separate RIL_CallForwardInfo's should be returned |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2908 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2909 | * If, however, both data and voice are forwarded to +18005551212, then |
| 2910 | * a single RIL_CallForwardInfo can be returned with the service class |
| 2911 | * set to "data + voice = 3") |
| 2912 | * |
| 2913 | * Valid errors: |
| 2914 | * SUCCESS |
| 2915 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2916 | * SS_MODIFIED_TO_DIAL |
| 2917 | * SS_MODIFIED_TO_USSD |
| 2918 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2919 | * INVALID_ARGUMENTS |
| 2920 | * NO_MEMORY |
| 2921 | * SYSTEM_ERR |
| 2922 | * MODEM_ERR |
| 2923 | * INTERNAL_ERR |
| 2924 | * NO_MEMORY |
| 2925 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2926 | */ |
| 2927 | #define RIL_REQUEST_QUERY_CALL_FORWARD_STATUS 33 |
| 2928 | |
| 2929 | |
| 2930 | /** |
| 2931 | * RIL_REQUEST_SET_CALL_FORWARD |
| 2932 | * |
| 2933 | * Configure call forward rule |
| 2934 | * |
| 2935 | * "data" is const RIL_CallForwardInfo * |
| 2936 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2937 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2938 | * Valid errors: |
| 2939 | * SUCCESS |
| 2940 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2941 | * SS_MODIFIED_TO_DIAL |
| 2942 | * SS_MODIFIED_TO_USSD |
| 2943 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2944 | * INVALID_ARGUMENTS |
| 2945 | * NO_MEMORY |
| 2946 | * SYSTEM_ERR |
| 2947 | * MODEM_ERR |
| 2948 | * INTERNAL_ERR |
| 2949 | * INVALID_STATE |
| 2950 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2951 | */ |
| 2952 | #define RIL_REQUEST_SET_CALL_FORWARD 34 |
| 2953 | |
| 2954 | |
| 2955 | /** |
| 2956 | * RIL_REQUEST_QUERY_CALL_WAITING |
| 2957 | * |
| 2958 | * Query current call waiting state |
| 2959 | * |
| 2960 | * "data" is const int * |
| 2961 | * ((const int *)data)[0] is the TS 27.007 service class to query. |
| 2962 | * "response" is a const int * |
| 2963 | * ((const int *)response)[0] is 0 for "disabled" and 1 for "enabled" |
| 2964 | * |
| 2965 | * If ((const int *)response)[0] is = 1, then ((const int *)response)[1] |
| 2966 | * must follow, with the TS 27.007 service class bit vector of services |
| 2967 | * for which call waiting is enabled. |
| 2968 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 2969 | * For example, if ((const int *)response)[0] is 1 and |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2970 | * ((const int *)response)[1] is 3, then call waiting is enabled for data |
| 2971 | * and voice and disabled for everything else |
| 2972 | * |
| 2973 | * Valid errors: |
| 2974 | * SUCCESS |
| 2975 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 2976 | * SS_MODIFIED_TO_DIAL |
| 2977 | * SS_MODIFIED_TO_USSD |
| 2978 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 2979 | * NO_MEMORY |
| 2980 | * MODEM_ERR |
| 2981 | * INTERNAL_ERR |
| 2982 | * NO_MEMORY |
| 2983 | * FDN_CHECK_FAILURE |
| 2984 | * INVALID_ARGUMENTS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 2985 | */ |
| 2986 | #define RIL_REQUEST_QUERY_CALL_WAITING 35 |
| 2987 | |
| 2988 | |
| 2989 | /** |
| 2990 | * RIL_REQUEST_SET_CALL_WAITING |
| 2991 | * |
| 2992 | * Configure current call waiting state |
| 2993 | * |
| 2994 | * "data" is const int * |
| 2995 | * ((const int *)data)[0] is 0 for "disabled" and 1 for "enabled" |
| 2996 | * ((const int *)data)[1] is the TS 27.007 service class bit vector of |
| 2997 | * services to modify |
| 2998 | * "response" is NULL |
| 2999 | * |
| 3000 | * Valid errors: |
| 3001 | * SUCCESS |
| 3002 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 3003 | * SS_MODIFIED_TO_DIAL |
| 3004 | * SS_MODIFIED_TO_USSD |
| 3005 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3006 | * INVALID_ARGUMENTS |
| 3007 | * NO_MEMORY |
| 3008 | * MODEM_ERR |
| 3009 | * INTERNAL_ERR |
| 3010 | * INVALID_STATE |
| 3011 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3012 | */ |
| 3013 | #define RIL_REQUEST_SET_CALL_WAITING 36 |
| 3014 | |
| 3015 | /** |
| 3016 | * RIL_REQUEST_SMS_ACKNOWLEDGE |
| 3017 | * |
| 3018 | * Acknowledge successful or failed receipt of SMS previously indicated |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3019 | * via RIL_UNSOL_RESPONSE_NEW_SMS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3020 | * |
| 3021 | * "data" is int * |
jsh | b60444e | 2009-05-29 11:09:17 -0700 | [diff] [blame] | 3022 | * ((int *)data)[0] is 1 on successful receipt |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3023 | * (basically, AT+CNMA=1 from TS 27.005 |
jsh | b60444e | 2009-05-29 11:09:17 -0700 | [diff] [blame] | 3024 | * is 0 on failed receipt |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3025 | * (basically, AT+CNMA=2 from TS 27.005) |
jsh | b60444e | 2009-05-29 11:09:17 -0700 | [diff] [blame] | 3026 | * ((int *)data)[1] if data[0] is 0, this contains the failure cause as defined |
| 3027 | * in TS 23.040, 9.2.3.22. Currently only 0xD3 (memory |
| 3028 | * capacity exceeded) and 0xFF (unspecified error) are |
| 3029 | * reported. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3030 | * |
| 3031 | * "response" is NULL |
| 3032 | * |
| 3033 | * FIXME would like request that specified RP-ACK/RP-ERROR PDU |
| 3034 | * |
| 3035 | * Valid errors: |
| 3036 | * SUCCESS |
| 3037 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3038 | */ |
| 3039 | #define RIL_REQUEST_SMS_ACKNOWLEDGE 37 |
| 3040 | |
| 3041 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3042 | * RIL_REQUEST_GET_IMEI - DEPRECATED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3043 | * |
| 3044 | * Get the device IMEI, including check digit |
| 3045 | * |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 3046 | * The request is DEPRECATED, use RIL_REQUEST_DEVICE_IDENTITY |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3047 | * Valid when RadioState is not RADIO_STATE_UNAVAILABLE |
| 3048 | * |
| 3049 | * "data" is NULL |
| 3050 | * "response" is a const char * containing the IMEI |
| 3051 | * |
| 3052 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3053 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3054 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3055 | */ |
| 3056 | |
| 3057 | #define RIL_REQUEST_GET_IMEI 38 |
| 3058 | |
| 3059 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3060 | * RIL_REQUEST_GET_IMEISV - DEPRECATED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3061 | * |
| 3062 | * Get the device IMEISV, which should be two decimal digits |
| 3063 | * |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 3064 | * The request is DEPRECATED, use RIL_REQUEST_DEVICE_IDENTITY |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3065 | * Valid when RadioState is not RADIO_STATE_UNAVAILABLE |
| 3066 | * |
| 3067 | * "data" is NULL |
| 3068 | * "response" is a const char * containing the IMEISV |
| 3069 | * |
| 3070 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3071 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3072 | * RADIO_NOT_AVAILABLE (radio resetting) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3073 | */ |
| 3074 | |
| 3075 | #define RIL_REQUEST_GET_IMEISV 39 |
| 3076 | |
| 3077 | |
| 3078 | /** |
| 3079 | * RIL_REQUEST_ANSWER |
| 3080 | * |
| 3081 | * Answer incoming call |
| 3082 | * |
| 3083 | * Will not be called for WAITING calls. |
| 3084 | * RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE will be used in this case |
| 3085 | * instead |
| 3086 | * |
| 3087 | * "data" is NULL |
| 3088 | * "response" is NULL |
| 3089 | * |
| 3090 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3091 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3092 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3093 | * INVALID_STATE |
| 3094 | * NO_MEMORY |
| 3095 | * SYSTEM_ERR |
| 3096 | * MODEM_ERR |
| 3097 | * INTERNAL_ERR |
| 3098 | * INVALID_CALL_ID |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3099 | */ |
| 3100 | |
| 3101 | #define RIL_REQUEST_ANSWER 40 |
| 3102 | |
| 3103 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3104 | * RIL_REQUEST_DEACTIVATE_DATA_CALL |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3105 | * |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 3106 | * Deactivate packet data connection and remove from the |
| 3107 | * data call list if SUCCESS is returned. Any other return |
| 3108 | * values should also try to remove the call from the list, |
| 3109 | * but that may not be possible. In any event a |
| 3110 | * RIL_REQUEST_RADIO_POWER off/on must clear the list. An |
| 3111 | * RIL_UNSOL_DATA_CALL_LIST_CHANGED is not expected to be |
| 3112 | * issued because of an RIL_REQUEST_DEACTIVATE_DATA_CALL. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3113 | * |
| 3114 | * "data" is const char ** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3115 | * ((char**)data)[0] indicating CID |
Kazuhiro Ondo | d86799a | 2010-12-02 13:22:35 -0600 | [diff] [blame] | 3116 | * ((char**)data)[1] indicating Disconnect Reason |
| 3117 | * 0 => No specific reason specified |
| 3118 | * 1 => Radio shutdown requested |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3119 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3120 | * "response" is NULL |
| 3121 | * |
| 3122 | * Valid errors: |
| 3123 | * SUCCESS |
| 3124 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3125 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3126 | * See also: RIL_REQUEST_SETUP_DATA_CALL |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3127 | */ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3128 | #define RIL_REQUEST_DEACTIVATE_DATA_CALL 41 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3129 | |
| 3130 | /** |
| 3131 | * RIL_REQUEST_QUERY_FACILITY_LOCK |
| 3132 | * |
| 3133 | * Query the status of a facility lock state |
| 3134 | * |
| 3135 | * "data" is const char ** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3136 | * ((const char **)data)[0] is the facility string code from TS 27.007 7.4 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3137 | * (eg "AO" for BAOC, "SC" for SIM lock) |
| 3138 | * ((const char **)data)[1] is the password, or "" if not required |
| 3139 | * ((const char **)data)[2] is the TS 27.007 service class bit vector of |
| 3140 | * services to query |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3141 | * ((const char **)data)[3] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
Wink Saville | fd72937 | 2011-02-22 16:19:39 -0800 | [diff] [blame] | 3142 | * This is only applicable in the case of Fixed Dialing Numbers |
| 3143 | * (FDN) requests. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3144 | * |
| 3145 | * "response" is an int * |
| 3146 | * ((const int *)response) 0 is the TS 27.007 service class bit vector of |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3147 | * services for which the specified barring facility |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3148 | * is active. "0" means "disabled for all" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3149 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3150 | * |
| 3151 | * Valid errors: |
| 3152 | * SUCCESS |
| 3153 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 3154 | * SS_MODIFIED_TO_DIAL |
| 3155 | * SS_MODIFIED_TO_USSD |
| 3156 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3157 | * INVALID_ARGUMENTS |
| 3158 | * NO_MEMORY |
| 3159 | * INTERNAL_ERR |
| 3160 | * SYSTEM_ERR |
| 3161 | * MODEM_ERR |
| 3162 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3163 | * |
| 3164 | */ |
| 3165 | #define RIL_REQUEST_QUERY_FACILITY_LOCK 42 |
| 3166 | |
| 3167 | /** |
| 3168 | * RIL_REQUEST_SET_FACILITY_LOCK |
| 3169 | * |
| 3170 | * Enable/disable one facility lock |
| 3171 | * |
| 3172 | * "data" is const char ** |
| 3173 | * |
| 3174 | * ((const char **)data)[0] = facility string code from TS 27.007 7.4 |
| 3175 | * (eg "AO" for BAOC) |
| 3176 | * ((const char **)data)[1] = "0" for "unlock" and "1" for "lock" |
| 3177 | * ((const char **)data)[2] = password |
| 3178 | * ((const char **)data)[3] = string representation of decimal TS 27.007 |
| 3179 | * service class bit vector. Eg, the string |
| 3180 | * "1" means "set this facility for voice services" |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3181 | * ((const char **)data)[4] = AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. |
Wink Saville | fd72937 | 2011-02-22 16:19:39 -0800 | [diff] [blame] | 3182 | * This is only applicable in the case of Fixed Dialing Numbers |
| 3183 | * (FDN) requests. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3184 | * |
jsh | 593c910 | 2009-06-24 16:13:44 -0700 | [diff] [blame] | 3185 | * "response" is int * |
| 3186 | * ((int *)response)[0] is the number of retries remaining, or -1 if unknown |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3187 | * |
| 3188 | * Valid errors: |
| 3189 | * SUCCESS |
| 3190 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 3191 | * SS_MODIFIED_TO_DIAL |
| 3192 | * SS_MODIFIED_TO_USSD |
| 3193 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3194 | * INVALID_ARGUMENTS |
| 3195 | * INTERNAL_ERR |
| 3196 | * NO_MEMORY |
| 3197 | * MODEM_ERR |
| 3198 | * INVALID_STATE |
| 3199 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3200 | * |
| 3201 | */ |
| 3202 | #define RIL_REQUEST_SET_FACILITY_LOCK 43 |
| 3203 | |
| 3204 | /** |
| 3205 | * RIL_REQUEST_CHANGE_BARRING_PASSWORD |
| 3206 | * |
| 3207 | * Change call barring facility password |
| 3208 | * |
| 3209 | * "data" is const char ** |
| 3210 | * |
| 3211 | * ((const char **)data)[0] = facility string code from TS 27.007 7.4 |
| 3212 | * (eg "AO" for BAOC) |
| 3213 | * ((const char **)data)[1] = old password |
| 3214 | * ((const char **)data)[2] = new password |
| 3215 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3216 | * "response" is NULL |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3217 | * |
| 3218 | * Valid errors: |
| 3219 | * SUCCESS |
| 3220 | * RADIO_NOT_AVAILABLE |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 3221 | * SS_MODIFIED_TO_DIAL |
| 3222 | * SS_MODIFIED_TO_USSD |
| 3223 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3224 | * INVALID_ARGUMENTS |
| 3225 | * NO_MEMORY |
| 3226 | * MODEM_ERR |
| 3227 | * INTERNAL_ERR |
| 3228 | * SYSTEM_ERR |
| 3229 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3230 | * |
| 3231 | */ |
| 3232 | #define RIL_REQUEST_CHANGE_BARRING_PASSWORD 44 |
| 3233 | |
| 3234 | /** |
| 3235 | * RIL_REQUEST_QUERY_NETWORK_SELECTION_MODE |
| 3236 | * |
| 3237 | * Query current network selectin mode |
| 3238 | * |
| 3239 | * "data" is NULL |
| 3240 | * |
| 3241 | * "response" is int * |
| 3242 | * ((const int *)response)[0] is |
| 3243 | * 0 for automatic selection |
| 3244 | * 1 for manual selection |
| 3245 | * |
| 3246 | * Valid errors: |
| 3247 | * SUCCESS |
| 3248 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3249 | * |
| 3250 | */ |
| 3251 | #define RIL_REQUEST_QUERY_NETWORK_SELECTION_MODE 45 |
| 3252 | |
| 3253 | /** |
| 3254 | * RIL_REQUEST_SET_NETWORK_SELECTION_AUTOMATIC |
| 3255 | * |
| 3256 | * Specify that the network should be selected automatically |
| 3257 | * |
| 3258 | * "data" is NULL |
| 3259 | * "response" is NULL |
| 3260 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3261 | * This request must not respond until the new operator is selected |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3262 | * and registered |
| 3263 | * |
| 3264 | * Valid errors: |
| 3265 | * SUCCESS |
| 3266 | * RADIO_NOT_AVAILABLE |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 3267 | * ILLEGAL_SIM_OR_ME |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3268 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3269 | * |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 3270 | * Note: Returns ILLEGAL_SIM_OR_ME when the failure is permanent and |
| 3271 | * no retries needed, such as illegal SIM or ME. |
| 3272 | * Returns GENERIC_FAILURE for all other causes that might be |
| 3273 | * fixed by retries. |
| 3274 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3275 | */ |
| 3276 | #define RIL_REQUEST_SET_NETWORK_SELECTION_AUTOMATIC 46 |
| 3277 | |
| 3278 | /** |
| 3279 | * RIL_REQUEST_SET_NETWORK_SELECTION_MANUAL |
| 3280 | * |
| 3281 | * Manually select a specified network. |
| 3282 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3283 | * "data" is const char * specifying MCCMNC of network to select (eg "310170") |
| 3284 | * "response" is NULL |
| 3285 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3286 | * This request must not respond until the new operator is selected |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3287 | * and registered |
| 3288 | * |
| 3289 | * Valid errors: |
| 3290 | * SUCCESS |
| 3291 | * RADIO_NOT_AVAILABLE |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 3292 | * ILLEGAL_SIM_OR_ME |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3293 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3294 | * |
John Wang | 7553447 | 2010-04-20 15:11:42 -0700 | [diff] [blame] | 3295 | * Note: Returns ILLEGAL_SIM_OR_ME when the failure is permanent and |
| 3296 | * no retries needed, such as illegal SIM or ME. |
| 3297 | * Returns GENERIC_FAILURE for all other causes that might be |
| 3298 | * fixed by retries. |
| 3299 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3300 | */ |
| 3301 | #define RIL_REQUEST_SET_NETWORK_SELECTION_MANUAL 47 |
| 3302 | |
| 3303 | /** |
| 3304 | * RIL_REQUEST_QUERY_AVAILABLE_NETWORKS |
| 3305 | * |
| 3306 | * Scans for available networks |
| 3307 | * |
| 3308 | * "data" is NULL |
| 3309 | * "response" is const char ** that should be an array of n*4 strings, where |
| 3310 | * n is the number of available networks |
| 3311 | * For each available network: |
| 3312 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3313 | * ((const char **)response)[n+0] is long alpha ONS or EONS |
| 3314 | * ((const char **)response)[n+1] is short alpha ONS or EONS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3315 | * ((const char **)response)[n+2] is 5 or 6 digit numeric code (MCC + MNC) |
| 3316 | * ((const char **)response)[n+3] is a string value of the status: |
| 3317 | * "unknown" |
| 3318 | * "available" |
| 3319 | * "current" |
| 3320 | * "forbidden" |
| 3321 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3322 | * Valid errors: |
| 3323 | * SUCCESS |
| 3324 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3325 | * OPERATION_NOT_ALLOWED |
Jayachandran C | b0cba83 | 2017-03-13 19:17:18 -0700 | [diff] [blame] | 3326 | * ABORTED |
| 3327 | * DEVICE_IN_USE |
| 3328 | * INTERNAL_ERR |
| 3329 | * NO_MEMORY |
| 3330 | * MODEM_ERR |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3331 | * |
| 3332 | */ |
| 3333 | #define RIL_REQUEST_QUERY_AVAILABLE_NETWORKS 48 |
| 3334 | |
| 3335 | /** |
| 3336 | * RIL_REQUEST_DTMF_START |
| 3337 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3338 | * Start playing a DTMF tone. Continue playing DTMF tone until |
| 3339 | * RIL_REQUEST_DTMF_STOP is received |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3340 | * |
| 3341 | * If a RIL_REQUEST_DTMF_START is received while a tone is currently playing, |
| 3342 | * it should cancel the previous tone and play the new one. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3343 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3344 | * "data" is a char * |
| 3345 | * ((char *)data)[0] is a single character with one of 12 values: 0-9,*,# |
| 3346 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3347 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3348 | * Valid errors: |
| 3349 | * SUCCESS |
| 3350 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3351 | * INVALID_ARGUMENTS |
| 3352 | * NO_RESOURCES |
| 3353 | * NO_MEMORY |
| 3354 | * SYSTEM_ERR |
| 3355 | * MODEM_ERR |
| 3356 | * INTERNAL_ERR |
| 3357 | * INVALID_CALL_ID |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3358 | * |
| 3359 | * See also: RIL_REQUEST_DTMF, RIL_REQUEST_DTMF_STOP |
| 3360 | */ |
| 3361 | #define RIL_REQUEST_DTMF_START 49 |
| 3362 | |
| 3363 | /** |
| 3364 | * RIL_REQUEST_DTMF_STOP |
| 3365 | * |
| 3366 | * Stop playing a currently playing DTMF tone. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3367 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3368 | * "data" is NULL |
| 3369 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3370 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3371 | * Valid errors: |
| 3372 | * SUCCESS |
| 3373 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3374 | * OPERATION_NOT_ALLOWED |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3375 | * NO_RESOURCES |
| 3376 | * NO_MEMORY |
| 3377 | * INVALID_ARGUMENTS |
| 3378 | * SYSTEM_ERR |
| 3379 | * MODEM_ERR |
| 3380 | * INTERNAL_ERR |
| 3381 | * INVALID_CALL_ID |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3382 | * |
| 3383 | * See also: RIL_REQUEST_DTMF, RIL_REQUEST_DTMF_START |
| 3384 | */ |
| 3385 | #define RIL_REQUEST_DTMF_STOP 50 |
| 3386 | |
| 3387 | /** |
| 3388 | * RIL_REQUEST_BASEBAND_VERSION |
| 3389 | * |
| 3390 | * Return string value indicating baseband version, eg |
| 3391 | * response from AT+CGMR |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3392 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3393 | * "data" is NULL |
| 3394 | * "response" is const char * containing version string for log reporting |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3395 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3396 | * Valid errors: |
| 3397 | * SUCCESS |
| 3398 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3399 | * EMPTY_RECORD |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3400 | * |
| 3401 | */ |
| 3402 | #define RIL_REQUEST_BASEBAND_VERSION 51 |
| 3403 | |
| 3404 | /** |
| 3405 | * RIL_REQUEST_SEPARATE_CONNECTION |
| 3406 | * |
| 3407 | * Separate a party from a multiparty call placing the multiparty call |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3408 | * (less the specified party) on hold and leaving the specified party |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3409 | * as the only other member of the current (active) call |
| 3410 | * |
| 3411 | * Like AT+CHLD=2x |
| 3412 | * |
| 3413 | * See TS 22.084 1.3.8.2 (iii) |
| 3414 | * TS 22.030 6.5.5 "Entering "2X followed by send" |
| 3415 | * TS 27.007 "AT+CHLD=2x" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3416 | * |
| 3417 | * "data" is an int * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3418 | * (int *)data)[0] contains Connection index (value of 'x' in CHLD above) "response" is NULL |
| 3419 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3420 | * "response" is NULL |
| 3421 | * |
| 3422 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3423 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3424 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3425 | * INVALID_ARGUMENTS |
| 3426 | * INVALID_STATE |
| 3427 | * NO_RESOURCES |
| 3428 | * NO_MEMORY |
| 3429 | * SYSTEM_ERR |
| 3430 | * MODEM_ERR |
| 3431 | * INTERNAL_ERR |
| 3432 | * INVALID_CALL_ID |
| 3433 | * INVALID_STATE |
| 3434 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3435 | */ |
| 3436 | #define RIL_REQUEST_SEPARATE_CONNECTION 52 |
| 3437 | |
| 3438 | |
| 3439 | /** |
| 3440 | * RIL_REQUEST_SET_MUTE |
| 3441 | * |
| 3442 | * Turn on or off uplink (microphone) mute. |
| 3443 | * |
| 3444 | * Will only be sent while voice call is active. |
| 3445 | * Will always be reset to "disable mute" when a new voice call is initiated |
| 3446 | * |
| 3447 | * "data" is an int * |
| 3448 | * (int *)data)[0] is 1 for "enable mute" and 0 for "disable mute" |
| 3449 | * |
| 3450 | * "response" is NULL |
| 3451 | * |
| 3452 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3453 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3454 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 3455 | * INVALID_ARGUMENTS |
| 3456 | * NO_MEMORY |
| 3457 | * REQUEST_RATE_LIMITED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3458 | */ |
| 3459 | |
| 3460 | #define RIL_REQUEST_SET_MUTE 53 |
| 3461 | |
| 3462 | /** |
| 3463 | * RIL_REQUEST_GET_MUTE |
| 3464 | * |
| 3465 | * Queries the current state of the uplink mute setting |
| 3466 | * |
| 3467 | * "data" is NULL |
| 3468 | * "response" is an int * |
| 3469 | * (int *)response)[0] is 1 for "mute enabled" and 0 for "mute disabled" |
| 3470 | * |
| 3471 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3472 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3473 | * RADIO_NOT_AVAILABLE (radio resetting) |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 3474 | * SS_MODIFIED_TO_DIAL |
| 3475 | * SS_MODIFIED_TO_USSD |
| 3476 | * SS_MODIFIED_TO_SS |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 3477 | * NO_MEMORY |
| 3478 | * REQUEST_RATE_LIMITED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3479 | */ |
| 3480 | |
| 3481 | #define RIL_REQUEST_GET_MUTE 54 |
| 3482 | |
| 3483 | /** |
| 3484 | * RIL_REQUEST_QUERY_CLIP |
| 3485 | * |
| 3486 | * Queries the status of the CLIP supplementary service |
| 3487 | * |
| 3488 | * (for MMI code "*#30#") |
| 3489 | * |
| 3490 | * "data" is NULL |
| 3491 | * "response" is an int * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3492 | * (int *)response)[0] is 1 for "CLIP provisioned" |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3493 | * and 0 for "CLIP not provisioned" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3494 | * and 2 for "unknown, e.g. no network etc" |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3495 | * |
| 3496 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3497 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3498 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3499 | * NO_MEMORY |
| 3500 | * SYSTEM_ERR |
| 3501 | * MODEM_ERR |
| 3502 | * INTERNAL_ERR |
| 3503 | * FDN_CHECK_FAILURE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3504 | */ |
| 3505 | |
| 3506 | #define RIL_REQUEST_QUERY_CLIP 55 |
| 3507 | |
| 3508 | /** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3509 | * RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE - Deprecated use the status |
| 3510 | * field in RIL_Data_Call_Response_v6. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3511 | * |
| 3512 | * Requests the failure cause code for the most recently failed PDP |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3513 | * context or CDMA data connection active |
| 3514 | * replaces RIL_REQUEST_LAST_PDP_FAIL_CAUSE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3515 | * |
| 3516 | * "data" is NULL |
| 3517 | * |
| 3518 | * "response" is a "int *" |
| 3519 | * ((int *)response)[0] is an integer cause code defined in TS 24.008 |
| 3520 | * section 6.1.3.1.3 or close approximation |
| 3521 | * |
| 3522 | * If the implementation does not have access to the exact cause codes, |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3523 | * then it should return one of the values listed in |
Wink Saville | 4380897 | 2011-01-13 17:39:51 -0800 | [diff] [blame] | 3524 | * RIL_DataCallFailCause, as the UI layer needs to distinguish these |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3525 | * cases for error notification |
| 3526 | * and potential retries. |
| 3527 | * |
| 3528 | * Valid errors: |
| 3529 | * SUCCESS |
| 3530 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3531 | * |
| 3532 | * See also: RIL_REQUEST_LAST_CALL_FAIL_CAUSE |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3533 | * |
| 3534 | * Deprecated use the status field in RIL_Data_Call_Response_v6. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3535 | */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3536 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3537 | #define RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE 56 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3538 | |
| 3539 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3540 | * RIL_REQUEST_DATA_CALL_LIST |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3541 | * |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 3542 | * Returns the data call list. An entry is added when a |
| 3543 | * RIL_REQUEST_SETUP_DATA_CALL is issued and removed on a |
| 3544 | * RIL_REQUEST_DEACTIVATE_DATA_CALL. The list is emptied |
| 3545 | * when RIL_REQUEST_RADIO_POWER off/on is issued. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3546 | * |
| 3547 | * "data" is NULL |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3548 | * "response" is an array of RIL_Data_Call_Response_v6 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3549 | * |
| 3550 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3551 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3552 | * RADIO_NOT_AVAILABLE (radio resetting) |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 3553 | * |
| 3554 | * See also: RIL_UNSOL_DATA_CALL_LIST_CHANGED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3555 | */ |
| 3556 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3557 | #define RIL_REQUEST_DATA_CALL_LIST 57 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3558 | |
| 3559 | /** |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 3560 | * RIL_REQUEST_RESET_RADIO - DEPRECATED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3561 | * |
| 3562 | * Request a radio reset. The RIL implementation may postpone |
| 3563 | * the reset until after this request is responded to if the baseband |
| 3564 | * is presently busy. |
| 3565 | * |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 3566 | * The request is DEPRECATED, use RIL_REQUEST_RADIO_POWER |
| 3567 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3568 | * "data" is NULL |
| 3569 | * "response" is NULL |
| 3570 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3571 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3572 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3573 | * RADIO_NOT_AVAILABLE (radio resetting) |
johnwang | f8bc167 | 2009-05-14 19:19:47 -0700 | [diff] [blame] | 3574 | * REQUEST_NOT_SUPPORTED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3575 | */ |
| 3576 | |
| 3577 | #define RIL_REQUEST_RESET_RADIO 58 |
| 3578 | |
| 3579 | /** |
| 3580 | * RIL_REQUEST_OEM_HOOK_RAW |
| 3581 | * |
| 3582 | * This request reserved for OEM-specific uses. It passes raw byte arrays |
| 3583 | * back and forth. |
| 3584 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3585 | * It can be invoked on the Java side from |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3586 | * com.android.internal.telephony.Phone.invokeOemRilRequestRaw() |
| 3587 | * |
| 3588 | * "data" is a char * of bytes copied from the byte[] data argument in java |
| 3589 | * "response" is a char * of bytes that will returned via the |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3590 | * caller's "response" Message here: |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3591 | * (byte[])(((AsyncResult)response.obj).result) |
| 3592 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3593 | * An error response here will result in |
| 3594 | * (((AsyncResult)response.obj).result) == null and |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3595 | * (((AsyncResult)response.obj).exception) being an instance of |
| 3596 | * com.android.internal.telephony.gsm.CommandException |
| 3597 | * |
| 3598 | * Valid errors: |
| 3599 | * All |
| 3600 | */ |
| 3601 | |
| 3602 | #define RIL_REQUEST_OEM_HOOK_RAW 59 |
| 3603 | |
| 3604 | /** |
| 3605 | * RIL_REQUEST_OEM_HOOK_STRINGS |
| 3606 | * |
| 3607 | * This request reserved for OEM-specific uses. It passes strings |
| 3608 | * back and forth. |
| 3609 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3610 | * It can be invoked on the Java side from |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3611 | * com.android.internal.telephony.Phone.invokeOemRilRequestStrings() |
| 3612 | * |
| 3613 | * "data" is a const char **, representing an array of null-terminated UTF-8 |
| 3614 | * strings copied from the "String[] strings" argument to |
| 3615 | * invokeOemRilRequestStrings() |
| 3616 | * |
| 3617 | * "response" is a const char **, representing an array of null-terminated UTF-8 |
| 3618 | * stings that will be returned via the caller's response message here: |
| 3619 | * |
| 3620 | * (String[])(((AsyncResult)response.obj).result) |
| 3621 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3622 | * An error response here will result in |
| 3623 | * (((AsyncResult)response.obj).result) == null and |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3624 | * (((AsyncResult)response.obj).exception) being an instance of |
| 3625 | * com.android.internal.telephony.gsm.CommandException |
| 3626 | * |
| 3627 | * Valid errors: |
| 3628 | * All |
| 3629 | */ |
| 3630 | |
| 3631 | #define RIL_REQUEST_OEM_HOOK_STRINGS 60 |
| 3632 | |
| 3633 | /** |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 3634 | * RIL_REQUEST_SCREEN_STATE - DEPRECATED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3635 | * |
| 3636 | * Indicates the current state of the screen. When the screen is off, the |
| 3637 | * RIL should notify the baseband to suppress certain notifications (eg, |
jsh | 4326561 | 2009-09-29 17:46:11 -0700 | [diff] [blame] | 3638 | * signal strength and changes in LAC/CID or BID/SID/NID/latitude/longitude) |
| 3639 | * in an effort to conserve power. These notifications should resume when the |
| 3640 | * screen is on. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3641 | * |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 3642 | * Note this request is deprecated. Use RIL_REQUEST_SEND_DEVICE_STATE to report the device state |
| 3643 | * to the modem and use RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER to turn on/off unsolicited |
| 3644 | * response from the modem in different scenarios. |
| 3645 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3646 | * "data" is int * |
| 3647 | * ((int *)data)[0] is == 1 for "Screen On" |
| 3648 | * ((int *)data)[0] is == 0 for "Screen Off" |
| 3649 | * |
| 3650 | * "response" is NULL |
| 3651 | * |
| 3652 | * Valid errors: |
| 3653 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3654 | */ |
| 3655 | #define RIL_REQUEST_SCREEN_STATE 61 |
| 3656 | |
| 3657 | |
| 3658 | /** |
| 3659 | * RIL_REQUEST_SET_SUPP_SVC_NOTIFICATION |
| 3660 | * |
| 3661 | * Enables/disables supplementary service related notifications |
| 3662 | * from the network. |
| 3663 | * |
| 3664 | * Notifications are reported via RIL_UNSOL_SUPP_SVC_NOTIFICATION. |
| 3665 | * |
| 3666 | * "data" is int * |
| 3667 | * ((int *)data)[0] is == 1 for notifications enabled |
| 3668 | * ((int *)data)[0] is == 0 for notifications disabled |
| 3669 | * |
| 3670 | * "response" is NULL |
| 3671 | * |
| 3672 | * Valid errors: |
| 3673 | * SUCCESS |
| 3674 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3675 | * SIM_BUSY |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3676 | * INVALID_ARGUMENTS |
| 3677 | * NO_MEMORY |
| 3678 | * SYSTEM_ERR |
| 3679 | * MODEM_ERR |
| 3680 | * INTERNAL_ERR |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3681 | * |
| 3682 | * See also: RIL_UNSOL_SUPP_SVC_NOTIFICATION. |
| 3683 | */ |
| 3684 | #define RIL_REQUEST_SET_SUPP_SVC_NOTIFICATION 62 |
| 3685 | |
| 3686 | /** |
| 3687 | * RIL_REQUEST_WRITE_SMS_TO_SIM |
| 3688 | * |
| 3689 | * Stores a SMS message to SIM memory. |
| 3690 | * |
| 3691 | * "data" is RIL_SMS_WriteArgs * |
| 3692 | * |
| 3693 | * "response" is int * |
| 3694 | * ((const int *)response)[0] is the record index where the message is stored. |
| 3695 | * |
| 3696 | * Valid errors: |
| 3697 | * SUCCESS |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3698 | * SIM_FULL |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 3699 | * INVALID_ARGUMENTS |
| 3700 | * INVALID_SMS_FORMAT |
| 3701 | * INTERNAL_ERR |
| 3702 | * MODEM_ERR |
| 3703 | * ENCODING_ERR |
| 3704 | * NO_MEMORY |
| 3705 | * NO_RESOURCES |
| 3706 | * INVALID_MODEM_STATE |
| 3707 | * MODE_NOT_SUPPORTED |
| 3708 | * INVALID_SMSC_ADDRESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3709 | * |
| 3710 | */ |
| 3711 | #define RIL_REQUEST_WRITE_SMS_TO_SIM 63 |
| 3712 | |
| 3713 | /** |
| 3714 | * RIL_REQUEST_DELETE_SMS_ON_SIM |
| 3715 | * |
| 3716 | * Deletes a SMS message from SIM memory. |
| 3717 | * |
| 3718 | * "data" is int * |
| 3719 | * ((int *)data)[0] is the record index of the message to delete. |
| 3720 | * |
| 3721 | * "response" is NULL |
| 3722 | * |
| 3723 | * Valid errors: |
| 3724 | * SUCCESS |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3725 | * SIM_FULL |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 3726 | * INVALID_ARGUMENTS |
| 3727 | * NO_MEMORY |
| 3728 | * REQUEST_RATE_LIMITED |
| 3729 | * SYSTEM_ERR |
| 3730 | * MODEM_ERR |
| 3731 | * NO_SUCH_ENTRY |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3732 | * |
| 3733 | */ |
| 3734 | #define RIL_REQUEST_DELETE_SMS_ON_SIM 64 |
| 3735 | |
| 3736 | /** |
| 3737 | * RIL_REQUEST_SET_BAND_MODE |
| 3738 | * |
| 3739 | * Assign a specified band for RF configuration. |
| 3740 | * |
| 3741 | * "data" is int * |
Nathan Harold | 92839f1 | 2016-02-12 10:02:28 -0800 | [diff] [blame] | 3742 | * ((int *)data)[0] is a RIL_RadioBandMode |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3743 | * |
| 3744 | * "response" is NULL |
| 3745 | * |
| 3746 | * Valid errors: |
| 3747 | * SUCCESS |
| 3748 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3749 | * OPERATION_NOT_ALLOWED |
Nathan Harold | 92839f1 | 2016-02-12 10:02:28 -0800 | [diff] [blame] | 3750 | * |
| 3751 | * See also: RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3752 | */ |
| 3753 | #define RIL_REQUEST_SET_BAND_MODE 65 |
| 3754 | |
| 3755 | /** |
| 3756 | * RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE |
| 3757 | * |
| 3758 | * Query the list of band mode supported by RF. |
| 3759 | * |
| 3760 | * "data" is NULL |
| 3761 | * |
| 3762 | * "response" is int * |
Nathan Harold | 92839f1 | 2016-02-12 10:02:28 -0800 | [diff] [blame] | 3763 | * "response" points to an array of int's, the int[0] is the size of array; |
| 3764 | * subsequent values are a list of RIL_RadioBandMode listing supported modes. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3765 | * |
| 3766 | * Valid errors: |
| 3767 | * SUCCESS |
| 3768 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3769 | * |
| 3770 | * See also: RIL_REQUEST_SET_BAND_MODE |
| 3771 | */ |
| 3772 | #define RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE 66 |
| 3773 | |
| 3774 | /** |
| 3775 | * RIL_REQUEST_STK_GET_PROFILE |
| 3776 | * |
| 3777 | * Requests the profile of SIM tool kit. |
| 3778 | * The profile indicates the SAT/USAT features supported by ME. |
| 3779 | * The SAT/USAT features refer to 3GPP TS 11.14 and 3GPP TS 31.111 |
| 3780 | * |
| 3781 | * "data" is NULL |
| 3782 | * |
| 3783 | * "response" is a const char * containing SAT/USAT profile |
| 3784 | * in hexadecimal format string starting with first byte of terminal profile |
| 3785 | * |
| 3786 | * Valid errors: |
| 3787 | * RIL_E_SUCCESS |
| 3788 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
| 3789 | * RIL_E_GENERIC_FAILURE |
| 3790 | */ |
| 3791 | #define RIL_REQUEST_STK_GET_PROFILE 67 |
| 3792 | |
| 3793 | /** |
| 3794 | * RIL_REQUEST_STK_SET_PROFILE |
| 3795 | * |
| 3796 | * Download the STK terminal profile as part of SIM initialization |
| 3797 | * procedure |
| 3798 | * |
| 3799 | * "data" is a const char * containing SAT/USAT profile |
| 3800 | * in hexadecimal format string starting with first byte of terminal profile |
| 3801 | * |
| 3802 | * "response" is NULL |
| 3803 | * |
| 3804 | * Valid errors: |
| 3805 | * RIL_E_SUCCESS |
| 3806 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
| 3807 | * RIL_E_GENERIC_FAILURE |
| 3808 | */ |
| 3809 | #define RIL_REQUEST_STK_SET_PROFILE 68 |
| 3810 | |
| 3811 | /** |
| 3812 | * RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND |
| 3813 | * |
| 3814 | * Requests to send a SAT/USAT envelope command to SIM. |
| 3815 | * The SAT/USAT envelope command refers to 3GPP TS 11.14 and 3GPP TS 31.111 |
| 3816 | * |
| 3817 | * "data" is a const char * containing SAT/USAT command |
| 3818 | * in hexadecimal format string starting with command tag |
| 3819 | * |
| 3820 | * "response" is a const char * containing SAT/USAT response |
| 3821 | * in hexadecimal format string starting with first byte of response |
| 3822 | * (May be NULL) |
| 3823 | * |
| 3824 | * Valid errors: |
| 3825 | * RIL_E_SUCCESS |
| 3826 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3827 | * SIM_BUSY |
| 3828 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3829 | * RIL_E_GENERIC_FAILURE |
| 3830 | */ |
| 3831 | #define RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND 69 |
| 3832 | |
| 3833 | /** |
| 3834 | * RIL_REQUEST_STK_SEND_TERMINAL_RESPONSE |
| 3835 | * |
| 3836 | * Requests to send a terminal response to SIM for a received |
| 3837 | * proactive command |
| 3838 | * |
| 3839 | * "data" is a const char * containing SAT/USAT response |
| 3840 | * in hexadecimal format string starting with first byte of response data |
| 3841 | * |
| 3842 | * "response" is NULL |
| 3843 | * |
| 3844 | * Valid errors: |
| 3845 | * RIL_E_SUCCESS |
| 3846 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3847 | * RIL_E_OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3848 | * RIL_E_GENERIC_FAILURE |
| 3849 | */ |
| 3850 | #define RIL_REQUEST_STK_SEND_TERMINAL_RESPONSE 70 |
| 3851 | |
| 3852 | /** |
| 3853 | * RIL_REQUEST_STK_HANDLE_CALL_SETUP_REQUESTED_FROM_SIM |
| 3854 | * |
| 3855 | * When STK application gets RIL_UNSOL_STK_CALL_SETUP, the call actually has |
| 3856 | * been initialized by ME already. (We could see the call has been in the 'call |
| 3857 | * list') So, STK application needs to accept/reject the call according as user |
| 3858 | * operations. |
| 3859 | * |
| 3860 | * "data" is int * |
| 3861 | * ((int *)data)[0] is > 0 for "accept" the call setup |
| 3862 | * ((int *)data)[0] is == 0 for "reject" the call setup |
| 3863 | * |
| 3864 | * "response" is NULL |
| 3865 | * |
| 3866 | * Valid errors: |
| 3867 | * RIL_E_SUCCESS |
| 3868 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3869 | * RIL_E_OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3870 | * RIL_E_GENERIC_FAILURE |
| 3871 | */ |
| 3872 | #define RIL_REQUEST_STK_HANDLE_CALL_SETUP_REQUESTED_FROM_SIM 71 |
| 3873 | |
| 3874 | /** |
| 3875 | * RIL_REQUEST_EXPLICIT_CALL_TRANSFER |
| 3876 | * |
| 3877 | * Connects the two calls and disconnects the subscriber from both calls. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3878 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3879 | * "data" is NULL |
| 3880 | * "response" is NULL |
| 3881 | * |
| 3882 | * Valid errors: |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3883 | * SUCCESS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3884 | * RADIO_NOT_AVAILABLE (radio resetting) |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 3885 | * INVALID_STATE |
| 3886 | * NO_RESOURCES |
| 3887 | * NO_MEMORY |
| 3888 | * INVALID_ARGUMENTS |
| 3889 | * SYSTEM_ERR |
| 3890 | * MODEM_ERR |
| 3891 | * INTERNAL_ERR |
| 3892 | * INVALID_CALL_ID |
| 3893 | * INVALID_STATE |
| 3894 | * OPERATION_NOT_ALLOWED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3895 | */ |
| 3896 | #define RIL_REQUEST_EXPLICIT_CALL_TRANSFER 72 |
| 3897 | |
| 3898 | /** |
| 3899 | * RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE |
| 3900 | * |
| 3901 | * Requests to set the preferred network type for searching and registering |
| 3902 | * (CS/PS domain, RAT, and operation mode) |
| 3903 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3904 | * "data" is int * which is RIL_PreferredNetworkType |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3905 | * |
| 3906 | * "response" is NULL |
| 3907 | * |
| 3908 | * Valid errors: |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3909 | * SUCCESS |
| 3910 | * RADIO_NOT_AVAILABLE (radio resetting) |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 3911 | * OPERATION_NOT_ALLOWED |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3912 | * MODE_NOT_SUPPORTED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3913 | */ |
| 3914 | #define RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE 73 |
| 3915 | |
| 3916 | /** |
| 3917 | * RIL_REQUEST_GET_PREFERRED_NETWORK_TYPE |
| 3918 | * |
| 3919 | * Query the preferred network type (CS/PS domain, RAT, and operation mode) |
| 3920 | * for searching and registering |
| 3921 | * |
| 3922 | * "data" is NULL |
| 3923 | * |
| 3924 | * "response" is int * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3925 | * ((int *)reponse)[0] is == RIL_PreferredNetworkType |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3926 | * |
| 3927 | * Valid errors: |
| 3928 | * SUCCESS |
| 3929 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3930 | * |
| 3931 | * See also: RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE |
| 3932 | */ |
| 3933 | #define RIL_REQUEST_GET_PREFERRED_NETWORK_TYPE 74 |
| 3934 | |
| 3935 | /** |
| 3936 | * RIL_REQUEST_NEIGHBORING_CELL_IDS |
| 3937 | * |
| 3938 | * Request neighboring cell id in GSM network |
| 3939 | * |
| 3940 | * "data" is NULL |
| 3941 | * "response" must be a " const RIL_NeighboringCell** " |
| 3942 | * |
| 3943 | * Valid errors: |
| 3944 | * SUCCESS |
| 3945 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3946 | */ |
| 3947 | #define RIL_REQUEST_GET_NEIGHBORING_CELL_IDS 75 |
| 3948 | |
| 3949 | /** |
| 3950 | * RIL_REQUEST_SET_LOCATION_UPDATES |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 3951 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3952 | * Enables/disables network state change notifications due to changes in |
jsh | 4326561 | 2009-09-29 17:46:11 -0700 | [diff] [blame] | 3953 | * LAC and/or CID (for GSM) or BID/SID/NID/latitude/longitude (for CDMA). |
| 3954 | * Basically +CREG=2 vs. +CREG=1 (TS 27.007). |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3955 | * |
| 3956 | * Note: The RIL implementation should default to "updates enabled" |
| 3957 | * when the screen is on and "updates disabled" when the screen is off. |
| 3958 | * |
| 3959 | * "data" is int * |
| 3960 | * ((int *)data)[0] is == 1 for updates enabled (+CREG=2) |
| 3961 | * ((int *)data)[0] is == 0 for updates disabled (+CREG=1) |
| 3962 | * |
| 3963 | * "response" is NULL |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 3964 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3965 | * Valid errors: |
| 3966 | * SUCCESS |
| 3967 | * RADIO_NOT_AVAILABLE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 3968 | * |
| 3969 | * See also: RIL_REQUEST_SCREEN_STATE, RIL_UNSOL_RESPONSE_NETWORK_STATE_CHANGED |
| 3970 | */ |
| 3971 | #define RIL_REQUEST_SET_LOCATION_UPDATES 76 |
| 3972 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3973 | /** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3974 | * RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3975 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3976 | * Request to set the location where the CDMA subscription shall |
| 3977 | * be retrieved |
| 3978 | * |
| 3979 | * "data" is int * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3980 | * ((int *)data)[0] is == RIL_CdmaSubscriptionSource |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3981 | * |
| 3982 | * "response" is NULL |
| 3983 | * |
| 3984 | * Valid errors: |
| 3985 | * SUCCESS |
| 3986 | * RADIO_NOT_AVAILABLE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3987 | * SIM_ABSENT |
| 3988 | * SUBSCRIPTION_NOT_AVAILABLE |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3989 | * |
| 3990 | * See also: RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3991 | */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 3992 | #define RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE 77 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3993 | |
| 3994 | /** |
| 3995 | * RIL_REQUEST_CDMA_SET_ROAMING_PREFERENCE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 3996 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 3997 | * Request to set the roaming preferences in CDMA |
| 3998 | * |
| 3999 | * "data" is int * |
| 4000 | * ((int *)data)[0] is == 0 for Home Networks only, as defined in PRL |
| 4001 | * ((int *)data)[0] is == 1 for Roaming on Affiliated networks, as defined in PRL |
| 4002 | * ((int *)data)[0] is == 2 for Roaming on Any Network, as defined in the PRL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4003 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4004 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4005 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4006 | * Valid errors: |
| 4007 | * SUCCESS |
| 4008 | * RADIO_NOT_AVAILABLE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4009 | */ |
| 4010 | #define RIL_REQUEST_CDMA_SET_ROAMING_PREFERENCE 78 |
| 4011 | |
| 4012 | /** |
| 4013 | * RIL_REQUEST_CDMA_QUERY_ROAMING_PREFERENCE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4014 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4015 | * Request the actual setting of the roaming preferences in CDMA in the modem |
| 4016 | * |
| 4017 | * "data" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4018 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4019 | * "response" is int * |
| 4020 | * ((int *)response)[0] is == 0 for Home Networks only, as defined in PRL |
| 4021 | * ((int *)response)[0] is == 1 for Roaming on Affiliated networks, as defined in PRL |
| 4022 | * ((int *)response)[0] is == 2 for Roaming on Any Network, as defined in the PRL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4023 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4024 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4025 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4026 | * Valid errors: |
| 4027 | * SUCCESS |
| 4028 | * RADIO_NOT_AVAILABLE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4029 | */ |
| 4030 | #define RIL_REQUEST_CDMA_QUERY_ROAMING_PREFERENCE 79 |
| 4031 | |
| 4032 | /** |
| 4033 | * RIL_REQUEST_SET_TTY_MODE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4034 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4035 | * Request to set the TTY mode |
| 4036 | * |
| 4037 | * "data" is int * |
| 4038 | * ((int *)data)[0] is == 0 for TTY off |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4039 | * ((int *)data)[0] is == 1 for TTY Full |
| 4040 | * ((int *)data)[0] is == 2 for TTY HCO (hearing carryover) |
| 4041 | * ((int *)data)[0] is == 3 for TTY VCO (voice carryover) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4042 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4043 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4044 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4045 | * Valid errors: |
| 4046 | * SUCCESS |
| 4047 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4048 | * INVALID_ARGUMENTS |
| 4049 | * MODEM_ERR |
| 4050 | * INTERNAL_ERR |
| 4051 | * NO_MEMOR |
| 4052 | * INVALID_ARGUMENTS |
| 4053 | * MODEM_ERR |
| 4054 | * INTERNAL_ERR |
| 4055 | * NO_MEMORYY |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4056 | */ |
| 4057 | #define RIL_REQUEST_SET_TTY_MODE 80 |
| 4058 | |
| 4059 | /** |
| 4060 | * RIL_REQUEST_QUERY_TTY_MODE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4061 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4062 | * Request the setting of TTY mode |
| 4063 | * |
| 4064 | * "data" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4065 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4066 | * "response" is int * |
| 4067 | * ((int *)response)[0] is == 0 for TTY off |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4068 | * ((int *)response)[0] is == 1 for TTY Full |
| 4069 | * ((int *)response)[0] is == 2 for TTY HCO (hearing carryover) |
| 4070 | * ((int *)response)[0] is == 3 for TTY VCO (voice carryover) |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4071 | * |
| 4072 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4073 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4074 | * Valid errors: |
| 4075 | * SUCCESS |
| 4076 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4077 | * MODEM_ERR |
| 4078 | * INTERNAL_ERR |
| 4079 | * NO_MEMORY |
| 4080 | * INVALID_ARGUMENTS |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4081 | */ |
| 4082 | #define RIL_REQUEST_QUERY_TTY_MODE 81 |
| 4083 | |
| 4084 | /** |
| 4085 | * RIL_REQUEST_CDMA_SET_PREFERRED_VOICE_PRIVACY_MODE |
| 4086 | * |
| 4087 | * Request to set the preferred voice privacy mode used in voice |
| 4088 | * scrambling |
| 4089 | * |
| 4090 | * "data" is int * |
| 4091 | * ((int *)data)[0] is == 0 for Standard Privacy Mode (Public Long Code Mask) |
| 4092 | * ((int *)data)[0] is == 1 for Enhanced Privacy Mode (Private Long Code Mask) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4093 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4094 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4095 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4096 | * Valid errors: |
| 4097 | * SUCCESS |
| 4098 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4099 | * INVALID_ARGUMENTS |
| 4100 | * SYSTEM_ERR |
| 4101 | * MODEM_ERR |
| 4102 | * INTERNAL_ERR |
| 4103 | * NO_MEMORY |
| 4104 | * INVALID_CALL_ID |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4105 | */ |
| 4106 | #define RIL_REQUEST_CDMA_SET_PREFERRED_VOICE_PRIVACY_MODE 82 |
| 4107 | |
| 4108 | /** |
| 4109 | * RIL_REQUEST_CDMA_QUERY_PREFERRED_VOICE_PRIVACY_MODE |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4110 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4111 | * Request the setting of preferred voice privacy mode |
| 4112 | * |
| 4113 | * "data" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4114 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4115 | * "response" is int * |
| 4116 | * ((int *)response)[0] is == 0 for Standard Privacy Mode (Public Long Code Mask) |
| 4117 | * ((int *)response)[0] is == 1 for Enhanced Privacy Mode (Private Long Code Mask) |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4118 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4119 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4120 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4121 | * Valid errors: |
| 4122 | * SUCCESS |
| 4123 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4124 | * MODEM_ERR |
| 4125 | * INTERNAL_ERR |
| 4126 | * NO_MEMORY |
| 4127 | * INVALID_ARGUMENTS |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4128 | */ |
| 4129 | #define RIL_REQUEST_CDMA_QUERY_PREFERRED_VOICE_PRIVACY_MODE 83 |
| 4130 | |
| 4131 | /** |
| 4132 | * RIL_REQUEST_CDMA_FLASH |
| 4133 | * |
| 4134 | * Send FLASH |
| 4135 | * |
| 4136 | * "data" is const char * |
| 4137 | * ((const char *)data)[0] is a FLASH string |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4138 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4139 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4140 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4141 | * Valid errors: |
| 4142 | * SUCCESS |
| 4143 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4144 | * INVALID_ARGUMENTS |
| 4145 | * NO_MEMORY |
| 4146 | * SYSTEM_ERR |
| 4147 | * MODEM_ERR |
| 4148 | * INTERNAL_ERR |
| 4149 | * INVALID_CALL_ID |
| 4150 | * INVALID_STATE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4151 | * |
| 4152 | */ |
| 4153 | #define RIL_REQUEST_CDMA_FLASH 84 |
| 4154 | |
| 4155 | /** |
| 4156 | * RIL_REQUEST_CDMA_BURST_DTMF |
| 4157 | * |
| 4158 | * Send DTMF string |
| 4159 | * |
jsh | 602f80f | 2009-07-10 15:44:37 -0700 | [diff] [blame] | 4160 | * "data" is const char ** |
| 4161 | * ((const char **)data)[0] is a DTMF string |
| 4162 | * ((const char **)data)[1] is the DTMF ON length in milliseconds, or 0 to use |
| 4163 | * default |
| 4164 | * ((const char **)data)[2] is the DTMF OFF length in milliseconds, or 0 to use |
| 4165 | * default |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4166 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4167 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4168 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4169 | * Valid errors: |
| 4170 | * SUCCESS |
| 4171 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 1034589 | 2016-03-19 09:02:28 -0700 | [diff] [blame] | 4172 | * INVALID_ARGUMENTS |
| 4173 | * NO_MEMORY |
| 4174 | * SYSTEM_ERR |
| 4175 | * MODEM_ERR |
| 4176 | * INTERNAL_ERR |
| 4177 | * INVALID_CALL_ID |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4178 | * |
| 4179 | */ |
| 4180 | #define RIL_REQUEST_CDMA_BURST_DTMF 85 |
| 4181 | |
| 4182 | /** |
Naveen Kalla | 03c1edf | 2009-09-23 11:18:35 -0700 | [diff] [blame] | 4183 | * RIL_REQUEST_CDMA_VALIDATE_AND_WRITE_AKEY |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4184 | * |
Naveen Kalla | 03c1edf | 2009-09-23 11:18:35 -0700 | [diff] [blame] | 4185 | * Takes a 26 digit string (20 digit AKEY + 6 digit checksum). |
| 4186 | * If the checksum is valid the 20 digit AKEY is written to NV, |
| 4187 | * replacing the existing AKEY no matter what it was before. |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4188 | * |
| 4189 | * "data" is const char * |
Naveen Kalla | 03c1edf | 2009-09-23 11:18:35 -0700 | [diff] [blame] | 4190 | * ((const char *)data)[0] is a 26 digit string (ASCII digits '0'-'9') |
| 4191 | * where the last 6 digits are a checksum of the |
| 4192 | * first 20, as specified in TR45.AHAG |
| 4193 | * "Common Cryptographic Algorithms, Revision D.1 |
| 4194 | * Section 2.2" |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4195 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4196 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4197 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4198 | * Valid errors: |
| 4199 | * SUCCESS |
| 4200 | * RADIO_NOT_AVAILABLE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4201 | * |
| 4202 | */ |
Naveen Kalla | 03c1edf | 2009-09-23 11:18:35 -0700 | [diff] [blame] | 4203 | #define RIL_REQUEST_CDMA_VALIDATE_AND_WRITE_AKEY 86 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4204 | |
| 4205 | /** |
| 4206 | * RIL_REQUEST_CDMA_SEND_SMS |
| 4207 | * |
| 4208 | * Send a CDMA SMS message |
| 4209 | * |
| 4210 | * "data" is const RIL_CDMA_SMS_Message * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4211 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4212 | * "response" is a const RIL_SMS_Response * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4213 | * |
johnwang | bfb151b | 2009-09-11 15:20:38 -0700 | [diff] [blame] | 4214 | * Based on the return error, caller decides to resend if sending sms |
| 4215 | * fails. The CDMA error class is derived as follows, |
| 4216 | * SUCCESS is error class 0 (no error) |
| 4217 | * SMS_SEND_FAIL_RETRY is error class 2 (temporary failure) |
| 4218 | * and GENERIC_FAILURE is error class 3 (permanent and no retry) |
| 4219 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4220 | * Valid errors: |
| 4221 | * SUCCESS |
| 4222 | * RADIO_NOT_AVAILABLE |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4223 | * SMS_SEND_FAIL_RETRY |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 4224 | * NETWORK_REJECT |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4225 | * INVALID_STATE |
| 4226 | * INVALID_ARGUMENTS |
| 4227 | * NO_MEMORY |
| 4228 | * REQUEST_RATE_LIMITED |
| 4229 | * INVALID_SMS_FORMAT |
| 4230 | * SYSTEM_ERR |
| 4231 | * FDN_CHECK_FAILURE |
| 4232 | * MODEM_ERR |
| 4233 | * NETWORK_ERR |
| 4234 | * ENCODING_ERR |
| 4235 | * INVALID_SMSC_ADDRESS |
| 4236 | * MODE_NOT_SUPPORTED |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4237 | * |
| 4238 | */ |
| 4239 | #define RIL_REQUEST_CDMA_SEND_SMS 87 |
| 4240 | |
| 4241 | /** |
| 4242 | * RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE |
| 4243 | * |
| 4244 | * Acknowledge the success or failure in the receipt of SMS |
| 4245 | * previously indicated via RIL_UNSOL_RESPONSE_CDMA_NEW_SMS |
| 4246 | * |
| 4247 | * "data" is const RIL_CDMA_SMS_Ack * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4248 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4249 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4250 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4251 | * Valid errors: |
| 4252 | * SUCCESS |
| 4253 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4254 | * INVALID_ARGUMENTS |
| 4255 | * NO_SMS_TO_ACK |
| 4256 | * INVALID_STATE |
| 4257 | * NO_MEMORY |
| 4258 | * REQUEST_RATE_LIMITED |
| 4259 | * SYSTEM_ERR |
| 4260 | * MODEM_ERR |
| 4261 | * INVALID_STATE |
| 4262 | * MODE_NOT_SUPPORTED |
| 4263 | * NETWORK_NOT_READY |
| 4264 | * INVALID_MODEM_STATE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4265 | * |
| 4266 | */ |
| 4267 | #define RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE 88 |
| 4268 | |
| 4269 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4270 | * RIL_REQUEST_GSM_GET_BROADCAST_SMS_CONFIG |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4271 | * |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4272 | * Request the setting of GSM/WCDMA Cell Broadcast SMS config. |
| 4273 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4274 | * "data" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4275 | * |
| 4276 | * "response" is a const RIL_GSM_BroadcastSmsConfigInfo ** |
| 4277 | * "responselen" is count * sizeof (RIL_GSM_BroadcastSmsConfigInfo *) |
| 4278 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4279 | * Valid errors: |
| 4280 | * SUCCESS |
| 4281 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4282 | * INVALID_STATE |
| 4283 | * NO_MEMORY |
| 4284 | * REQUEST_RATE_LIMITED |
| 4285 | * SYSTEM_ERR |
| 4286 | * NO_RESOURCES |
| 4287 | * MODEM_ERR |
| 4288 | * SYSTEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4289 | * |
| 4290 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4291 | #define RIL_REQUEST_GSM_GET_BROADCAST_SMS_CONFIG 89 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4292 | |
| 4293 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4294 | * RIL_REQUEST_GSM_SET_BROADCAST_SMS_CONFIG |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4295 | * |
| 4296 | * Set GSM/WCDMA Cell Broadcast SMS config |
| 4297 | * |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4298 | * "data" is a const RIL_GSM_BroadcastSmsConfigInfo ** |
| 4299 | * "datalen" is count * sizeof(RIL_GSM_BroadcastSmsConfigInfo *) |
| 4300 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4301 | * "response" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4302 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4303 | * Valid errors: |
| 4304 | * SUCCESS |
| 4305 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4306 | * INVALID_STATE |
| 4307 | * INVALID_ARGUMENTS |
| 4308 | * NO_MEMORY |
| 4309 | * SYSTEM_ERR |
| 4310 | * REQUEST_RATE_LIMITED |
| 4311 | * MODEM_ERR |
| 4312 | * SYSTEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4313 | * |
| 4314 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4315 | #define RIL_REQUEST_GSM_SET_BROADCAST_SMS_CONFIG 90 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4316 | |
| 4317 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4318 | * RIL_REQUEST_GSM_SMS_BROADCAST_ACTIVATION |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4319 | * |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4320 | * Enable or disable the reception of GSM/WCDMA Cell Broadcast SMS |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4321 | * |
| 4322 | * "data" is const int * |
| 4323 | * (const int *)data[0] indicates to activate or turn off the |
| 4324 | * reception of GSM/WCDMA Cell Broadcast SMS, 0-1, |
| 4325 | * 0 - Activate, 1 - Turn off |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4326 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4327 | * "response" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4328 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4329 | * Valid errors: |
| 4330 | * SUCCESS |
| 4331 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4332 | * INVALID_STATE |
| 4333 | * INVALID_ARGUMENTS |
| 4334 | * NO_MEMORY |
| 4335 | * SYSTEM_ERR |
| 4336 | * REQUEST_RATE_LIMITED |
| 4337 | * MODEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4338 | * |
| 4339 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4340 | #define RIL_REQUEST_GSM_SMS_BROADCAST_ACTIVATION 91 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4341 | |
| 4342 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4343 | * RIL_REQUEST_CDMA_GET_BROADCAST_SMS_CONFIG |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4344 | * |
| 4345 | * Request the setting of CDMA Broadcast SMS config |
| 4346 | * |
| 4347 | * "data" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4348 | * |
| 4349 | * "response" is a const RIL_CDMA_BroadcastSmsConfigInfo ** |
| 4350 | * "responselen" is count * sizeof (RIL_CDMA_BroadcastSmsConfigInfo *) |
| 4351 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4352 | * Valid errors: |
| 4353 | * SUCCESS |
| 4354 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4355 | * INVALID_STATE |
| 4356 | * NO_MEMORY |
| 4357 | * REQUEST_RATE_LIMITED |
| 4358 | * SYSTEM_ERR |
| 4359 | * NO_RESOURCES |
| 4360 | * MODEM_ERR |
| 4361 | * SYSTEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4362 | * |
| 4363 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4364 | #define RIL_REQUEST_CDMA_GET_BROADCAST_SMS_CONFIG 92 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4365 | |
| 4366 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4367 | * RIL_REQUEST_CDMA_SET_BROADCAST_SMS_CONFIG |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4368 | * |
| 4369 | * Set CDMA Broadcast SMS config |
| 4370 | * |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 4371 | * "data" is a const RIL_CDMA_BroadcastSmsConfigInfo ** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4372 | * "datalen" is count * sizeof(const RIL_CDMA_BroadcastSmsConfigInfo *) |
| 4373 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4374 | * "response" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4375 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4376 | * Valid errors: |
| 4377 | * SUCCESS |
| 4378 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4379 | * INVALID_STATE |
| 4380 | * INVALID_ARGUMENTS |
| 4381 | * NO_MEMORY |
| 4382 | * SYSTEM_ERR |
| 4383 | * REQUEST_RATE_LIMITED |
| 4384 | * MODEM_ERR |
| 4385 | * SYSTEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4386 | * |
| 4387 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4388 | #define RIL_REQUEST_CDMA_SET_BROADCAST_SMS_CONFIG 93 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4389 | |
| 4390 | /** |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4391 | * RIL_REQUEST_CDMA_SMS_BROADCAST_ACTIVATION |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4392 | * |
| 4393 | * Enable or disable the reception of CDMA Broadcast SMS |
| 4394 | * |
| 4395 | * "data" is const int * |
| 4396 | * (const int *)data[0] indicates to activate or turn off the |
| 4397 | * reception of CDMA Broadcast SMS, 0-1, |
| 4398 | * 0 - Activate, 1 - Turn off |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4399 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4400 | * "response" is NULL |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4401 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4402 | * Valid errors: |
| 4403 | * SUCCESS |
| 4404 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4405 | * INVALID_STATE |
| 4406 | * INVALID_ARGUMENTS |
| 4407 | * NO_MEMORY |
| 4408 | * SYSTEM_ERR |
| 4409 | * REQUEST_RATE_LIMITED |
| 4410 | * MODEM_ERR |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4411 | * |
| 4412 | */ |
Wink Saville | a592eeb | 2009-05-22 13:26:36 -0700 | [diff] [blame] | 4413 | #define RIL_REQUEST_CDMA_SMS_BROADCAST_ACTIVATION 94 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4414 | |
| 4415 | /** |
| 4416 | * RIL_REQUEST_CDMA_SUBSCRIPTION |
| 4417 | * |
| 4418 | * Request the device MDN / H_SID / H_NID. |
| 4419 | * |
| 4420 | * The request is only allowed when CDMA subscription is available. When CDMA |
| 4421 | * subscription is changed, application layer should re-issue the request to |
| 4422 | * update the subscription information. |
| 4423 | * |
| 4424 | * If a NULL value is returned for any of the device id, it means that error |
| 4425 | * accessing the device. |
| 4426 | * |
| 4427 | * "response" is const char ** |
| 4428 | * ((const char **)response)[0] is MDN if CDMA subscription is available |
jsh | 29be25c | 2009-07-14 20:18:59 -0700 | [diff] [blame] | 4429 | * ((const char **)response)[1] is a comma separated list of H_SID (Home SID) if |
| 4430 | * CDMA subscription is available, in decimal format |
| 4431 | * ((const char **)response)[2] is a comma separated list of H_NID (Home NID) if |
| 4432 | * CDMA subscription is available, in decimal format |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4433 | * ((const char **)response)[3] is MIN (10 digits, MIN2+MIN1) if CDMA subscription is available |
Wink Saville | d4ee7dc | 2009-06-05 15:11:30 -0700 | [diff] [blame] | 4434 | * ((const char **)response)[4] is PRL version if CDMA subscription is available |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4435 | * |
| 4436 | * Valid errors: |
| 4437 | * SUCCESS |
| 4438 | * RIL_E_SUBSCRIPTION_NOT_AVAILABLE |
| 4439 | */ |
| 4440 | |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4441 | #define RIL_REQUEST_CDMA_SUBSCRIPTION 95 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4442 | |
| 4443 | /** |
| 4444 | * RIL_REQUEST_CDMA_WRITE_SMS_TO_RUIM |
| 4445 | * |
| 4446 | * Stores a CDMA SMS message to RUIM memory. |
| 4447 | * |
| 4448 | * "data" is RIL_CDMA_SMS_WriteArgs * |
| 4449 | * |
| 4450 | * "response" is int * |
| 4451 | * ((const int *)response)[0] is the record index where the message is stored. |
| 4452 | * |
| 4453 | * Valid errors: |
| 4454 | * SUCCESS |
| 4455 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 4456 | * SIM_FULL |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4457 | * INVALID_ARGUMENTS |
| 4458 | * INVALID_SMS_FORMAT |
| 4459 | * INTERNAL_ERR |
| 4460 | * MODEM_ERR |
| 4461 | * ENCODING_ERR |
| 4462 | * NO_MEMORY |
| 4463 | * NO_RESOURCES |
| 4464 | * INVALID_MODEM_STATE |
| 4465 | * MODE_NOT_SUPPORTED |
| 4466 | * INVALID_SMSC_ADDRESS |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4467 | * |
| 4468 | */ |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4469 | #define RIL_REQUEST_CDMA_WRITE_SMS_TO_RUIM 96 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4470 | |
| 4471 | /** |
| 4472 | * RIL_REQUEST_CDMA_DELETE_SMS_ON_RUIM |
| 4473 | * |
| 4474 | * Deletes a CDMA SMS message from RUIM memory. |
| 4475 | * |
| 4476 | * "data" is int * |
| 4477 | * ((int *)data)[0] is the record index of the message to delete. |
| 4478 | * |
| 4479 | * "response" is NULL |
| 4480 | * |
| 4481 | * Valid errors: |
| 4482 | * SUCCESS |
| 4483 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4484 | * INVALID_ARGUMENTS |
| 4485 | * NO_MEMORY |
| 4486 | * REQUEST_RATE_LIMITED |
| 4487 | * SYSTEM_ERR |
| 4488 | * MODEM_ERR |
| 4489 | * NO_SUCH_ENTRY |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4490 | * |
| 4491 | */ |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4492 | #define RIL_REQUEST_CDMA_DELETE_SMS_ON_RUIM 97 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4493 | |
| 4494 | /** |
| 4495 | * RIL_REQUEST_DEVICE_IDENTITY |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4496 | * |
| 4497 | * Request the device ESN / MEID / IMEI / IMEISV. |
| 4498 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4499 | * The request is always allowed and contains GSM and CDMA device identity; |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4500 | * it substitutes the deprecated requests RIL_REQUEST_GET_IMEI and |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4501 | * RIL_REQUEST_GET_IMEISV. |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4502 | * |
| 4503 | * If a NULL value is returned for any of the device id, it means that error |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4504 | * accessing the device. |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4505 | * |
| 4506 | * When CDMA subscription is changed the ESN/MEID may change. The application |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4507 | * layer should re-issue the request to update the device identity in this case. |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4508 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4509 | * "response" is const char ** |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4510 | * ((const char **)response)[0] is IMEI if GSM subscription is available |
| 4511 | * ((const char **)response)[1] is IMEISV if GSM subscription is available |
| 4512 | * ((const char **)response)[2] is ESN if CDMA subscription is available |
| 4513 | * ((const char **)response)[3] is MEID if CDMA subscription is available |
| 4514 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4515 | * Valid errors: |
| 4516 | * SUCCESS |
| 4517 | * RADIO_NOT_AVAILABLE |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4518 | */ |
Wink Saville | eafe79d | 2009-04-03 18:02:34 -0700 | [diff] [blame] | 4519 | #define RIL_REQUEST_DEVICE_IDENTITY 98 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4520 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4521 | /** |
| 4522 | * RIL_REQUEST_EXIT_EMERGENCY_CALLBACK_MODE |
| 4523 | * |
| 4524 | * Request the radio's system selection module to exit emergency |
| 4525 | * callback mode. RIL will not respond with SUCCESS until the modem has |
| 4526 | * completely exited from Emergency Callback Mode. |
| 4527 | * |
| 4528 | * "data" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4529 | * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4530 | * "response" is NULL |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 4531 | * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4532 | * Valid errors: |
| 4533 | * SUCCESS |
| 4534 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 4535 | * OPERATION_NOT_ALLOWED |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 4536 | * |
| 4537 | */ |
| 4538 | #define RIL_REQUEST_EXIT_EMERGENCY_CALLBACK_MODE 99 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 4539 | |
jsh | 000a9fe | 2009-05-11 14:52:35 -0700 | [diff] [blame] | 4540 | /** |
| 4541 | * RIL_REQUEST_GET_SMSC_ADDRESS |
| 4542 | * |
| 4543 | * Queries the default Short Message Service Center address on the device. |
| 4544 | * |
| 4545 | * "data" is NULL |
| 4546 | * |
| 4547 | * "response" is const char * containing the SMSC address. |
| 4548 | * |
| 4549 | * Valid errors: |
| 4550 | * SUCCESS |
| 4551 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4552 | * NO_MEMORY |
| 4553 | * REQUEST_RATE_LIMITED |
| 4554 | * SYSTEM_ERR |
| 4555 | * INTERNAL_ERR |
| 4556 | * MODEM_ERR |
| 4557 | * INVALID_ARGUMENTS |
| 4558 | * INVALID_MODEM_STATE |
| 4559 | * NOT_PROVISIONED |
jsh | 000a9fe | 2009-05-11 14:52:35 -0700 | [diff] [blame] | 4560 | * |
| 4561 | */ |
| 4562 | #define RIL_REQUEST_GET_SMSC_ADDRESS 100 |
| 4563 | |
| 4564 | /** |
| 4565 | * RIL_REQUEST_SET_SMSC_ADDRESS |
| 4566 | * |
| 4567 | * Sets the default Short Message Service Center address on the device. |
| 4568 | * |
| 4569 | * "data" is const char * containing the SMSC address. |
| 4570 | * |
| 4571 | * "response" is NULL |
| 4572 | * |
| 4573 | * Valid errors: |
| 4574 | * SUCCESS |
| 4575 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4576 | * INVALID_ARGUMENTS |
| 4577 | * INVALID_SMS_FORMAT |
| 4578 | * NO_MEMORY |
| 4579 | * SYSTEM_ERR |
| 4580 | * REQUEST_RATE_LIMITED |
| 4581 | * MODEM_ERR |
| 4582 | * NO_RESOURCES |
jsh | 000a9fe | 2009-05-11 14:52:35 -0700 | [diff] [blame] | 4583 | * |
| 4584 | */ |
| 4585 | #define RIL_REQUEST_SET_SMSC_ADDRESS 101 |
| 4586 | |
jsh | b60444e | 2009-05-29 11:09:17 -0700 | [diff] [blame] | 4587 | /** |
| 4588 | * RIL_REQUEST_REPORT_SMS_MEMORY_STATUS |
| 4589 | * |
| 4590 | * Indicates whether there is storage available for new SMS messages. |
| 4591 | * |
| 4592 | * "data" is int * |
| 4593 | * ((int *)data)[0] is 1 if memory is available for storing new messages |
| 4594 | * is 0 if memory capacity is exceeded |
| 4595 | * |
| 4596 | * "response" is NULL |
| 4597 | * |
| 4598 | * Valid errors: |
| 4599 | * SUCCESS |
| 4600 | * RADIO_NOT_AVAILABLE |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4601 | * INVALID_ARGUMENTS |
| 4602 | * NO_MEMORY |
| 4603 | * INVALID_STATE |
| 4604 | * SYSTEM_ERR |
| 4605 | * REQUEST_RATE_LIMITED |
| 4606 | * MODEM_ERR |
jsh | b60444e | 2009-05-29 11:09:17 -0700 | [diff] [blame] | 4607 | * |
| 4608 | */ |
| 4609 | #define RIL_REQUEST_REPORT_SMS_MEMORY_STATUS 102 |
| 4610 | |
Wink Saville | 2641d5b | 2009-06-08 17:40:42 -0700 | [diff] [blame] | 4611 | /** |
| 4612 | * RIL_REQUEST_REPORT_STK_SERVICE_IS_RUNNING |
| 4613 | * |
| 4614 | * Indicates that the StkSerivce is running and is |
| 4615 | * ready to receive RIL_UNSOL_STK_XXXXX commands. |
| 4616 | * |
| 4617 | * "data" is NULL |
| 4618 | * "response" is NULL |
| 4619 | * |
| 4620 | * Valid errors: |
| 4621 | * SUCCESS |
| 4622 | * RADIO_NOT_AVAILABLE |
Wink Saville | 2641d5b | 2009-06-08 17:40:42 -0700 | [diff] [blame] | 4623 | * |
| 4624 | */ |
| 4625 | #define RIL_REQUEST_REPORT_STK_SERVICE_IS_RUNNING 103 |
| 4626 | |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 4627 | /** |
| 4628 | * RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE |
| 4629 | * |
| 4630 | * Request to query the location where the CDMA subscription shall |
| 4631 | * be retrieved |
| 4632 | * |
| 4633 | * "data" is NULL |
| 4634 | * |
| 4635 | * "response" is int * |
| 4636 | * ((int *)data)[0] is == RIL_CdmaSubscriptionSource |
| 4637 | * |
| 4638 | * Valid errors: |
| 4639 | * SUCCESS |
| 4640 | * RADIO_NOT_AVAILABLE |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 4641 | * SUBSCRIPTION_NOT_AVAILABLE |
| 4642 | * |
| 4643 | * See also: RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE |
| 4644 | */ |
| 4645 | #define RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE 104 |
| 4646 | |
Jake Hamby | fa8d584 | 2011-08-19 16:22:18 -0700 | [diff] [blame] | 4647 | /** |
| 4648 | * RIL_REQUEST_ISIM_AUTHENTICATION |
| 4649 | * |
| 4650 | * Request the ISIM application on the UICC to perform AKA |
| 4651 | * challenge/response algorithm for IMS authentication |
| 4652 | * |
| 4653 | * "data" is a const char * containing the challenge string in Base64 format |
| 4654 | * "response" is a const char * containing the response in Base64 format |
| 4655 | * |
| 4656 | * Valid errors: |
| 4657 | * SUCCESS |
| 4658 | * RADIO_NOT_AVAILABLE |
Jake Hamby | fa8d584 | 2011-08-19 16:22:18 -0700 | [diff] [blame] | 4659 | */ |
| 4660 | #define RIL_REQUEST_ISIM_AUTHENTICATION 105 |
| 4661 | |
Jake Hamby | 300105d | 2011-09-26 01:01:44 -0700 | [diff] [blame] | 4662 | /** |
| 4663 | * RIL_REQUEST_ACKNOWLEDGE_INCOMING_GSM_SMS_WITH_PDU |
| 4664 | * |
| 4665 | * Acknowledge successful or failed receipt of SMS previously indicated |
| 4666 | * via RIL_UNSOL_RESPONSE_NEW_SMS, including acknowledgement TPDU to send |
| 4667 | * as the RP-User-Data element of the RP-ACK or RP-ERROR PDU. |
| 4668 | * |
| 4669 | * "data" is const char ** |
| 4670 | * ((const char **)data)[0] is "1" on successful receipt (send RP-ACK) |
| 4671 | * is "0" on failed receipt (send RP-ERROR) |
| 4672 | * ((const char **)data)[1] is the acknowledgement TPDU in hexadecimal format |
| 4673 | * |
| 4674 | * "response" is NULL |
| 4675 | * |
| 4676 | * Valid errors: |
| 4677 | * SUCCESS |
| 4678 | * RADIO_NOT_AVAILABLE |
Jake Hamby | 300105d | 2011-09-26 01:01:44 -0700 | [diff] [blame] | 4679 | */ |
| 4680 | #define RIL_REQUEST_ACKNOWLEDGE_INCOMING_GSM_SMS_WITH_PDU 106 |
| 4681 | |
| 4682 | /** |
| 4683 | * RIL_REQUEST_STK_SEND_ENVELOPE_WITH_STATUS |
| 4684 | * |
| 4685 | * Requests to send a SAT/USAT envelope command to SIM. |
| 4686 | * The SAT/USAT envelope command refers to 3GPP TS 11.14 and 3GPP TS 31.111. |
| 4687 | * |
| 4688 | * This request has one difference from RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND: |
| 4689 | * the SW1 and SW2 status bytes from the UICC response are returned along with |
| 4690 | * the response data, using the same structure as RIL_REQUEST_SIM_IO. |
| 4691 | * |
| 4692 | * The RIL implementation shall perform the normal processing of a '91XX' |
| 4693 | * response in SW1/SW2 to retrieve the pending proactive command and send it |
| 4694 | * as an unsolicited response, as RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND does. |
| 4695 | * |
| 4696 | * "data" is a const char * containing the SAT/USAT command |
| 4697 | * in hexadecimal format starting with command tag |
| 4698 | * |
| 4699 | * "response" is a const RIL_SIM_IO_Response * |
| 4700 | * |
| 4701 | * Valid errors: |
| 4702 | * RIL_E_SUCCESS |
| 4703 | * RIL_E_RADIO_NOT_AVAILABLE (radio resetting) |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 4704 | * SIM_BUSY |
| 4705 | * OPERATION_NOT_ALLOWED |
Jake Hamby | 300105d | 2011-09-26 01:01:44 -0700 | [diff] [blame] | 4706 | * RIL_E_GENERIC_FAILURE |
| 4707 | */ |
| 4708 | #define RIL_REQUEST_STK_SEND_ENVELOPE_WITH_STATUS 107 |
| 4709 | |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 4710 | /** |
| 4711 | * RIL_REQUEST_VOICE_RADIO_TECH |
| 4712 | * |
| 4713 | * Query the radio technology type (3GPP/3GPP2) used for voice. Query is valid only |
| 4714 | * when radio state is RADIO_STATE_ON |
| 4715 | * |
| 4716 | * "data" is NULL |
| 4717 | * "response" is int * |
| 4718 | * ((int *) response)[0] is of type const RIL_RadioTechnology |
| 4719 | * |
| 4720 | * Valid errors: |
| 4721 | * SUCCESS |
| 4722 | * RADIO_NOT_AVAILABLE |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 4723 | */ |
| 4724 | #define RIL_REQUEST_VOICE_RADIO_TECH 108 |
| 4725 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 4726 | /** |
| 4727 | * RIL_REQUEST_GET_CELL_INFO_LIST |
| 4728 | * |
| 4729 | * Request all of the current cell information known to the radio. The radio |
| 4730 | * must a list of all current cells, including the neighboring cells. If for a particular |
| 4731 | * cell information isn't known then the appropriate unknown value will be returned. |
| 4732 | * This does not cause or change the rate of RIL_UNSOL_CELL_INFO_LIST. |
| 4733 | * |
| 4734 | * "data" is NULL |
| 4735 | * |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 4736 | * "response" is an array of RIL_CellInfo_v12. |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 4737 | */ |
| 4738 | #define RIL_REQUEST_GET_CELL_INFO_LIST 109 |
| 4739 | |
| 4740 | /** |
| 4741 | * RIL_REQUEST_SET_UNSOL_CELL_INFO_LIST_RATE |
| 4742 | * |
| 4743 | * Sets the minimum time between when RIL_UNSOL_CELL_INFO_LIST should be invoked. |
Wink Saville | c57b3eb | 2013-04-17 12:51:41 -0700 | [diff] [blame] | 4744 | * A value of 0, means invoke RIL_UNSOL_CELL_INFO_LIST when any of the reported |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 4745 | * information changes. Setting the value to INT_MAX(0x7fffffff) means never issue |
| 4746 | * a RIL_UNSOL_CELL_INFO_LIST. |
| 4747 | * |
| 4748 | * "data" is int * |
| 4749 | * ((int *)data)[0] is minimum time in milliseconds |
| 4750 | * |
| 4751 | * "response" is NULL |
| 4752 | * |
| 4753 | * Valid errors: |
| 4754 | * SUCCESS |
| 4755 | * RADIO_NOT_AVAILABLE |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 4756 | */ |
| 4757 | #define RIL_REQUEST_SET_UNSOL_CELL_INFO_LIST_RATE 110 |
Jake Hamby | 300105d | 2011-09-26 01:01:44 -0700 | [diff] [blame] | 4758 | |
Sungmin Choi | 7569753 | 2013-04-26 15:04:45 -0700 | [diff] [blame] | 4759 | /** |
| 4760 | * RIL_REQUEST_SET_INITIAL_ATTACH_APN |
| 4761 | * |
| 4762 | * Set an apn to initial attach network |
Ankit N | bc37e51 | 2016-12-07 21:05:43 +0530 | [diff] [blame] | 4763 | * |
| 4764 | * "data" is a const char ** |
| 4765 | * ((const char **)data)[0] is the APN to connect if radio technology is LTE |
| 4766 | * ((const char **)data)[1] is the connection type to request must be one of the |
| 4767 | * PDP_type values in TS 27.007 section 10.1.1. |
| 4768 | * For example, "IP", "IPV6", "IPV4V6", or "PPP". |
| 4769 | * ((const char **)data)[2] is the PAP / CHAP auth type. Values: |
| 4770 | * 0 => PAP and CHAP is never performed. |
| 4771 | * 1 => PAP may be performed; CHAP is never performed. |
| 4772 | * 2 => CHAP may be performed; PAP is never performed. |
| 4773 | * 3 => PAP / CHAP may be performed - baseband dependent. |
| 4774 | * ((const char **)data)[3] is the username for APN, or NULL |
| 4775 | * ((const char **)data)[4] is the password for APN, or NULL |
| 4776 | * |
Sungmin Choi | 7569753 | 2013-04-26 15:04:45 -0700 | [diff] [blame] | 4777 | * "response" is NULL |
| 4778 | * |
| 4779 | * Valid errors: |
| 4780 | * SUCCESS |
| 4781 | * RADIO_NOT_AVAILABLE (radio resetting) |
Sungmin Choi | 7569753 | 2013-04-26 15:04:45 -0700 | [diff] [blame] | 4782 | * SUBSCRIPTION_NOT_AVAILABLE |
| 4783 | */ |
| 4784 | #define RIL_REQUEST_SET_INITIAL_ATTACH_APN 111 |
| 4785 | |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4786 | /** |
| 4787 | * RIL_REQUEST_IMS_REGISTRATION_STATE |
| 4788 | * |
Nathan Harold | 0eb43c2 | 2016-12-19 12:04:32 -0800 | [diff] [blame] | 4789 | * This message is DEPRECATED and shall be removed in a future release (target: 2018); |
| 4790 | * instead, provide IMS registration status via an IMS Service. |
| 4791 | * |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4792 | * Request current IMS registration state |
| 4793 | * |
| 4794 | * "data" is NULL |
| 4795 | * |
| 4796 | * "response" is int * |
| 4797 | * ((int *)response)[0] is registration state: |
| 4798 | * 0 - Not registered |
| 4799 | * 1 - Registered |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4800 | * |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 4801 | * If ((int*)response)[0] is = 1, then ((int *) response)[1] |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4802 | * must follow with IMS SMS format: |
| 4803 | * |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 4804 | * ((int *) response)[1] is of type RIL_RadioTechnologyFamily |
| 4805 | * |
| 4806 | * Valid errors: |
| 4807 | * SUCCESS |
| 4808 | * RADIO_NOT_AVAILABLE |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4809 | */ |
| 4810 | #define RIL_REQUEST_IMS_REGISTRATION_STATE 112 |
| 4811 | |
| 4812 | /** |
| 4813 | * RIL_REQUEST_IMS_SEND_SMS |
| 4814 | * |
| 4815 | * Send a SMS message over IMS |
| 4816 | * |
| 4817 | * "data" is const RIL_IMS_SMS_Message * |
| 4818 | * |
| 4819 | * "response" is a const RIL_SMS_Response * |
| 4820 | * |
| 4821 | * Based on the return error, caller decides to resend if sending sms |
| 4822 | * fails. SMS_SEND_FAIL_RETRY means retry, and other errors means no retry. |
| 4823 | * In case of retry, data is encoded based on Voice Technology available. |
| 4824 | * |
| 4825 | * Valid errors: |
| 4826 | * SUCCESS |
| 4827 | * RADIO_NOT_AVAILABLE |
| 4828 | * SMS_SEND_FAIL_RETRY |
| 4829 | * FDN_CHECK_FAILURE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 4830 | * NETWORK_REJECT |
Ajay Nambi | 68900f5 | 2016-03-11 12:02:55 -0800 | [diff] [blame] | 4831 | * INVALID_ARGUMENTS |
| 4832 | * INVALID_STATE |
| 4833 | * NO_MEMORY |
| 4834 | * INVALID_SMS_FORMAT |
| 4835 | * SYSTEM_ERR |
| 4836 | * REQUEST_RATE_LIMITED |
| 4837 | * MODEM_ERR |
| 4838 | * NETWORK_ERR |
| 4839 | * ENCODING_ERR |
| 4840 | * INVALID_SMSC_ADDRESS |
| 4841 | * MODE_NOT_SUPPORTED |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 4842 | * |
| 4843 | */ |
| 4844 | #define RIL_REQUEST_IMS_SEND_SMS 113 |
| 4845 | |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4846 | /** |
| 4847 | * RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC |
| 4848 | * |
| 4849 | * Request APDU exchange on the basic channel. This command reflects TS 27.007 |
| 4850 | * "generic SIM access" operation (+CSIM). The modem must ensure proper function |
| 4851 | * of GSM/CDMA, and filter commands appropriately. It should filter |
| 4852 | * channel management and SELECT by DF name commands. |
| 4853 | * |
| 4854 | * "data" is a const RIL_SIM_APDU * |
| 4855 | * "sessionid" field should be ignored. |
| 4856 | * |
| 4857 | * "response" is a const RIL_SIM_IO_Response * |
| 4858 | * |
| 4859 | * Valid errors: |
| 4860 | * SUCCESS |
| 4861 | * RADIO_NOT_AVAILABLE |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4862 | */ |
| 4863 | #define RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC 114 |
| 4864 | |
| 4865 | /** |
| 4866 | * RIL_REQUEST_SIM_OPEN_CHANNEL |
| 4867 | * |
| 4868 | * Open a new logical channel and select the given application. This command |
Wileen Chiu | 410b756 | 2015-11-23 14:25:22 -0800 | [diff] [blame] | 4869 | * reflects TS 27.007 "open logical channel" operation (+CCHO). This request |
| 4870 | * also specifies the P2 parameter (described in ISO 7816-4). |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4871 | * |
Wileen Chiu | 410b756 | 2015-11-23 14:25:22 -0800 | [diff] [blame] | 4872 | * "data" is a const RIL_OpenChannelParam * |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4873 | * |
| 4874 | * "response" is int * |
| 4875 | * ((int *)data)[0] contains the session id of the logical channel. |
Shishir Agrawal | 760123f | 2014-10-14 09:14:57 -0700 | [diff] [blame] | 4876 | * ((int *)data)[1] onwards may optionally contain the select response for the |
| 4877 | * open channel command with one byte per integer. |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4878 | * |
| 4879 | * Valid errors: |
| 4880 | * SUCCESS |
| 4881 | * RADIO_NOT_AVAILABLE |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4882 | * MISSING_RESOURCE |
| 4883 | * NO_SUCH_ELEMENT |
| 4884 | */ |
| 4885 | #define RIL_REQUEST_SIM_OPEN_CHANNEL 115 |
| 4886 | |
| 4887 | /** |
| 4888 | * RIL_REQUEST_SIM_CLOSE_CHANNEL |
| 4889 | * |
| 4890 | * Close a previously opened logical channel. This command reflects TS 27.007 |
| 4891 | * "close logical channel" operation (+CCHC). |
| 4892 | * |
| 4893 | * "data" is int * |
| 4894 | * ((int *)data)[0] is the session id of logical the channel to close. |
| 4895 | * |
| 4896 | * "response" is NULL |
| 4897 | * |
| 4898 | * Valid errors: |
| 4899 | * SUCCESS |
| 4900 | * RADIO_NOT_AVAILABLE |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4901 | */ |
| 4902 | #define RIL_REQUEST_SIM_CLOSE_CHANNEL 116 |
| 4903 | |
| 4904 | /** |
| 4905 | * RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL |
| 4906 | * |
| 4907 | * Exchange APDUs with a UICC over a previously opened logical channel. This |
| 4908 | * command reflects TS 27.007 "generic logical channel access" operation |
| 4909 | * (+CGLA). The modem should filter channel management and SELECT by DF name |
| 4910 | * commands. |
| 4911 | * |
| 4912 | * "data" is a const RIL_SIM_APDU* |
| 4913 | * |
| 4914 | * "response" is a const RIL_SIM_IO_Response * |
| 4915 | * |
| 4916 | * Valid errors: |
| 4917 | * SUCCESS |
| 4918 | * RADIO_NOT_AVAILABLE |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 4919 | */ |
| 4920 | #define RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL 117 |
| 4921 | |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4922 | /** |
| 4923 | * RIL_REQUEST_NV_READ_ITEM |
| 4924 | * |
| 4925 | * Read one of the radio NV items defined in RadioNVItems.java / ril_nv_items.h. |
| 4926 | * This is used for device configuration by some CDMA operators. |
| 4927 | * |
| 4928 | * "data" is a const RIL_NV_ReadItem * |
| 4929 | * |
| 4930 | * "response" is const char * containing the contents of the NV item |
| 4931 | * |
| 4932 | * Valid errors: |
| 4933 | * SUCCESS |
| 4934 | * RADIO_NOT_AVAILABLE |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4935 | */ |
| 4936 | #define RIL_REQUEST_NV_READ_ITEM 118 |
| 4937 | |
| 4938 | /** |
| 4939 | * RIL_REQUEST_NV_WRITE_ITEM |
| 4940 | * |
| 4941 | * Write one of the radio NV items defined in RadioNVItems.java / ril_nv_items.h. |
| 4942 | * This is used for device configuration by some CDMA operators. |
| 4943 | * |
| 4944 | * "data" is a const RIL_NV_WriteItem * |
| 4945 | * |
| 4946 | * "response" is NULL |
| 4947 | * |
| 4948 | * Valid errors: |
| 4949 | * SUCCESS |
| 4950 | * RADIO_NOT_AVAILABLE |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4951 | */ |
| 4952 | #define RIL_REQUEST_NV_WRITE_ITEM 119 |
| 4953 | |
| 4954 | /** |
| 4955 | * RIL_REQUEST_NV_WRITE_CDMA_PRL |
| 4956 | * |
| 4957 | * Update the CDMA Preferred Roaming List (PRL) in the radio NV storage. |
| 4958 | * This is used for device configuration by some CDMA operators. |
| 4959 | * |
| 4960 | * "data" is a const char * containing the PRL as a byte array |
| 4961 | * |
| 4962 | * "response" is NULL |
| 4963 | * |
| 4964 | * Valid errors: |
| 4965 | * SUCCESS |
| 4966 | * RADIO_NOT_AVAILABLE |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4967 | */ |
| 4968 | #define RIL_REQUEST_NV_WRITE_CDMA_PRL 120 |
| 4969 | |
| 4970 | /** |
| 4971 | * RIL_REQUEST_NV_RESET_CONFIG |
| 4972 | * |
| 4973 | * Reset the radio NV configuration to the factory state. |
| 4974 | * This is used for device configuration by some CDMA operators. |
| 4975 | * |
| 4976 | * "data" is int * |
Jake Hamby | d27c9d5 | 2014-02-06 14:52:05 -0800 | [diff] [blame] | 4977 | * ((int *)data)[0] is 1 to reload all NV items |
| 4978 | * ((int *)data)[0] is 2 for erase NV reset (SCRTN) |
| 4979 | * ((int *)data)[0] is 3 for factory reset (RTN) |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4980 | * |
| 4981 | * "response" is NULL |
| 4982 | * |
| 4983 | * Valid errors: |
| 4984 | * SUCCESS |
| 4985 | * RADIO_NOT_AVAILABLE |
Jake Hamby | 8a4a233 | 2014-01-15 13:12:05 -0800 | [diff] [blame] | 4986 | */ |
| 4987 | #define RIL_REQUEST_NV_RESET_CONFIG 121 |
| 4988 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 4989 | /** RIL_REQUEST_SET_UICC_SUBSCRIPTION |
| 4990 | * FIXME This API needs to have more documentation. |
| 4991 | * |
| 4992 | * Selection/de-selection of a subscription from a SIM card |
| 4993 | * "data" is const RIL_SelectUiccSub* |
| 4994 | |
| 4995 | * |
| 4996 | * "response" is NULL |
| 4997 | * |
| 4998 | * Valid errors: |
| 4999 | * SUCCESS |
| 5000 | * RADIO_NOT_AVAILABLE (radio resetting) |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 5001 | * SUBSCRIPTION_NOT_SUPPORTED |
| 5002 | * |
| 5003 | */ |
| 5004 | #define RIL_REQUEST_SET_UICC_SUBSCRIPTION 122 |
| 5005 | |
| 5006 | /** |
| 5007 | * RIL_REQUEST_ALLOW_DATA |
| 5008 | * |
| 5009 | * Tells the modem whether data calls are allowed or not |
| 5010 | * |
| 5011 | * "data" is int * |
| 5012 | * FIXME slotId and aid will be added. |
| 5013 | * ((int *)data)[0] is == 0 to allow data calls |
| 5014 | * ((int *)data)[0] is == 1 to disallow data calls |
| 5015 | * |
| 5016 | * "response" is NULL |
| 5017 | * |
| 5018 | * Valid errors: |
| 5019 | * |
| 5020 | * SUCCESS |
| 5021 | * RADIO_NOT_AVAILABLE (radio resetting) |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 5022 | * |
| 5023 | */ |
| 5024 | #define RIL_REQUEST_ALLOW_DATA 123 |
| 5025 | |
| 5026 | /** |
| 5027 | * RIL_REQUEST_GET_HARDWARE_CONFIG |
| 5028 | * |
| 5029 | * Request all of the current hardware (modem and sim) associated |
| 5030 | * with the RIL. |
| 5031 | * |
| 5032 | * "data" is NULL |
| 5033 | * |
| 5034 | * "response" is an array of RIL_HardwareConfig. |
| 5035 | */ |
| 5036 | #define RIL_REQUEST_GET_HARDWARE_CONFIG 124 |
| 5037 | |
| 5038 | /** |
Amit Mahajan | 2b77203 | 2014-06-26 14:20:11 -0700 | [diff] [blame] | 5039 | * RIL_REQUEST_SIM_AUTHENTICATION |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 5040 | * |
| 5041 | * Returns the response of SIM Authentication through RIL to a |
| 5042 | * challenge request. |
| 5043 | * |
| 5044 | * "data" Base64 encoded string containing challenge: |
| 5045 | * int authContext; P2 value of authentication command, see P2 parameter in |
| 5046 | * 3GPP TS 31.102 7.1.2 |
| 5047 | * char *authData; the challenge string in Base64 format, see 3GPP |
| 5048 | * TS 31.102 7.1.2 |
| 5049 | * char *aid; AID value, See ETSI 102.221 8.1 and 101.220 4, |
| 5050 | * NULL if no value |
| 5051 | * |
| 5052 | * "response" Base64 encoded strings containing response: |
| 5053 | * int sw1; Status bytes per 3GPP TS 31.102 section 7.3 |
| 5054 | * int sw2; |
| 5055 | * char *simResponse; Response in Base64 format, see 3GPP TS 31.102 7.1.2 |
| 5056 | */ |
Amit Mahajan | 2b77203 | 2014-06-26 14:20:11 -0700 | [diff] [blame] | 5057 | #define RIL_REQUEST_SIM_AUTHENTICATION 125 |
Shishir Agrawal | 2458d8d | 2013-11-27 14:53:05 -0800 | [diff] [blame] | 5058 | |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5059 | /** |
| 5060 | * RIL_REQUEST_GET_DC_RT_INFO |
| 5061 | * |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5062 | * The request is DEPRECATED, use RIL_REQUEST_GET_ACTIVITY_INFO |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5063 | * Requests the Data Connection Real Time Info |
| 5064 | * |
| 5065 | * "data" is NULL |
| 5066 | * |
| 5067 | * "response" is the most recent RIL_DcRtInfo |
| 5068 | * |
| 5069 | * Valid errors: |
| 5070 | * SUCCESS |
| 5071 | * RADIO_NOT_AVAILABLE |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5072 | * |
| 5073 | * See also: RIL_UNSOL_DC_RT_INFO_CHANGED |
| 5074 | */ |
| 5075 | #define RIL_REQUEST_GET_DC_RT_INFO 126 |
| 5076 | |
| 5077 | /** |
| 5078 | * RIL_REQUEST_SET_DC_RT_INFO_RATE |
| 5079 | * |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5080 | * The request is DEPRECATED |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5081 | * This is the minimum number of milliseconds between successive |
| 5082 | * RIL_UNSOL_DC_RT_INFO_CHANGED messages and defines the highest rate |
| 5083 | * at which RIL_UNSOL_DC_RT_INFO_CHANGED's will be sent. A value of |
| 5084 | * 0 means send as fast as possible. |
| 5085 | * |
| 5086 | * "data" The number of milliseconds as an int |
| 5087 | * |
| 5088 | * "response" is null |
| 5089 | * |
| 5090 | * Valid errors: |
| 5091 | * SUCCESS must not fail |
| 5092 | */ |
| 5093 | #define RIL_REQUEST_SET_DC_RT_INFO_RATE 127 |
| 5094 | |
Amit Mahajan | c796e22 | 2014-08-13 16:54:01 +0000 | [diff] [blame] | 5095 | /** |
| 5096 | * RIL_REQUEST_SET_DATA_PROFILE |
| 5097 | * |
| 5098 | * Set data profile in modem |
Hui Wang | 8d67962 | 2014-10-16 14:59:27 -0500 | [diff] [blame] | 5099 | * Modem should erase existed profiles from framework, and apply new profiles |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 5100 | * "data" is a const RIL_DataProfileInfo ** |
Amit Mahajan | c796e22 | 2014-08-13 16:54:01 +0000 | [diff] [blame] | 5101 | * "datalen" is count * sizeof(const RIL_DataProfileInfo *) |
| 5102 | * "response" is NULL |
| 5103 | * |
| 5104 | * Valid errors: |
| 5105 | * SUCCESS |
| 5106 | * RADIO_NOT_AVAILABLE (radio resetting) |
Amit Mahajan | c796e22 | 2014-08-13 16:54:01 +0000 | [diff] [blame] | 5107 | * SUBSCRIPTION_NOT_AVAILABLE |
| 5108 | */ |
| 5109 | #define RIL_REQUEST_SET_DATA_PROFILE 128 |
Naveen Kalla | a65a16a | 2014-07-31 16:48:31 -0700 | [diff] [blame] | 5110 | |
| 5111 | /** |
| 5112 | * RIL_REQUEST_SHUTDOWN |
| 5113 | * |
| 5114 | * Device is shutting down. All further commands are ignored |
| 5115 | * and RADIO_NOT_AVAILABLE must be returned. |
| 5116 | * |
| 5117 | * "data" is null |
| 5118 | * "response" is NULL |
| 5119 | * |
| 5120 | * Valid errors: |
| 5121 | * SUCCESS |
| 5122 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 5123 | * OPERATION_NOT_ALLOWED |
Naveen Kalla | a65a16a | 2014-07-31 16:48:31 -0700 | [diff] [blame] | 5124 | */ |
| 5125 | #define RIL_REQUEST_SHUTDOWN 129 |
| 5126 | |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 5127 | /** |
| 5128 | * RIL_REQUEST_GET_RADIO_CAPABILITY |
| 5129 | * |
| 5130 | * Used to get phone radio capablility. |
| 5131 | * |
Abhishek Adappa | 772c0d2 | 2015-02-09 11:11:12 -0800 | [diff] [blame] | 5132 | * "data" is the RIL_RadioCapability structure |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 5133 | * |
| 5134 | * Valid errors: |
| 5135 | * SUCCESS |
| 5136 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 5137 | * OPERATION_NOT_ALLOWED |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 5138 | */ |
| 5139 | #define RIL_REQUEST_GET_RADIO_CAPABILITY 130 |
| 5140 | |
| 5141 | /** |
| 5142 | * RIL_REQUEST_SET_RADIO_CAPABILITY |
| 5143 | * |
| 5144 | * Used to set the phones radio capability. Be VERY careful |
| 5145 | * using this request as it may cause some vendor modems to reset. Because |
| 5146 | * of the possible modem reset any RIL commands after this one may not be |
| 5147 | * processed. |
| 5148 | * |
| 5149 | * "data" is the RIL_RadioCapability structure |
| 5150 | * |
| 5151 | * "response" is the RIL_RadioCapability structure, used to feedback return status |
| 5152 | * |
| 5153 | * Valid errors: |
| 5154 | * SUCCESS means a RIL_UNSOL_RADIO_CAPABILITY will be sent within 30 seconds. |
| 5155 | * RADIO_NOT_AVAILABLE |
twen.chang | df7add0 | 2016-03-04 18:27:48 +0800 | [diff] [blame] | 5156 | * OPERATION_NOT_ALLOWED |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 5157 | */ |
| 5158 | #define RIL_REQUEST_SET_RADIO_CAPABILITY 131 |
| 5159 | |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5160 | /** |
| 5161 | * RIL_REQUEST_START_LCE |
| 5162 | * |
| 5163 | * Start Link Capacity Estimate (LCE) service if supported by the radio. |
| 5164 | * |
| 5165 | * "data" is const int * |
| 5166 | * ((const int*)data)[0] specifies the desired reporting interval (ms). |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 5167 | * ((const int*)data)[1] specifies the LCE service mode. 1: PULL; 0: PUSH. |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5168 | * |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 5169 | * "response" is the RIL_LceStatusInfo. |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5170 | * |
| 5171 | * Valid errors: |
| 5172 | * SUCCESS |
| 5173 | * RADIO_NOT_AVAILABLE |
| 5174 | * LCE_NOT_SUPPORTED |
| 5175 | */ |
| 5176 | #define RIL_REQUEST_START_LCE 132 |
| 5177 | |
| 5178 | /** |
| 5179 | * RIL_REQUEST_STOP_LCE |
| 5180 | * |
| 5181 | * Stop Link Capacity Estimate (LCE) service, the STOP operation should be |
| 5182 | * idempotent for the radio modem. |
| 5183 | * |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 5184 | * "response" is the RIL_LceStatusInfo. |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5185 | * |
| 5186 | * Valid errors: |
| 5187 | * SUCCESS |
| 5188 | * RADIO_NOT_AVAILABLE |
| 5189 | * LCE_NOT_SUPPORTED |
| 5190 | */ |
| 5191 | #define RIL_REQUEST_STOP_LCE 133 |
| 5192 | |
| 5193 | /** |
| 5194 | * RIL_REQUEST_PULL_LCEDATA |
| 5195 | * |
| 5196 | * Pull LCE service for capacity information. |
| 5197 | * |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 5198 | * "response" is the RIL_LceDataInfo. |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5199 | * |
| 5200 | * Valid errors: |
| 5201 | * SUCCESS |
| 5202 | * RADIO_NOT_AVAILABLE |
| 5203 | * LCE_NOT_SUPPORTED |
| 5204 | */ |
| 5205 | #define RIL_REQUEST_PULL_LCEDATA 134 |
| 5206 | |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5207 | /** |
| 5208 | * RIL_REQUEST_GET_ACTIVITY_INFO |
| 5209 | * |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 5210 | * Get modem activity information for power consumption estimation. |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5211 | * |
Nathan Harold | c863521 | 2016-10-10 11:15:21 -0700 | [diff] [blame] | 5212 | * Request clear-on-read statistics information that is used for |
| 5213 | * estimating the per-millisecond power consumption of the cellular |
| 5214 | * modem. |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5215 | * |
| 5216 | * "data" is null |
| 5217 | * "response" is const RIL_ActivityStatsInfo * |
| 5218 | * |
| 5219 | * Valid errors: |
| 5220 | * |
| 5221 | * SUCCESS |
| 5222 | * RADIO_NOT_AVAILABLE (radio resetting) |
| 5223 | * GENERIC_FAILURE |
| 5224 | */ |
| 5225 | #define RIL_REQUEST_GET_ACTIVITY_INFO 135 |
Naveen Kalla | a65a16a | 2014-07-31 16:48:31 -0700 | [diff] [blame] | 5226 | |
Meng Wang | b4e3431 | 2016-05-12 14:54:36 -0700 | [diff] [blame] | 5227 | /** |
| 5228 | * RIL_REQUEST_SET_CARRIER_RESTRICTIONS |
| 5229 | * |
Meng Wang | d5c540f | 2016-07-15 15:41:19 -0700 | [diff] [blame] | 5230 | * Set carrier restrictions for this sim slot. Expected modem behavior: |
| 5231 | * If never receives this command |
| 5232 | * - Must allow all carriers |
| 5233 | * Receives this command with data being NULL |
| 5234 | * - Must allow all carriers. If a previously allowed SIM is present, modem must not reload |
| 5235 | * the SIM. If a previously disallowed SIM is present, reload the SIM and notify Android. |
| 5236 | * Receives this command with a list of carriers |
| 5237 | * - Only allow specified carriers, persist across power cycles and FDR. If a present SIM |
| 5238 | * is in the allowed list, modem must not reload the SIM. If a present SIM is *not* in |
| 5239 | * the allowed list, modem must detach from the registered network and only keep emergency |
| 5240 | * service, and notify Android SIM refresh reset with new SIM state being |
| 5241 | * RIL_CARDSTATE_RESTRICTED. Emergency service must be enabled. |
Meng Wang | b4e3431 | 2016-05-12 14:54:36 -0700 | [diff] [blame] | 5242 | * |
| 5243 | * "data" is const RIL_CarrierRestrictions * |
| 5244 | * A list of allowed carriers and possibly a list of excluded carriers. |
| 5245 | * If data is NULL, means to clear previous carrier restrictions and allow all carriers |
| 5246 | * |
| 5247 | * "response" is int * |
| 5248 | * ((int *)data)[0] contains the number of allowed carriers which have been set correctly. |
| 5249 | * On success, it should match the length of list data->allowed_carriers. |
| 5250 | * If data is NULL, the value must be 0. |
| 5251 | * |
| 5252 | * Valid errors: |
| 5253 | * RIL_E_SUCCESS |
| 5254 | * RIL_E_INVALID_ARGUMENTS |
| 5255 | * RIL_E_RADIO_NOT_AVAILABLE |
| 5256 | * RIL_E_REQUEST_NOT_SUPPORTED |
| 5257 | */ |
| 5258 | #define RIL_REQUEST_SET_CARRIER_RESTRICTIONS 136 |
| 5259 | |
| 5260 | /** |
| 5261 | * RIL_REQUEST_GET_CARRIER_RESTRICTIONS |
| 5262 | * |
Meng Wang | d5c540f | 2016-07-15 15:41:19 -0700 | [diff] [blame] | 5263 | * Get carrier restrictions for this sim slot. Expected modem behavior: |
| 5264 | * Return list of allowed carriers, or null if all carriers are allowed. |
Meng Wang | b4e3431 | 2016-05-12 14:54:36 -0700 | [diff] [blame] | 5265 | * |
| 5266 | * "data" is NULL |
| 5267 | * |
| 5268 | * "response" is const RIL_CarrierRestrictions *. |
| 5269 | * If response is NULL, it means all carriers are allowed. |
| 5270 | * |
| 5271 | * Valid errors: |
| 5272 | * RIL_E_SUCCESS |
| 5273 | * RIL_E_RADIO_NOT_AVAILABLE |
| 5274 | * RIL_E_REQUEST_NOT_SUPPORTED |
| 5275 | */ |
| 5276 | #define RIL_REQUEST_GET_CARRIER_RESTRICTIONS 137 |
| 5277 | |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 5278 | /** |
| 5279 | * RIL_REQUEST_SEND_DEVICE_STATE |
| 5280 | * |
| 5281 | * Send the updated device state. |
| 5282 | * Modem can perform power saving based on the provided device state. |
| 5283 | * "data" is const int * |
| 5284 | * ((const int*)data)[0] A RIL_DeviceStateType that specifies the device state type. |
| 5285 | * ((const int*)data)[1] Specifies the state. See RIL_DeviceStateType for the definition of each |
| 5286 | * type. |
| 5287 | * |
| 5288 | * "datalen" is count * sizeof(const RIL_DeviceState *) |
| 5289 | * "response" is NULL |
| 5290 | * |
| 5291 | * Valid errors: |
| 5292 | * SUCCESS |
| 5293 | * RADIO_NOT_AVAILABLE (radio resetting) |
| 5294 | */ |
| 5295 | #define RIL_REQUEST_SEND_DEVICE_STATE 138 |
| 5296 | |
| 5297 | /** |
| 5298 | * RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER |
| 5299 | * |
| 5300 | * Set the unsolicited response filter |
| 5301 | * This is used to prevent unnecessary application processor |
| 5302 | * wake up for power saving purposes by suppressing the |
| 5303 | * unsolicited responses in certain scenarios. |
| 5304 | * |
| 5305 | * "data" is an int * |
| 5306 | * |
| 5307 | * ((int *)data)[0] is a 32-bit bitmask of RIL_UnsolicitedResponseFilter |
| 5308 | * |
| 5309 | * "response" is NULL |
| 5310 | * |
| 5311 | * Valid errors: |
| 5312 | * SUCCESS |
| 5313 | * INVALID_ARGUMENTS (e.g. the requested filter doesn't exist) |
| 5314 | * RADIO_NOT_AVAILABLE (radio resetting) |
| 5315 | */ |
| 5316 | #define RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER 139 |
| 5317 | |
Wileen Chiu | 718c0bf | 2017-01-04 11:37:19 -0800 | [diff] [blame] | 5318 | /** |
| 5319 | * RIL_REQUEST_SET_SIM_CARD_POWER |
| 5320 | * |
| 5321 | * Set SIM card power up or down |
| 5322 | * |
| 5323 | * Request is equivalent to inserting and removing the card, with |
| 5324 | * an additional effect where the ability to detect card removal/insertion |
| 5325 | * is disabled when the SIM card is powered down. |
| 5326 | * |
| 5327 | * This will generate RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED |
| 5328 | * as if the SIM had been inserted or removed. |
| 5329 | * |
| 5330 | * "data" is int * |
| 5331 | * ((int *)data)[0] is 1 for "SIM POWER UP" |
| 5332 | * ((int *)data)[0] is 0 for "SIM POWER DOWN" |
| 5333 | * |
| 5334 | * "response" is NULL |
| 5335 | * |
| 5336 | * Valid errors: |
| 5337 | * SUCCESS |
| 5338 | * RADIO_NOT_AVAILABLE |
| 5339 | * REQUEST_NOT_SUPPORTED |
| 5340 | * SIM_ABSENT |
| 5341 | * INVALID_ARGUMENTS |
| 5342 | */ |
| 5343 | #define RIL_REQUEST_SET_SIM_CARD_POWER 140 |
pkanwar | c61837e | 2017-03-17 12:49:34 -0700 | [diff] [blame] | 5344 | |
| 5345 | /** |
| 5346 | * RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION |
| 5347 | * |
| 5348 | * Provide Carrier specific information to the modem that will be used to |
| 5349 | * encrypt the IMSI and IMPI. Sent by the framework during boot, carrier |
| 5350 | * switch and everytime we receive a new certificate. |
| 5351 | * |
| 5352 | * "data" is the RIL_CarrierInfoForImsiEncryption * structure. |
| 5353 | * |
| 5354 | * "response" is NULL |
| 5355 | * |
| 5356 | * Valid errors: |
| 5357 | * RIL_E_SUCCESS |
| 5358 | * RIL_E_RADIO_NOT_AVAILABLE |
| 5359 | * SIM_ABSENT |
| 5360 | * RIL_E_REQUEST_NOT_SUPPORTED |
| 5361 | * INVALID_ARGUMENTS |
| 5362 | * MODEM_INTERNAL_FAILURE |
| 5363 | */ |
| 5364 | #define RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION 141 |
| 5365 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5366 | /***********************************************************************/ |
| 5367 | |
Sanket Padawe | 6ff9a87 | 2016-01-27 15:09:12 -0800 | [diff] [blame] | 5368 | /** |
| 5369 | * RIL_RESPONSE_ACKNOWLEDGEMENT |
| 5370 | * |
| 5371 | * This is used by Asynchronous solicited messages and Unsolicited messages |
| 5372 | * to acknowledge the receipt of those messages in RIL.java so that the ack |
| 5373 | * can be used to let ril.cpp to release wakelock. |
| 5374 | * |
| 5375 | * Valid errors |
| 5376 | * SUCCESS |
| 5377 | * RADIO_NOT_AVAILABLE |
| 5378 | */ |
| 5379 | |
| 5380 | #define RIL_RESPONSE_ACKNOWLEDGEMENT 800 |
| 5381 | |
| 5382 | /***********************************************************************/ |
| 5383 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5384 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5385 | #define RIL_UNSOL_RESPONSE_BASE 1000 |
| 5386 | |
| 5387 | /** |
| 5388 | * RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED |
| 5389 | * |
| 5390 | * Indicate when value of RIL_RadioState has changed. |
| 5391 | * |
| 5392 | * Callee will invoke RIL_RadioStateRequest method on main thread |
| 5393 | * |
| 5394 | * "data" is NULL |
| 5395 | */ |
| 5396 | |
| 5397 | #define RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED 1000 |
| 5398 | |
| 5399 | |
| 5400 | /** |
| 5401 | * RIL_UNSOL_RESPONSE_CALL_STATE_CHANGED |
| 5402 | * |
| 5403 | * Indicate when call state has changed |
| 5404 | * |
| 5405 | * Callee will invoke RIL_REQUEST_GET_CURRENT_CALLS on main thread |
| 5406 | * |
| 5407 | * "data" is NULL |
| 5408 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5409 | * Response should be invoked on, for example, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5410 | * "RING", "BUSY", "NO CARRIER", and also call state |
| 5411 | * transitions (DIALING->ALERTING ALERTING->ACTIVE) |
| 5412 | * |
| 5413 | * Redundent or extraneous invocations are tolerated |
| 5414 | */ |
| 5415 | #define RIL_UNSOL_RESPONSE_CALL_STATE_CHANGED 1001 |
| 5416 | |
| 5417 | |
| 5418 | /** |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5419 | * RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5420 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5421 | * Called when the voice network state changed |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5422 | * |
| 5423 | * Callee will invoke the following requests on main thread: |
| 5424 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5425 | * RIL_REQUEST_VOICE_REGISTRATION_STATE |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5426 | * RIL_REQUEST_OPERATOR |
| 5427 | * |
| 5428 | * "data" is NULL |
| 5429 | * |
| 5430 | * FIXME should this happen when SIM records are loaded? (eg, for |
| 5431 | * EONS) |
| 5432 | */ |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5433 | #define RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED 1002 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5434 | |
| 5435 | /** |
| 5436 | * RIL_UNSOL_RESPONSE_NEW_SMS |
| 5437 | * |
| 5438 | * Called when new SMS is received. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5439 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5440 | * "data" is const char * |
| 5441 | * This is a pointer to a string containing the PDU of an SMS-DELIVER |
| 5442 | * as an ascii string of hex digits. The PDU starts with the SMSC address |
| 5443 | * per TS 27.005 (+CMT:) |
| 5444 | * |
| 5445 | * Callee will subsequently confirm the receipt of thei SMS with a |
| 5446 | * RIL_REQUEST_SMS_ACKNOWLEDGE |
| 5447 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5448 | * No new RIL_UNSOL_RESPONSE_NEW_SMS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5449 | * or RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT messages should be sent until a |
| 5450 | * RIL_REQUEST_SMS_ACKNOWLEDGE has been received |
| 5451 | */ |
| 5452 | |
| 5453 | #define RIL_UNSOL_RESPONSE_NEW_SMS 1003 |
| 5454 | |
| 5455 | /** |
| 5456 | * RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT |
| 5457 | * |
| 5458 | * Called when new SMS Status Report is received. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5459 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5460 | * "data" is const char * |
| 5461 | * This is a pointer to a string containing the PDU of an SMS-STATUS-REPORT |
| 5462 | * as an ascii string of hex digits. The PDU starts with the SMSC address |
| 5463 | * per TS 27.005 (+CDS:). |
| 5464 | * |
| 5465 | * Callee will subsequently confirm the receipt of the SMS with a |
| 5466 | * RIL_REQUEST_SMS_ACKNOWLEDGE |
| 5467 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5468 | * No new RIL_UNSOL_RESPONSE_NEW_SMS |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5469 | * or RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT messages should be sent until a |
| 5470 | * RIL_REQUEST_SMS_ACKNOWLEDGE has been received |
| 5471 | */ |
| 5472 | |
| 5473 | #define RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT 1004 |
| 5474 | |
| 5475 | /** |
| 5476 | * RIL_UNSOL_RESPONSE_NEW_SMS_ON_SIM |
| 5477 | * |
| 5478 | * Called when new SMS has been stored on SIM card |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5479 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5480 | * "data" is const int * |
| 5481 | * ((const int *)data)[0] contains the slot index on the SIM that contains |
| 5482 | * the new message |
| 5483 | */ |
| 5484 | |
| 5485 | #define RIL_UNSOL_RESPONSE_NEW_SMS_ON_SIM 1005 |
| 5486 | |
| 5487 | /** |
| 5488 | * RIL_UNSOL_ON_USSD |
| 5489 | * |
| 5490 | * Called when a new USSD message is received. |
| 5491 | * |
| 5492 | * "data" is const char ** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5493 | * ((const char **)data)[0] points to a type code, which is |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5494 | * one of these string values: |
| 5495 | * "0" USSD-Notify -- text in ((const char **)data)[1] |
| 5496 | * "1" USSD-Request -- text in ((const char **)data)[1] |
| 5497 | * "2" Session terminated by network |
| 5498 | * "3" other local client (eg, SIM Toolkit) has responded |
| 5499 | * "4" Operation not supported |
| 5500 | * "5" Network timeout |
| 5501 | * |
| 5502 | * The USSD session is assumed to persist if the type code is "1", otherwise |
| 5503 | * the current session (if any) is assumed to have terminated. |
| 5504 | * |
| 5505 | * ((const char **)data)[1] points to a message string if applicable, which |
| 5506 | * should always be in UTF-8. |
| 5507 | */ |
| 5508 | #define RIL_UNSOL_ON_USSD 1006 |
| 5509 | /* Previously #define RIL_UNSOL_ON_USSD_NOTIFY 1006 */ |
| 5510 | |
| 5511 | /** |
| 5512 | * RIL_UNSOL_ON_USSD_REQUEST |
| 5513 | * |
| 5514 | * Obsolete. Send via RIL_UNSOL_ON_USSD |
| 5515 | */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5516 | #define RIL_UNSOL_ON_USSD_REQUEST 1007 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5517 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5518 | /** |
| 5519 | * RIL_UNSOL_NITZ_TIME_RECEIVED |
| 5520 | * |
| 5521 | * Called when radio has received a NITZ time message |
| 5522 | * |
| 5523 | * "data" is const char * pointing to NITZ time string |
| 5524 | * in the form "yy/mm/dd,hh:mm:ss(+/-)tz,dt" |
| 5525 | */ |
| 5526 | #define RIL_UNSOL_NITZ_TIME_RECEIVED 1008 |
| 5527 | |
| 5528 | /** |
| 5529 | * RIL_UNSOL_SIGNAL_STRENGTH |
| 5530 | * |
| 5531 | * Radio may report signal strength rather han have it polled. |
| 5532 | * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 5533 | * "data" is a const RIL_SignalStrength * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5534 | */ |
| 5535 | #define RIL_UNSOL_SIGNAL_STRENGTH 1009 |
| 5536 | |
| 5537 | |
| 5538 | /** |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5539 | * RIL_UNSOL_DATA_CALL_LIST_CHANGED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5540 | * |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5541 | * "data" is an array of RIL_Data_Call_Response_v6 identical to that |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 5542 | * returned by RIL_REQUEST_DATA_CALL_LIST. It is the complete list |
| 5543 | * of current data contexts including new contexts that have been |
| 5544 | * activated. A data call is only removed from this list when the |
| 5545 | * framework sends a RIL_REQUEST_DEACTIVATE_DATA_CALL or the radio |
| 5546 | * is powered off/on. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5547 | * |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5548 | * See also: RIL_REQUEST_DATA_CALL_LIST |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5549 | */ |
| 5550 | |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5551 | #define RIL_UNSOL_DATA_CALL_LIST_CHANGED 1010 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5552 | |
| 5553 | /** |
| 5554 | * RIL_UNSOL_SUPP_SVC_NOTIFICATION |
| 5555 | * |
| 5556 | * Reports supplementary service related notification from the network. |
| 5557 | * |
| 5558 | * "data" is a const RIL_SuppSvcNotification * |
| 5559 | * |
| 5560 | */ |
| 5561 | |
| 5562 | #define RIL_UNSOL_SUPP_SVC_NOTIFICATION 1011 |
| 5563 | |
| 5564 | /** |
| 5565 | * RIL_UNSOL_STK_SESSION_END |
| 5566 | * |
| 5567 | * Indicate when STK session is terminated by SIM. |
| 5568 | * |
| 5569 | * "data" is NULL |
| 5570 | */ |
| 5571 | #define RIL_UNSOL_STK_SESSION_END 1012 |
| 5572 | |
| 5573 | /** |
| 5574 | * RIL_UNSOL_STK_PROACTIVE_COMMAND |
| 5575 | * |
| 5576 | * Indicate when SIM issue a STK proactive command to applications |
| 5577 | * |
| 5578 | * "data" is a const char * containing SAT/USAT proactive command |
| 5579 | * in hexadecimal format string starting with command tag |
| 5580 | * |
| 5581 | */ |
| 5582 | #define RIL_UNSOL_STK_PROACTIVE_COMMAND 1013 |
| 5583 | |
| 5584 | /** |
| 5585 | * RIL_UNSOL_STK_EVENT_NOTIFY |
| 5586 | * |
| 5587 | * Indicate when SIM notifies applcations some event happens. |
| 5588 | * Generally, application does not need to have any feedback to |
| 5589 | * SIM but shall be able to indicate appropriate messages to users. |
| 5590 | * |
| 5591 | * "data" is a const char * containing SAT/USAT commands or responses |
| 5592 | * sent by ME to SIM or commands handled by ME, in hexadecimal format string |
| 5593 | * starting with first byte of response data or command tag |
| 5594 | * |
| 5595 | */ |
| 5596 | #define RIL_UNSOL_STK_EVENT_NOTIFY 1014 |
| 5597 | |
| 5598 | /** |
| 5599 | * RIL_UNSOL_STK_CALL_SETUP |
| 5600 | * |
| 5601 | * Indicate when SIM wants application to setup a voice call. |
| 5602 | * |
| 5603 | * "data" is const int * |
| 5604 | * ((const int *)data)[0] contains timeout value (in milliseconds) |
| 5605 | */ |
| 5606 | #define RIL_UNSOL_STK_CALL_SETUP 1015 |
| 5607 | |
| 5608 | /** |
| 5609 | * RIL_UNSOL_SIM_SMS_STORAGE_FULL |
| 5610 | * |
| 5611 | * Indicates that SMS storage on the SIM is full. Sent when the network |
| 5612 | * attempts to deliver a new SMS message. Messages cannot be saved on the |
| 5613 | * SIM until space is freed. In particular, incoming Class 2 messages |
| 5614 | * cannot be stored. |
| 5615 | * |
| 5616 | * "data" is null |
| 5617 | * |
| 5618 | */ |
| 5619 | #define RIL_UNSOL_SIM_SMS_STORAGE_FULL 1016 |
| 5620 | |
| 5621 | /** |
| 5622 | * RIL_UNSOL_SIM_REFRESH |
| 5623 | * |
| 5624 | * Indicates that file(s) on the SIM have been updated, or the SIM |
| 5625 | * has been reinitialized. |
| 5626 | * |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 5627 | * In the case where RIL is version 6 or older: |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5628 | * "data" is an int * |
| 5629 | * ((int *)data)[0] is a RIL_SimRefreshResult. |
| 5630 | * ((int *)data)[1] is the EFID of the updated file if the result is |
Alex Yakavenka | 45e740e | 2012-01-31 11:48:27 -0800 | [diff] [blame] | 5631 | * SIM_FILE_UPDATE or NULL for any other result. |
| 5632 | * |
| 5633 | * In the case where RIL is version 7: |
| 5634 | * "data" is a RIL_SimRefreshResponse_v7 * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5635 | * |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 5636 | * Note: If the SIM state changes as a result of the SIM refresh (eg, |
| 5637 | * SIM_READY -> SIM_LOCKED_OR_ABSENT), RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5638 | * should be sent. |
| 5639 | */ |
| 5640 | #define RIL_UNSOL_SIM_REFRESH 1017 |
| 5641 | |
| 5642 | /** |
| 5643 | * RIL_UNSOL_CALL_RING |
| 5644 | * |
| 5645 | * Ring indication for an incoming call (eg, RING or CRING event). |
Wink Saville | 6453306 | 2009-08-28 11:16:03 -0700 | [diff] [blame] | 5646 | * There must be at least one RIL_UNSOL_CALL_RING at the beginning |
| 5647 | * of a call and sending multiple is optional. If the system property |
| 5648 | * ro.telephony.call_ring.multiple is false then the upper layers |
| 5649 | * will generate the multiple events internally. Otherwise the vendor |
| 5650 | * ril must generate multiple RIL_UNSOL_CALL_RING if |
| 5651 | * ro.telephony.call_ring.multiple is true or if it is absent. |
| 5652 | * |
| 5653 | * The rate of these events is controlled by ro.telephony.call_ring.delay |
| 5654 | * and has a default value of 3000 (3 seconds) if absent. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5655 | * |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5656 | * "data" is null for GSM |
| 5657 | * "data" is const RIL_CDMA_SignalInfoRecord * if CDMA |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 5658 | */ |
| 5659 | #define RIL_UNSOL_CALL_RING 1018 |
| 5660 | |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5661 | /** |
| 5662 | * RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED |
| 5663 | * |
| 5664 | * Indicates that SIM state changes. |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5665 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5666 | * Callee will invoke RIL_REQUEST_GET_SIM_STATUS on main thread |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5667 | |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5668 | * "data" is null |
| 5669 | */ |
| 5670 | #define RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED 1019 |
| 5671 | |
| 5672 | /** |
| 5673 | * RIL_UNSOL_RESPONSE_CDMA_NEW_SMS |
| 5674 | * |
| 5675 | * Called when new CDMA SMS is received |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5676 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5677 | * "data" is const RIL_CDMA_SMS_Message * |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5678 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5679 | * Callee will subsequently confirm the receipt of the SMS with |
| 5680 | * a RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5681 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5682 | * No new RIL_UNSOL_RESPONSE_CDMA_NEW_SMS should be sent until |
| 5683 | * RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE has been received |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 5684 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5685 | */ |
| 5686 | #define RIL_UNSOL_RESPONSE_CDMA_NEW_SMS 1020 |
| 5687 | |
| 5688 | /** |
| 5689 | * RIL_UNSOL_RESPONSE_NEW_BROADCAST_SMS |
| 5690 | * |
| 5691 | * Called when new Broadcast SMS is received |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5692 | * |
Henrik Hall | 0eba202 | 2010-11-25 10:20:56 +0100 | [diff] [blame] | 5693 | * "data" can be one of the following: |
| 5694 | * If received from GSM network, "data" is const char of 88 bytes |
| 5695 | * which indicates each page of a CBS Message sent to the MS by the |
| 5696 | * BTS as coded in 3GPP 23.041 Section 9.4.1.2. |
| 5697 | * If received from UMTS network, "data" is const char of 90 up to 1252 |
| 5698 | * bytes which contain between 1 and 15 CBS Message pages sent as one |
| 5699 | * packet to the MS by the BTS as coded in 3GPP 23.041 Section 9.4.2.2. |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5700 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5701 | */ |
| 5702 | #define RIL_UNSOL_RESPONSE_NEW_BROADCAST_SMS 1021 |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5703 | |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5704 | /** |
| 5705 | * RIL_UNSOL_CDMA_RUIM_SMS_STORAGE_FULL |
| 5706 | * |
| 5707 | * Indicates that SMS storage on the RUIM is full. Messages |
| 5708 | * cannot be saved on the RUIM until space is freed. |
| 5709 | * |
| 5710 | * "data" is null |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5711 | * |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5712 | */ |
Wink Saville | f4c4d36 | 2009-04-02 01:37:03 -0700 | [diff] [blame] | 5713 | #define RIL_UNSOL_CDMA_RUIM_SMS_STORAGE_FULL 1022 |
| 5714 | |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5715 | /** |
| 5716 | * RIL_UNSOL_RESTRICTED_STATE_CHANGED |
| 5717 | * |
| 5718 | * Indicates a restricted state change (eg, for Domain Specific Access Control). |
| 5719 | * |
| 5720 | * Radio need send this msg after radio off/on cycle no matter it is changed or not. |
| 5721 | * |
| 5722 | * "data" is an int * |
| 5723 | * ((int *)data)[0] contains a bitmask of RIL_RESTRICTED_STATE_* values. |
| 5724 | */ |
| 5725 | #define RIL_UNSOL_RESTRICTED_STATE_CHANGED 1023 |
| 5726 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 5727 | /** |
| 5728 | * RIL_UNSOL_ENTER_EMERGENCY_CALLBACK_MODE |
| 5729 | * |
| 5730 | * Indicates that the radio system selection module has |
| 5731 | * autonomously entered emergency callback mode. |
| 5732 | * |
| 5733 | * "data" is null |
| 5734 | * |
| 5735 | */ |
| 5736 | #define RIL_UNSOL_ENTER_EMERGENCY_CALLBACK_MODE 1024 |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5737 | |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 5738 | /** |
| 5739 | * RIL_UNSOL_CDMA_CALL_WAITING |
| 5740 | * |
| 5741 | * Called when CDMA radio receives a call waiting indication. |
| 5742 | * |
| 5743 | * "data" is const RIL_CDMA_CallWaiting * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 5744 | * |
Wink Saville | 1b5fd23 | 2009-04-22 14:50:00 -0700 | [diff] [blame] | 5745 | */ |
| 5746 | #define RIL_UNSOL_CDMA_CALL_WAITING 1025 |
| 5747 | |
| 5748 | /** |
| 5749 | * RIL_UNSOL_CDMA_OTA_PROVISION_STATUS |
| 5750 | * |
| 5751 | * Called when CDMA radio receives an update of the progress of an |
| 5752 | * OTASP/OTAPA call. |
| 5753 | * |
| 5754 | * "data" is const int * |
| 5755 | * For CDMA this is an integer OTASP/OTAPA status listed in |
| 5756 | * RIL_CDMA_OTA_ProvisionStatus. |
| 5757 | * |
| 5758 | */ |
| 5759 | #define RIL_UNSOL_CDMA_OTA_PROVISION_STATUS 1026 |
| 5760 | |
| 5761 | /** |
| 5762 | * RIL_UNSOL_CDMA_INFO_REC |
| 5763 | * |
| 5764 | * Called when CDMA radio receives one or more info recs. |
| 5765 | * |
| 5766 | * "data" is const RIL_CDMA_InformationRecords * |
| 5767 | * |
| 5768 | */ |
| 5769 | #define RIL_UNSOL_CDMA_INFO_REC 1027 |
The Android Open Source Project | 34a5108 | 2009-03-05 14:34:37 -0800 | [diff] [blame] | 5770 | |
Jaikumar Ganesh | af6ecbf | 2009-04-29 13:27:51 -0700 | [diff] [blame] | 5771 | /** |
| 5772 | * RIL_UNSOL_OEM_HOOK_RAW |
| 5773 | * |
| 5774 | * This is for OEM specific use. |
| 5775 | * |
| 5776 | * "data" is a byte[] |
| 5777 | */ |
| 5778 | #define RIL_UNSOL_OEM_HOOK_RAW 1028 |
| 5779 | |
John Wang | 5d621da | 2009-09-18 17:17:48 -0700 | [diff] [blame] | 5780 | /** |
| 5781 | * RIL_UNSOL_RINGBACK_TONE |
| 5782 | * |
| 5783 | * Indicates that nework doesn't have in-band information, need to |
| 5784 | * play out-band tone. |
| 5785 | * |
| 5786 | * "data" is an int * |
| 5787 | * ((int *)data)[0] == 0 for stop play ringback tone. |
| 5788 | * ((int *)data)[0] == 1 for start play ringback tone. |
| 5789 | */ |
| 5790 | #define RIL_UNSOL_RINGBACK_TONE 1029 |
| 5791 | |
John Wang | 5909cf8 | 2010-01-29 00:18:54 -0800 | [diff] [blame] | 5792 | /** |
| 5793 | * RIL_UNSOL_RESEND_INCALL_MUTE |
| 5794 | * |
| 5795 | * Indicates that framework/application need reset the uplink mute state. |
| 5796 | * |
| 5797 | * There may be situations where the mute state becomes out of sync |
| 5798 | * between the application and device in some GSM infrastructures. |
| 5799 | * |
| 5800 | * "data" is null |
| 5801 | */ |
| 5802 | #define RIL_UNSOL_RESEND_INCALL_MUTE 1030 |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5803 | |
| 5804 | /** |
| 5805 | * RIL_UNSOL_CDMA_SUBSCRIPTION_SOURCE_CHANGED |
| 5806 | * |
| 5807 | * Called when CDMA subscription source changed. |
| 5808 | * |
| 5809 | * "data" is int * |
| 5810 | * ((int *)data)[0] is == RIL_CdmaSubscriptionSource |
| 5811 | */ |
Wink Saville | 29487ef | 2011-04-15 09:15:31 -0700 | [diff] [blame] | 5812 | #define RIL_UNSOL_CDMA_SUBSCRIPTION_SOURCE_CHANGED 1031 |
Wink Saville | c0114b3 | 2011-02-18 10:14:07 -0800 | [diff] [blame] | 5813 | |
| 5814 | /** |
| 5815 | * RIL_UNSOL_CDMA_PRL_CHANGED |
| 5816 | * |
| 5817 | * Called when PRL (preferred roaming list) changes. |
| 5818 | * |
| 5819 | * "data" is int * |
| 5820 | * ((int *)data)[0] is PRL_VERSION as would be returned by RIL_REQUEST_CDMA_SUBSCRIPTION |
| 5821 | */ |
| 5822 | #define RIL_UNSOL_CDMA_PRL_CHANGED 1032 |
| 5823 | |
| 5824 | /** |
| 5825 | * RIL_UNSOL_EXIT_EMERGENCY_CALLBACK_MODE |
| 5826 | * |
| 5827 | * Called when Emergency Callback Mode Ends |
| 5828 | * |
| 5829 | * Indicates that the radio system selection module has |
| 5830 | * proactively exited emergency callback mode. |
| 5831 | * |
| 5832 | * "data" is NULL |
| 5833 | * |
| 5834 | */ |
| 5835 | #define RIL_UNSOL_EXIT_EMERGENCY_CALLBACK_MODE 1033 |
| 5836 | |
Wink Saville | 5b9df33 | 2011-04-06 16:24:21 -0700 | [diff] [blame] | 5837 | /** |
| 5838 | * RIL_UNSOL_RIL_CONNECTED |
| 5839 | * |
| 5840 | * Called the ril connects and returns the version |
| 5841 | * |
| 5842 | * "data" is int * |
| 5843 | * ((int *)data)[0] is RIL_VERSION |
| 5844 | */ |
| 5845 | #define RIL_UNSOL_RIL_CONNECTED 1034 |
| 5846 | |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 5847 | /** |
| 5848 | * RIL_UNSOL_VOICE_RADIO_TECH_CHANGED |
| 5849 | * |
| 5850 | * Indicates that voice technology has changed. Contains new radio technology |
| 5851 | * as a data in the message. |
| 5852 | * |
| 5853 | * "data" is int * |
| 5854 | * ((int *)data)[0] is of type const RIL_RadioTechnology |
| 5855 | * |
| 5856 | */ |
| 5857 | #define RIL_UNSOL_VOICE_RADIO_TECH_CHANGED 1035 |
| 5858 | |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 5859 | /** |
| 5860 | * RIL_UNSOL_CELL_INFO_LIST |
| 5861 | * |
| 5862 | * Same information as returned by RIL_REQUEST_GET_CELL_INFO_LIST, but returned |
| 5863 | * at the rate no greater than specified by RIL_REQUEST_SET_UNSOL_CELL_INFO_RATE. |
| 5864 | * |
| 5865 | * "data" is NULL |
| 5866 | * |
Sanket Padawe | f53c5fa | 2016-01-27 10:00:38 -0800 | [diff] [blame] | 5867 | * "response" is an array of RIL_CellInfo_v12. |
Wink Saville | 8a9e021 | 2013-04-09 12:11:38 -0700 | [diff] [blame] | 5868 | */ |
| 5869 | #define RIL_UNSOL_CELL_INFO_LIST 1036 |
Naveen Kalla | 2bc78d6 | 2011-12-07 16:22:53 -0800 | [diff] [blame] | 5870 | |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 5871 | /** |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 5872 | * RIL_UNSOL_RESPONSE_IMS_NETWORK_STATE_CHANGED |
| 5873 | * |
Nathan Harold | 0eb43c2 | 2016-12-19 12:04:32 -0800 | [diff] [blame] | 5874 | * This message is DEPRECATED and shall be removed in a future release (target: 2018); |
| 5875 | * instead, provide IMS registration status via an IMS Service. |
| 5876 | * |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 5877 | * Called when IMS registration state has changed |
| 5878 | * |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 5879 | * To get IMS registration state and IMS SMS format, callee needs to invoke the |
| 5880 | * following request on main thread: |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 5881 | * |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 5882 | * RIL_REQUEST_IMS_REGISTRATION_STATE |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 5883 | * |
Wink Saville | 865ce3b | 2013-11-08 16:37:01 -0800 | [diff] [blame] | 5884 | * "data" is NULL |
| 5885 | * |
Sukanya Rajkhowa | a18b9d1 | 2013-09-10 12:30:13 -0700 | [diff] [blame] | 5886 | */ |
| 5887 | #define RIL_UNSOL_RESPONSE_IMS_NETWORK_STATE_CHANGED 1037 |
| 5888 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 5889 | /** |
| 5890 | * RIL_UNSOL_UICC_SUBSCRIPTION_STATUS_CHANGED |
| 5891 | * |
| 5892 | * Indicated when there is a change in subscription status. |
| 5893 | * This event will be sent in the following scenarios |
| 5894 | * - subscription readiness at modem, which was selected by telephony layer |
| 5895 | * - when subscription is deactivated by modem due to UICC card removal |
| 5896 | * - When network invalidates the subscription i.e. attach reject due to authentication reject |
| 5897 | * |
| 5898 | * "data" is const int * |
| 5899 | * ((const int *)data)[0] == 0 for Subscription Deactivated |
| 5900 | * ((const int *)data)[0] == 1 for Subscription Activated |
| 5901 | * |
| 5902 | */ |
| 5903 | #define RIL_UNSOL_UICC_SUBSCRIPTION_STATUS_CHANGED 1038 |
| 5904 | |
| 5905 | /** |
| 5906 | * RIL_UNSOL_SRVCC_STATE_NOTIFY |
| 5907 | * |
| 5908 | * Called when Single Radio Voice Call Continuity(SRVCC) |
| 5909 | * progress state has changed |
| 5910 | * |
| 5911 | * "data" is int * |
| 5912 | * ((int *)data)[0] is of type const RIL_SrvccState |
| 5913 | * |
| 5914 | */ |
| 5915 | |
| 5916 | #define RIL_UNSOL_SRVCC_STATE_NOTIFY 1039 |
| 5917 | |
| 5918 | /** |
| 5919 | * RIL_UNSOL_HARDWARE_CONFIG_CHANGED |
| 5920 | * |
| 5921 | * Called when the hardware configuration associated with the RILd changes |
| 5922 | * |
| 5923 | * "data" is an array of RIL_HardwareConfig |
| 5924 | * |
| 5925 | */ |
| 5926 | #define RIL_UNSOL_HARDWARE_CONFIG_CHANGED 1040 |
| 5927 | |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5928 | /** |
| 5929 | * RIL_UNSOL_DC_RT_INFO_CHANGED |
| 5930 | * |
Sooraj Sasindran | 73f2ccb | 2015-04-08 17:23:07 -0700 | [diff] [blame] | 5931 | * The message is DEPRECATED, use RIL_REQUEST_GET_ACTIVITY_INFO |
Wink Saville | c29360a | 2014-07-13 05:17:28 -0700 | [diff] [blame] | 5932 | * Sent when the DC_RT_STATE changes but the time |
| 5933 | * between these messages must not be less than the |
| 5934 | * value set by RIL_REQUEST_SET_DC_RT_RATE. |
| 5935 | * |
| 5936 | * "data" is the most recent RIL_DcRtInfo |
| 5937 | * |
| 5938 | */ |
| 5939 | #define RIL_UNSOL_DC_RT_INFO_CHANGED 1041 |
| 5940 | |
Wink Saville | 8b4e4f7 | 2014-10-17 15:01:45 -0700 | [diff] [blame] | 5941 | /** |
| 5942 | * RIL_UNSOL_RADIO_CAPABILITY |
| 5943 | * |
| 5944 | * Sent when RIL_REQUEST_SET_RADIO_CAPABILITY completes. |
| 5945 | * Returns the phone radio capability exactly as |
| 5946 | * RIL_REQUEST_GET_RADIO_CAPABILITY and should be the |
| 5947 | * same set as sent by RIL_REQUEST_SET_RADIO_CAPABILITY. |
| 5948 | * |
| 5949 | * "data" is the RIL_RadioCapability structure |
| 5950 | */ |
| 5951 | #define RIL_UNSOL_RADIO_CAPABILITY 1042 |
| 5952 | |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 5953 | /* |
| 5954 | * RIL_UNSOL_ON_SS |
| 5955 | * |
| 5956 | * Called when SS response is received when DIAL/USSD/SS is changed to SS by |
| 5957 | * call control. |
| 5958 | * |
| 5959 | * "data" is const RIL_StkCcUnsolSsResponse * |
| 5960 | * |
| 5961 | */ |
| 5962 | #define RIL_UNSOL_ON_SS 1043 |
| 5963 | |
| 5964 | /** |
| 5965 | * RIL_UNSOL_STK_CC_ALPHA_NOTIFY |
| 5966 | * |
| 5967 | * Called when there is an ALPHA from UICC during Call Control. |
| 5968 | * |
| 5969 | * "data" is const char * containing ALPHA string from UICC in UTF-8 format. |
| 5970 | * |
| 5971 | */ |
| 5972 | #define RIL_UNSOL_STK_CC_ALPHA_NOTIFY 1044 |
| 5973 | |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5974 | /** |
| 5975 | * RIL_UNSOL_LCEDATA_RECV |
| 5976 | * |
| 5977 | * Called when there is an incoming Link Capacity Estimate (LCE) info report. |
| 5978 | * |
fenglu | 290add3 | 2015-05-01 17:05:15 -0700 | [diff] [blame] | 5979 | * "data" is the RIL_LceDataInfo structure. |
fenglu | f740829 | 2015-04-14 14:53:55 -0700 | [diff] [blame] | 5980 | * |
| 5981 | */ |
| 5982 | #define RIL_UNSOL_LCEDATA_RECV 1045 |
| 5983 | |
Robert Greenwalt | 27e99c5 | 2016-06-01 16:31:38 -0700 | [diff] [blame] | 5984 | /** |
| 5985 | * RIL_UNSOL_PCO_DATA |
| 5986 | * |
| 5987 | * Called when there is new Carrier PCO data received for a data call. Ideally |
| 5988 | * only new data will be forwarded, though this is not required. Multiple |
| 5989 | * boxes of carrier PCO data for a given call should result in a series of |
| 5990 | * RIL_UNSOL_PCO_DATA calls. |
| 5991 | * |
| 5992 | * "data" is the RIL_PCO_Data structure. |
| 5993 | * |
| 5994 | */ |
| 5995 | #define RIL_UNSOL_PCO_DATA 1046 |
| 5996 | |
pkanwar | c61837e | 2017-03-17 12:49:34 -0700 | [diff] [blame] | 5997 | /** |
| 5998 | * RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION |
| 5999 | * |
| 6000 | * Called when the modem needs Carrier specific information that will |
| 6001 | * be used to encrypt IMSI and IMPI. |
| 6002 | * |
| 6003 | * "data" is NULL |
| 6004 | * |
| 6005 | */ |
| 6006 | #define RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION 1047 |
| 6007 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6008 | /***********************************************************************/ |
| 6009 | |
Amit Mahajan | 54563d3 | 2014-11-22 00:54:49 +0000 | [diff] [blame] | 6010 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6011 | #if defined(ANDROID_MULTI_SIM) |
| 6012 | /** |
| 6013 | * RIL_Request Function pointer |
| 6014 | * |
| 6015 | * @param request is one of RIL_REQUEST_* |
| 6016 | * @param data is pointer to data defined for that RIL_REQUEST_* |
| 6017 | * data is owned by caller, and should not be modified or freed by callee |
Sanket Padawe | 05c2307 | 2016-08-08 15:42:17 -0700 | [diff] [blame] | 6018 | * structures passed as data may contain pointers to non-contiguous memory |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6019 | * @param t should be used in subsequent call to RIL_onResponse |
Sanket Padawe | 05c2307 | 2016-08-08 15:42:17 -0700 | [diff] [blame] | 6020 | * @param datalen is the length of "data" which is defined as other argument. It may or may |
| 6021 | * not be equal to sizeof(data). Refer to the documentation of individual structures |
| 6022 | * to find if pointers listed in the structure are contiguous and counted in the datalen |
| 6023 | * length or not. |
| 6024 | * (Eg: RIL_IMS_SMS_Message where we don't have datalen equal to sizeof(data)) |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6025 | * |
| 6026 | */ |
| 6027 | typedef void (*RIL_RequestFunc) (int request, void *data, |
| 6028 | size_t datalen, RIL_Token t, RIL_SOCKET_ID socket_id); |
| 6029 | |
| 6030 | /** |
| 6031 | * This function should return the current radio state synchronously |
| 6032 | */ |
| 6033 | typedef RIL_RadioState (*RIL_RadioStateRequest)(RIL_SOCKET_ID socket_id); |
| 6034 | |
| 6035 | #else |
| 6036 | /* Backward compatible */ |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6037 | |
| 6038 | /** |
| 6039 | * RIL_Request Function pointer |
| 6040 | * |
| 6041 | * @param request is one of RIL_REQUEST_* |
| 6042 | * @param data is pointer to data defined for that RIL_REQUEST_* |
| 6043 | * data is owned by caller, and should not be modified or freed by callee |
Sanket Padawe | 05c2307 | 2016-08-08 15:42:17 -0700 | [diff] [blame] | 6044 | * structures passed as data may contain pointers to non-contiguous memory |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6045 | * @param t should be used in subsequent call to RIL_onResponse |
Sanket Padawe | 05c2307 | 2016-08-08 15:42:17 -0700 | [diff] [blame] | 6046 | * @param datalen is the length of "data" which is defined as other argument. It may or may |
| 6047 | * not be equal to sizeof(data). Refer to the documentation of individual structures |
| 6048 | * to find if pointers listed in the structure are contiguous and counted in the datalen |
| 6049 | * length or not. |
| 6050 | * (Eg: RIL_IMS_SMS_Message where we don't have datalen equal to sizeof(data)) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6051 | * |
| 6052 | */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6053 | typedef void (*RIL_RequestFunc) (int request, void *data, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6054 | size_t datalen, RIL_Token t); |
| 6055 | |
| 6056 | /** |
| 6057 | * This function should return the current radio state synchronously |
| 6058 | */ |
| 6059 | typedef RIL_RadioState (*RIL_RadioStateRequest)(); |
| 6060 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6061 | #endif |
| 6062 | |
| 6063 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6064 | /** |
| 6065 | * This function returns "1" if the specified RIL_REQUEST code is |
| 6066 | * supported and 0 if it is not |
| 6067 | * |
| 6068 | * @param requestCode is one of RIL_REQUEST codes |
| 6069 | */ |
| 6070 | |
| 6071 | typedef int (*RIL_Supports)(int requestCode); |
| 6072 | |
| 6073 | /** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6074 | * This function is called from a separate thread--not the |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6075 | * thread that calls RIL_RequestFunc--and indicates that a pending |
| 6076 | * request should be cancelled. |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6077 | * |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6078 | * On cancel, the callee should do its best to abandon the request and |
| 6079 | * call RIL_onRequestComplete with RIL_Errno CANCELLED at some later point. |
| 6080 | * |
| 6081 | * Subsequent calls to RIL_onRequestComplete for this request with |
| 6082 | * other results will be tolerated but ignored. (That is, it is valid |
| 6083 | * to ignore the cancellation request) |
| 6084 | * |
| 6085 | * RIL_Cancel calls should return immediately, and not wait for cancellation |
| 6086 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6087 | * Please see ITU v.250 5.6.1 for how one might implement this on a TS 27.007 |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6088 | * interface |
| 6089 | * |
| 6090 | * @param t token wants to be canceled |
| 6091 | */ |
| 6092 | |
| 6093 | typedef void (*RIL_Cancel)(RIL_Token t); |
| 6094 | |
| 6095 | typedef void (*RIL_TimedCallback) (void *param); |
| 6096 | |
| 6097 | /** |
| 6098 | * Return a version string for your RIL implementation |
| 6099 | */ |
| 6100 | typedef const char * (*RIL_GetVersion) (void); |
| 6101 | |
| 6102 | typedef struct { |
| 6103 | int version; /* set to RIL_VERSION */ |
| 6104 | RIL_RequestFunc onRequest; |
| 6105 | RIL_RadioStateRequest onStateRequest; |
| 6106 | RIL_Supports supports; |
| 6107 | RIL_Cancel onCancel; |
| 6108 | RIL_GetVersion getVersion; |
| 6109 | } RIL_RadioFunctions; |
| 6110 | |
Sungmin Choi | 7569753 | 2013-04-26 15:04:45 -0700 | [diff] [blame] | 6111 | typedef struct { |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 6112 | char *apn; /* the APN to connect to */ |
| 6113 | char *protocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on |
| 6114 | roaming network. For example, "IP", "IPV6", "IPV4V6", or "PPP".*/ |
| 6115 | int authtype; /* authentication protocol used for this PDP context |
| 6116 | (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) */ |
| 6117 | char *username; /* the username for APN, or NULL */ |
| 6118 | char *password; /* the password for APN, or NULL */ |
Sungmin Choi | 7569753 | 2013-04-26 15:04:45 -0700 | [diff] [blame] | 6119 | } RIL_InitialAttachApn; |
| 6120 | |
Amit Mahajan | 2b77203 | 2014-06-26 14:20:11 -0700 | [diff] [blame] | 6121 | typedef struct { |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 6122 | char *apn; /* the APN to connect to */ |
| 6123 | char *protocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on |
| 6124 | home network. For example, "IP", "IPV6", "IPV4V6", or "PPP". */ |
| 6125 | char *roamingProtocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on |
| 6126 | roaming network. For example, "IP", "IPV6", "IPV4V6", or "PPP".*/ |
| 6127 | int authtype; /* authentication protocol used for this PDP context |
| 6128 | (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) */ |
| 6129 | char *username; /* the username for APN, or NULL */ |
| 6130 | char *password; /* the password for APN, or NULL */ |
| 6131 | int supportedTypesBitmask; /* supported APN types bitmask. See RIL_ApnTypes for the value of |
| 6132 | each bit. */ |
| 6133 | int bearerBitmask; /* the bearer bitmask. See RIL_RadioAccessFamily for the value of |
| 6134 | each bit. */ |
| 6135 | int modemCognitive; /* indicating the APN setting was sent to the modem through |
| 6136 | setDataProfile earlier. */ |
| 6137 | int mtu; /* maximum transmission unit (MTU) size in bytes */ |
| 6138 | char *mvnoType; /* the MVNO type: possible values are "imsi", "gid", "spn" */ |
| 6139 | char *mvnoMatchData; /* MVNO match data. Can be anything defined by the carrier. |
| 6140 | For example, |
| 6141 | SPN like: "A MOBILE", "BEN NL", etc... |
| 6142 | IMSI like: "302720x94", "2060188", etc... |
| 6143 | GID like: "4E", "33", etc... */ |
| 6144 | } RIL_InitialAttachApn_v15; |
| 6145 | |
| 6146 | typedef struct { |
Amit Mahajan | 2b77203 | 2014-06-26 14:20:11 -0700 | [diff] [blame] | 6147 | int authContext; /* P2 value of authentication command, see P2 parameter in |
| 6148 | 3GPP TS 31.102 7.1.2 */ |
| 6149 | char *authData; /* the challenge string in Base64 format, see 3GPP |
| 6150 | TS 31.102 7.1.2 */ |
| 6151 | char *aid; /* AID value, See ETSI 102.221 8.1 and 101.220 4, |
| 6152 | NULL if no value. */ |
| 6153 | } RIL_SimAuthentication; |
| 6154 | |
Robert Greenwalt | 17ea3fa | 2016-06-15 14:59:38 -0700 | [diff] [blame] | 6155 | typedef struct { |
Jack Yu | 06181bb | 2017-01-10 12:10:41 -0800 | [diff] [blame] | 6156 | int cid; /* Context ID, uniquely identifies this call */ |
| 6157 | char *bearer_proto; /* One of the PDP_type values in TS 27.007 section 10.1.1. |
| 6158 | For example, "IP", "IPV6", "IPV4V6". */ |
| 6159 | int pco_id; /* The protocol ID for this box. Note that only IDs from |
| 6160 | FF00H - FFFFH are accepted. If more than one is included |
| 6161 | from the network, multiple calls should be made to send all |
| 6162 | of them. */ |
| 6163 | int contents_length; /* The number of octets in the contents. */ |
| 6164 | char *contents; /* Carrier-defined content. It is binary, opaque and |
| 6165 | loosely defined in LTE Layer 3 spec 24.008 */ |
Robert Greenwalt | 17ea3fa | 2016-06-15 14:59:38 -0700 | [diff] [blame] | 6166 | } RIL_PCO_Data; |
| 6167 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6168 | #ifdef RIL_SHLIB |
| 6169 | struct RIL_Env { |
| 6170 | /** |
| 6171 | * "t" is parameter passed in on previous call to RIL_Notification |
| 6172 | * routine. |
| 6173 | * |
| 6174 | * If "e" != SUCCESS, then response can be null/is ignored |
| 6175 | * |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6176 | * "response" is owned by caller, and should not be modified or |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6177 | * freed by callee |
| 6178 | * |
| 6179 | * RIL_onRequestComplete will return as soon as possible |
| 6180 | */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6181 | void (*OnRequestComplete)(RIL_Token t, RIL_Errno e, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6182 | void *response, size_t responselen); |
| 6183 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6184 | #if defined(ANDROID_MULTI_SIM) |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6185 | /** |
| 6186 | * "unsolResponse" is one of RIL_UNSOL_RESPONSE_* |
| 6187 | * "data" is pointer to data defined for that RIL_UNSOL_RESPONSE_* |
| 6188 | * |
| 6189 | * "data" is owned by caller, and should not be modified or freed by callee |
| 6190 | */ |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6191 | void (*OnUnsolicitedResponse)(int unsolResponse, const void *data, size_t datalen, RIL_SOCKET_ID socket_id); |
| 6192 | #else |
| 6193 | /** |
| 6194 | * "unsolResponse" is one of RIL_UNSOL_RESPONSE_* |
| 6195 | * "data" is pointer to data defined for that RIL_UNSOL_RESPONSE_* |
| 6196 | * |
| 6197 | * "data" is owned by caller, and should not be modified or freed by callee |
| 6198 | */ |
| 6199 | void (*OnUnsolicitedResponse)(int unsolResponse, const void *data, size_t datalen); |
| 6200 | #endif |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6201 | /** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6202 | * Call user-specifed "callback" function on on the same thread that |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6203 | * RIL_RequestFunc is called. If "relativeTime" is specified, then it specifies |
| 6204 | * a relative time value at which the callback is invoked. If relativeTime is |
| 6205 | * NULL or points to a 0-filled structure, the callback will be invoked as |
| 6206 | * soon as possible |
| 6207 | */ |
| 6208 | |
Dianne Hackborn | 0d9f0c0 | 2010-06-25 16:50:46 -0700 | [diff] [blame] | 6209 | void (*RequestTimedCallback) (RIL_TimedCallback callback, |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6210 | void *param, const struct timeval *relativeTime); |
Sanket Padawe | 6ff9a87 | 2016-01-27 15:09:12 -0800 | [diff] [blame] | 6211 | /** |
| 6212 | * "t" is parameter passed in on previous call RIL_Notification routine |
| 6213 | * |
| 6214 | * RIL_onRequestAck will be called by vendor when an Async RIL request was received |
| 6215 | * by them and an ack needs to be sent back to java ril. |
| 6216 | */ |
| 6217 | void (*OnRequestAck) (RIL_Token t); |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6218 | }; |
| 6219 | |
| 6220 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6221 | /** |
| 6222 | * RIL implementations must defined RIL_Init |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6223 | * argc and argv will be command line arguments intended for the RIL implementation |
| 6224 | * Return NULL on error |
| 6225 | * |
| 6226 | * @param env is environment point defined as RIL_Env |
| 6227 | * @param argc number of arguments |
| 6228 | * @param argv list fo arguments |
| 6229 | * |
| 6230 | */ |
| 6231 | const RIL_RadioFunctions *RIL_Init(const struct RIL_Env *env, int argc, char **argv); |
| 6232 | |
Sanket Padawe | 1be49ba | 2016-03-31 17:37:23 -0700 | [diff] [blame] | 6233 | /** |
| 6234 | * If BT SAP(SIM Access Profile) is supported, then RIL implementations must define RIL_SAP_Init |
| 6235 | * for initializing RIL_RadioFunctions used for BT SAP communcations. It is called whenever RILD |
| 6236 | * starts or modem restarts. Returns handlers for SAP related request that are made on SAP |
| 6237 | * sepecific socket, analogous to the RIL_RadioFunctions returned by the call to RIL_Init |
| 6238 | * and used on the general RIL socket. |
| 6239 | * argc and argv will be command line arguments intended for the RIL implementation |
| 6240 | * Return NULL on error. |
| 6241 | * |
| 6242 | * @param env is environment point defined as RIL_Env |
| 6243 | * @param argc number of arguments |
| 6244 | * @param argv list fo arguments |
| 6245 | * |
| 6246 | */ |
| 6247 | const RIL_RadioFunctions *RIL_SAP_Init(const struct RIL_Env *env, int argc, char **argv); |
| 6248 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6249 | #else /* RIL_SHLIB */ |
| 6250 | |
| 6251 | /** |
| 6252 | * Call this once at startup to register notification routine |
| 6253 | * |
| 6254 | * @param callbacks user-specifed callback function |
| 6255 | */ |
| 6256 | void RIL_register (const RIL_RadioFunctions *callbacks); |
| 6257 | |
Amit Mahajan | cd77a5b | 2016-08-25 11:19:21 -0700 | [diff] [blame] | 6258 | void rilc_thread_pool(); |
| 6259 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6260 | |
| 6261 | /** |
| 6262 | * |
| 6263 | * RIL_onRequestComplete will return as soon as possible |
| 6264 | * |
| 6265 | * @param t is parameter passed in on previous call to RIL_Notification |
Wink Saville | 3d54e74 | 2009-05-18 18:00:44 -0700 | [diff] [blame] | 6266 | * routine. |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6267 | * @param e error code |
| 6268 | * if "e" != SUCCESS, then response can be null/is ignored |
| 6269 | * @param response is owned by caller, and should not be modified or |
| 6270 | * freed by callee |
| 6271 | * @param responselen the length of response in byte |
| 6272 | */ |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6273 | void RIL_onRequestComplete(RIL_Token t, RIL_Errno e, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6274 | void *response, size_t responselen); |
| 6275 | |
Sanket Padawe | 6ff9a87 | 2016-01-27 15:09:12 -0800 | [diff] [blame] | 6276 | /** |
| 6277 | * RIL_onRequestAck will be called by vendor when an Async RIL request was received by them and |
| 6278 | * an ack needs to be sent back to java ril. This doesn't mark the end of the command or it's |
| 6279 | * results, just that the command was received and will take a while. After sending this Ack |
| 6280 | * its vendor's responsibility to make sure that AP is up whenever needed while command is |
| 6281 | * being processed. |
| 6282 | * |
| 6283 | * @param t is parameter passed in on previous call to RIL_Notification |
| 6284 | * routine. |
| 6285 | */ |
| 6286 | void RIL_onRequestAck(RIL_Token t); |
| 6287 | |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6288 | #if defined(ANDROID_MULTI_SIM) |
| 6289 | /** |
| 6290 | * @param unsolResponse is one of RIL_UNSOL_RESPONSE_* |
| 6291 | * @param data is pointer to data defined for that RIL_UNSOL_RESPONSE_* |
| 6292 | * "data" is owned by caller, and should not be modified or freed by callee |
| 6293 | * @param datalen the length of data in byte |
| 6294 | */ |
| 6295 | |
| 6296 | void RIL_onUnsolicitedResponse(int unsolResponse, const void *data, |
| 6297 | size_t datalen, RIL_SOCKET_ID socket_id); |
| 6298 | #else |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6299 | /** |
| 6300 | * @param unsolResponse is one of RIL_UNSOL_RESPONSE_* |
| 6301 | * @param data is pointer to data defined for that RIL_UNSOL_RESPONSE_* |
| 6302 | * "data" is owned by caller, and should not be modified or freed by callee |
| 6303 | * @param datalen the length of data in byte |
| 6304 | */ |
| 6305 | |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6306 | void RIL_onUnsolicitedResponse(int unsolResponse, const void *data, |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6307 | size_t datalen); |
Etan Cohen | d365219 | 2014-06-20 08:28:44 -0700 | [diff] [blame] | 6308 | #endif |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6309 | |
| 6310 | /** |
Wink Saville | 7f85680 | 2009-06-09 10:23:37 -0700 | [diff] [blame] | 6311 | * Call user-specifed "callback" function on on the same thread that |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6312 | * RIL_RequestFunc is called. If "relativeTime" is specified, then it specifies |
| 6313 | * a relative time value at which the callback is invoked. If relativeTime is |
| 6314 | * NULL or points to a 0-filled structure, the callback will be invoked as |
| 6315 | * soon as possible |
| 6316 | * |
| 6317 | * @param callback user-specifed callback function |
| 6318 | * @param param parameter list |
| 6319 | * @param relativeTime a relative time value at which the callback is invoked |
| 6320 | */ |
| 6321 | |
Dianne Hackborn | 0d9f0c0 | 2010-06-25 16:50:46 -0700 | [diff] [blame] | 6322 | void RIL_requestTimedCallback (RIL_TimedCallback callback, |
| 6323 | void *param, const struct timeval *relativeTime); |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6324 | |
The Android Open Source Project | 00f06fc | 2009-03-03 19:32:15 -0800 | [diff] [blame] | 6325 | #endif /* RIL_SHLIB */ |
| 6326 | |
| 6327 | #ifdef __cplusplus |
| 6328 | } |
| 6329 | #endif |
| 6330 | |
| 6331 | #endif /*ANDROID_RIL_H*/ |