blob: 973fb4783d843134d9fae78a3e7b27faac1550e4 [file] [log] [blame]
liubin281ac462023-07-19 14:22:54 +08001/**
2 *@file ql_mcm_voice.h
3 *@date 2017-11-30
4 *@author
5 *@brief
6 */
7
8#ifndef __QL_MCM_VOICE_H__
9#define __QL_MCM_VOICE_H__
10
11#include "mbtk_type.h"
12#include "mbtk_log.h"
13#include "ql_vcall.h"
14
15#define QL_MCM_MAX_VOICE_CALLS 8 /** GSM provides up to 8 calls; 3GPP2 provides 2. */
16#define QL_MCM_MAX_PHONE_NUMBER 82 /** Maximum phone number length. */
17#define QL_MCM_MAX_UUS_DATA 20 /** Maximum user-to-user data. */
18#define QL_MCM_MAX_DTMF_LENGTH 20 /** Maximum DTMF length. */
19#define QL_MCM_MAX_USSD_LENGTH 128 /** Maximum USSD length. */
20#define QL_MCM_MAX_PASSWORD_LENGTH 4 /** Maximum password length. */
21#define QL_MCM_MAX_CALL_FORWARDING_INFO 13 /** Maximum call forwarding information. */
22#define QL_MCM_MAX_ECALL_MSD 140 /** Maximum size of the MSD sent to the network with an eCall */
23#define QL_MCM_MAX_ECALL_URC_EVENT_LENGTH 128 /** Maximum size of the ecall urc event */
24
25
26typedef enum
27{
28 E_QL_MCM_VOICE_CALL_STATE_INCOMING = 0x0000, /**< MT incoming; CC setup. */
29 E_QL_MCM_VOICE_CALL_STATE_DIALING = 0x0001, /**< Dialing state. */
30 E_QL_MCM_VOICE_CALL_STATE_ALERTING = 0x0002, /**< MT call waiting; MO alterting. */
31 E_QL_MCM_VOICE_CALL_STATE_ACTIVE = 0x0003, /**< Call is active. */
32 E_QL_MCM_VOICE_CALL_STATE_HOLDING = 0x0004, /**< Call is on hold. */
33 E_QL_MCM_VOICE_CALL_STATE_END = 0x0005, /**< Call is disconnected. */
34 E_QL_MCM_VOICE_CALL_STATE_WAITING = 0x0006, /**< Call is waiting. */
35} ql_mcm_voice_call_state_t;
36
37typedef enum
38{
39 E_QL_MCM_VOICE_TECH_NONE = 0, /**< None. */
40 E_QL_MCM_VOICE_TECH_3GPP = 1, /**< 3GPP. */
41 E_QL_MCM_VOICE_TECH_3GPP2 = 2, /**< 3GPP2. */
42} ql_mcm_voice_tech_t;
43
44typedef enum
45{
46 E_QL_MCM_VOICE_CALL_NUMBER_UNKNOWN = 0x0000,
47 E_QL_MCM_VOICE_CALL_NUMBER_ALLOWED = 0x0001, /**< Number allowed. */
48 E_QL_MCM_VOICE_CALL_NUMBER_RESTRICTED = 0x0002, /**< Number restricted. */
49 E_QL_MCM_VOICE_CALL_NUMBER_PAYPHONE = 0x0003, /**< Payhone number. */
50} ql_mcm_voice_call_number_presentation_type_t;
51
52typedef enum
53{
54 E_QL_MCM_VOICE_CALL_MOBILE_ORIGINATED = 0x0000, /**< Mobile-originated. */
55 E_QL_MCM_VOICE_CALL_MOBILE_TERMINATED = 0x0001, /**< Mobile-terminated. */
56} ql_mcm_voice_call_direction_type_t;
57
58typedef enum
59{
60 E_QL_MCM_VOICE_CALL_ANSWER, //!<Answer the call.
61 E_QL_MCM_VOICE_CALL_END, //!<Deprecated. Do not use.
62 E_QL_MCM_VOICE_CALL_HOLD, //!<Hold the call.
63 E_QL_MCM_VOICE_CALL_UNHOLD, //!<Release the call from hold.
64 E_QL_MCM_VOICE_CALL_CONFERENCE, //!<Conference call.
65 E_QL_MCM_VOICE_CALL_GO_PRIVATE, //!<Private call.
66 E_QL_MCM_VOICE_CALL_END_ALL //!<End all calls.
67} ql_mcm_voice_call_operation_t; //!< Voice call operation type.
68
69typedef enum
70{
71 E_QL_MCM_VOICE_CALL_END_REASON_NONE = 0,
72 E_QL_MCM_VOICE_CALL_END_CAUSE_OFFLINE = 1,
73 E_QL_MCM_VOICE_CALL_END_CAUSE_CDMA_LOCK = 2,
74 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_SRV = 3,
75 E_QL_MCM_VOICE_CALL_END_CAUSE_FADE = 4,
76 E_QL_MCM_VOICE_CALL_END_CAUSE_INTERCEPT = 5,
77 E_QL_MCM_VOICE_CALL_END_CAUSE_REORDER = 6,
78 E_QL_MCM_VOICE_CALL_END_CAUSE_REL_NORMAL = 7,
79 E_QL_MCM_VOICE_CALL_END_CAUSE_REL_SO_REJ = 8,
80 E_QL_MCM_VOICE_CALL_END_CAUSE_INCOM_CALL = 9,
81 E_QL_MCM_VOICE_CALL_END_CAUSE_ALERT_STOP = 10,
82 E_QL_MCM_VOICE_CALL_END_CAUSE_CLIENT_END = 11,
83 E_QL_MCM_VOICE_CALL_END_CAUSE_ACTIVATION = 12,
84 E_QL_MCM_VOICE_CALL_END_CAUSE_MC_ABORT = 13,
85 E_QL_MCM_VOICE_CALL_END_CAUSE_MAX_ACCESS_PROBE = 14,
86 E_QL_MCM_VOICE_CALL_END_CAUSE_PSIST_N = 15,
87 E_QL_MCM_VOICE_CALL_END_CAUSE_UIM_NOT_PRESENT = 16,
88 E_QL_MCM_VOICE_CALL_END_CAUSE_ACC_IN_PROG = 17,
89 E_QL_MCM_VOICE_CALL_END_CAUSE_ACC_FAIL = 18,
90 E_QL_MCM_VOICE_CALL_END_CAUSE_RETRY_ORDER = 19,
91 E_QL_MCM_VOICE_CALL_END_CAUSE_CCS_NOT_SUPPORTED_BY_BS = 20,
92 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_RESPONSE_FROM_BS = 21,
93 E_QL_MCM_VOICE_CALL_END_CAUSE_REJECTED_BY_BS = 22,
94 E_QL_MCM_VOICE_CALL_END_CAUSE_INCOMPATIBLE = 23,
95 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_BLOCK = 24,
96 E_QL_MCM_VOICE_CALL_END_CAUSE_ALREADY_IN_TC = 25,
97 E_QL_MCM_VOICE_CALL_END_CAUSE_EMERGENCY_FLASHED = 26,
98 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_CALL_ORIG_DURING_GPS = 27,
99 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_CALL_ORIG_DURING_SMS = 28,
100 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_CALL_ORIG_DURING_DATA= 29,
101 E_QL_MCM_VOICE_CALL_END_CAUSE_REDIR_OR_HANDOFF = 30,
102 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_BLOCK_ALL = 31,
103 E_QL_MCM_VOICE_CALL_END_CAUSE_OTASP_SPC_ERR = 32,
104 E_QL_MCM_VOICE_CALL_END_CAUSE_IS707B_MAX_ACC = 33,
105 E_QL_MCM_VOICE_CALL_END_CAUSE_ACC_FAIL_REJ_ORD = 34,
106 E_QL_MCM_VOICE_CALL_END_CAUSE_ACC_FAIL_RETRY_ORD = 35,
107 E_QL_MCM_VOICE_CALL_END_CAUSE_TIMEOUT_T42 = 36,
108 E_QL_MCM_VOICE_CALL_END_CAUSE_TIMEOUT_T40 = 37,
109 E_QL_MCM_VOICE_CALL_END_CAUSE_SRV_INIT_FAIL = 38,
110 E_QL_MCM_VOICE_CALL_END_CAUSE_T50_EXP = 39,
111 E_QL_MCM_VOICE_CALL_END_CAUSE_T51_EXP = 40,
112 E_QL_MCM_VOICE_CALL_END_CAUSE_RL_ACK_TIMEOUT = 41,
113 E_QL_MCM_VOICE_CALL_END_CAUSE_BAD_FL = 42,
114 E_QL_MCM_VOICE_CALL_END_CAUSE_TRM_REQ_FAIL = 43,
115 E_QL_MCM_VOICE_CALL_END_CAUSE_TIMEOUT_T41 = 44,
116 E_QL_MCM_VOICE_CALL_END_CAUSE_INCOM_REJ = 45,
117 E_QL_MCM_VOICE_CALL_END_CAUSE_SETUP_REJ = 46,
118 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_END = 47,
119 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_FUNDS = 48,
120 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_GW_SRV = 49,
121 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_CDMA_SRV = 50,
122 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_FULL_SRV = 51,
123 E_QL_MCM_VOICE_CALL_END_CAUSE_MAX_PS_CALLS = 52,
124 E_QL_MCM_VOICE_CALL_END_CAUSE_UNKNOWN_SUBSCRIBER = 53,
125 E_QL_MCM_VOICE_CALL_END_CAUSE_ILLEGAL_SUBSCRIBER = 54,
126 E_QL_MCM_VOICE_CALL_END_CAUSE_BEARER_SERVICE_NOT_PROVISIONED= 55,
127 E_QL_MCM_VOICE_CALL_END_CAUSE_TELE_SERVICE_NOT_PROVISIONED = 56,
128 E_QL_MCM_VOICE_CALL_END_CAUSE_ILLEGAL_EQUIPMENT = 57,
129 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_BARRED = 58,
130 E_QL_MCM_VOICE_CALL_END_CAUSE_ILLEGAL_SS_OPERATION = 59,
131 E_QL_MCM_VOICE_CALL_END_CAUSE_SS_ERROR_STATUS = 60,
132 E_QL_MCM_VOICE_CALL_END_CAUSE_SS_NOT_AVAILABLE = 61,
133 E_QL_MCM_VOICE_CALL_END_CAUSE_SS_SUBSCRIPTION_VIOLATION = 62,
134 E_QL_MCM_VOICE_CALL_END_CAUSE_SS_INCOMPATIBILITY = 63,
135 E_QL_MCM_VOICE_CALL_END_CAUSE_FACILITY_NOT_SUPPORTED = 64,
136 E_QL_MCM_VOICE_CALL_END_CAUSE_ABSENT_SUBSCRIBER = 65,
137 E_QL_MCM_VOICE_CALL_END_CAUSE_SHORT_TERM_DENIAL = 66,
138 E_QL_MCM_VOICE_CALL_END_CAUSE_LONG_TERM_DENIAL = 67,
139 E_QL_MCM_VOICE_CALL_END_CAUSE_SYSTEM_FAILURE = 68,
140 E_QL_MCM_VOICE_CALL_END_CAUSE_DATA_MISSING = 69,
141 E_QL_MCM_VOICE_CALL_END_CAUSE_UNEXPECTED_DATA_VALUE = 70,
142 E_QL_MCM_VOICE_CALL_END_CAUSE_PWD_REGISTRATION_FAILURE = 71,
143 E_QL_MCM_VOICE_CALL_END_CAUSE_NEGATIVE_PWD_CHECK = 72,
144 E_QL_MCM_VOICE_CALL_END_CAUSE_NUM_OF_PWD_ATTEMPTS_VIOLATION = 73,
145 E_QL_MCM_VOICE_CALL_END_CAUSE_POSITION_METHOD_FAILURE = 74,
146 E_QL_MCM_VOICE_CALL_END_CAUSE_UNKNOWN_ALPHABET = 75,
147 E_QL_MCM_VOICE_CALL_END_CAUSE_USSD_BUSY = 76,
148 E_QL_MCM_VOICE_CALL_END_CAUSE_REJECTED_BY_USER = 77,
149 E_QL_MCM_VOICE_CALL_END_CAUSE_REJECTED_BY_NETWORK = 78,
150 E_QL_MCM_VOICE_CALL_END_CAUSE_DEFLECTION_TO_SERVED_SUBSCRIBER = 79,
151 E_QL_MCM_VOICE_CALL_END_CAUSE_SPECIAL_SERVICE_CODE = 80,
152 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_DEFLECTED_TO_NUMBER = 81,
153 E_QL_MCM_VOICE_CALL_END_CAUSE_MPTY_PARTICIPANTS_EXCEEDED= 82,
154 E_QL_MCM_VOICE_CALL_END_CAUSE_RESOURCES_NOT_AVAILABLE = 83,
155 E_QL_MCM_VOICE_CALL_END_CAUSE_UNASSIGNED_NUMBER = 84,
156 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_ROUTE_TO_DESTINATION = 85,
157 E_QL_MCM_VOICE_CALL_END_CAUSE_CHANNEL_UNACCEPTABLE = 86,
158 E_QL_MCM_VOICE_CALL_END_CAUSE_OPERATOR_DETERMINED_BARRING = 87,
159 E_QL_MCM_VOICE_CALL_END_CAUSE_NORMAL_CALL_CLEARING = 88,
160 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_BUSY = 89,
161 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_USER_RESPONDING = 90,
162 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_ALERTING_NO_ANSWER = 91,
163 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_REJECTED = 92,
164 E_QL_MCM_VOICE_CALL_END_CAUSE_NUMBER_CHANGED = 93,
165 E_QL_MCM_VOICE_CALL_END_CAUSE_PREEMPTION = 94,
166 E_QL_MCM_VOICE_CALL_END_CAUSE_DESTINATION_OUT_OF_ORDER = 95,
167 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_NUMBER_FORMAT = 96,
168 E_QL_MCM_VOICE_CALL_END_CAUSE_FACILITY_REJECTED = 97,
169 E_QL_MCM_VOICE_CALL_END_CAUSE_RESP_TO_STATUS_ENQUIRY = 98,
170 E_QL_MCM_VOICE_CALL_END_CAUSE_NORMAL_UNSPECIFIED = 99,
171 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_CIRCUIT_OR_CHANNEL_AVAILABLE = 100,
172 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_OUT_OF_ORDER = 101,
173 E_QL_MCM_VOICE_CALL_END_CAUSE_TEMPORARY_FAILURE = 102,
174 E_QL_MCM_VOICE_CALL_END_CAUSE_SWITCHING_EQUIPMENT_CONGESTION = 103,
175 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_INFORMATION_DISCARDED = 104,
176 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUESTED_CIRCUIT_OR_CHANNEL_NOT_AVAILABLE = 105,
177 E_QL_MCM_VOICE_CALL_END_CAUSE_RESOURCES_UNAVAILABLE_OR_UNSPECIFIED = 106,
178 E_QL_MCM_VOICE_CALL_END_CAUSE_QOS_UNAVAILABLE = 107,
179 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUESTED_FACILITY_NOT_SUBSCRIBED = 108,
180 E_QL_MCM_VOICE_CALL_END_CAUSE_INCOMING_CALLS_BARRED_WITHIN_CUG = 109,
181 E_QL_MCM_VOICE_CALL_END_CAUSE_BEARER_CAPABILITY_NOT_AUTH = 110,
182 E_QL_MCM_VOICE_CALL_END_CAUSE_BEARER_CAPABILITY_UNAVAILABLE = 111,
183 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVICE_OPTION_NOT_AVAILABLE = 112,
184 E_QL_MCM_VOICE_CALL_END_CAUSE_ACM_LIMIT_EXCEEDED = 113,
185 E_QL_MCM_VOICE_CALL_END_CAUSE_BEARER_SERVICE_NOT_IMPLEMENTED = 114,
186 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUESTED_FACILITY_NOT_IMPLEMENTED= 115,
187 E_QL_MCM_VOICE_CALL_END_CAUSE_ONLY_DIGITAL_INFORMATION_BEARER_AVAILABLE = 116,
188 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVICE_OR_OPTION_NOT_IMPLEMENTED = 117,
189 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_TRANSACTION_IDENTIFIER = 118,
190 E_QL_MCM_VOICE_CALL_END_CAUSE_USER_NOT_MEMBER_OF_CUG = 119,
191 E_QL_MCM_VOICE_CALL_END_CAUSE_INCOMPATIBLE_DESTINATION = 120,
192 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_TRANSIT_NW_SELECTION = 121,
193 E_QL_MCM_VOICE_CALL_END_CAUSE_SEMANTICALLY_INCORRECT_MESSAGE = 122,
194 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_MANDATORY_INFORMATION = 123,
195 E_QL_MCM_VOICE_CALL_END_CAUSE_MESSAGE_TYPE_NON_IMPLEMENTED = 124,
196 E_QL_MCM_VOICE_CALL_END_CAUSE_MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 125,
197 E_QL_MCM_VOICE_CALL_END_CAUSE_INFORMATION_ELEMENT_NON_EXISTENT = 126,
198 E_QL_MCM_VOICE_CALL_END_CAUSE_CONDITONAL_IE_ERROR = 127,
199 E_QL_MCM_VOICE_CALL_END_CAUSE_MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 128,
200 E_QL_MCM_VOICE_CALL_END_CAUSE_RECOVERY_ON_TIMER_EXPIRED = 129,
201 E_QL_MCM_VOICE_CALL_END_CAUSE_PROTOCOL_ERROR_UNSPECIFIED = 130,
202 E_QL_MCM_VOICE_CALL_END_CAUSE_INTERWORKING_UNSPECIFIED = 131,
203 E_QL_MCM_VOICE_CALL_END_CAUSE_OUTGOING_CALLS_BARRED_WITHIN_CUG = 132,
204 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_CUG_SELECTION = 133,
205 E_QL_MCM_VOICE_CALL_END_CAUSE_UNKNOWN_CUG_INDEX = 134,
206 E_QL_MCM_VOICE_CALL_END_CAUSE_CUG_INDEX_INCOMPATIBLE = 135,
207 E_QL_MCM_VOICE_CALL_END_CAUSE_CUG_CALL_FAILURE_UNSPECIFIED = 136,
208 E_QL_MCM_VOICE_CALL_END_CAUSE_CLIR_NOT_SUBSCRIBED = 137,
209 E_QL_MCM_VOICE_CALL_END_CAUSE_CCBS_POSSIBLE = 138,
210 E_QL_MCM_VOICE_CALL_END_CAUSE_CCBS_NOT_POSSIBLE = 139,
211 E_QL_MCM_VOICE_CALL_END_CAUSE_IMSI_UNKNOWN_IN_HLR = 140,
212 E_QL_MCM_VOICE_CALL_END_CAUSE_ILLEGAL_MS = 141,
213 E_QL_MCM_VOICE_CALL_END_CAUSE_IMSI_UNKNOWN_IN_VLR = 142,
214 E_QL_MCM_VOICE_CALL_END_CAUSE_IMEI_NOT_ACCEPTED = 143,
215 E_QL_MCM_VOICE_CALL_END_CAUSE_ILLEGAL_ME = 144,
216 E_QL_MCM_VOICE_CALL_END_CAUSE_PLMN_NOT_ALLOWED = 145,
217 E_QL_MCM_VOICE_CALL_END_CAUSE_LOCATION_AREA_NOT_ALLOWED = 146,
218 E_QL_MCM_VOICE_CALL_END_CAUSE_ROAMING_NOT_ALLOWED_IN_THIS_LOCATION_AREA = 147,
219 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_SUITABLE_CELLS_IN_LOCATION_AREA= 148,
220 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_FAILURE = 149,
221 E_QL_MCM_VOICE_CALL_END_CAUSE_MAC_FAILURE = 150,
222 E_QL_MCM_VOICE_CALL_END_CAUSE_SYNCH_FAILURE = 151,
223 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_CONGESTION = 152,
224 E_QL_MCM_VOICE_CALL_END_CAUSE_GSM_AUTHENTICATION_UNACCEPTABLE = 153,
225 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVICE_NOT_SUBSCRIBED = 154,
226 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVICE_TEMPORARILY_OUT_OF_ORDER = 155,
227 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_CANNOT_BE_IDENTIFIED = 156,
228 E_QL_MCM_VOICE_CALL_END_CAUSE_INCORRECT_SEMANTICS_IN_MESSAGE = 157,
229 E_QL_MCM_VOICE_CALL_END_CAUSE_MANDATORY_INFORMATION_INVALID = 158,
230 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_FAILURE = 159,
231 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_SIM = 160,
232 E_QL_MCM_VOICE_CALL_END_CAUSE_WRONG_STATE = 161,
233 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_CLASS_BLOCKED = 162,
234 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_RESOURCES = 163,
235 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_USER_DATA = 164,
236 E_QL_MCM_VOICE_CALL_END_CAUSE_TIMER_T3230_EXPIRED = 165,
237 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_CELL_AVAILABLE = 166,
238 E_QL_MCM_VOICE_CALL_END_CAUSE_ABORT_MSG_RECEIVED = 167,
239 E_QL_MCM_VOICE_CALL_END_CAUSE_RADIO_LINK_LOST = 168,
240 E_QL_MCM_VOICE_CALL_END_CAUSE_TIMER_T303_EXPIRED = 169,
241 E_QL_MCM_VOICE_CALL_END_CAUSE_CNM_MM_REL_PENDING = 170,
242 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_RR_REL_IND = 171,
243 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_RR_RANDOM_ACCESS_FAILURE = 172,
244 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_RRC_REL_IND = 173,
245 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_RRC_CLOSE_SESSION_IND = 174,
246 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_RRC_OPEN_SESSION_FAILURE = 175,
247 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_LOW_LEVEL_FAIL = 176,
248 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_LOW_LEVEL_FAIL_REDIAL_NOT_ALLOWED = 177,
249 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_LOW_LEVEL_IMMED_RETRY = 178,
250 E_QL_MCM_VOICE_CALL_END_CAUSE_ACCESS_STRATUM_REJ_ABORT_RADIO_UNAVAILABLE = 179,
251 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVICE_OPTION_NOT_SUPPORTED = 180,
252 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_UL_DATA_CNF_FAILURE_TXN = 181,
253 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_UL_DATA_CNF_FAILURE_HO = 182,
254 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_UL_DATA_CNF_FAILURE_CONN_REL = 183,
255 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_UL_DATA_CNF_FAILURE_RLF = 184,
256 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_UL_DATA_CNF_FAILURE_CTRL_NOT_CONN = 185,
257 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_SUCCESS = 186,
258 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE = 187,
259 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_ABORTED = 188,
260 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_ACCESS_BARRED = 189,
261 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_CELL_RESEL = 190,
262 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_CONFIG_FAILURE = 191,
263 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_TIMER_EXPIRED = 192,
264 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_LINK_FAILURE = 193,
265 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_NOT_CAMPED = 194,
266 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_SI_FAILURE = 195,
267 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_EST_FAILURE_CONN_REJECT = 196,
268 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_NORMAL = 197,
269 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_RLF = 198,
270 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_CRE_FAILURE = 199,
271 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_OOS_DURING_CRE = 200,
272 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_ABORTED = 201,
273 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_SIB_READ_ERROR = 202,
274 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_CONN_REL_ABORTED_IRAT_SUCCESS = 203,
275 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_LRRC_RADIO_LINK_FAILURE = 204,
276 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_DETACH_WITH_REATTACH_LTE_NW_DETACH = 205,
277 E_QL_MCM_VOICE_CALL_END_CAUSE_AS_REJ_DETACH_WITH_OUT_REATTACH_LTE_NW_DETACH = 206,
278 E_QL_MCM_VOICE_CALL_END_CAUSE_BAD_REQ_WAIT_INVITE = 207,
279 E_QL_MCM_VOICE_CALL_END_CAUSE_BAD_REQ_WAIT_REINVITE = 208,
280 E_QL_MCM_VOICE_CALL_END_CAUSE_INVALID_REMOTE_URI = 209,
281 E_QL_MCM_VOICE_CALL_END_CAUSE_REMOTE_UNSUPP_MEDIA_TYPE = 210,
282 E_QL_MCM_VOICE_CALL_END_CAUSE_PEER_NOT_REACHABLE = 211,
283 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_NO_RESP_TIME_OUT = 212,
284 E_QL_MCM_VOICE_CALL_END_CAUSE_NETWORK_NO_RESP_HOLD_FAIL = 213,
285 E_QL_MCM_VOICE_CALL_END_CAUSE_DATA_CONNECTION_LOST = 214,
286 E_QL_MCM_VOICE_CALL_END_CAUSE_UPGRADE_DOWNGRADE_REJ = 215,
287 E_QL_MCM_VOICE_CALL_END_CAUSE_SIP_403_FORBIDDEN = 216,
288 E_QL_MCM_VOICE_CALL_END_CAUSE_NO_NETWORK_RESP = 217,
289 E_QL_MCM_VOICE_CALL_END_CAUSE_UPGRADE_DOWNGRADE_FAILED = 218,
290 E_QL_MCM_VOICE_CALL_END_CAUSE_UPGRADE_DOWNGRADE_CANCELLED = 219,
291 E_QL_MCM_VOICE_CALL_END_CAUSE_SSAC_REJECT = 220,
292 E_QL_MCM_VOICE_CALL_END_CAUSE_THERMAL_EMERGENCY = 221,
293 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_SOFT_FAILURE = 222,
294 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_HARD_FAILURE = 223,
295 E_QL_MCM_VOICE_CALL_END_CAUSE_CONNECTION_EST_FAILURE = 224,
296 E_QL_MCM_VOICE_CALL_END_CAUSE_CONNECTION_FAILURE = 225,
297 E_QL_MCM_VOICE_CALL_END_CAUSE_RRC_CONN_REL_NO_MT_SETUP = 226,
298 E_QL_MCM_VOICE_CALL_END_CAUSE_ESR_FAILURE = 227,
299 E_QL_MCM_VOICE_CALL_END_CAUSE_MT_CSFB_NO_RESPONSE_FROM_NW = 228,
300 E_QL_MCM_VOICE_CALL_END_CAUSE_BUSY_EVERYWHERE = 229,
301 E_QL_MCM_VOICE_CALL_END_CAUSE_ANSWERED_ELSEWHERE = 230,
302 E_QL_MCM_VOICE_CALL_END_CAUSE_RLF_DURING_CC_DISCONNECT = 231,
303 E_QL_MCM_VOICE_CALL_END_CAUSE_TEMP_REDIAL_ALLOWED = 232,
304 E_QL_MCM_VOICE_CALL_END_CAUSE_PERM_REDIAL_NOT_NEEDED = 233,
305 E_QL_MCM_VOICE_CALL_END_CAUSE_MERGED_TO_CONFERENCE = 234,
306 E_QL_MCM_VOICE_CALL_END_CAUSE_LOW_BATTERY = 235,
307 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_DEFLECTED = 236,
308 E_QL_MCM_VOICE_CALL_END_CAUSE_RTP_RTCP_TIMEOUT = 237,
309 E_QL_MCM_VOICE_CALL_END_CAUSE_RINGING_RINGBACK_TIMEOUT = 238,
310 E_QL_MCM_VOICE_CALL_END_CAUSE_REG_RESTORATION = 239,
311 E_QL_MCM_VOICE_CALL_END_CAUSE_CODEC_ERROR = 240,
312 E_QL_MCM_VOICE_CALL_END_CAUSE_UNSUPPORTED_SDP = 241,
313 E_QL_MCM_VOICE_CALL_END_CAUSE_RTP_FAILURE = 242,
314 E_QL_MCM_VOICE_CALL_END_CAUSE_QoS_FAILURE = 243,
315 E_QL_MCM_VOICE_CALL_END_CAUSE_MULTIPLE_CHOICES = 244,
316 E_QL_MCM_VOICE_CALL_END_CAUSE_MOVED_PERMANENTLY = 245,
317 E_QL_MCM_VOICE_CALL_END_CAUSE_MOVED_TEMPORARILY = 246,
318 E_QL_MCM_VOICE_CALL_END_CAUSE_USE_PROXY = 247,
319 E_QL_MCM_VOICE_CALL_END_CAUSE_ALTERNATE_SERVICE = 248,
320 E_QL_MCM_VOICE_CALL_END_CAUSE_ALTERNATE_EMERGENCY_CALL = 249,
321 E_QL_MCM_VOICE_CALL_END_CAUSE_UNAUTHORIZED = 250,
322 E_QL_MCM_VOICE_CALL_END_CAUSE_PAYMENT_REQUIRED = 251,
323 E_QL_MCM_VOICE_CALL_END_CAUSE_METHOD_NOT_ALLOWED = 252,
324 E_QL_MCM_VOICE_CALL_END_CAUSE_NOT_ACCEPTABLE = 253,
325 E_QL_MCM_VOICE_CALL_END_CAUSE_PROXY_AUTHENTICATION_REQUIRED = 254,
326 E_QL_MCM_VOICE_CALL_END_CAUSE_GONE = 255,
327 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUEST_ENTITY_TOO_LARGE = 256,
328 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUEST_URI_TOO_LARGE = 257,
329 E_QL_MCM_VOICE_CALL_END_CAUSE_UNSUPPORTED_URI_SCHEME = 258,
330 E_QL_MCM_VOICE_CALL_END_CAUSE_BAD_EXTENSION = 259,
331 E_QL_MCM_VOICE_CALL_END_CAUSE_EXTENSION_REQUIRED = 260,
332 E_QL_MCM_VOICE_CALL_END_CAUSE_INTERVAL_TOO_BRIEF = 261,
333 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_OR_TRANS_DOES_NOT_EXIST = 262,
334 E_QL_MCM_VOICE_CALL_END_CAUSE_LOOP_DETECTED = 263,
335 E_QL_MCM_VOICE_CALL_END_CAUSE_TOO_MANY_HOPS = 264,
336 E_QL_MCM_VOICE_CALL_END_CAUSE_ADDRESS_INCOMPLETE = 265,
337 E_QL_MCM_VOICE_CALL_END_CAUSE_AMBIGUOUS = 266,
338 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUEST_TERMINATED = 267,
339 E_QL_MCM_VOICE_CALL_END_CAUSE_NOT_ACCEPTABLE_HERE = 268,
340 E_QL_MCM_VOICE_CALL_END_CAUSE_REQUEST_PENDING = 269,
341 E_QL_MCM_VOICE_CALL_END_CAUSE_UNDECIPHERABLE = 270,
342 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVER_INTERNAL_ERROR = 271,
343 E_QL_MCM_VOICE_CALL_END_CAUSE_NOT_IMPLEMENTED = 272,
344 E_QL_MCM_VOICE_CALL_END_CAUSE_BAD_GATEWAY = 273,
345 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVER_TIME_OUT = 274,
346 E_QL_MCM_VOICE_CALL_END_CAUSE_VERSION_NOT_SUPPORTED = 275,
347 E_QL_MCM_VOICE_CALL_END_CAUSE_MESSAGE_TOO_LARGE = 276,
348 E_QL_MCM_VOICE_CALL_END_CAUSE_DOES_NOT_EXIST_ANYWHERE = 277,
349 E_QL_MCM_VOICE_CALL_END_CAUSE_SESS_DESCR_NOT_ACCEPTABLE = 278,
350 E_QL_MCM_VOICE_CALL_END_CAUSE_SRVCC_END_CALL = 279,
351 E_QL_MCM_VOICE_CALL_END_CAUSE_INTERNAL_ERROR = 280,
352 E_QL_MCM_VOICE_CALL_END_CAUSE_SERVER_UNAVAILABLE = 281,
353 E_QL_MCM_VOICE_CALL_END_CAUSE_PRECONDITION_FAILURE = 282,
354 E_QL_MCM_VOICE_CALL_END_CAUSE_DRVCC_IN_PROG = 283,
355 E_QL_MCM_VOICE_CALL_END_CAUSE_DRVCC_END_CALL = 284,
356 E_QL_MCM_VOICE_CALL_END_CAUSE_CS_HARD_FAILURE = 285,
357 E_QL_MCM_VOICE_CALL_END_CAUSE_CS_ACQ_FAILURE = 286,
358 E_QL_MCM_VOICE_CALL_END_CAUSE_FALLBACK_TO_CS = 287,
359 E_QL_MCM_VOICE_CALL_END_CAUSE_DEAD_BATTERY = 288,
360 E_QL_MCM_VOICE_CALL_END_CAUSE_HO_NOT_FEASIBLE = 289,
361 E_QL_MCM_VOICE_CALL_END_CAUSE_PDN_DISCONNECTED = 290,
362 E_QL_MCM_VOICE_CALL_END_CAUSE_REJECTED_ELSEWHERE = 291,
363 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_PULLED = 292,
364 E_QL_MCM_VOICE_CALL_END_CAUSE_CALL_PULL_OUT_OF_SYNC = 293,
365 E_QL_MCM_VOICE_CALL_END_CAUSE_HOLD_RESUME_FAILED = 294,
366 E_QL_MCM_VOICE_CALL_END_CAUSE_HOLD_RESUME_CANCELED = 295,
367 E_QL_MCM_VOICE_CALL_END_CAUSE_REINVITE_COLLISION = 296,
368 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_MSG_INVAILD = 297,
369 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_MSG_IGNORE = 298,
370 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_ACQ_FAIL = 299,
371 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_REL_ORDER= 300,
372 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_REORDER = 301,
373 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_INTERCEPT_ORDER = 302,
374 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_NORMAL = 303,
375 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_SO_REJ = 304,
376 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAIL_CALL_REL_OTASP_SPC_ERR = 305,
377 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_SRCH_TT_FAIL = 306,
378 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_TCH_INIT_FAIL = 307,
379 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_FAILURE_USER_CALL_END = 308,
380 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_FAILURE_RETRY_EXHAUST = 309,
381 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_FAILURE_CALL_REL_REG_REJ = 310,
382 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_FAILURE_FAILURE_CALL_REL_NW_REL_ODR= 311,
383 E_QL_MCM_VOICE_CALL_END_CAUSE_1XCSFB_HO_FAILURE = 312,
384 E_QL_MCM_VOICE_CALL_END_CAUSE_EMM_REJ_TIMER_T3417_EXT_EXP = 313,
385 E_QL_MCM_VOICE_CALL_END_CAUSE_EMM_REJ_TIMER_T3417_EXP = 314,
386 E_QL_MCM_VOICE_CALL_END_CAUSE_EMM_REJ_SERVICE_REQ_FAILURE_LTE_NW_REJECT = 315,
387 E_QL_MCM_VOICE_CALL_END_CAUSE_EMM_REJ_SERVICE_REQ_FAILURE_CS_DOMAIN_NOT_AVAILABLE = 316,
388 E_QL_MCM_VOICE_CALL_END_CAUSE_EMM_REJ = 317,
389} ql_mcm_voice_call_end_reason_t;
390
391typedef enum
392{
393 E_QL_MCM_VOICE_UUS_TYPE1_IMPLICIT, //!< Type 1 implicit.
394 E_QL_MCM_VOICE_UUS_TYPE1_REQUIRED, //!< Type 1 required.
395 E_QL_MCM_VOICE_UUS_TYPE1_NOT_REQUIRED, //!< Type 1 not required.
396 E_QL_MCM_VOICE_UUS_TYPE2_REQUIRED, //!< Type 2 required.
397 E_QL_MCM_VOICE_UUS_TYPE2_NOT_REQUIRED, //!< Type 2 not required.
398 E_QL_MCM_VOICE_UUS_TYPE3_REQUIRED, //!< Type 3 required.
399 E_QL_MCM_VOICE_UUS_TYPE3_NOT_REQUIRED, //!< Type 3 not required.
400 E_QL_MCM_VOICE_UUS_TYPE_DATA //!< Data.
401} ql_mcm_voice_uus_type_t;
402
403typedef enum
404{
405 E_QL_MCM_VOICE_UUS_DCS_IA5, //!< IA5.
406 E_QL_MCM_VOICE_UUS_DCS_OHLP, //!< OHLP.
407 E_QL_MCM_VOICE_UUS_DCS_USP, //!< USP.
408 E_QL_MCM_VOICE_UUS_DCS_X244 //!< x244.
409} ql_mcm_voice_uus_dcs_type_t; //!< UUS data coding scheme.
410
411
412typedef struct
413{
414 ql_mcm_voice_uus_type_t type; /**< UUS type; range -- 0 to 6.*/
415 ql_mcm_voice_uus_dcs_type_t dcs; /**< UUS data coding scheme; range -- 0 to 4.*/
416 uint32_t uus_data_len; /**< Must be set to the number of elements in uus_data. */
417 uint8_t uus_data[QL_MCM_MAX_UUS_DATA];/**< Voice call UUS data.*/
418} ql_mcm_voice_uusdata_t;
419
420typedef struct
421{
422 uint32_t call_id; /**< Call ID associated with this call.*/
423 ql_mcm_voice_call_state_t state; /**< Current call state (mcm_voice_call_state).*/
424 ql_mcm_voice_tech_t tech; /**< Technology (mcm_tech).*/
425 char number[QL_MCM_MAX_PHONE_NUMBER + 1]; /**< Phone number.*/
426 ql_mcm_voice_call_number_presentation_type_t number_presentation; /**< Number presentation.*/
427 ql_mcm_voice_call_direction_type_t direction; /**< Voice call direction.*/
428 uint8_t uusdata_valid; /**< Indicates whether UUS data is valid.*/
429 ql_mcm_voice_uusdata_t uusdata; /**< User-to-user signaling data.*/
430 uint8_t call_end_reason_valid; /**< Indicates whether call_end_reason is valid.*/
431 ql_mcm_voice_call_end_reason_t call_end_reason;
432} ql_mcm_voice_call_record_t;
433
434typedef struct
435{
436 uint32_t calls_len; /**< Must be set to # of elements in calls */
437 ql_mcm_voice_call_record_t calls[QL_MCM_MAX_VOICE_CALLS]; /**< Calls.*/
438} ql_mcm_voice_calls_state_t;
439
440
441typedef enum
442{
443 E_QL_MCM_VOICE_CALL_FORWARDING_DISABLED = 0, /**< Disabled. */
444 E_QL_MCM_VOICE_CALL_FORWARDING_ENABLED = 1, /**< Enabled. */
445} QL_MCM_VOICE_CALL_FORWARDING_STATUS_T;
446
447typedef enum
448{
449 E_QL_MCM_VOICE_CALL_FORWARDING_TYPE_VOICE = 0, /**< Voice. */
450 E_QL_MCM_VOICE_CALL_FORWARDING_TYPE_DATA = 1, /**< Data. */
451 E_QL_MCM_VOICE_CALL_FORWARDING_TYPE_VOICE_DATA = 2, /**< Voice and data. */
452} QL_MCM_VOICE_CALL_FORWARDING_TYPE_T;
453
454typedef struct
455{
456 QL_MCM_VOICE_CALL_FORWARDING_TYPE_T type; /**< Call forwarding type.*/
457 char number[QL_MCM_MAX_PHONE_NUMBER + 1]; /**< Call forwarding number.*/
458} QL_MCM_VOICE_CALL_FORWARDING_INFO_T; /* Type */
459
460typedef struct
461{
462 QL_MCM_VOICE_CALL_FORWARDING_STATUS_T status; /**< Call forwarding status.*/
463 uint32_t info_len; /**< Must be set to # of elements in info */
464 QL_MCM_VOICE_CALL_FORWARDING_INFO_T info[QL_MCM_MAX_CALL_FORWARDING_INFO];/**< Call forwarding information.*/
465} ql_mcm_voice_call_forwarding_status_list_t; /* Message */
466
467typedef enum
468{
469 E_QL_MCM_VOICE_SERVICE_UNKOWN = 0,
470 E_QL_MCM_VOICE_SERVICE_REGISTER = 1, /**< Register. */
471 E_QL_MCM_VOICE_SERVICE_ERASE = 2, /**< Erase. */
472} E_QL_MCM_VOICE_CALL_SERVICE_T;
473
474typedef enum
475{
476 E_QL_MCM_VOICE_CALL_FORWARD_UNCONDITIONALLY = 0, /**< Unconditional call forwarding. */
477 E_QL_MCM_VOICE_CALL_FORWARD_MOBILEBUSY = 1, /**< Forward when the mobile device is busy. */
478 E_QL_MCM_VOICE_CALL_FORWARD_NOREPLY = 2, /**< Forward when there is no reply. */
479 E_QL_MCM_VOICE_CALL_FORWARD_UNREACHABLE = 3, /**< Forward when the call is unreachable. */
480 E_QL_MCM_VOICE_CALL_FORWARD_ALLFORWARDING = 4, /**< All forwarding(0-3). */
481 E_QL_MCM_VOICE_CALL_FORWARD_ALLCONDITIONAL = 5, /**< All conditional forwarding(1-3). */
482} E_QL_MCM_VOICE_CALL_FORWARDING_REASON_T;
483
484
485typedef enum
486{
487 E_QL_MCM_VOICE_CALL_WAITING_VOICE_ENABLED = 0, /**< Voice call waiting enabled. */
488 E_QL_MCM_VOICE_CALL_WAITING_DISABLED = 1, /**< Voice call waiting disabled. */
489} E_QL_MCM_VOICE_CALL_WAITING_SERVICE_T;
490
491typedef struct
492{
493 E_QL_MCM_VOICE_CALL_WAITING_SERVICE_T waiting_service;
494} ql_mcm_voice_call_waiting_service_t;
495
496
497
498typedef enum
499{
500 E_QL_MCM_VOICE_CLIR_INVOCATION = 0, /**< Invocation. */
501 E_QL_MCM_VOICE_CLIR_SUPPRESSION = 1, /**< Suppression. */
502} ql_mcm_voice_clir_action_t;
503
504typedef enum
505{
506 E_QL_MCM_VOICE_CLIR_NOT_PROVISIONED = 0, /**< Not provisioned. */
507 E_QL_MCM_VOICE_CLIR_PROVISIONED_PERMANENT_MODE = 1, /**< Permanently provisioned. */
508 E_QL_MCM_VOICE_CLIR_PRESENTATION_RESTRICTED = 2, /**< Restricted presentation. */
509 E_QL_MCM_VOICE_CLIR_PRESENTATION_ALLOWED = 3, /**< Allowed presentation. */
510} ql_mcm_voice_clir_presentation_t;
511
512typedef struct
513{
514 ql_mcm_voice_clir_action_t action;
515 ql_mcm_voice_clir_presentation_t presentation; /**< CLIR presentation.*/
516} ql_mcm_voice_clir_info_t;
517
518
519
520typedef enum
521{
522 E_QL_MCM_VOICE_USSD_MSG_TYPE_NEW_MESSAGE = 0, /**< Initiate a new USSD sesion with network. */
523 E_QL_MCM_VOICE_USSD_MSG_TYPE_REPLY_TO_IND = 1, /**< Reply to a USSD indication from the network. */
524} ql_mcm_voice_ussd_msg_type_t;
525
526typedef enum
527{
528 E_QL_MCM_VOICE_USSD_ENCODING_ASCII = 0, /**< ASCII coding scheme. */
529 E_QL_MCM_VOICE_USSD_ENCODING_8BIT = 1, /**< 8-bit coding scheme. */
530 E_QL_MCM_VOICE_USSD_ENCODING_UCS2 = 2, /**< UCS2. */
531} ql_mcm_voice_ussd_encoding_type_t;
532
533typedef struct
534{
535 ql_mcm_voice_ussd_msg_type_t type; /**< Whether sending a new request or a reply to indication*/
536 ql_mcm_voice_ussd_encoding_type_t encoding; /**< USSD encoding.*/
537 char ussd_string[QL_MCM_MAX_USSD_LENGTH + 1]; /**< USSD string.*/
538} ql_mcm_voice_ussd_info_t; /* Message */
539
540
541typedef enum
542{
543 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_ALLOUTGOING = 0, /**< All outgoing. */
544 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_OUTGOINGINT = 1, /**< Outgoing internal. */
545 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_OUTGOINGINTEXTOHOME = 2, /**< Outgoing external to home. */
546 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_ALLINCOMING = 3, /**< All incoming. */
547 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_INCOMINGROAMING = 4, /**< Roaming incoming. */
548 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_ALLBARRING = 5, /**< All calls are barred. */
549 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_ALLOUTGOINGBARRING = 6, /**< All outgoing calls are barred. */
550 E_QL_MCM_SIMRIL_CHANGE_CALL_BARRING_PWD_REASON_ALLINCOMINGBARRING = 7, /**< All incoming calls are barred. */
551} ql_mcm_change_call_barring_pwd_reason_t;
552
553typedef struct
554{
555 ql_mcm_change_call_barring_pwd_reason_t reason; /**< Reason for the password change. Refer to 3GPP TS 27.007 @xhyperref{S8,[S8]}, Section 7.4.*/
556 char old_pwd[QL_MCM_MAX_PASSWORD_LENGTH + 1];
557 char new_pwd[QL_MCM_MAX_PASSWORD_LENGTH + 1];
558} ql_mcm_change_call_barring_pwd_info_t; /* Message */
559
560
561typedef enum
562{
563 E_QL_MCM_SIMRIL_E911_UNKNOWN = -1, /**< E911 unknown. */
564 E_QL_MCM_SIMRIL_E911_INACTIVE = 0, /**< E911 INACTIVE. */
565 E_QL_MCM_SIMRIL_E911_ACTIVE = 1, /**< E911 ACTIVE. */
566} ql_mcm_simril_e911_state_t;
567
568typedef ql_mcm_voice_call_state_t E_QL_VOICE_CALL_STATE_T;
569
570typedef enum
571{
572 E_QL_MCM_ECALL_TEST = 0x01,
573 E_QL_MCM_ECALL_EMERGENCY = 0x02,
574 E_QL_MCM_ECALL_RECONFIG = 0x03,
575} E_QL_MCM_ECALL_VARIANT_T;
576
577typedef enum
578{
579 E_QL_MCM_VOICE_AUTO_ANSWER_ENABLE = 0, /**< Enable auto-answer. */
580 E_QL_MCM_VOICE_AUTO_ANSWER_DISABLE = 1, /**< Disable auto-answer. */
581} E_QL_MCM_VOICE_AUTO_ANSWER_T;
582
583
584//Laurence.yin-2018/04/03-QCM9XOL00004C011-P02, <[MCM-ECALL] : add ecall status ind info.>
585typedef enum
586{
587 E_QL_MCM_VOICE_UNKOWN_IND = 0,
588 E_QL_MCM_VOICE_CALL_IND,
589 E_QL_MCM_VOICE_ECALL_STATUE_IND,
590 E_QL_MCM_VOICE_ECALL_URC_IND,
591 E_QL_MCM_VOICE_ECALL_EVENT_IND,
592
593} E_QL_MCM_VOICE_IND_T;
594
595typedef enum
596{
597 E_QL_MCM_VOICE_ECALL_MSD_TRANSMISSION_STATUS_SUCCESS = 0x00, /**< Success \n */
598 E_QL_MCM_VOICE_ECALL_MSD_TRANSMISSION_STATUS_FAILURE = 0x01, /**< Generic failure */
599} E_QL_MCM_EALL_MSD_TRANSMISSION_STATUS_T;
600
601typedef enum
602{
603 E_QL_MCM_VOICE_ECALL_INACTIVE = 0,
604 E_QL_MCM_VOICE_ECALL_ORIGINATING_CALL = 1,
605 E_QL_MCM_VOICE_ECALL_IN_CALL_TRANSMITTING = 2, /**< ECALL APP TRANSMITTING */
606 E_QL_MCM_VOICE_ECALL_WATING_FOR_AL_ACK = 3,
607 E_QL_MCM_VOICE_ECALL_IN_CALL = 4,
608 E_QL_MCM_VOICE_ECALL_IDLE_ALLOW_MT_ECALL = 5,
609} E_QL_MCM_ECALL_STATE_T;
610
611typedef enum
612{
613 E_QL_MCM_VOICE_ECALL_MODE_NOMAL = 0,
614 E_QL_MCM_VOICE_ECALL_MODE_ONLY = 1,
615 E_QL_MCM_VOICE_ECALL_MODE_DEFAULT = 2
616} E_QL_MCM_ECALL_MODE_T;
617
618typedef enum
619{
620 E_QL_MCM_VOICE_ECALL_CONFIG_ENABLE = 0,
621 E_QL_MCM_VOICE_ECALL_CONFIG_VIOCECONF,
622 E_QL_MCM_VOICE_ECALL_CONFIG_MODE,
623 E_QL_MCM_VOICE_ECALL_CONFIG_PROCESSINFO,
624 E_QL_MCM_VOICE_ECALL_CONFIG_START_TIMER,
625 E_QL_MCM_VOICE_ECALL_CONFIG_HACK_TIMER,
626 E_QL_MCM_VOICE_ECALL_CONFIG_MSD_TRANSMISSION,
627 E_QL_MCM_VOICE_ECALL_CONFIG_MO_FAILR_REDIAL,
628 E_QL_MCM_VOICE_ECALL_CONFIG_DROP_REDIAL
629} E_QL_MCM_ECALL_CONFIG_T;
630
631typedef struct
632{
633 char ecall_msd[QL_MCM_MAX_ECALL_MSD]; //max msd length 140
634 uint32_t msd_len;
635 int manual;
636 E_QL_MCM_ECALL_VARIANT_T eCallModeType;
637} ql_mcm_ecall_info;
638
639typedef struct
640{
641 uint8_t enable; /* Enable or disable ecall ;0 -- Disable; 1 -- Enable */
642 uint8_t voiceconfig; /* Enable or disable to mute IVS speaker in MSD
643 0 -- Disable to mute IVS speaker automatical in MSD transmission
644 1 -- Enable to mute IVS speaker automatical in MSD transmission */
645 E_QL_MCM_ECALL_MODE_T ecallmode; /* The Ecall mode. */
646 uint8_t processinfo; /* Enable or disable to report ecall event info. 0 -- Disable; 1 -- Enable */
647 uint8_t T5; /* The timer of IVS waiting for "START". */
648 uint8_t T6; /* The timer of IVS waiting for "HACK". */
649 uint8_t T7; /* The timer of MSD transmission. */
650 uint8_t mofailredial; /* The dial fail times. */
651 uint8_t dropredial;
652} ql_mcm_ecall_config_info;
653
654
655typedef struct
656{
657 uint8_t call_id; /**< call_id.*/
658 uint8_t ecall_msd_tx_status_valid;
659 E_QL_MCM_EALL_MSD_TRANSMISSION_STATUS_T ecall_msd_tx_status;
660} ql_mcm_voice_ecall_status_t; /* Message */
661
662typedef struct
663{
664 uint8_t call_id; /**< call_id.*/
665 uint32_t ecall_urc_event_len; /**< Must be set to # of elements in ecall_urc_event */
666 char ecall_urc_event[QL_MCM_MAX_ECALL_URC_EVENT_LENGTH];
667} ql_mcm_voice_ecall_urc_t;
668
669typedef enum
670{
671 E_QL_MCM_VOICE_ECALL_EVENT_FAIL_START_TIMEOUT = 1, /**< Wait for START timeout. */
672 E_QL_MCM_VOICE_ECALL_EVENT_FAIL_HACK_TIMEOUT = 2, /**< Wait for HACK timeout. */
673 E_QL_MCM_VOICE_ECALL_EVENT_FAIL_MSD_TRANSMISSION_TIMEOUT = 3, /**< MSD transmission timeout. */
674 E_QL_MCM_VOICE_ECALL_EVENT_FAIL_IVS_RESET_TIMEOUT = 4 /**< IVS reset. */
675} E_QL_MCM_VOICE_ECALL_EVENT_FAIL_T;
676
677typedef enum
678{
679 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_IVS_START_RECEIVED_MSD = 1, /**< IVS Link Layer receives START message and starts to send MSD */
680 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_IVS_NACK_RECEIVED = 2, /**< IVS Link Layer receives NACK message. */
681 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_IVS_ACK_RECEIVED = 3, /**< IVS Link Layer receives the first LACK message. */
682 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_IVS_TX_COMPLETED = 4, /**< IVS MSD transmission is complete. */
683 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_IVS_HLACK_RECEIVED = 5 /**< IVS Link Layer receives first HACK message. */
684} E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_T;
685
686typedef enum
687{
688 E_QL_MCM_VOICE_ECALL_EVENT_MSDUPDATE_IVS_UPDATING_MSD = 0, /**< Indicates MSD has been updated. */
689 E_QL_MCM_VOICE_ECALL_EVENT_MSDUPDATE_PSAP_REQURE_UPDATE_MSD = 1, /**< Indicate timeout of updating MSD and module starts to transfer the old MSD. */
690 E_QL_MCM_VOICE_ECALL_EVENT_MSDUPDATE_IVS_UPDATE_MSD_TIMEOUT = 2 /**< Indicate to update MSD in 5 seconds. */
691} E_QL_MCM_VOICE_ECALL_EVENT_MSDUPDATE_T;
692
693typedef enum
694{
695 E_QL_MCM_VOICE_ECALL_EVENT_ECALL_ESTABLISHNG_SUCCESS = 0, /**< Establish eCall successfully. */
696 E_QL_MCM_VOICE_ECALL_EVENT_ECALL_ESTABLISHNG_FAIL = 1 /**< Establish eCall fails. */
697} E_QL_MCM_VOICE_ECALL_EVENT_ESTABLISH_T;
698
699typedef struct
700{
701 uint16_t hack_code; /**< psap hack code.*/
702} ql_mcm_voice_ecall_event_hackcode_t; /* Type */
703
704typedef struct
705{
706 uint8_t ori_remainder_times; /**< originate fail remainder times*/
707 uint16_t time; /**< the minimum time duration between the previous call attempt*/
708} ql_mcm_voice_ecall_event_originate_fail_and_redial_t; /* Type */
709
710typedef struct
711{
712 uint8_t drop_remainder_times; /**< dorp remainder times*/
713 uint16_t time; /**< the minimum time duration between the previous call attempt*/
714} ql_mcm_voice_ecall_event_drop_and_redial_t; /* Type */
715
716
717typedef struct
718{
719 uint8_t ecall_event_fails_valid;
720 E_QL_MCM_VOICE_ECALL_EVENT_FAIL_T ecall_event_fails; /**< event of eCall Failed.*/
721 uint8_t ecall_event_process_valid;
722 E_QL_MCM_VOICE_ECALL_EVENT_PROCESS_T ecall_event_process; /**< event of eCall process.*/
723 uint8_t ecall_event_msdupdate_valid;
724 E_QL_MCM_VOICE_ECALL_EVENT_MSDUPDATE_T ecall_event_msdupdate; /**< event of ecall msd update.*/
725 uint8_t ecall_event_establish_valid;
726 E_QL_MCM_VOICE_ECALL_EVENT_ESTABLISH_T ecall_event_establish; /**< event of eCall establish.*/
727 uint8_t ecall_event_hackcode_valid;
728 ql_mcm_voice_ecall_event_hackcode_t ecall_event_hackcode; /**< event of eCall hack code.*/
729 uint8_t ecall_event_ori_redial_valid;
730 ql_mcm_voice_ecall_event_originate_fail_and_redial_t ecall_event_ori_redial; /**< event of originate fail and redial.*/
731 uint8_t ecall_event_drop_redial_valid;
732 ql_mcm_voice_ecall_event_drop_and_redial_t ecall_event_drop_redial; /**< event of drop and redial.*/
733} ql_mcm_voice_ecall_event_t; /* Message */
734
735
736typedef ql_mcm_voice_calls_state_t ql_mcm_voice_call_ind;
737typedef ql_mcm_voice_ecall_status_t ql_mcm_voice_ecall_status_ind;
738typedef ql_mcm_voice_ecall_urc_t ql_mcm_voice_ecall_urc_ind;
739typedef ql_mcm_voice_ecall_event_t ql_mcm_voice_ecall_event_ind;
740
741
742
743
744/* Callback function registered via QL_Voice_Call_AddStateHandler;
745 This will be called if any stated changed of call_id
746*/
747typedef void (*QL_VoiceCall_CommonStateHandlerFunc_t)
748(
749 unsigned long message_id,
750 void *ind_data,
751 uint32_t ind_data_len
752);
753
754
755typedef uint32 voice_client_handle_type;
756
757/* Callback function registered via QL_Voice_Call_AddStateHandler;
758 This will be called if any stated changed of call_id
759*/
760typedef void (*QL_VoiceCall_StateHandlerFunc_t)
761(
762 int call_id,
763 char* phone_num,
764 E_QL_VOICE_CALL_STATE_T state,
765 void *contextPtr
766);
767
768/* Init voice module and return h_voice, this should be called before any other APIs */
769int QL_Voice_Call_Client_Init(voice_client_handle_type *ph_voice);
770
771/* DeInit voice module and release resources, this should be called at last */
772int QL_Voice_Call_Client_Deinit(voice_client_handle_type h_voice);
773
774/* Add callback function, if any call state changed, handlerPtr will be called to notify App */
775int QL_Voice_Call_AddStateHandler(voice_client_handle_type h_voice,
776 QL_VoiceCall_StateHandlerFunc_t handlerPtr,
777 void* contextPtr);
778
779/* Remove callback function, won't receive any notify anymore */
780int QL_Voice_Call_RemoveStateHandler(voice_client_handle_type h_voice);
781
782//Laurence.yin-2018/04/03-QCM9XOL00004C011-P02, <[MCM-ECALL] : add ecall status ind info.>
783/* Add callback function, if any call state changed, handlerPtr will be called to notify App */
784int QL_Voice_Call_AddCommonStateHandler(voice_client_handle_type h_voice,
785 QL_VoiceCall_CommonStateHandlerFunc_t handlerPtr);
786
787/* Remove callback function, won't receive any notify anymore */
788int QL_Voice_Call_RemoveCommonStateHandler(voice_client_handle_type h_voice);
789
790
791/* Start call and return call_id, this can be used in the later */
792int QL_Voice_Call_Start(voice_client_handle_type h_voice,
793 E_QL_VCALL_ID_T simId,
794 char* phone_number, ///< [IN] Destination identifier for the voice
795 int *call_id); ///< [OUT] call id
796
797/* End call of call_id, which returned by QL_Voice_Call_Start or callback func register via QL_Voice_Call_AddStateHandler */
798int QL_Voice_Call_End( voice_client_handle_type h_voice,
799 int call_id); ///< [IN] call id, return by QL_Voice_Start
800
801/* Answer the call of call_id, which returned by callback func register via QL_Voice_Call_AddStateHandler */
802int QL_Voice_Call_Answer(voice_client_handle_type h_voice,
803 int call_id );
804
805int QL_Voice_Call_Hold( voice_client_handle_type h_voice);
806
807int QL_Voice_Call_UnHold( voice_client_handle_type h_voice);
808
809int QL_Voice_Call_Conference( voice_client_handle_type h_voice);
810
811int QL_Voice_Call_EndConference( voice_client_handle_type h_voice);
812
813int QL_Voice_Call_Ecall(voice_client_handle_type h_voice,
814 E_QL_VCALL_ID_T simId,
815 char* phone_number,
816 ql_mcm_ecall_info ecall_info,
817 int *call_id);
818
819
820int QL_Voice_Call_SetAutoAnswer(voice_client_handle_type h_voice,
821 E_QL_MCM_VOICE_AUTO_ANSWER_T eAnswerType,
822 uint32_t uAnswerTime);
823
824int QL_Voice_Call_Ecall_HangUp(voice_client_handle_type h_voice);
825
826int QL_Voice_Call_Ecall_UpdateMsd(voice_client_handle_type h_voice,const char *msd,uint32_t msd_len);
827
828//Ecall Push caommand
829int QL_Voice_Call_Ecall_MsdPush(voice_client_handle_type h_voice,
830 E_QL_MCM_ECALL_STATE_T *ecall_state);
831
832//Get Ecall config info
833int QL_Voice_Call_Ecall_GetConfigInfo(voice_client_handle_type h_voice,
834 ql_mcm_ecall_config_info *ecall_config);
835
836int QL_Voice_Call_Ecall_SetConfigInfo(voice_client_handle_type h_voice,
837 E_QL_MCM_ECALL_CONFIG_T ecall_config_type,
838 uint8_t value);
839
840
841
842//Cancel dial
843int QL_Voice_Call_CancelDial( voice_client_handle_type h_voice);
844
845//VTS API
846int QL_Voice_Call_Dtmf( voice_client_handle_type h_voice,uint8_t digit,int call_id);
847
848
849int QL_Voice_Call_GetCallStatus
850(
851 int h_voice,
852 int call_id, // If call_id<0, means to get all calls state, or get specified call_id info
853 ql_mcm_voice_calls_state_t *pt_callstate
854);
855
856//Set forwarding
857int QL_Voice_Call_SetForwarding
858(
859 int h_voice,
860 E_QL_MCM_VOICE_CALL_SERVICE_T service,
861 E_QL_MCM_VOICE_CALL_FORWARDING_REASON_T reason,
862 char *number
863);
864
865//Get forwarding status
866int QL_Voice_Call_GetForwardingStatus
867(
868 int h_voice,
869 E_QL_MCM_VOICE_CALL_FORWARDING_REASON_T reason,
870 ql_mcm_voice_call_forwarding_status_list_t *pt_status
871);
872
873//Set voice call waiting
874int QL_Voice_Call_SetWaiting
875(
876 int h_voice,
877 ql_mcm_voice_call_waiting_service_t e_service
878);
879
880//Get voice call waiting status
881int QL_Voice_Call_GetWaitingStatus
882(
883 int h_voice,
884 ql_mcm_voice_call_waiting_service_t *pe_service
885);
886
887
888/*
889Usage 1 (register callback and wait for new call in, then answer):
8901, QL_Voice_Call_Client_Init
8912, QL_Voice_Call_AddStateHandler(pf_cb)
8923, wait for new call arrive, pf_cb will pass the call_id to app.
8934, QL_Voice_Call_Answer(call_id)
8945, QL_Voice_Call_End
8956, QL_Voice_Call_Client_Deinit
896
897
898Usage 2 (call out):
8991, QL_Voice_Call_Client_Init
9002, QL_Voice_Call_AddStateHandler(pf_cb)
9013, QL_Voice_Call_Start
9024, QL_Voice_Call_End
9035, QL_Voice_Call_Client_Deinit
904
905
906*/
907
908
909#endif // __QL_MCM_VOICE_H__