FreeCalypso > hg > fc-tourmaline
comparison src/ui/mfw/mfw_sms.h @ 3:67bfe9f274f6
src/ui: import of src/ui3 from Magnetite
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Fri, 16 Oct 2020 06:33:10 +0000 |
parents | |
children | 92abb46dc1ba |
comparison
equal
deleted
inserted
replaced
2:3a14ee9a9843 | 3:67bfe9f274f6 |
---|---|
1 /* | |
2 +--------------------------------------------------------------------+ | |
3 | PROJECT: MMI-Framework (8417) $Workfile:: mfw_sms.h $| | |
4 | $Author:: Vo $Revision:: 1 $| | |
5 | CREATED: 21.12.98 $Modtime:: 21.03.00 10:48 $| | |
6 | STATE : code | | |
7 +--------------------------------------------------------------------+ | |
8 | |
9 MODULE : MFW_SMS | |
10 | |
11 PURPOSE : This modul contains the definition for SMS management. | |
12 | |
13 | |
14 $History:: mfw_sms.h $ | |
15 | |
16 Feb 28, 2007 OMAPS00109953 a0393213(R.Prabakar) | |
17 Description : Need to be able to store SMS in SIM/ME | |
18 Solution : Earlier, index alone was sufficient to identify messages. Now memory should also be taken care of. | |
19 | |
20 Feb 07, 2006 DR: OMAPS00059261 x0pleela | |
21 Description: SMS is not forwarding STATUS reports that are read from SIM storage to ACI | |
22 Solution: Renamed "MFW_SMS_STATRPT_PENDG" to MFW_SMS_STATRPT in T_MFW_SMS_STAT | |
23 Removed T_MFW_SMS_MT_TYPE enumeration added earlier | |
24 | |
25 Feb 01, 2006 DR: OMAPS00059261 x0pleela | |
26 Description: SMS is not forwarding STATUS reports that are read from SIM storage to ACI | |
27 Solution: Added new enumeration T_MFW_SMS_MSG_TYPE to suport message type MT, MO or STATUS REPORT. | |
28 Changed the name from T_MFW_SMS_MSG_TYPE to T_MFW_SMS_MT_TYPE | |
29 Changed the type of new field sms_msg_type ( of type T_MFW_SMS_MT_TYPE) in the structure T_MFW_SMS_MT. | |
30 Added new enumeration type "MFW_SMS_STATRPT_PENDG" into T_MFW_SMS_STAT | |
31 | |
32 Jan 30, 2006 DR: OMAPS00059261 x0pleela | |
33 Description: SMS is not forwarding STATUS reports that are read from SIM storage to ACI | |
34 Solution: Added new enumeration T_MFW_SMS_MSG_TYPE to suport message type either TEXT or STATUS REPORT. | |
35 Added new field sms_msg_type to the structure T_MFW_SMS_MT. | |
36 | |
37 Jan 20, 2006 REF: DRT OMAPS00053377 xdeepadh | |
38 Description: SMS Validity Period - using MMI - Failure, MS not able to set SMS validity | |
39 Solution: Store the first octet too while querying. | |
40 | |
41 Dec 15, 2005 REF: MMI-FIX-OMAPS00058684 x0035544 | |
42 Description: OMAPS00045726 / MMI-FIX-30439 Follow-Up : ifdef for FF Home Zone forgotten. | |
43 Solution: Added Feature flag FF_HOMEZONE for the function sms_homezoneCBToggle(U8 Activate_CB) | |
44 in this file as it has got the prototype for this function | |
45 | |
46 Jun 14, 2005 REF: MMI-FIX-30439 x0018858 | |
47 Description: The homezone/cityzone tags were not being displayed properly. | |
48 Solution: Modified to save the tags properly in caches and also made the | |
49 appropriate modifications to update the same properly during mobility. | |
50 | |
51 x0018858 24 Mar, 2005 MMI-FIX-11321 | |
52 Issue Description :- If the inbox is full and a new message is receivd, no indication is received. | |
53 Fix: Added support for handling indication when message box is full and | |
54 there is a pending message. | |
55 | |
56 Feb 16, 2005 REF: CRR MMI-SPR-27900 xnkulkar | |
57 Issue description: BMI: using the tool nowSMS the voicemail indication via sms does not work | |
58 Solution: Instead of identifying voice using addr[0] and pid, we use dcs. Also, messages belonging | |
59 to group "1100" are deleted when voicemail icon is displayed. | |
60 | |
61 Oct 04, 2004 REF: CRR 25519 Deepa M.D | |
62 Bug:Re-align structure members in MFW | |
63 Fix:Structure elements have been realigned to avoid the structure padding | |
64 | |
65 * ***************** Version 27 ***************** | |
66 SPR 2260: Merged in bugfixes 1833, and 1830 | |
67 fom the 1.6.3 branch into this file. | |
68 * | |
69 * ***************** Version 26 ***************** | |
70 * User: Vo Date: 22.03.00 Time: 17:44 | |
71 * Updated in $/GSM/Condat/MS/SRC/MFW | |
72 * check voice mail status | |
73 * | |
74 * ***************** Version 24 ***************** | |
75 * User: Vo Date: 14.01.00 Time: 20:15 | |
76 * Updated in $/GSM/Condat/MS/SRC/MFW | |
77 * Bug fix: Constant define: MAX_CBMSG_LEN | |
78 * New:change parameter "data" to "data + len" in function | |
79 * sms_submit(), sms_store() and sms_change() | |
80 * | |
81 * ***************** Version 23 ***************** | |
82 * User: Vo Date: 2.12.99 Time: 13:15 | |
83 * Updated in $/GSM/Condat/MS/SRC/MFW | |
84 * | |
85 * ***************** Version 22 ***************** | |
86 * User: Vo Date: 17.11.99 Time: 12:17 | |
87 * Updated in $/GSM/Condat/MS/SRC/MFW | |
88 * change define NON_STRING_CHARACTER to NO_ASCIIZ | |
89 * | |
90 * ***************** Version 21 ***************** | |
91 * User: Vo Date: 17.11.99 Time: 11:00 | |
92 * Updated in $/GSM/Condat/MS/SRC/MFW | |
93 * 1. Change constants: T_MFW_SMS_MEM | |
94 * 2. New constants: T_MFW_SMS_MO_TYPE for submit message type | |
95 * 3. New constants: T_MFW_SMS_CMD_IND for command indication | |
96 * 4. #ifdef NON_STRING_CHARACTER - alpha uses data + len | |
97 * 5. Change interface: sms_submit() | |
98 * 6. New interface: sms_change_read_status() | |
99 * | |
100 * ***************** Version 20 ***************** | |
101 * User: Vo Date: 21.10.99 Time: 13:35 | |
102 * Updated in $/GSM/Condat/MS/SRC/MFW | |
103 * change constant define | |
104 * | |
105 * ***************** Version 19 ***************** | |
106 * User: Es Date: 16.09.99 Time: 17:23 | |
107 * Updated in $/GSM/DEV/MS/SRC/MFW | |
108 * added TON/NPI fields to T_MFW_SMS_ADDR | |
109 * | |
110 * ***************** Version 18 ***************** | |
111 * User: Vo Date: 12.09.99 Time: 12:40 | |
112 * Updated in $/GSM/DEV/MS/SRC/MFW | |
113 * change parameter 'dcs' in T_MFW_SMS_CB_INFO (adaptation to ACI) | |
114 * | |
115 * ***************** Version 17 ***************** | |
116 * User: Vo Date: 10.09.99 Time: 19:53 | |
117 * Updated in $/GSM/DEV/MS/SRC/MFW | |
118 * move sms_save_pref_lang() to sim_save_pref_lang() | |
119 * | |
120 * ***************** Version 16 ***************** | |
121 * User: Vo Date: 30.08.99 Time: 15:19 | |
122 * Updated in $/GSM/DEV/MS/SRC/MFW | |
123 * new events | |
124 * | |
125 * ***************** Version 15 ***************** | |
126 * User: Vo Date: 26.07.99 Time: 14:32 | |
127 * Updated in $/GSM/DEV/MS/SRC/MFW | |
128 * Add new definitions | |
129 * | |
130 * ***************** Version 14 ***************** | |
131 * User: Vo Date: 16.07.99 Time: 13:50 | |
132 * Updated in $/GSM/DEV/MS/SRC/MFW | |
133 * | |
134 * ***************** Version 13 ***************** | |
135 * User: Vo Date: 16.07.99 Time: 10:39 | |
136 * Updated in $/GSM/DEV/MS/SRC/MFW | |
137 * | |
138 * ***************** Version 12 ***************** | |
139 * User: Vo Date: 22.06.99 Time: 8:54 | |
140 * Updated in $/GSM/DEV/MS/SRC/MFW | |
141 * | |
142 * ***************** Version 11 ***************** | |
143 * User: Vo Date: 1.06.99 Time: 14:47 | |
144 * Updated in $/GSM/DEV/MS/SRC/MFW | |
145 * | |
146 * ***************** Version 10 ***************** | |
147 * User: Vo Date: 28.05.99 Time: 9:52 | |
148 * Updated in $/GSM/DEV/MS/SRC/MFW | |
149 * | |
150 * ***************** Version 9 ***************** | |
151 * User: Vo Date: 21.05.99 Time: 13:51 | |
152 * Updated in $/GSM/DEV/MS/SRC/MFW | |
153 * | |
154 * ***************** Version 8 ***************** | |
155 * User: Vo Date: 18.05.99 Time: 14:35 | |
156 * Updated in $/GSM/DEV/MS/SRC/MFW | |
157 * | |
158 * ***************** Version 7 ***************** | |
159 * User: Vo Date: 25.03.99 Time: 16:34 | |
160 * Updated in $/GSM/DEV/MS/SRC/MFW | |
161 * | |
162 * ***************** Version 6 ***************** | |
163 * User: Vo Date: 25.02.99 Time: 16:47 | |
164 * Updated in $/GSM/DEV/MS/SRC/MFW | |
165 * | |
166 * ***************** Version 5 ***************** | |
167 * User: Vo Date: 17.02.99 Time: 20:00 | |
168 * Updated in $/GSM/DEV/MS/SRC/MFW | |
169 * | |
170 * ***************** Version 4 ***************** | |
171 * User: Vo Date: 11.02.99 Time: 15:43 | |
172 * Updated in $/GSM/DEV/MS/SRC/MFW | |
173 * | |
174 * ***************** Version 3 ***************** | |
175 * User: Vo Date: 11.02.99 Time: 12:54 | |
176 * Updated in $/GSM/DEV/MS/SRC/MFW | |
177 * | |
178 * ***************** Version 2 ***************** | |
179 * User: Vo Date: 7.01.99 Time: 12:38 | |
180 * Updated in $/GSM/DEV/MS/SRC/MFW | |
181 * | |
182 * ***************** Version 1 ***************** | |
183 * User: Vo Date: 30.12.98 Time: 11:49 | |
184 * Created in $/GSM/DEV/MS/SRC/MFW | |
185 | |
186 */ | |
187 | |
188 #ifndef DEF_MFW_SMS_HEADER | |
189 #define DEF_MFW_SMS_HEADER | |
190 | |
191 #include "mfw_cm.h" | |
192 #include "aci_lst.h" | |
193 #include "conc_sms.h" | |
194 | |
195 #ifndef NEPTUNE_BOARD | |
196 //#define MAX_IDENTS 0x14 | |
197 #else | |
198 #define MAX_IDENTS 0x14 /* NEPTUNE Integration: Uncommented.*/ | |
199 #endif | |
200 | |
201 #define MAX_SCTP_DIGITS 2 | |
202 #define BASIC_MAX_MSG_LEN 160 | |
203 #define MAX_CBMSG_LEN 94 | |
204 //1227 - API - 05/10/02 - Create new Define for Single SMS and increase original for Conc_SMS | |
205 #define MAX_MSG_LEN_SGL 161 //Max message length for disabled Conc SMS API | |
206 | |
207 /*JVJ-SPR-1298. Provisional until a new option in the .inf file is inserted.*/ | |
208 | |
209 #ifdef MMI_LITE | |
210 /*SPR 2350, concat messagse of up to 500 chars should be allowed*/ | |
211 #define MAX_MSG_LEN_LITE (MAX_MSG_LEN_SGL*3) | |
212 #define MAX_MSG_LEN MAX_MSG_LEN_LITE | |
213 #else | |
214 #define MAX_MSG_LEN 1601 //Max size for a SMS | |
215 #endif | |
216 | |
217 #define MAX_MSG_LEN_ARRAY (MAX_MSG_LEN+1) //Array size for SMS | |
218 | |
219 | |
220 /*MC, chinese message lengths*/ | |
221 #define MAX_MSG_LEN_SGL_CHI 140 //Max message length for single chinese message | |
222 #define MAX_MSG_LEN_CHI (MAX_MSG_LEN_SGL_CHI*10) | |
223 | |
224 | |
225 /* | |
226 * events are organised as bitmaps | |
227 */ | |
228 #define E_SMS_MO_AVAIL 0x0001 | |
229 #define E_SMS_CMD_AVAIL 0x0002 | |
230 #define E_SMS_SAVE_AVAIL 0x0004 | |
231 #define E_SMS_MT 0x0008 | |
232 #define E_SMS_MO 0x0010 | |
233 #define E_SMS_CB 0x0020 | |
234 #define E_SMS_CB_RECEIVED 0x0040 | |
235 #define E_SMS_MT_RECEIVED 0x0080 | |
236 #define E_SMS_STATUS 0x0100 | |
237 #define E_SMS_MEM 0x0200 | |
238 #define E_SMS_OK 0x0400 | |
239 #define E_SMS_ERR 0x0800 | |
240 #define E_SMS_BUSY 0x1000 | |
241 #define E_SMS_READY 0x2000 | |
242 #define E_SMS_MEM_FULL 0x4000 | |
243 #define E_SMS_MEM_FREE 0x8000 | |
244 | |
245 #define E_SMS_RECEIVED 0x0600 | |
246 #define E_SMS_ALL_SERVICE 0xffff | |
247 | |
248 #if defined (FF_WAP) && defined (FF_GPF_TCPIP) | |
249 //liuyu | |
250 /* SPR#2086 */ | |
251 #define E_SMS_WAP_MT_RECEIVED 0x10000 | |
252 #define E_SMS_WAP_MO_SENT 0x20000 | |
253 #define E_SMS_WAP_ERR 0x40000 | |
254 #endif | |
255 | |
256 /* definition for validity period mode */ | |
257 #define SMS_VPF_NOTPRESENT 0 | |
258 #define SMS_VPF_NUMERICAL 2 // Corresponds to relative period | |
259 #define SMS_VPF_STRING 3 // Corresponds to absolute period | |
260 | |
261 /* definition for reply path */ | |
262 #define SMS_UNSET_RP 0 | |
263 #define SMS_SET_RP 1 | |
264 | |
265 /* definition for reject duplicates */ | |
266 #define SMS_ACCEPT_RD 0 | |
267 #define SMS_REJECT_RD 1 | |
268 | |
269 /* definition for status report request */ | |
270 #define SMS_NOT_REQUESTED_SRR 0 | |
271 #define SMS_REQUESTED_SRR 1 | |
272 | |
273 /* SMS management functional return codes */ | |
274 typedef enum | |
275 { | |
276 MFW_SMS_FAIL = -1, /* execution of command failed */ | |
277 MFW_SMS_OK /* execution of command completed */ | |
278 } T_MFW_SMS_RETURN; | |
279 | |
280 /* definition for message type */ | |
281 typedef enum | |
282 { | |
283 MFW_NO_MESSAGE, | |
284 MFW_SMS_MESSAGE, /* SMS message */ | |
285 MFW_CB_MESSAGE /* cell broadcast message */ | |
286 } T_MFW_SMS_TYPE; | |
287 | |
288 /* definition for submit message type */ | |
289 typedef enum | |
290 { | |
291 MFW_SMS_SUBMIT, | |
292 MFW_SMS_REPLY, | |
293 MFW_SMS_SUBMIT_SENT, | |
294 MFW_SMS_REPLY_SENT | |
295 } T_MFW_SMS_MO_TYPE; | |
296 | |
297 /* Memory which messages are stored */ | |
298 typedef enum | |
299 { | |
300 MFW_MEM_NOTPRESENT=-1, /*a0393213 OMAPS00109953*/ | |
301 MFW_MEM_ME, | |
302 MFW_MEM_SIM | |
303 } T_MFW_SMS_MEM; | |
304 | |
305 // Feb 16, 2005 REF: CRR MMI-SPR-27900 xnkulkar | |
306 // Added MFW_SMS_VOICEMSG_DELETE to enum T_MFW_SMS_STAT | |
307 | |
308 /* Memory which messages are stored */ | |
309 typedef enum | |
310 { | |
311 MFW_SMS_UNKNOWN, | |
312 MFW_SMS_UNREAD, /* received unread message */ | |
313 MFW_SMS_READ, /* received read message */ | |
314 MFW_SMS_STOR_UNSENT, /* stored unsent messgae */ | |
315 MFW_SMS_STOR_SENT, /* stored sent message */ | |
316 MFW_SMS_MO, /* MO SMS message */ | |
317 MFW_SMS_MT, /* MT SMS message */ | |
318 MFW_SMS_ALL, | |
319 MFW_SMS_NotVOICE, | |
320 MFW_SMS_VOICE, /* voice mail message */ | |
321 MFW_SMS_VOICEMSG_DELETE, // To mark the voice mail sms for deletion (group 1100) | |
322 MFW_SMS_STATRPT, ////x0pleela 01 Feb, 2006 DR: OMAPS00059261 /* Status report status*/ //x0pleela 06 Feb, 2006 DR: OMAPS00059261 Removed pending from name | |
323 MFW_SMS_INVALID /*SPR2260*/ | |
324 } T_MFW_SMS_STAT; | |
325 | |
326 /*SPR 2260, eneumerated type for concat status of message in list*/ | |
327 typedef enum | |
328 { | |
329 MFW_SMS_NO_CONC, | |
330 MFW_SMS_CONC_PART, | |
331 MFW_SMS_CONC_WHOLE | |
332 } | |
333 T_MFW_SMS_CONC_STAT ; | |
334 | |
335 typedef struct | |
336 { | |
337 UBYTE year [MAX_SCTP_DIGITS]; | |
338 UBYTE month [MAX_SCTP_DIGITS]; | |
339 UBYTE day [MAX_SCTP_DIGITS]; | |
340 UBYTE hour [MAX_SCTP_DIGITS]; | |
341 UBYTE minute [MAX_SCTP_DIGITS]; | |
342 UBYTE second [MAX_SCTP_DIGITS]; | |
343 SHORT timezone; | |
344 } T_MFW_SMS_SCTP; | |
345 | |
346 /* SMS command */ | |
347 typedef enum | |
348 { | |
349 SMS_ENQ_PREV_SMS, /* Starts an enquiry to previously sended short message */ | |
350 SMS_CAN_STAT_REQ, /* Cancels status report request */ | |
351 SMS_DEL_PREV_SMS, /* Deletion of previous sended short message */ | |
352 SMS_REQ_STAT_REP /* Requests status report for SMS message */ | |
353 } T_MFW_SMS_COMMAND; | |
354 | |
355 typedef enum | |
356 { | |
357 MT_IND_IDX, /* message will be stored to memory and index will | |
358 be indicated (E_SMS_MT_RECEIVED) */ | |
359 MT_IND_NO_IDX, /* message will be stored to memory and index will | |
360 not be indicated */ | |
361 MT_IND_MSG, /* message will be indicated to mmi (E_SMS_MT) | |
362 but not stored to memory */ | |
363 MT_CB_IDX, /* CB message will be stored to memory and index will | |
364 be indicated (E_SMS_CB_RECEIVED) */ | |
365 MT_CB_NO_IDX, /* CB message will be stored to memory and index will | |
366 not be indicated */ | |
367 MT_CB_MSG, /* CB message will be indicated to mmi (E_SMS_CB) | |
368 but not stored to memory */ | |
369 /* Marcus: Issue 1170: 07/10/2002: Start */ | |
370 MT_IND_SRR_ON, /* Status reports are to be notified */ | |
371 MT_IND_SRR_OFF /* Status reports are not to be notified */ | |
372 /* Marcus: Issue 1170: 07/10/2002: End */ | |
373 | |
374 } T_MFW_SMS_MT_IND; | |
375 | |
376 typedef enum | |
377 { | |
378 CMD_SMS_NO_CMD, | |
379 CMD_SMS_SUBMIT, /* send message */ | |
380 CMD_SMS_MEMORY, /* set/get preferred message store */ | |
381 CMD_SMS_READ, /* read message */ | |
382 CMD_SMS_STORE, /* save message */ | |
383 CMD_SMS_DELETE, /* delete message */ | |
384 CMD_SMS_COMMAND, /* send command */ | |
385 CMD_SMS_SET_PARA, /* set SMS parameter */ | |
386 CMD_SMS_SET_CB_PARA, /* set cell broadcast parameter */ | |
387 CMD_SMS_SET_IND /* set new message indication */ | |
388 } T_MFW_SMS_CMD_IND; | |
389 | |
390 //x0pleela 01 Feb, 2006 DR: OMAPS00059261 | |
391 /* SMS type: MT, MO, STAT RPT */ | |
392 | |
393 typedef enum | |
394 { | |
395 MFW_MSG_DELIVER, | |
396 MFW_MSG_SUBMIT, | |
397 MFW_MSG_STATUS_REPORT | |
398 }T_MFW_SMS_MSG_TYPE; | |
399 | |
400 typedef struct | |
401 { | |
402 UBYTE mem; | |
403 UBYTE used; | |
404 UBYTE total; | |
405 UBYTE dummy; | |
406 } T_MFW_SMS_MEM_INFO; | |
407 | |
408 /* SMS parameters */ | |
409 typedef struct | |
410 { | |
411 CHAR sc_addr[MAX_LEN]; /* service centre address */ | |
412 SHORT prot_id; /* protocol identifier */ | |
413 SHORT dcs; /* data coding scheme */ | |
414 UBYTE srr; /* status report request */ | |
415 UBYTE rp; /* reply path */ | |
416 UBYTE rd; /* reject duplicates */ | |
417 UBYTE vp_mode; /* validity period mode */ | |
418 UBYTE vp_rel; /* validity period relative */ | |
419 T_MFW_SMS_SCTP vp_abs; /* validity period absolute */ | |
420 SHORT first_oct; /* First Octet*/ | |
421 } T_MFW_SMS_INFO; | |
422 | |
423 /* Identification to incomming message */ | |
424 typedef struct | |
425 { | |
426 UBYTE mem; /* indicate the memory for stored message */ | |
427 UBYTE index; /* index of message */ | |
428 UBYTE concat_status; /* status of concatenated */ | |
429 UBYTE received_sms_type; /* type of sms */ | |
430 } T_MFW_SMS_ID; | |
431 | |
432 /* Information about mobile terminated short message */ | |
433 typedef struct | |
434 { | |
435 CHAR tag[MFW_TAG_LEN]; | |
436 #ifdef NO_ASCIIZ | |
437 UBYTE len; /* length of name */ | |
438 UBYTE dummy1; | |
439 UBYTE dummy2; | |
440 UBYTE dummy3; | |
441 #endif | |
442 CHAR number[MFW_NUM_LEN]; | |
443 T_MFW_PHB_TON ton; | |
444 T_MFW_PHB_NPI npi; | |
445 } T_MFW_SMS_ADDR; | |
446 | |
447 | |
448 typedef struct | |
449 { | |
450 UBYTE index; /* index of message */ | |
451 T_MFW_SMS_ADDR orig_addr; /* call party address */ | |
452 CHAR sc_addr[MAX_LEN]; /* service centre address */ | |
453 UBYTE prot_id; /* protocol identifier */ | |
454 SHORT dcs; /* data coding scheme */ | |
455 UBYTE rp; /* reply path */ | |
456 UBYTE ti; /* type indicator */ | |
457 T_MFW_SMS_SCTP sctp; /* service centre timestamp */ | |
458 USHORT/*UBYTE*/ msg_len; /* length of short message */ | |
459 CHAR sms_msg[MAX_MSG_LEN_ARRAY]; /* short message */ | |
460 UBYTE udh_len; /* length of user data header */ | |
461 UBYTE udh[BASIC_MAX_MSG_LEN]; /* user data header */ | |
462 T_MFW_SMS_STAT sms_msg_type; //x0pleela 01 Feb, 2006 DR: OMAPS00059261 /* sms message type: MT text or MT status report*/ | |
463 BOOL voicemail;/*SPR#1408 - DS - TRUE if a voicemail message. Port of 1669*/ | |
464 T_MFW_SMS_MEM memory; /*a0393213 OMAPS00109953 - memory (SIM/ME) where the message is stored*/ | |
465 } T_MFW_SMS_MT; | |
466 | |
467 /* Incomming call broadcast message */ | |
468 typedef struct | |
469 { | |
470 SHORT sn; /* serial number in integer format */ | |
471 USHORT msg_id; /* message identification */ | |
472 UBYTE dcs; /* data coding scheme */ | |
473 UBYTE page; /* number of this page */ | |
474 UBYTE pages; /* number of total pages */ | |
475 UBYTE msg_len; /* length of short message */ | |
476 CHAR cb_msg[MAX_CBMSG_LEN]; /* cell broadcast message */ | |
477 } T_MFW_SMS_CB; | |
478 | |
479 /* Parameter for cell broadcast message */ | |
480 typedef struct | |
481 { | |
482 UBYTE mode; /* acception mode: 0 - accept, 1 - not accept */ | |
483 #ifdef FF_2TO1_PS | |
484 USHORT msg_id[CBM_MAX_RANGE_NUMBER]; /* message identifier */ | |
485 UBYTE dcs[CBM_MAX_RANGE_NUMBER]; /* data coding schemes */ | |
486 #else | |
487 USHORT msg_id[MAX_IDENTS]; /* message identifier */ | |
488 UBYTE dcs[MAX_IDENTS]; /* data coding schemes */ | |
489 #endif | |
490 UBYTE dummy; | |
491 } T_MFW_SMS_CB_INFO; | |
492 | |
493 /* Information for mobile originated short message */ | |
494 typedef struct | |
495 { | |
496 T_MFW_SMS_ADDR dest_addr; /* called party address */ | |
497 CHAR sc_addr[MAX_LEN]; /* service centre address */ | |
498 UBYTE prot_id; /* protocol identifier */ | |
499 SHORT dcs; /* data coding scheme */ | |
500 UBYTE status; /* status of sms message */ | |
501 UBYTE vp_mode; /* validity period mode */ | |
502 UBYTE vp_rel; /* validity period relative */ | |
503 T_MFW_SMS_SCTP vp_abs; /* validity period absolute */ | |
504 CHAR sms_msg[MAX_MSG_LEN_ARRAY]; /* short message */ | |
505 USHORT msg_len; /* length of short message */ | |
506 UBYTE msg_ref; /* message reference */ | |
507 T_MFW_SMS_MEM memory; /*a0393213 OMAPS00109953 - memory(SIM/ME) where the message is saved*/ | |
508 } T_MFW_SMS_MO; | |
509 | |
510 /* Status report for short message */ | |
511 typedef struct | |
512 { | |
513 SHORT msg_id; /* message type */ | |
514 UBYTE msg_ref; /* message Reference */ | |
515 T_MFW_SMS_ADDR addr; /* called party address */ | |
516 UBYTE status; /* status of sms message */ | |
517 T_MFW_SMS_SCTP rctp; /* received sms timestamp */ | |
518 } T_MFW_SMS_STATUS; | |
519 /***************************Go-lite Optimization changes Start***********************/ | |
520 //Oct 04, 2004 REF: CRR 25519 Deepa M.D | |
521 //Structure elements (T_MFW_SMS_MSG)are realigned to avoid the structure padding | |
522 typedef struct | |
523 { | |
524 T_MFW_SMS_STAT stat; | |
525 T_MFW_SMS_STAT msg_type; /* voice mail status */ | |
526 T_MFW_SMS_CONC_STAT concat_status;/*2260*/ | |
527 T_MFW_SMS_ADDR addr; | |
528 T_MFW_SMS_SCTP rctp; | |
529 SHORT index; | |
530 SHORT first_index;/*index of first sms in concat assembly SPR 2260*/ | |
531 USHORT msg_ref; | |
532 T_MFW_SMS_MEM mem; /*a0393213 OMAPS00109953 - memory where the sms is stored (SIM or ME)*/ | |
533 T_MFW_SMS_MEM first_mem; /*a0393213 OMAPS00109953 - memory where the first segment in cSMS is stored (SIM or ME)*/ | |
534 } T_MFW_SMS_MSG;/*structure used in message list*/ | |
535 /***************************Go-lite Optimization changes end***********************/ | |
536 // PATCH JPS 29.09: new structure used in mfw_index_list | |
537 typedef struct | |
538 { | |
539 SHORT index; | |
540 T_MFW_SMS_STAT stat; | |
541 T_MFW_SMS_STAT msg_type; | |
542 T_MFW_SMS_CONC_STAT concat_status;/*SPR 2260*/ | |
543 T_MFW_SMS_MEM memory; /*a0393213 OMAPS00109953 - memory where the sms is stored (SIM or ME)*/ | |
544 } T_MFW_SMS_IDX;/*structure passed in sms_copy_idx() function,used externally*/ | |
545 // PATCH JPS 29.09 END | |
546 | |
547 /* | |
548 * SMS event Parameter | |
549 */ | |
550 typedef union | |
551 { | |
552 T_MFW_SMS_ID sms_id; | |
553 T_MFW_SMS_MT sms_mt; | |
554 T_MFW_SMS_MO sms_mo; | |
555 T_MFW_SMS_CB sms_cb; | |
556 T_MFW_SMS_STATUS sms_status; | |
557 T_MFW_SMS_MEM_INFO sms_mem; | |
558 UBYTE index; | |
559 UBYTE cmd_ind; | |
560 } T_MFW_SMS_PARA; | |
561 | |
562 /*a0393213 OMAPS00109953 - SMS indexes are retrieved during bootup. | |
563 This enum shall be used to maintain the state machine during that process*/ | |
564 typedef enum | |
565 { | |
566 MFW_SMS_INDEX_NOT_RETRIEVED=0, | |
567 MFW_SMS_SIM_INDEX_RETRIEVING, | |
568 MFW_SMS_FFS_INDEX_RETRIEVING, | |
569 MFW_SMS_INDEX_RETRIEVED | |
570 } T_MFW_SMS_INDEX_RETRIEVE_STATE; | |
571 | |
572 /*a0393213 OMAPS00109953 - this function updates the SMS memory details of SIM/ME*/ | |
573 static void sms_update_memory(); | |
574 | |
575 EXTERN void sms_init (void); | |
576 EXTERN void sms_exit (void); | |
577 EXTERN T_MFW_HND sms_create (T_MFW_HND hWin, | |
578 T_MFW_EVENT event, | |
579 T_MFW_CB cbfunc); | |
580 EXTERN T_MFW_RES sms_delete (T_MFW_HND h); | |
581 | |
582 #ifdef NO_ASCIIZ | |
583 | |
584 #if defined (FF_WAP) && defined (FF_GPF_TCPIP) | |
585 EXTERN T_MFW sms_submit (T_MFW_SMS_MO_TYPE type, | |
586 CHAR *dest_addr, | |
587 UBYTE *msg, | |
588 USHORT msg_len, | |
589 CHAR *sca); | |
590 //Dec 14, 2005 REF: MMI-FIX-OMAPS00058684 x0035544 | |
591 #ifdef FF_HOMEZONE | |
592 //Jun 14, 2005 REF: MMI-FIX-30439 x0018858 | |
593 EXTERN void sms_homezoneCBToggle(U8 Activate); | |
594 #endif | |
595 EXTERN T_MFW sms_submit_wap_sms(T_MFW_SMS_MO_TYPE type, | |
596 CHAR *dest_addr, | |
597 T_MFW_PHB_TON addr_type, | |
598 UBYTE *msg, | |
599 USHORT msg_len, | |
600 CHAR *sca, | |
601 T_MFW_PHB_TON sc_type); /* SPR#2086 - SH - Added */ | |
602 #else | |
603 | |
604 EXTERN T_MFW sms_submit (T_MFW_SMS_MO_TYPE type, | |
605 CHAR *dest_addr, | |
606 UBYTE *msg, | |
607 USHORT msg_len, | |
608 CHAR *sca); | |
609 #endif | |
610 EXTERN T_MFW sms_store (T_MFW_SMS_MO_TYPE type, | |
611 CHAR *addr, | |
612 UBYTE *msg, | |
613 USHORT msg_len, | |
614 CHAR *sca); | |
615 EXTERN T_MFW sms_change (CHAR *addr, | |
616 UBYTE *msg, | |
617 USHORT msg_len, | |
618 UBYTE index, | |
619 T_MFW_SMS_MEM sms_memory /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
620 ); | |
621 #else | |
622 | |
623 #if defined (FF_WAP) && defined (FF_GPF_TCPIP) | |
624 | |
625 EXTERN T_MFW sms_submit (T_MFW_SMS_MO_TYPE type, | |
626 CHAR *dest_addr, | |
627 T_MFW_PHB_TON addr_type, | |
628 UBYTE *msg, USHORT msg_len, | |
629 CHAR *sca, | |
630 T_MFW_PHB_TON sc_type); // sbh added length, see function itself | |
631 EXTERN T_MFW sms_submit_wap_sms(T_MFW_SMS_MO_TYPE type, | |
632 CHAR *dest_addr, | |
633 T_MFW_PHB_TON addr_type, | |
634 UBYTE *msg, | |
635 USHORT msg_len, | |
636 CHAR *sca, | |
637 T_MFW_PHB_TON sc_type); /* SPR#2086 - SH - Added */ | |
638 #else | |
639 EXTERN T_MFW sms_submit (T_MFW_SMS_MO_TYPE type, | |
640 CHAR *dest_addr, | |
641 UBYTE *msg, USHORT msg_len, | |
642 CHAR *sca); // sbh added length, see function itself | |
643 #endif | |
644 | |
645 EXTERN T_MFW sms_store (T_MFW_SMS_MO_TYPE type, | |
646 CHAR *addr, | |
647 UBYTE *msg, USHORT msg_len, | |
648 CHAR *sca); // sbh added length, see function itself | |
649 EXTERN T_MFW sms_change (CHAR *addr, | |
650 UBYTE *msg, USHORT msg_len, | |
651 UBYTE index, | |
652 T_MFW_SMS_MEM sms_memory /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
653 ); // sbh added length, see function itself | |
654 #endif | |
655 EXTERN T_MFW sms_stored_submit (CHAR *dest_addr, | |
656 UBYTE index); | |
657 /*SPR 2260, added concatenated status parameter*/ | |
658 EXTERN T_MFW sms_store_new_msg_info(UBYTE index, T_ACI_CMGL_SM* sm, UBYTE update_mem, T_CONC_ASSEMBLY_RETURN conc_stat | |
659 ,T_SMS_TYPE received_sms_type, T_MFW_SMS_MEM mem); /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
660 | |
661 | |
662 EXTERN T_MFW sms_send_new_msg_ind(T_ACI_CMGL_SM* sm,UBYTE index, UBYTE mem, UBYTE received_sms_type, UBYTE concatenated_status); | |
663 | |
664 EXTERN T_MFW sms_set_pref_memory (UBYTE mem); | |
665 EXTERN T_MFW sms_read (UBYTE type, UBYTE index | |
666 ,T_MFW_SMS_MEM mem); /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
667 | |
668 EXTERN T_MFW sms_mt_store (T_MFW_SMS_MT *mt_msg, | |
669 T_MFW_SMS_STAT stat); | |
670 EXTERN T_MFW sms_msg_delete (UBYTE index | |
671 , T_MFW_SMS_MEM sms_memory); /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
672 | |
673 EXTERN T_MFW sms_get_memset (void); | |
674 EXTERN T_MFW sms_command (CHAR *dest_addr, | |
675 UBYTE command, | |
676 UBYTE msg_ref); | |
677 EXTERN T_MFW sms_parameter (T_MFW_SMS_INFO *sms_info, BOOL fGet); | |
678 EXTERN T_MFW sms_set_SrvCntr_number (T_MFW_SMS_INFO *sms_info); | |
679 EXTERN T_MFW sms_set_dcs_number (T_MFW_SMS_INFO *sms_info);//GW Added | |
680 EXTERN T_MFW sms_set_val_period (T_MFW_SMS_INFO *sms_info);//GW Added | |
681 EXTERN T_MFW sms_set_cell_broadcast_info (UBYTE mode, | |
682 T_MFW_SMS_CB_INFO *sms_cb_info); | |
683 EXTERN T_MFW sms_get_cell_broadcast_info (T_MFW_SMS_CB_INFO *sms_cb_info); | |
684 EXTERN void sms_set_mt_ind (T_MFW_SMS_MT_IND sms_ind); | |
685 EXTERN SHORT sms_message_count (T_MFW_SMS_STAT stat); | |
686 EXTERN SHORT sms_message_list (T_MFW_SMS_STAT stat, | |
687 T_MFW_SMS_MSG * msg_list, | |
688 int max_entries); | |
689 // PATCH JPS 29.09: add function equivalent of sms_message_list bu more economic | |
690 EXTERN SHORT sms_index_list (T_MFW_SMS_STAT stat, | |
691 T_MFW_SMS_IDX * msg_list, | |
692 int max_entries); | |
693 // PATCH JPS 29.09 END | |
694 /*a0393213 OMAPS00109953 - memory added as parameter*/ | |
695 EXTERN T_MFW sms_change_read_status (SHORT index | |
696 , T_MFW_SMS_MEM sms_memory); | |
697 | |
698 //x0018858 24 Mar, 2005 MMI-FIX-11321 | |
699 //begin -MMI-FIX-11321 | |
700 EXTERN T_MFW sms_set_cind_values(T_ACI_MM_CIND_VAL_TYPE *cindSettings); | |
701 EXTERN T_MFW sms_set_cmer_values(T_ACI_MM_CMER_VAL_TYPE *cmerSettings); | |
702 //end -MMI-FIX-11321 | |
703 | |
704 /* Added to remove warning */ | |
705 EXTERN UBYTE dspl_Enable (UBYTE in_Enable); | |
706 | |
707 #endif |