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