blob: 3d40b8f6e12240169985795abe7b0d39c2294e18 [file] [log] [blame]
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08001/*
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 Saville7f856802009-06-09 10:23:37 -070017#ifndef ANDROID_RIL_H
The Android Open Source Project00f06fc2009-03-03 19:32:15 -080018#define ANDROID_RIL_H 1
19
20#include <stdlib.h>
Wink Saville8a9e0212013-04-09 12:11:38 -070021#include <stdint.h>
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -070022#include <telephony/ril_cdma_sms.h>
Jake Hamby8a4a2332014-01-15 13:12:05 -080023#include <telephony/ril_nv_items.h>
Etan Cohend3652192014-06-20 08:28:44 -070024#include <telephony/ril_msim.h>
Jake Hamby8a4a2332014-01-15 13:12:05 -080025
Wink Savillef4c4d362009-04-02 01:37:03 -070026#ifndef FEATURE_UNIT_TEST
The Android Open Source Project00f06fc2009-03-03 19:32:15 -080027#include <sys/time.h>
Wink Savillef4c4d362009-04-02 01:37:03 -070028#endif /* !FEATURE_UNIT_TEST */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -080029
30#ifdef __cplusplus
31extern "C" {
32#endif
33
Amit Mahajan93f603c2017-05-15 16:41:44 -070034#ifndef SIM_COUNT
Etan Cohend3652192014-06-20 08:28:44 -070035#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
Amit Mahajan93f603c2017-05-15 16:41:44 -070048#endif
Etan Cohend3652192014-06-20 08:28:44 -070049
Sanket Padawe88cf6a52016-01-11 12:45:43 -080050/*
51 * RIL version.
52 * Value of RIL_VERSION should not be changed in future. Here onwards,
53 * when a new change is supposed to be introduced which could involve new
54 * schemes added like Wakelocks, data structures added/updated, etc, we would
55 * just document RIL version associated with that change below. When OEM updates its
56 * RIL with those changes, they would return that new RIL version during RIL_REGISTER.
57 * We should make use of the returned version by vendor to identify appropriate scheme
58 * or data structure version to use.
59 *
60 * Documentation of RIL version and associated changes
Sanket Padawef53c5fa2016-01-27 10:00:38 -080061 * RIL_VERSION = 12 : This version corresponds to updated data structures namely
Sanket Padawe88cf6a52016-01-11 12:45:43 -080062 * RIL_Data_Call_Response_v11, RIL_SIM_IO_v6, RIL_CardStatus_v6,
63 * RIL_SimRefreshResponse_v7, RIL_CDMA_CallWaiting_v6,
Sanket Padawe6ff9a872016-01-27 15:09:12 -080064 * RIL_LTE_SignalStrength_v8, RIL_SignalStrength_v10, RIL_CellIdentityGsm_v12
65 * RIL_CellIdentityWcdma_v12, RIL_CellIdentityLte_v12,RIL_CellInfoGsm_v12,
66 * RIL_CellInfoWcdma_v12, RIL_CellInfoLte_v12, RIL_CellInfo_v12.
Sanket Padawe88cf6a52016-01-11 12:45:43 -080067 *
Sanket Padawe6ff9a872016-01-27 15:09:12 -080068 * RIL_VERSION = 13 : This version includes new wakelock semantics and as the first
Robert Greenwalt27e99c52016-06-01 16:31:38 -070069 * strongly versioned version it enforces structure use.
Jack Yude8c8552017-01-24 12:03:52 -080070 *
Robert Greenwalt27e99c52016-06-01 16:31:38 -070071 * RIL_VERSION = 14 : New data structures are added, namely RIL_CarrierMatchType,
72 * RIL_Carrier, RIL_CarrierRestrictions and RIL_PCO_Data.
73 * New commands added: RIL_REQUEST_SET_CARRIER_RESTRICTIONS,
Naveen Kalla90ddf072016-09-14 13:41:04 -070074 * RIL_REQUEST_SET_CARRIER_RESTRICTIONS and RIL_UNSOL_PCO_DATA.
Wileen Chiu35380a32017-01-04 11:37:19 -080075 *
76 * RIL_VERSION = 15 : New commands added:
77 * RIL_UNSOL_MODEM_RESTART,
78 * RIL_REQUEST_SEND_DEVICE_STATE,
79 * RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER,
pkanwarc61837e2017-03-17 12:49:34 -070080 * RIL_REQUEST_SET_SIM_CARD_POWER,
81 * RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION,
82 * RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION
Jack Yude8c8552017-01-24 12:03:52 -080083 * The new parameters for RIL_REQUEST_SETUP_DATA_CALL,
84 * Updated data structures: RIL_DataProfileInfo_v15, RIL_InitialAttachApn_v15
Sooraj Sasindranf4714b72016-11-30 18:36:03 -080085 * New data structure RIL_DataRegistrationStateResponse,
86 * RIL_VoiceRegistrationStateResponse same is
87 * used in RIL_REQUEST_DATA_REGISTRATION_STATE and
88 * RIL_REQUEST_VOICE_REGISTRATION_STATE respectively.
Wileen Chiud6222e02015-11-23 14:25:22 -080089 * New data structure RIL_OpenChannelParams.
yinxu7317bd42017-05-03 15:15:19 -070090 * RIL_REQUEST_START_NETWORK_SCAN
91 * RIL_REQUEST_STOP_NETWORK_SCAN
92 * RIL_UNSOL_NETWORK_SCAN_RESULT
Sanket Padawe88cf6a52016-01-11 12:45:43 -080093 */
Sanket Padawef53c5fa2016-01-27 10:00:38 -080094#define RIL_VERSION 12
95#define LAST_IMPRECISE_RIL_VERSION 12 // Better self-documented name
Alex Yakavenka45e740e2012-01-31 11:48:27 -080096#define RIL_VERSION_MIN 6 /* Minimum RIL_VERSION supported */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -080097
Wink Savillea592eeb2009-05-22 13:26:36 -070098#define CDMA_ALPHA_INFO_BUFFER_LENGTH 64
99#define CDMA_NUMBER_INFO_BUFFER_LENGTH 81
100
Etan Cohend3652192014-06-20 08:28:44 -0700101#define MAX_RILDS 3
Amit Mahajan35e93102017-03-28 11:17:55 -0700102#define MAX_SERVICE_NAME_LENGTH 6
Etan Cohend3652192014-06-20 08:28:44 -0700103#define MAX_CLIENT_ID_LENGTH 2
104#define MAX_DEBUG_SOCKET_NAME_LENGTH 12
105#define MAX_QEMU_PIPE_NAME_LENGTH 11
Wink Saville8b4e4f72014-10-17 15:01:45 -0700106#define MAX_UUID_LENGTH 64
yinxu7317bd42017-05-03 15:15:19 -0700107#define MAX_BANDS 8
108#define MAX_CHANNELS 32
109#define MAX_RADIO_ACCESS_NETWORKS 8
Wink Saville8b4e4f72014-10-17 15:01:45 -0700110
Etan Cohend3652192014-06-20 08:28:44 -0700111
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800112typedef void * RIL_Token;
113
114typedef enum {
Etan Cohend3652192014-06-20 08:28:44 -0700115 RIL_SOCKET_1,
116#if (SIM_COUNT >= 2)
117 RIL_SOCKET_2,
118#if (SIM_COUNT >= 3)
119 RIL_SOCKET_3,
120#endif
121#if (SIM_COUNT >= 4)
122 RIL_SOCKET_4,
123#endif
124#endif
125 RIL_SOCKET_NUM
126} RIL_SOCKET_ID;
127
128
129typedef enum {
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800130 RIL_E_SUCCESS = 0,
131 RIL_E_RADIO_NOT_AVAILABLE = 1, /* If radio did not start or is resetting */
132 RIL_E_GENERIC_FAILURE = 2,
133 RIL_E_PASSWORD_INCORRECT = 3, /* for PIN/PIN2 methods only! */
134 RIL_E_SIM_PIN2 = 4, /* Operation requires SIM PIN2 to be entered */
135 RIL_E_SIM_PUK2 = 5, /* Operation requires SIM PIN2 to be entered */
136 RIL_E_REQUEST_NOT_SUPPORTED = 6,
137 RIL_E_CANCELLED = 7,
138 RIL_E_OP_NOT_ALLOWED_DURING_VOICE_CALL = 8, /* data ops are not allowed during voice
139 call on a Class C GPRS device */
140 RIL_E_OP_NOT_ALLOWED_BEFORE_REG_TO_NW = 9, /* data ops are not allowed before device
141 registers in network */
Wink Saville3d54e742009-05-18 18:00:44 -0700142 RIL_E_SMS_SEND_FAIL_RETRY = 10, /* fail to send sms and need retry */
143 RIL_E_SIM_ABSENT = 11, /* fail to set the location where CDMA subscription
144 shall be retrieved because of SIM or RUIM
Wink Savillef4c4d362009-04-02 01:37:03 -0700145 card absent */
Wink Saville3d54e742009-05-18 18:00:44 -0700146 RIL_E_SUBSCRIPTION_NOT_AVAILABLE = 12, /* fail to find CDMA subscription from specified
Wink Savillef4c4d362009-04-02 01:37:03 -0700147 location */
jsh602f80f2009-07-10 15:44:37 -0700148 RIL_E_MODE_NOT_SUPPORTED = 13, /* HW does not support preferred network type */
John Wang75534472010-04-20 15:11:42 -0700149 RIL_E_FDN_CHECK_FAILURE = 14, /* command failed because recipient is not on FDN list */
Shishir Agrawal2458d8d2013-11-27 14:53:05 -0800150 RIL_E_ILLEGAL_SIM_OR_ME = 15, /* network selection failed due to
John Wang75534472010-04-20 15:11:42 -0700151 illegal SIM or ME */
Shishir Agrawal2458d8d2013-11-27 14:53:05 -0800152 RIL_E_MISSING_RESOURCE = 16, /* no logical channel available */
Amit Mahajan54563d32014-11-22 00:54:49 +0000153 RIL_E_NO_SUCH_ELEMENT = 17, /* application not found on SIM */
154 RIL_E_DIAL_MODIFIED_TO_USSD = 18, /* DIAL request modified to USSD */
155 RIL_E_DIAL_MODIFIED_TO_SS = 19, /* DIAL request modified to SS */
156 RIL_E_DIAL_MODIFIED_TO_DIAL = 20, /* DIAL request modified to DIAL with different
157 data */
158 RIL_E_USSD_MODIFIED_TO_DIAL = 21, /* USSD request modified to DIAL */
159 RIL_E_USSD_MODIFIED_TO_SS = 22, /* USSD request modified to SS */
160 RIL_E_USSD_MODIFIED_TO_USSD = 23, /* USSD request modified to different USSD
161 request */
162 RIL_E_SS_MODIFIED_TO_DIAL = 24, /* SS request modified to DIAL */
163 RIL_E_SS_MODIFIED_TO_USSD = 25, /* SS request modified to USSD */
164 RIL_E_SUBSCRIPTION_NOT_SUPPORTED = 26, /* Subscription not supported by RIL */
fengluf7408292015-04-14 14:53:55 -0700165 RIL_E_SS_MODIFIED_TO_SS = 27, /* SS request modified to different SS request */
Sooraj Sasindran7e333b32016-01-27 14:30:45 -0800166 RIL_E_LCE_NOT_SUPPORTED = 36, /* LCE service not supported(36 in RILConstants.java) */
167 RIL_E_NO_MEMORY = 37, /* Not sufficient memory to process the request */
Jayachandran Cb0cba832017-03-13 19:17:18 -0700168 RIL_E_INTERNAL_ERR = 38, /* Modem hit unexpected error scenario while handling
169 this request */
Sooraj Sasindran7e333b32016-01-27 14:30:45 -0800170 RIL_E_SYSTEM_ERR = 39, /* Hit platform or system error */
Jayachandran Cb0cba832017-03-13 19:17:18 -0700171 RIL_E_MODEM_ERR = 40, /* Vendor RIL got unexpected or incorrect response
172 from modem for this request */
Ajay Nambi10345892016-03-19 09:02:28 -0700173 RIL_E_INVALID_STATE = 41, /* Unexpected request for the current state */
Sooraj Sasindran7e333b32016-01-27 14:30:45 -0800174 RIL_E_NO_RESOURCES = 42, /* Not sufficient resource to process the request */
175 RIL_E_SIM_ERR = 43, /* Received error from SIM card */
176 RIL_E_INVALID_ARGUMENTS = 44, /* Received invalid arguments in request */
177 RIL_E_INVALID_SIM_STATE = 45, /* Can not process the request in current SIM state */
178 RIL_E_INVALID_MODEM_STATE = 46, /* Can not process the request in current Modem state */
179 RIL_E_INVALID_CALL_ID = 47, /* Received invalid call id in request */
180 RIL_E_NO_SMS_TO_ACK = 48, /* ACK received when there is no SMS to ack */
Nathan Haroldc97b2842016-02-02 12:04:35 -0800181 RIL_E_NETWORK_ERR = 49, /* Received error from network */
Sanket Padawe0106aed2016-02-09 09:56:31 -0800182 RIL_E_REQUEST_RATE_LIMITED = 50, /* Operation denied due to overly-frequent requests */
twen.changdf7add02016-03-04 18:27:48 +0800183 RIL_E_SIM_BUSY = 51, /* SIM is busy */
184 RIL_E_SIM_FULL = 52, /* The target EF is full */
185 RIL_E_NETWORK_REJECT = 53, /* Request is rejected by network */
186 RIL_E_OPERATION_NOT_ALLOWED = 54, /* Not allowed the request now */
187 RIL_E_EMPTY_RECORD = 55, /* The request record is empty */
Ajay Nambi68900f52016-03-11 12:02:55 -0800188 RIL_E_INVALID_SMS_FORMAT = 56, /* Invalid sms format */
189 RIL_E_ENCODING_ERR = 57, /* Message not encoded properly */
190 RIL_E_INVALID_SMSC_ADDRESS = 58, /* SMSC address specified is invalid */
191 RIL_E_NO_SUCH_ENTRY = 59, /* No such entry present to perform the request */
192 RIL_E_NETWORK_NOT_READY = 60, /* Network is not ready to perform the request */
193 RIL_E_NOT_PROVISIONED = 61, /* Device doesnot have this value provisioned */
Ajay Nambi10345892016-03-19 09:02:28 -0700194 RIL_E_NO_SUBSCRIPTION = 62, /* Device doesnot have subscription */
195 RIL_E_NO_NETWORK_FOUND = 63, /* Network cannot be found */
196 RIL_E_DEVICE_IN_USE = 64, /* Operation cannot be performed because the device
197 is currently in use */
198 RIL_E_ABORTED = 65, /* Operation aborted */
Sanket Padawe85f952a2017-01-02 23:46:00 -0800199 RIL_E_INVALID_RESPONSE = 66, /* Invalid response sent by vendor code */
Sanket Padawe0106aed2016-02-09 09:56:31 -0800200 // OEM specific error codes. To be used by OEM when they don't want to reveal
201 // specific error codes which would be replaced by Generic failure.
202 RIL_E_OEM_ERROR_1 = 501,
203 RIL_E_OEM_ERROR_2 = 502,
204 RIL_E_OEM_ERROR_3 = 503,
205 RIL_E_OEM_ERROR_4 = 504,
206 RIL_E_OEM_ERROR_5 = 505,
207 RIL_E_OEM_ERROR_6 = 506,
208 RIL_E_OEM_ERROR_7 = 507,
209 RIL_E_OEM_ERROR_8 = 508,
210 RIL_E_OEM_ERROR_9 = 509,
211 RIL_E_OEM_ERROR_10 = 510,
212 RIL_E_OEM_ERROR_11 = 511,
213 RIL_E_OEM_ERROR_12 = 512,
214 RIL_E_OEM_ERROR_13 = 513,
215 RIL_E_OEM_ERROR_14 = 514,
216 RIL_E_OEM_ERROR_15 = 515,
217 RIL_E_OEM_ERROR_16 = 516,
218 RIL_E_OEM_ERROR_17 = 517,
219 RIL_E_OEM_ERROR_18 = 518,
220 RIL_E_OEM_ERROR_19 = 519,
221 RIL_E_OEM_ERROR_20 = 520,
222 RIL_E_OEM_ERROR_21 = 521,
223 RIL_E_OEM_ERROR_22 = 522,
224 RIL_E_OEM_ERROR_23 = 523,
225 RIL_E_OEM_ERROR_24 = 524,
226 RIL_E_OEM_ERROR_25 = 525
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800227} RIL_Errno;
228
229typedef enum {
230 RIL_CALL_ACTIVE = 0,
231 RIL_CALL_HOLDING = 1,
232 RIL_CALL_DIALING = 2, /* MO call only */
233 RIL_CALL_ALERTING = 3, /* MO call only */
234 RIL_CALL_INCOMING = 4, /* MT call only */
235 RIL_CALL_WAITING = 5 /* MT call only */
236} RIL_CallState;
237
238typedef enum {
Wink Savillef4c4d362009-04-02 01:37:03 -0700239 RADIO_STATE_OFF = 0, /* Radio explictly powered off (eg CFUN=0) */
240 RADIO_STATE_UNAVAILABLE = 1, /* Radio unavailable (eg, resetting or not booted) */
Naveen Kalla2bc78d62011-12-07 16:22:53 -0800241 RADIO_STATE_ON = 10 /* Radio is on */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800242} RIL_RadioState;
243
Wink Saville43808972011-01-13 17:39:51 -0800244typedef enum {
245 RADIO_TECH_UNKNOWN = 0,
246 RADIO_TECH_GPRS = 1,
247 RADIO_TECH_EDGE = 2,
248 RADIO_TECH_UMTS = 3,
249 RADIO_TECH_IS95A = 4,
250 RADIO_TECH_IS95B = 5,
251 RADIO_TECH_1xRTT = 6,
252 RADIO_TECH_EVDO_0 = 7,
253 RADIO_TECH_EVDO_A = 8,
254 RADIO_TECH_HSDPA = 9,
255 RADIO_TECH_HSUPA = 10,
256 RADIO_TECH_HSPA = 11,
257 RADIO_TECH_EVDO_B = 12,
258 RADIO_TECH_EHRPD = 13,
Glenn Kastenc9419612011-02-02 17:44:18 -0800259 RADIO_TECH_LTE = 14,
Naveen Kalla2bc78d62011-12-07 16:22:53 -0800260 RADIO_TECH_HSPAP = 15, // HSPA+
Etan Cohend3652192014-06-20 08:28:44 -0700261 RADIO_TECH_GSM = 16, // Only supports voice
Yashdev Singh3c8f37c2015-02-23 13:04:28 -0800262 RADIO_TECH_TD_SCDMA = 17,
Ajay Nambi6dbb43c2015-05-14 18:50:20 -0700263 RADIO_TECH_IWLAN = 18,
264 RADIO_TECH_LTE_CA = 19
Wink Saville43808972011-01-13 17:39:51 -0800265} RIL_RadioTechnology;
266
Wink Saville8b4e4f72014-10-17 15:01:45 -0700267typedef enum {
268 RAF_UNKNOWN = (1 << RADIO_TECH_UNKNOWN),
269 RAF_GPRS = (1 << RADIO_TECH_GPRS),
270 RAF_EDGE = (1 << RADIO_TECH_EDGE),
271 RAF_UMTS = (1 << RADIO_TECH_UMTS),
272 RAF_IS95A = (1 << RADIO_TECH_IS95A),
273 RAF_IS95B = (1 << RADIO_TECH_IS95B),
274 RAF_1xRTT = (1 << RADIO_TECH_1xRTT),
275 RAF_EVDO_0 = (1 << RADIO_TECH_EVDO_0),
276 RAF_EVDO_A = (1 << RADIO_TECH_EVDO_A),
277 RAF_HSDPA = (1 << RADIO_TECH_HSDPA),
278 RAF_HSUPA = (1 << RADIO_TECH_HSUPA),
279 RAF_HSPA = (1 << RADIO_TECH_HSPA),
280 RAF_EVDO_B = (1 << RADIO_TECH_EVDO_B),
281 RAF_EHRPD = (1 << RADIO_TECH_EHRPD),
282 RAF_LTE = (1 << RADIO_TECH_LTE),
283 RAF_HSPAP = (1 << RADIO_TECH_HSPAP),
284 RAF_GSM = (1 << RADIO_TECH_GSM),
285 RAF_TD_SCDMA = (1 << RADIO_TECH_TD_SCDMA),
Ajay Nambi6dbb43c2015-05-14 18:50:20 -0700286 RAF_LTE_CA = (1 << RADIO_TECH_LTE_CA)
Wink Saville8b4e4f72014-10-17 15:01:45 -0700287} RIL_RadioAccessFamily;
288
289typedef enum {
Nathan Harold92839f12016-02-12 10:02:28 -0800290 BAND_MODE_UNSPECIFIED = 0, //"unspecified" (selected by baseband automatically)
291 BAND_MODE_EURO = 1, //"EURO band" (GSM-900 / DCS-1800 / WCDMA-IMT-2000)
292 BAND_MODE_USA = 2, //"US band" (GSM-850 / PCS-1900 / WCDMA-850 / WCDMA-PCS-1900)
293 BAND_MODE_JPN = 3, //"JPN band" (WCDMA-800 / WCDMA-IMT-2000)
294 BAND_MODE_AUS = 4, //"AUS band" (GSM-900 / DCS-1800 / WCDMA-850 / WCDMA-IMT-2000)
295 BAND_MODE_AUS_2 = 5, //"AUS band 2" (GSM-900 / DCS-1800 / WCDMA-850)
296 BAND_MODE_CELL_800 = 6, //"Cellular" (800-MHz Band)
297 BAND_MODE_PCS = 7, //"PCS" (1900-MHz Band)
298 BAND_MODE_JTACS = 8, //"Band Class 3" (JTACS Band)
299 BAND_MODE_KOREA_PCS = 9, //"Band Class 4" (Korean PCS Band)
300 BAND_MODE_5_450M = 10, //"Band Class 5" (450-MHz Band)
301 BAND_MODE_IMT2000 = 11, //"Band Class 6" (2-GMHz IMT2000 Band)
302 BAND_MODE_7_700M_2 = 12, //"Band Class 7" (Upper 700-MHz Band)
303 BAND_MODE_8_1800M = 13, //"Band Class 8" (1800-MHz Band)
304 BAND_MODE_9_900M = 14, //"Band Class 9" (900-MHz Band)
305 BAND_MODE_10_800M_2 = 15, //"Band Class 10" (Secondary 800-MHz Band)
306 BAND_MODE_EURO_PAMR_400M = 16, //"Band Class 11" (400-MHz European PAMR Band)
307 BAND_MODE_AWS = 17, //"Band Class 15" (AWS Band)
308 BAND_MODE_USA_2500M = 18 //"Band Class 16" (US 2.5-GHz Band)
309} RIL_RadioBandMode;
310
311typedef enum {
Wink Saville8b4e4f72014-10-17 15:01:45 -0700312 RC_PHASE_CONFIGURED = 0, // LM is configured is initial value and value after FINISH completes
313 RC_PHASE_START = 1, // START is sent before Apply and indicates that an APPLY will be
314 // forthcoming with these same parameters
315 RC_PHASE_APPLY = 2, // APPLY is sent after all LM's receive START and returned
316 // RIL_RadioCapability.status = 0, if any START's fail no
317 // APPLY will be sent
318 RC_PHASE_UNSOL_RSP = 3, // UNSOL_RSP is sent with RIL_UNSOL_RADIO_CAPABILITY
319 RC_PHASE_FINISH = 4 // FINISH is sent after all commands have completed. If an error
320 // occurs in any previous command the RIL_RadioAccessesFamily and
Legler Wu8caf06f2014-10-29 14:02:14 +0800321 // logicalModemUuid fields will be the prior configuration thus
Wink Saville8b4e4f72014-10-17 15:01:45 -0700322 // restoring the configuration to the previous value. An error
323 // returned by this command will generally be ignored or may
324 // cause that logical modem to be removed from service.
325} RadioCapabilityPhase;
326
327typedef enum {
328 RC_STATUS_NONE = 0, // This parameter has no meaning with RC_PHASE_START,
329 // RC_PHASE_APPLY
330 RC_STATUS_SUCCESS = 1, // Tell modem the action transaction of set radio
331 // capability was success with RC_PHASE_FINISH
332 RC_STATUS_FAIL = 2, // Tell modem the action transaction of set radio
333 // capability is fail with RC_PHASE_FINISH.
334} RadioCapabilityStatus;
335
336#define RIL_RADIO_CAPABILITY_VERSION 1
337typedef struct {
Legler Wu8caf06f2014-10-29 14:02:14 +0800338 int version; // Version of structure, RIL_RADIO_CAPABILITY_VERSION
Wink Saville8b4e4f72014-10-17 15:01:45 -0700339 int session; // Unique session value defined by framework returned in all "responses/unsol"
340 int phase; // CONFIGURED, START, APPLY, FINISH
341 int rat; // RIL_RadioAccessFamily for the radio
342 char logicalModemUuid[MAX_UUID_LENGTH]; // A UUID typically "com.xxxx.lmX where X is the logical modem.
343 int status; // Return status and an input parameter for RC_PHASE_FINISH
344} RIL_RadioCapability;
345
Wink Savillec0114b32011-02-18 10:14:07 -0800346// Do we want to split Data from Voice and the use
347// RIL_RadioTechnology for get/setPreferredVoice/Data ?
348typedef enum {
349 PREF_NET_TYPE_GSM_WCDMA = 0, /* GSM/WCDMA (WCDMA preferred) */
350 PREF_NET_TYPE_GSM_ONLY = 1, /* GSM only */
351 PREF_NET_TYPE_WCDMA = 2, /* WCDMA */
352 PREF_NET_TYPE_GSM_WCDMA_AUTO = 3, /* GSM/WCDMA (auto mode, according to PRL) */
353 PREF_NET_TYPE_CDMA_EVDO_AUTO = 4, /* CDMA and EvDo (auto mode, according to PRL) */
354 PREF_NET_TYPE_CDMA_ONLY = 5, /* CDMA only */
355 PREF_NET_TYPE_EVDO_ONLY = 6, /* EvDo only */
356 PREF_NET_TYPE_GSM_WCDMA_CDMA_EVDO_AUTO = 7, /* GSM/WCDMA, CDMA, and EvDo (auto mode, according to PRL) */
357 PREF_NET_TYPE_LTE_CDMA_EVDO = 8, /* LTE, CDMA and EvDo */
358 PREF_NET_TYPE_LTE_GSM_WCDMA = 9, /* LTE, GSM/WCDMA */
359 PREF_NET_TYPE_LTE_CMDA_EVDO_GSM_WCDMA = 10, /* LTE, CDMA, EvDo, GSM/WCDMA */
Uma Maheswari Ramalingam0e094872011-09-28 13:25:48 -0700360 PREF_NET_TYPE_LTE_ONLY = 11, /* LTE only */
Rakesh Pallerla8c20ebe2015-03-31 14:52:49 -0700361 PREF_NET_TYPE_LTE_WCDMA = 12, /* LTE/WCDMA */
362 PREF_NET_TYPE_TD_SCDMA_ONLY = 13, /* TD-SCDMA only */
363 PREF_NET_TYPE_TD_SCDMA_WCDMA = 14, /* TD-SCDMA and WCDMA */
364 PREF_NET_TYPE_TD_SCDMA_LTE = 15, /* TD-SCDMA and LTE */
365 PREF_NET_TYPE_TD_SCDMA_GSM = 16, /* TD-SCDMA and GSM */
366 PREF_NET_TYPE_TD_SCDMA_GSM_LTE = 17, /* TD-SCDMA,GSM and LTE */
367 PREF_NET_TYPE_TD_SCDMA_GSM_WCDMA = 18, /* TD-SCDMA, GSM/WCDMA */
368 PREF_NET_TYPE_TD_SCDMA_WCDMA_LTE = 19, /* TD-SCDMA, WCDMA and LTE */
369 PREF_NET_TYPE_TD_SCDMA_GSM_WCDMA_LTE = 20, /* TD-SCDMA, GSM/WCDMA and LTE */
370 PREF_NET_TYPE_TD_SCDMA_GSM_WCDMA_CDMA_EVDO_AUTO = 21, /* TD-SCDMA, GSM/WCDMA, CDMA and EvDo */
371 PREF_NET_TYPE_TD_SCDMA_LTE_CDMA_EVDO_GSM_WCDMA = 22 /* TD-SCDMA, LTE, CDMA, EvDo GSM/WCDMA */
Wink Savillec0114b32011-02-18 10:14:07 -0800372} RIL_PreferredNetworkType;
373
374/* Source for cdma subscription */
375typedef enum {
376 CDMA_SUBSCRIPTION_SOURCE_RUIM_SIM = 0,
377 CDMA_SUBSCRIPTION_SOURCE_NV = 1
378} RIL_CdmaSubscriptionSource;
379
Wink Saville74fa3882009-12-22 15:35:41 -0800380/* User-to-User signaling Info activation types derived from 3GPP 23.087 v8.0 */
381typedef enum {
382 RIL_UUS_TYPE1_IMPLICIT = 0,
383 RIL_UUS_TYPE1_REQUIRED = 1,
384 RIL_UUS_TYPE1_NOT_REQUIRED = 2,
385 RIL_UUS_TYPE2_REQUIRED = 3,
386 RIL_UUS_TYPE2_NOT_REQUIRED = 4,
387 RIL_UUS_TYPE3_REQUIRED = 5,
388 RIL_UUS_TYPE3_NOT_REQUIRED = 6
389} RIL_UUS_Type;
390
391/* User-to-User Signaling Information data coding schemes. Possible values for
392 * Octet 3 (Protocol Discriminator field) in the UUIE. The values have been
393 * specified in section 10.5.4.25 of 3GPP TS 24.008 */
394typedef enum {
395 RIL_UUS_DCS_USP = 0, /* User specified protocol */
396 RIL_UUS_DCS_OSIHLP = 1, /* OSI higher layer protocol */
397 RIL_UUS_DCS_X244 = 2, /* X.244 */
398 RIL_UUS_DCS_RMCF = 3, /* Reserved for system mangement
399 convergence function */
400 RIL_UUS_DCS_IA5c = 4 /* IA5 characters */
401} RIL_UUS_DCS;
402
403/* User-to-User Signaling Information defined in 3GPP 23.087 v8.0
404 * This data is passed in RIL_ExtensionRecord and rec contains this
405 * structure when type is RIL_UUS_INFO_EXT_REC */
406typedef struct {
407 RIL_UUS_Type uusType; /* UUS Type */
408 RIL_UUS_DCS uusDcs; /* UUS Data Coding Scheme */
409 int uusLength; /* Length of UUS Data */
410 char * uusData; /* UUS Data */
411} RIL_UUS_Info;
412
413/* CDMA Signal Information Record as defined in C.S0005 section 3.7.5.5 */
Wink Saville1b5fd232009-04-22 14:50:00 -0700414typedef struct {
415 char isPresent; /* non-zero if signal information record is present */
416 char signalType; /* as defined 3.7.5.5-1 */
417 char alertPitch; /* as defined 3.7.5.5-2 */
418 char signal; /* as defined 3.7.5.5-3, 3.7.5.5-4 or 3.7.5.5-5 */
419} RIL_CDMA_SignalInfoRecord;
420
Wink Saville1b5fd232009-04-22 14:50:00 -0700421typedef struct {
422 RIL_CallState state;
423 int index; /* Connection Index for use with, eg, AT+CHLD */
424 int toa; /* type of address, eg 145 = intl */
425 char isMpty; /* nonzero if is mpty call */
426 char isMT; /* nonzero if call is mobile terminated */
427 char als; /* ALS line indicator if available
428 (0 = line 1) */
429 char isVoice; /* nonzero if this is is a voice call */
430 char isVoicePrivacy; /* nonzero if CDMA voice privacy mode is active */
431 char * number; /* Remote party number */
432 int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown 3=Payphone */
433 char * name; /* Remote party name */
434 int namePresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown 3=Payphone */
Wink Saville74fa3882009-12-22 15:35:41 -0800435 RIL_UUS_Info * uusInfo; /* NULL or Pointer to User-User Signaling Information */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800436} RIL_Call;
437
Wink Savillec0114b32011-02-18 10:14:07 -0800438/* Deprecated, use RIL_Data_Call_Response_v6 */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800439typedef struct {
Wink Saville43808972011-01-13 17:39:51 -0800440 int cid; /* Context ID, uniquely identifies this call */
Wink Saville1b5fd232009-04-22 14:50:00 -0700441 int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */
Lorenzo Colitti4f81dcf2010-09-01 19:38:57 -0700442 char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1.
443 For example, "IP", "IPV6", "IPV4V6", or "PPP". */
Wink Saville43808972011-01-13 17:39:51 -0800444 char * apn; /* ignored */
Wink Savillec0114b32011-02-18 10:14:07 -0800445 char * address; /* An address, e.g., "192.0.1.3" or "2001:db8::1". */
446} RIL_Data_Call_Response_v4;
Wink Saville43808972011-01-13 17:39:51 -0800447
448/*
449 * Returned by RIL_REQUEST_SETUP_DATA_CALL, RIL_REQUEST_DATA_CALL_LIST
450 * and RIL_UNSOL_DATA_CALL_LIST_CHANGED, on error status != 0.
451 */
452typedef struct {
453 int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */
Kazuhiro Ondobeb25b52011-06-17 16:26:45 -0500454 int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry
455 back-off timer value RIL wants to override the one
456 pre-configured in FW.
457 The unit is miliseconds.
458 The value < 0 means no value is suggested.
Kazuhiro Ondo16157582011-07-24 07:56:32 -0700459 The value 0 means retry should be done ASAP.
Wink Saville8a9e0212013-04-09 12:11:38 -0700460 The value of INT_MAX(0x7fffffff) means no retry. */
Wink Saville43808972011-01-13 17:39:51 -0800461 int cid; /* Context ID, uniquely identifies this call */
462 int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */
463 char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1.
464 For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is
465 PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported
466 such as "IP" or "IPV6" */
467 char * ifname; /* The network interface name */
Wink Savillec0114b32011-02-18 10:14:07 -0800468 char * addresses; /* A space-delimited list of addresses with optional "/" prefix length,
469 e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64".
Wink Saville43808972011-01-13 17:39:51 -0800470 May not be empty, typically 1 IPv4 or 1 IPv6 or
Wink Savillec0114b32011-02-18 10:14:07 -0800471 one of each. If the prefix length is absent the addresses
472 are assumed to be point to point with IPv4 having a prefix
473 length of 32 and IPv6 128. */
Wink Saville43808972011-01-13 17:39:51 -0800474 char * dnses; /* A space-delimited list of DNS server addresses,
475 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
476 May be empty. */
Wink Savillec0114b32011-02-18 10:14:07 -0800477 char * gateways; /* A space-delimited list of default gateway addresses,
478 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
479 May be empty in which case the addresses represent point
480 to point connections. */
481} RIL_Data_Call_Response_v6;
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800482
Etan Cohend3652192014-06-20 08:28:44 -0700483typedef struct {
484 int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */
485 int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry
486 back-off timer value RIL wants to override the one
487 pre-configured in FW.
488 The unit is miliseconds.
489 The value < 0 means no value is suggested.
490 The value 0 means retry should be done ASAP.
491 The value of INT_MAX(0x7fffffff) means no retry. */
492 int cid; /* Context ID, uniquely identifies this call */
493 int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */
494 char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1.
495 For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is
496 PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported
497 such as "IP" or "IPV6" */
498 char * ifname; /* The network interface name */
499 char * addresses; /* A space-delimited list of addresses with optional "/" prefix length,
500 e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64".
501 May not be empty, typically 1 IPv4 or 1 IPv6 or
502 one of each. If the prefix length is absent the addresses
503 are assumed to be point to point with IPv4 having a prefix
504 length of 32 and IPv6 128. */
505 char * dnses; /* A space-delimited list of DNS server addresses,
506 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
507 May be empty. */
508 char * gateways; /* A space-delimited list of default gateway addresses,
509 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
510 May be empty in which case the addresses represent point
511 to point connections. */
512 char * pcscf; /* the Proxy Call State Control Function address
513 via PCO(Protocol Configuration Option) for IMS client. */
Sukanya Rajkhowab44dda32014-06-02 14:03:44 -0700514} RIL_Data_Call_Response_v9;
515
516typedef struct {
517 int status; /* A RIL_DataCallFailCause, 0 which is PDP_FAIL_NONE if no error */
518 int suggestedRetryTime; /* If status != 0, this fields indicates the suggested retry
519 back-off timer value RIL wants to override the one
520 pre-configured in FW.
521 The unit is miliseconds.
522 The value < 0 means no value is suggested.
523 The value 0 means retry should be done ASAP.
524 The value of INT_MAX(0x7fffffff) means no retry. */
525 int cid; /* Context ID, uniquely identifies this call */
526 int active; /* 0=inactive, 1=active/physical link down, 2=active/physical link up */
527 char * type; /* One of the PDP_type values in TS 27.007 section 10.1.1.
528 For example, "IP", "IPV6", "IPV4V6", or "PPP". If status is
529 PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED this is the type supported
530 such as "IP" or "IPV6" */
531 char * ifname; /* The network interface name */
532 char * addresses; /* A space-delimited list of addresses with optional "/" prefix length,
533 e.g., "192.0.1.3" or "192.0.1.11/16 2001:db8::1/64".
534 May not be empty, typically 1 IPv4 or 1 IPv6 or
535 one of each. If the prefix length is absent the addresses
536 are assumed to be point to point with IPv4 having a prefix
537 length of 32 and IPv6 128. */
538 char * dnses; /* A space-delimited list of DNS server addresses,
539 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
540 May be empty. */
541 char * gateways; /* A space-delimited list of default gateway addresses,
542 e.g., "192.0.1.3" or "192.0.1.11 2001:db8::1".
543 May be empty in which case the addresses represent point
544 to point connections. */
545 char * pcscf; /* the Proxy Call State Control Function address
546 via PCO(Protocol Configuration Option) for IMS client. */
547 int mtu; /* MTU received from network
548 Value <= 0 means network has either not sent a value or
549 sent an invalid value */
550} RIL_Data_Call_Response_v11;
Etan Cohend3652192014-06-20 08:28:44 -0700551
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -0700552typedef enum {
553 RADIO_TECH_3GPP = 1, /* 3GPP Technologies - GSM, WCDMA */
554 RADIO_TECH_3GPP2 = 2 /* 3GPP2 Technologies - CDMA */
555} RIL_RadioTechnologyFamily;
556
557typedef struct {
558 RIL_RadioTechnologyFamily tech;
559 unsigned char retry; /* 0 == not retry, nonzero == retry */
560 int messageRef; /* Valid field if retry is set to nonzero.
561 Contains messageRef from RIL_SMS_Response
562 corresponding to failed MO SMS.
563 */
564
565 union {
566 /* Valid field if tech is RADIO_TECH_3GPP2. See RIL_REQUEST_CDMA_SEND_SMS */
567 RIL_CDMA_SMS_Message* cdmaMessage;
568
569 /* Valid field if tech is RADIO_TECH_3GPP. See RIL_REQUEST_SEND_SMS */
Sanket Padawe05c23072016-08-08 15:42:17 -0700570 char** gsmMessage; /* This is an array of pointers where pointers
571 are contiguous but elements pointed by those pointers
572 are not contiguous
573 */
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -0700574 } message;
575} RIL_IMS_SMS_Message;
576
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800577typedef struct {
Tammo Spalink8e3a2ca2009-09-11 11:26:30 +0800578 int messageRef; /* TP-Message-Reference for GSM,
579 and BearerData MessageId for CDMA
580 (See 3GPP2 C.S0015-B, v2.0, table 4.5-1). */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800581 char *ackPDU; /* or NULL if n/a */
Jaikumar Ganesh920c78f2009-06-04 10:53:15 -0700582 int errorCode; /* See 3GPP 27.005, 3.2.5 for GSM/UMTS,
583 3GPP2 N.S0005 (IS-41C) Table 171 for CDMA,
584 -1 if unknown or not applicable*/
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800585} RIL_SMS_Response;
586
587/** Used by RIL_REQUEST_WRITE_SMS_TO_SIM */
588typedef struct {
589 int status; /* Status of message. See TS 27.005 3.1, "<stat>": */
590 /* 0 = "REC UNREAD" */
591 /* 1 = "REC READ" */
592 /* 2 = "STO UNSENT" */
593 /* 3 = "STO SENT" */
johnwangf8bc1672009-05-14 19:19:47 -0700594 char * pdu; /* PDU of message to write, as an ASCII hex string less the SMSC address,
595 the TP-layer length is "strlen(pdu)/2". */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800596 char * smsc; /* SMSC address in GSM BCD format prefixed by a length byte
597 (as expected by TS 27.005) or NULL for default SMSC */
598} RIL_SMS_WriteArgs;
599
600/** Used by RIL_REQUEST_DIAL */
601typedef struct {
602 char * address;
603 int clir;
604 /* (same as 'n' paremeter in TS 27.007 7.7 "+CLIR"
605 * clir == 0 on "use subscription default value"
606 * clir == 1 on "CLIR invocation" (restrict CLI presentation)
607 * clir == 2 on "CLIR suppression" (allow CLI presentation)
608 */
Wink Saville74fa3882009-12-22 15:35:41 -0800609 RIL_UUS_Info * uusInfo; /* NULL or Pointer to User-User Signaling Information */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800610} RIL_Dial;
611
612typedef struct {
613 int command; /* one of the commands listed for TS 27.007 +CRSM*/
614 int fileid; /* EF id */
615 char *path; /* "pathid" from TS 27.007 +CRSM command.
616 Path is in hex asciii format eg "7f205f70"
Wink Saville1b5fd232009-04-22 14:50:00 -0700617 Path must always be provided.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800618 */
619 int p1;
620 int p2;
621 int p3;
622 char *data; /* May be NULL*/
623 char *pin2; /* May be NULL*/
Wink Savillec0114b32011-02-18 10:14:07 -0800624} RIL_SIM_IO_v5;
625
626typedef struct {
627 int command; /* one of the commands listed for TS 27.007 +CRSM*/
628 int fileid; /* EF id */
629 char *path; /* "pathid" from TS 27.007 +CRSM command.
630 Path is in hex asciii format eg "7f205f70"
631 Path must always be provided.
632 */
633 int p1;
634 int p2;
635 int p3;
636 char *data; /* May be NULL*/
637 char *pin2; /* May be NULL*/
638 char *aidPtr; /* AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value. */
639} RIL_SIM_IO_v6;
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800640
Shishir Agrawal2458d8d2013-11-27 14:53:05 -0800641/* Used by RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL and
642 * RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC. */
643typedef struct {
644 int sessionid; /* "sessionid" from TS 27.007 +CGLA command. Should be
645 ignored for +CSIM command. */
646
647 /* Following fields are used to derive the APDU ("command" and "length"
648 values in TS 27.007 +CSIM and +CGLA commands). */
649 int cla;
650 int instruction;
651 int p1;
652 int p2;
653 int p3; /* A negative P3 implies a 4 byte APDU. */
654 char *data; /* May be NULL. In hex string format. */
655} RIL_SIM_APDU;
656
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800657typedef struct {
658 int sw1;
659 int sw2;
Amit Mahajan2875bc22014-08-06 10:03:15 -0700660 char *simResponse; /* In hex string format ([a-fA-F0-9]*), except for SIM_AUTHENTICATION
661 response for which it is in Base64 format, see 3GPP TS 31.102 7.1.2 */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800662} RIL_SIM_IO_Response;
663
664/* See also com.android.internal.telephony.gsm.CallForwardInfo */
665
666typedef struct {
667 int status; /*
668 * For RIL_REQUEST_QUERY_CALL_FORWARD_STATUS
669 * status 1 = active, 0 = not active
670 *
671 * For RIL_REQUEST_SET_CALL_FORWARD:
672 * status is:
673 * 0 = disable
674 * 1 = enable
675 * 2 = interrogate
676 * 3 = registeration
677 * 4 = erasure
678 */
679
Wink Saville3d54e742009-05-18 18:00:44 -0700680 int reason; /* from TS 27.007 7.11 "reason" */
681 int serviceClass;/* From 27.007 +CCFC/+CLCK "class"
682 See table for Android mapping from
683 MMI service code
684 0 means user doesn't input class */
685 int toa; /* "type" from TS 27.007 7.11 */
686 char * number; /* "number" from TS 27.007 7.11. May be NULL */
687 int timeSeconds; /* for CF no reply only */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800688}RIL_CallForwardInfo;
689
690typedef struct {
johnwange0ba6a92009-09-11 19:14:52 -0700691 char * cid; /* Combination of LAC and Cell Id in 32 bits in GSM.
692 * Upper 16 bits is LAC and lower 16 bits
693 * is CID (as described in TS 27.005)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800694 * Primary Scrambling Code (as described in TS 25.331)
Wink Saville7f856802009-06-09 10:23:37 -0700695 * in 9 bits in UMTS
johnwange0ba6a92009-09-11 19:14:52 -0700696 * Valid values are hexadecimal 0x0000 - 0xffffffff.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800697 */
johnwange0ba6a92009-09-11 19:14:52 -0700698 int rssi; /* Received RSSI in GSM,
699 * Level index of CPICH Received Signal Code Power in UMTS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800700 */
701} RIL_NeighboringCell;
702
fengluf7408292015-04-14 14:53:55 -0700703typedef struct {
704 char lce_status; /* LCE service status:
705 * -1 = not supported;
706 * 0 = stopped;
707 * 1 = active.
708 */
709 unsigned int actual_interval_ms; /* actual LCE reporting interval,
710 * meaningful only if LCEStatus = 1.
711 */
712} RIL_LceStatusInfo;
713
714typedef struct {
fenglu290add32015-05-01 17:05:15 -0700715 unsigned int last_hop_capacity_kbps; /* last-hop cellular capacity: kilobits/second. */
fengluf7408292015-04-14 14:53:55 -0700716 unsigned char confidence_level; /* capacity estimate confidence: 0-100 */
717 unsigned char lce_suspended; /* LCE report going to be suspended? (e.g., radio
718 * moves to inactive state or network type change)
719 * 1 = suspended;
720 * 0 = not suspended.
721 */
722} RIL_LceDataInfo;
723
Meng Wangb4e34312016-05-12 14:54:36 -0700724typedef enum {
725 RIL_MATCH_ALL = 0, /* Apply to all carriers with the same mcc/mnc */
726 RIL_MATCH_SPN = 1, /* Use SPN and mcc/mnc to identify the carrier */
727 RIL_MATCH_IMSI_PREFIX = 2, /* Use IMSI prefix and mcc/mnc to identify the carrier */
728 RIL_MATCH_GID1 = 3, /* Use GID1 and mcc/mnc to identify the carrier */
729 RIL_MATCH_GID2 = 4, /* Use GID2 and mcc/mnc to identify the carrier */
730} RIL_CarrierMatchType;
731
732typedef struct {
733 const char * mcc;
734 const char * mnc;
735 RIL_CarrierMatchType match_type; /* Specify match type for the carrier.
736 * If it’s RIL_MATCH_ALL, match_data is null;
737 * otherwise, match_data is the value for the match type.
738 */
739 const char * match_data;
740} RIL_Carrier;
741
742typedef struct {
743 int32_t len_allowed_carriers; /* length of array allowed_carriers */
744 int32_t len_excluded_carriers; /* length of array excluded_carriers */
745 RIL_Carrier * allowed_carriers; /* whitelist for allowed carriers */
746 RIL_Carrier * excluded_carriers; /* blacklist for explicitly excluded carriers
747 * which match allowed_carriers. Eg. allowed_carriers match
748 * mcc/mnc, excluded_carriers has same mcc/mnc and gid1
749 * is ABCD. It means except the carrier whose gid1 is ABCD,
750 * all carriers with the same mcc/mnc are allowed.
751 */
752} RIL_CarrierRestrictions;
753
pkanwarc61837e2017-03-17 12:49:34 -0700754typedef struct {
pkanwarfb9166e2017-05-21 10:24:30 -0700755 char * mcc; /* MCC of the Carrier. */
756 char * mnc ; /* MNC of the Carrier. */
757 uint8_t * carrierKey; /* Public Key from the Carrier used to encrypt the
758 * IMSI/IMPI.
759 */
Youngrak Leee6f16f22017-12-03 10:50:37 -0800760 int32_t carrierKeyLength; /* Length of the Public Key. */
pkanwarfb9166e2017-05-21 10:24:30 -0700761 char * keyIdentifier; /* The keyIdentifier Attribute value pair that helps
762 * a server locate the private key to decrypt the
763 * permanent identity.
764 */
765 int64_t expirationTime; /* Date-Time (in UTC) when the key will expire. */
766
pkanwarc61837e2017-03-17 12:49:34 -0700767} RIL_CarrierInfoForImsiEncryption;
768
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800769/* See RIL_REQUEST_LAST_CALL_FAIL_CAUSE */
770typedef enum {
Naveen Kalla1b3a6fe2010-04-21 16:44:37 -0700771 CALL_FAIL_UNOBTAINABLE_NUMBER = 1,
Sooraj Sasindrand2102792014-09-12 17:00:03 +0800772 CALL_FAIL_NO_ROUTE_TO_DESTINATION = 3,
773 CALL_FAIL_CHANNEL_UNACCEPTABLE = 6,
774 CALL_FAIL_OPERATOR_DETERMINED_BARRING = 8,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800775 CALL_FAIL_NORMAL = 16,
776 CALL_FAIL_BUSY = 17,
Sooraj Sasindrand2102792014-09-12 17:00:03 +0800777 CALL_FAIL_NO_USER_RESPONDING = 18,
778 CALL_FAIL_NO_ANSWER_FROM_USER = 19,
779 CALL_FAIL_CALL_REJECTED = 21,
780 CALL_FAIL_NUMBER_CHANGED = 22,
781 CALL_FAIL_PREEMPTION = 25,
782 CALL_FAIL_DESTINATION_OUT_OF_ORDER = 27,
783 CALL_FAIL_INVALID_NUMBER_FORMAT = 28,
784 CALL_FAIL_FACILITY_REJECTED = 29,
785 CALL_FAIL_RESP_TO_STATUS_ENQUIRY = 30,
786 CALL_FAIL_NORMAL_UNSPECIFIED = 31,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800787 CALL_FAIL_CONGESTION = 34,
Sooraj Sasindrand2102792014-09-12 17:00:03 +0800788 CALL_FAIL_NETWORK_OUT_OF_ORDER = 38,
789 CALL_FAIL_TEMPORARY_FAILURE = 41,
790 CALL_FAIL_SWITCHING_EQUIPMENT_CONGESTION = 42,
791 CALL_FAIL_ACCESS_INFORMATION_DISCARDED = 43,
792 CALL_FAIL_REQUESTED_CIRCUIT_OR_CHANNEL_NOT_AVAILABLE = 44,
793 CALL_FAIL_RESOURCES_UNAVAILABLE_OR_UNSPECIFIED = 47,
794 CALL_FAIL_QOS_UNAVAILABLE = 49,
795 CALL_FAIL_REQUESTED_FACILITY_NOT_SUBSCRIBED = 50,
796 CALL_FAIL_INCOMING_CALLS_BARRED_WITHIN_CUG = 55,
797 CALL_FAIL_BEARER_CAPABILITY_NOT_AUTHORIZED = 57,
798 CALL_FAIL_BEARER_CAPABILITY_UNAVAILABLE = 58,
799 CALL_FAIL_SERVICE_OPTION_NOT_AVAILABLE = 63,
800 CALL_FAIL_BEARER_SERVICE_NOT_IMPLEMENTED = 65,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800801 CALL_FAIL_ACM_LIMIT_EXCEEDED = 68,
Sooraj Sasindrand2102792014-09-12 17:00:03 +0800802 CALL_FAIL_REQUESTED_FACILITY_NOT_IMPLEMENTED = 69,
803 CALL_FAIL_ONLY_DIGITAL_INFORMATION_BEARER_AVAILABLE = 70,
804 CALL_FAIL_SERVICE_OR_OPTION_NOT_IMPLEMENTED = 79,
805 CALL_FAIL_INVALID_TRANSACTION_IDENTIFIER = 81,
806 CALL_FAIL_USER_NOT_MEMBER_OF_CUG = 87,
807 CALL_FAIL_INCOMPATIBLE_DESTINATION = 88,
808 CALL_FAIL_INVALID_TRANSIT_NW_SELECTION = 91,
809 CALL_FAIL_SEMANTICALLY_INCORRECT_MESSAGE = 95,
810 CALL_FAIL_INVALID_MANDATORY_INFORMATION = 96,
811 CALL_FAIL_MESSAGE_TYPE_NON_IMPLEMENTED = 97,
812 CALL_FAIL_MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 98,
813 CALL_FAIL_INFORMATION_ELEMENT_NON_EXISTENT = 99,
814 CALL_FAIL_CONDITIONAL_IE_ERROR = 100,
815 CALL_FAIL_MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 101,
816 CALL_FAIL_RECOVERY_ON_TIMER_EXPIRED = 102,
817 CALL_FAIL_PROTOCOL_ERROR_UNSPECIFIED = 111,
818 CALL_FAIL_INTERWORKING_UNSPECIFIED = 127,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800819 CALL_FAIL_CALL_BARRED = 240,
820 CALL_FAIL_FDN_BLOCKED = 241,
jsh602f80f2009-07-10 15:44:37 -0700821 CALL_FAIL_IMSI_UNKNOWN_IN_VLR = 242,
822 CALL_FAIL_IMEI_NOT_ACCEPTED = 243,
Amit Mahajan54563d32014-11-22 00:54:49 +0000823 CALL_FAIL_DIAL_MODIFIED_TO_USSD = 244, /* STK Call Control */
824 CALL_FAIL_DIAL_MODIFIED_TO_SS = 245,
825 CALL_FAIL_DIAL_MODIFIED_TO_DIAL = 246,
Jayachandran Ccc2a2022017-03-07 09:55:58 -0800826 CALL_FAIL_RADIO_OFF = 247, /* Radio is OFF */
827 CALL_FAIL_OUT_OF_SERVICE = 248, /* No cellular coverage */
828 CALL_FAIL_NO_VALID_SIM = 249, /* No valid SIM is present */
829 CALL_FAIL_RADIO_INTERNAL_ERROR = 250, /* Internal error at Modem */
830 CALL_FAIL_NETWORK_RESP_TIMEOUT = 251, /* No response from network */
831 CALL_FAIL_NETWORK_REJECT = 252, /* Explicit network reject */
832 CALL_FAIL_RADIO_ACCESS_FAILURE = 253, /* RRC connection failure. Eg.RACH */
833 CALL_FAIL_RADIO_LINK_FAILURE = 254, /* Radio Link Failure */
834 CALL_FAIL_RADIO_LINK_LOST = 255, /* Radio link lost due to poor coverage */
835 CALL_FAIL_RADIO_UPLINK_FAILURE = 256, /* Radio uplink failure */
836 CALL_FAIL_RADIO_SETUP_FAILURE = 257, /* RRC connection setup failure */
837 CALL_FAIL_RADIO_RELEASE_NORMAL = 258, /* RRC connection release, normal */
838 CALL_FAIL_RADIO_RELEASE_ABNORMAL = 259, /* RRC connection release, abnormal */
839 CALL_FAIL_ACCESS_CLASS_BLOCKED = 260, /* Access class barring */
840 CALL_FAIL_NETWORK_DETACH = 261, /* Explicit network detach */
Wink Saville1b5fd232009-04-22 14:50:00 -0700841 CALL_FAIL_CDMA_LOCKED_UNTIL_POWER_CYCLE = 1000,
842 CALL_FAIL_CDMA_DROP = 1001,
843 CALL_FAIL_CDMA_INTERCEPT = 1002,
844 CALL_FAIL_CDMA_REORDER = 1003,
845 CALL_FAIL_CDMA_SO_REJECT = 1004,
846 CALL_FAIL_CDMA_RETRY_ORDER = 1005,
847 CALL_FAIL_CDMA_ACCESS_FAILURE = 1006,
848 CALL_FAIL_CDMA_PREEMPTED = 1007,
849 CALL_FAIL_CDMA_NOT_EMERGENCY = 1008, /* For non-emergency number dialed
850 during emergency callback mode */
Naveen Kalla03c1edf2009-09-23 11:18:35 -0700851 CALL_FAIL_CDMA_ACCESS_BLOCKED = 1009, /* CDMA network access probes blocked */
Jayachandran Ccc2a2022017-03-07 09:55:58 -0800852
853 /* OEM specific error codes. Used to distinguish error from
854 * CALL_FAIL_ERROR_UNSPECIFIED and help assist debugging */
855 CALL_FAIL_OEM_CAUSE_1 = 0xf001,
856 CALL_FAIL_OEM_CAUSE_2 = 0xf002,
857 CALL_FAIL_OEM_CAUSE_3 = 0xf003,
858 CALL_FAIL_OEM_CAUSE_4 = 0xf004,
859 CALL_FAIL_OEM_CAUSE_5 = 0xf005,
860 CALL_FAIL_OEM_CAUSE_6 = 0xf006,
861 CALL_FAIL_OEM_CAUSE_7 = 0xf007,
862 CALL_FAIL_OEM_CAUSE_8 = 0xf008,
863 CALL_FAIL_OEM_CAUSE_9 = 0xf009,
864 CALL_FAIL_OEM_CAUSE_10 = 0xf00a,
865 CALL_FAIL_OEM_CAUSE_11 = 0xf00b,
866 CALL_FAIL_OEM_CAUSE_12 = 0xf00c,
867 CALL_FAIL_OEM_CAUSE_13 = 0xf00d,
868 CALL_FAIL_OEM_CAUSE_14 = 0xf00e,
869 CALL_FAIL_OEM_CAUSE_15 = 0xf00f,
870
Sooraj Sasindrand2102792014-09-12 17:00:03 +0800871 CALL_FAIL_ERROR_UNSPECIFIED = 0xffff /* This error will be deprecated soon,
872 vendor code should make sure to map error
873 code to specific error */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800874} RIL_LastCallFailCause;
875
Chao Liu548a81e2015-05-14 16:13:46 -0700876typedef struct {
877 RIL_LastCallFailCause cause_code;
878 char * vendor_cause;
879} RIL_LastCallFailCauseInfo;
880
Wink Savillef4c4d362009-04-02 01:37:03 -0700881/* See RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800882typedef enum {
Wink Saville43808972011-01-13 17:39:51 -0800883 PDP_FAIL_NONE = 0, /* No error, connection ok */
884
885 /* an integer cause code defined in TS 24.008
886 section 6.1.3.1.3 or TS 24.301 Release 8+ Annex B.
887 If the implementation does not have access to the exact cause codes,
888 then it should return one of the following values,
889 as the UI layer needs to distinguish these
890 cases for error notification and potential retries. */
Jaikumar Ganeshd6aa2e32009-05-04 11:09:46 -0700891 PDP_FAIL_OPERATOR_BARRED = 0x08, /* no retry */
Sanket Padaweac308b92016-01-07 14:41:17 -0800892 PDP_FAIL_NAS_SIGNALLING = 0x0E,
893 PDP_FAIL_LLC_SNDCP = 0x19,
Jaikumar Ganeshd6aa2e32009-05-04 11:09:46 -0700894 PDP_FAIL_INSUFFICIENT_RESOURCES = 0x1A,
895 PDP_FAIL_MISSING_UKNOWN_APN = 0x1B, /* no retry */
896 PDP_FAIL_UNKNOWN_PDP_ADDRESS_TYPE = 0x1C, /* no retry */
897 PDP_FAIL_USER_AUTHENTICATION = 0x1D, /* no retry */
898 PDP_FAIL_ACTIVATION_REJECT_GGSN = 0x1E, /* no retry */
899 PDP_FAIL_ACTIVATION_REJECT_UNSPECIFIED = 0x1F,
900 PDP_FAIL_SERVICE_OPTION_NOT_SUPPORTED = 0x20, /* no retry */
901 PDP_FAIL_SERVICE_OPTION_NOT_SUBSCRIBED = 0x21, /* no retry */
902 PDP_FAIL_SERVICE_OPTION_OUT_OF_ORDER = 0x22,
Wink Saville43808972011-01-13 17:39:51 -0800903 PDP_FAIL_NSAPI_IN_USE = 0x23, /* no retry */
Hui Wang11e8b232014-09-19 16:40:17 -0500904 PDP_FAIL_REGULAR_DEACTIVATION = 0x24, /* possibly restart radio,
905 based on framework config */
Sanket Padaweac308b92016-01-07 14:41:17 -0800906 PDP_FAIL_QOS_NOT_ACCEPTED = 0x25,
907 PDP_FAIL_NETWORK_FAILURE = 0x26,
908 PDP_FAIL_UMTS_REACTIVATION_REQ = 0x27,
909 PDP_FAIL_FEATURE_NOT_SUPP = 0x28,
910 PDP_FAIL_TFT_SEMANTIC_ERROR = 0x29,
911 PDP_FAIL_TFT_SYTAX_ERROR = 0x2A,
912 PDP_FAIL_UNKNOWN_PDP_CONTEXT = 0x2B,
913 PDP_FAIL_FILTER_SEMANTIC_ERROR = 0x2C,
914 PDP_FAIL_FILTER_SYTAX_ERROR = 0x2D,
915 PDP_FAIL_PDP_WITHOUT_ACTIVE_TFT = 0x2E,
Wink Saville43808972011-01-13 17:39:51 -0800916 PDP_FAIL_ONLY_IPV4_ALLOWED = 0x32, /* no retry */
917 PDP_FAIL_ONLY_IPV6_ALLOWED = 0x33, /* no retry */
918 PDP_FAIL_ONLY_SINGLE_BEARER_ALLOWED = 0x34,
Sanket Padaweac308b92016-01-07 14:41:17 -0800919 PDP_FAIL_ESM_INFO_NOT_RECEIVED = 0x35,
920 PDP_FAIL_PDN_CONN_DOES_NOT_EXIST = 0x36,
921 PDP_FAIL_MULTI_CONN_TO_SAME_PDN_NOT_ALLOWED = 0x37,
922 PDP_FAIL_MAX_ACTIVE_PDP_CONTEXT_REACHED = 0x41,
923 PDP_FAIL_UNSUPPORTED_APN_IN_CURRENT_PLMN = 0x42,
924 PDP_FAIL_INVALID_TRANSACTION_ID = 0x51,
925 PDP_FAIL_MESSAGE_INCORRECT_SEMANTIC = 0x5F,
926 PDP_FAIL_INVALID_MANDATORY_INFO = 0x60,
927 PDP_FAIL_MESSAGE_TYPE_UNSUPPORTED = 0x61,
928 PDP_FAIL_MSG_TYPE_NONCOMPATIBLE_STATE = 0x62,
929 PDP_FAIL_UNKNOWN_INFO_ELEMENT = 0x63,
930 PDP_FAIL_CONDITIONAL_IE_ERROR = 0x64,
931 PDP_FAIL_MSG_AND_PROTOCOL_STATE_UNCOMPATIBLE = 0x65,
932 PDP_FAIL_PROTOCOL_ERRORS = 0x6F, /* no retry */
933 PDP_FAIL_APN_TYPE_CONFLICT = 0x70,
934 PDP_FAIL_INVALID_PCSCF_ADDR = 0x71,
935 PDP_FAIL_INTERNAL_CALL_PREEMPT_BY_HIGH_PRIO_APN = 0x72,
936 PDP_FAIL_EMM_ACCESS_BARRED = 0x73,
937 PDP_FAIL_EMERGENCY_IFACE_ONLY = 0x74,
938 PDP_FAIL_IFACE_MISMATCH = 0x75,
939 PDP_FAIL_COMPANION_IFACE_IN_USE = 0x76,
940 PDP_FAIL_IP_ADDRESS_MISMATCH = 0x77,
941 PDP_FAIL_IFACE_AND_POL_FAMILY_MISMATCH = 0x78,
942 PDP_FAIL_EMM_ACCESS_BARRED_INFINITE_RETRY = 0x79,
943 PDP_FAIL_AUTH_FAILURE_ON_EMERGENCY_CALL = 0x7A,
Wink Saville43808972011-01-13 17:39:51 -0800944
Sanket Padawe0106aed2016-02-09 09:56:31 -0800945 // OEM specific error codes. To be used by OEMs when they don't want to
946 // reveal error code which would be replaced by PDP_FAIL_ERROR_UNSPECIFIED
947 PDP_FAIL_OEM_DCFAILCAUSE_1 = 0x1001,
948 PDP_FAIL_OEM_DCFAILCAUSE_2 = 0x1002,
949 PDP_FAIL_OEM_DCFAILCAUSE_3 = 0x1003,
950 PDP_FAIL_OEM_DCFAILCAUSE_4 = 0x1004,
951 PDP_FAIL_OEM_DCFAILCAUSE_5 = 0x1005,
952 PDP_FAIL_OEM_DCFAILCAUSE_6 = 0x1006,
953 PDP_FAIL_OEM_DCFAILCAUSE_7 = 0x1007,
954 PDP_FAIL_OEM_DCFAILCAUSE_8 = 0x1008,
955 PDP_FAIL_OEM_DCFAILCAUSE_9 = 0x1009,
956 PDP_FAIL_OEM_DCFAILCAUSE_10 = 0x100A,
957 PDP_FAIL_OEM_DCFAILCAUSE_11 = 0x100B,
958 PDP_FAIL_OEM_DCFAILCAUSE_12 = 0x100C,
959 PDP_FAIL_OEM_DCFAILCAUSE_13 = 0x100D,
960 PDP_FAIL_OEM_DCFAILCAUSE_14 = 0x100E,
961 PDP_FAIL_OEM_DCFAILCAUSE_15 = 0x100F,
962
Jaikumar Ganeshd6aa2e32009-05-04 11:09:46 -0700963 /* Not mentioned in the specification */
Wink Savillec0114b32011-02-18 10:14:07 -0800964 PDP_FAIL_VOICE_REGISTRATION_FAIL = -1,
965 PDP_FAIL_DATA_REGISTRATION_FAIL = -2,
Wink Saville43808972011-01-13 17:39:51 -0800966
967 /* reasons for data call drop - network/modem disconnect */
Wink Saville3492c6e2013-10-03 13:53:27 -0700968 PDP_FAIL_SIGNAL_LOST = -3,
Wink Saville43808972011-01-13 17:39:51 -0800969 PDP_FAIL_PREF_RADIO_TECH_CHANGED = -4,/* preferred technology has changed, should retry
970 with parameters appropriate for new technology */
971 PDP_FAIL_RADIO_POWER_OFF = -5, /* data call was disconnected because radio was resetting,
972 powered off - no retry */
973 PDP_FAIL_TETHERED_CALL_ACTIVE = -6, /* data call was disconnected by modem because tethered
974 mode was up on same APN/data profile - no retry until
975 tethered call is off */
976
Sanket Padaweac308b92016-01-07 14:41:17 -0800977 PDP_FAIL_ERROR_UNSPECIFIED = 0xffff, /* retry silently. Will be deprecated soon as
978 new error codes are added making this unnecessary */
Wink Saville43808972011-01-13 17:39:51 -0800979} RIL_DataCallFailCause;
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800980
jsh602f80f2009-07-10 15:44:37 -0700981/* See RIL_REQUEST_SETUP_DATA_CALL */
982typedef enum {
983 RIL_DATA_PROFILE_DEFAULT = 0,
984 RIL_DATA_PROFILE_TETHERED = 1,
Hui Wang8d679622014-10-16 14:59:27 -0500985 RIL_DATA_PROFILE_IMS = 2,
986 RIL_DATA_PROFILE_FOTA = 3,
987 RIL_DATA_PROFILE_CBS = 4,
988 RIL_DATA_PROFILE_OEM_BASE = 1000, /* Start of OEM-specific profiles */
989 RIL_DATA_PROFILE_INVALID = 0xFFFFFFFF
jsh602f80f2009-07-10 15:44:37 -0700990} RIL_DataProfile;
991
The Android Open Source Project00f06fc2009-03-03 19:32:15 -0800992/* Used by RIL_UNSOL_SUPP_SVC_NOTIFICATION */
993typedef struct {
994 int notificationType; /*
995 * 0 = MO intermediate result code
996 * 1 = MT unsolicited result code
997 */
998 int code; /* See 27.007 7.17
999 "code1" for MO
1000 "code2" for MT. */
1001 int index; /* CUG index. See 27.007 7.17. */
1002 int type; /* "type" from 27.007 7.17 (MT only). */
1003 char * number; /* "number" from 27.007 7.17
1004 (MT only, may be NULL). */
1005} RIL_SuppSvcNotification;
1006
Wink Savillef4c4d362009-04-02 01:37:03 -07001007#define RIL_CARD_MAX_APPS 8
1008
1009typedef enum {
Meng Wangb4e34312016-05-12 14:54:36 -07001010 RIL_CARDSTATE_ABSENT = 0,
1011 RIL_CARDSTATE_PRESENT = 1,
1012 RIL_CARDSTATE_ERROR = 2,
1013 RIL_CARDSTATE_RESTRICTED = 3 /* card is present but not usable due to carrier restrictions.*/
Wink Savillef4c4d362009-04-02 01:37:03 -07001014} RIL_CardState;
1015
1016typedef enum {
1017 RIL_PERSOSUBSTATE_UNKNOWN = 0, /* initial state */
1018 RIL_PERSOSUBSTATE_IN_PROGRESS = 1, /* in between each lock transition */
Wink Saville7f856802009-06-09 10:23:37 -07001019 RIL_PERSOSUBSTATE_READY = 2, /* when either SIM or RUIM Perso is finished
1020 since each app can only have 1 active perso
Wink Savillef4c4d362009-04-02 01:37:03 -07001021 involved */
1022 RIL_PERSOSUBSTATE_SIM_NETWORK = 3,
1023 RIL_PERSOSUBSTATE_SIM_NETWORK_SUBSET = 4,
1024 RIL_PERSOSUBSTATE_SIM_CORPORATE = 5,
1025 RIL_PERSOSUBSTATE_SIM_SERVICE_PROVIDER = 6,
1026 RIL_PERSOSUBSTATE_SIM_SIM = 7,
1027 RIL_PERSOSUBSTATE_SIM_NETWORK_PUK = 8, /* The corresponding perso lock is blocked */
1028 RIL_PERSOSUBSTATE_SIM_NETWORK_SUBSET_PUK = 9,
1029 RIL_PERSOSUBSTATE_SIM_CORPORATE_PUK = 10,
1030 RIL_PERSOSUBSTATE_SIM_SERVICE_PROVIDER_PUK = 11,
1031 RIL_PERSOSUBSTATE_SIM_SIM_PUK = 12,
1032 RIL_PERSOSUBSTATE_RUIM_NETWORK1 = 13,
1033 RIL_PERSOSUBSTATE_RUIM_NETWORK2 = 14,
1034 RIL_PERSOSUBSTATE_RUIM_HRPD = 15,
1035 RIL_PERSOSUBSTATE_RUIM_CORPORATE = 16,
1036 RIL_PERSOSUBSTATE_RUIM_SERVICE_PROVIDER = 17,
1037 RIL_PERSOSUBSTATE_RUIM_RUIM = 18,
1038 RIL_PERSOSUBSTATE_RUIM_NETWORK1_PUK = 19, /* The corresponding perso lock is blocked */
1039 RIL_PERSOSUBSTATE_RUIM_NETWORK2_PUK = 20,
1040 RIL_PERSOSUBSTATE_RUIM_HRPD_PUK = 21,
1041 RIL_PERSOSUBSTATE_RUIM_CORPORATE_PUK = 22,
1042 RIL_PERSOSUBSTATE_RUIM_SERVICE_PROVIDER_PUK = 23,
1043 RIL_PERSOSUBSTATE_RUIM_RUIM_PUK = 24
1044} RIL_PersoSubstate;
1045
1046typedef enum {
1047 RIL_APPSTATE_UNKNOWN = 0,
1048 RIL_APPSTATE_DETECTED = 1,
1049 RIL_APPSTATE_PIN = 2, /* If PIN1 or UPin is required */
1050 RIL_APPSTATE_PUK = 3, /* If PUK1 or Puk for UPin is required */
Wink Saville7f856802009-06-09 10:23:37 -07001051 RIL_APPSTATE_SUBSCRIPTION_PERSO = 4, /* perso_substate should be look at
Wink Savillef4c4d362009-04-02 01:37:03 -07001052 when app_state is assigned to this value */
1053 RIL_APPSTATE_READY = 5
1054} RIL_AppState;
1055
1056typedef enum {
1057 RIL_PINSTATE_UNKNOWN = 0,
1058 RIL_PINSTATE_ENABLED_NOT_VERIFIED = 1,
1059 RIL_PINSTATE_ENABLED_VERIFIED = 2,
1060 RIL_PINSTATE_DISABLED = 3,
1061 RIL_PINSTATE_ENABLED_BLOCKED = 4,
1062 RIL_PINSTATE_ENABLED_PERM_BLOCKED = 5
1063} RIL_PinState;
1064
1065typedef enum {
1066 RIL_APPTYPE_UNKNOWN = 0,
1067 RIL_APPTYPE_SIM = 1,
1068 RIL_APPTYPE_USIM = 2,
1069 RIL_APPTYPE_RUIM = 3,
Wink Savillec0114b32011-02-18 10:14:07 -08001070 RIL_APPTYPE_CSIM = 4,
1071 RIL_APPTYPE_ISIM = 5
Wink Savillef4c4d362009-04-02 01:37:03 -07001072} RIL_AppType;
1073
Sooraj Sasindranf4714b72016-11-30 18:36:03 -08001074/*
1075 * Please note that registration state UNKNOWN is
1076 * treated as "out of service" in the Android telephony.
1077 * Registration state REG_DENIED must be returned if Location Update
1078 * Reject (with cause 17 - Network Failure) is received
1079 * repeatedly from the network, to facilitate
1080 * "managed roaming"
1081 */
1082typedef enum {
1083 RIL_NOT_REG_AND_NOT_SEARCHING = 0, // Not registered, MT is not currently searching
1084 // a new operator to register
1085 RIL_REG_HOME = 1, // Registered, home network
1086 RIL_NOT_REG_AND_SEARCHING = 2, // Not registered, but MT is currently searching
1087 // a new operator to register
1088 RIL_REG_DENIED = 3, // Registration denied
1089 RIL_UNKNOWN = 4, // Unknown
1090 RIL_REG_ROAMING = 5, // Registered, roaming
1091 RIL_NOT_REG_AND_EMERGENCY_AVAILABLE_AND_NOT_SEARCHING = 10, // Same as
1092 // RIL_NOT_REG_AND_NOT_SEARCHING but indicates that
1093 // emergency calls are enabled.
1094 RIL_NOT_REG_AND_EMERGENCY_AVAILABLE_AND_SEARCHING = 12, // Same as RIL_NOT_REG_AND_SEARCHING
1095 // but indicates that
1096 // emergency calls are enabled.
1097 RIL_REG_DENIED_AND_EMERGENCY_AVAILABLE = 13, // Same as REG_DENIED but indicates that
1098 // emergency calls are enabled.
1099 RIL_UNKNOWN_AND_EMERGENCY_AVAILABLE = 14, // Same as UNKNOWN but indicates that
1100 // emergency calls are enabled.
1101} RIL_RegState;
1102
Wink Savillef4c4d362009-04-02 01:37:03 -07001103typedef struct
1104{
Wink Saville7f856802009-06-09 10:23:37 -07001105 RIL_AppType app_type;
1106 RIL_AppState app_state;
1107 RIL_PersoSubstate perso_substate; /* applicable only if app_state ==
Wink Savillef4c4d362009-04-02 01:37:03 -07001108 RIL_APPSTATE_SUBSCRIPTION_PERSO */
Wink Saville7f856802009-06-09 10:23:37 -07001109 char *aid_ptr; /* null terminated string, e.g., from 0xA0, 0x00 -> 0x41,
Wink Savillef4c4d362009-04-02 01:37:03 -07001110 0x30, 0x30, 0x30 */
1111 char *app_label_ptr; /* null terminated string */
Wink Savillec0114b32011-02-18 10:14:07 -08001112 int pin1_replaced; /* applicable to USIM, CSIM & ISIM */
Wink Saville7f856802009-06-09 10:23:37 -07001113 RIL_PinState pin1;
1114 RIL_PinState pin2;
Wink Savillef4c4d362009-04-02 01:37:03 -07001115} RIL_AppStatus;
1116
Wink Savillec0114b32011-02-18 10:14:07 -08001117/* Deprecated, use RIL_CardStatus_v6 */
1118typedef struct
1119{
1120 RIL_CardState card_state;
1121 RIL_PinState universal_pin_state; /* applicable to USIM and CSIM: RIL_PINSTATE_xxx */
1122 int gsm_umts_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */
1123 int cdma_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */
1124 int num_applications; /* value <= RIL_CARD_MAX_APPS */
1125 RIL_AppStatus applications[RIL_CARD_MAX_APPS];
1126} RIL_CardStatus_v5;
1127
Wink Savillef4c4d362009-04-02 01:37:03 -07001128typedef struct
1129{
Wink Saville7f856802009-06-09 10:23:37 -07001130 RIL_CardState card_state;
Wink Savillef4c4d362009-04-02 01:37:03 -07001131 RIL_PinState universal_pin_state; /* applicable to USIM and CSIM: RIL_PINSTATE_xxx */
Wink Savillec0114b32011-02-18 10:14:07 -08001132 int gsm_umts_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */
1133 int cdma_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */
1134 int ims_subscription_app_index; /* value < RIL_CARD_MAX_APPS, -1 if none */
Wink Savillef4c4d362009-04-02 01:37:03 -07001135 int num_applications; /* value <= RIL_CARD_MAX_APPS */
1136 RIL_AppStatus applications[RIL_CARD_MAX_APPS];
Wink Savillec0114b32011-02-18 10:14:07 -08001137} RIL_CardStatus_v6;
Wink Savillef4c4d362009-04-02 01:37:03 -07001138
Alex Yakavenka45e740e2012-01-31 11:48:27 -08001139/** The result of a SIM refresh, returned in data[0] of RIL_UNSOL_SIM_REFRESH
1140 * or as part of RIL_SimRefreshResponse_v7
1141 */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08001142typedef enum {
1143 /* A file on SIM has been updated. data[1] contains the EFID. */
1144 SIM_FILE_UPDATE = 0,
Alex Yakavenka45e740e2012-01-31 11:48:27 -08001145 /* SIM initialized. All files should be re-read. */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08001146 SIM_INIT = 1,
1147 /* SIM reset. SIM power required, SIM may be locked and all files should be re-read. */
1148 SIM_RESET = 2
1149} RIL_SimRefreshResult;
1150
Alex Yakavenka45e740e2012-01-31 11:48:27 -08001151typedef struct {
1152 RIL_SimRefreshResult result;
1153 int ef_id; /* is the EFID of the updated file if the result is */
1154 /* SIM_FILE_UPDATE or 0 for any other result. */
1155 char * aid; /* is AID(application ID) of the card application */
1156 /* See ETSI 102.221 8.1 and 101.220 4 */
1157 /* For SIM_FILE_UPDATE result it can be set to AID of */
1158 /* application in which updated EF resides or it can be */
1159 /* NULL if EF is outside of an application. */
1160 /* For SIM_INIT result this field is set to AID of */
1161 /* application that caused REFRESH */
1162 /* For SIM_RESET result it is NULL. */
1163} RIL_SimRefreshResponse_v7;
1164
Wink Savillec0114b32011-02-18 10:14:07 -08001165/* Deprecated, use RIL_CDMA_CallWaiting_v6 */
1166typedef struct {
1167 char * number; /* Remote party number */
1168 int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown */
1169 char * name; /* Remote party name */
1170 RIL_CDMA_SignalInfoRecord signalInfoRecord;
1171} RIL_CDMA_CallWaiting_v5;
1172
Wink Saville1b5fd232009-04-22 14:50:00 -07001173typedef struct {
1174 char * number; /* Remote party number */
1175 int numberPresentation; /* 0=Allowed, 1=Restricted, 2=Not Specified/Unknown */
1176 char * name; /* Remote party name */
Wink Saville3d54e742009-05-18 18:00:44 -07001177 RIL_CDMA_SignalInfoRecord signalInfoRecord;
Wink Savillec0114b32011-02-18 10:14:07 -08001178 /* Number type/Number plan required to support International Call Waiting */
1179 int number_type; /* 0=Unknown, 1=International, 2=National,
1180 3=Network specific, 4=subscriber */
1181 int number_plan; /* 0=Unknown, 1=ISDN, 3=Data, 4=Telex, 8=Nat'l, 9=Private */
1182} RIL_CDMA_CallWaiting_v6;
Wink Saville1b5fd232009-04-22 14:50:00 -07001183
Wink Savillea592eeb2009-05-22 13:26:36 -07001184/**
1185 * Which types of Cell Broadcast Message (CBM) are to be received by the ME
1186 *
1187 * uFromServiceID - uToServiceID defines a range of CBM message identifiers
1188 * whose value is 0x0000 - 0xFFFF as defined in TS 23.041 9.4.1.2.2 for GMS
1189 * and 9.4.4.2.2 for UMTS. All other values can be treated as empty
1190 * CBM message ID.
1191 *
1192 * uFromCodeScheme - uToCodeScheme defines a range of CBM data coding schemes
1193 * whose value is 0x00 - 0xFF as defined in TS 23.041 9.4.1.2.3 for GMS
1194 * and 9.4.4.2.3 for UMTS.
1195 * All other values can be treated as empty CBM data coding scheme.
1196 *
1197 * selected 0 means message types specified in <fromServiceId, toServiceId>
1198 * and <fromCodeScheme, toCodeScheme>are not accepted, while 1 means accepted.
1199 *
1200 * Used by RIL_REQUEST_GSM_GET_BROADCAST_CONFIG and
1201 * RIL_REQUEST_GSM_SET_BROADCAST_CONFIG.
1202 */
Wink Savillef4c4d362009-04-02 01:37:03 -07001203typedef struct {
Wink Savillea592eeb2009-05-22 13:26:36 -07001204 int fromServiceId;
1205 int toServiceId;
1206 int fromCodeScheme;
1207 int toCodeScheme;
1208 unsigned char selected;
1209} RIL_GSM_BroadcastSmsConfigInfo;
Wink Savillef4c4d362009-04-02 01:37:03 -07001210
The Android Open Source Project34a51082009-03-05 14:34:37 -08001211/* No restriction at all including voice/SMS/USSD/SS/AV64 and packet data. */
1212#define RIL_RESTRICTED_STATE_NONE 0x00
1213/* Block emergency call due to restriction. But allow all normal voice/SMS/USSD/SS/AV64. */
1214#define RIL_RESTRICTED_STATE_CS_EMERGENCY 0x01
1215/* Block all normal voice/SMS/USSD/SS/AV64 due to restriction. Only Emergency call allowed. */
1216#define RIL_RESTRICTED_STATE_CS_NORMAL 0x02
Wink Savillea592eeb2009-05-22 13:26:36 -07001217/* Block all voice/SMS/USSD/SS/AV64 including emergency call due to restriction.*/
The Android Open Source Project34a51082009-03-05 14:34:37 -08001218#define RIL_RESTRICTED_STATE_CS_ALL 0x04
1219/* Block packet data access due to restriction. */
1220#define RIL_RESTRICTED_STATE_PS_ALL 0x10
1221
Wink Saville1b5fd232009-04-22 14:50:00 -07001222/* The status for an OTASP/OTAPA session */
1223typedef enum {
1224 CDMA_OTA_PROVISION_STATUS_SPL_UNLOCKED,
1225 CDMA_OTA_PROVISION_STATUS_SPC_RETRIES_EXCEEDED,
1226 CDMA_OTA_PROVISION_STATUS_A_KEY_EXCHANGED,
1227 CDMA_OTA_PROVISION_STATUS_SSD_UPDATED,
1228 CDMA_OTA_PROVISION_STATUS_NAM_DOWNLOADED,
1229 CDMA_OTA_PROVISION_STATUS_MDN_DOWNLOADED,
1230 CDMA_OTA_PROVISION_STATUS_IMSI_DOWNLOADED,
1231 CDMA_OTA_PROVISION_STATUS_PRL_DOWNLOADED,
1232 CDMA_OTA_PROVISION_STATUS_COMMITTED,
1233 CDMA_OTA_PROVISION_STATUS_OTAPA_STARTED,
1234 CDMA_OTA_PROVISION_STATUS_OTAPA_STOPPED,
1235 CDMA_OTA_PROVISION_STATUS_OTAPA_ABORTED
1236} RIL_CDMA_OTA_ProvisionStatus;
1237
1238typedef struct {
1239 int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */
1240 int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */
1241} RIL_GW_SignalStrength;
1242
Wink Savillec57b3eb2013-04-17 12:51:41 -07001243typedef struct {
1244 int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */
1245 int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001246 int timingAdvance; /* Timing Advance in bit periods. 1 bit period = 48/13 us.
1247 * INT_MAX denotes invalid value */
1248} RIL_GSM_SignalStrength_v12;
1249
1250typedef struct {
1251 int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */
1252 int bitErrorRate; /* bit error rate (0-7, 99) as defined in TS 27.007 8.5 */
Wink Savillec57b3eb2013-04-17 12:51:41 -07001253} RIL_SignalStrengthWcdma;
Wink Saville1b5fd232009-04-22 14:50:00 -07001254
1255typedef struct {
1256 int dbm; /* Valid values are positive integers. This value is the actual RSSI value
1257 * multiplied by -1. Example: If the actual RSSI is -75, then this response
1258 * value will be 75.
1259 */
1260 int ecio; /* Valid values are positive integers. This value is the actual Ec/Io multiplied
1261 * by -10. Example: If the actual Ec/Io is -12.5 dB, then this response value
1262 * will be 125.
1263 */
1264} RIL_CDMA_SignalStrength;
1265
1266
1267typedef struct {
1268 int dbm; /* Valid values are positive integers. This value is the actual RSSI value
1269 * multiplied by -1. Example: If the actual RSSI is -75, then this response
1270 * value will be 75.
1271 */
1272 int ecio; /* Valid values are positive integers. This value is the actual Ec/Io multiplied
1273 * by -10. Example: If the actual Ec/Io is -12.5 dB, then this response value
1274 * will be 125.
1275 */
1276 int signalNoiseRatio; /* Valid values are 0-8. 8 is the highest signal to noise ratio. */
1277} RIL_EVDO_SignalStrength;
1278
Wink Savillec0114b32011-02-18 10:14:07 -08001279typedef struct {
1280 int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */
Wink Saville473adc92011-06-13 10:24:09 -07001281 int rsrp; /* The current Reference Signal Receive Power in dBm multipled by -1.
1282 * Range: 44 to 140 dBm
1283 * INT_MAX: 0x7FFFFFFF denotes invalid value.
1284 * Reference: 3GPP TS 36.133 9.1.4 */
1285 int rsrq; /* The current Reference Signal Receive Quality in dB multiplied by -1.
1286 * Range: 20 to 3 dB.
1287 * INT_MAX: 0x7FFFFFFF denotes invalid value.
1288 * Reference: 3GPP TS 36.133 9.1.7 */
1289 int rssnr; /* The current reference signal signal-to-noise ratio in 0.1 dB units.
1290 * Range: -200 to +300 (-200 = -20.0 dB, +300 = 30dB).
1291 * INT_MAX : 0x7FFFFFFF denotes invalid value.
1292 * Reference: 3GPP TS 36.101 8.1.1 */
1293 int cqi; /* The current Channel Quality Indicator.
1294 * Range: 0 to 15.
1295 * INT_MAX : 0x7FFFFFFF denotes invalid value.
1296 * Reference: 3GPP TS 36.101 9.2, 9.3, A.4 */
Wink Savillec0114b32011-02-18 10:14:07 -08001297} RIL_LTE_SignalStrength;
1298
Wink Saville8a9e0212013-04-09 12:11:38 -07001299typedef struct {
1300 int signalStrength; /* Valid values are (0-31, 99) as defined in TS 27.007 8.5 */
1301 int rsrp; /* The current Reference Signal Receive Power in dBm multipled by -1.
1302 * Range: 44 to 140 dBm
1303 * INT_MAX: 0x7FFFFFFF denotes invalid value.
1304 * Reference: 3GPP TS 36.133 9.1.4 */
1305 int rsrq; /* The current Reference Signal Receive Quality in dB multiplied by -1.
1306 * Range: 20 to 3 dB.
1307 * INT_MAX: 0x7FFFFFFF denotes invalid value.
1308 * Reference: 3GPP TS 36.133 9.1.7 */
1309 int rssnr; /* The current reference signal signal-to-noise ratio in 0.1 dB units.
1310 * Range: -200 to +300 (-200 = -20.0 dB, +300 = 30dB).
1311 * INT_MAX : 0x7FFFFFFF denotes invalid value.
1312 * Reference: 3GPP TS 36.101 8.1.1 */
1313 int cqi; /* The current Channel Quality Indicator.
1314 * Range: 0 to 15.
1315 * INT_MAX : 0x7FFFFFFF denotes invalid value.
1316 * Reference: 3GPP TS 36.101 9.2, 9.3, A.4 */
1317 int timingAdvance; /* timing advance in micro seconds for a one way trip from cell to device.
1318 * Approximate distance can be calculated using 300m/us * timingAdvance.
1319 * Range: 0 to 0x7FFFFFFE
1320 * INT_MAX : 0x7FFFFFFF denotes invalid value.
1321 * Reference: 3GPP 36.321 section 6.1.3.5
1322 * also: http://www.cellular-planningoptimization.com/2010/02/timing-advance-with-calculation.html */
1323} RIL_LTE_SignalStrength_v8;
1324
Etan Cohend3652192014-06-20 08:28:44 -07001325typedef struct {
1326 int rscp; /* The Received Signal Code Power in dBm multipled by -1.
1327 * Range : 25 to 120
1328 * INT_MAX: 0x7FFFFFFF denotes invalid value.
1329 * Reference: 3GPP TS 25.123, section 9.1.1.1 */
1330} RIL_TD_SCDMA_SignalStrength;
1331
Wink Savillec0114b32011-02-18 10:14:07 -08001332/* Deprecated, use RIL_SignalStrength_v6 */
1333typedef struct {
1334 RIL_GW_SignalStrength GW_SignalStrength;
1335 RIL_CDMA_SignalStrength CDMA_SignalStrength;
1336 RIL_EVDO_SignalStrength EVDO_SignalStrength;
1337} RIL_SignalStrength_v5;
Wink Saville1b5fd232009-04-22 14:50:00 -07001338
1339typedef struct {
1340 RIL_GW_SignalStrength GW_SignalStrength;
1341 RIL_CDMA_SignalStrength CDMA_SignalStrength;
1342 RIL_EVDO_SignalStrength EVDO_SignalStrength;
Wink Savillec0114b32011-02-18 10:14:07 -08001343 RIL_LTE_SignalStrength LTE_SignalStrength;
1344} RIL_SignalStrength_v6;
Wink Saville1b5fd232009-04-22 14:50:00 -07001345
Wink Saville8a9e0212013-04-09 12:11:38 -07001346typedef struct {
1347 RIL_GW_SignalStrength GW_SignalStrength;
1348 RIL_CDMA_SignalStrength CDMA_SignalStrength;
1349 RIL_EVDO_SignalStrength EVDO_SignalStrength;
1350 RIL_LTE_SignalStrength_v8 LTE_SignalStrength;
1351} RIL_SignalStrength_v8;
1352
Etan Cohend3652192014-06-20 08:28:44 -07001353typedef struct {
1354 RIL_GW_SignalStrength GW_SignalStrength;
1355 RIL_CDMA_SignalStrength CDMA_SignalStrength;
1356 RIL_EVDO_SignalStrength EVDO_SignalStrength;
1357 RIL_LTE_SignalStrength_v8 LTE_SignalStrength;
1358 RIL_TD_SCDMA_SignalStrength TD_SCDMA_SignalStrength;
1359} RIL_SignalStrength_v10;
1360
Wink Saville8a9e0212013-04-09 12:11:38 -07001361typedef struct {
Wink Savillec57b3eb2013-04-17 12:51:41 -07001362 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1363 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1364 int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */
1365 int cid; /* 16-bit GSM Cell Identity described in TS 27.007, 0..65535, INT_MAX if unknown */
Wink Saville8a9e0212013-04-09 12:11:38 -07001366} RIL_CellIdentityGsm;
1367
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001368typedef struct {
1369 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1370 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1371 int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */
1372 int cid; /* 16-bit GSM Cell Identity described in TS 27.007, 0..65535, INT_MAX if unknown */
Nathan Harold5ce4b2a2017-08-29 16:59:03 -07001373 int arfcn; /* 16-bit GSM Absolute RF channel number; this value must be reported */
1374 uint8_t bsic; /* 6-bit Base Station Identity Code; 0xFF if unknown */
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001375} RIL_CellIdentityGsm_v12;
1376
Wink Savillec57b3eb2013-04-17 12:51:41 -07001377typedef struct {
1378 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1379 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1380 int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */
1381 int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */
1382 int psc; /* 9-bit UMTS Primary Scrambling Code described in TS 25.331, 0..511, INT_MAX if unknown */
1383} RIL_CellIdentityWcdma;
1384
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001385typedef struct {
1386 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1387 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1388 int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */
1389 int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */
Nathan Harold5ce4b2a2017-08-29 16:59:03 -07001390 int psc; /* 9-bit UMTS Primary Scrambling Code described in TS 25.331, 0..511; this value must be reported */
1391 int uarfcn; /* 16-bit UMTS Absolute RF Channel Number; this value must be reported */
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001392} RIL_CellIdentityWcdma_v12;
1393
Wink Saville8a9e0212013-04-09 12:11:38 -07001394typedef struct {
Wink Savillec57b3eb2013-04-17 12:51:41 -07001395 int networkId; /* Network Id 0..65535, INT_MAX if unknown */
1396 int systemId; /* CDMA System Id 0..32767, INT_MAX if unknown */
1397 int basestationId; /* Base Station Id 0..65535, INT_MAX if unknown */
Wink Saville8a9e0212013-04-09 12:11:38 -07001398 int longitude; /* Longitude is a decimal number as specified in 3GPP2 C.S0005-A v6.0.
1399 * It is represented in units of 0.25 seconds and ranges from -2592000
1400 * to 2592000, both values inclusive (corresponding to a range of -180
Wink Savillec57b3eb2013-04-17 12:51:41 -07001401 * to +180 degrees). INT_MAX if unknown */
Wink Saville8a9e0212013-04-09 12:11:38 -07001402
1403 int latitude; /* Latitude is a decimal number as specified in 3GPP2 C.S0005-A v6.0.
1404 * It is represented in units of 0.25 seconds and ranges from -1296000
1405 * to 1296000, both values inclusive (corresponding to a range of -90
Wink Savillec57b3eb2013-04-17 12:51:41 -07001406 * to +90 degrees). INT_MAX if unknown */
Wink Saville8a9e0212013-04-09 12:11:38 -07001407} RIL_CellIdentityCdma;
1408
Wink Saville8a9e0212013-04-09 12:11:38 -07001409typedef struct {
Wink Savillec57b3eb2013-04-17 12:51:41 -07001410 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1411 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1412 int ci; /* 28-bit Cell Identity described in TS ???, INT_MAX if unknown */
1413 int pci; /* physical cell id 0..503, INT_MAX if unknown */
1414 int tac; /* 16-bit tracking area code, INT_MAX if unknown */
Wink Saville8a9e0212013-04-09 12:11:38 -07001415} RIL_CellIdentityLte;
1416
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001417typedef struct {
1418 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1419 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1420 int ci; /* 28-bit Cell Identity described in TS ???, INT_MAX if unknown */
Nathan Harold5ce4b2a2017-08-29 16:59:03 -07001421 int pci; /* physical cell id 0..503; this value must be reported */
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001422 int tac; /* 16-bit tracking area code, INT_MAX if unknown */
Nathan Harold5ce4b2a2017-08-29 16:59:03 -07001423 int earfcn; /* 18-bit LTE Absolute RF Channel Number; this value must be reported */
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001424} RIL_CellIdentityLte_v12;
1425
Etan Cohend3652192014-06-20 08:28:44 -07001426typedef struct {
1427 int mcc; /* 3-digit Mobile Country Code, 0..999, INT_MAX if unknown */
1428 int mnc; /* 2 or 3-digit Mobile Network Code, 0..999, INT_MAX if unknown */
1429 int lac; /* 16-bit Location Area Code, 0..65535, INT_MAX if unknown */
1430 int cid; /* 28-bit UMTS Cell Identity described in TS 25.331, 0..268435455, INT_MAX if unknown */
1431 int cpid; /* 8-bit Cell Parameters ID described in TS 25.331, 0..127, INT_MAX if unknown */
1432} RIL_CellIdentityTdscdma;
1433
Wink Saville8a9e0212013-04-09 12:11:38 -07001434typedef struct {
1435 RIL_CellIdentityGsm cellIdentityGsm;
1436 RIL_GW_SignalStrength signalStrengthGsm;
1437} RIL_CellInfoGsm;
1438
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001439typedef struct {
1440 RIL_CellIdentityGsm_v12 cellIdentityGsm;
1441 RIL_GSM_SignalStrength_v12 signalStrengthGsm;
1442} RIL_CellInfoGsm_v12;
1443
Wink Savillec57b3eb2013-04-17 12:51:41 -07001444typedef struct {
1445 RIL_CellIdentityWcdma cellIdentityWcdma;
1446 RIL_SignalStrengthWcdma signalStrengthWcdma;
1447} RIL_CellInfoWcdma;
1448
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001449typedef struct {
1450 RIL_CellIdentityWcdma_v12 cellIdentityWcdma;
1451 RIL_SignalStrengthWcdma signalStrengthWcdma;
1452} RIL_CellInfoWcdma_v12;
1453
Wink Saville8a9e0212013-04-09 12:11:38 -07001454typedef struct {
1455 RIL_CellIdentityCdma cellIdentityCdma;
1456 RIL_CDMA_SignalStrength signalStrengthCdma;
1457 RIL_EVDO_SignalStrength signalStrengthEvdo;
1458} RIL_CellInfoCdma;
1459
Wink Saville8a9e0212013-04-09 12:11:38 -07001460typedef struct {
1461 RIL_CellIdentityLte cellIdentityLte;
1462 RIL_LTE_SignalStrength_v8 signalStrengthLte;
1463} RIL_CellInfoLte;
1464
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001465typedef struct {
1466 RIL_CellIdentityLte_v12 cellIdentityLte;
1467 RIL_LTE_SignalStrength_v8 signalStrengthLte;
1468} RIL_CellInfoLte_v12;
1469
Etan Cohend3652192014-06-20 08:28:44 -07001470typedef struct {
1471 RIL_CellIdentityTdscdma cellIdentityTdscdma;
1472 RIL_TD_SCDMA_SignalStrength signalStrengthTdscdma;
1473} RIL_CellInfoTdscdma;
1474
Wink Saville8a9e0212013-04-09 12:11:38 -07001475// Must be the same as CellInfo.TYPE_XXX
1476typedef enum {
Sooraj Sasindranf4714b72016-11-30 18:36:03 -08001477 RIL_CELL_INFO_TYPE_NONE = 0, /* indicates no cell information */
Wink Saville8a9e0212013-04-09 12:11:38 -07001478 RIL_CELL_INFO_TYPE_GSM = 1,
1479 RIL_CELL_INFO_TYPE_CDMA = 2,
1480 RIL_CELL_INFO_TYPE_LTE = 3,
Wink Savillec57b3eb2013-04-17 12:51:41 -07001481 RIL_CELL_INFO_TYPE_WCDMA = 4,
Etan Cohend3652192014-06-20 08:28:44 -07001482 RIL_CELL_INFO_TYPE_TD_SCDMA = 5
Wink Saville8a9e0212013-04-09 12:11:38 -07001483} RIL_CellInfoType;
1484
1485// Must be the same as CellInfo.TIMESTAMP_TYPE_XXX
1486typedef enum {
1487 RIL_TIMESTAMP_TYPE_UNKNOWN = 0,
1488 RIL_TIMESTAMP_TYPE_ANTENNA = 1,
1489 RIL_TIMESTAMP_TYPE_MODEM = 2,
1490 RIL_TIMESTAMP_TYPE_OEM_RIL = 3,
1491 RIL_TIMESTAMP_TYPE_JAVA_RIL = 4,
1492} RIL_TimeStampType;
1493
1494typedef struct {
1495 RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */
1496 int registered; /* !0 if this cell is registered 0 if not registered */
1497 RIL_TimeStampType timeStampType; /* type of time stamp represented by timeStamp */
1498 uint64_t timeStamp; /* Time in nanos as returned by ril_nano_time */
1499 union {
1500 RIL_CellInfoGsm gsm;
1501 RIL_CellInfoCdma cdma;
1502 RIL_CellInfoLte lte;
Wink Savillec57b3eb2013-04-17 12:51:41 -07001503 RIL_CellInfoWcdma wcdma;
Etan Cohend3652192014-06-20 08:28:44 -07001504 RIL_CellInfoTdscdma tdscdma;
Wink Saville8a9e0212013-04-09 12:11:38 -07001505 } CellInfo;
1506} RIL_CellInfo;
1507
Sanket Padawef53c5fa2016-01-27 10:00:38 -08001508typedef struct {
1509 RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */
1510 int registered; /* !0 if this cell is registered 0 if not registered */
1511 RIL_TimeStampType timeStampType; /* type of time stamp represented by timeStamp */
1512 uint64_t timeStamp; /* Time in nanos as returned by ril_nano_time */
1513 union {
1514 RIL_CellInfoGsm_v12 gsm;
1515 RIL_CellInfoCdma cdma;
1516 RIL_CellInfoLte_v12 lte;
1517 RIL_CellInfoWcdma_v12 wcdma;
1518 RIL_CellInfoTdscdma tdscdma;
1519 } CellInfo;
1520} RIL_CellInfo_v12;
1521
Sooraj Sasindranf4714b72016-11-30 18:36:03 -08001522typedef struct {
1523 RIL_CellInfoType cellInfoType; /* cell type for selecting from union CellInfo */
1524 union {
1525 RIL_CellIdentityGsm_v12 cellIdentityGsm;
1526 RIL_CellIdentityWcdma_v12 cellIdentityWcdma;
1527 RIL_CellIdentityLte_v12 cellIdentityLte;
1528 RIL_CellIdentityTdscdma cellIdentityTdscdma;
1529 RIL_CellIdentityCdma cellIdentityCdma;
1530 };
1531}RIL_CellIdentity_v16;
1532
1533typedef struct {
1534 RIL_RegState regState; // Valid reg states are RIL_NOT_REG_AND_NOT_SEARCHING,
1535 // REG_HOME, RIL_NOT_REG_AND_SEARCHING, REG_DENIED,
1536 // UNKNOWN, REG_ROAMING defined in RegState
1537 RIL_RadioTechnology rat; // indicates the available voice radio technology,
1538 // valid values as defined by RadioTechnology.
1539 int32_t cssSupported; // concurrent services support indicator. if
1540 // registered on a CDMA system.
1541 // 0 - Concurrent services not supported,
1542 // 1 - Concurrent services supported
1543 int32_t roamingIndicator; // TSB-58 Roaming Indicator if registered
1544 // on a CDMA or EVDO system or -1 if not.
1545 // Valid values are 0-255.
1546 int32_t systemIsInPrl; // indicates whether the current system is in the
1547 // PRL if registered on a CDMA or EVDO system or -1 if
1548 // not. 0=not in the PRL, 1=in the PRL
1549 int32_t defaultRoamingIndicator; // default Roaming Indicator from the PRL,
1550 // if registered on a CDMA or EVDO system or -1 if not.
1551 // Valid values are 0-255.
1552 int32_t reasonForDenial; // reasonForDenial if registration state is 3
1553 // (Registration denied) this is an enumerated reason why
1554 // registration was denied. See 3GPP TS 24.008,
1555 // 10.5.3.6 and Annex G.
1556 // 0 - General
1557 // 1 - Authentication Failure
1558 // 2 - IMSI unknown in HLR
1559 // 3 - Illegal MS
1560 // 4 - Illegal ME
1561 // 5 - PLMN not allowed
1562 // 6 - Location area not allowed
1563 // 7 - Roaming not allowed
1564 // 8 - No Suitable Cells in this Location Area
1565 // 9 - Network failure
1566 // 10 - Persistent location update reject
1567 // 11 - PLMN not allowed
1568 // 12 - Location area not allowed
1569 // 13 - Roaming not allowed in this Location Area
1570 // 15 - No Suitable Cells in this Location Area
1571 // 17 - Network Failure
1572 // 20 - MAC Failure
1573 // 21 - Sync Failure
1574 // 22 - Congestion
1575 // 23 - GSM Authentication unacceptable
1576 // 25 - Not Authorized for this CSG
1577 // 32 - Service option not supported
1578 // 33 - Requested service option not subscribed
1579 // 34 - Service option temporarily out of order
1580 // 38 - Call cannot be identified
1581 // 48-63 - Retry upon entry into a new cell
1582 // 95 - Semantically incorrect message
1583 // 96 - Invalid mandatory information
1584 // 97 - Message type non-existent or not implemented
1585 // 98 - Message type not compatible with protocol state
1586 // 99 - Information element non-existent or
1587 // not implemented
1588 // 100 - Conditional IE error
1589 // 101 - Message not compatible with protocol state;
1590 RIL_CellIdentity_v16 cellIdentity; // current cell information
1591}RIL_VoiceRegistrationStateResponse;
1592
1593
1594typedef struct {
1595 RIL_RegState regState; // Valid reg states are RIL_NOT_REG_AND_NOT_SEARCHING,
1596 // REG_HOME, RIL_NOT_REG_AND_SEARCHING, REG_DENIED,
1597 // UNKNOWN, REG_ROAMING defined in RegState
1598 RIL_RadioTechnology rat; // indicates the available data radio technology,
1599 // valid values as defined by RadioTechnology.
1600 int32_t reasonDataDenied; // if registration state is 3 (Registration
1601 // denied) this is an enumerated reason why
1602 // registration was denied. See 3GPP TS 24.008,
1603 // Annex G.6 "Additional cause codes for GMM".
1604 // 7 == GPRS services not allowed
1605 // 8 == GPRS services and non-GPRS services not allowed
1606 // 9 == MS identity cannot be derived by the network
1607 // 10 == Implicitly detached
1608 // 14 == GPRS services not allowed in this PLMN
1609 // 16 == MSC temporarily not reachable
1610 // 40 == No PDP context activated
1611 int32_t maxDataCalls; // The maximum number of simultaneous Data Calls that
1612 // must be established using setupDataCall().
1613 RIL_CellIdentity_v16 cellIdentity; // Current cell information
1614}RIL_DataRegistrationStateResponse;
1615
Wink Saville1b5fd232009-04-22 14:50:00 -07001616/* Names of the CDMA info records (C.S0005 section 3.7.5) */
1617typedef enum {
1618 RIL_CDMA_DISPLAY_INFO_REC,
1619 RIL_CDMA_CALLED_PARTY_NUMBER_INFO_REC,
1620 RIL_CDMA_CALLING_PARTY_NUMBER_INFO_REC,
1621 RIL_CDMA_CONNECTED_NUMBER_INFO_REC,
1622 RIL_CDMA_SIGNAL_INFO_REC,
1623 RIL_CDMA_REDIRECTING_NUMBER_INFO_REC,
1624 RIL_CDMA_LINE_CONTROL_INFO_REC,
1625 RIL_CDMA_EXTENDED_DISPLAY_INFO_REC,
1626 RIL_CDMA_T53_CLIR_INFO_REC,
1627 RIL_CDMA_T53_RELEASE_INFO_REC,
1628 RIL_CDMA_T53_AUDIO_CONTROL_INFO_REC
1629} RIL_CDMA_InfoRecName;
1630
1631/* Display Info Rec as defined in C.S0005 section 3.7.5.1
1632 Extended Display Info Rec as defined in C.S0005 section 3.7.5.16
1633 Note: the Extended Display info rec contains multiple records of the
1634 form: display_tag, display_len, and display_len occurrences of the
1635 chari field if the display_tag is not 10000000 or 10000001.
1636 To save space, the records are stored consecutively in a byte buffer.
1637 The display_tag, display_len and chari fields are all 1 byte.
1638*/
1639
1640typedef struct {
1641 char alpha_len;
Wink Savillea592eeb2009-05-22 13:26:36 -07001642 char alpha_buf[CDMA_ALPHA_INFO_BUFFER_LENGTH];
Wink Saville1b5fd232009-04-22 14:50:00 -07001643} RIL_CDMA_DisplayInfoRecord;
1644
1645/* Called Party Number Info Rec as defined in C.S0005 section 3.7.5.2
1646 Calling Party Number Info Rec as defined in C.S0005 section 3.7.5.3
1647 Connected Number Info Rec as defined in C.S0005 section 3.7.5.4
1648*/
1649
1650typedef struct {
1651 char len;
Wink Savillea592eeb2009-05-22 13:26:36 -07001652 char buf[CDMA_NUMBER_INFO_BUFFER_LENGTH];
Wink Saville1b5fd232009-04-22 14:50:00 -07001653 char number_type;
1654 char number_plan;
1655 char pi;
1656 char si;
1657} RIL_CDMA_NumberInfoRecord;
1658
1659/* Redirecting Number Information Record as defined in C.S0005 section 3.7.5.11 */
1660typedef enum {
1661 RIL_REDIRECTING_REASON_UNKNOWN = 0,
1662 RIL_REDIRECTING_REASON_CALL_FORWARDING_BUSY = 1,
1663 RIL_REDIRECTING_REASON_CALL_FORWARDING_NO_REPLY = 2,
1664 RIL_REDIRECTING_REASON_CALLED_DTE_OUT_OF_ORDER = 9,
1665 RIL_REDIRECTING_REASON_CALL_FORWARDING_BY_THE_CALLED_DTE = 10,
1666 RIL_REDIRECTING_REASON_CALL_FORWARDING_UNCONDITIONAL = 15,
1667 RIL_REDIRECTING_REASON_RESERVED
1668} RIL_CDMA_RedirectingReason;
1669
1670typedef struct {
1671 RIL_CDMA_NumberInfoRecord redirectingNumber;
1672 /* redirectingReason is set to RIL_REDIRECTING_REASON_UNKNOWN if not included */
1673 RIL_CDMA_RedirectingReason redirectingReason;
1674} RIL_CDMA_RedirectingNumberInfoRecord;
1675
1676/* Line Control Information Record as defined in C.S0005 section 3.7.5.15 */
1677typedef struct {
1678 char lineCtrlPolarityIncluded;
1679 char lineCtrlToggle;
1680 char lineCtrlReverse;
1681 char lineCtrlPowerDenial;
1682} RIL_CDMA_LineControlInfoRecord;
1683
1684/* T53 CLIR Information Record */
1685typedef struct {
1686 char cause;
1687} RIL_CDMA_T53_CLIRInfoRecord;
1688
1689/* T53 Audio Control Information Record */
1690typedef struct {
1691 char upLink;
1692 char downLink;
1693} RIL_CDMA_T53_AudioControlInfoRecord;
1694
1695typedef struct {
1696
1697 RIL_CDMA_InfoRecName name;
1698
1699 union {
1700 /* Display and Extended Display Info Rec */
1701 RIL_CDMA_DisplayInfoRecord display;
1702
1703 /* Called Party Number, Calling Party Number, Connected Number Info Rec */
1704 RIL_CDMA_NumberInfoRecord number;
1705
1706 /* Signal Info Rec */
1707 RIL_CDMA_SignalInfoRecord signal;
1708
1709 /* Redirecting Number Info Rec */
1710 RIL_CDMA_RedirectingNumberInfoRecord redir;
1711
1712 /* Line Control Info Rec */
1713 RIL_CDMA_LineControlInfoRecord lineCtrl;
1714
1715 /* T53 CLIR Info Rec */
1716 RIL_CDMA_T53_CLIRInfoRecord clir;
1717
1718 /* T53 Audio Control Info Rec */
1719 RIL_CDMA_T53_AudioControlInfoRecord audioCtrl;
1720 } rec;
1721} RIL_CDMA_InformationRecord;
1722
1723#define RIL_CDMA_MAX_NUMBER_OF_INFO_RECS 10
1724
1725typedef struct {
1726 char numberOfInfoRecs;
1727 RIL_CDMA_InformationRecord infoRec[RIL_CDMA_MAX_NUMBER_OF_INFO_RECS];
1728} RIL_CDMA_InformationRecords;
1729
Jake Hamby8a4a2332014-01-15 13:12:05 -08001730/* See RIL_REQUEST_NV_READ_ITEM */
1731typedef struct {
1732 RIL_NV_Item itemID;
1733} RIL_NV_ReadItem;
1734
1735/* See RIL_REQUEST_NV_WRITE_ITEM */
1736typedef struct {
1737 RIL_NV_Item itemID;
1738 char * value;
1739} RIL_NV_WriteItem;
1740
Etan Cohend3652192014-06-20 08:28:44 -07001741typedef enum {
1742 HANDOVER_STARTED = 0,
1743 HANDOVER_COMPLETED = 1,
1744 HANDOVER_FAILED = 2,
1745 HANDOVER_CANCELED = 3
1746} RIL_SrvccState;
1747
1748/* hardware configuration reported to RILJ. */
1749typedef enum {
1750 RIL_HARDWARE_CONFIG_MODEM = 0,
1751 RIL_HARDWARE_CONFIG_SIM = 1,
1752} RIL_HardwareConfig_Type;
1753
1754typedef enum {
1755 RIL_HARDWARE_CONFIG_STATE_ENABLED = 0,
1756 RIL_HARDWARE_CONFIG_STATE_STANDBY = 1,
1757 RIL_HARDWARE_CONFIG_STATE_DISABLED = 2,
1758} RIL_HardwareConfig_State;
1759
1760typedef struct {
1761 int rilModel;
1762 uint32_t rat; /* bitset - ref. RIL_RadioTechnology. */
1763 int maxVoice;
1764 int maxData;
1765 int maxStandby;
1766} RIL_HardwareConfig_Modem;
1767
1768typedef struct {
Wink Saville8b4e4f72014-10-17 15:01:45 -07001769 char modemUuid[MAX_UUID_LENGTH];
Etan Cohend3652192014-06-20 08:28:44 -07001770} RIL_HardwareConfig_Sim;
1771
1772typedef struct {
1773 RIL_HardwareConfig_Type type;
Wink Saville8b4e4f72014-10-17 15:01:45 -07001774 char uuid[MAX_UUID_LENGTH];
Etan Cohend3652192014-06-20 08:28:44 -07001775 RIL_HardwareConfig_State state;
1776 union {
1777 RIL_HardwareConfig_Modem modem;
1778 RIL_HardwareConfig_Sim sim;
1779 } cfg;
1780} RIL_HardwareConfig;
1781
Amit Mahajan54563d32014-11-22 00:54:49 +00001782typedef enum {
1783 SS_CFU,
1784 SS_CF_BUSY,
1785 SS_CF_NO_REPLY,
1786 SS_CF_NOT_REACHABLE,
1787 SS_CF_ALL,
1788 SS_CF_ALL_CONDITIONAL,
1789 SS_CLIP,
1790 SS_CLIR,
1791 SS_COLP,
1792 SS_COLR,
1793 SS_WAIT,
1794 SS_BAOC,
1795 SS_BAOIC,
1796 SS_BAOIC_EXC_HOME,
1797 SS_BAIC,
1798 SS_BAIC_ROAMING,
1799 SS_ALL_BARRING,
1800 SS_OUTGOING_BARRING,
1801 SS_INCOMING_BARRING
1802} RIL_SsServiceType;
1803
1804typedef enum {
1805 SS_ACTIVATION,
1806 SS_DEACTIVATION,
1807 SS_INTERROGATION,
1808 SS_REGISTRATION,
1809 SS_ERASURE
1810} RIL_SsRequestType;
1811
1812typedef enum {
1813 SS_ALL_TELE_AND_BEARER_SERVICES,
1814 SS_ALL_TELESEVICES,
1815 SS_TELEPHONY,
1816 SS_ALL_DATA_TELESERVICES,
1817 SS_SMS_SERVICES,
1818 SS_ALL_TELESERVICES_EXCEPT_SMS
1819} RIL_SsTeleserviceType;
1820
1821#define SS_INFO_MAX 4
1822#define NUM_SERVICE_CLASSES 7
1823
1824typedef struct {
1825 int numValidIndexes; /* This gives the number of valid values in cfInfo.
1826 For example if voice is forwarded to one number and data
1827 is forwarded to a different one then numValidIndexes will be
1828 2 indicating total number of valid values in cfInfo.
1829 Similarly if all the services are forwarded to the same
1830 number then the value of numValidIndexes will be 1. */
1831
1832 RIL_CallForwardInfo cfInfo[NUM_SERVICE_CLASSES]; /* This is the response data
1833 for SS request to query call
1834 forward status. see
1835 RIL_REQUEST_QUERY_CALL_FORWARD_STATUS */
1836} RIL_CfData;
1837
1838typedef struct {
1839 RIL_SsServiceType serviceType;
1840 RIL_SsRequestType requestType;
1841 RIL_SsTeleserviceType teleserviceType;
1842 int serviceClass;
1843 RIL_Errno result;
1844
1845 union {
1846 int ssInfo[SS_INFO_MAX]; /* This is the response data for most of the SS GET/SET
1847 RIL requests. E.g. RIL_REQUSET_GET_CLIR returns
1848 two ints, so first two values of ssInfo[] will be
1849 used for response if serviceType is SS_CLIR and
1850 requestType is SS_INTERROGATION */
1851
1852 RIL_CfData cfData;
1853 };
1854} RIL_StkCcUnsolSsResponse;
1855
Wink Saville7f856802009-06-09 10:23:37 -07001856/**
Wink Savillec29360a2014-07-13 05:17:28 -07001857 * Data connection power state
1858 */
1859typedef enum {
1860 RIL_DC_POWER_STATE_LOW = 1, // Low power state
1861 RIL_DC_POWER_STATE_MEDIUM = 2, // Medium power state
1862 RIL_DC_POWER_STATE_HIGH = 3, // High power state
1863 RIL_DC_POWER_STATE_UNKNOWN = INT32_MAX // Unknown state
1864} RIL_DcPowerStates;
1865
1866/**
1867 * Data connection real time info
1868 */
1869typedef struct {
1870 uint64_t time; // Time in nanos as returned by ril_nano_time
1871 RIL_DcPowerStates powerState; // Current power state
1872} RIL_DcRtInfo;
1873
Amit Mahajanc796e222014-08-13 16:54:01 +00001874/**
1875 * Data profile to modem
1876 */
1877typedef struct {
1878 /* id of the data profile */
1879 int profileId;
1880 /* the APN to connect to */
1881 char* apn;
1882 /** one of the PDP_type values in TS 27.007 section 10.1.1.
1883 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
1884 */
1885 char* protocol;
1886 /** authentication protocol used for this PDP context
1887 * (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3)
1888 */
1889 int authType;
1890 /* the username for APN, or NULL */
1891 char* user;
1892 /* the password for APN, or NULL */
1893 char* password;
1894 /* the profile type, TYPE_COMMON-0, TYPE_3GPP-1, TYPE_3GPP2-2 */
1895 int type;
1896 /* the period in seconds to limit the maximum connections */
1897 int maxConnsTime;
1898 /* the maximum connections during maxConnsTime */
1899 int maxConns;
1900 /** the required wait time in seconds after a successful UE initiated
1901 * disconnect of a given PDN connection before the device can send
1902 * a new PDN connection request for that given PDN
1903 */
1904 int waitTime;
1905 /* true to enable the profile, 0 to disable, 1 to enable */
1906 int enabled;
1907} RIL_DataProfileInfo;
Wink Savillec29360a2014-07-13 05:17:28 -07001908
Jack Yude8c8552017-01-24 12:03:52 -08001909typedef struct {
1910 /* id of the data profile */
1911 int profileId;
1912 /* the APN to connect to */
1913 char* apn;
1914 /** one of the PDP_type values in TS 27.007 section 10.1.1.
1915 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
1916 */
1917 char* protocol;
1918 /** one of the PDP_type values in TS 27.007 section 10.1.1 used on roaming network.
1919 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
1920 */
1921 char *roamingProtocol;
1922 /** authentication protocol used for this PDP context
1923 * (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3)
1924 */
1925 int authType;
1926 /* the username for APN, or NULL */
1927 char* user;
1928 /* the password for APN, or NULL */
1929 char* password;
1930 /* the profile type, TYPE_COMMON-0, TYPE_3GPP-1, TYPE_3GPP2-2 */
1931 int type;
1932 /* the period in seconds to limit the maximum connections */
1933 int maxConnsTime;
1934 /* the maximum connections during maxConnsTime */
1935 int maxConns;
1936 /** the required wait time in seconds after a successful UE initiated
1937 * disconnect of a given PDN connection before the device can send
1938 * a new PDN connection request for that given PDN
1939 */
1940 int waitTime;
1941 /* true to enable the profile, 0 to disable, 1 to enable */
1942 int enabled;
1943 /* supported APN types bitmask. See RIL_ApnTypes for the value of each bit. */
1944 int supportedTypesBitmask;
1945 /** the bearer bitmask. See RIL_RadioAccessFamily for the value of each bit. */
1946 int bearerBitmask;
1947 /** maximum transmission unit (MTU) size in bytes */
1948 int mtu;
1949 /** the MVNO type: possible values are "imsi", "gid", "spn" */
1950 char *mvnoType;
1951 /** MVNO match data. Can be anything defined by the carrier. For example,
1952 * SPN like: "A MOBILE", "BEN NL", etc...
1953 * IMSI like: "302720x94", "2060188", etc...
1954 * GID like: "4E", "33", etc...
1955 */
1956 char *mvnoMatchData;
1957} RIL_DataProfileInfo_v15;
1958
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001959/* Tx Power Levels */
Prerepa Viswanadham73157492015-05-28 00:37:32 -07001960#define RIL_NUM_TX_POWER_LEVELS 5
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001961
Nathan Haroldc8635212016-10-10 11:15:21 -07001962/**
1963 * Aggregate modem activity information
1964 */
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001965typedef struct {
1966
Nathan Haroldc8635212016-10-10 11:15:21 -07001967 /* total time (in ms) when modem is in a low power or
1968 * sleep state
1969 */
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001970 uint32_t sleep_mode_time_ms;
1971
Nathan Haroldc8635212016-10-10 11:15:21 -07001972 /* total time (in ms) when modem is awake but neither
1973 * the transmitter nor receiver are active/awake */
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001974 uint32_t idle_mode_time_ms;
1975
Nathan Haroldc8635212016-10-10 11:15:21 -07001976 /* total time (in ms) during which the transmitter is active/awake,
1977 * subdivided by manufacturer-defined device-specific
1978 * contiguous increasing ranges of transmit power between
1979 * 0 and the transmitter's maximum transmit power.
1980 */
Prerepa Viswanadham73157492015-05-28 00:37:32 -07001981 uint32_t tx_mode_time_ms[RIL_NUM_TX_POWER_LEVELS];
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001982
Nathan Haroldc8635212016-10-10 11:15:21 -07001983 /* total time (in ms) for which receiver is active/awake and
1984 * the transmitter is inactive */
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07001985 uint32_t rx_mode_time_ms;
1986} RIL_ActivityStatsInfo;
1987
Jack Yude8c8552017-01-24 12:03:52 -08001988typedef enum {
1989 RIL_APN_TYPE_UNKNOWN = 0x0, // Unknown
1990 RIL_APN_TYPE_DEFAULT = 0x1, // APN type for default data traffic
1991 RIL_APN_TYPE_MMS = 0x2, // APN type for MMS traffic
1992 RIL_APN_TYPE_SUPL = 0x4, // APN type for SUPL assisted GPS
1993 RIL_APN_TYPE_DUN = 0x8, // APN type for DUN traffic
1994 RIL_APN_TYPE_HIPRI = 0x10, // APN type for HiPri traffic
1995 RIL_APN_TYPE_FOTA = 0x20, // APN type for FOTA
1996 RIL_APN_TYPE_IMS = 0x40, // APN type for IMS
1997 RIL_APN_TYPE_CBS = 0x80, // APN type for CBS
1998 RIL_APN_TYPE_IA = 0x100, // APN type for IA Initial Attach APN
1999 RIL_APN_TYPE_EMERGENCY = 0x200, // APN type for Emergency PDN. This is not an IA apn,
2000 // but is used for access to carrier services in an
2001 // emergency call situation.
2002 RIL_APN_TYPE_ALL = 0xFFFFFFFF // All APN types
2003} RIL_ApnTypes;
2004
2005typedef enum {
2006 RIL_DST_POWER_SAVE_MODE, // Device power save mode (provided by PowerManager)
2007 // True indicates the device is in power save mode.
2008 RIL_DST_CHARGING_STATE, // Device charging state (provided by BatteryManager)
2009 // True indicates the device is charging.
2010 RIL_DST_LOW_DATA_EXPECTED // Low data expected mode. True indicates low data traffic
2011 // is expected, for example, when the device is idle
2012 // (e.g. not doing tethering in the background). Note
2013 // this doesn't mean no data is expected.
2014} RIL_DeviceStateType;
2015
2016typedef enum {
2017 RIL_UR_SIGNAL_STRENGTH = 0x01, // When this bit is set, modem should always send the
2018 // signal strength update through
2019 // RIL_UNSOL_SIGNAL_STRENGTH, otherwise suppress it.
2020 RIL_UR_FULL_NETWORK_STATE = 0x02, // When this bit is set, modem should always send
2021 // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED
2022 // when any field in
2023 // RIL_REQUEST_VOICE_REGISTRATION_STATE or
2024 // RIL_REQUEST_DATA_REGISTRATION_STATE changes. When
2025 // this bit is not set, modem should suppress
2026 // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED
2027 // only when insignificant fields change
2028 // (e.g. cell info).
2029 // Modem should continue sending
2030 // RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED
2031 // when significant fields are updated even when this
2032 // bit is not set. The following fields are
2033 // considered significant, registration state and
2034 // radio technology.
2035 RIL_UR_DATA_CALL_DORMANCY_CHANGED = 0x04 // When this bit is set, modem should send the data
2036 // call list changed unsolicited response
2037 // RIL_UNSOL_DATA_CALL_LIST_CHANGED whenever any
2038 // field in RIL_Data_Call_Response changes.
2039 // Otherwise modem should suppress the unsolicited
2040 // response when the only changed field is 'active'
2041 // (for data dormancy). For all other fields change,
2042 // modem should continue sending
2043 // RIL_UNSOL_DATA_CALL_LIST_CHANGED regardless this
2044 // bit is set or not.
2045} RIL_UnsolicitedResponseFilter;
2046
Wileen Chiud6222e02015-11-23 14:25:22 -08002047typedef struct {
2048 char * aidPtr; /* AID value, See ETSI 102.221 and 101.220*/
2049 int p2; /* P2 parameter (described in ISO 7816-4)
2050 P2Constants:NO_P2 if to be ignored */
2051} RIL_OpenChannelParams;
2052
yinxu7317bd42017-05-03 15:15:19 -07002053typedef enum {
2054 RIL_ONE_SHOT = 0x01, // Performs the scan only once
2055 RIL_PERIODIC = 0x02 // Performs the scan periodically until cancelled
2056} RIL_ScanType;
2057
2058typedef enum {
2059 GERAN = 0x01, // GSM EDGE Radio Access Network
2060 UTRAN = 0x02, // Universal Terrestrial Radio Access Network
2061 EUTRAN = 0x03, // Evolved Universal Terrestrial Radio Access Network
2062} RIL_RadioAccessNetworks;
2063
2064typedef enum {
2065 GERAN_BAND_T380 = 1,
2066 GERAN_BAND_T410 = 2,
2067 GERAN_BAND_450 = 3,
2068 GERAN_BAND_480 = 4,
2069 GERAN_BAND_710 = 5,
2070 GERAN_BAND_750 = 6,
2071 GERAN_BAND_T810 = 7,
2072 GERAN_BAND_850 = 8,
2073 GERAN_BAND_P900 = 9,
2074 GERAN_BAND_E900 = 10,
2075 GERAN_BAND_R900 = 11,
2076 GERAN_BAND_DCS1800 = 12,
2077 GERAN_BAND_PCS1900 = 13,
2078 GERAN_BAND_ER900 = 14,
2079} RIL_GeranBands;
2080
2081typedef enum {
2082 UTRAN_BAND_1 = 1,
2083 UTRAN_BAND_2 = 2,
2084 UTRAN_BAND_3 = 3,
2085 UTRAN_BAND_4 = 4,
2086 UTRAN_BAND_5 = 5,
2087 UTRAN_BAND_6 = 6,
2088 UTRAN_BAND_7 = 7,
2089 UTRAN_BAND_8 = 8,
2090 UTRAN_BAND_9 = 9,
2091 UTRAN_BAND_10 = 10,
2092 UTRAN_BAND_11 = 11,
2093 UTRAN_BAND_12 = 12,
2094 UTRAN_BAND_13 = 13,
2095 UTRAN_BAND_14 = 14,
2096 UTRAN_BAND_19 = 19,
2097 UTRAN_BAND_20 = 20,
2098 UTRAN_BAND_21 = 21,
2099 UTRAN_BAND_22 = 22,
2100 UTRAN_BAND_25 = 25,
2101 UTRAN_BAND_26 = 26,
2102} RIL_UtranBands;
2103
2104typedef enum {
2105 EUTRAN_BAND_1 = 1,
2106 EUTRAN_BAND_2 = 2,
2107 EUTRAN_BAND_3 = 3,
2108 EUTRAN_BAND_4 = 4,
2109 EUTRAN_BAND_5 = 5,
2110 EUTRAN_BAND_6 = 6,
2111 EUTRAN_BAND_7 = 7,
2112 EUTRAN_BAND_8 = 8,
2113 EUTRAN_BAND_9 = 9,
2114 EUTRAN_BAND_10 = 10,
2115 EUTRAN_BAND_11 = 11,
2116 EUTRAN_BAND_12 = 12,
2117 EUTRAN_BAND_13 = 13,
2118 EUTRAN_BAND_14 = 14,
2119 EUTRAN_BAND_17 = 17,
2120 EUTRAN_BAND_18 = 18,
2121 EUTRAN_BAND_19 = 19,
2122 EUTRAN_BAND_20 = 20,
2123 EUTRAN_BAND_21 = 21,
2124 EUTRAN_BAND_22 = 22,
2125 EUTRAN_BAND_23 = 23,
2126 EUTRAN_BAND_24 = 24,
2127 EUTRAN_BAND_25 = 25,
2128 EUTRAN_BAND_26 = 26,
2129 EUTRAN_BAND_27 = 27,
2130 EUTRAN_BAND_28 = 28,
2131 EUTRAN_BAND_30 = 30,
2132 EUTRAN_BAND_31 = 31,
2133 EUTRAN_BAND_33 = 33,
2134 EUTRAN_BAND_34 = 34,
2135 EUTRAN_BAND_35 = 35,
2136 EUTRAN_BAND_36 = 36,
2137 EUTRAN_BAND_37 = 37,
2138 EUTRAN_BAND_38 = 38,
2139 EUTRAN_BAND_39 = 39,
2140 EUTRAN_BAND_40 = 40,
2141 EUTRAN_BAND_41 = 41,
2142 EUTRAN_BAND_42 = 42,
2143 EUTRAN_BAND_43 = 43,
2144 EUTRAN_BAND_44 = 44,
2145 EUTRAN_BAND_45 = 45,
2146 EUTRAN_BAND_46 = 46,
2147 EUTRAN_BAND_47 = 47,
2148 EUTRAN_BAND_48 = 48,
2149 EUTRAN_BAND_65 = 65,
2150 EUTRAN_BAND_66 = 66,
2151 EUTRAN_BAND_68 = 68,
2152 EUTRAN_BAND_70 = 70,
2153} RIL_EutranBands;
2154
2155typedef struct {
2156 RIL_RadioAccessNetworks radio_access_network; // The type of network to scan.
yinxu8688abd2017-05-22 11:26:45 -07002157 uint32_t bands_length; // Length of bands
yinxu7317bd42017-05-03 15:15:19 -07002158 union {
2159 RIL_GeranBands geran_bands[MAX_BANDS];
2160 RIL_UtranBands utran_bands[MAX_BANDS];
2161 RIL_EutranBands eutran_bands[MAX_BANDS];
2162 } bands;
yinxu8688abd2017-05-22 11:26:45 -07002163 uint32_t channels_length; // Length of channels
yinxu7317bd42017-05-03 15:15:19 -07002164 uint32_t channels[MAX_CHANNELS]; // Frequency channels to scan
2165} RIL_RadioAccessSpecifier;
2166
2167typedef struct {
2168 RIL_ScanType type; // Type of the scan
yinxu8688abd2017-05-22 11:26:45 -07002169 int32_t interval; // Time interval in seconds
2170 // between periodic scans, only
2171 // valid when type=RIL_PERIODIC
2172 uint32_t specifiers_length; // Length of specifiers
yinxu7317bd42017-05-03 15:15:19 -07002173 RIL_RadioAccessSpecifier specifiers[MAX_RADIO_ACCESS_NETWORKS]; // Radio access networks
2174 // with bands/channels.
2175} RIL_NetworkScanRequest;
2176
2177typedef enum {
2178 PARTIAL = 0x01, // The result contains a part of the scan results
2179 COMPLETE = 0x02, // The result contains the last part of the scan results
2180} RIL_ScanStatus;
2181
2182typedef struct {
yinxu8688abd2017-05-22 11:26:45 -07002183 RIL_ScanStatus status; // The status of the scan
2184 uint32_t network_infos_length; // Total length of RIL_CellInfo
2185 RIL_CellInfo_v12* network_infos; // List of network information
yinxu7317bd42017-05-03 15:15:19 -07002186} RIL_NetworkScanResult;
2187
Wink Savillec29360a2014-07-13 05:17:28 -07002188/**
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002189 * RIL_REQUEST_GET_SIM_STATUS
2190 *
2191 * Requests status of the SIM interface and the SIM card
Wink Saville7f856802009-06-09 10:23:37 -07002192 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002193 * "data" is NULL
2194 *
Wink Savillefd729372011-02-22 16:19:39 -08002195 * "response" is const RIL_CardStatus_v6 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002196 *
2197 * Valid errors:
sqiana216ed42017-06-20 11:54:31 -07002198 *
2199 * SUCCESS
2200 * RADIO_NOT_AVAILABLE
2201 * INTERNAL_ERR
2202 * NO_MEMORY
2203 * NO_RESOURCES
2204 * CANCELLED
2205 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002206 */
2207#define RIL_REQUEST_GET_SIM_STATUS 1
2208
2209/**
2210 * RIL_REQUEST_ENTER_SIM_PIN
2211 *
John Wang309ac292009-07-30 14:53:23 -07002212 * Supplies SIM PIN. Only called if RIL_CardStatus has RIL_APPSTATE_PIN state
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002213 *
2214 * "data" is const char **
2215 * ((const char **)data)[0] is PIN value
Wink Savillec0114b32011-02-18 10:14:07 -08002216 * ((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 Project00f06fc2009-03-03 19:32:15 -08002217 *
jsh593c9102009-06-24 16:13:44 -07002218 * "response" is int *
2219 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002220 *
2221 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002222 *
2223 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002224 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002225 * PASSWORD_INCORRECT
sqiana216ed42017-06-20 11:54:31 -07002226 * INTERNAL_ERR
2227 * NO_MEMORY
2228 * NO_RESOURCES
2229 * CANCELLED
2230 * INVALID_ARGUMENTS
2231 * INVALID_SIM_STATE
2232 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002233 */
2234
2235#define RIL_REQUEST_ENTER_SIM_PIN 2
2236
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002237/**
2238 * RIL_REQUEST_ENTER_SIM_PUK
2239 *
Wink Saville7f856802009-06-09 10:23:37 -07002240 * Supplies SIM PUK and new PIN.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002241 *
2242 * "data" is const char **
2243 * ((const char **)data)[0] is PUK value
2244 * ((const char **)data)[1] is new PIN value
Wink Savillec0114b32011-02-18 10:14:07 -08002245 * ((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 Project00f06fc2009-03-03 19:32:15 -08002246 *
jsh593c9102009-06-24 16:13:44 -07002247 * "response" is int *
2248 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002249 *
2250 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002251 *
2252 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002253 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002254 * PASSWORD_INCORRECT
2255 * (PUK is invalid)
sqiana216ed42017-06-20 11:54:31 -07002256 * INTERNAL_ERR
2257 * NO_MEMORY
2258 * NO_RESOURCES
2259 * CANCELLED
2260 * INVALID_ARGUMENTS
2261 * INVALID_SIM_STATE
2262 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002263 */
2264
2265#define RIL_REQUEST_ENTER_SIM_PUK 3
2266
2267/**
2268 * RIL_REQUEST_ENTER_SIM_PIN2
2269 *
2270 * Supplies SIM PIN2. Only called following operation where SIM_PIN2 was
2271 * returned as a a failure from a previous operation.
2272 *
2273 * "data" is const char **
2274 * ((const char **)data)[0] is PIN2 value
Wink Savillec0114b32011-02-18 10:14:07 -08002275 * ((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 Project00f06fc2009-03-03 19:32:15 -08002276 *
jsh593c9102009-06-24 16:13:44 -07002277 * "response" is int *
2278 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002279 *
2280 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002281 *
2282 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002283 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002284 * PASSWORD_INCORRECT
sqiana216ed42017-06-20 11:54:31 -07002285 * INTERNAL_ERR
2286 * NO_MEMORY
2287 * NO_RESOURCES
2288 * CANCELLED
2289 * INVALID_ARGUMENTS
2290 * INVALID_SIM_STATE
2291 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002292 */
2293
2294#define RIL_REQUEST_ENTER_SIM_PIN2 4
2295
2296/**
2297 * RIL_REQUEST_ENTER_SIM_PUK2
2298 *
Wink Saville7f856802009-06-09 10:23:37 -07002299 * Supplies SIM PUK2 and new PIN2.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002300 *
2301 * "data" is const char **
2302 * ((const char **)data)[0] is PUK2 value
2303 * ((const char **)data)[1] is new PIN2 value
Wink Savillec0114b32011-02-18 10:14:07 -08002304 * ((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 Project00f06fc2009-03-03 19:32:15 -08002305 *
jsh593c9102009-06-24 16:13:44 -07002306 * "response" is int *
2307 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002308 *
2309 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002310 *
2311 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002312 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002313 * PASSWORD_INCORRECT
2314 * (PUK2 is invalid)
sqiana216ed42017-06-20 11:54:31 -07002315 * INTERNAL_ERR
2316 * NO_MEMORY
2317 * NO_RESOURCES
2318 * CANCELLED
2319 * INVALID_ARGUMENTS
2320 * INVALID_SIM_STATE
2321 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002322 */
2323
2324#define RIL_REQUEST_ENTER_SIM_PUK2 5
2325
2326/**
2327 * RIL_REQUEST_CHANGE_SIM_PIN
2328 *
Wink Saville7f856802009-06-09 10:23:37 -07002329 * Supplies old SIM PIN and new PIN.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002330 *
2331 * "data" is const char **
2332 * ((const char **)data)[0] is old PIN value
2333 * ((const char **)data)[1] is new PIN value
Wink Savillec0114b32011-02-18 10:14:07 -08002334 * ((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 Project00f06fc2009-03-03 19:32:15 -08002335 *
jsh593c9102009-06-24 16:13:44 -07002336 * "response" is int *
2337 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002338 *
2339 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002340 *
2341 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002342 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002343 * PASSWORD_INCORRECT
2344 * (old PIN is invalid)
sqiana216ed42017-06-20 11:54:31 -07002345 * INTERNAL_ERR
2346 * NO_MEMORY
2347 * NO_RESOURCES
2348 * CANCELLED
2349 * INVALID_ARGUMENTS
2350 * INVALID_SIM_STATE
2351 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002352 */
2353
2354#define RIL_REQUEST_CHANGE_SIM_PIN 6
2355
2356
2357/**
2358 * RIL_REQUEST_CHANGE_SIM_PIN2
2359 *
Wink Saville7f856802009-06-09 10:23:37 -07002360 * Supplies old SIM PIN2 and new PIN2.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002361 *
2362 * "data" is const char **
2363 * ((const char **)data)[0] is old PIN2 value
2364 * ((const char **)data)[1] is new PIN2 value
Wink Savillec0114b32011-02-18 10:14:07 -08002365 * ((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 Project00f06fc2009-03-03 19:32:15 -08002366 *
jsh593c9102009-06-24 16:13:44 -07002367 * "response" is int *
2368 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002369 *
2370 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002371 *
2372 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002373 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002374 * PASSWORD_INCORRECT
2375 * (old PIN2 is invalid)
sqiana216ed42017-06-20 11:54:31 -07002376 * INTERNAL_ERR
2377 * NO_MEMORY
2378 * NO_RESOURCES
2379 * CANCELLED
2380 * INVALID_ARGUMENTS
2381 * INVALID_SIM_STATE
2382 * REQUEST_NOT_SUPPORTED
Wink Saville7f856802009-06-09 10:23:37 -07002383 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002384 */
2385
2386#define RIL_REQUEST_CHANGE_SIM_PIN2 7
2387
2388/**
2389 * RIL_REQUEST_ENTER_NETWORK_DEPERSONALIZATION
2390 *
2391 * Requests that network personlization be deactivated
2392 *
2393 * "data" is const char **
2394 * ((const char **)(data))[0]] is network depersonlization code
2395 *
jsh593c9102009-06-24 16:13:44 -07002396 * "response" is int *
2397 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002398 *
2399 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002400 *
2401 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002402 * RADIO_NOT_AVAILABLE (radio resetting)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002403 * PASSWORD_INCORRECT
2404 * (code is invalid)
Sanket Padaweceba34c2017-07-27 11:21:03 -07002405 * SIM_ABSENT
sqiana216ed42017-06-20 11:54:31 -07002406 * INTERNAL_ERR
2407 * NO_MEMORY
2408 * NO_RESOURCES
2409 * CANCELLED
2410 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002411 */
2412
2413#define RIL_REQUEST_ENTER_NETWORK_DEPERSONALIZATION 8
2414
2415/**
Wink Saville7f856802009-06-09 10:23:37 -07002416 * RIL_REQUEST_GET_CURRENT_CALLS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002417 *
2418 * Requests current call list
2419 *
2420 * "data" is NULL
2421 *
2422 * "response" must be a "const RIL_Call **"
Wink Saville7f856802009-06-09 10:23:37 -07002423 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002424 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002425 *
2426 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002427 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002428 * NO_MEMORY
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002429 * (request will be made again in a few hundred msec)
sqiana216ed42017-06-20 11:54:31 -07002430 * INTERNAL_ERR
2431 * NO_RESOURCES
2432 * CANCELLED
2433 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002434 */
2435
2436#define RIL_REQUEST_GET_CURRENT_CALLS 9
2437
2438
Wink Saville7f856802009-06-09 10:23:37 -07002439/**
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002440 * RIL_REQUEST_DIAL
2441 *
2442 * Initiate voice call
2443 *
2444 * "data" is const RIL_Dial *
2445 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07002446 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002447 * This method is never used for supplementary service codes
2448 *
2449 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002450 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002451 * RADIO_NOT_AVAILABLE (radio resetting)
Amit Mahajan54563d32014-11-22 00:54:49 +00002452 * DIAL_MODIFIED_TO_USSD
2453 * DIAL_MODIFIED_TO_SS
2454 * DIAL_MODIFIED_TO_DIAL
Ajay Nambi10345892016-03-19 09:02:28 -07002455 * INVALID_ARGUMENTS
2456 * NO_MEMORY
2457 * INVALID_STATE
2458 * NO_RESOURCES
2459 * INTERNAL_ERR
2460 * FDN_CHECK_FAILURE
2461 * MODEM_ERR
2462 * NO_SUBSCRIPTION
2463 * NO_NETWORK_FOUND
2464 * INVALID_CALL_ID
2465 * DEVICE_IN_USE
Naina Nalluri1d3f4482017-07-17 11:44:37 -07002466 * OPERATION_NOT_ALLOWED
Ajay Nambi10345892016-03-19 09:02:28 -07002467 * ABORTED
sqiana216ed42017-06-20 11:54:31 -07002468 * CANCELLED
2469 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002470 */
2471#define RIL_REQUEST_DIAL 10
2472
2473/**
2474 * RIL_REQUEST_GET_IMSI
2475 *
2476 * Get the SIM IMSI
2477 *
Naveen Kalla2bc78d62011-12-07 16:22:53 -08002478 * Only valid when radio state is "RADIO_STATE_ON"
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002479 *
Wink Savillec0114b32011-02-18 10:14:07 -08002480 * "data" is const char **
2481 * ((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 Project00f06fc2009-03-03 19:32:15 -08002482 * "response" is a const char * containing the IMSI
2483 *
2484 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002485 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002486 * RADIO_NOT_AVAILABLE (radio resetting)
sqiana216ed42017-06-20 11:54:31 -07002487 * INTERNAL_ERR
2488 * NO_MEMORY
2489 * NO_RESOURCES
2490 * CANCELLED
2491 * INVALID_SIM_STATE
2492 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002493 */
2494
2495#define RIL_REQUEST_GET_IMSI 11
2496
2497/**
2498 * RIL_REQUEST_HANGUP
2499 *
2500 * Hang up a specific line (like AT+CHLD=1x)
2501 *
John Wang06bae4b2010-11-18 16:37:09 -08002502 * After this HANGUP request returns, RIL should show the connection is NOT
2503 * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query.
2504 *
Wink Saville7f856802009-06-09 10:23:37 -07002505 * "data" is an int *
Wink Savillef4c4d362009-04-02 01:37:03 -07002506 * (int *)data)[0] contains Connection index (value of 'x' in CHLD above)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002507 *
2508 * "response" is NULL
2509 *
2510 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002511 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002512 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002513 * INVALID_ARGUMENTS
2514 * NO_MEMORY
2515 * INVALID_STATE
2516 * MODEM_ERR
2517 * INTERNAL_ERR
2518 * NO_MEMORY
2519 * INVALID_CALL_ID
2520 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07002521 * NO_RESOURCES
2522 * CANCELLED
2523 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002524 */
2525
2526#define RIL_REQUEST_HANGUP 12
2527
2528/**
2529 * RIL_REQUEST_HANGUP_WAITING_OR_BACKGROUND
2530 *
2531 * Hang up waiting or held (like AT+CHLD=0)
2532 *
John Wang06bae4b2010-11-18 16:37:09 -08002533 * After this HANGUP request returns, RIL should show the connection is NOT
2534 * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query.
2535 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002536 * "data" is NULL
2537 * "response" is NULL
2538 *
2539 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002540 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002541 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002542 * INVALID_STATE
2543 * NO_MEMORY
2544 * MODEM_ERR
2545 * INTERNAL_ERR
2546 * NO_MEMORY
2547 * INVALID_CALL_ID
2548 * NO_RESOURCES
2549 * OPERATION_NOT_ALLOWED
2550 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07002551 * NO_RESOURCES
2552 * CANCELLED
2553 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002554 */
2555
2556#define RIL_REQUEST_HANGUP_WAITING_OR_BACKGROUND 13
2557
2558/**
2559 * RIL_REQUEST_HANGUP_FOREGROUND_RESUME_BACKGROUND
2560 *
2561 * Hang up waiting or held (like AT+CHLD=1)
2562 *
John Wang06bae4b2010-11-18 16:37:09 -08002563 * After this HANGUP request returns, RIL should show the connection is NOT
2564 * active anymore in next RIL_REQUEST_GET_CURRENT_CALLS query.
2565 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002566 * "data" is NULL
2567 * "response" is NULL
2568 *
2569 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002570 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002571 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002572 * INVALID_STATE
2573 * NO_MEMORY
2574 * MODEM_ERR
2575 * INTERNAL_ERR
2576 * INVALID_CALL_ID
2577 * OPERATION_NOT_ALLOWED
2578 * INVALID_ARGUMENTS
2579 * NO_RESOURCES
sqiana216ed42017-06-20 11:54:31 -07002580 * CANCELLED
2581 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002582 */
2583
2584#define RIL_REQUEST_HANGUP_FOREGROUND_RESUME_BACKGROUND 14
2585
2586/**
2587 * RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE
2588 *
2589 * Switch waiting or holding call and active call (like AT+CHLD=2)
2590 *
2591 * State transitions should be is follows:
2592 *
2593 * If call 1 is waiting and call 2 is active, then if this re
2594 *
2595 * BEFORE AFTER
2596 * Call 1 Call 2 Call 1 Call 2
2597 * ACTIVE HOLDING HOLDING ACTIVE
2598 * ACTIVE WAITING HOLDING ACTIVE
2599 * HOLDING WAITING HOLDING ACTIVE
2600 * ACTIVE IDLE HOLDING IDLE
2601 * IDLE IDLE IDLE IDLE
2602 *
2603 * "data" is NULL
2604 * "response" is NULL
2605 *
2606 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002607 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002608 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002609 * INVALID_STATE
2610 * NO_MEMORY
2611 * MODEM_ERR
2612 * INTERNAL_ERR
2613 * INVALID_STATE
2614 * INVALID_ARGUMENTS
2615 * INVALID_CALL_ID
2616 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07002617 * NO_RESOURCES
2618 * CANCELLED
2619 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002620 */
2621
2622#define RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE 15
2623#define RIL_REQUEST_SWITCH_HOLDING_AND_ACTIVE 15
2624
2625/**
2626 * RIL_REQUEST_CONFERENCE
2627 *
2628 * Conference holding and active (like AT+CHLD=3)
2629
2630 * "data" is NULL
2631 * "response" is NULL
2632 *
2633 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002634 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002635 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002636 * NO_MEMORY
2637 * MODEM_ERR
2638 * INTERNAL_ERR
2639 * INVALID_STATE
2640 * INVALID_CALL_ID
2641 * INVALID_ARGUMENTS
2642 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07002643 * NO_RESOURCES
2644 * CANCELLED
2645 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002646 */
2647#define RIL_REQUEST_CONFERENCE 16
2648
2649/**
2650 * RIL_REQUEST_UDUB
2651 *
Wink Saville7f856802009-06-09 10:23:37 -07002652 * Send UDUB (user determined used busy) to ringing or
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002653 * waiting call answer)(RIL_BasicRequest r);
2654 *
2655 * "data" is NULL
2656 * "response" is NULL
2657 *
2658 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07002659 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002660 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07002661 * INVALID_STATE
2662 * NO_RESOURCES
2663 * NO_MEMORY
2664 * MODEM_ERR
2665 * INTERNAL_ERR
2666 * INVALID_CALL_ID
2667 * OPERATION_NOT_ALLOWED
2668 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07002669 * CANCELLED
2670 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002671 */
2672#define RIL_REQUEST_UDUB 17
2673
2674/**
2675 * RIL_REQUEST_LAST_CALL_FAIL_CAUSE
2676 *
2677 * Requests the failure cause code for the most recently terminated call
2678 *
2679 * "data" is NULL
Jayachandran Ccc2a2022017-03-07 09:55:58 -08002680 * "response" is a const RIL_LastCallFailCauseInfo *
2681 * RIL_LastCallFailCauseInfo contains LastCallFailCause and vendor cause.
2682 * The vendor cause code must be used for debugging purpose only.
2683 * The implementation must return one of the values of LastCallFailCause
2684 * as mentioned below.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002685 *
Jayachandran Ccc2a2022017-03-07 09:55:58 -08002686 * GSM failure reasons codes for the cause codes defined in TS 24.008 Annex H
2687 * where possible.
2688 * CDMA failure reasons codes for the possible call failure scenarios
2689 * described in the "CDMA IS-2000 Release A (C.S0005-A v6.0)" standard.
2690 * Any of the following reason codes if the call is failed or dropped due to reason
2691 * mentioned with in the braces.
2692 *
2693 * CALL_FAIL_RADIO_OFF (Radio is OFF)
2694 * CALL_FAIL_OUT_OF_SERVICE (No cell coverage)
2695 * CALL_FAIL_NO_VALID_SIM (No valid SIM)
2696 * CALL_FAIL_RADIO_INTERNAL_ERROR (Modem hit unexpected error scenario)
2697 * CALL_FAIL_NETWORK_RESP_TIMEOUT (No response from network)
2698 * CALL_FAIL_NETWORK_REJECT (Explicit network reject)
2699 * CALL_FAIL_RADIO_ACCESS_FAILURE (RRC connection failure. Eg.RACH)
2700 * CALL_FAIL_RADIO_LINK_FAILURE (Radio Link Failure)
2701 * CALL_FAIL_RADIO_LINK_LOST (Radio link lost due to poor coverage)
2702 * CALL_FAIL_RADIO_UPLINK_FAILURE (Radio uplink failure)
2703 * CALL_FAIL_RADIO_SETUP_FAILURE (RRC connection setup failure)
2704 * CALL_FAIL_RADIO_RELEASE_NORMAL (RRC connection release, normal)
2705 * CALL_FAIL_RADIO_RELEASE_ABNORMAL (RRC connection release, abnormal)
2706 * CALL_FAIL_ACCESS_CLASS_BLOCKED (Access class barring)
2707 * CALL_FAIL_NETWORK_DETACH (Explicit network detach)
2708 *
2709 * OEM causes (CALL_FAIL_OEM_CAUSE_XX) must be used for debug purpose only
The Android Open Source Project34a51082009-03-05 14:34:37 -08002710 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002711 * If the implementation does not have access to the exact cause codes,
2712 * then it should return one of the values listed in RIL_LastCallFailCause,
2713 * as the UI layer needs to distinguish these cases for tone generation or
2714 * error notification.
2715 *
2716 * Valid errors:
2717 * SUCCESS
2718 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07002719 * NO_MEMORY
sqiana216ed42017-06-20 11:54:31 -07002720 * INTERNAL_ERR
2721 * NO_RESOURCES
2722 * CANCELLED
2723 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002724 *
Wink Savillef4c4d362009-04-02 01:37:03 -07002725 * See also: RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002726 */
2727#define RIL_REQUEST_LAST_CALL_FAIL_CAUSE 18
2728
2729/**
2730 * RIL_REQUEST_SIGNAL_STRENGTH
2731 *
Wink Saville1b5fd232009-04-22 14:50:00 -07002732 * Requests current signal strength and associated information
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002733 *
2734 * Must succeed if radio is on.
2735 *
2736 * "data" is NULL
Wink Saville1b5fd232009-04-22 14:50:00 -07002737 *
2738 * "response" is a const RIL_SignalStrength *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002739 *
2740 * Valid errors:
2741 * SUCCESS
2742 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07002743 * NO_MEMORY
2744 * INTERNAL_ERR
2745 * SYSTEM_ERR
2746 * MODEM_ERR
2747 * NOT_PROVISIONED
2748 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07002749 * NO_RESOURCES
2750 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002751 */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002752#define RIL_REQUEST_SIGNAL_STRENGTH 19
Wink Saville3d54e742009-05-18 18:00:44 -07002753
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002754/**
Wink Savillec0114b32011-02-18 10:14:07 -08002755 * RIL_REQUEST_VOICE_REGISTRATION_STATE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002756 *
2757 * Request current registration state
2758 *
2759 * "data" is NULL
Sooraj Sasindranf4714b72016-11-30 18:36:03 -08002760 * "response" is a const RIL_VoiceRegistrationStateResponse *
Wink Saville1b5fd232009-04-22 14:50:00 -07002761 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002762 * Valid errors:
2763 * SUCCESS
2764 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07002765 * INTERNAL_ERR
2766 * NO_MEMORY
2767 * NO_RESOURCES
2768 * CANCELLED
2769 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002770 */
Wink Savillec0114b32011-02-18 10:14:07 -08002771#define RIL_REQUEST_VOICE_REGISTRATION_STATE 20
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002772
2773/**
Wink Savillec0114b32011-02-18 10:14:07 -08002774 * RIL_REQUEST_DATA_REGISTRATION_STATE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002775 *
Wink Savillec0114b32011-02-18 10:14:07 -08002776 * Request current DATA registration state
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002777 *
2778 * "data" is NULL
Sooraj Sasindranf4714b72016-11-30 18:36:03 -08002779 * "response" is a const RIL_DataRegistrationStateResponse *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002780 *
2781 * Valid errors:
2782 * SUCCESS
2783 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07002784 * NO_MEMORY
2785 * INTERNAL_ERR
2786 * SYSTEM_ERR
2787 * MODEM_ERR
2788 * NOT_PROVISIONED
2789 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07002790 * NO_RESOURCES
2791 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002792 */
Wink Savillec0114b32011-02-18 10:14:07 -08002793#define RIL_REQUEST_DATA_REGISTRATION_STATE 21
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002794
2795/**
2796 * RIL_REQUEST_OPERATOR
2797 *
2798 * Request current operator ONS or EONS
2799 *
2800 * "data" is NULL
2801 * "response" is a "const char **"
Wink Saville7f856802009-06-09 10:23:37 -07002802 * ((const char **)response)[0] is long alpha ONS or EONS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002803 * or NULL if unregistered
2804 *
Wink Saville7f856802009-06-09 10:23:37 -07002805 * ((const char **)response)[1] is short alpha ONS or EONS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002806 * or NULL if unregistered
2807 * ((const char **)response)[2] is 5 or 6 digit numeric code (MCC + MNC)
2808 * or NULL if unregistered
Wink Saville7f856802009-06-09 10:23:37 -07002809 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002810 * Valid errors:
2811 * SUCCESS
2812 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07002813 * NO_MEMORY
2814 * INTERNAL_ERR
2815 * SYSTEM_ERR
2816 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07002817 * NO_RESOURCES
2818 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002819 */
2820#define RIL_REQUEST_OPERATOR 22
2821
2822/**
2823 * RIL_REQUEST_RADIO_POWER
2824 *
2825 * Toggle radio on and off (for "airplane" mode)
Wink Saville29487ef2011-04-15 09:15:31 -07002826 * If the radio is is turned off/on the radio modem subsystem
2827 * is expected return to an initialized state. For instance,
2828 * any voice and data calls will be terminated and all associated
2829 * lists emptied.
2830 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002831 * "data" is int *
2832 * ((int *)data)[0] is > 0 for "Radio On"
2833 * ((int *)data)[0] is == 0 for "Radio Off"
2834 *
2835 * "response" is NULL
2836 *
2837 * Turn radio on if "on" > 0
2838 * Turn radio off if "on" == 0
2839 *
2840 * Valid errors:
2841 * SUCCESS
2842 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08002843 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07002844 * INVALID_STATE
2845 * NO_MEMORY
2846 * INTERNAL_ERR
2847 * SYSTEM_ERR
2848 * INVALID_ARGUMENTS
2849 * MODEM_ERR
2850 * DEVICE_IN_USE
2851 * OPERATION_NOT_ALLOWED
2852 * INVALID_MODEM_STATE
2853 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07002854 * NO_RESOURCES
2855 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002856 */
2857#define RIL_REQUEST_RADIO_POWER 23
2858
2859/**
2860 * RIL_REQUEST_DTMF
2861 *
2862 * Send a DTMF tone
2863 *
2864 * If the implementation is currently playing a tone requested via
2865 * RIL_REQUEST_DTMF_START, that tone should be cancelled and the new tone
2866 * should be played instead
2867 *
jsh602f80f2009-07-10 15:44:37 -07002868 * "data" is a char * containing a single character with one of 12 values: 0-9,*,#
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002869 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07002870 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002871 * FIXME should this block/mute microphone?
2872 * How does this interact with local DTMF feedback?
2873 *
2874 * Valid errors:
2875 * SUCCESS
2876 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07002877 * INVALID_ARGUMENTS
2878 * NO_RESOURCES
2879 * NO_MEMORY
2880 * MODEM_ERR
2881 * INTERNAL_ERR
2882 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07002883 * NO_RESOURCES
2884 * CANCELLED
2885 * INVALID_MODEM_STATE
2886 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002887 *
2888 * See also: RIL_REQUEST_DTMF_STOP, RIL_REQUEST_DTMF_START
2889 *
2890 */
2891#define RIL_REQUEST_DTMF 24
2892
2893/**
2894 * RIL_REQUEST_SEND_SMS
Wink Saville7f856802009-06-09 10:23:37 -07002895 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002896 * Send an SMS message
2897 *
2898 * "data" is const char **
2899 * ((const char **)data)[0] is SMSC address in GSM BCD format prefixed
2900 * by a length byte (as expected by TS 27.005) or NULL for default SMSC
2901 * ((const char **)data)[1] is SMS in PDU format as an ASCII hex string
2902 * less the SMSC address
2903 * TP-Layer-Length is be "strlen(((const char **)data)[1])/2"
2904 *
2905 * "response" is a const RIL_SMS_Response *
2906 *
2907 * Based on the return error, caller decides to resend if sending sms
Wink Saville7f856802009-06-09 10:23:37 -07002908 * fails. SMS_SEND_FAIL_RETRY means retry (i.e. error cause is 332)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002909 *
2910 * Valid errors:
2911 * SUCCESS
2912 * RADIO_NOT_AVAILABLE
2913 * SMS_SEND_FAIL_RETRY
jsh602f80f2009-07-10 15:44:37 -07002914 * FDN_CHECK_FAILURE
twen.changdf7add02016-03-04 18:27:48 +08002915 * NETWORK_REJECT
Ajay Nambi68900f52016-03-11 12:02:55 -08002916 * INVALID_STATE
2917 * INVALID_ARGUMENTS
2918 * NO_MEMORY
2919 * REQUEST_RATE_LIMITED
2920 * INVALID_SMS_FORMAT
2921 * SYSTEM_ERR
2922 * ENCODING_ERR
2923 * INVALID_SMSC_ADDRESS
2924 * MODEM_ERR
2925 * NETWORK_ERR
Naina Nalluri1d3f4482017-07-17 11:44:37 -07002926 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07002927 * NO_MEMORY
2928 * NO_RESOURCES
2929 * CANCELLED
2930 * REQUEST_NOT_SUPPORTED
Ajay Nambi68900f52016-03-11 12:02:55 -08002931 * MODE_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08002932 * SIM_ABSENT
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002933 *
2934 * FIXME how do we specify TP-Message-Reference if we need to resend?
2935 */
2936#define RIL_REQUEST_SEND_SMS 25
2937
2938
2939/**
2940 * RIL_REQUEST_SEND_SMS_EXPECT_MORE
Wink Saville7f856802009-06-09 10:23:37 -07002941 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002942 * Send an SMS message. Identical to RIL_REQUEST_SEND_SMS,
2943 * except that more messages are expected to be sent soon. If possible,
2944 * keep SMS relay protocol link open (eg TS 27.005 AT+CMMS command)
2945 *
2946 * "data" is const char **
2947 * ((const char **)data)[0] is SMSC address in GSM BCD format prefixed
2948 * by a length byte (as expected by TS 27.005) or NULL for default SMSC
2949 * ((const char **)data)[1] is SMS in PDU format as an ASCII hex string
2950 * less the SMSC address
2951 * TP-Layer-Length is be "strlen(((const char **)data)[1])/2"
2952 *
2953 * "response" is a const RIL_SMS_Response *
2954 *
2955 * Based on the return error, caller decides to resend if sending sms
Wink Saville7f856802009-06-09 10:23:37 -07002956 * fails. SMS_SEND_FAIL_RETRY means retry (i.e. error cause is 332)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002957 *
2958 * Valid errors:
2959 * SUCCESS
2960 * RADIO_NOT_AVAILABLE
2961 * SMS_SEND_FAIL_RETRY
twen.changdf7add02016-03-04 18:27:48 +08002962 * NETWORK_REJECT
Ajay Nambi68900f52016-03-11 12:02:55 -08002963 * INVALID_STATE
2964 * INVALID_ARGUMENTS
2965 * NO_MEMORY
2966 * INVALID_SMS_FORMAT
2967 * SYSTEM_ERR
2968 * REQUEST_RATE_LIMITED
2969 * FDN_CHECK_FAILURE
2970 * MODEM_ERR
2971 * NETWORK_ERR
2972 * ENCODING_ERR
2973 * INVALID_SMSC_ADDRESS
Naina Nalluri1d3f4482017-07-17 11:44:37 -07002974 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07002975 * INTERNAL_ERR
2976 * NO_RESOURCES
2977 * CANCELLED
2978 * REQUEST_NOT_SUPPORTED
Ajay Nambi68900f52016-03-11 12:02:55 -08002979 * MODE_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08002980 * SIM_ABSENT
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002981 *
2982 */
2983#define RIL_REQUEST_SEND_SMS_EXPECT_MORE 26
2984
2985
2986/**
Wink Savillef4c4d362009-04-02 01:37:03 -07002987 * RIL_REQUEST_SETUP_DATA_CALL
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002988 *
Wink Saville29487ef2011-04-15 09:15:31 -07002989 * Setup a packet data connection. If RIL_Data_Call_Response_v6.status
2990 * return success it is added to the list of data calls and a
2991 * RIL_UNSOL_DATA_CALL_LIST_CHANGED is sent. The call remains in the
2992 * list until RIL_REQUEST_DEACTIVATE_DATA_CALL is issued or the
2993 * radio is powered off/on. This list is returned by RIL_REQUEST_DATA_CALL_LIST
2994 * and RIL_UNSOL_DATA_CALL_LIST_CHANGED.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08002995 *
Wink Saville43808972011-01-13 17:39:51 -08002996 * The RIL is expected to:
2997 * - Create one data call context.
2998 * - Create and configure a dedicated interface for the context
2999 * - The interface must be point to point.
3000 * - The interface is configured with one or more addresses and
3001 * is capable of sending and receiving packets. The prefix length
3002 * of the addresses must be /32 for IPv4 and /128 for IPv6.
3003 * - Must NOT change the linux routing table.
Wink Savillec0114b32011-02-18 10:14:07 -08003004 * - Support up to RIL_REQUEST_DATA_REGISTRATION_STATE response[5]
Wink Saville43808972011-01-13 17:39:51 -08003005 * number of simultaneous data call contexts.
3006 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003007 * "data" is a const char **
Wink Savillec0114b32011-02-18 10:14:07 -08003008 * ((const char **)data)[0] Radio technology to use: 0-CDMA, 1-GSM/UMTS, 2...
3009 * for values above 2 this is RIL_RadioTechnology + 2.
jsh602f80f2009-07-10 15:44:37 -07003010 * ((const char **)data)[1] is a RIL_DataProfile (support is optional)
Wink Saville7f856802009-06-09 10:23:37 -07003011 * ((const char **)data)[2] is the APN to connect to if radio technology is GSM/UMTS. This APN will
Wink Savillef4c4d362009-04-02 01:37:03 -07003012 * override the one in the profile. NULL indicates no APN overrride.
3013 * ((const char **)data)[3] is the username for APN, or NULL
3014 * ((const char **)data)[4] is the password for APN, or NULL
Jaikumar Ganesh920c78f2009-06-04 10:53:15 -07003015 * ((const char **)data)[5] is the PAP / CHAP auth type. Values:
3016 * 0 => PAP and CHAP is never performed.
3017 * 1 => PAP may be performed; CHAP is never performed.
3018 * 2 => CHAP may be performed; PAP is never performed.
3019 * 3 => PAP / CHAP may be performed - baseband dependent.
Jack Yude8c8552017-01-24 12:03:52 -08003020 * ((const char **)data)[6] is the non-roaming/home connection type to request. Must be one of the
Wink Savillec0114b32011-02-18 10:14:07 -08003021 * PDP_type values in TS 27.007 section 10.1.1.
Lorenzo Colitti4f81dcf2010-09-01 19:38:57 -07003022 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
Jack Yude8c8552017-01-24 12:03:52 -08003023 * ((const char **)data)[7] is the roaming connection type to request. Must be one of the
3024 * PDP_type values in TS 27.007 section 10.1.1.
3025 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
3026 * ((const char **)data)[8] is the bitmask of APN type in decimal string format. The
3027 * bitmask will encapsulate the following values:
3028 * ia,mms,agps,supl,hipri,fota,dun,ims,default.
3029 * ((const char **)data)[9] is the bearer bitmask in decimal string format. Each bit is a
3030 * RIL_RadioAccessFamily. "0" or NULL indicates all RATs.
3031 * ((const char **)data)[10] is the boolean in string format indicating the APN setting was
3032 * sent to the modem through RIL_REQUEST_SET_DATA_PROFILE earlier.
3033 * ((const char **)data)[11] is the mtu size in bytes of the mobile interface to which
3034 * the apn is connected.
3035 * ((const char **)data)[12] is the MVNO type:
3036 * possible values are "imsi", "gid", "spn".
3037 * ((const char **)data)[13] is MVNO match data in string. Can be anything defined by the carrier.
3038 * For example,
3039 * SPN like: "A MOBILE", "BEN NL", etc...
3040 * IMSI like: "302720x94", "2060188", etc...
3041 * GID like: "4E", "33", etc...
3042 * ((const char **)data)[14] is the boolean string indicating data roaming is allowed or not. "1"
3043 * indicates data roaming is enabled by the user, "0" indicates disabled.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003044 *
Sukanya Rajkhowab44dda32014-06-02 14:03:44 -07003045 * "response" is a RIL_Data_Call_Response_v11
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003046 *
3047 * FIXME may need way to configure QoS settings
Wink Saville3d54e742009-05-18 18:00:44 -07003048 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003049 * Valid errors:
Wink Saville43808972011-01-13 17:39:51 -08003050 * SUCCESS should be returned on both success and failure of setup with
Wink Savillec0114b32011-02-18 10:14:07 -08003051 * the RIL_Data_Call_Response_v6.status containing the actual status.
3052 * For all other errors the RIL_Data_Call_Resonse_v6 is ignored.
Wink Saville43808972011-01-13 17:39:51 -08003053 *
3054 * Other errors could include:
sqian2e093612017-04-24 11:48:06 -07003055 * RADIO_NOT_AVAILABLE, OP_NOT_ALLOWED_BEFORE_REG_TO_NW,
sqiana216ed42017-06-20 11:54:31 -07003056 * OP_NOT_ALLOWED_DURING_VOICE_CALL, REQUEST_NOT_SUPPORTED,
Sanket Padaweceba34c2017-07-27 11:21:03 -07003057 * INVALID_ARGUMENTS, INTERNAL_ERR, NO_MEMORY, NO_RESOURCES,
3058 * SIM_ABSENT and CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003059 *
Wink Savillef4c4d362009-04-02 01:37:03 -07003060 * See also: RIL_REQUEST_DEACTIVATE_DATA_CALL
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003061 */
Wink Savillef4c4d362009-04-02 01:37:03 -07003062#define RIL_REQUEST_SETUP_DATA_CALL 27
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003063
3064
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003065/**
3066 * RIL_REQUEST_SIM_IO
3067 *
3068 * Request SIM I/O operation.
3069 * This is similar to the TS 27.007 "restricted SIM" operation
3070 * where it assumes all of the EF selection will be done by the
3071 * callee.
3072 *
Wink Savillefd729372011-02-22 16:19:39 -08003073 * "data" is a const RIL_SIM_IO_v6 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003074 * Please note that RIL_SIM_IO has a "PIN2" field which may be NULL,
3075 * or may specify a PIN2 for operations that require a PIN2 (eg
3076 * updating FDN records)
3077 *
3078 * "response" is a const RIL_SIM_IO_Response *
3079 *
3080 * Arguments and responses that are unused for certain
3081 * values of "command" should be ignored or set to NULL
3082 *
3083 * Valid errors:
3084 * SUCCESS
3085 * RADIO_NOT_AVAILABLE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003086 * SIM_PIN2
3087 * SIM_PUK2
sqiana216ed42017-06-20 11:54:31 -07003088 * INVALID_SIM_STATE
3089 * SIM_ERR
3090 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003091 */
3092#define RIL_REQUEST_SIM_IO 28
3093
3094/**
3095 * RIL_REQUEST_SEND_USSD
3096 *
3097 * Send a USSD message
3098 *
3099 * If a USSD session already exists, the message should be sent in the
3100 * context of that session. Otherwise, a new session should be created.
3101 *
3102 * The network reply should be reported via RIL_UNSOL_ON_USSD
3103 *
3104 * Only one USSD session may exist at a time, and the session is assumed
3105 * to exist until:
3106 * a) The android system invokes RIL_REQUEST_CANCEL_USSD
3107 * b) The implementation sends a RIL_UNSOL_ON_USSD with a type code
3108 * of "0" (USSD-Notify/no further action) or "2" (session terminated)
3109 *
3110 * "data" is a const char * containing the USSD request in UTF-8 format
3111 * "response" is NULL
3112 *
3113 * Valid errors:
3114 * SUCCESS
3115 * RADIO_NOT_AVAILABLE
jsh602f80f2009-07-10 15:44:37 -07003116 * FDN_CHECK_FAILURE
Amit Mahajan54563d32014-11-22 00:54:49 +00003117 * USSD_MODIFIED_TO_DIAL
3118 * USSD_MODIFIED_TO_SS
3119 * USSD_MODIFIED_TO_USSD
twen.changdf7add02016-03-04 18:27:48 +08003120 * SIM_BUSY
3121 * OPERATION_NOT_ALLOWED
Ajay Nambi10345892016-03-19 09:02:28 -07003122 * INVALID_ARGUMENTS
3123 * NO_MEMORY
3124 * MODEM_ERR
3125 * INTERNAL_ERR
3126 * ABORTED
3127 * SYSTEM_ERR
3128 * INVALID_STATE
sqiana216ed42017-06-20 11:54:31 -07003129 * NO_RESOURCES
3130 * CANCELLED
3131 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003132 *
3133 * See also: RIL_REQUEST_CANCEL_USSD, RIL_UNSOL_ON_USSD
3134 */
3135
3136#define RIL_REQUEST_SEND_USSD 29
3137
3138/**
3139 * RIL_REQUEST_CANCEL_USSD
Wink Saville7f856802009-06-09 10:23:37 -07003140 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003141 * Cancel the current USSD session if one exists
3142 *
3143 * "data" is null
3144 * "response" is NULL
3145 *
3146 * Valid errors:
3147 * SUCCESS
3148 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08003149 * SIM_BUSY
3150 * OPERATION_NOT_ALLOWED
Ajay Nambi10345892016-03-19 09:02:28 -07003151 * MODEM_ERR
3152 * INTERNAL_ERR
3153 * NO_MEMORY
3154 * INVALID_STATE
sqiana216ed42017-06-20 11:54:31 -07003155 * NO_RESOURCES
3156 * CANCELLED
3157 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003158 */
3159
3160#define RIL_REQUEST_CANCEL_USSD 30
3161
Wink Saville7f856802009-06-09 10:23:37 -07003162/**
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003163 * RIL_REQUEST_GET_CLIR
3164 *
3165 * Gets current CLIR status
3166 * "data" is NULL
3167 * "response" is int *
3168 * ((int *)data)[0] is "n" parameter from TS 27.007 7.7
3169 * ((int *)data)[1] is "m" parameter from TS 27.007 7.7
3170 *
3171 * Valid errors:
3172 * SUCCESS
3173 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003174 * SS_MODIFIED_TO_DIAL
3175 * SS_MODIFIED_TO_USSD
3176 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003177 * NO_MEMORY
3178 * MODEM_ERR
3179 * INTERNAL_ERR
3180 * FDN_CHECK_FAILURE
3181 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07003182 * NO_RESOURCES
3183 * CANCELLED
3184 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003185 */
3186#define RIL_REQUEST_GET_CLIR 31
3187
3188/**
3189 * RIL_REQUEST_SET_CLIR
3190 *
3191 * "data" is int *
3192 * ((int *)data)[0] is "n" parameter from TS 27.007 7.7
3193 *
3194 * "response" is NULL
3195 *
3196 * Valid errors:
3197 * SUCCESS
3198 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003199 * SS_MODIFIED_TO_DIAL
3200 * SS_MODIFIED_TO_USSD
3201 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003202 * INVALID_ARGUMENTS
3203 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07003204 * INTERNAL_ERR
3205 * NO_MEMORY
3206 * NO_RESOURCES
3207 * CANCELLED
3208 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003209 */
3210#define RIL_REQUEST_SET_CLIR 32
3211
3212/**
3213 * RIL_REQUEST_QUERY_CALL_FORWARD_STATUS
3214 *
3215 * "data" is const RIL_CallForwardInfo *
3216 *
3217 * "response" is const RIL_CallForwardInfo **
3218 * "response" points to an array of RIL_CallForwardInfo *'s, one for
3219 * each distinct registered phone number.
3220 *
3221 * For example, if data is forwarded to +18005551212 and voice is forwarded
3222 * to +18005559999, then two separate RIL_CallForwardInfo's should be returned
Wink Saville7f856802009-06-09 10:23:37 -07003223 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003224 * If, however, both data and voice are forwarded to +18005551212, then
3225 * a single RIL_CallForwardInfo can be returned with the service class
3226 * set to "data + voice = 3")
3227 *
3228 * Valid errors:
3229 * SUCCESS
3230 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003231 * SS_MODIFIED_TO_DIAL
3232 * SS_MODIFIED_TO_USSD
3233 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003234 * INVALID_ARGUMENTS
3235 * NO_MEMORY
3236 * SYSTEM_ERR
3237 * MODEM_ERR
3238 * INTERNAL_ERR
3239 * NO_MEMORY
3240 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003241 * NO_RESOURCES
3242 * CANCELLED
3243 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003244 */
3245#define RIL_REQUEST_QUERY_CALL_FORWARD_STATUS 33
3246
3247
3248/**
3249 * RIL_REQUEST_SET_CALL_FORWARD
3250 *
3251 * Configure call forward rule
3252 *
3253 * "data" is const RIL_CallForwardInfo *
3254 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07003255 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003256 * Valid errors:
3257 * SUCCESS
3258 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003259 * SS_MODIFIED_TO_DIAL
3260 * SS_MODIFIED_TO_USSD
3261 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003262 * INVALID_ARGUMENTS
3263 * NO_MEMORY
3264 * SYSTEM_ERR
3265 * MODEM_ERR
3266 * INTERNAL_ERR
3267 * INVALID_STATE
3268 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003269 * NO_RESOURCES
3270 * CANCELLED
3271 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003272 */
3273#define RIL_REQUEST_SET_CALL_FORWARD 34
3274
3275
3276/**
3277 * RIL_REQUEST_QUERY_CALL_WAITING
3278 *
3279 * Query current call waiting state
3280 *
3281 * "data" is const int *
3282 * ((const int *)data)[0] is the TS 27.007 service class to query.
3283 * "response" is a const int *
3284 * ((const int *)response)[0] is 0 for "disabled" and 1 for "enabled"
3285 *
3286 * If ((const int *)response)[0] is = 1, then ((const int *)response)[1]
3287 * must follow, with the TS 27.007 service class bit vector of services
3288 * for which call waiting is enabled.
3289 *
Wink Saville7f856802009-06-09 10:23:37 -07003290 * For example, if ((const int *)response)[0] is 1 and
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003291 * ((const int *)response)[1] is 3, then call waiting is enabled for data
3292 * and voice and disabled for everything else
3293 *
3294 * Valid errors:
3295 * SUCCESS
3296 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003297 * SS_MODIFIED_TO_DIAL
3298 * SS_MODIFIED_TO_USSD
3299 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003300 * NO_MEMORY
3301 * MODEM_ERR
3302 * INTERNAL_ERR
3303 * NO_MEMORY
3304 * FDN_CHECK_FAILURE
3305 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07003306 * NO_RESOURCES
3307 * CANCELLED
3308 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003309 */
3310#define RIL_REQUEST_QUERY_CALL_WAITING 35
3311
3312
3313/**
3314 * RIL_REQUEST_SET_CALL_WAITING
3315 *
3316 * Configure current call waiting state
3317 *
3318 * "data" is const int *
3319 * ((const int *)data)[0] is 0 for "disabled" and 1 for "enabled"
3320 * ((const int *)data)[1] is the TS 27.007 service class bit vector of
3321 * services to modify
3322 * "response" is NULL
3323 *
3324 * Valid errors:
3325 * SUCCESS
3326 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003327 * SS_MODIFIED_TO_DIAL
3328 * SS_MODIFIED_TO_USSD
3329 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003330 * INVALID_ARGUMENTS
3331 * NO_MEMORY
3332 * MODEM_ERR
3333 * INTERNAL_ERR
3334 * INVALID_STATE
3335 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003336 * NO_RESOURCES
3337 * CANCELLED
3338 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003339 */
3340#define RIL_REQUEST_SET_CALL_WAITING 36
3341
3342/**
3343 * RIL_REQUEST_SMS_ACKNOWLEDGE
3344 *
3345 * Acknowledge successful or failed receipt of SMS previously indicated
Wink Saville7f856802009-06-09 10:23:37 -07003346 * via RIL_UNSOL_RESPONSE_NEW_SMS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003347 *
3348 * "data" is int *
jshb60444e2009-05-29 11:09:17 -07003349 * ((int *)data)[0] is 1 on successful receipt
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003350 * (basically, AT+CNMA=1 from TS 27.005
jshb60444e2009-05-29 11:09:17 -07003351 * is 0 on failed receipt
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003352 * (basically, AT+CNMA=2 from TS 27.005)
jshb60444e2009-05-29 11:09:17 -07003353 * ((int *)data)[1] if data[0] is 0, this contains the failure cause as defined
3354 * in TS 23.040, 9.2.3.22. Currently only 0xD3 (memory
3355 * capacity exceeded) and 0xFF (unspecified error) are
3356 * reported.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003357 *
3358 * "response" is NULL
3359 *
3360 * FIXME would like request that specified RP-ACK/RP-ERROR PDU
3361 *
3362 * Valid errors:
3363 * SUCCESS
3364 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07003365 * INTERNAL_ERR
3366 * NO_MEMORY
3367 * NO_RESOURCES
3368 * CANCELLED
3369 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003370 */
3371#define RIL_REQUEST_SMS_ACKNOWLEDGE 37
3372
3373/**
Wink Savillef4c4d362009-04-02 01:37:03 -07003374 * RIL_REQUEST_GET_IMEI - DEPRECATED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003375 *
3376 * Get the device IMEI, including check digit
3377 *
johnwangf8bc1672009-05-14 19:19:47 -07003378 * The request is DEPRECATED, use RIL_REQUEST_DEVICE_IDENTITY
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003379 * Valid when RadioState is not RADIO_STATE_UNAVAILABLE
3380 *
3381 * "data" is NULL
3382 * "response" is a const char * containing the IMEI
3383 *
3384 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003385 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003386 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07003387 * NO_MEMORY
3388 * INTERNAL_ERR
3389 * SYSTEM_ERR
3390 * MODEM_ERR
3391 * NOT_PROVISIONED
3392 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003393 * NO_RESOURCES
3394 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003395 */
3396
3397#define RIL_REQUEST_GET_IMEI 38
3398
3399/**
Wink Savillef4c4d362009-04-02 01:37:03 -07003400 * RIL_REQUEST_GET_IMEISV - DEPRECATED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003401 *
3402 * Get the device IMEISV, which should be two decimal digits
3403 *
johnwangf8bc1672009-05-14 19:19:47 -07003404 * The request is DEPRECATED, use RIL_REQUEST_DEVICE_IDENTITY
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003405 * Valid when RadioState is not RADIO_STATE_UNAVAILABLE
3406 *
3407 * "data" is NULL
3408 * "response" is a const char * containing the IMEISV
3409 *
3410 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003411 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003412 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07003413 * NO_MEMORY
3414 * INTERNAL_ERR
3415 * SYSTEM_ERR
3416 * MODEM_ERR
3417 * NOT_PROVISIONED
3418 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003419 * NO_RESOURCES
3420 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003421 */
3422
3423#define RIL_REQUEST_GET_IMEISV 39
3424
3425
3426/**
3427 * RIL_REQUEST_ANSWER
3428 *
3429 * Answer incoming call
3430 *
3431 * Will not be called for WAITING calls.
3432 * RIL_REQUEST_SWITCH_WAITING_OR_HOLDING_AND_ACTIVE will be used in this case
3433 * instead
3434 *
3435 * "data" is NULL
3436 * "response" is NULL
3437 *
3438 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003439 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003440 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07003441 * INVALID_STATE
3442 * NO_MEMORY
3443 * SYSTEM_ERR
3444 * MODEM_ERR
3445 * INTERNAL_ERR
3446 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07003447 * NO_RESOURCES
3448 * CANCELLED
3449 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003450 */
3451
3452#define RIL_REQUEST_ANSWER 40
3453
3454/**
Wink Savillef4c4d362009-04-02 01:37:03 -07003455 * RIL_REQUEST_DEACTIVATE_DATA_CALL
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003456 *
Wink Saville29487ef2011-04-15 09:15:31 -07003457 * Deactivate packet data connection and remove from the
3458 * data call list if SUCCESS is returned. Any other return
3459 * values should also try to remove the call from the list,
3460 * but that may not be possible. In any event a
3461 * RIL_REQUEST_RADIO_POWER off/on must clear the list. An
3462 * RIL_UNSOL_DATA_CALL_LIST_CHANGED is not expected to be
3463 * issued because of an RIL_REQUEST_DEACTIVATE_DATA_CALL.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003464 *
3465 * "data" is const char **
Wink Savillef4c4d362009-04-02 01:37:03 -07003466 * ((char**)data)[0] indicating CID
Kazuhiro Ondod86799a2010-12-02 13:22:35 -06003467 * ((char**)data)[1] indicating Disconnect Reason
3468 * 0 => No specific reason specified
3469 * 1 => Radio shutdown requested
Wink Saville7f856802009-06-09 10:23:37 -07003470 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003471 * "response" is NULL
3472 *
3473 * Valid errors:
3474 * SUCCESS
3475 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07003476 * INVALID_CALL_ID
3477 * INVALID_STATE
3478 * INVALID_ARGUMENTS
3479 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003480 * INTERNAL_ERR
3481 * NO_MEMORY
3482 * NO_RESOURCES
3483 * CANCELLED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08003484 * SIM_ABSENT
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003485 *
Wink Savillef4c4d362009-04-02 01:37:03 -07003486 * See also: RIL_REQUEST_SETUP_DATA_CALL
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003487 */
Wink Savillef4c4d362009-04-02 01:37:03 -07003488#define RIL_REQUEST_DEACTIVATE_DATA_CALL 41
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003489
3490/**
3491 * RIL_REQUEST_QUERY_FACILITY_LOCK
3492 *
3493 * Query the status of a facility lock state
3494 *
3495 * "data" is const char **
Wink Saville7f856802009-06-09 10:23:37 -07003496 * ((const char **)data)[0] is the facility string code from TS 27.007 7.4
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003497 * (eg "AO" for BAOC, "SC" for SIM lock)
3498 * ((const char **)data)[1] is the password, or "" if not required
3499 * ((const char **)data)[2] is the TS 27.007 service class bit vector of
3500 * services to query
Wink Savillec0114b32011-02-18 10:14:07 -08003501 * ((const char **)data)[3] is AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value.
Wink Savillefd729372011-02-22 16:19:39 -08003502 * This is only applicable in the case of Fixed Dialing Numbers
3503 * (FDN) requests.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003504 *
3505 * "response" is an int *
3506 * ((const int *)response) 0 is the TS 27.007 service class bit vector of
Wink Saville7f856802009-06-09 10:23:37 -07003507 * services for which the specified barring facility
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003508 * is active. "0" means "disabled for all"
Wink Saville7f856802009-06-09 10:23:37 -07003509 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003510 *
3511 * Valid errors:
3512 * SUCCESS
3513 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003514 * SS_MODIFIED_TO_DIAL
3515 * SS_MODIFIED_TO_USSD
3516 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003517 * INVALID_ARGUMENTS
3518 * NO_MEMORY
3519 * INTERNAL_ERR
3520 * SYSTEM_ERR
3521 * MODEM_ERR
3522 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003523 * NO_RESOURCES
3524 * CANCELLED
3525 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003526 *
3527 */
3528#define RIL_REQUEST_QUERY_FACILITY_LOCK 42
3529
3530/**
3531 * RIL_REQUEST_SET_FACILITY_LOCK
3532 *
3533 * Enable/disable one facility lock
3534 *
3535 * "data" is const char **
3536 *
3537 * ((const char **)data)[0] = facility string code from TS 27.007 7.4
3538 * (eg "AO" for BAOC)
3539 * ((const char **)data)[1] = "0" for "unlock" and "1" for "lock"
3540 * ((const char **)data)[2] = password
3541 * ((const char **)data)[3] = string representation of decimal TS 27.007
3542 * service class bit vector. Eg, the string
3543 * "1" means "set this facility for voice services"
Wink Savillec0114b32011-02-18 10:14:07 -08003544 * ((const char **)data)[4] = AID value, See ETSI 102.221 8.1 and 101.220 4, NULL if no value.
Wink Savillefd729372011-02-22 16:19:39 -08003545 * This is only applicable in the case of Fixed Dialing Numbers
3546 * (FDN) requests.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003547 *
jsh593c9102009-06-24 16:13:44 -07003548 * "response" is int *
3549 * ((int *)response)[0] is the number of retries remaining, or -1 if unknown
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003550 *
3551 * Valid errors:
3552 * SUCCESS
3553 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003554 * SS_MODIFIED_TO_DIAL
3555 * SS_MODIFIED_TO_USSD
3556 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003557 * INVALID_ARGUMENTS
3558 * INTERNAL_ERR
3559 * NO_MEMORY
3560 * MODEM_ERR
3561 * INVALID_STATE
3562 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003563 * NO_RESOURCES
3564 * CANCELLED
3565 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003566 *
3567 */
3568#define RIL_REQUEST_SET_FACILITY_LOCK 43
3569
3570/**
3571 * RIL_REQUEST_CHANGE_BARRING_PASSWORD
3572 *
3573 * Change call barring facility password
3574 *
3575 * "data" is const char **
3576 *
3577 * ((const char **)data)[0] = facility string code from TS 27.007 7.4
3578 * (eg "AO" for BAOC)
3579 * ((const char **)data)[1] = old password
3580 * ((const char **)data)[2] = new password
3581 *
Wink Saville7f856802009-06-09 10:23:37 -07003582 * "response" is NULL
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003583 *
3584 * Valid errors:
3585 * SUCCESS
3586 * RADIO_NOT_AVAILABLE
Amit Mahajan54563d32014-11-22 00:54:49 +00003587 * SS_MODIFIED_TO_DIAL
3588 * SS_MODIFIED_TO_USSD
3589 * SS_MODIFIED_TO_SS
Ajay Nambi10345892016-03-19 09:02:28 -07003590 * INVALID_ARGUMENTS
3591 * NO_MEMORY
3592 * MODEM_ERR
3593 * INTERNAL_ERR
3594 * SYSTEM_ERR
3595 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003596 * NO_RESOURCES
3597 * CANCELLED
3598 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003599 *
3600 */
3601#define RIL_REQUEST_CHANGE_BARRING_PASSWORD 44
3602
3603/**
3604 * RIL_REQUEST_QUERY_NETWORK_SELECTION_MODE
3605 *
3606 * Query current network selectin mode
3607 *
3608 * "data" is NULL
3609 *
3610 * "response" is int *
3611 * ((const int *)response)[0] is
3612 * 0 for automatic selection
3613 * 1 for manual selection
3614 *
3615 * Valid errors:
3616 * SUCCESS
3617 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07003618 * NO_MEMORY
3619 * INTERNAL_ERR
3620 * SYSTEM_ERR
3621 * INVALID_ARGUMENTS
3622 * MODEM_ERR
3623 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003624 * NO_RESOURCES
3625 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003626 *
3627 */
3628#define RIL_REQUEST_QUERY_NETWORK_SELECTION_MODE 45
3629
3630/**
3631 * RIL_REQUEST_SET_NETWORK_SELECTION_AUTOMATIC
3632 *
3633 * Specify that the network should be selected automatically
3634 *
3635 * "data" is NULL
3636 * "response" is NULL
3637 *
Wink Saville7f856802009-06-09 10:23:37 -07003638 * This request must not respond until the new operator is selected
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003639 * and registered
3640 *
3641 * Valid errors:
3642 * SUCCESS
3643 * RADIO_NOT_AVAILABLE
John Wang75534472010-04-20 15:11:42 -07003644 * ILLEGAL_SIM_OR_ME
twen.changdf7add02016-03-04 18:27:48 +08003645 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07003646 * NO_MEMORY
3647 * INTERNAL_ERR
3648 * SYSTEM_ERR
3649 * INVALID_ARGUMENTS
3650 * MODEM_ERR
3651 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003652 * NO_RESOURCES
3653 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003654 *
John Wang75534472010-04-20 15:11:42 -07003655 * Note: Returns ILLEGAL_SIM_OR_ME when the failure is permanent and
3656 * no retries needed, such as illegal SIM or ME.
John Wang75534472010-04-20 15:11:42 -07003657 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003658 */
3659#define RIL_REQUEST_SET_NETWORK_SELECTION_AUTOMATIC 46
3660
3661/**
3662 * RIL_REQUEST_SET_NETWORK_SELECTION_MANUAL
3663 *
3664 * Manually select a specified network.
3665 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003666 * "data" is const char * specifying MCCMNC of network to select (eg "310170")
3667 * "response" is NULL
3668 *
Wink Saville7f856802009-06-09 10:23:37 -07003669 * This request must not respond until the new operator is selected
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003670 * and registered
3671 *
3672 * Valid errors:
3673 * SUCCESS
3674 * RADIO_NOT_AVAILABLE
John Wang75534472010-04-20 15:11:42 -07003675 * ILLEGAL_SIM_OR_ME
twen.changdf7add02016-03-04 18:27:48 +08003676 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07003677 * INVALID_STATE
3678 * NO_MEMORY
3679 * INTERNAL_ERR
3680 * SYSTEM_ERR
3681 * INVALID_ARGUMENTS
3682 * MODEM_ERR
3683 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003684 * NO_RESOURCES
3685 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003686 *
John Wang75534472010-04-20 15:11:42 -07003687 * Note: Returns ILLEGAL_SIM_OR_ME when the failure is permanent and
3688 * no retries needed, such as illegal SIM or ME.
John Wang75534472010-04-20 15:11:42 -07003689 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003690 */
3691#define RIL_REQUEST_SET_NETWORK_SELECTION_MANUAL 47
3692
3693/**
3694 * RIL_REQUEST_QUERY_AVAILABLE_NETWORKS
3695 *
3696 * Scans for available networks
3697 *
3698 * "data" is NULL
3699 * "response" is const char ** that should be an array of n*4 strings, where
3700 * n is the number of available networks
3701 * For each available network:
3702 *
Wink Saville7f856802009-06-09 10:23:37 -07003703 * ((const char **)response)[n+0] is long alpha ONS or EONS
3704 * ((const char **)response)[n+1] is short alpha ONS or EONS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003705 * ((const char **)response)[n+2] is 5 or 6 digit numeric code (MCC + MNC)
3706 * ((const char **)response)[n+3] is a string value of the status:
3707 * "unknown"
3708 * "available"
3709 * "current"
3710 * "forbidden"
3711 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003712 * Valid errors:
3713 * SUCCESS
3714 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08003715 * OPERATION_NOT_ALLOWED
Jayachandran Cb0cba832017-03-13 19:17:18 -07003716 * ABORTED
3717 * DEVICE_IN_USE
3718 * INTERNAL_ERR
3719 * NO_MEMORY
3720 * MODEM_ERR
Naina Nalluri67728582017-05-04 17:40:04 -07003721 * REQUEST_NOT_SUPPORTED
3722 * CANCELLED
3723 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07003724 * NO_RESOURCES
3725 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003726 *
3727 */
3728#define RIL_REQUEST_QUERY_AVAILABLE_NETWORKS 48
3729
3730/**
3731 * RIL_REQUEST_DTMF_START
3732 *
Wink Saville7f856802009-06-09 10:23:37 -07003733 * Start playing a DTMF tone. Continue playing DTMF tone until
3734 * RIL_REQUEST_DTMF_STOP is received
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003735 *
3736 * If a RIL_REQUEST_DTMF_START is received while a tone is currently playing,
3737 * it should cancel the previous tone and play the new one.
Wink Saville7f856802009-06-09 10:23:37 -07003738 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003739 * "data" is a char *
3740 * ((char *)data)[0] is a single character with one of 12 values: 0-9,*,#
3741 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07003742 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003743 * Valid errors:
3744 * SUCCESS
3745 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07003746 * INVALID_ARGUMENTS
3747 * NO_RESOURCES
3748 * NO_MEMORY
3749 * SYSTEM_ERR
3750 * MODEM_ERR
3751 * INTERNAL_ERR
3752 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07003753 * CANCELLED
3754 * INVALID_MODEM_STATE
3755 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003756 *
3757 * See also: RIL_REQUEST_DTMF, RIL_REQUEST_DTMF_STOP
3758 */
3759#define RIL_REQUEST_DTMF_START 49
3760
3761/**
3762 * RIL_REQUEST_DTMF_STOP
3763 *
3764 * Stop playing a currently playing DTMF tone.
Wink Saville7f856802009-06-09 10:23:37 -07003765 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003766 * "data" is NULL
3767 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07003768 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003769 * Valid errors:
3770 * SUCCESS
3771 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08003772 * OPERATION_NOT_ALLOWED
Ajay Nambi10345892016-03-19 09:02:28 -07003773 * NO_RESOURCES
3774 * NO_MEMORY
3775 * INVALID_ARGUMENTS
3776 * SYSTEM_ERR
3777 * MODEM_ERR
3778 * INTERNAL_ERR
3779 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07003780 * CANCELLED
3781 * INVALID_MODEM_STATE
3782 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003783 *
3784 * See also: RIL_REQUEST_DTMF, RIL_REQUEST_DTMF_START
3785 */
3786#define RIL_REQUEST_DTMF_STOP 50
3787
3788/**
3789 * RIL_REQUEST_BASEBAND_VERSION
3790 *
3791 * Return string value indicating baseband version, eg
3792 * response from AT+CGMR
Wink Saville7f856802009-06-09 10:23:37 -07003793 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003794 * "data" is NULL
3795 * "response" is const char * containing version string for log reporting
Wink Saville7f856802009-06-09 10:23:37 -07003796 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003797 * Valid errors:
3798 * SUCCESS
3799 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08003800 * EMPTY_RECORD
Naina Nalluri67728582017-05-04 17:40:04 -07003801 * NO_MEMORY
3802 * INTERNAL_ERR
3803 * SYSTEM_ERR
3804 * MODEM_ERR
3805 * NOT_PROVISIONED
3806 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07003807 * NO_RESOURCES
3808 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003809 *
3810 */
3811#define RIL_REQUEST_BASEBAND_VERSION 51
3812
3813/**
3814 * RIL_REQUEST_SEPARATE_CONNECTION
3815 *
3816 * Separate a party from a multiparty call placing the multiparty call
Wink Saville7f856802009-06-09 10:23:37 -07003817 * (less the specified party) on hold and leaving the specified party
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003818 * as the only other member of the current (active) call
3819 *
3820 * Like AT+CHLD=2x
3821 *
3822 * See TS 22.084 1.3.8.2 (iii)
3823 * TS 22.030 6.5.5 "Entering "2X followed by send"
3824 * TS 27.007 "AT+CHLD=2x"
Wink Saville7f856802009-06-09 10:23:37 -07003825 *
3826 * "data" is an int *
Wink Savillef4c4d362009-04-02 01:37:03 -07003827 * (int *)data)[0] contains Connection index (value of 'x' in CHLD above) "response" is NULL
3828 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003829 * "response" is NULL
3830 *
3831 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003832 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003833 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07003834 * INVALID_ARGUMENTS
3835 * INVALID_STATE
3836 * NO_RESOURCES
3837 * NO_MEMORY
3838 * SYSTEM_ERR
3839 * MODEM_ERR
3840 * INTERNAL_ERR
3841 * INVALID_CALL_ID
3842 * INVALID_STATE
3843 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07003844 * CANCELLED
3845 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003846 */
3847#define RIL_REQUEST_SEPARATE_CONNECTION 52
3848
3849
3850/**
3851 * RIL_REQUEST_SET_MUTE
3852 *
3853 * Turn on or off uplink (microphone) mute.
3854 *
3855 * Will only be sent while voice call is active.
3856 * Will always be reset to "disable mute" when a new voice call is initiated
3857 *
3858 * "data" is an int *
3859 * (int *)data)[0] is 1 for "enable mute" and 0 for "disable mute"
3860 *
3861 * "response" is NULL
3862 *
3863 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003864 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003865 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi68900f52016-03-11 12:02:55 -08003866 * INVALID_ARGUMENTS
3867 * NO_MEMORY
3868 * REQUEST_RATE_LIMITED
sqiana216ed42017-06-20 11:54:31 -07003869 * INTERNAL_ERR
3870 * NO_RESOURCES
3871 * CANCELLED
3872 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003873 */
3874
3875#define RIL_REQUEST_SET_MUTE 53
3876
3877/**
3878 * RIL_REQUEST_GET_MUTE
3879 *
3880 * Queries the current state of the uplink mute setting
3881 *
3882 * "data" is NULL
3883 * "response" is an int *
3884 * (int *)response)[0] is 1 for "mute enabled" and 0 for "mute disabled"
3885 *
3886 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003887 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003888 * RADIO_NOT_AVAILABLE (radio resetting)
Amit Mahajan54563d32014-11-22 00:54:49 +00003889 * SS_MODIFIED_TO_DIAL
3890 * SS_MODIFIED_TO_USSD
3891 * SS_MODIFIED_TO_SS
Ajay Nambi68900f52016-03-11 12:02:55 -08003892 * NO_MEMORY
3893 * REQUEST_RATE_LIMITED
sqiana216ed42017-06-20 11:54:31 -07003894 * INTERNAL_ERR
3895 * NO_RESOURCES
3896 * CANCELLED
3897 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003898 */
3899
3900#define RIL_REQUEST_GET_MUTE 54
3901
3902/**
3903 * RIL_REQUEST_QUERY_CLIP
3904 *
3905 * Queries the status of the CLIP supplementary service
3906 *
3907 * (for MMI code "*#30#")
3908 *
3909 * "data" is NULL
3910 * "response" is an int *
Wink Saville7f856802009-06-09 10:23:37 -07003911 * (int *)response)[0] is 1 for "CLIP provisioned"
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003912 * and 0 for "CLIP not provisioned"
Wink Saville7f856802009-06-09 10:23:37 -07003913 * and 2 for "unknown, e.g. no network etc"
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003914 *
3915 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003916 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003917 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07003918 * NO_MEMORY
3919 * SYSTEM_ERR
3920 * MODEM_ERR
3921 * INTERNAL_ERR
3922 * FDN_CHECK_FAILURE
sqiana216ed42017-06-20 11:54:31 -07003923 * NO_RESOURCES
3924 * CANCELLED
3925 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003926 */
3927
3928#define RIL_REQUEST_QUERY_CLIP 55
3929
3930/**
Wink Savillec0114b32011-02-18 10:14:07 -08003931 * RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE - Deprecated use the status
3932 * field in RIL_Data_Call_Response_v6.
Wink Saville7f856802009-06-09 10:23:37 -07003933 *
3934 * Requests the failure cause code for the most recently failed PDP
Wink Savillef4c4d362009-04-02 01:37:03 -07003935 * context or CDMA data connection active
3936 * replaces RIL_REQUEST_LAST_PDP_FAIL_CAUSE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003937 *
3938 * "data" is NULL
3939 *
3940 * "response" is a "int *"
3941 * ((int *)response)[0] is an integer cause code defined in TS 24.008
3942 * section 6.1.3.1.3 or close approximation
3943 *
3944 * If the implementation does not have access to the exact cause codes,
Wink Saville7f856802009-06-09 10:23:37 -07003945 * then it should return one of the values listed in
Wink Saville43808972011-01-13 17:39:51 -08003946 * RIL_DataCallFailCause, as the UI layer needs to distinguish these
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003947 * cases for error notification
3948 * and potential retries.
3949 *
3950 * Valid errors:
3951 * SUCCESS
3952 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07003953 * INTERNAL_ERR
3954 * NO_MEMORY
3955 * NO_RESOURCES
3956 * CANCELLED
3957 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003958 *
3959 * See also: RIL_REQUEST_LAST_CALL_FAIL_CAUSE
Wink Savillec0114b32011-02-18 10:14:07 -08003960 *
3961 * Deprecated use the status field in RIL_Data_Call_Response_v6.
Wink Saville7f856802009-06-09 10:23:37 -07003962 */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003963
Wink Savillef4c4d362009-04-02 01:37:03 -07003964#define RIL_REQUEST_LAST_DATA_CALL_FAIL_CAUSE 56
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003965
3966/**
Wink Savillef4c4d362009-04-02 01:37:03 -07003967 * RIL_REQUEST_DATA_CALL_LIST
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003968 *
Wink Saville29487ef2011-04-15 09:15:31 -07003969 * Returns the data call list. An entry is added when a
3970 * RIL_REQUEST_SETUP_DATA_CALL is issued and removed on a
3971 * RIL_REQUEST_DEACTIVATE_DATA_CALL. The list is emptied
3972 * when RIL_REQUEST_RADIO_POWER off/on is issued.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003973 *
3974 * "data" is NULL
Wink Savillec0114b32011-02-18 10:14:07 -08003975 * "response" is an array of RIL_Data_Call_Response_v6
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003976 *
3977 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07003978 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003979 * RADIO_NOT_AVAILABLE (radio resetting)
sqiana216ed42017-06-20 11:54:31 -07003980 * INTERNAL_ERR
3981 * NO_MEMORY
3982 * NO_RESOURCES
3983 * CANCELLED
3984 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08003985 * SIM_ABSENT
Wink Saville29487ef2011-04-15 09:15:31 -07003986 *
3987 * See also: RIL_UNSOL_DATA_CALL_LIST_CHANGED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003988 */
3989
Wink Savillef4c4d362009-04-02 01:37:03 -07003990#define RIL_REQUEST_DATA_CALL_LIST 57
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003991
3992/**
johnwangf8bc1672009-05-14 19:19:47 -07003993 * RIL_REQUEST_RESET_RADIO - DEPRECATED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08003994 *
3995 * Request a radio reset. The RIL implementation may postpone
3996 * the reset until after this request is responded to if the baseband
3997 * is presently busy.
3998 *
johnwangf8bc1672009-05-14 19:19:47 -07003999 * The request is DEPRECATED, use RIL_REQUEST_RADIO_POWER
4000 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004001 * "data" is NULL
4002 * "response" is NULL
4003 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004004 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07004005 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004006 * RADIO_NOT_AVAILABLE (radio resetting)
johnwangf8bc1672009-05-14 19:19:47 -07004007 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004008 */
4009
4010#define RIL_REQUEST_RESET_RADIO 58
4011
4012/**
4013 * RIL_REQUEST_OEM_HOOK_RAW
4014 *
4015 * This request reserved for OEM-specific uses. It passes raw byte arrays
4016 * back and forth.
4017 *
Wink Saville7f856802009-06-09 10:23:37 -07004018 * It can be invoked on the Java side from
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004019 * com.android.internal.telephony.Phone.invokeOemRilRequestRaw()
4020 *
4021 * "data" is a char * of bytes copied from the byte[] data argument in java
4022 * "response" is a char * of bytes that will returned via the
Wink Saville7f856802009-06-09 10:23:37 -07004023 * caller's "response" Message here:
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004024 * (byte[])(((AsyncResult)response.obj).result)
4025 *
Wink Saville7f856802009-06-09 10:23:37 -07004026 * An error response here will result in
4027 * (((AsyncResult)response.obj).result) == null and
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004028 * (((AsyncResult)response.obj).exception) being an instance of
4029 * com.android.internal.telephony.gsm.CommandException
4030 *
4031 * Valid errors:
4032 * All
4033 */
4034
4035#define RIL_REQUEST_OEM_HOOK_RAW 59
4036
4037/**
4038 * RIL_REQUEST_OEM_HOOK_STRINGS
4039 *
4040 * This request reserved for OEM-specific uses. It passes strings
4041 * back and forth.
4042 *
Wink Saville7f856802009-06-09 10:23:37 -07004043 * It can be invoked on the Java side from
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004044 * com.android.internal.telephony.Phone.invokeOemRilRequestStrings()
4045 *
4046 * "data" is a const char **, representing an array of null-terminated UTF-8
4047 * strings copied from the "String[] strings" argument to
4048 * invokeOemRilRequestStrings()
4049 *
4050 * "response" is a const char **, representing an array of null-terminated UTF-8
4051 * stings that will be returned via the caller's response message here:
4052 *
4053 * (String[])(((AsyncResult)response.obj).result)
4054 *
Wink Saville7f856802009-06-09 10:23:37 -07004055 * An error response here will result in
4056 * (((AsyncResult)response.obj).result) == null and
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004057 * (((AsyncResult)response.obj).exception) being an instance of
4058 * com.android.internal.telephony.gsm.CommandException
4059 *
4060 * Valid errors:
4061 * All
4062 */
4063
4064#define RIL_REQUEST_OEM_HOOK_STRINGS 60
4065
4066/**
Jack Yude8c8552017-01-24 12:03:52 -08004067 * RIL_REQUEST_SCREEN_STATE - DEPRECATED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004068 *
4069 * Indicates the current state of the screen. When the screen is off, the
4070 * RIL should notify the baseband to suppress certain notifications (eg,
jsh43265612009-09-29 17:46:11 -07004071 * signal strength and changes in LAC/CID or BID/SID/NID/latitude/longitude)
4072 * in an effort to conserve power. These notifications should resume when the
4073 * screen is on.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004074 *
Jack Yude8c8552017-01-24 12:03:52 -08004075 * Note this request is deprecated. Use RIL_REQUEST_SEND_DEVICE_STATE to report the device state
4076 * to the modem and use RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER to turn on/off unsolicited
4077 * response from the modem in different scenarios.
4078 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004079 * "data" is int *
4080 * ((int *)data)[0] is == 1 for "Screen On"
4081 * ((int *)data)[0] is == 0 for "Screen Off"
4082 *
4083 * "response" is NULL
4084 *
4085 * Valid errors:
4086 * SUCCESS
Naina Nalluri67728582017-05-04 17:40:04 -07004087 * NO_MEMORY
4088 * INTERNAL_ERR
4089 * SYSTEM_ERR
4090 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07004091 * NO_RESOURCES
4092 * CANCELLED
Naina Nalluri67728582017-05-04 17:40:04 -07004093 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004094 */
4095#define RIL_REQUEST_SCREEN_STATE 61
4096
4097
4098/**
4099 * RIL_REQUEST_SET_SUPP_SVC_NOTIFICATION
4100 *
4101 * Enables/disables supplementary service related notifications
4102 * from the network.
4103 *
4104 * Notifications are reported via RIL_UNSOL_SUPP_SVC_NOTIFICATION.
4105 *
4106 * "data" is int *
4107 * ((int *)data)[0] is == 1 for notifications enabled
4108 * ((int *)data)[0] is == 0 for notifications disabled
4109 *
4110 * "response" is NULL
4111 *
4112 * Valid errors:
4113 * SUCCESS
4114 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08004115 * SIM_BUSY
Ajay Nambi10345892016-03-19 09:02:28 -07004116 * INVALID_ARGUMENTS
4117 * NO_MEMORY
4118 * SYSTEM_ERR
4119 * MODEM_ERR
4120 * INTERNAL_ERR
sqiana216ed42017-06-20 11:54:31 -07004121 * NO_RESOURCES
4122 * CANCELLED
4123 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004124 *
4125 * See also: RIL_UNSOL_SUPP_SVC_NOTIFICATION.
4126 */
4127#define RIL_REQUEST_SET_SUPP_SVC_NOTIFICATION 62
4128
4129/**
4130 * RIL_REQUEST_WRITE_SMS_TO_SIM
4131 *
4132 * Stores a SMS message to SIM memory.
4133 *
4134 * "data" is RIL_SMS_WriteArgs *
4135 *
4136 * "response" is int *
4137 * ((const int *)response)[0] is the record index where the message is stored.
4138 *
4139 * Valid errors:
4140 * SUCCESS
twen.changdf7add02016-03-04 18:27:48 +08004141 * SIM_FULL
Ajay Nambi68900f52016-03-11 12:02:55 -08004142 * INVALID_ARGUMENTS
4143 * INVALID_SMS_FORMAT
4144 * INTERNAL_ERR
4145 * MODEM_ERR
4146 * ENCODING_ERR
4147 * NO_MEMORY
4148 * NO_RESOURCES
4149 * INVALID_MODEM_STATE
Naina Nalluri1d3f4482017-07-17 11:44:37 -07004150 * OPERATION_NOT_ALLOWED
Ajay Nambi68900f52016-03-11 12:02:55 -08004151 * INVALID_SMSC_ADDRESS
sqiana216ed42017-06-20 11:54:31 -07004152 * CANCELLED
4153 * INVALID_MODEM_STATE
4154 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08004155 * SIM_ABSENT
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004156 *
4157 */
4158#define RIL_REQUEST_WRITE_SMS_TO_SIM 63
4159
4160/**
4161 * RIL_REQUEST_DELETE_SMS_ON_SIM
4162 *
4163 * Deletes a SMS message from SIM memory.
4164 *
4165 * "data" is int *
4166 * ((int *)data)[0] is the record index of the message to delete.
4167 *
4168 * "response" is NULL
4169 *
4170 * Valid errors:
4171 * SUCCESS
twen.changdf7add02016-03-04 18:27:48 +08004172 * SIM_FULL
Ajay Nambi68900f52016-03-11 12:02:55 -08004173 * INVALID_ARGUMENTS
4174 * NO_MEMORY
4175 * REQUEST_RATE_LIMITED
4176 * SYSTEM_ERR
4177 * MODEM_ERR
4178 * NO_SUCH_ENTRY
sqiana216ed42017-06-20 11:54:31 -07004179 * INTERNAL_ERR
4180 * NO_RESOURCES
4181 * CANCELLED
4182 * INVALID_MODEM_STATE
4183 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08004184 * SIM_ABSENT
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004185 *
4186 */
4187#define RIL_REQUEST_DELETE_SMS_ON_SIM 64
4188
4189/**
4190 * RIL_REQUEST_SET_BAND_MODE
4191 *
4192 * Assign a specified band for RF configuration.
4193 *
4194 * "data" is int *
Nathan Harold92839f12016-02-12 10:02:28 -08004195 * ((int *)data)[0] is a RIL_RadioBandMode
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004196 *
4197 * "response" is NULL
4198 *
4199 * Valid errors:
4200 * SUCCESS
4201 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08004202 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07004203 * NO_MEMORY
4204 * INTERNAL_ERR
4205 * SYSTEM_ERR
4206 * INVALID_ARGUMENTS
4207 * MODEM_ERR
4208 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004209 * NO_RESOURCES
4210 * CANCELLED
Nathan Harold92839f12016-02-12 10:02:28 -08004211 *
4212 * See also: RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004213 */
4214#define RIL_REQUEST_SET_BAND_MODE 65
4215
4216/**
4217 * RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE
4218 *
4219 * Query the list of band mode supported by RF.
4220 *
4221 * "data" is NULL
4222 *
4223 * "response" is int *
Nathan Harold92839f12016-02-12 10:02:28 -08004224 * "response" points to an array of int's, the int[0] is the size of array;
4225 * subsequent values are a list of RIL_RadioBandMode listing supported modes.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004226 *
4227 * Valid errors:
4228 * SUCCESS
4229 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004230 * NO_MEMORY
4231 * INTERNAL_ERR
4232 * SYSTEM_ERR
4233 * MODEM_ERR
4234 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004235 * NO_RESOURCES
4236 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004237 *
4238 * See also: RIL_REQUEST_SET_BAND_MODE
4239 */
4240#define RIL_REQUEST_QUERY_AVAILABLE_BAND_MODE 66
4241
4242/**
4243 * RIL_REQUEST_STK_GET_PROFILE
4244 *
4245 * Requests the profile of SIM tool kit.
4246 * The profile indicates the SAT/USAT features supported by ME.
4247 * The SAT/USAT features refer to 3GPP TS 11.14 and 3GPP TS 31.111
4248 *
4249 * "data" is NULL
4250 *
4251 * "response" is a const char * containing SAT/USAT profile
4252 * in hexadecimal format string starting with first byte of terminal profile
4253 *
4254 * Valid errors:
4255 * RIL_E_SUCCESS
4256 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
sqiana216ed42017-06-20 11:54:31 -07004257 * INTERNAL_ERR
4258 * NO_MEMORY
4259 * NO_RESOURCES
4260 * CANCELLED
4261 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004262 */
4263#define RIL_REQUEST_STK_GET_PROFILE 67
4264
4265/**
4266 * RIL_REQUEST_STK_SET_PROFILE
4267 *
4268 * Download the STK terminal profile as part of SIM initialization
4269 * procedure
4270 *
4271 * "data" is a const char * containing SAT/USAT profile
4272 * in hexadecimal format string starting with first byte of terminal profile
4273 *
4274 * "response" is NULL
4275 *
4276 * Valid errors:
4277 * RIL_E_SUCCESS
4278 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
sqiana216ed42017-06-20 11:54:31 -07004279 * INTERNAL_ERR
4280 * NO_MEMORY
4281 * NO_RESOURCES
4282 * CANCELLED
4283 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004284 */
4285#define RIL_REQUEST_STK_SET_PROFILE 68
4286
4287/**
4288 * RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND
4289 *
4290 * Requests to send a SAT/USAT envelope command to SIM.
4291 * The SAT/USAT envelope command refers to 3GPP TS 11.14 and 3GPP TS 31.111
4292 *
4293 * "data" is a const char * containing SAT/USAT command
4294 * in hexadecimal format string starting with command tag
4295 *
4296 * "response" is a const char * containing SAT/USAT response
4297 * in hexadecimal format string starting with first byte of response
4298 * (May be NULL)
4299 *
4300 * Valid errors:
4301 * RIL_E_SUCCESS
4302 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
twen.changdf7add02016-03-04 18:27:48 +08004303 * SIM_BUSY
4304 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004305 * INTERNAL_ERR
4306 * NO_MEMORY
4307 * NO_RESOURCES
4308 * CANCELLED
4309 * INVALID_ARGUMENTS
4310 * MODEM_ERR
4311 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004312 */
4313#define RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND 69
4314
4315/**
4316 * RIL_REQUEST_STK_SEND_TERMINAL_RESPONSE
4317 *
4318 * Requests to send a terminal response to SIM for a received
4319 * proactive command
4320 *
4321 * "data" is a const char * containing SAT/USAT response
4322 * in hexadecimal format string starting with first byte of response data
4323 *
4324 * "response" is NULL
4325 *
4326 * Valid errors:
4327 * RIL_E_SUCCESS
4328 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
twen.changdf7add02016-03-04 18:27:48 +08004329 * RIL_E_OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004330 * INTERNAL_ERR
4331 * NO_MEMORY
4332 * NO_RESOURCES
4333 * CANCELLED
4334 * INVALID_MODEM_STATE
4335 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004336 */
4337#define RIL_REQUEST_STK_SEND_TERMINAL_RESPONSE 70
4338
4339/**
4340 * RIL_REQUEST_STK_HANDLE_CALL_SETUP_REQUESTED_FROM_SIM
4341 *
4342 * When STK application gets RIL_UNSOL_STK_CALL_SETUP, the call actually has
4343 * been initialized by ME already. (We could see the call has been in the 'call
4344 * list') So, STK application needs to accept/reject the call according as user
4345 * operations.
4346 *
4347 * "data" is int *
4348 * ((int *)data)[0] is > 0 for "accept" the call setup
4349 * ((int *)data)[0] is == 0 for "reject" the call setup
4350 *
4351 * "response" is NULL
4352 *
4353 * Valid errors:
4354 * RIL_E_SUCCESS
4355 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
twen.changdf7add02016-03-04 18:27:48 +08004356 * RIL_E_OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004357 * INTERNAL_ERR
4358 * NO_MEMORY
4359 * NO_RESOURCES
4360 * CANCELLED
4361 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004362 */
4363#define RIL_REQUEST_STK_HANDLE_CALL_SETUP_REQUESTED_FROM_SIM 71
4364
4365/**
4366 * RIL_REQUEST_EXPLICIT_CALL_TRANSFER
4367 *
4368 * Connects the two calls and disconnects the subscriber from both calls.
Wink Saville7f856802009-06-09 10:23:37 -07004369 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004370 * "data" is NULL
4371 * "response" is NULL
4372 *
4373 * Valid errors:
Wink Saville7f856802009-06-09 10:23:37 -07004374 * SUCCESS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004375 * RADIO_NOT_AVAILABLE (radio resetting)
Ajay Nambi10345892016-03-19 09:02:28 -07004376 * INVALID_STATE
4377 * NO_RESOURCES
4378 * NO_MEMORY
4379 * INVALID_ARGUMENTS
4380 * SYSTEM_ERR
4381 * MODEM_ERR
4382 * INTERNAL_ERR
4383 * INVALID_CALL_ID
4384 * INVALID_STATE
4385 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004386 * NO_RESOURCES
4387 * CANCELLED
4388 * REQUEST_NOT_SUPPORTED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004389 */
4390#define RIL_REQUEST_EXPLICIT_CALL_TRANSFER 72
4391
4392/**
4393 * RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE
4394 *
4395 * Requests to set the preferred network type for searching and registering
4396 * (CS/PS domain, RAT, and operation mode)
4397 *
Wink Savillec0114b32011-02-18 10:14:07 -08004398 * "data" is int * which is RIL_PreferredNetworkType
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004399 *
4400 * "response" is NULL
4401 *
4402 * Valid errors:
Wink Savillef4c4d362009-04-02 01:37:03 -07004403 * SUCCESS
4404 * RADIO_NOT_AVAILABLE (radio resetting)
twen.changdf7add02016-03-04 18:27:48 +08004405 * OPERATION_NOT_ALLOWED
Wink Savillef4c4d362009-04-02 01:37:03 -07004406 * MODE_NOT_SUPPORTED
Naina Nalluri67728582017-05-04 17:40:04 -07004407 * NO_MEMORY
4408 * INTERNAL_ERR
4409 * SYSTEM_ERR
4410 * INVALID_ARGUMENTS
4411 * MODEM_ERR
4412 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004413 * NO_RESOURCES
4414 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004415 */
4416#define RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE 73
4417
4418/**
4419 * RIL_REQUEST_GET_PREFERRED_NETWORK_TYPE
4420 *
4421 * Query the preferred network type (CS/PS domain, RAT, and operation mode)
4422 * for searching and registering
4423 *
4424 * "data" is NULL
4425 *
4426 * "response" is int *
Wink Savillec0114b32011-02-18 10:14:07 -08004427 * ((int *)reponse)[0] is == RIL_PreferredNetworkType
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004428 *
4429 * Valid errors:
4430 * SUCCESS
4431 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004432 * NO_MEMORY
4433 * INTERNAL_ERR
4434 * SYSTEM_ERR
4435 * INVALID_ARGUMENTS
4436 * MODEM_ERR
4437 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004438 * NO_RESOURCES
4439 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004440 *
4441 * See also: RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE
4442 */
4443#define RIL_REQUEST_GET_PREFERRED_NETWORK_TYPE 74
4444
4445/**
4446 * RIL_REQUEST_NEIGHBORING_CELL_IDS
4447 *
4448 * Request neighboring cell id in GSM network
4449 *
4450 * "data" is NULL
4451 * "response" must be a " const RIL_NeighboringCell** "
4452 *
4453 * Valid errors:
4454 * SUCCESS
4455 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004456 * NO_MEMORY
4457 * INTERNAL_ERR
4458 * SYSTEM_ERR
4459 * MODEM_ERR
4460 * NO_NETWORK_FOUND
4461 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004462 * NO_RESOURCES
4463 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004464 */
4465#define RIL_REQUEST_GET_NEIGHBORING_CELL_IDS 75
4466
4467/**
4468 * RIL_REQUEST_SET_LOCATION_UPDATES
Wink Saville3d54e742009-05-18 18:00:44 -07004469 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004470 * Enables/disables network state change notifications due to changes in
jsh43265612009-09-29 17:46:11 -07004471 * LAC and/or CID (for GSM) or BID/SID/NID/latitude/longitude (for CDMA).
4472 * Basically +CREG=2 vs. +CREG=1 (TS 27.007).
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004473 *
4474 * Note: The RIL implementation should default to "updates enabled"
4475 * when the screen is on and "updates disabled" when the screen is off.
4476 *
4477 * "data" is int *
4478 * ((int *)data)[0] is == 1 for updates enabled (+CREG=2)
4479 * ((int *)data)[0] is == 0 for updates disabled (+CREG=1)
4480 *
4481 * "response" is NULL
Wink Saville3d54e742009-05-18 18:00:44 -07004482 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004483 * Valid errors:
4484 * SUCCESS
4485 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004486 * NO_MEMORY
4487 * INTERNAL_ERR
4488 * SYSTEM_ERR
4489 * INVALID_ARGUMENTS
4490 * MODEM_ERR
4491 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004492 * NO_RESOURCES
4493 * CANCELLED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08004494 *
4495 * See also: RIL_REQUEST_SCREEN_STATE, RIL_UNSOL_RESPONSE_NETWORK_STATE_CHANGED
4496 */
4497#define RIL_REQUEST_SET_LOCATION_UPDATES 76
4498
Wink Savillef4c4d362009-04-02 01:37:03 -07004499/**
Wink Savillec0114b32011-02-18 10:14:07 -08004500 * RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE
Wink Saville7f856802009-06-09 10:23:37 -07004501 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004502 * Request to set the location where the CDMA subscription shall
4503 * be retrieved
4504 *
4505 * "data" is int *
Wink Savillec0114b32011-02-18 10:14:07 -08004506 * ((int *)data)[0] is == RIL_CdmaSubscriptionSource
Wink Savillef4c4d362009-04-02 01:37:03 -07004507 *
4508 * "response" is NULL
4509 *
4510 * Valid errors:
4511 * SUCCESS
4512 * RADIO_NOT_AVAILABLE
Wink Savillef4c4d362009-04-02 01:37:03 -07004513 * SIM_ABSENT
4514 * SUBSCRIPTION_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07004515 * INTERNAL_ERR
4516 * NO_MEMORY
4517 * NO_RESOURCES
4518 * CANCELLED
4519 * REQUEST_NOT_SUPPORTED
Wink Savillec0114b32011-02-18 10:14:07 -08004520 *
4521 * See also: RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE
Wink Savillef4c4d362009-04-02 01:37:03 -07004522 */
Wink Savillec0114b32011-02-18 10:14:07 -08004523#define RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE 77
Wink Savillef4c4d362009-04-02 01:37:03 -07004524
4525/**
4526 * RIL_REQUEST_CDMA_SET_ROAMING_PREFERENCE
Wink Saville7f856802009-06-09 10:23:37 -07004527 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004528 * Request to set the roaming preferences in CDMA
4529 *
4530 * "data" is int *
4531 * ((int *)data)[0] is == 0 for Home Networks only, as defined in PRL
4532 * ((int *)data)[0] is == 1 for Roaming on Affiliated networks, as defined in PRL
4533 * ((int *)data)[0] is == 2 for Roaming on Any Network, as defined in the PRL
Wink Saville7f856802009-06-09 10:23:37 -07004534 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004535 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004536 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004537 * Valid errors:
4538 * SUCCESS
4539 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004540 * NO_MEMORY
4541 * INTERNAL_ERR
4542 * SYSTEM_ERR
4543 * INVALID_ARGUMENTS
4544 * MODEM_ERR
4545 * REQUEST_NOT_SUPPORTED
4546 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004547 * NO_RESOURCES
4548 * CANCELLED
Wink Savillef4c4d362009-04-02 01:37:03 -07004549 */
4550#define RIL_REQUEST_CDMA_SET_ROAMING_PREFERENCE 78
4551
4552/**
4553 * RIL_REQUEST_CDMA_QUERY_ROAMING_PREFERENCE
Wink Saville7f856802009-06-09 10:23:37 -07004554 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004555 * Request the actual setting of the roaming preferences in CDMA in the modem
4556 *
4557 * "data" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004558 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004559 * "response" is int *
4560 * ((int *)response)[0] is == 0 for Home Networks only, as defined in PRL
4561 * ((int *)response)[0] is == 1 for Roaming on Affiliated networks, as defined in PRL
4562 * ((int *)response)[0] is == 2 for Roaming on Any Network, as defined in the PRL
Wink Saville7f856802009-06-09 10:23:37 -07004563 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004564 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004565 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004566 * Valid errors:
4567 * SUCCESS
4568 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004569 * NO_MEMORY
4570 * INTERNAL_ERR
4571 * SYSTEM_ERR
4572 * INVALID_ARGUMENTS
4573 * MODEM_ERR
4574 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004575 * NO_RESOURCES
4576 * CANCELLED
Wink Savillef4c4d362009-04-02 01:37:03 -07004577 */
4578#define RIL_REQUEST_CDMA_QUERY_ROAMING_PREFERENCE 79
4579
4580/**
4581 * RIL_REQUEST_SET_TTY_MODE
Wink Saville7f856802009-06-09 10:23:37 -07004582 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004583 * Request to set the TTY mode
4584 *
4585 * "data" is int *
4586 * ((int *)data)[0] is == 0 for TTY off
Wink Saville1b5fd232009-04-22 14:50:00 -07004587 * ((int *)data)[0] is == 1 for TTY Full
4588 * ((int *)data)[0] is == 2 for TTY HCO (hearing carryover)
4589 * ((int *)data)[0] is == 3 for TTY VCO (voice carryover)
Wink Saville7f856802009-06-09 10:23:37 -07004590 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004591 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004592 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004593 * Valid errors:
4594 * SUCCESS
4595 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004596 * INVALID_ARGUMENTS
4597 * MODEM_ERR
4598 * INTERNAL_ERR
sqiana216ed42017-06-20 11:54:31 -07004599 * NO_MEMORY
Ajay Nambi10345892016-03-19 09:02:28 -07004600 * INVALID_ARGUMENTS
4601 * MODEM_ERR
4602 * INTERNAL_ERR
sqiana216ed42017-06-20 11:54:31 -07004603 * NO_MEMORY
4604 * NO_RESOURCES
4605 * CANCELLED
4606 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004607 */
4608#define RIL_REQUEST_SET_TTY_MODE 80
4609
4610/**
4611 * RIL_REQUEST_QUERY_TTY_MODE
Wink Saville7f856802009-06-09 10:23:37 -07004612 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004613 * Request the setting of TTY mode
4614 *
4615 * "data" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004616 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004617 * "response" is int *
4618 * ((int *)response)[0] is == 0 for TTY off
Wink Saville1b5fd232009-04-22 14:50:00 -07004619 * ((int *)response)[0] is == 1 for TTY Full
4620 * ((int *)response)[0] is == 2 for TTY HCO (hearing carryover)
4621 * ((int *)response)[0] is == 3 for TTY VCO (voice carryover)
Wink Savillef4c4d362009-04-02 01:37:03 -07004622 *
4623 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004624 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004625 * Valid errors:
4626 * SUCCESS
4627 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004628 * MODEM_ERR
4629 * INTERNAL_ERR
4630 * NO_MEMORY
4631 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07004632 * NO_RESOURCES
4633 * CANCELLED
4634 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004635 */
4636#define RIL_REQUEST_QUERY_TTY_MODE 81
4637
4638/**
4639 * RIL_REQUEST_CDMA_SET_PREFERRED_VOICE_PRIVACY_MODE
4640 *
4641 * Request to set the preferred voice privacy mode used in voice
4642 * scrambling
4643 *
4644 * "data" is int *
4645 * ((int *)data)[0] is == 0 for Standard Privacy Mode (Public Long Code Mask)
4646 * ((int *)data)[0] is == 1 for Enhanced Privacy Mode (Private Long Code Mask)
Wink Saville7f856802009-06-09 10:23:37 -07004647 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004648 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004649 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004650 * Valid errors:
4651 * SUCCESS
4652 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004653 * INVALID_ARGUMENTS
4654 * SYSTEM_ERR
4655 * MODEM_ERR
4656 * INTERNAL_ERR
4657 * NO_MEMORY
4658 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07004659 * NO_RESOURCES
4660 * CANCELLED
4661 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004662 */
4663#define RIL_REQUEST_CDMA_SET_PREFERRED_VOICE_PRIVACY_MODE 82
4664
4665/**
4666 * RIL_REQUEST_CDMA_QUERY_PREFERRED_VOICE_PRIVACY_MODE
Wink Saville7f856802009-06-09 10:23:37 -07004667 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004668 * Request the setting of preferred voice privacy mode
4669 *
4670 * "data" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004671 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004672 * "response" is int *
4673 * ((int *)response)[0] is == 0 for Standard Privacy Mode (Public Long Code Mask)
4674 * ((int *)response)[0] is == 1 for Enhanced Privacy Mode (Private Long Code Mask)
Wink Saville7f856802009-06-09 10:23:37 -07004675 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004676 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004677 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004678 * Valid errors:
4679 * SUCCESS
4680 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004681 * MODEM_ERR
4682 * INTERNAL_ERR
4683 * NO_MEMORY
4684 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07004685 * NO_RESOURCES
4686 * CANCELLED
4687 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004688 */
4689#define RIL_REQUEST_CDMA_QUERY_PREFERRED_VOICE_PRIVACY_MODE 83
4690
4691/**
4692 * RIL_REQUEST_CDMA_FLASH
4693 *
4694 * Send FLASH
4695 *
4696 * "data" is const char *
4697 * ((const char *)data)[0] is a FLASH string
Wink Saville7f856802009-06-09 10:23:37 -07004698 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004699 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004700 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004701 * Valid errors:
4702 * SUCCESS
4703 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004704 * INVALID_ARGUMENTS
4705 * NO_MEMORY
4706 * SYSTEM_ERR
4707 * MODEM_ERR
4708 * INTERNAL_ERR
4709 * INVALID_CALL_ID
4710 * INVALID_STATE
sqiana216ed42017-06-20 11:54:31 -07004711 * NO_RESOURCES
4712 * CANCELLED
4713 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004714 *
4715 */
4716#define RIL_REQUEST_CDMA_FLASH 84
4717
4718/**
4719 * RIL_REQUEST_CDMA_BURST_DTMF
4720 *
4721 * Send DTMF string
4722 *
jsh602f80f2009-07-10 15:44:37 -07004723 * "data" is const char **
4724 * ((const char **)data)[0] is a DTMF string
4725 * ((const char **)data)[1] is the DTMF ON length in milliseconds, or 0 to use
4726 * default
4727 * ((const char **)data)[2] is the DTMF OFF length in milliseconds, or 0 to use
4728 * default
Wink Saville7f856802009-06-09 10:23:37 -07004729 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004730 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004731 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004732 * Valid errors:
4733 * SUCCESS
4734 * RADIO_NOT_AVAILABLE
Ajay Nambi10345892016-03-19 09:02:28 -07004735 * INVALID_ARGUMENTS
4736 * NO_MEMORY
4737 * SYSTEM_ERR
4738 * MODEM_ERR
4739 * INTERNAL_ERR
4740 * INVALID_CALL_ID
sqiana216ed42017-06-20 11:54:31 -07004741 * NO_RESOURCES
4742 * CANCELLED
Naina Nalluri1d3f4482017-07-17 11:44:37 -07004743 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004744 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004745 *
4746 */
4747#define RIL_REQUEST_CDMA_BURST_DTMF 85
4748
4749/**
Naveen Kalla03c1edf2009-09-23 11:18:35 -07004750 * RIL_REQUEST_CDMA_VALIDATE_AND_WRITE_AKEY
Wink Savillef4c4d362009-04-02 01:37:03 -07004751 *
Naveen Kalla03c1edf2009-09-23 11:18:35 -07004752 * Takes a 26 digit string (20 digit AKEY + 6 digit checksum).
4753 * If the checksum is valid the 20 digit AKEY is written to NV,
4754 * replacing the existing AKEY no matter what it was before.
Wink Savillef4c4d362009-04-02 01:37:03 -07004755 *
4756 * "data" is const char *
Naveen Kalla03c1edf2009-09-23 11:18:35 -07004757 * ((const char *)data)[0] is a 26 digit string (ASCII digits '0'-'9')
4758 * where the last 6 digits are a checksum of the
4759 * first 20, as specified in TR45.AHAG
4760 * "Common Cryptographic Algorithms, Revision D.1
4761 * Section 2.2"
Wink Saville7f856802009-06-09 10:23:37 -07004762 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004763 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004764 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004765 * Valid errors:
4766 * SUCCESS
4767 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07004768 * NO_MEMORY
4769 * INTERNAL_ERR
4770 * SYSTEM_ERR
4771 * INVALID_ARGUMENTS
4772 * MODEM_ERR
4773 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07004774 * NO_RESOURCES
4775 * CANCELLED
Wink Savillef4c4d362009-04-02 01:37:03 -07004776 *
4777 */
Naveen Kalla03c1edf2009-09-23 11:18:35 -07004778#define RIL_REQUEST_CDMA_VALIDATE_AND_WRITE_AKEY 86
Wink Savillef4c4d362009-04-02 01:37:03 -07004779
4780/**
4781 * RIL_REQUEST_CDMA_SEND_SMS
4782 *
4783 * Send a CDMA SMS message
4784 *
4785 * "data" is const RIL_CDMA_SMS_Message *
Wink Saville7f856802009-06-09 10:23:37 -07004786 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004787 * "response" is a const RIL_SMS_Response *
Wink Saville7f856802009-06-09 10:23:37 -07004788 *
johnwangbfb151b2009-09-11 15:20:38 -07004789 * Based on the return error, caller decides to resend if sending sms
4790 * fails. The CDMA error class is derived as follows,
4791 * SUCCESS is error class 0 (no error)
4792 * SMS_SEND_FAIL_RETRY is error class 2 (temporary failure)
johnwangbfb151b2009-09-11 15:20:38 -07004793 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004794 * Valid errors:
4795 * SUCCESS
4796 * RADIO_NOT_AVAILABLE
Wink Saville1b5fd232009-04-22 14:50:00 -07004797 * SMS_SEND_FAIL_RETRY
twen.changdf7add02016-03-04 18:27:48 +08004798 * NETWORK_REJECT
Ajay Nambi68900f52016-03-11 12:02:55 -08004799 * INVALID_STATE
4800 * INVALID_ARGUMENTS
4801 * NO_MEMORY
4802 * REQUEST_RATE_LIMITED
4803 * INVALID_SMS_FORMAT
4804 * SYSTEM_ERR
4805 * FDN_CHECK_FAILURE
4806 * MODEM_ERR
4807 * NETWORK_ERR
4808 * ENCODING_ERR
4809 * INVALID_SMSC_ADDRESS
Naina Nalluri1d3f4482017-07-17 11:44:37 -07004810 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07004811 * NO_RESOURCES
4812 * CANCELLED
4813 * REQUEST_NOT_SUPPORTED
Ajay Nambi68900f52016-03-11 12:02:55 -08004814 * MODE_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08004815 * SIM_ABSENT
Wink Savillef4c4d362009-04-02 01:37:03 -07004816 *
4817 */
4818#define RIL_REQUEST_CDMA_SEND_SMS 87
4819
4820/**
4821 * RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE
4822 *
4823 * Acknowledge the success or failure in the receipt of SMS
4824 * previously indicated via RIL_UNSOL_RESPONSE_CDMA_NEW_SMS
4825 *
4826 * "data" is const RIL_CDMA_SMS_Ack *
Wink Saville7f856802009-06-09 10:23:37 -07004827 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004828 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07004829 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004830 * Valid errors:
4831 * SUCCESS
4832 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004833 * INVALID_ARGUMENTS
4834 * NO_SMS_TO_ACK
4835 * INVALID_STATE
4836 * NO_MEMORY
4837 * REQUEST_RATE_LIMITED
4838 * SYSTEM_ERR
4839 * MODEM_ERR
4840 * INVALID_STATE
Naina Nalluri1d3f4482017-07-17 11:44:37 -07004841 * OPERATION_NOT_ALLOWED
Ajay Nambi68900f52016-03-11 12:02:55 -08004842 * NETWORK_NOT_READY
4843 * INVALID_MODEM_STATE
sqiana216ed42017-06-20 11:54:31 -07004844 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004845 *
4846 */
4847#define RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE 88
4848
4849/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004850 * RIL_REQUEST_GSM_GET_BROADCAST_SMS_CONFIG
Wink Savillef4c4d362009-04-02 01:37:03 -07004851 *
Wink Savillea592eeb2009-05-22 13:26:36 -07004852 * Request the setting of GSM/WCDMA Cell Broadcast SMS config.
4853 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004854 * "data" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07004855 *
4856 * "response" is a const RIL_GSM_BroadcastSmsConfigInfo **
4857 * "responselen" is count * sizeof (RIL_GSM_BroadcastSmsConfigInfo *)
4858 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004859 * Valid errors:
4860 * SUCCESS
4861 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004862 * INVALID_STATE
4863 * NO_MEMORY
4864 * REQUEST_RATE_LIMITED
4865 * SYSTEM_ERR
4866 * NO_RESOURCES
4867 * MODEM_ERR
4868 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07004869 * INTERNAL_ERR
4870 * NO_RESOURCES
4871 * CANCELLED
4872 * INVALID_MODEM_STATE
4873 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004874 */
Wink Savillea592eeb2009-05-22 13:26:36 -07004875#define RIL_REQUEST_GSM_GET_BROADCAST_SMS_CONFIG 89
Wink Savillef4c4d362009-04-02 01:37:03 -07004876
4877/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004878 * RIL_REQUEST_GSM_SET_BROADCAST_SMS_CONFIG
Wink Savillef4c4d362009-04-02 01:37:03 -07004879 *
4880 * Set GSM/WCDMA Cell Broadcast SMS config
4881 *
Wink Savillea592eeb2009-05-22 13:26:36 -07004882 * "data" is a const RIL_GSM_BroadcastSmsConfigInfo **
4883 * "datalen" is count * sizeof(RIL_GSM_BroadcastSmsConfigInfo *)
4884 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004885 * "response" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07004886 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004887 * Valid errors:
4888 * SUCCESS
4889 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004890 * INVALID_STATE
4891 * INVALID_ARGUMENTS
4892 * NO_MEMORY
4893 * SYSTEM_ERR
4894 * REQUEST_RATE_LIMITED
4895 * MODEM_ERR
4896 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07004897 * INTERNAL_ERR
4898 * NO_RESOURCES
4899 * CANCELLED
4900 * INVALID_MODEM_STATE
4901 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004902 *
4903 */
Wink Savillea592eeb2009-05-22 13:26:36 -07004904#define RIL_REQUEST_GSM_SET_BROADCAST_SMS_CONFIG 90
Wink Savillef4c4d362009-04-02 01:37:03 -07004905
4906/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004907 * RIL_REQUEST_GSM_SMS_BROADCAST_ACTIVATION
Wink Savillef4c4d362009-04-02 01:37:03 -07004908 *
Wink Savillea592eeb2009-05-22 13:26:36 -07004909* Enable or disable the reception of GSM/WCDMA Cell Broadcast SMS
Wink Savillef4c4d362009-04-02 01:37:03 -07004910 *
4911 * "data" is const int *
4912 * (const int *)data[0] indicates to activate or turn off the
4913 * reception of GSM/WCDMA Cell Broadcast SMS, 0-1,
4914 * 0 - Activate, 1 - Turn off
Wink Savillea592eeb2009-05-22 13:26:36 -07004915 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004916 * "response" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07004917 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004918 * Valid errors:
4919 * SUCCESS
4920 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004921 * INVALID_STATE
4922 * INVALID_ARGUMENTS
4923 * NO_MEMORY
4924 * SYSTEM_ERR
4925 * REQUEST_RATE_LIMITED
sqiana216ed42017-06-20 11:54:31 -07004926* MODEM_ERR
4927* INTERNAL_ERR
4928* NO_RESOURCES
4929* CANCELLED
4930* INVALID_MODEM_STATE
4931 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004932 *
4933 */
Wink Savillea592eeb2009-05-22 13:26:36 -07004934#define RIL_REQUEST_GSM_SMS_BROADCAST_ACTIVATION 91
Wink Savillef4c4d362009-04-02 01:37:03 -07004935
4936/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004937 * RIL_REQUEST_CDMA_GET_BROADCAST_SMS_CONFIG
Wink Savillef4c4d362009-04-02 01:37:03 -07004938 *
4939 * Request the setting of CDMA Broadcast SMS config
4940 *
4941 * "data" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07004942 *
4943 * "response" is a const RIL_CDMA_BroadcastSmsConfigInfo **
4944 * "responselen" is count * sizeof (RIL_CDMA_BroadcastSmsConfigInfo *)
4945 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004946 * Valid errors:
4947 * SUCCESS
4948 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004949 * INVALID_STATE
4950 * NO_MEMORY
4951 * REQUEST_RATE_LIMITED
4952 * SYSTEM_ERR
4953 * NO_RESOURCES
4954 * MODEM_ERR
4955 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07004956 * INTERNAL_ERR
4957 * NO_RESOURCES
4958 * CANCELLED
4959 * INVALID_MODEM_STATE
4960 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004961 *
4962 */
Wink Savillea592eeb2009-05-22 13:26:36 -07004963#define RIL_REQUEST_CDMA_GET_BROADCAST_SMS_CONFIG 92
Wink Savillef4c4d362009-04-02 01:37:03 -07004964
4965/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004966 * RIL_REQUEST_CDMA_SET_BROADCAST_SMS_CONFIG
Wink Savillef4c4d362009-04-02 01:37:03 -07004967 *
4968 * Set CDMA Broadcast SMS config
4969 *
Jack Yude8c8552017-01-24 12:03:52 -08004970 * "data" is a const RIL_CDMA_BroadcastSmsConfigInfo **
Wink Savillea592eeb2009-05-22 13:26:36 -07004971 * "datalen" is count * sizeof(const RIL_CDMA_BroadcastSmsConfigInfo *)
4972 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004973 * "response" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07004974 *
Wink Savillef4c4d362009-04-02 01:37:03 -07004975 * Valid errors:
4976 * SUCCESS
4977 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08004978 * INVALID_STATE
4979 * INVALID_ARGUMENTS
4980 * NO_MEMORY
4981 * SYSTEM_ERR
4982 * REQUEST_RATE_LIMITED
4983 * MODEM_ERR
4984 * SYSTEM_ERR
sqiana216ed42017-06-20 11:54:31 -07004985 * INTERNAL_ERR
4986 * NO_RESOURCES
4987 * CANCELLED
4988 * INVALID_MODEM_STATE
4989 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07004990 *
4991 */
Wink Savillea592eeb2009-05-22 13:26:36 -07004992#define RIL_REQUEST_CDMA_SET_BROADCAST_SMS_CONFIG 93
Wink Savillef4c4d362009-04-02 01:37:03 -07004993
4994/**
Wink Savillea592eeb2009-05-22 13:26:36 -07004995 * RIL_REQUEST_CDMA_SMS_BROADCAST_ACTIVATION
Wink Savillef4c4d362009-04-02 01:37:03 -07004996 *
4997 * Enable or disable the reception of CDMA Broadcast SMS
4998 *
4999 * "data" is const int *
5000 * (const int *)data[0] indicates to activate or turn off the
5001 * reception of CDMA Broadcast SMS, 0-1,
5002 * 0 - Activate, 1 - Turn off
Wink Savillea592eeb2009-05-22 13:26:36 -07005003 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005004 * "response" is NULL
Wink Savillea592eeb2009-05-22 13:26:36 -07005005 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005006 * Valid errors:
5007 * SUCCESS
5008 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08005009 * INVALID_STATE
5010 * INVALID_ARGUMENTS
5011 * NO_MEMORY
5012 * SYSTEM_ERR
5013 * REQUEST_RATE_LIMITED
5014 * MODEM_ERR
sqiana216ed42017-06-20 11:54:31 -07005015 * INTERNAL_ERR
5016 * NO_RESOURCES
5017 * CANCELLED
5018 * INVALID_MODEM_STATE
5019 * REQUEST_NOT_SUPPORTED
Wink Savillef4c4d362009-04-02 01:37:03 -07005020 *
5021 */
Wink Savillea592eeb2009-05-22 13:26:36 -07005022#define RIL_REQUEST_CDMA_SMS_BROADCAST_ACTIVATION 94
Wink Savillef4c4d362009-04-02 01:37:03 -07005023
5024/**
5025 * RIL_REQUEST_CDMA_SUBSCRIPTION
5026 *
5027 * Request the device MDN / H_SID / H_NID.
5028 *
5029 * The request is only allowed when CDMA subscription is available. When CDMA
5030 * subscription is changed, application layer should re-issue the request to
5031 * update the subscription information.
5032 *
5033 * If a NULL value is returned for any of the device id, it means that error
5034 * accessing the device.
5035 *
5036 * "response" is const char **
5037 * ((const char **)response)[0] is MDN if CDMA subscription is available
jsh29be25c2009-07-14 20:18:59 -07005038 * ((const char **)response)[1] is a comma separated list of H_SID (Home SID) if
5039 * CDMA subscription is available, in decimal format
5040 * ((const char **)response)[2] is a comma separated list of H_NID (Home NID) if
5041 * CDMA subscription is available, in decimal format
Wink Saville1b5fd232009-04-22 14:50:00 -07005042 * ((const char **)response)[3] is MIN (10 digits, MIN2+MIN1) if CDMA subscription is available
Wink Savilled4ee7dc2009-06-05 15:11:30 -07005043 * ((const char **)response)[4] is PRL version if CDMA subscription is available
Wink Savillef4c4d362009-04-02 01:37:03 -07005044 *
5045 * Valid errors:
5046 * SUCCESS
5047 * RIL_E_SUBSCRIPTION_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07005048 * NO_MEMORY
5049 * INTERNAL_ERR
5050 * SYSTEM_ERR
5051 * INVALID_ARGUMENTS
5052 * MODEM_ERR
5053 * NOT_PROVISIONED
5054 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005055 * INTERNAL_ERR
5056 * NO_RESOURCES
5057 * CANCELLED
Naina Nalluri67728582017-05-04 17:40:04 -07005058 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005059 */
5060
Wink Savilleeafe79d2009-04-03 18:02:34 -07005061#define RIL_REQUEST_CDMA_SUBSCRIPTION 95
Wink Savillef4c4d362009-04-02 01:37:03 -07005062
5063/**
5064 * RIL_REQUEST_CDMA_WRITE_SMS_TO_RUIM
5065 *
5066 * Stores a CDMA SMS message to RUIM memory.
5067 *
5068 * "data" is RIL_CDMA_SMS_WriteArgs *
5069 *
5070 * "response" is int *
5071 * ((const int *)response)[0] is the record index where the message is stored.
5072 *
5073 * Valid errors:
5074 * SUCCESS
5075 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08005076 * SIM_FULL
Ajay Nambi68900f52016-03-11 12:02:55 -08005077 * INVALID_ARGUMENTS
5078 * INVALID_SMS_FORMAT
5079 * INTERNAL_ERR
5080 * MODEM_ERR
5081 * ENCODING_ERR
5082 * NO_MEMORY
5083 * NO_RESOURCES
5084 * INVALID_MODEM_STATE
Naina Nalluri1d3f4482017-07-17 11:44:37 -07005085 * OPERATION_NOT_ALLOWED
Ajay Nambi68900f52016-03-11 12:02:55 -08005086 * INVALID_SMSC_ADDRESS
sqiana216ed42017-06-20 11:54:31 -07005087 * CANCELLED
5088 * INVALID_MODEM_STATE
5089 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005090 * SIM_ABSENT
Wink Savillef4c4d362009-04-02 01:37:03 -07005091 *
5092 */
Wink Savilleeafe79d2009-04-03 18:02:34 -07005093#define RIL_REQUEST_CDMA_WRITE_SMS_TO_RUIM 96
Wink Savillef4c4d362009-04-02 01:37:03 -07005094
5095/**
5096 * RIL_REQUEST_CDMA_DELETE_SMS_ON_RUIM
5097 *
5098 * Deletes a CDMA SMS message from RUIM memory.
5099 *
5100 * "data" is int *
5101 * ((int *)data)[0] is the record index of the message to delete.
5102 *
5103 * "response" is NULL
5104 *
5105 * Valid errors:
5106 * SUCCESS
5107 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08005108 * INVALID_ARGUMENTS
5109 * NO_MEMORY
5110 * REQUEST_RATE_LIMITED
5111 * SYSTEM_ERR
5112 * MODEM_ERR
5113 * NO_SUCH_ENTRY
sqiana216ed42017-06-20 11:54:31 -07005114 * INTERNAL_ERR
5115 * NO_RESOURCES
5116 * CANCELLED
5117 * INVALID_MODEM_STATE
5118 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005119 * SIM_ABSENT
Wink Savillef4c4d362009-04-02 01:37:03 -07005120 */
Wink Savilleeafe79d2009-04-03 18:02:34 -07005121#define RIL_REQUEST_CDMA_DELETE_SMS_ON_RUIM 97
Wink Savillef4c4d362009-04-02 01:37:03 -07005122
5123/**
5124 * RIL_REQUEST_DEVICE_IDENTITY
Wink Savilleeafe79d2009-04-03 18:02:34 -07005125 *
5126 * Request the device ESN / MEID / IMEI / IMEISV.
5127 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005128 * The request is always allowed and contains GSM and CDMA device identity;
Wink Savilleeafe79d2009-04-03 18:02:34 -07005129 * it substitutes the deprecated requests RIL_REQUEST_GET_IMEI and
Wink Savillef4c4d362009-04-02 01:37:03 -07005130 * RIL_REQUEST_GET_IMEISV.
Wink Savilleeafe79d2009-04-03 18:02:34 -07005131 *
5132 * If a NULL value is returned for any of the device id, it means that error
Wink Savillef4c4d362009-04-02 01:37:03 -07005133 * accessing the device.
Wink Savilleeafe79d2009-04-03 18:02:34 -07005134 *
5135 * When CDMA subscription is changed the ESN/MEID may change. The application
Wink Savillef4c4d362009-04-02 01:37:03 -07005136 * layer should re-issue the request to update the device identity in this case.
Wink Savilleeafe79d2009-04-03 18:02:34 -07005137 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005138 * "response" is const char **
Wink Savilleeafe79d2009-04-03 18:02:34 -07005139 * ((const char **)response)[0] is IMEI if GSM subscription is available
5140 * ((const char **)response)[1] is IMEISV if GSM subscription is available
5141 * ((const char **)response)[2] is ESN if CDMA subscription is available
5142 * ((const char **)response)[3] is MEID if CDMA subscription is available
5143 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005144 * Valid errors:
5145 * SUCCESS
5146 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07005147 * NO_MEMORY
5148 * INTERNAL_ERR
5149 * SYSTEM_ERR
5150 * INVALID_ARGUMENTS
5151 * MODEM_ERR
5152 * NOT_PROVISIONED
5153 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005154 * NO_RESOURCES
5155 * CANCELLED
Naina Nalluri67728582017-05-04 17:40:04 -07005156 *
Wink Savillef4c4d362009-04-02 01:37:03 -07005157 */
Wink Savilleeafe79d2009-04-03 18:02:34 -07005158#define RIL_REQUEST_DEVICE_IDENTITY 98
Wink Savillef4c4d362009-04-02 01:37:03 -07005159
Wink Saville1b5fd232009-04-22 14:50:00 -07005160/**
5161 * RIL_REQUEST_EXIT_EMERGENCY_CALLBACK_MODE
5162 *
5163 * Request the radio's system selection module to exit emergency
5164 * callback mode. RIL will not respond with SUCCESS until the modem has
5165 * completely exited from Emergency Callback Mode.
5166 *
5167 * "data" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07005168 *
Wink Saville1b5fd232009-04-22 14:50:00 -07005169 * "response" is NULL
Wink Saville7f856802009-06-09 10:23:37 -07005170 *
Wink Saville1b5fd232009-04-22 14:50:00 -07005171 * Valid errors:
5172 * SUCCESS
5173 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08005174 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07005175 * NO_MEMORY
5176 * INTERNAL_ERR
5177 * SYSTEM_ERR
5178 * INVALID_ARGUMENTS
5179 * MODEM_ERR
5180 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005181 * NO_RESOURCES
5182 * CANCELLED
Wink Saville1b5fd232009-04-22 14:50:00 -07005183 *
5184 */
5185#define RIL_REQUEST_EXIT_EMERGENCY_CALLBACK_MODE 99
Wink Savillef4c4d362009-04-02 01:37:03 -07005186
jsh000a9fe2009-05-11 14:52:35 -07005187/**
5188 * RIL_REQUEST_GET_SMSC_ADDRESS
5189 *
5190 * Queries the default Short Message Service Center address on the device.
5191 *
5192 * "data" is NULL
5193 *
5194 * "response" is const char * containing the SMSC address.
5195 *
5196 * Valid errors:
5197 * SUCCESS
5198 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08005199 * NO_MEMORY
5200 * REQUEST_RATE_LIMITED
5201 * SYSTEM_ERR
5202 * INTERNAL_ERR
5203 * MODEM_ERR
5204 * INVALID_ARGUMENTS
5205 * INVALID_MODEM_STATE
5206 * NOT_PROVISIONED
sqiana216ed42017-06-20 11:54:31 -07005207 * NO_RESOURCES
5208 * CANCELLED
5209 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005210 * SIM_ABSENT
jsh000a9fe2009-05-11 14:52:35 -07005211 *
5212 */
5213#define RIL_REQUEST_GET_SMSC_ADDRESS 100
5214
5215/**
5216 * RIL_REQUEST_SET_SMSC_ADDRESS
5217 *
5218 * Sets the default Short Message Service Center address on the device.
5219 *
5220 * "data" is const char * containing the SMSC address.
5221 *
5222 * "response" is NULL
5223 *
5224 * Valid errors:
5225 * SUCCESS
5226 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08005227 * INVALID_ARGUMENTS
5228 * INVALID_SMS_FORMAT
5229 * NO_MEMORY
5230 * SYSTEM_ERR
5231 * REQUEST_RATE_LIMITED
5232 * MODEM_ERR
5233 * NO_RESOURCES
sqiana216ed42017-06-20 11:54:31 -07005234 * INTERNAL_ERR
5235 * CANCELLED
5236 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005237 * SIM_ABSENT
jsh000a9fe2009-05-11 14:52:35 -07005238 */
5239#define RIL_REQUEST_SET_SMSC_ADDRESS 101
5240
jshb60444e2009-05-29 11:09:17 -07005241/**
5242 * RIL_REQUEST_REPORT_SMS_MEMORY_STATUS
5243 *
5244 * Indicates whether there is storage available for new SMS messages.
5245 *
5246 * "data" is int *
5247 * ((int *)data)[0] is 1 if memory is available for storing new messages
5248 * is 0 if memory capacity is exceeded
5249 *
5250 * "response" is NULL
5251 *
5252 * Valid errors:
5253 * SUCCESS
5254 * RADIO_NOT_AVAILABLE
Ajay Nambi68900f52016-03-11 12:02:55 -08005255 * INVALID_ARGUMENTS
5256 * NO_MEMORY
5257 * INVALID_STATE
5258 * SYSTEM_ERR
5259 * REQUEST_RATE_LIMITED
5260 * MODEM_ERR
sqiana216ed42017-06-20 11:54:31 -07005261 * INTERNAL_ERR
5262 * NO_RESOURCES
5263 * CANCELLED
5264 * REQUEST_NOT_SUPPORTED
jshb60444e2009-05-29 11:09:17 -07005265 *
5266 */
5267#define RIL_REQUEST_REPORT_SMS_MEMORY_STATUS 102
5268
Wink Saville2641d5b2009-06-08 17:40:42 -07005269/**
5270 * RIL_REQUEST_REPORT_STK_SERVICE_IS_RUNNING
5271 *
5272 * Indicates that the StkSerivce is running and is
5273 * ready to receive RIL_UNSOL_STK_XXXXX commands.
5274 *
5275 * "data" is NULL
5276 * "response" is NULL
5277 *
5278 * Valid errors:
5279 * SUCCESS
5280 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005281 * INTERNAL_ERR
5282 * NO_MEMORY
5283 * NO_RESOURCES
5284 * CANCELLED
5285 * REQUEST_NOT_SUPPORTED
Wink Saville2641d5b2009-06-08 17:40:42 -07005286 *
5287 */
5288#define RIL_REQUEST_REPORT_STK_SERVICE_IS_RUNNING 103
5289
Wink Savillec0114b32011-02-18 10:14:07 -08005290/**
5291 * RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE
5292 *
5293 * Request to query the location where the CDMA subscription shall
5294 * be retrieved
5295 *
5296 * "data" is NULL
5297 *
5298 * "response" is int *
5299 * ((int *)data)[0] is == RIL_CdmaSubscriptionSource
5300 *
5301 * Valid errors:
5302 * SUCCESS
5303 * RADIO_NOT_AVAILABLE
Wink Savillec0114b32011-02-18 10:14:07 -08005304 * SUBSCRIPTION_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005305 * INTERNAL_ERR
5306 * NO_MEMORY
5307 * NO_RESOURCES
5308 * CANCELLED
5309 * REQUEST_NOT_SUPPORTED
Wink Savillec0114b32011-02-18 10:14:07 -08005310 *
5311 * See also: RIL_REQUEST_CDMA_SET_SUBSCRIPTION_SOURCE
5312 */
5313#define RIL_REQUEST_CDMA_GET_SUBSCRIPTION_SOURCE 104
5314
Jake Hambyfa8d5842011-08-19 16:22:18 -07005315/**
5316 * RIL_REQUEST_ISIM_AUTHENTICATION
5317 *
5318 * Request the ISIM application on the UICC to perform AKA
5319 * challenge/response algorithm for IMS authentication
5320 *
5321 * "data" is a const char * containing the challenge string in Base64 format
5322 * "response" is a const char * containing the response in Base64 format
5323 *
5324 * Valid errors:
5325 * SUCCESS
5326 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005327 * INTERNAL_ERR
5328 * NO_MEMORY
5329 * NO_RESOURCES
5330 * CANCELLED
5331 * REQUEST_NOT_SUPPORTED
Jake Hambyfa8d5842011-08-19 16:22:18 -07005332 */
5333#define RIL_REQUEST_ISIM_AUTHENTICATION 105
5334
Jake Hamby300105d2011-09-26 01:01:44 -07005335/**
5336 * RIL_REQUEST_ACKNOWLEDGE_INCOMING_GSM_SMS_WITH_PDU
5337 *
5338 * Acknowledge successful or failed receipt of SMS previously indicated
5339 * via RIL_UNSOL_RESPONSE_NEW_SMS, including acknowledgement TPDU to send
5340 * as the RP-User-Data element of the RP-ACK or RP-ERROR PDU.
5341 *
5342 * "data" is const char **
5343 * ((const char **)data)[0] is "1" on successful receipt (send RP-ACK)
5344 * is "0" on failed receipt (send RP-ERROR)
5345 * ((const char **)data)[1] is the acknowledgement TPDU in hexadecimal format
5346 *
5347 * "response" is NULL
5348 *
5349 * Valid errors:
5350 * SUCCESS
5351 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005352 * INTERNAL_ERR
5353 * NO_MEMORY
5354 * NO_RESOURCES
5355 * CANCELLED
5356 * REQUEST_NOT_SUPPORTED
Jake Hamby300105d2011-09-26 01:01:44 -07005357 */
5358#define RIL_REQUEST_ACKNOWLEDGE_INCOMING_GSM_SMS_WITH_PDU 106
5359
5360/**
5361 * RIL_REQUEST_STK_SEND_ENVELOPE_WITH_STATUS
5362 *
5363 * Requests to send a SAT/USAT envelope command to SIM.
5364 * The SAT/USAT envelope command refers to 3GPP TS 11.14 and 3GPP TS 31.111.
5365 *
5366 * This request has one difference from RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND:
5367 * the SW1 and SW2 status bytes from the UICC response are returned along with
5368 * the response data, using the same structure as RIL_REQUEST_SIM_IO.
5369 *
5370 * The RIL implementation shall perform the normal processing of a '91XX'
5371 * response in SW1/SW2 to retrieve the pending proactive command and send it
5372 * as an unsolicited response, as RIL_REQUEST_STK_SEND_ENVELOPE_COMMAND does.
5373 *
5374 * "data" is a const char * containing the SAT/USAT command
5375 * in hexadecimal format starting with command tag
5376 *
5377 * "response" is a const RIL_SIM_IO_Response *
5378 *
5379 * Valid errors:
5380 * RIL_E_SUCCESS
5381 * RIL_E_RADIO_NOT_AVAILABLE (radio resetting)
twen.changdf7add02016-03-04 18:27:48 +08005382 * SIM_BUSY
5383 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07005384 * INTERNAL_ERR
5385 * NO_MEMORY
5386 * NO_RESOURCES
5387 * CANCELLED
5388 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005389 * SIM_ABSENT
Jake Hamby300105d2011-09-26 01:01:44 -07005390 */
5391#define RIL_REQUEST_STK_SEND_ENVELOPE_WITH_STATUS 107
5392
Naveen Kalla2bc78d62011-12-07 16:22:53 -08005393/**
5394 * RIL_REQUEST_VOICE_RADIO_TECH
5395 *
5396 * Query the radio technology type (3GPP/3GPP2) used for voice. Query is valid only
Sooraj Sasindranb80acba2015-10-08 16:03:16 -07005397 * when radio state is not RADIO_STATE_UNAVAILABLE
Naveen Kalla2bc78d62011-12-07 16:22:53 -08005398 *
5399 * "data" is NULL
5400 * "response" is int *
5401 * ((int *) response)[0] is of type const RIL_RadioTechnology
5402 *
5403 * Valid errors:
5404 * SUCCESS
5405 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005406 * INTERNAL_ERR
5407 * NO_MEMORY
5408 * NO_RESOURCES
5409 * CANCELLED
5410 * REQUEST_NOT_SUPPORTED
Naveen Kalla2bc78d62011-12-07 16:22:53 -08005411 */
5412#define RIL_REQUEST_VOICE_RADIO_TECH 108
5413
Wink Saville8a9e0212013-04-09 12:11:38 -07005414/**
5415 * RIL_REQUEST_GET_CELL_INFO_LIST
5416 *
5417 * Request all of the current cell information known to the radio. The radio
5418 * must a list of all current cells, including the neighboring cells. If for a particular
5419 * cell information isn't known then the appropriate unknown value will be returned.
5420 * This does not cause or change the rate of RIL_UNSOL_CELL_INFO_LIST.
5421 *
5422 * "data" is NULL
5423 *
Sanket Padawef53c5fa2016-01-27 10:00:38 -08005424 * "response" is an array of RIL_CellInfo_v12.
Naina Nalluri67728582017-05-04 17:40:04 -07005425 *
5426 * Valid errors:
5427 * SUCCESS
5428 * RADIO_NOT_AVAILABLE
5429 * NO_MEMORY
5430 * INTERNAL_ERR
5431 * SYSTEM_ERR
5432 * MODEM_ERR
5433 * NO_NETWORK_FOUND
5434 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005435 * NO_RESOURCES
5436 * CANCELLED
Naina Nalluri67728582017-05-04 17:40:04 -07005437 *
Wink Saville8a9e0212013-04-09 12:11:38 -07005438 */
5439#define RIL_REQUEST_GET_CELL_INFO_LIST 109
5440
5441/**
5442 * RIL_REQUEST_SET_UNSOL_CELL_INFO_LIST_RATE
5443 *
5444 * Sets the minimum time between when RIL_UNSOL_CELL_INFO_LIST should be invoked.
Wink Savillec57b3eb2013-04-17 12:51:41 -07005445 * A value of 0, means invoke RIL_UNSOL_CELL_INFO_LIST when any of the reported
Wink Saville8a9e0212013-04-09 12:11:38 -07005446 * information changes. Setting the value to INT_MAX(0x7fffffff) means never issue
5447 * a RIL_UNSOL_CELL_INFO_LIST.
5448 *
5449 * "data" is int *
5450 * ((int *)data)[0] is minimum time in milliseconds
5451 *
5452 * "response" is NULL
5453 *
5454 * Valid errors:
5455 * SUCCESS
5456 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07005457 * NO_MEMORY
5458 * INTERNAL_ERR
5459 * SYSTEM_ERR
5460 * INVALID_ARGUMENTS
5461 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005462 * NO_RESOURCES
5463 * CANCELLED
Wink Saville8a9e0212013-04-09 12:11:38 -07005464 */
5465#define RIL_REQUEST_SET_UNSOL_CELL_INFO_LIST_RATE 110
Jake Hamby300105d2011-09-26 01:01:44 -07005466
Sungmin Choi75697532013-04-26 15:04:45 -07005467/**
5468 * RIL_REQUEST_SET_INITIAL_ATTACH_APN
5469 *
5470 * Set an apn to initial attach network
Ankit Nbc37e512016-12-07 21:05:43 +05305471 *
5472 * "data" is a const char **
5473 * ((const char **)data)[0] is the APN to connect if radio technology is LTE
5474 * ((const char **)data)[1] is the connection type to request must be one of the
5475 * PDP_type values in TS 27.007 section 10.1.1.
5476 * For example, "IP", "IPV6", "IPV4V6", or "PPP".
5477 * ((const char **)data)[2] is the PAP / CHAP auth type. Values:
5478 * 0 => PAP and CHAP is never performed.
5479 * 1 => PAP may be performed; CHAP is never performed.
5480 * 2 => CHAP may be performed; PAP is never performed.
5481 * 3 => PAP / CHAP may be performed - baseband dependent.
5482 * ((const char **)data)[3] is the username for APN, or NULL
5483 * ((const char **)data)[4] is the password for APN, or NULL
5484 *
Sungmin Choi75697532013-04-26 15:04:45 -07005485 * "response" is NULL
5486 *
5487 * Valid errors:
5488 * SUCCESS
5489 * RADIO_NOT_AVAILABLE (radio resetting)
Sungmin Choi75697532013-04-26 15:04:45 -07005490 * SUBSCRIPTION_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07005491 * NO_MEMORY
5492 * INTERNAL_ERR
5493 * SYSTEM_ERR
5494 * INVALID_ARGUMENTS
5495 * MODEM_ERR
5496 * NOT_PROVISIONED
5497 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005498 * NO_RESOURCES
5499 * CANCELLED
Naina Nalluri67728582017-05-04 17:40:04 -07005500 *
Sungmin Choi75697532013-04-26 15:04:45 -07005501 */
5502#define RIL_REQUEST_SET_INITIAL_ATTACH_APN 111
5503
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005504/**
5505 * RIL_REQUEST_IMS_REGISTRATION_STATE
5506 *
Nathan Harold0eb43c22016-12-19 12:04:32 -08005507 * This message is DEPRECATED and shall be removed in a future release (target: 2018);
5508 * instead, provide IMS registration status via an IMS Service.
5509 *
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005510 * Request current IMS registration state
5511 *
5512 * "data" is NULL
5513 *
5514 * "response" is int *
5515 * ((int *)response)[0] is registration state:
5516 * 0 - Not registered
5517 * 1 - Registered
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005518 *
Wink Saville865ce3b2013-11-08 16:37:01 -08005519 * If ((int*)response)[0] is = 1, then ((int *) response)[1]
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005520 * must follow with IMS SMS format:
5521 *
Wink Saville865ce3b2013-11-08 16:37:01 -08005522 * ((int *) response)[1] is of type RIL_RadioTechnologyFamily
5523 *
5524 * Valid errors:
5525 * SUCCESS
5526 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005527 * INTERNAL_ERR
5528 * NO_MEMORY
5529 * NO_RESOURCES
5530 * CANCELLED
5531 * INVALID_MODEM_STATE
5532 * REQUEST_NOT_SUPPORTED
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005533 */
5534#define RIL_REQUEST_IMS_REGISTRATION_STATE 112
5535
5536/**
5537 * RIL_REQUEST_IMS_SEND_SMS
5538 *
5539 * Send a SMS message over IMS
5540 *
5541 * "data" is const RIL_IMS_SMS_Message *
5542 *
5543 * "response" is a const RIL_SMS_Response *
5544 *
5545 * Based on the return error, caller decides to resend if sending sms
5546 * fails. SMS_SEND_FAIL_RETRY means retry, and other errors means no retry.
5547 * In case of retry, data is encoded based on Voice Technology available.
5548 *
5549 * Valid errors:
5550 * SUCCESS
5551 * RADIO_NOT_AVAILABLE
5552 * SMS_SEND_FAIL_RETRY
5553 * FDN_CHECK_FAILURE
twen.changdf7add02016-03-04 18:27:48 +08005554 * NETWORK_REJECT
Ajay Nambi68900f52016-03-11 12:02:55 -08005555 * INVALID_ARGUMENTS
5556 * INVALID_STATE
5557 * NO_MEMORY
5558 * INVALID_SMS_FORMAT
5559 * SYSTEM_ERR
5560 * REQUEST_RATE_LIMITED
5561 * MODEM_ERR
5562 * NETWORK_ERR
5563 * ENCODING_ERR
5564 * INVALID_SMSC_ADDRESS
Naina Nalluri1d3f4482017-07-17 11:44:37 -07005565 * OPERATION_NOT_ALLOWED
sqiana216ed42017-06-20 11:54:31 -07005566 * INTERNAL_ERR
5567 * NO_RESOURCES
5568 * CANCELLED
5569 * REQUEST_NOT_SUPPORTED
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07005570 *
5571 */
5572#define RIL_REQUEST_IMS_SEND_SMS 113
5573
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005574/**
5575 * RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC
5576 *
5577 * Request APDU exchange on the basic channel. This command reflects TS 27.007
5578 * "generic SIM access" operation (+CSIM). The modem must ensure proper function
5579 * of GSM/CDMA, and filter commands appropriately. It should filter
5580 * channel management and SELECT by DF name commands.
5581 *
5582 * "data" is a const RIL_SIM_APDU *
5583 * "sessionid" field should be ignored.
5584 *
5585 * "response" is a const RIL_SIM_IO_Response *
5586 *
5587 * Valid errors:
5588 * SUCCESS
5589 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005590 * INTERNAL_ERR
5591 * NO_MEMORY
5592 * NO_RESOURCES
5593 * CANCELLED
5594 * REQUEST_NOT_SUPPORTED
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005595 */
5596#define RIL_REQUEST_SIM_TRANSMIT_APDU_BASIC 114
5597
5598/**
5599 * RIL_REQUEST_SIM_OPEN_CHANNEL
5600 *
5601 * Open a new logical channel and select the given application. This command
Wileen Chiud6222e02015-11-23 14:25:22 -08005602 * reflects TS 27.007 "open logical channel" operation (+CCHO). This request
5603 * also specifies the P2 parameter (described in ISO 7816-4).
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005604 *
Wileen Chiud6222e02015-11-23 14:25:22 -08005605 * "data" is a const RIL_OpenChannelParam *
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005606 *
5607 * "response" is int *
5608 * ((int *)data)[0] contains the session id of the logical channel.
Shishir Agrawal760123f2014-10-14 09:14:57 -07005609 * ((int *)data)[1] onwards may optionally contain the select response for the
5610 * open channel command with one byte per integer.
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005611 *
5612 * Valid errors:
5613 * SUCCESS
5614 * RADIO_NOT_AVAILABLE
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005615 * MISSING_RESOURCE
5616 * NO_SUCH_ELEMENT
sqiana216ed42017-06-20 11:54:31 -07005617 * INTERNAL_ERR
5618 * NO_MEMORY
5619 * NO_RESOURCES
5620 * CANCELLED
5621 * SIM_ERR
5622 * INVALID_SIM_STATE
5623 * MISSING_RESOURCE
5624 * REQUEST_NOT_SUPPORTED
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005625 */
5626#define RIL_REQUEST_SIM_OPEN_CHANNEL 115
5627
5628/**
5629 * RIL_REQUEST_SIM_CLOSE_CHANNEL
5630 *
5631 * Close a previously opened logical channel. This command reflects TS 27.007
5632 * "close logical channel" operation (+CCHC).
5633 *
5634 * "data" is int *
5635 * ((int *)data)[0] is the session id of logical the channel to close.
5636 *
5637 * "response" is NULL
5638 *
5639 * Valid errors:
5640 * SUCCESS
5641 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005642 * INTERNAL_ERR
5643 * NO_MEMORY
5644 * NO_RESOURCES
5645 * CANCELLED
5646 * REQUEST_NOT_SUPPORTED
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005647 */
5648#define RIL_REQUEST_SIM_CLOSE_CHANNEL 116
5649
5650/**
5651 * RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL
5652 *
5653 * Exchange APDUs with a UICC over a previously opened logical channel. This
5654 * command reflects TS 27.007 "generic logical channel access" operation
5655 * (+CGLA). The modem should filter channel management and SELECT by DF name
5656 * commands.
5657 *
5658 * "data" is a const RIL_SIM_APDU*
5659 *
5660 * "response" is a const RIL_SIM_IO_Response *
5661 *
5662 * Valid errors:
5663 * SUCCESS
5664 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005665 * INTERNAL_ERR
5666 * NO_MEMORY
5667 * NO_RESOURCES
5668 * CANCELLED
5669 * REQUEST_NOT_SUPPORTED
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005670 */
5671#define RIL_REQUEST_SIM_TRANSMIT_APDU_CHANNEL 117
5672
Jake Hamby8a4a2332014-01-15 13:12:05 -08005673/**
5674 * RIL_REQUEST_NV_READ_ITEM
5675 *
5676 * Read one of the radio NV items defined in RadioNVItems.java / ril_nv_items.h.
5677 * This is used for device configuration by some CDMA operators.
5678 *
5679 * "data" is a const RIL_NV_ReadItem *
5680 *
5681 * "response" is const char * containing the contents of the NV item
5682 *
5683 * Valid errors:
5684 * SUCCESS
5685 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005686 * REQUEST_NOT_SUPPORTED
Jake Hamby8a4a2332014-01-15 13:12:05 -08005687 */
5688#define RIL_REQUEST_NV_READ_ITEM 118
5689
5690/**
5691 * RIL_REQUEST_NV_WRITE_ITEM
5692 *
5693 * Write one of the radio NV items defined in RadioNVItems.java / ril_nv_items.h.
5694 * This is used for device configuration by some CDMA operators.
5695 *
5696 * "data" is a const RIL_NV_WriteItem *
5697 *
5698 * "response" is NULL
5699 *
5700 * Valid errors:
5701 * SUCCESS
5702 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005703 * REQUEST_NOT_SUPPORTED
Jake Hamby8a4a2332014-01-15 13:12:05 -08005704 */
5705#define RIL_REQUEST_NV_WRITE_ITEM 119
5706
5707/**
5708 * RIL_REQUEST_NV_WRITE_CDMA_PRL
5709 *
5710 * Update the CDMA Preferred Roaming List (PRL) in the radio NV storage.
5711 * This is used for device configuration by some CDMA operators.
5712 *
5713 * "data" is a const char * containing the PRL as a byte array
5714 *
5715 * "response" is NULL
5716 *
5717 * Valid errors:
5718 * SUCCESS
5719 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005720 * REQUEST_NOT_SUPPORTED
Jake Hamby8a4a2332014-01-15 13:12:05 -08005721 */
5722#define RIL_REQUEST_NV_WRITE_CDMA_PRL 120
5723
5724/**
5725 * RIL_REQUEST_NV_RESET_CONFIG
5726 *
5727 * Reset the radio NV configuration to the factory state.
5728 * This is used for device configuration by some CDMA operators.
5729 *
5730 * "data" is int *
Jake Hambyd27c9d52014-02-06 14:52:05 -08005731 * ((int *)data)[0] is 1 to reload all NV items
5732 * ((int *)data)[0] is 2 for erase NV reset (SCRTN)
5733 * ((int *)data)[0] is 3 for factory reset (RTN)
Jake Hamby8a4a2332014-01-15 13:12:05 -08005734 *
5735 * "response" is NULL
5736 *
5737 * Valid errors:
5738 * SUCCESS
5739 * RADIO_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005740 * REQUEST_NOT_SUPPORTED
Jake Hamby8a4a2332014-01-15 13:12:05 -08005741 */
5742#define RIL_REQUEST_NV_RESET_CONFIG 121
5743
Etan Cohend3652192014-06-20 08:28:44 -07005744 /** RIL_REQUEST_SET_UICC_SUBSCRIPTION
5745 * FIXME This API needs to have more documentation.
5746 *
5747 * Selection/de-selection of a subscription from a SIM card
5748 * "data" is const RIL_SelectUiccSub*
5749
5750 *
5751 * "response" is NULL
5752 *
5753 * Valid errors:
5754 * SUCCESS
5755 * RADIO_NOT_AVAILABLE (radio resetting)
Etan Cohend3652192014-06-20 08:28:44 -07005756 * SUBSCRIPTION_NOT_SUPPORTED
Naina Nalluri67728582017-05-04 17:40:04 -07005757 * NO_MEMORY
5758 * INTERNAL_ERR
5759 * SYSTEM_ERR
5760 * INVALID_ARGUMENTS
5761 * MODEM_ERR
5762 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005763 * NO_RESOURCES
5764 * CANCELLED
Etan Cohend3652192014-06-20 08:28:44 -07005765 *
5766 */
5767#define RIL_REQUEST_SET_UICC_SUBSCRIPTION 122
5768
5769/**
5770 * RIL_REQUEST_ALLOW_DATA
5771 *
5772 * Tells the modem whether data calls are allowed or not
5773 *
5774 * "data" is int *
5775 * FIXME slotId and aid will be added.
5776 * ((int *)data)[0] is == 0 to allow data calls
5777 * ((int *)data)[0] is == 1 to disallow data calls
5778 *
5779 * "response" is NULL
5780 *
5781 * Valid errors:
5782 *
5783 * SUCCESS
5784 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07005785 * NO_MEMORY
5786 * INTERNAL_ERR
5787 * SYSTEM_ERR
5788 * MODEM_ERR
5789 * INVALID_ARGUMENTS
5790 * DEVICE_IN_USE
5791 * INVALID_MODEM_STATE
5792 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005793 * NO_RESOURCES
5794 * CANCELLED
Etan Cohend3652192014-06-20 08:28:44 -07005795 *
5796 */
5797#define RIL_REQUEST_ALLOW_DATA 123
5798
5799/**
5800 * RIL_REQUEST_GET_HARDWARE_CONFIG
5801 *
5802 * Request all of the current hardware (modem and sim) associated
5803 * with the RIL.
5804 *
5805 * "data" is NULL
5806 *
5807 * "response" is an array of RIL_HardwareConfig.
sqiana216ed42017-06-20 11:54:31 -07005808 *
5809 * Valid errors:
5810 * RADIO_NOT_AVAILABLE
5811 * REQUEST_NOT_SUPPORTED
Etan Cohend3652192014-06-20 08:28:44 -07005812 */
5813#define RIL_REQUEST_GET_HARDWARE_CONFIG 124
5814
5815/**
Amit Mahajan2b772032014-06-26 14:20:11 -07005816 * RIL_REQUEST_SIM_AUTHENTICATION
Etan Cohend3652192014-06-20 08:28:44 -07005817 *
5818 * Returns the response of SIM Authentication through RIL to a
5819 * challenge request.
5820 *
5821 * "data" Base64 encoded string containing challenge:
5822 * int authContext; P2 value of authentication command, see P2 parameter in
5823 * 3GPP TS 31.102 7.1.2
5824 * char *authData; the challenge string in Base64 format, see 3GPP
5825 * TS 31.102 7.1.2
5826 * char *aid; AID value, See ETSI 102.221 8.1 and 101.220 4,
5827 * NULL if no value
5828 *
5829 * "response" Base64 encoded strings containing response:
5830 * int sw1; Status bytes per 3GPP TS 31.102 section 7.3
5831 * int sw2;
5832 * char *simResponse; Response in Base64 format, see 3GPP TS 31.102 7.1.2
sqiana216ed42017-06-20 11:54:31 -07005833 *
5834 * Valid errors:
5835 * RADIO_NOT_AVAILABLE
5836 * INTERNAL_ERR
5837 * NO_MEMORY
5838 * NO_RESOURCES
5839 * CANCELLED
5840 * INVALID_MODEM_STATE
5841 * INVALID_ARGUMENTS
5842 * SIM_ERR
5843 * REQUEST_NOT_SUPPORTED
Etan Cohend3652192014-06-20 08:28:44 -07005844 */
Amit Mahajan2b772032014-06-26 14:20:11 -07005845#define RIL_REQUEST_SIM_AUTHENTICATION 125
Shishir Agrawal2458d8d2013-11-27 14:53:05 -08005846
Wink Savillec29360a2014-07-13 05:17:28 -07005847/**
5848 * RIL_REQUEST_GET_DC_RT_INFO
5849 *
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07005850 * The request is DEPRECATED, use RIL_REQUEST_GET_ACTIVITY_INFO
Wink Savillec29360a2014-07-13 05:17:28 -07005851 * Requests the Data Connection Real Time Info
5852 *
5853 * "data" is NULL
5854 *
5855 * "response" is the most recent RIL_DcRtInfo
5856 *
5857 * Valid errors:
5858 * SUCCESS
5859 * RADIO_NOT_AVAILABLE
Naina Nalluri67728582017-05-04 17:40:04 -07005860 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005861 * INTERNAL_ERR
5862 * NO_MEMORY
5863 * NO_RESOURCES
5864 * CANCELLED
Wink Savillec29360a2014-07-13 05:17:28 -07005865 *
5866 * See also: RIL_UNSOL_DC_RT_INFO_CHANGED
5867 */
5868#define RIL_REQUEST_GET_DC_RT_INFO 126
5869
5870/**
5871 * RIL_REQUEST_SET_DC_RT_INFO_RATE
5872 *
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07005873 * The request is DEPRECATED
Wink Savillec29360a2014-07-13 05:17:28 -07005874 * This is the minimum number of milliseconds between successive
5875 * RIL_UNSOL_DC_RT_INFO_CHANGED messages and defines the highest rate
5876 * at which RIL_UNSOL_DC_RT_INFO_CHANGED's will be sent. A value of
5877 * 0 means send as fast as possible.
5878 *
5879 * "data" The number of milliseconds as an int
5880 *
5881 * "response" is null
5882 *
5883 * Valid errors:
5884 * SUCCESS must not fail
5885 */
5886#define RIL_REQUEST_SET_DC_RT_INFO_RATE 127
5887
Amit Mahajanc796e222014-08-13 16:54:01 +00005888/**
5889 * RIL_REQUEST_SET_DATA_PROFILE
5890 *
5891 * Set data profile in modem
Hui Wang8d679622014-10-16 14:59:27 -05005892 * Modem should erase existed profiles from framework, and apply new profiles
Jack Yude8c8552017-01-24 12:03:52 -08005893 * "data" is a const RIL_DataProfileInfo **
Amit Mahajanc796e222014-08-13 16:54:01 +00005894 * "datalen" is count * sizeof(const RIL_DataProfileInfo *)
5895 * "response" is NULL
5896 *
5897 * Valid errors:
5898 * SUCCESS
5899 * RADIO_NOT_AVAILABLE (radio resetting)
Amit Mahajanc796e222014-08-13 16:54:01 +00005900 * SUBSCRIPTION_NOT_AVAILABLE
sqiana216ed42017-06-20 11:54:31 -07005901 * INTERNAL_ERR
5902 * NO_MEMORY
5903 * NO_RESOURCES
5904 * CANCELLED
5905 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08005906 * SIM_ABSENT
Amit Mahajanc796e222014-08-13 16:54:01 +00005907 */
5908#define RIL_REQUEST_SET_DATA_PROFILE 128
Naveen Kallaa65a16a2014-07-31 16:48:31 -07005909
5910/**
5911 * RIL_REQUEST_SHUTDOWN
5912 *
5913 * Device is shutting down. All further commands are ignored
5914 * and RADIO_NOT_AVAILABLE must be returned.
5915 *
5916 * "data" is null
5917 * "response" is NULL
5918 *
5919 * Valid errors:
5920 * SUCCESS
5921 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08005922 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07005923 * NO_MEMORY
5924 * INTERNAL_ERR
5925 * SYSTEM_ERR
5926 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005927 * NO_RESOURCES
5928 * CANCELLED
Naveen Kallaa65a16a2014-07-31 16:48:31 -07005929 */
5930#define RIL_REQUEST_SHUTDOWN 129
5931
Wink Saville8b4e4f72014-10-17 15:01:45 -07005932/**
5933 * RIL_REQUEST_GET_RADIO_CAPABILITY
5934 *
5935 * Used to get phone radio capablility.
5936 *
Abhishek Adappa772c0d22015-02-09 11:11:12 -08005937 * "data" is the RIL_RadioCapability structure
Wink Saville8b4e4f72014-10-17 15:01:45 -07005938 *
5939 * Valid errors:
5940 * SUCCESS
5941 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08005942 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07005943 * INVALID_STATE
5944 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005945 * INTERNAL_ERR
5946 * NO_MEMORY
5947 * NO_RESOURCES
5948 * CANCELLED
Wink Saville8b4e4f72014-10-17 15:01:45 -07005949 */
5950#define RIL_REQUEST_GET_RADIO_CAPABILITY 130
5951
5952/**
5953 * RIL_REQUEST_SET_RADIO_CAPABILITY
5954 *
5955 * Used to set the phones radio capability. Be VERY careful
5956 * using this request as it may cause some vendor modems to reset. Because
5957 * of the possible modem reset any RIL commands after this one may not be
5958 * processed.
5959 *
5960 * "data" is the RIL_RadioCapability structure
5961 *
5962 * "response" is the RIL_RadioCapability structure, used to feedback return status
5963 *
5964 * Valid errors:
5965 * SUCCESS means a RIL_UNSOL_RADIO_CAPABILITY will be sent within 30 seconds.
5966 * RADIO_NOT_AVAILABLE
twen.changdf7add02016-03-04 18:27:48 +08005967 * OPERATION_NOT_ALLOWED
Naina Nalluri67728582017-05-04 17:40:04 -07005968 * NO_MEMORY
5969 * INTERNAL_ERR
5970 * SYSTEM_ERR
5971 * INVALID_ARGUMENTS
5972 * MODEM_ERR
5973 * INVALID_STATE
5974 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005975 * NO_RESOURCES
5976 * CANCELLED
Wink Saville8b4e4f72014-10-17 15:01:45 -07005977 */
5978#define RIL_REQUEST_SET_RADIO_CAPABILITY 131
5979
fengluf7408292015-04-14 14:53:55 -07005980/**
5981 * RIL_REQUEST_START_LCE
5982 *
5983 * Start Link Capacity Estimate (LCE) service if supported by the radio.
5984 *
5985 * "data" is const int *
5986 * ((const int*)data)[0] specifies the desired reporting interval (ms).
fenglu290add32015-05-01 17:05:15 -07005987 * ((const int*)data)[1] specifies the LCE service mode. 1: PULL; 0: PUSH.
fengluf7408292015-04-14 14:53:55 -07005988 *
fenglu290add32015-05-01 17:05:15 -07005989 * "response" is the RIL_LceStatusInfo.
fengluf7408292015-04-14 14:53:55 -07005990 *
5991 * Valid errors:
5992 * SUCCESS
5993 * RADIO_NOT_AVAILABLE
5994 * LCE_NOT_SUPPORTED
Naina Nalluri67728582017-05-04 17:40:04 -07005995 * INTERNAL_ERR
5996 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07005997 * NO_MEMORY
5998 * NO_RESOURCES
5999 * CANCELLED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08006000 * SIM_ABSENT
fengluf7408292015-04-14 14:53:55 -07006001 */
6002#define RIL_REQUEST_START_LCE 132
6003
6004/**
6005 * RIL_REQUEST_STOP_LCE
6006 *
6007 * Stop Link Capacity Estimate (LCE) service, the STOP operation should be
6008 * idempotent for the radio modem.
6009 *
fenglu290add32015-05-01 17:05:15 -07006010 * "response" is the RIL_LceStatusInfo.
fengluf7408292015-04-14 14:53:55 -07006011 *
6012 * Valid errors:
6013 * SUCCESS
6014 * RADIO_NOT_AVAILABLE
6015 * LCE_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006016 * INTERNAL_ERR
6017 * NO_MEMORY
6018 * NO_RESOURCES
6019 * CANCELLED
6020 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08006021 * SIM_ABSENT
fengluf7408292015-04-14 14:53:55 -07006022 */
6023#define RIL_REQUEST_STOP_LCE 133
6024
6025/**
6026 * RIL_REQUEST_PULL_LCEDATA
6027 *
6028 * Pull LCE service for capacity information.
6029 *
fenglu290add32015-05-01 17:05:15 -07006030 * "response" is the RIL_LceDataInfo.
fengluf7408292015-04-14 14:53:55 -07006031 *
6032 * Valid errors:
6033 * SUCCESS
6034 * RADIO_NOT_AVAILABLE
6035 * LCE_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006036 * INTERNAL_ERR
6037 * NO_MEMORY
6038 * NO_RESOURCES
6039 * CANCELLED
6040 * REQUEST_NOT_SUPPORTED
Henry (Hung-Wen) Tung807fb292017-07-14 23:51:47 +08006041 * SIM_ABSENT
fengluf7408292015-04-14 14:53:55 -07006042 */
6043#define RIL_REQUEST_PULL_LCEDATA 134
6044
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07006045/**
6046 * RIL_REQUEST_GET_ACTIVITY_INFO
6047 *
Nathan Haroldc8635212016-10-10 11:15:21 -07006048 * Get modem activity information for power consumption estimation.
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07006049 *
Nathan Haroldc8635212016-10-10 11:15:21 -07006050 * Request clear-on-read statistics information that is used for
6051 * estimating the per-millisecond power consumption of the cellular
6052 * modem.
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07006053 *
6054 * "data" is null
6055 * "response" is const RIL_ActivityStatsInfo *
6056 *
6057 * Valid errors:
6058 *
6059 * SUCCESS
6060 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07006061 * NO_MEMORY
6062 * INTERNAL_ERR
6063 * SYSTEM_ERR
6064 * MODEM_ERR
6065 * NOT_PROVISIONED
6066 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006067 * NO_RESOURCES CANCELLED
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07006068 */
6069#define RIL_REQUEST_GET_ACTIVITY_INFO 135
Naveen Kallaa65a16a2014-07-31 16:48:31 -07006070
Meng Wangb4e34312016-05-12 14:54:36 -07006071/**
6072 * RIL_REQUEST_SET_CARRIER_RESTRICTIONS
6073 *
Meng Wangd5c540f2016-07-15 15:41:19 -07006074 * Set carrier restrictions for this sim slot. Expected modem behavior:
6075 * If never receives this command
6076 * - Must allow all carriers
6077 * Receives this command with data being NULL
6078 * - Must allow all carriers. If a previously allowed SIM is present, modem must not reload
6079 * the SIM. If a previously disallowed SIM is present, reload the SIM and notify Android.
6080 * Receives this command with a list of carriers
6081 * - Only allow specified carriers, persist across power cycles and FDR. If a present SIM
6082 * is in the allowed list, modem must not reload the SIM. If a present SIM is *not* in
6083 * the allowed list, modem must detach from the registered network and only keep emergency
6084 * service, and notify Android SIM refresh reset with new SIM state being
6085 * RIL_CARDSTATE_RESTRICTED. Emergency service must be enabled.
Meng Wangb4e34312016-05-12 14:54:36 -07006086 *
6087 * "data" is const RIL_CarrierRestrictions *
6088 * A list of allowed carriers and possibly a list of excluded carriers.
6089 * If data is NULL, means to clear previous carrier restrictions and allow all carriers
6090 *
6091 * "response" is int *
6092 * ((int *)data)[0] contains the number of allowed carriers which have been set correctly.
6093 * On success, it should match the length of list data->allowed_carriers.
6094 * If data is NULL, the value must be 0.
6095 *
6096 * Valid errors:
6097 * RIL_E_SUCCESS
6098 * RIL_E_INVALID_ARGUMENTS
6099 * RIL_E_RADIO_NOT_AVAILABLE
6100 * RIL_E_REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006101 * INTERNAL_ERR
6102 * NO_MEMORY
6103 * NO_RESOURCES
6104 * CANCELLED
Meng Wangb4e34312016-05-12 14:54:36 -07006105 */
6106#define RIL_REQUEST_SET_CARRIER_RESTRICTIONS 136
6107
6108/**
6109 * RIL_REQUEST_GET_CARRIER_RESTRICTIONS
6110 *
Meng Wangd5c540f2016-07-15 15:41:19 -07006111 * Get carrier restrictions for this sim slot. Expected modem behavior:
6112 * Return list of allowed carriers, or null if all carriers are allowed.
Meng Wangb4e34312016-05-12 14:54:36 -07006113 *
6114 * "data" is NULL
6115 *
6116 * "response" is const RIL_CarrierRestrictions *.
6117 * If response is NULL, it means all carriers are allowed.
6118 *
6119 * Valid errors:
6120 * RIL_E_SUCCESS
6121 * RIL_E_RADIO_NOT_AVAILABLE
6122 * RIL_E_REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006123 * INTERNAL_ERR
6124 * NO_MEMORY
6125 * NO_RESOURCES
6126 * CANCELLED
Meng Wangb4e34312016-05-12 14:54:36 -07006127 */
6128#define RIL_REQUEST_GET_CARRIER_RESTRICTIONS 137
6129
Jack Yude8c8552017-01-24 12:03:52 -08006130/**
6131 * RIL_REQUEST_SEND_DEVICE_STATE
6132 *
6133 * Send the updated device state.
6134 * Modem can perform power saving based on the provided device state.
6135 * "data" is const int *
6136 * ((const int*)data)[0] A RIL_DeviceStateType that specifies the device state type.
6137 * ((const int*)data)[1] Specifies the state. See RIL_DeviceStateType for the definition of each
6138 * type.
6139 *
6140 * "datalen" is count * sizeof(const RIL_DeviceState *)
6141 * "response" is NULL
6142 *
6143 * Valid errors:
6144 * SUCCESS
6145 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07006146 * NO_MEMORY
6147 * INTERNAL_ERR
6148 * SYSTEM_ERR
6149 * INVALID_ARGUMENTS
6150 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006151 * NO_RESOURCES
6152 * CANCELLED
Jack Yude8c8552017-01-24 12:03:52 -08006153 */
6154#define RIL_REQUEST_SEND_DEVICE_STATE 138
6155
6156/**
6157 * RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER
6158 *
6159 * Set the unsolicited response filter
6160 * This is used to prevent unnecessary application processor
6161 * wake up for power saving purposes by suppressing the
6162 * unsolicited responses in certain scenarios.
6163 *
6164 * "data" is an int *
6165 *
6166 * ((int *)data)[0] is a 32-bit bitmask of RIL_UnsolicitedResponseFilter
6167 *
6168 * "response" is NULL
6169 *
6170 * Valid errors:
6171 * SUCCESS
6172 * INVALID_ARGUMENTS (e.g. the requested filter doesn't exist)
6173 * RADIO_NOT_AVAILABLE (radio resetting)
Naina Nalluri67728582017-05-04 17:40:04 -07006174 * NO_MEMORY
6175 * INTERNAL_ERR
6176 * SYSTEM_ERR
6177 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006178 * NO_RESOURCES
6179 * CANCELLED
Jack Yude8c8552017-01-24 12:03:52 -08006180 */
6181#define RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER 139
6182
Wileen Chiu35380a32017-01-04 11:37:19 -08006183 /**
6184 * RIL_REQUEST_SET_SIM_CARD_POWER
6185 *
6186 * Set SIM card power up or down
6187 *
6188 * Request is equivalent to inserting and removing the card, with
6189 * an additional effect where the ability to detect card removal/insertion
6190 * is disabled when the SIM card is powered down.
6191 *
6192 * This will generate RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED
6193 * as if the SIM had been inserted or removed.
6194 *
6195 * "data" is int *
6196 * ((int *)data)[0] is 1 for "SIM POWER UP"
6197 * ((int *)data)[0] is 0 for "SIM POWER DOWN"
6198 *
6199 * "response" is NULL
6200 *
6201 * Valid errors:
6202 * SUCCESS
6203 * RADIO_NOT_AVAILABLE
6204 * REQUEST_NOT_SUPPORTED
6205 * SIM_ABSENT
6206 * INVALID_ARGUMENTS
sqiana216ed42017-06-20 11:54:31 -07006207 * INTERNAL_ERR
6208 * NO_MEMORY
6209 * NO_RESOURCES
6210 * CANCELLED
Wileen Chiu35380a32017-01-04 11:37:19 -08006211 */
6212#define RIL_REQUEST_SET_SIM_CARD_POWER 140
pkanwarc61837e2017-03-17 12:49:34 -07006213
6214/**
6215 * RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION
6216 *
6217 * Provide Carrier specific information to the modem that will be used to
6218 * encrypt the IMSI and IMPI. Sent by the framework during boot, carrier
6219 * switch and everytime we receive a new certificate.
6220 *
6221 * "data" is the RIL_CarrierInfoForImsiEncryption * structure.
6222 *
6223 * "response" is NULL
6224 *
6225 * Valid errors:
6226 * RIL_E_SUCCESS
6227 * RIL_E_RADIO_NOT_AVAILABLE
6228 * SIM_ABSENT
6229 * RIL_E_REQUEST_NOT_SUPPORTED
6230 * INVALID_ARGUMENTS
6231 * MODEM_INTERNAL_FAILURE
sqiana216ed42017-06-20 11:54:31 -07006232 * INTERNAL_ERR
6233 * NO_MEMORY
6234 * NO_RESOURCES
6235 * CANCELLED
pkanwarc61837e2017-03-17 12:49:34 -07006236 */
6237#define RIL_REQUEST_SET_CARRIER_INFO_IMSI_ENCRYPTION 141
6238
yinxu7317bd42017-05-03 15:15:19 -07006239/**
6240 * RIL_REQUEST_START_NETWORK_SCAN
6241 *
6242 * Starts a new network scan
6243 *
6244 * Request to start a network scan with specified radio access networks with frequency bands and/or
6245 * channels.
6246 *
6247 * "data" is a const RIL_NetworkScanRequest *.
6248 * "response" is NULL
6249 *
6250 * Valid errors:
6251 * SUCCESS
6252 * RADIO_NOT_AVAILABLE
6253 * OPERATION_NOT_ALLOWED
6254 * DEVICE_IN_USE
6255 * INTERNAL_ERR
6256 * NO_MEMORY
6257 * MODEM_ERR
6258 * INVALID_ARGUMENTS
6259 * REQUEST_NOT_SUPPORTED
sqiana216ed42017-06-20 11:54:31 -07006260 * NO_RESOURCES
6261 * CANCELLED
yinxu7317bd42017-05-03 15:15:19 -07006262 *
6263 */
6264#define RIL_REQUEST_START_NETWORK_SCAN 142
6265
6266/**
6267 * RIL_REQUEST_STOP_NETWORK_SCAN
6268 *
6269 * Stops an ongoing network scan
6270 *
6271 * Request to stop the ongoing network scan. Since the modem can only perform one scan at a time,
6272 * there is no parameter for this request.
6273 *
6274 * "data" is NULL
6275 * "response" is NULL
6276 *
6277 * Valid errors:
6278 * SUCCESS
6279 * INTERNAL_ERR
6280 * MODEM_ERR
sqiana216ed42017-06-20 11:54:31 -07006281 * NO_MEMORY
6282 * NO_RESOURCES
6283 * CANCELLED
6284 * REQUEST_NOT_SUPPORTED
yinxu7317bd42017-05-03 15:15:19 -07006285 *
6286 */
6287#define RIL_REQUEST_STOP_NETWORK_SCAN 143
6288
Nathan Haroldec94b822017-05-25 16:10:35 -07006289/**
6290 * RIL_REQUEST_START_KEEPALIVE
6291 *
6292 * Start a keepalive session
6293 *
6294 * Request that the modem begin sending keepalive packets on a particular
6295 * data call, with a specified source, destination, and format.
6296 *
6297 * "data" is a const RIL_RequestKeepalive
6298 * "response" is RIL_KeepaliveStatus with a valid "handle"
6299 *
6300 * Valid errors:
6301 * SUCCESS
6302 * NO_RESOURCES
6303 * INVALID_ARGUMENTS
6304 *
6305 */
6306#define RIL_REQUEST_START_KEEPALIVE 144
6307
6308/**
6309 * RIL_REQUEST_STOP_KEEPALIVE
6310 *
6311 * Stops an ongoing keepalive session
6312 *
6313 * Requests that a keepalive session with the given handle be stopped.
6314 * there is no parameter for this request.
6315 *
6316 * "data" is an integer handle
6317 * "response" is NULL
6318 *
6319 * Valid errors:
6320 * SUCCESS
6321 * INVALID_ARGUMENTS
6322 *
6323 */
6324#define RIL_REQUEST_STOP_KEEPALIVE 145
6325
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006326/***********************************************************************/
6327
Sanket Padawe6ff9a872016-01-27 15:09:12 -08006328/**
6329 * RIL_RESPONSE_ACKNOWLEDGEMENT
6330 *
6331 * This is used by Asynchronous solicited messages and Unsolicited messages
6332 * to acknowledge the receipt of those messages in RIL.java so that the ack
6333 * can be used to let ril.cpp to release wakelock.
6334 *
6335 * Valid errors
6336 * SUCCESS
6337 * RADIO_NOT_AVAILABLE
6338 */
6339
6340#define RIL_RESPONSE_ACKNOWLEDGEMENT 800
6341
6342/***********************************************************************/
6343
Wink Savillef4c4d362009-04-02 01:37:03 -07006344
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006345#define RIL_UNSOL_RESPONSE_BASE 1000
6346
6347/**
6348 * RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED
6349 *
6350 * Indicate when value of RIL_RadioState has changed.
6351 *
6352 * Callee will invoke RIL_RadioStateRequest method on main thread
6353 *
6354 * "data" is NULL
6355 */
6356
6357#define RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED 1000
6358
6359
6360/**
6361 * RIL_UNSOL_RESPONSE_CALL_STATE_CHANGED
6362 *
6363 * Indicate when call state has changed
6364 *
6365 * Callee will invoke RIL_REQUEST_GET_CURRENT_CALLS on main thread
6366 *
6367 * "data" is NULL
6368 *
Wink Saville7f856802009-06-09 10:23:37 -07006369 * Response should be invoked on, for example,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006370 * "RING", "BUSY", "NO CARRIER", and also call state
6371 * transitions (DIALING->ALERTING ALERTING->ACTIVE)
6372 *
6373 * Redundent or extraneous invocations are tolerated
6374 */
6375#define RIL_UNSOL_RESPONSE_CALL_STATE_CHANGED 1001
6376
6377
6378/**
Wink Savillec0114b32011-02-18 10:14:07 -08006379 * RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006380 *
Wink Savillec0114b32011-02-18 10:14:07 -08006381 * Called when the voice network state changed
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006382 *
6383 * Callee will invoke the following requests on main thread:
6384 *
Wink Savillec0114b32011-02-18 10:14:07 -08006385 * RIL_REQUEST_VOICE_REGISTRATION_STATE
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006386 * RIL_REQUEST_OPERATOR
6387 *
6388 * "data" is NULL
6389 *
6390 * FIXME should this happen when SIM records are loaded? (eg, for
6391 * EONS)
6392 */
Wink Savillec0114b32011-02-18 10:14:07 -08006393#define RIL_UNSOL_RESPONSE_VOICE_NETWORK_STATE_CHANGED 1002
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006394
6395/**
6396 * RIL_UNSOL_RESPONSE_NEW_SMS
6397 *
6398 * Called when new SMS is received.
Wink Saville7f856802009-06-09 10:23:37 -07006399 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006400 * "data" is const char *
6401 * This is a pointer to a string containing the PDU of an SMS-DELIVER
6402 * as an ascii string of hex digits. The PDU starts with the SMSC address
6403 * per TS 27.005 (+CMT:)
6404 *
6405 * Callee will subsequently confirm the receipt of thei SMS with a
6406 * RIL_REQUEST_SMS_ACKNOWLEDGE
6407 *
Wink Saville7f856802009-06-09 10:23:37 -07006408 * No new RIL_UNSOL_RESPONSE_NEW_SMS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006409 * or RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT messages should be sent until a
6410 * RIL_REQUEST_SMS_ACKNOWLEDGE has been received
6411 */
6412
6413#define RIL_UNSOL_RESPONSE_NEW_SMS 1003
6414
6415/**
6416 * RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT
6417 *
6418 * Called when new SMS Status Report is received.
Wink Saville7f856802009-06-09 10:23:37 -07006419 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006420 * "data" is const char *
6421 * This is a pointer to a string containing the PDU of an SMS-STATUS-REPORT
6422 * as an ascii string of hex digits. The PDU starts with the SMSC address
6423 * per TS 27.005 (+CDS:).
6424 *
6425 * Callee will subsequently confirm the receipt of the SMS with a
6426 * RIL_REQUEST_SMS_ACKNOWLEDGE
6427 *
Wink Saville7f856802009-06-09 10:23:37 -07006428 * No new RIL_UNSOL_RESPONSE_NEW_SMS
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006429 * or RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT messages should be sent until a
6430 * RIL_REQUEST_SMS_ACKNOWLEDGE has been received
6431 */
6432
6433#define RIL_UNSOL_RESPONSE_NEW_SMS_STATUS_REPORT 1004
6434
6435/**
6436 * RIL_UNSOL_RESPONSE_NEW_SMS_ON_SIM
6437 *
6438 * Called when new SMS has been stored on SIM card
Wink Saville7f856802009-06-09 10:23:37 -07006439 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006440 * "data" is const int *
6441 * ((const int *)data)[0] contains the slot index on the SIM that contains
6442 * the new message
6443 */
6444
6445#define RIL_UNSOL_RESPONSE_NEW_SMS_ON_SIM 1005
6446
6447/**
6448 * RIL_UNSOL_ON_USSD
6449 *
6450 * Called when a new USSD message is received.
6451 *
6452 * "data" is const char **
Wink Saville7f856802009-06-09 10:23:37 -07006453 * ((const char **)data)[0] points to a type code, which is
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006454 * one of these string values:
6455 * "0" USSD-Notify -- text in ((const char **)data)[1]
6456 * "1" USSD-Request -- text in ((const char **)data)[1]
6457 * "2" Session terminated by network
6458 * "3" other local client (eg, SIM Toolkit) has responded
6459 * "4" Operation not supported
6460 * "5" Network timeout
6461 *
6462 * The USSD session is assumed to persist if the type code is "1", otherwise
6463 * the current session (if any) is assumed to have terminated.
6464 *
6465 * ((const char **)data)[1] points to a message string if applicable, which
6466 * should always be in UTF-8.
6467 */
6468#define RIL_UNSOL_ON_USSD 1006
6469/* Previously #define RIL_UNSOL_ON_USSD_NOTIFY 1006 */
6470
6471/**
6472 * RIL_UNSOL_ON_USSD_REQUEST
6473 *
6474 * Obsolete. Send via RIL_UNSOL_ON_USSD
6475 */
Wink Saville7f856802009-06-09 10:23:37 -07006476#define RIL_UNSOL_ON_USSD_REQUEST 1007
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006477
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006478/**
6479 * RIL_UNSOL_NITZ_TIME_RECEIVED
6480 *
6481 * Called when radio has received a NITZ time message
6482 *
6483 * "data" is const char * pointing to NITZ time string
6484 * in the form "yy/mm/dd,hh:mm:ss(+/-)tz,dt"
6485 */
6486#define RIL_UNSOL_NITZ_TIME_RECEIVED 1008
6487
6488/**
6489 * RIL_UNSOL_SIGNAL_STRENGTH
6490 *
6491 * Radio may report signal strength rather han have it polled.
6492 *
Wink Saville1b5fd232009-04-22 14:50:00 -07006493 * "data" is a const RIL_SignalStrength *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006494 */
6495#define RIL_UNSOL_SIGNAL_STRENGTH 1009
6496
6497
6498/**
Wink Savillef4c4d362009-04-02 01:37:03 -07006499 * RIL_UNSOL_DATA_CALL_LIST_CHANGED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006500 *
Wink Savillec0114b32011-02-18 10:14:07 -08006501 * "data" is an array of RIL_Data_Call_Response_v6 identical to that
Wink Saville29487ef2011-04-15 09:15:31 -07006502 * returned by RIL_REQUEST_DATA_CALL_LIST. It is the complete list
6503 * of current data contexts including new contexts that have been
6504 * activated. A data call is only removed from this list when the
6505 * framework sends a RIL_REQUEST_DEACTIVATE_DATA_CALL or the radio
6506 * is powered off/on.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006507 *
Wink Savillef4c4d362009-04-02 01:37:03 -07006508 * See also: RIL_REQUEST_DATA_CALL_LIST
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006509 */
6510
Wink Savillef4c4d362009-04-02 01:37:03 -07006511#define RIL_UNSOL_DATA_CALL_LIST_CHANGED 1010
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006512
6513/**
6514 * RIL_UNSOL_SUPP_SVC_NOTIFICATION
6515 *
6516 * Reports supplementary service related notification from the network.
6517 *
6518 * "data" is a const RIL_SuppSvcNotification *
6519 *
6520 */
6521
6522#define RIL_UNSOL_SUPP_SVC_NOTIFICATION 1011
6523
6524/**
6525 * RIL_UNSOL_STK_SESSION_END
6526 *
6527 * Indicate when STK session is terminated by SIM.
6528 *
6529 * "data" is NULL
6530 */
6531#define RIL_UNSOL_STK_SESSION_END 1012
6532
6533/**
6534 * RIL_UNSOL_STK_PROACTIVE_COMMAND
6535 *
6536 * Indicate when SIM issue a STK proactive command to applications
6537 *
6538 * "data" is a const char * containing SAT/USAT proactive command
6539 * in hexadecimal format string starting with command tag
6540 *
6541 */
6542#define RIL_UNSOL_STK_PROACTIVE_COMMAND 1013
6543
6544/**
6545 * RIL_UNSOL_STK_EVENT_NOTIFY
6546 *
6547 * Indicate when SIM notifies applcations some event happens.
6548 * Generally, application does not need to have any feedback to
6549 * SIM but shall be able to indicate appropriate messages to users.
6550 *
6551 * "data" is a const char * containing SAT/USAT commands or responses
6552 * sent by ME to SIM or commands handled by ME, in hexadecimal format string
6553 * starting with first byte of response data or command tag
6554 *
6555 */
6556#define RIL_UNSOL_STK_EVENT_NOTIFY 1014
6557
6558/**
6559 * RIL_UNSOL_STK_CALL_SETUP
6560 *
6561 * Indicate when SIM wants application to setup a voice call.
6562 *
6563 * "data" is const int *
6564 * ((const int *)data)[0] contains timeout value (in milliseconds)
6565 */
6566#define RIL_UNSOL_STK_CALL_SETUP 1015
6567
6568/**
6569 * RIL_UNSOL_SIM_SMS_STORAGE_FULL
6570 *
6571 * Indicates that SMS storage on the SIM is full. Sent when the network
6572 * attempts to deliver a new SMS message. Messages cannot be saved on the
6573 * SIM until space is freed. In particular, incoming Class 2 messages
6574 * cannot be stored.
6575 *
6576 * "data" is null
6577 *
6578 */
6579#define RIL_UNSOL_SIM_SMS_STORAGE_FULL 1016
6580
6581/**
6582 * RIL_UNSOL_SIM_REFRESH
6583 *
6584 * Indicates that file(s) on the SIM have been updated, or the SIM
6585 * has been reinitialized.
6586 *
Alex Yakavenka45e740e2012-01-31 11:48:27 -08006587 * In the case where RIL is version 6 or older:
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006588 * "data" is an int *
6589 * ((int *)data)[0] is a RIL_SimRefreshResult.
6590 * ((int *)data)[1] is the EFID of the updated file if the result is
Alex Yakavenka45e740e2012-01-31 11:48:27 -08006591 * SIM_FILE_UPDATE or NULL for any other result.
6592 *
6593 * In the case where RIL is version 7:
6594 * "data" is a RIL_SimRefreshResponse_v7 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006595 *
Naveen Kalla2bc78d62011-12-07 16:22:53 -08006596 * Note: If the SIM state changes as a result of the SIM refresh (eg,
6597 * SIM_READY -> SIM_LOCKED_OR_ABSENT), RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006598 * should be sent.
6599 */
6600#define RIL_UNSOL_SIM_REFRESH 1017
6601
6602/**
6603 * RIL_UNSOL_CALL_RING
6604 *
6605 * Ring indication for an incoming call (eg, RING or CRING event).
Wink Saville64533062009-08-28 11:16:03 -07006606 * There must be at least one RIL_UNSOL_CALL_RING at the beginning
6607 * of a call and sending multiple is optional. If the system property
6608 * ro.telephony.call_ring.multiple is false then the upper layers
6609 * will generate the multiple events internally. Otherwise the vendor
6610 * ril must generate multiple RIL_UNSOL_CALL_RING if
6611 * ro.telephony.call_ring.multiple is true or if it is absent.
6612 *
6613 * The rate of these events is controlled by ro.telephony.call_ring.delay
6614 * and has a default value of 3000 (3 seconds) if absent.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006615 *
Wink Saville3d54e742009-05-18 18:00:44 -07006616 * "data" is null for GSM
6617 * "data" is const RIL_CDMA_SignalInfoRecord * if CDMA
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08006618 */
6619#define RIL_UNSOL_CALL_RING 1018
6620
The Android Open Source Project34a51082009-03-05 14:34:37 -08006621/**
6622 * RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED
6623 *
6624 * Indicates that SIM state changes.
Wink Saville3d54e742009-05-18 18:00:44 -07006625 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006626 * Callee will invoke RIL_REQUEST_GET_SIM_STATUS on main thread
Wink Savillef4c4d362009-04-02 01:37:03 -07006627
The Android Open Source Project34a51082009-03-05 14:34:37 -08006628 * "data" is null
6629 */
6630#define RIL_UNSOL_RESPONSE_SIM_STATUS_CHANGED 1019
6631
6632/**
6633 * RIL_UNSOL_RESPONSE_CDMA_NEW_SMS
6634 *
6635 * Called when new CDMA SMS is received
Wink Saville3d54e742009-05-18 18:00:44 -07006636 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006637 * "data" is const RIL_CDMA_SMS_Message *
Wink Saville3d54e742009-05-18 18:00:44 -07006638 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006639 * Callee will subsequently confirm the receipt of the SMS with
6640 * a RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE
Wink Saville3d54e742009-05-18 18:00:44 -07006641 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006642 * No new RIL_UNSOL_RESPONSE_CDMA_NEW_SMS should be sent until
6643 * RIL_REQUEST_CDMA_SMS_ACKNOWLEDGE has been received
Wink Saville3d54e742009-05-18 18:00:44 -07006644 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006645 */
6646#define RIL_UNSOL_RESPONSE_CDMA_NEW_SMS 1020
6647
6648/**
6649 * RIL_UNSOL_RESPONSE_NEW_BROADCAST_SMS
6650 *
6651 * Called when new Broadcast SMS is received
Wink Saville7f856802009-06-09 10:23:37 -07006652 *
Henrik Hall0eba2022010-11-25 10:20:56 +01006653 * "data" can be one of the following:
6654 * If received from GSM network, "data" is const char of 88 bytes
6655 * which indicates each page of a CBS Message sent to the MS by the
6656 * BTS as coded in 3GPP 23.041 Section 9.4.1.2.
6657 * If received from UMTS network, "data" is const char of 90 up to 1252
6658 * bytes which contain between 1 and 15 CBS Message pages sent as one
6659 * packet to the MS by the BTS as coded in 3GPP 23.041 Section 9.4.2.2.
Wink Savillef4c4d362009-04-02 01:37:03 -07006660 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006661 */
6662#define RIL_UNSOL_RESPONSE_NEW_BROADCAST_SMS 1021
Wink Savillef4c4d362009-04-02 01:37:03 -07006663
The Android Open Source Project34a51082009-03-05 14:34:37 -08006664/**
6665 * RIL_UNSOL_CDMA_RUIM_SMS_STORAGE_FULL
6666 *
6667 * Indicates that SMS storage on the RUIM is full. Messages
6668 * cannot be saved on the RUIM until space is freed.
6669 *
6670 * "data" is null
Wink Savillef4c4d362009-04-02 01:37:03 -07006671 *
The Android Open Source Project34a51082009-03-05 14:34:37 -08006672 */
Wink Savillef4c4d362009-04-02 01:37:03 -07006673#define RIL_UNSOL_CDMA_RUIM_SMS_STORAGE_FULL 1022
6674
The Android Open Source Project34a51082009-03-05 14:34:37 -08006675/**
6676 * RIL_UNSOL_RESTRICTED_STATE_CHANGED
6677 *
6678 * Indicates a restricted state change (eg, for Domain Specific Access Control).
6679 *
6680 * Radio need send this msg after radio off/on cycle no matter it is changed or not.
6681 *
6682 * "data" is an int *
6683 * ((int *)data)[0] contains a bitmask of RIL_RESTRICTED_STATE_* values.
6684 */
6685#define RIL_UNSOL_RESTRICTED_STATE_CHANGED 1023
6686
Wink Saville1b5fd232009-04-22 14:50:00 -07006687/**
6688 * RIL_UNSOL_ENTER_EMERGENCY_CALLBACK_MODE
6689 *
6690 * Indicates that the radio system selection module has
6691 * autonomously entered emergency callback mode.
6692 *
6693 * "data" is null
6694 *
6695 */
6696#define RIL_UNSOL_ENTER_EMERGENCY_CALLBACK_MODE 1024
The Android Open Source Project34a51082009-03-05 14:34:37 -08006697
Wink Saville1b5fd232009-04-22 14:50:00 -07006698/**
6699 * RIL_UNSOL_CDMA_CALL_WAITING
6700 *
6701 * Called when CDMA radio receives a call waiting indication.
6702 *
6703 * "data" is const RIL_CDMA_CallWaiting *
Wink Saville7f856802009-06-09 10:23:37 -07006704 *
Wink Saville1b5fd232009-04-22 14:50:00 -07006705 */
6706#define RIL_UNSOL_CDMA_CALL_WAITING 1025
6707
6708/**
6709 * RIL_UNSOL_CDMA_OTA_PROVISION_STATUS
6710 *
6711 * Called when CDMA radio receives an update of the progress of an
6712 * OTASP/OTAPA call.
6713 *
6714 * "data" is const int *
6715 * For CDMA this is an integer OTASP/OTAPA status listed in
6716 * RIL_CDMA_OTA_ProvisionStatus.
6717 *
6718 */
6719#define RIL_UNSOL_CDMA_OTA_PROVISION_STATUS 1026
6720
6721/**
6722 * RIL_UNSOL_CDMA_INFO_REC
6723 *
6724 * Called when CDMA radio receives one or more info recs.
6725 *
6726 * "data" is const RIL_CDMA_InformationRecords *
6727 *
6728 */
6729#define RIL_UNSOL_CDMA_INFO_REC 1027
The Android Open Source Project34a51082009-03-05 14:34:37 -08006730
Jaikumar Ganeshaf6ecbf2009-04-29 13:27:51 -07006731/**
6732 * RIL_UNSOL_OEM_HOOK_RAW
6733 *
6734 * This is for OEM specific use.
6735 *
6736 * "data" is a byte[]
6737 */
6738#define RIL_UNSOL_OEM_HOOK_RAW 1028
6739
John Wang5d621da2009-09-18 17:17:48 -07006740/**
6741 * RIL_UNSOL_RINGBACK_TONE
6742 *
6743 * Indicates that nework doesn't have in-band information, need to
6744 * play out-band tone.
6745 *
6746 * "data" is an int *
6747 * ((int *)data)[0] == 0 for stop play ringback tone.
6748 * ((int *)data)[0] == 1 for start play ringback tone.
6749 */
6750#define RIL_UNSOL_RINGBACK_TONE 1029
6751
John Wang5909cf82010-01-29 00:18:54 -08006752/**
6753 * RIL_UNSOL_RESEND_INCALL_MUTE
6754 *
6755 * Indicates that framework/application need reset the uplink mute state.
6756 *
6757 * There may be situations where the mute state becomes out of sync
6758 * between the application and device in some GSM infrastructures.
6759 *
6760 * "data" is null
6761 */
6762#define RIL_UNSOL_RESEND_INCALL_MUTE 1030
Wink Savillec0114b32011-02-18 10:14:07 -08006763
6764/**
6765 * RIL_UNSOL_CDMA_SUBSCRIPTION_SOURCE_CHANGED
6766 *
6767 * Called when CDMA subscription source changed.
6768 *
6769 * "data" is int *
6770 * ((int *)data)[0] is == RIL_CdmaSubscriptionSource
6771 */
Wink Saville29487ef2011-04-15 09:15:31 -07006772#define RIL_UNSOL_CDMA_SUBSCRIPTION_SOURCE_CHANGED 1031
Wink Savillec0114b32011-02-18 10:14:07 -08006773
6774/**
6775 * RIL_UNSOL_CDMA_PRL_CHANGED
6776 *
6777 * Called when PRL (preferred roaming list) changes.
6778 *
6779 * "data" is int *
6780 * ((int *)data)[0] is PRL_VERSION as would be returned by RIL_REQUEST_CDMA_SUBSCRIPTION
6781 */
6782#define RIL_UNSOL_CDMA_PRL_CHANGED 1032
6783
6784/**
6785 * RIL_UNSOL_EXIT_EMERGENCY_CALLBACK_MODE
6786 *
6787 * Called when Emergency Callback Mode Ends
6788 *
6789 * Indicates that the radio system selection module has
6790 * proactively exited emergency callback mode.
6791 *
6792 * "data" is NULL
6793 *
6794 */
6795#define RIL_UNSOL_EXIT_EMERGENCY_CALLBACK_MODE 1033
6796
Wink Saville5b9df332011-04-06 16:24:21 -07006797/**
6798 * RIL_UNSOL_RIL_CONNECTED
6799 *
6800 * Called the ril connects and returns the version
6801 *
6802 * "data" is int *
6803 * ((int *)data)[0] is RIL_VERSION
6804 */
6805#define RIL_UNSOL_RIL_CONNECTED 1034
6806
Naveen Kalla2bc78d62011-12-07 16:22:53 -08006807/**
6808 * RIL_UNSOL_VOICE_RADIO_TECH_CHANGED
6809 *
6810 * Indicates that voice technology has changed. Contains new radio technology
6811 * as a data in the message.
6812 *
6813 * "data" is int *
6814 * ((int *)data)[0] is of type const RIL_RadioTechnology
6815 *
6816 */
6817#define RIL_UNSOL_VOICE_RADIO_TECH_CHANGED 1035
6818
Wink Saville8a9e0212013-04-09 12:11:38 -07006819/**
6820 * RIL_UNSOL_CELL_INFO_LIST
6821 *
6822 * Same information as returned by RIL_REQUEST_GET_CELL_INFO_LIST, but returned
6823 * at the rate no greater than specified by RIL_REQUEST_SET_UNSOL_CELL_INFO_RATE.
6824 *
6825 * "data" is NULL
6826 *
Sanket Padawef53c5fa2016-01-27 10:00:38 -08006827 * "response" is an array of RIL_CellInfo_v12.
Wink Saville8a9e0212013-04-09 12:11:38 -07006828 */
6829#define RIL_UNSOL_CELL_INFO_LIST 1036
Naveen Kalla2bc78d62011-12-07 16:22:53 -08006830
Wink Saville865ce3b2013-11-08 16:37:01 -08006831/**
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07006832 * RIL_UNSOL_RESPONSE_IMS_NETWORK_STATE_CHANGED
6833 *
Nathan Harold0eb43c22016-12-19 12:04:32 -08006834 * This message is DEPRECATED and shall be removed in a future release (target: 2018);
6835 * instead, provide IMS registration status via an IMS Service.
6836 *
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07006837 * Called when IMS registration state has changed
6838 *
Wink Saville865ce3b2013-11-08 16:37:01 -08006839 * To get IMS registration state and IMS SMS format, callee needs to invoke the
6840 * following request on main thread:
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07006841 *
Wink Saville865ce3b2013-11-08 16:37:01 -08006842 * RIL_REQUEST_IMS_REGISTRATION_STATE
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07006843 *
Wink Saville865ce3b2013-11-08 16:37:01 -08006844 * "data" is NULL
6845 *
Sukanya Rajkhowaa18b9d12013-09-10 12:30:13 -07006846 */
6847#define RIL_UNSOL_RESPONSE_IMS_NETWORK_STATE_CHANGED 1037
6848
Etan Cohend3652192014-06-20 08:28:44 -07006849/**
6850 * RIL_UNSOL_UICC_SUBSCRIPTION_STATUS_CHANGED
6851 *
6852 * Indicated when there is a change in subscription status.
6853 * This event will be sent in the following scenarios
6854 * - subscription readiness at modem, which was selected by telephony layer
6855 * - when subscription is deactivated by modem due to UICC card removal
6856 * - When network invalidates the subscription i.e. attach reject due to authentication reject
6857 *
6858 * "data" is const int *
6859 * ((const int *)data)[0] == 0 for Subscription Deactivated
6860 * ((const int *)data)[0] == 1 for Subscription Activated
6861 *
6862 */
6863#define RIL_UNSOL_UICC_SUBSCRIPTION_STATUS_CHANGED 1038
6864
6865/**
6866 * RIL_UNSOL_SRVCC_STATE_NOTIFY
6867 *
6868 * Called when Single Radio Voice Call Continuity(SRVCC)
6869 * progress state has changed
6870 *
6871 * "data" is int *
6872 * ((int *)data)[0] is of type const RIL_SrvccState
6873 *
6874 */
6875
6876#define RIL_UNSOL_SRVCC_STATE_NOTIFY 1039
6877
6878/**
6879 * RIL_UNSOL_HARDWARE_CONFIG_CHANGED
6880 *
6881 * Called when the hardware configuration associated with the RILd changes
6882 *
6883 * "data" is an array of RIL_HardwareConfig
6884 *
6885 */
6886#define RIL_UNSOL_HARDWARE_CONFIG_CHANGED 1040
6887
Wink Savillec29360a2014-07-13 05:17:28 -07006888/**
6889 * RIL_UNSOL_DC_RT_INFO_CHANGED
6890 *
Sooraj Sasindran73f2ccb2015-04-08 17:23:07 -07006891 * The message is DEPRECATED, use RIL_REQUEST_GET_ACTIVITY_INFO
Wink Savillec29360a2014-07-13 05:17:28 -07006892 * Sent when the DC_RT_STATE changes but the time
6893 * between these messages must not be less than the
6894 * value set by RIL_REQUEST_SET_DC_RT_RATE.
6895 *
6896 * "data" is the most recent RIL_DcRtInfo
6897 *
6898 */
6899#define RIL_UNSOL_DC_RT_INFO_CHANGED 1041
6900
Wink Saville8b4e4f72014-10-17 15:01:45 -07006901/**
6902 * RIL_UNSOL_RADIO_CAPABILITY
6903 *
6904 * Sent when RIL_REQUEST_SET_RADIO_CAPABILITY completes.
6905 * Returns the phone radio capability exactly as
6906 * RIL_REQUEST_GET_RADIO_CAPABILITY and should be the
6907 * same set as sent by RIL_REQUEST_SET_RADIO_CAPABILITY.
6908 *
6909 * "data" is the RIL_RadioCapability structure
6910 */
6911#define RIL_UNSOL_RADIO_CAPABILITY 1042
6912
Amit Mahajan54563d32014-11-22 00:54:49 +00006913/*
6914 * RIL_UNSOL_ON_SS
6915 *
6916 * Called when SS response is received when DIAL/USSD/SS is changed to SS by
6917 * call control.
6918 *
6919 * "data" is const RIL_StkCcUnsolSsResponse *
6920 *
6921 */
6922#define RIL_UNSOL_ON_SS 1043
6923
6924/**
6925 * RIL_UNSOL_STK_CC_ALPHA_NOTIFY
6926 *
6927 * Called when there is an ALPHA from UICC during Call Control.
6928 *
6929 * "data" is const char * containing ALPHA string from UICC in UTF-8 format.
6930 *
6931 */
6932#define RIL_UNSOL_STK_CC_ALPHA_NOTIFY 1044
6933
fengluf7408292015-04-14 14:53:55 -07006934/**
6935 * RIL_UNSOL_LCEDATA_RECV
6936 *
6937 * Called when there is an incoming Link Capacity Estimate (LCE) info report.
6938 *
fenglu290add32015-05-01 17:05:15 -07006939 * "data" is the RIL_LceDataInfo structure.
fengluf7408292015-04-14 14:53:55 -07006940 *
6941 */
6942#define RIL_UNSOL_LCEDATA_RECV 1045
6943
Robert Greenwalt27e99c52016-06-01 16:31:38 -07006944 /**
6945 * RIL_UNSOL_PCO_DATA
6946 *
6947 * Called when there is new Carrier PCO data received for a data call. Ideally
6948 * only new data will be forwarded, though this is not required. Multiple
6949 * boxes of carrier PCO data for a given call should result in a series of
6950 * RIL_UNSOL_PCO_DATA calls.
6951 *
6952 * "data" is the RIL_PCO_Data structure.
6953 *
6954 */
6955#define RIL_UNSOL_PCO_DATA 1046
6956
Naveen Kalla90ddf072016-09-14 13:41:04 -07006957 /**
6958 * RIL_UNSOL_MODEM_RESTART
6959 *
6960 * Called when there is a modem reset.
6961 *
6962 * "reason" is "const char *" containing the reason for the reset. It
6963 * could be a crash signature if the restart was due to a crash or some
6964 * string such as "user-initiated restart" or "AT command initiated
6965 * restart" that explains the cause of the modem restart.
6966 *
6967 * When modem restarts, one of the following radio state transitions will happen
6968 * 1) RADIO_STATE_ON->RADIO_STATE_UNAVAILABLE->RADIO_STATE_ON or
6969 * 2) RADIO_STATE_OFF->RADIO_STATE_UNAVAILABLE->RADIO_STATE_OFF
6970 * This message can be sent either just before the RADIO_STATE changes to RADIO_STATE_UNAVAILABLE
6971 * or just after but should never be sent after the RADIO_STATE changes from UNAVAILABLE to
6972 * AVAILABLE(RADIO_STATE_ON/RADIO_STATE_OFF) again.
6973 *
6974 * It should NOT be sent after the RADIO_STATE changes to AVAILABLE after the
6975 * modem restart as that could be interpreted as a second modem reset by the
6976 * framework.
6977 */
6978#define RIL_UNSOL_MODEM_RESTART 1047
6979
pkanwarc61837e2017-03-17 12:49:34 -07006980/**
6981 * RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION
6982 *
6983 * Called when the modem needs Carrier specific information that will
6984 * be used to encrypt IMSI and IMPI.
6985 *
6986 * "data" is NULL
6987 *
6988 */
pkanwar2a6951e2017-04-27 13:15:56 -07006989#define RIL_UNSOL_CARRIER_INFO_IMSI_ENCRYPTION 1048
pkanwarc61837e2017-03-17 12:49:34 -07006990
yinxu7317bd42017-05-03 15:15:19 -07006991/**
6992 * RIL_UNSOL_NETWORK_SCAN_RESULT
6993 *
6994 * Returns incremental result for the network scan which is started by
6995 * RIL_REQUEST_START_NETWORK_SCAN, sent to report results, status, or errors.
6996 *
6997 * "data" is NULL
6998 * "response" is a const RIL_NetworkScanResult *
6999 */
7000#define RIL_UNSOL_NETWORK_SCAN_RESULT 1049
7001
Nathan Haroldec94b822017-05-25 16:10:35 -07007002/**
7003 * RIL_UNSOL_KEEPALIVE_STATUS
7004 *
7005 * "data" is NULL
7006 * "response" is a const RIL_KeepaliveStatus *
7007 */
7008#define RIL_UNSOL_KEEPALIVE_STATUS 1050
7009
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007010/***********************************************************************/
7011
Amit Mahajan54563d32014-11-22 00:54:49 +00007012
Etan Cohend3652192014-06-20 08:28:44 -07007013#if defined(ANDROID_MULTI_SIM)
7014/**
7015 * RIL_Request Function pointer
7016 *
7017 * @param request is one of RIL_REQUEST_*
7018 * @param data is pointer to data defined for that RIL_REQUEST_*
7019 * data is owned by caller, and should not be modified or freed by callee
Sanket Padawe05c23072016-08-08 15:42:17 -07007020 * structures passed as data may contain pointers to non-contiguous memory
Etan Cohend3652192014-06-20 08:28:44 -07007021 * @param t should be used in subsequent call to RIL_onResponse
Sanket Padawe05c23072016-08-08 15:42:17 -07007022 * @param datalen is the length of "data" which is defined as other argument. It may or may
7023 * not be equal to sizeof(data). Refer to the documentation of individual structures
7024 * to find if pointers listed in the structure are contiguous and counted in the datalen
7025 * length or not.
7026 * (Eg: RIL_IMS_SMS_Message where we don't have datalen equal to sizeof(data))
Etan Cohend3652192014-06-20 08:28:44 -07007027 *
7028 */
7029typedef void (*RIL_RequestFunc) (int request, void *data,
7030 size_t datalen, RIL_Token t, RIL_SOCKET_ID socket_id);
7031
7032/**
7033 * This function should return the current radio state synchronously
7034 */
7035typedef RIL_RadioState (*RIL_RadioStateRequest)(RIL_SOCKET_ID socket_id);
7036
7037#else
7038/* Backward compatible */
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007039
7040/**
7041 * RIL_Request Function pointer
7042 *
7043 * @param request is one of RIL_REQUEST_*
7044 * @param data is pointer to data defined for that RIL_REQUEST_*
7045 * data is owned by caller, and should not be modified or freed by callee
Sanket Padawe05c23072016-08-08 15:42:17 -07007046 * structures passed as data may contain pointers to non-contiguous memory
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007047 * @param t should be used in subsequent call to RIL_onResponse
Sanket Padawe05c23072016-08-08 15:42:17 -07007048 * @param datalen is the length of "data" which is defined as other argument. It may or may
7049 * not be equal to sizeof(data). Refer to the documentation of individual structures
7050 * to find if pointers listed in the structure are contiguous and counted in the datalen
7051 * length or not.
7052 * (Eg: RIL_IMS_SMS_Message where we don't have datalen equal to sizeof(data))
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007053 *
7054 */
Wink Saville7f856802009-06-09 10:23:37 -07007055typedef void (*RIL_RequestFunc) (int request, void *data,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007056 size_t datalen, RIL_Token t);
7057
7058/**
7059 * This function should return the current radio state synchronously
7060 */
7061typedef RIL_RadioState (*RIL_RadioStateRequest)();
7062
Etan Cohend3652192014-06-20 08:28:44 -07007063#endif
7064
7065
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007066/**
7067 * This function returns "1" if the specified RIL_REQUEST code is
7068 * supported and 0 if it is not
7069 *
7070 * @param requestCode is one of RIL_REQUEST codes
7071 */
7072
7073typedef int (*RIL_Supports)(int requestCode);
7074
7075/**
Wink Saville7f856802009-06-09 10:23:37 -07007076 * This function is called from a separate thread--not the
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007077 * thread that calls RIL_RequestFunc--and indicates that a pending
7078 * request should be cancelled.
Wink Saville7f856802009-06-09 10:23:37 -07007079 *
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007080 * On cancel, the callee should do its best to abandon the request and
7081 * call RIL_onRequestComplete with RIL_Errno CANCELLED at some later point.
7082 *
7083 * Subsequent calls to RIL_onRequestComplete for this request with
7084 * other results will be tolerated but ignored. (That is, it is valid
7085 * to ignore the cancellation request)
7086 *
7087 * RIL_Cancel calls should return immediately, and not wait for cancellation
7088 *
Wink Saville7f856802009-06-09 10:23:37 -07007089 * Please see ITU v.250 5.6.1 for how one might implement this on a TS 27.007
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007090 * interface
7091 *
7092 * @param t token wants to be canceled
7093 */
7094
7095typedef void (*RIL_Cancel)(RIL_Token t);
7096
7097typedef void (*RIL_TimedCallback) (void *param);
7098
7099/**
7100 * Return a version string for your RIL implementation
7101 */
7102typedef const char * (*RIL_GetVersion) (void);
7103
7104typedef struct {
7105 int version; /* set to RIL_VERSION */
7106 RIL_RequestFunc onRequest;
7107 RIL_RadioStateRequest onStateRequest;
7108 RIL_Supports supports;
7109 RIL_Cancel onCancel;
7110 RIL_GetVersion getVersion;
7111} RIL_RadioFunctions;
7112
Sungmin Choi75697532013-04-26 15:04:45 -07007113typedef struct {
Jack Yude8c8552017-01-24 12:03:52 -08007114 char *apn; /* the APN to connect to */
7115 char *protocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on
7116 roaming network. For example, "IP", "IPV6", "IPV4V6", or "PPP".*/
7117 int authtype; /* authentication protocol used for this PDP context
7118 (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) */
7119 char *username; /* the username for APN, or NULL */
7120 char *password; /* the password for APN, or NULL */
Sungmin Choi75697532013-04-26 15:04:45 -07007121} RIL_InitialAttachApn;
7122
Amit Mahajan2b772032014-06-26 14:20:11 -07007123typedef struct {
Jack Yude8c8552017-01-24 12:03:52 -08007124 char *apn; /* the APN to connect to */
7125 char *protocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on
7126 home network. For example, "IP", "IPV6", "IPV4V6", or "PPP". */
7127 char *roamingProtocol; /* one of the PDP_type values in TS 27.007 section 10.1.1 used on
7128 roaming network. For example, "IP", "IPV6", "IPV4V6", or "PPP".*/
7129 int authtype; /* authentication protocol used for this PDP context
7130 (None: 0, PAP: 1, CHAP: 2, PAP&CHAP: 3) */
7131 char *username; /* the username for APN, or NULL */
7132 char *password; /* the password for APN, or NULL */
7133 int supportedTypesBitmask; /* supported APN types bitmask. See RIL_ApnTypes for the value of
7134 each bit. */
7135 int bearerBitmask; /* the bearer bitmask. See RIL_RadioAccessFamily for the value of
7136 each bit. */
7137 int modemCognitive; /* indicating the APN setting was sent to the modem through
7138 setDataProfile earlier. */
7139 int mtu; /* maximum transmission unit (MTU) size in bytes */
7140 char *mvnoType; /* the MVNO type: possible values are "imsi", "gid", "spn" */
7141 char *mvnoMatchData; /* MVNO match data. Can be anything defined by the carrier.
7142 For example,
7143 SPN like: "A MOBILE", "BEN NL", etc...
7144 IMSI like: "302720x94", "2060188", etc...
7145 GID like: "4E", "33", etc... */
7146} RIL_InitialAttachApn_v15;
7147
7148typedef struct {
Amit Mahajan2b772032014-06-26 14:20:11 -07007149 int authContext; /* P2 value of authentication command, see P2 parameter in
7150 3GPP TS 31.102 7.1.2 */
7151 char *authData; /* the challenge string in Base64 format, see 3GPP
7152 TS 31.102 7.1.2 */
7153 char *aid; /* AID value, See ETSI 102.221 8.1 and 101.220 4,
7154 NULL if no value. */
7155} RIL_SimAuthentication;
7156
Robert Greenwalt17ea3fa2016-06-15 14:59:38 -07007157typedef struct {
Jack Yude8c8552017-01-24 12:03:52 -08007158 int cid; /* Context ID, uniquely identifies this call */
7159 char *bearer_proto; /* One of the PDP_type values in TS 27.007 section 10.1.1.
7160 For example, "IP", "IPV6", "IPV4V6". */
7161 int pco_id; /* The protocol ID for this box. Note that only IDs from
7162 FF00H - FFFFH are accepted. If more than one is included
7163 from the network, multiple calls should be made to send all
7164 of them. */
7165 int contents_length; /* The number of octets in the contents. */
7166 char *contents; /* Carrier-defined content. It is binary, opaque and
7167 loosely defined in LTE Layer 3 spec 24.008 */
Robert Greenwalt17ea3fa2016-06-15 14:59:38 -07007168} RIL_PCO_Data;
7169
Nathan Haroldec94b822017-05-25 16:10:35 -07007170typedef enum {
7171 NATT_IPV4 = 0, /* Keepalive specified by RFC 3948 Sec. 2.3 using IPv4 */
7172 NATT_IPV6 = 1 /* Keepalive specified by RFC 3948 Sec. 2.3 using IPv6 */
7173} RIL_KeepaliveType;
7174
7175#define MAX_INADDR_LEN 16
7176typedef struct {
7177 RIL_KeepaliveType type; /* Type of keepalive packet */
7178 char sourceAddress[MAX_INADDR_LEN]; /* Source address in network-byte order */
7179 int sourcePort; /* Source port if applicable, or 0x7FFFFFFF;
7180 the maximum value is 65535 */
7181 char destinationAddress[MAX_INADDR_LEN]; /* Destination address in network-byte order */
7182 int destinationPort; /* Destination port if applicable or 0x7FFFFFFF;
7183 the maximum value is 65535 */
7184 int maxKeepaliveIntervalMillis; /* Maximum milliseconds between two packets */
7185 int cid; /* Context ID, uniquely identifies this call */
7186} RIL_KeepaliveRequest;
7187
7188typedef enum {
7189 KEEPALIVE_ACTIVE, /* Keepalive session is active */
7190 KEEPALIVE_INACTIVE, /* Keepalive session is inactive */
7191 KEEPALIVE_PENDING /* Keepalive session status not available */
7192} RIL_KeepaliveStatusCode;
7193
7194typedef struct {
7195 uint32_t sessionHandle;
7196 RIL_KeepaliveStatusCode code;
7197} RIL_KeepaliveStatus;
7198
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007199#ifdef RIL_SHLIB
7200struct RIL_Env {
7201 /**
7202 * "t" is parameter passed in on previous call to RIL_Notification
7203 * routine.
7204 *
7205 * If "e" != SUCCESS, then response can be null/is ignored
7206 *
Wink Saville7f856802009-06-09 10:23:37 -07007207 * "response" is owned by caller, and should not be modified or
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007208 * freed by callee
7209 *
7210 * RIL_onRequestComplete will return as soon as possible
7211 */
Wink Saville7f856802009-06-09 10:23:37 -07007212 void (*OnRequestComplete)(RIL_Token t, RIL_Errno e,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007213 void *response, size_t responselen);
7214
Etan Cohend3652192014-06-20 08:28:44 -07007215#if defined(ANDROID_MULTI_SIM)
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007216 /**
7217 * "unsolResponse" is one of RIL_UNSOL_RESPONSE_*
7218 * "data" is pointer to data defined for that RIL_UNSOL_RESPONSE_*
7219 *
7220 * "data" is owned by caller, and should not be modified or freed by callee
7221 */
Etan Cohend3652192014-06-20 08:28:44 -07007222 void (*OnUnsolicitedResponse)(int unsolResponse, const void *data, size_t datalen, RIL_SOCKET_ID socket_id);
7223#else
7224 /**
7225 * "unsolResponse" is one of RIL_UNSOL_RESPONSE_*
7226 * "data" is pointer to data defined for that RIL_UNSOL_RESPONSE_*
7227 *
7228 * "data" is owned by caller, and should not be modified or freed by callee
7229 */
7230 void (*OnUnsolicitedResponse)(int unsolResponse, const void *data, size_t datalen);
7231#endif
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007232 /**
Wink Saville7f856802009-06-09 10:23:37 -07007233 * Call user-specifed "callback" function on on the same thread that
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007234 * RIL_RequestFunc is called. If "relativeTime" is specified, then it specifies
7235 * a relative time value at which the callback is invoked. If relativeTime is
7236 * NULL or points to a 0-filled structure, the callback will be invoked as
7237 * soon as possible
7238 */
7239
Dianne Hackborn0d9f0c02010-06-25 16:50:46 -07007240 void (*RequestTimedCallback) (RIL_TimedCallback callback,
Wink Saville7f856802009-06-09 10:23:37 -07007241 void *param, const struct timeval *relativeTime);
Sanket Padawe6ff9a872016-01-27 15:09:12 -08007242 /**
7243 * "t" is parameter passed in on previous call RIL_Notification routine
7244 *
7245 * RIL_onRequestAck will be called by vendor when an Async RIL request was received
7246 * by them and an ack needs to be sent back to java ril.
7247 */
7248 void (*OnRequestAck) (RIL_Token t);
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007249};
7250
7251
Wink Saville7f856802009-06-09 10:23:37 -07007252/**
7253 * RIL implementations must defined RIL_Init
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007254 * argc and argv will be command line arguments intended for the RIL implementation
7255 * Return NULL on error
7256 *
7257 * @param env is environment point defined as RIL_Env
7258 * @param argc number of arguments
7259 * @param argv list fo arguments
7260 *
7261 */
7262const RIL_RadioFunctions *RIL_Init(const struct RIL_Env *env, int argc, char **argv);
7263
Sanket Padawe1be49ba2016-03-31 17:37:23 -07007264/**
7265 * If BT SAP(SIM Access Profile) is supported, then RIL implementations must define RIL_SAP_Init
7266 * for initializing RIL_RadioFunctions used for BT SAP communcations. It is called whenever RILD
7267 * starts or modem restarts. Returns handlers for SAP related request that are made on SAP
7268 * sepecific socket, analogous to the RIL_RadioFunctions returned by the call to RIL_Init
7269 * and used on the general RIL socket.
7270 * argc and argv will be command line arguments intended for the RIL implementation
7271 * Return NULL on error.
7272 *
7273 * @param env is environment point defined as RIL_Env
7274 * @param argc number of arguments
7275 * @param argv list fo arguments
7276 *
7277 */
7278const RIL_RadioFunctions *RIL_SAP_Init(const struct RIL_Env *env, int argc, char **argv);
7279
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007280#else /* RIL_SHLIB */
7281
7282/**
7283 * Call this once at startup to register notification routine
7284 *
7285 * @param callbacks user-specifed callback function
7286 */
7287void RIL_register (const RIL_RadioFunctions *callbacks);
7288
Amit Mahajan18fe36b2016-08-25 11:19:21 -07007289void rilc_thread_pool();
7290
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007291
7292/**
7293 *
7294 * RIL_onRequestComplete will return as soon as possible
7295 *
7296 * @param t is parameter passed in on previous call to RIL_Notification
Wink Saville3d54e742009-05-18 18:00:44 -07007297 * routine.
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007298 * @param e error code
7299 * if "e" != SUCCESS, then response can be null/is ignored
7300 * @param response is owned by caller, and should not be modified or
7301 * freed by callee
7302 * @param responselen the length of response in byte
7303 */
Wink Saville7f856802009-06-09 10:23:37 -07007304void RIL_onRequestComplete(RIL_Token t, RIL_Errno e,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007305 void *response, size_t responselen);
7306
Sanket Padawe6ff9a872016-01-27 15:09:12 -08007307/**
7308 * RIL_onRequestAck will be called by vendor when an Async RIL request was received by them and
7309 * an ack needs to be sent back to java ril. This doesn't mark the end of the command or it's
7310 * results, just that the command was received and will take a while. After sending this Ack
7311 * its vendor's responsibility to make sure that AP is up whenever needed while command is
7312 * being processed.
7313 *
7314 * @param t is parameter passed in on previous call to RIL_Notification
7315 * routine.
7316 */
7317void RIL_onRequestAck(RIL_Token t);
7318
Etan Cohend3652192014-06-20 08:28:44 -07007319#if defined(ANDROID_MULTI_SIM)
7320/**
7321 * @param unsolResponse is one of RIL_UNSOL_RESPONSE_*
7322 * @param data is pointer to data defined for that RIL_UNSOL_RESPONSE_*
7323 * "data" is owned by caller, and should not be modified or freed by callee
7324 * @param datalen the length of data in byte
7325 */
7326
7327void RIL_onUnsolicitedResponse(int unsolResponse, const void *data,
7328 size_t datalen, RIL_SOCKET_ID socket_id);
7329#else
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007330/**
7331 * @param unsolResponse is one of RIL_UNSOL_RESPONSE_*
7332 * @param data is pointer to data defined for that RIL_UNSOL_RESPONSE_*
7333 * "data" is owned by caller, and should not be modified or freed by callee
7334 * @param datalen the length of data in byte
7335 */
7336
Wink Saville7f856802009-06-09 10:23:37 -07007337void RIL_onUnsolicitedResponse(int unsolResponse, const void *data,
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007338 size_t datalen);
Etan Cohend3652192014-06-20 08:28:44 -07007339#endif
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007340
7341/**
Wink Saville7f856802009-06-09 10:23:37 -07007342 * Call user-specifed "callback" function on on the same thread that
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007343 * RIL_RequestFunc is called. If "relativeTime" is specified, then it specifies
7344 * a relative time value at which the callback is invoked. If relativeTime is
7345 * NULL or points to a 0-filled structure, the callback will be invoked as
7346 * soon as possible
7347 *
7348 * @param callback user-specifed callback function
7349 * @param param parameter list
7350 * @param relativeTime a relative time value at which the callback is invoked
7351 */
7352
Dianne Hackborn0d9f0c02010-06-25 16:50:46 -07007353void RIL_requestTimedCallback (RIL_TimedCallback callback,
7354 void *param, const struct timeval *relativeTime);
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007355
The Android Open Source Project00f06fc2009-03-03 19:32:15 -08007356#endif /* RIL_SHLIB */
7357
7358#ifdef __cplusplus
7359}
7360#endif
7361
7362#endif /*ANDROID_RIL_H*/