comparison src/aci2/ksd/ksd.h @ 3:93999a60b835

src/aci2, src/condat2: import of g23m/condat source pieces from TCS211
author Mychaela Falconia <falcon@freecalypso.org>
date Mon, 26 Sep 2016 00:29:36 +0000
parents
children
comparison
equal deleted inserted replaced
2:c41a534f33c6 3:93999a60b835
1 /*
2 +-----------------------------------------------------------------------------
3 | Project : GSM-PS (6147)
4 | Modul : KSD
5 +-----------------------------------------------------------------------------
6 | Copyright 2002 Texas Instruments Berlin, AG
7 | All rights reserved.
8 |
9 | This file is confidential and a trade secret of Texas
10 | Instruments Berlin, AG
11 | The receipt of or possession of this file does not convey
12 | any rights to reproduce or disclose its contents or to
13 | manufacture, use, or sell anything it may describe, in
14 | whole, or in part, without the specific written consent of
15 | Texas Instruments Berlin, AG.
16 +-----------------------------------------------------------------------------
17 | Purpose : This module is used for decoding of EMMI key sequences
18 | and supplementary service control strings.
19 +-----------------------------------------------------------------------------
20 */
21
22 #ifndef KSD_H
23 #define KSD_H
24
25 /*==== CONSTANTS ==================================================*/
26
27 #define KSD_TON_International 0x01
28 #define KSD_TON_Unknown 0x00
29
30 #define KSD_NPI_IsdnTelephony 0x01
31 #define KSD_NPI_Unknown 0x00
32
33 #define KSD_TOS_Nsap 0x00
34
35 #define KSD_OE_Even 0x00
36 #define KSD_OE_Odd 0x01
37
38 #define KSD_TIME_NONE 0xFF /* no time parameter */
39 #define KSD_IDX_NONE 0xFF /* no index parameter */
40
41 /*==== TYPES ======================================================*/
42
43 typedef enum /* +COLP parameter <mode> */
44 {
45 COLP_MOD_NotPresent = -1,
46 COLP_MOD_Disable,
47 COLP_MOD_Enable
48 }
49 T_ACA_COLP_MOD;
50
51 typedef enum /* +CLIP parameter <mode> */
52 {
53 CLIP_MOD_NotPresent = -1,
54 CLIP_MOD_Disable,
55 CLIP_MOD_Enable
56 }
57 T_ACA_CLIP_MOD;
58
59 typedef enum /* KSD operation codes */
60 {
61 KSD_OP_NONE = 0, /* no operation */
62 KSD_OP_IRGT, /* interrogate SS */
63 KSD_OP_REG, /* register SS */
64 KSD_OP_ERS, /* erase SS */
65 KSD_OP_ACT, /* activate SS */
66 KSD_OP_DEACT /* deactivate SS */
67 }
68 T_ACI_KSD_OP;
69
70 typedef enum /* KSD supplementary service codes */
71 {
72 KSD_SS_NONE = 0xFF, /* no operation */
73 KSD_SS_ALL_SERV = 0x00, /* all ss service */
74 KSD_SS_CLIP = 0x11, /* calling line identification presentation */
75 KSD_SS_CLIR = 0x12, /* calling line identification restriction */
76 KSD_SS_COLP = 0x13, /* connected line identification presentation */
77 KSD_SS_COLR = 0x14, /* connected line identification restriction */
78 KSD_SS_ALL_FWSS = 0x20, /* all forwarding SS */
79 KSD_SS_CFU = 0x21, /* call forwarding unconditional */
80 KSD_SS_ALL_CFWSS = 0x28, /* all conditional forwarding SS */
81 KSD_SS_CFB = 0x29, /* call forwarding on mobile subscriber busy */
82 KSD_SS_CFNRY = 0x2a, /* call forwarding on no reply */
83 KSD_SS_CFNRC = 0x2b, /* call forwarding on mobile subscriber not reachable */
84 KSD_SS_CW = 0x41, /* call waiting */
85 KSD_SS_CCBS = 0x43, /* completion of call to busy subscribers */
86 KSD_SS_ALL_CBSS = 0x90, /* all barring SS */
87 KSD_SS_BOC = 0x91, /* barring of outgoing calls */
88 KSD_SS_BAOC = 0x92, /* barring of all outgoing calls */
89 KSD_SS_BOIC = 0x93, /* barring of outgoing international calls */
90 KSD_SS_BOICXH = 0x94, /* barring of outgoing international calls except those directed to the home PLMN */
91 KSD_SS_BIC = 0x99, /* barring of incoming calls */
92 KSD_SS_BAIC = 0x9a, /* barring of all incoming calls */
93 KSD_SS_BICRM = 0x9b, /* barring of incoming calls when roaming outside home PLMN Country */
94 KSD_SS_PIN1 = 0xE0, /* PIN 1 */
95 KSD_SS_PIN2 = 0xE1 /* PIN 2 */
96 }
97 T_ACI_KSD_SS;
98
99 #define KSD_BS_TeleBearerUnknown (0xFF)
100
101 typedef enum /* KSD basic service codes GSM 2.30 */
102 {
103 KSD_BS_None = 0, /* no basic service */
104 KSD_BS_AllTeleAllBearer = 9,
105 KSD_BS_AllTele = 10,
106 KSD_BS_Telephony,
107 KSD_BS_AllData,
108 KSD_BS_AllFax,
109 KSD_BS_SMS = 16,
110 KSD_BS_VoiceGroup,
111 KSD_BS_AllTeleXcptSMS = 19,
112 KSD_BS_AllBearer,
113 KSD_BS_AllAsync,
114 KSD_BS_AllSync,
115 KSD_BS_AllDataCircSync = 24,
116 KSD_BS_AllDataCircAsync,
117 KSD_BS_AllDedPackAcc,
118 KSD_BS_AllDedPADAcc,
119 KSD_BS_AllPLMNSpecTele = 50,
120 KSD_BS_PLMNSpecTele1,
121 KSD_BS_PLMNSpecTele2,
122 KSD_BS_PLMNSpecTele3,
123 KSD_BS_PLMNSpecTele4,
124 KSD_BS_PLMNSpecTele5,
125 KSD_BS_PLMNSpecTele6,
126 KSD_BS_PLMNSpecTele7,
127 KSD_BS_PLMNSpecTele8,
128 KSD_BS_PLMNSpecTele9,
129 KSD_BS_PLMNSpecTele10,
130 KSD_BS_PLMNSpecTele11,
131 KSD_BS_PLMNSpecTele12,
132 KSD_BS_PLMNSpecTele13,
133 KSD_BS_PLMNSpecTele14,
134 KSD_BS_PLMNSpecTele15,
135 KSD_BS_AllPLMNSpecBearer = 70,
136 KSD_BS_PLMNSpecBearer1,
137 KSD_BS_PLMNSpecBearer2,
138 KSD_BS_PLMNSpecBearer3,
139 KSD_BS_PLMNSpecBearer4,
140 KSD_BS_PLMNSpecBearer5,
141 KSD_BS_PLMNSpecBearer6,
142 KSD_BS_PLMNSpecBearer7,
143 KSD_BS_PLMNSpecBearer8,
144 KSD_BS_PLMNSpecBearer9,
145 KSD_BS_PLMNSpecBearer10,
146 KSD_BS_PLMNSpecBearer11,
147 KSD_BS_PLMNSpecBearer12,
148 KSD_BS_PLMNSpecBearer13,
149 KSD_BS_PLMNSpecBearer14,
150 KSD_BS_PLMNSpecBearer15,
151 KSD_BS_AuxTelephony = 89
152 }
153 T_ACI_KSD_BS;
154
155 typedef enum /* KSD basic service type */
156 {
157 KSD_BS_TP_None = 0, /* no basic service type */
158 KSD_BS_TP_Tele = 0x83, /* basic service teleservice */
159 KSD_BS_TP_Bearer = 0x82 /* basic service bearer service */
160 }
161 T_ACI_KSD_BS_TP;
162
163 /* teleservice */
164 typedef enum
165 {
166 KSD_TS_ALL_TS =0x0, /* all teleservices */
167 KSD_TS_ALL_SPCH =0x10, /* All speech transmission services */
168 KSD_TS_TLPHNY =0x11, /* telephony */
169 KSD_TS_EMRGNCY =0x12, /* emergency calls */
170 KSD_TS_ALL_SMS =0x20, /* all SMS services */
171 KSD_TS_SMS_MT =0x21, /* SMS MT PP */
172 KSD_TS_SMS_MO =0x22, /* SMS MO PP */
173 KSD_TS_ALL_FAX =0x60, /* all FAX transmission services */
174 KSD_TS_FAX3_ALT_SPCH =0x61, /* FAX group 3 alter. speech */
175 KSD_TS_FAX3_AUTO =0x62, /* FAX group 3 automatic */
176 KSD_TS_FAX4 =0x63, /* FAX group 4 */
177 KSD_TS_ALL_DATA =0x70, /* all FAX and SMS services */
178 KSD_TS_ALL_XCPT_SMS =0x80, /* all FAX and speech services */
179 KSD_TS_ALL_PSSS =0xd0, /* all PLMN specific TS */
180 KSD_TS_PLMN1 =0xd1, /* PLMN specific TS 1 */
181 KSD_TS_PLMN2 =0xd2, /* PLMN specific TS 2 */
182 KSD_TS_PLMN3 =0xd3, /* PLMN specific TS 3 */
183 KSD_TS_PLMN4 =0xd4, /* PLMN specific TS 4 */
184 KSD_TS_PLMN5 =0xd5, /* PLMN specific TS 5 */
185 KSD_TS_PLMN6 =0xd6, /* PLMN specific TS 6 */
186 KSD_TS_PLMN7 =0xd7, /* PLMN specific TS 7 */
187 KSD_TS_PLMN8 =0xd8, /* PLMN specific TS 8 */
188 KSD_TS_PLMN9 =0xd9, /* PLMN specific TS 9 */
189 KSD_TS_PLMNA =0xda, /* PLMN specific TS A */
190 KSD_TS_PLMNB =0xdb, /* PLMN specific TS B */
191 KSD_TS_PLMNC =0xdc, /* PLMN specific TS C */
192 KSD_TS_PLMND =0xdd, /* PLMN specific TS D */
193 KSD_TS_PLMNE =0xde, /* PLMN specific TS E */
194 KSD_TS_PLMNF =0xdf /* PLMN specific TS F */
195
196 } T_ACI_KSD_TELE_SERVICE;
197
198 /* bearer service */
199 typedef enum
200 {
201 KSD_BS_ALL_BS =0x0, /* all bearer services */
202 KSD_BS_ALL_DATA_CDA =0x10, /* all data CDA services */
203 KSD_BS_CDA_300 =0x11, /* data CDA 300 bps */
204 KSD_BS_CDA_1200 =0x12, /* data CDA 1200 bps */
205 KSD_BS_CDA_1200_75 =0x13, /* data CDA 1200/75 bps */
206 KSD_BS_CDA_2400 =0x14, /* data CDA 2400 bps */
207 KSD_BS_CDA_4800 =0x15, /* data CDA 4800 bps */
208 KSD_BS_CDA_9600 =0x16, /* data CDA 9600 bps */
209 KSD_BS_ALL_DATA_CDS =0x18, /* all data CDS services */
210 KSD_BS_CDS_1200 =0x1a, /* data CDS 1200 bps */
211 KSD_BS_CDS_2400 =0x1c, /* data CDS 2400 bps */
212 KSD_BS_CDS_4800 =0x1d, /* data CDS 4800 bps */
213 KSD_BS_CDS_9600 =0x1e, /* data CDS 9600 bps */
214 KSD_BS_ALL_DATA_PAD =0x20, /* all data PAD services */
215 KSD_BS_PAD_300 =0x21, /* data PAD 300 bps */
216 KSD_BS_PAD_1200 =0x22, /* data PAD 1200 bps */
217 KSD_BS_PAD_1200_75 =0x23, /* data PAD 1200/75 bps */
218 KSD_BS_PAD_2400 =0x24, /* data PAD 2400 bps */
219 KSD_BS_PAD_4800 =0x25, /* data PAD 4800 bps */
220 KSD_BS_PAD_9600 =0x26, /* data PAD 9600 bps */
221 KSD_BS_ALL_DATA_PDS =0x28, /* all data PDS services */
222 KSD_BS_PDS_2400 =0x2c, /* data PDS 2400 bps */
223 KSD_BS_PDS_4800 =0x2d, /* data PDS 4800 bps */
224 KSD_BS_PDS_9600 =0x2e, /* data PDS 9600 bps */
225 KSD_BS_SPCH_ALT_CDA =0x30, /* all data CDA alter. speech */
226 KSD_BS_SPCH_ALT_CDS =0x38, /* all data CDS alter. speech */
227 KSD_BS_SPCH_FLD_CDA =0x40, /* all data speech followed CDA */
228 KSD_BS_SPCH_FLD_CDS =0x48, /* all data speech followed CDA */
229 KSD_BS_ALL_DC_ASYN =0x50, /* all data circuit asynchronous */
230 KSD_BS_ALL_ASYN =0x60, /* all asynchronous services */
231 KSD_BS_ALL_DC_SYN =0x58, /* all data circuit synchronous */
232 KSD_BS_ALL_SYN =0x68, /* all synchronous services */
233 KSD_BS_ALL_PSSS =0xd0, /* all PLMN specific BS */
234 KSD_BS_PLMN1 =0xd1, /* PLMN specific 1 */
235 KSD_BS_PLMN2 =0xd2, /* PLMN specific 2 */
236 KSD_BS_PLMN3 =0xd3, /* PLMN specific 3 */
237 KSD_BS_PLMN4 =0xd4, /* PLMN specific 4 */
238 KSD_BS_PLMN5 =0xd5, /* PLMN specific 5 */
239 KSD_BS_PLMN6 =0xd6, /* PLMN specific 6 */
240 KSD_BS_PLMN7 =0xd7, /* PLMN specific 7 */
241 KSD_BS_PLMN8 =0xd8, /* PLMN specific 8 */
242 KSD_BS_PLMN9 =0xd9, /* PLMN specific 9 */
243 KSD_BS_PLMNA =0xda, /* PLMN specific A */
244 KSD_BS_PLMNB =0xdb, /* PLMN specific B */
245 KSD_BS_PLMNC =0xdc, /* PLMN specific C */
246 KSD_BS_PLMND =0xdd, /* PLMN specific D */
247 KSD_BS_PLMNE =0xde, /* PLMN specific E */
248 KSD_BS_PLMNF =0xdf /* PLMN specific F */
249
250 } T_ACI_KSD_BEARER_SERVICE;
251
252 typedef enum /* KSD SS Status */
253 {
254 KSD_ST_NOT_VALID = 0xFF,/* no valid SS status */
255 KSD_ST_NONE = 0, /* not registered, not active, not provisioned,
256 not quiescent */
257 KSD_ST_A, /* Active */
258 KSD_ST_R, /* Registered */
259 KSD_ST_RA, /* Registered,Active */
260 KSD_ST_P, /* Provisioned */
261 KSD_ST_PA, /* Provisioned,Active */
262 KSD_ST_PR, /* Provisioned,Registered */
263 KSD_ST_PRA, /* Provisioned,Registered,Active */
264 KSD_ST_Q, /* Quiescent */
265 KSD_ST_QA, /* Quiescent,Active */
266 KSD_ST_QR, /* Quiescent,Registered */
267 KSD_ST_QRA, /* Quiescent,Registered,Active */
268 KSD_ST_QP, /* Quiescent,Provisioned */
269 KSD_ST_QPA, /* Quiescent,Provisioned,Active */
270 KSD_ST_QPR, /* Quiescent,Provisioned,Registered */
271 KSD_ST_QPRA /* Quiescent,Provisioned,Registered,Active */
272 }
273 T_ACI_KSD_ST;
274
275 typedef enum /* KSD CLIR option */
276 {
277 KSD_CO_NOT_VALID = 0xFF, /* no valid CLIR option */
278 KSD_CO_PERMANENT = 0x0, /* CLIR permanent */
279 KSD_CO_TEMPORARY = 0x1, /* CLIR temporary default */
280 KSD_CO_ALLOWED = 0x2 /* CLIR Allowed temporary default */
281 }
282 T_ACI_KSD_CLIR_OP;
283
284 typedef enum
285 {
286 KSD_OVR_CAT_NOT_VALID = 0xFF, /* no valid CLIR option */
287 KSD_OVR_CAT_ENABLED = 0x0, /* Override enabled */
288 KSD_OVR_CAT_DISABLED = 0x1 /* Override disabled */
289 }
290 T_ACI_KSD_OVRD_CTG;
291
292 typedef enum
293 {
294 KSD_NO_ERROR = 0x0,
295 KSD_ERR_UNKNOWN_SUBSCRIBER = 0x1,
296 KSD_ERR_ILLEGAL_SUBSCRIBER = 0x9,
297 KSD_ERR_BEARER_SVC_NOT_PROV = 0xa,
298 KSD_ERR_TELE_SVC_NOT_PROV = 0xb,
299 KSD_ERR_ILLEGAL_EQUIPMENT = 0xc,
300 KSD_ERR_CALL_BARRED = 0xd,
301 KSD_ERR_ILLEGAL_SS_OPERATION = 0x10,
302 KSD_ERR_SS_ERR_STATUS = 0x11,
303 KSD_ERR_SS_NOT_AVAIL = 0x12,
304 KSD_ERR_SS_SUBS_VIOLATION = 0x13,
305 KSD_ERR_SS_INCOMP = 0x14,
306 KSD_ERR_FAC_NOT_SUPPORTED = 0x15,
307 KSD_ERR_ABSENT_SUBS = 0x1b,
308 KSD_ERR_SYSTEM_FAIL = 0x22,
309 KSD_ERR_DATA_MISSING = 0x23,
310 KSD_ERR_UNEXPECT_DATA = 0x24,
311 KSD_ERR_PWD_REG_FAIL = 0x25,
312 KSD_ERR_NEG_PWD_CHECK = 0x26,
313 KSD_ERR_NUM_PWD_VIOLATION = 0x2b,
314 KSD_ERR_UNKNOWN_ALPHA = 0x47,
315 KSD_ERR_USSD_BUSY = 0x48,
316 KSD_ERR_MAX_NUM_MPTY_EXCEED = 0x7e,
317 KSD_ERR_RESOURCE_NOT_AVAIL = 0x7f,
318 KSD_GEN_PROB_UNRECOG_CMP = 0xA0,
319 KSD_GEN_PROB_MISTYPED_CMP = 0xA1,
320 KSD_GEN_PROB_BAD_STRUCT_CMP = 0xA2,
321 KSD_INV_PROB_DUPL_INV_ID = 0xB0,
322 KSD_INV_PROB_UNRECOG_OP = 0xB1,
323 KSD_INV_PROB_MISTYPED_PAR = 0xB2,
324 KSD_INV_PROB_RESOURCE_LIM = 0xB3,
325 KSD_INV_PROB_INIT_RELEASE = 0xB4,
326 KSD_INV_PROB_UNRECOG_LNK_ID = 0xB5,
327 KSD_INV_PROB_LNK_RES_UNEXP = 0xB6,
328 KSD_INV_PROB_UNEXP_LNK_OP = 0xB7,
329 KSD_RES_PROB_UNRECOG_INV_ID = 0xC0,
330 KSD_RES_PROB_RET_RES_UNEXP = 0xC1,
331 KSD_RES_PROB_MISTYPED_PAR = 0xC2,
332 KSD_ERR_PROB_UNRECOG_INV_ID = 0xD0,
333 KSD_ERR_PROB_RET_ERR_UNEXP = 0xD1,
334 KSD_ERR_PROB_UNRECOG_ERR = 0xD2,
335 KSD_ERR_PROB_UNEXP_ERR = 0xD3,
336 KSD_ERR_PROB_MISTYPED_PAR = 0xD4,
337 KSD_ERR_FATAL_INV_RESULT = 0xE0,
338 KSD_ERR_FATAL_CCD_DEC = 0xE1,
339 KSD_ERR_FATAL_SS_ENT = 0xE2
340 }
341 T_ACI_KSD_ERR;
342
343 typedef enum /* type of key sequence */
344 {
345 #ifdef SMI
346 SEQGRP_KEYPAD_IND,
347 SEQGRP_LCD_TEST,
348 SEQGRP_SET_ABBR_DIAL,
349 SEQGRP_SHOW_CALL_TABLE,
350
351 SEQGRP_SMS_SEND,
352 SEQGRP_SMS_SEND_FROM_MEM,
353 SEQGRP_SMS_WRITE,
354 SEQGRP_SMS_DELETE,
355 SEQGRP_SMS_READ,
356 SEQGRP_SMS_LIST,
357 SEQGRP_SMS_READ_SINGLE,
358
359 SEQGRP_SND_CBST,
360 SEQGRP_SND_CRLP,
361 SEQGRP_SND_DS,
362
363 SEQGRP_DATA_SPEECH,
364 SEQGRP_SPEECH_DATA,
365 #endif
366
367 SEQGRP_CHANGE_REGISTER,
368 SEQGRP_SET_REGISTER,
369 SEQGRP_START_REGISTER,
370
371 SEQGRP_ACT_SIM_LOCK,
372 SEQGRP_DEACT_SIM_LOCK,
373 SEQGRP_INTRGT_SIM_LOCK,
374
375 SEQGRP_DTMF,
376
377 SEQGRP_SUP_CLIR,
378 SEQGRP_INV_CLIR,
379 SEQGRP_SUP_CLIP,
380 SEQGRP_INV_CLIP,
381 SEQGRP_SUP_COLR,
382 SEQGRP_INV_COLR,
383 SEQGRP_SUP_COLP,
384 SEQGRP_INV_COLP,
385 SEQGRP_TTY_SERV,
386
387 SEQGRP_CB,
388 SEQGRP_CF,
389 SEQGRP_CHLD,
390 SEQGRP_CL,
391 SEQGRP_CW,
392 SEQGRP_DIAL,
393 SEQGRP_DIAL_IDX,
394 SEQGRP_PRSNT_IMEI,
395 SEQGRP_PWD,
396 SEQGRP_UBLK,
397 SEQGRP_UNKNOWN,
398 SEQGRP_USSD,
399 SEQGRP_CCBS,
400 SEQGRP_CTFR,
401
402 SEQGRP_HOOK_OFF,
403 SEQGRP_HOOK_ON,
404
405 SEQGRP_MS_OFF,
406 SEQGRP_MS_ON,
407
408 SEQGRP_EM_MODE
409 }
410 T_KSD_SEQGRP;
411
412 typedef struct /* parameter list of function cmh_ksdCB */
413 {
414 UBYTE opCd;
415 UBYTE ssCd;
416 UBYTE bsCd;
417 UBYTE *pwd;
418 } T_ACI_KSD_CB_PRM;
419
420 typedef struct /* parameter list of function cmh_ksdCF */
421 {
422 UBYTE opCd;
423 UBYTE ssCd;
424 UBYTE bsCd;
425 UBYTE *num;
426 UBYTE npi;
427 UBYTE ton;
428 UBYTE *sub;
429 UBYTE tos;
430 UBYTE oe;
431 UBYTE time;
432 } T_ACI_KSD_CF_PRM;
433
434 typedef struct /* parameter list of function cmh_ksdCL */
435 {
436 UBYTE opCd;
437 UBYTE ssCd;
438 } T_ACI_KSD_CL_PRM;
439
440 typedef struct /* parameter list of function cmh_ksdCW */
441 {
442 UBYTE opCd;
443 UBYTE bsCd;
444 } T_ACI_KSD_CW_PRM;
445
446 typedef struct /* parameter list of function cmh_ksdPWD */
447 {
448 UBYTE ssCd;
449 UBYTE *oldPwd;
450 UBYTE *newPwd;
451 UBYTE *newPwd2;
452 } T_ACI_KSD_PWD_PRM;
453
454 typedef struct /* parameter list of function cmh_ksdUBLK */
455 {
456 UBYTE ssCd;
457 UBYTE *puk;
458 UBYTE *pin;
459 } T_ACI_KSD_UBLK_PRM;
460
461 typedef struct /* parameter list of function cmh_ksdUSSD */
462 {
463 UBYTE* ussd;
464 } T_ACI_KSD_USSD_PRM;
465
466 typedef struct /* parameter list of function cmh_ksdCCBS */
467 {
468 UBYTE opCd;
469 UBYTE idx;
470 } T_ACI_KSD_CCBS_PRM;
471
472 typedef struct /* parameter list used for setting of */
473 { /* abbreviated dialing parameter */
474 CHAR* number;
475 BYTE index;
476 }
477 T_KSD_ABBR_DIAL;
478
479 typedef struct /* parameter list of function sAT_PlusCBST */
480 {
481 T_ACI_BS_SPEED speed;
482 T_ACI_CBST_NAM name;
483 T_ACI_CBST_CE ce;
484 }
485 T_KSD_CBST;
486
487 typedef struct /* parameter list for TTY/CTM service request */
488 {
489 T_ACI_CTTY_REQ req;
490 }
491 T_KSD_CTTY;
492
493 typedef struct /* parameter list of function sAT_PlusCHLD */
494 {
495 T_ACI_CHLD_MOD mode;
496 CHAR* call;
497 }
498 T_KSD_CHLD;
499
500 typedef struct /* parameter list of function sAT_PlusCTFR */
501 {
502 CHAR *number;
503 T_ACI_TOA type;
504 CHAR *subaddr;
505 T_ACI_TOS satype;
506 }
507 T_KSD_CTFR;
508
509 typedef struct /* parameter list of function sAT_PlusCLCK */
510 {
511 T_ACI_CLCK_FAC fac;
512 T_ACI_CLCK_MOD mode;
513 CHAR* passwd;
514 T_ACI_CLASS class_type;
515 }
516 T_KSD_CLCK;
517
518 typedef struct /* parameter list of function qAT_PlusCLCK */
519 {
520 T_ACI_CLCK_FAC fac;
521 }
522 T_KSD_CLCK_QUERY;
523
524 typedef struct /* parameter list of function sAT_PlusCLIP */
525 {
526 T_ACA_CLIP_MOD mode;
527 }
528 T_KSD_CLIP;
529
530 typedef struct /* parameter list of function sAT_PlusCLIR */
531 {
532 T_ACI_CLIR_MOD mode;
533 }
534 T_KSD_CLIR;
535
536 typedef struct /* parameter list of function sAT_PlusCOLP */
537 {
538 T_ACA_COLP_MOD mode;
539 }
540 T_KSD_COLP;
541
542 typedef struct /* parameter list of function sAT_PlusCOPS */
543 {
544 T_ACI_COPS_MOD mode;
545 T_ACI_COPS_FRMT frmt;
546 CHAR* oper;
547 }
548 T_KSD_COPS;
549
550 typedef struct /* parameter list of function sAT_PlusCRLP */
551 {
552 SHORT iws;
553 SHORT mws;
554 SHORT t1;
555 SHORT n2;
556 }
557 T_KSD_CRLP;
558
559 typedef struct /* parameter list of function sAT_Dn */
560 {
561 CHAR* number;
562 T_ACI_D_CLIR_OVRD clirOvrd;
563 T_ACI_D_CUG_CTRL cugCtrl;
564 T_ACI_D_TOC callType;
565 }
566 T_KSD_DIAL;
567
568 typedef struct /* parameter list of function sAT_Dm */
569 {
570 CHAR* str;
571 T_ACI_PB_STOR mem;
572 SHORT index;
573 T_ACI_D_CLIR_OVRD clirOvrd;
574 T_ACI_D_CUG_CTRL cugCtrl;
575 T_ACI_D_TOC callType;
576 }
577 T_KSD_DIAL_IDX;
578
579 typedef struct /* parameter list of function sAT_PlusDS */
580 {
581 T_ACI_DS_DIR dir;
582 T_ACI_DS_COMP comp;
583 LONG maxDict;
584 SHORT maxStr;
585 }
586 T_KSD_DS;
587
588 typedef struct /* parameter list of the keypad indication */
589 {
590 UBYTE keyCode;
591 UBYTE keyStat;
592 }
593 T_KSD_KEYPAD_IND;
594
595 typedef union /* decoded parameter for ACI function */
596 {
597 T_ACI_KSD_CB_PRM cb;
598 T_ACI_KSD_CF_PRM cf;
599 T_ACI_KSD_CL_PRM cl;
600 T_ACI_KSD_CW_PRM cw;
601 T_ACI_KSD_PWD_PRM pwd;
602 T_ACI_KSD_UBLK_PRM ublk;
603 T_ACI_KSD_USSD_PRM ussd;
604 T_ACI_KSD_CCBS_PRM ccbs;
605
606 CHAR dtmf;
607 T_KSD_ABBR_DIAL abbrDial;
608 T_KSD_CBST cbst;
609 T_KSD_CTTY ctty;
610 T_KSD_CHLD chld;
611 T_KSD_CTFR ctfr;
612 T_KSD_CLCK clck;
613 T_KSD_CLCK_QUERY clck_query;
614 T_KSD_CLIP Clip; /* capital C in Clir, Clip and Colp is */
615 T_KSD_CLIR Clir; /* necessary to avoid identifier conflicts*/
616 T_KSD_COLP Colp; /* (see constants in project MFW) */
617 T_KSD_COPS cops;
618 T_KSD_CRLP crlp;
619 T_KSD_DIAL dial;
620 T_KSD_DIAL_IDX dialIdx;
621 T_KSD_DS ds;
622 T_KSD_KEYPAD_IND keypad;
623 }
624 T_KSD_SEQPARAM;
625
626 /*==== PROTOTYPES =================================================*/
627 /*
628 +--------------------------------------------------------------------+
629 | PROJECT : GSM-PS (6147) MODULE : KSD |
630 | STATE : code ROUTINE : ksd_decode |
631 +--------------------------------------------------------------------+
632
633 PURPOSE : This function decodes the incoming keystroke sequence.
634
635 <inSeq>: key sequence, to be decoded
636 <inCall>: TRUE if MMI is within a call, otherwise
637 FALSE
638 <outSeqGrp>: sequence group
639 <outRestSeq>: rest key sequence, to be decoded by a
640 further call to this function
641 <outSeqParam>: sequence parameter
642
643 returns: TRUE if decoding was successfull,
644 otherwise FALSE
645 */
646 GLOBAL BOOL ksd_decode (CHAR* inSeq,
647 BOOL inCall,
648 T_KSD_SEQGRP* outSeqGrp,
649 CHAR** outRestSeq,
650 T_KSD_SEQPARAM* outSeqParam);
651
652 /*
653 +--------------------------------------------------------------------+
654 | PROJECT : GSM-PS (6147) MODULE : KSD |
655 | STATE : code ROUTINE : ksd_getPwdHidden |
656 +--------------------------------------------------------------------+
657
658 PURPOSE : This function is used to hide passwords which are being
659 entered during input of a keystroke sequence.
660
661 <inSeq>: key sequence to be manipulated
662 <replace>: character which is used for replacing of
663 passwords
664 */
665 GLOBAL void ksd_getPwdHidden (CHAR* inSeq,
666 CHAR replace);
667
668 /*
669 +--------------------------------------------------------------------+
670 | PROJECT : GSM-PS (6147) MODULE : KSD |
671 | STATE : code ROUTINE : ksd_isSscs |
672 +--------------------------------------------------------------------+
673
674 PURPOSE : This function return whether the given string is a
675 supplementary service control string.
676
677 <inSeq>: key sequence
678
679 returns: TRUE if string is a supplementary service
680 control string, otherwise FALSE
681 */
682 GLOBAL BOOL ksd_isSscs (CHAR* inSeq);
683
684 /*
685 +--------------------------------------------------------------------+
686 | PROJECT : GSM-PS (6147) MODULE : KSD |
687 | STATE : code ROUTINE : ksd_isSATSscs |
688 +--------------------------------------------------------------------+
689
690 PURPOSE : This function return whether the given string is a
691 supplementary service control string for SAT.
692
693 <inSeq>: key sequence
694
695 returns: TRUE if string is a supplementary service
696 control string for SAT, otherwise FALSE
697 */
698 GLOBAL BOOL ksd_isSATSscs ( CHAR* inSeq );
699
700 /*
701 +--------------------------------------------------------------------+
702 | PROJECT : GSM-PS (6147) MODULE : KSD |
703 | STATE : code ROUTINE : ksd_isUSSD |
704 +--------------------------------------------------------------------+
705
706 PURPOSE : This function checks whether key sequence is an
707 unstructured SS command.
708
709 <keySeq>: buffer containing the key sequence
710 */
711 GLOBAL BOOL ksd_isUSSD (CHAR *keySeq);
712
713 /*
714 +--------------------------------------------------------------------+
715 | PROJECT : GSM-PS (6147) MODULE : KSD |
716 | STATE : code ROUTINE : ksd_isFDNCheckSeq |
717 +--------------------------------------------------------------------+
718
719 PURPOSE : This function return whether the given string must check
720 in FDN phonebook
721
722 <inSeq>: key sequence
723
724 returns: TRUE if string must check,
725 otherwise FALSE
726 */
727 GLOBAL BOOL ksd_isFDNCheckSeq (CHAR* inSeq);
728
729
730 /*
731 +--------------------------------------------------------------------+
732 | PROJECT : GSM-PS (6147) MODULE : KSD |
733 | STATE : code ROUTINE : ksd_isBCDForUSBand |
734 +--------------------------------------------------------------------+
735
736 PURPOSE : This function checks if US band is used and key sequence
737 is "0" or "00", because these key sequences shall be send
738 to network as normal dialing numbers when using US band.
739
740 <inSeq>: key sequence
741
742 returns: TRUE if US band is used and key sequence
743 is "0" or "00",
744 otherwise FALSE
745 */
746 GLOBAL BOOL ksd_isBCDForUSBand (CHAR* inSeq);
747 /*
748 +--------------------------------------------------------------------+
749 | PROJECT : GSM-PS (6147) MODULE : KSD |
750 | STATE : code ROUTINE : ksd_check_write_to_LDN |
751 +--------------------------------------------------------------------+
752
753 PURPOSE : This function is used to decide if the keystroke sequence needs to
754 be stored in the LDN or not.
755
756 <inSeq>: key sequence
757
758 returns: TRUE if the keystroke sequence doesn't contain password
759 or it is not a local string
760 otherwise FALSE
761 */
762 GLOBAL BOOL ksd_isLDNWriteCheckSeq(CHAR* inSeq);
763
764
765
766 /*==== EXPORT =====================================================*/
767
768 #endif
769