4 * Copyright (c) 2012 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Ja-young Gu <jygu@samsung.com>
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
21 #ifndef __TYPE_SMS_H__
22 #define __TYPE_SMS_H__
27 TREQ_SMS_SEND_UMTS_MSG,
34 TREQ_SMS_GET_CB_CONFIG,
35 TREQ_SMS_SET_CB_CONFIG,
36 TREQ_SMS_SET_MEM_STATUS,
37 TREQ_SMS_GET_PREF_BEARER,
38 TREQ_SMS_SET_PREF_BEARER,
39 TREQ_SMS_SET_DELIVERY_REPORT,
40 TREQ_SMS_SET_MSG_STATUS,
43 TREQ_SMS_GET_PARAMCNT,
44 TREQ_SMS_SEND_CDMA_MSG,
46 TREQ_PS_ACTIVATE_CONTEXT,
47 TREQ_PS_DEACTIVATE_CONTEXT,
49 TREQ_PS_PDP_DEACTIVATE,
51 TREQ_PS_SET_PORT_LIST,
52 TREQ_PS_GET_PORT_LIST,
53 TREQ_PS_DUN_PIN_CONTROL,
56 /*==================================================================================================
58 ==================================================================================================*/
61 #define SMS_SMSP_ADDRESS_LEN 20 /* EF-SMSP digit length */
62 #define SMS_SMSP_ALPHA_ID_LEN_MAX 128 /* EF-SMSP alpha id length */
63 #define SMS_MAX_EFSMSP_RECORD_LENGTH 156 /* Maximum number of bytes SMSP Record size (Y + 28), y : 0 ~ 128 */
65 #define SMS_MSG_SIZE_MAX 918 /**< Maximum Message Size */
66 #define SMS_CB_SIZE_MAX 93 /** Maximum CB Message Size */
67 #define SMS_ETWS_SIZE_MAX 56 /** Maximum ETWS Message Size */
69 #define SMS_ENCODED_SCA_LEN_MAX 12 /* Encoded SCA is 12 bytes long maximum */
71 #define SMS_CB_PAGE_SIZE_MAX 9 /**< CB maximum page size*/
72 #define SMS_GSM_SMS_MSG_NUM_MAX 255 /**< Maximum GSM SMS message number*/
73 #define SMS_GSM_SMS_CBMI_LIST_SIZE_MAX 50 /**< Maximum GSM SMS CBMI list size*/
74 #define SMS_SMDATA_SIZE_MAX 164 /**< Maximum SMS data size that can be stored*/
75 #define SMS_MAX_INDEX 255 /**< Maximum index value for SMS */
77 #define SMS_SMSP_PARAMS_MAX_LEN 28
79 // ************************ CDMA Features **************************//
80 #define SMS_PARAM_TELESERVICE_MASK 1 << 0 /**< Teleservice parameter bit position */
81 #define SMS_PARAM_SERVICE_CATEGORY_MASK 1 << 1 /**< Service Category parameter bit position */
82 #define SMS_PARAM_ADDRESS_MASK 1 << 2 /**< Address parameter bit position */
83 #define SMS_PARAM_SUBADDRESS_MASK 1 << 3 /**< Subaddress parameter bit position */
84 #define SMS_PARAM_BEARER_REPLY_MASK 1 << 4 /**< Bearer reply parameter bit position */
85 #define SMS_PARAM_CAUSE_CODES_MASK 1 << 5 /**< Cause Code parameter bit position */
86 #define SMS_PARAM_MESSAGE_ID_MASK 1 << 6 /**< Message ID parameter bit position */
87 #define SMS_PARAM_USER_DATA_MASK 1 << 7 /**< User Data parameter bit position */
88 #define SMS_PARAM_USER_RESPONSE_CODE_MASK 1 << 8 /**< User Response Code parameter bit position */
89 #define SMS_PARAM_MC_TIME_STAMP_MASK 1 << 9 /**< Message Center Timestamp parameter bit position */
90 #define SMS_PARAM_VALIDITY_PERIOD_ABS_MASK 1 << 10 /**< Valid period Absolute parameter bit position */
91 #define SMS_PARAM_VALIDITY_PERIOD_REL_MASK 1 << 11 /**< Valid period Relative parameter bit position */
92 #define SMS_PARAM_DEFERRED_DELIVERY_ABS_MASK 1 << 12 /**< Deferred delivery absolute parameter bit position */
93 #define SMS_PARAM_DEFERRED_DELIVERY_REL_MASK 1 << 13 /**< Deferred delivery relative parameter bit position */
94 #define SMS_PARAM_PRIORITY_MASK 1 << 14 /**< Priority parameter bit position */
95 #define SMS_PARAM_PRIVACY_MASK 1 << 15 /**< Privacy parameter bit position */
96 #define SMS_PARAM_REPLY_OPTION_MASK 1 << 16 /**< Reply Option parameter bit position */
97 #define SMS_PARAM_NUMBER_OF_MESSAGE_MASK 1 << 17 /**< Number of message parameter bit position */
98 #define SMS_PARAM_ALERT_ON_DELIVERY_MASK 1 << 18 /**< Alert on delivery parameter bit position */
99 #define SMS_PARAM_LANGUAGE_MASK 1 << 19 /**< Language parameter bit position */
100 #define SMS_PARAM_CALLBACK_MASK 1 << 20 /**< Callback Number parameter bit position */
101 #define SMS_PARAM_DISPLAY_MODE_MASK 1 << 21 /**< Display mode parameter bit position */
102 #define SMS_PARAM_MULTI_ENCODING_USER_DATA_MASK 1 << 22 /**< Multi Encoding user data parameter bit position */
104 #define SMS_MAXLENGTH_SMS_MT_USER_DATA 160 /**< Maximum MT user data size*/
105 #define SMS_MAXLENGTH_SMS_MO_USER_DATA 160 /**< Maximum MO user data size*/
107 #define SMS_MAXLENGTH_SMS_ADDRESS 32 /**< MAX sms destination(or origination ) address /call back number */
109 #define SMS_ERR_CLASS0_STATUS_SEND_OK 0 /**< send success */
110 #define SMS_ERR_CLASS23_ADDRESS_VACANT 0 /**< address vacant */
111 #define SMS_ERR_CLASS23_ADDRESS_TRANSLATION_FAILURE 1 /**< address translation failure */
112 #define SMS_ERR_CLASS23_NETWORK_RESOURCE_SHORTAGE 2 /**< network resource shortage */
113 #define SMS_ERR_CLASS23_NETWORK_FAILURE 3 /**< network failure */
114 #define SMS_ERR_CLASS23_INVALID_TELESERVICE_ID 4 /**< invalid teleservice id */
115 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM 5 /**< other network problem */
116 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM_MORE_FIRST 6 /**< other network problem more first */
117 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM_MORE_LAST 31 /**< other network problem more last */
118 #define SMS_ERR_CLASS23_NO_PAGE_RESPONSE 32 /**< no page response */
119 #define SMS_ERR_CLASS23_DESTINATION_BUSY 33 /**< destination busy */
120 #define SMS_ERR_CLASS23_NO_ACK 34 /**< no ack */
121 #define SMS_ERR_CLASS23_DESTINATION_RESOURCE_SHORTAGE 35 /**< destination resource shortage */
122 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED 36 /**< sms delivery postponed */
123 #define SMS_ERR_CLASS23_DESTINATION_OUT_OF_SERVICE 37 /**< destination out of service */
124 #define SMS_ERR_CLASS23_DESTINATION_NO_LONGER_AT_THIS_ADDRESS 38 /**< destination no longer at this address */
125 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM 39 /**< other terminal problem */
126 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM_MORE_FIRST 40 /**< other terminal problem more first */
127 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM_MORE_LAST 47 /**< other terminal problem more last */
128 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED_MORE_FIRST 48 /**< sms delivery postpone more first */
129 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED_MORE_LAST 63 /**< sms delivery postpone more last */
130 #define SMS_ERR_CLASS23_RADIO_IF_RESOURCE_SHORTAGE 64 /**< radio interface resource shortage */
131 #define SMS_ERR_CLASS23_RADIO_IF_INCOMPATIBLE 65 /**< radio interface incompatible */
132 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM 66 /**< other radio interface problem */
133 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM_MORE_FIRST 67 /**< other radio interface problem more first */
134 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM_MORE_LAST 95 /**< other radio interface problem more last */
135 #define SMS_ERR_CLASS23_UNEXPECTED_PARM_SIZE 96 /**< unexpected parameter size */
136 #define SMS_ERR_CLASS23_SMS_ORIGINATION_DENIED 97 /**< sms origination denied */
137 #define SMS_ERR_CLASS23_SMS_TERMINATION_DENIED 98 /**< sms termination denied */
138 #define SMS_ERR_CLASS23_SUPPL_SERVICE_NOT_SUPPORTED 99 /**< supplementary service not supported */
139 #define SMS_ERR_CLASS23_SMS_NOT_SUPPORTED 100 /**< sms not supported */
140 #define SMS_ERR_CLASS23_RESERVED_101 101 /**< reserved 101 */
141 #define SMS_ERR_CLASS23_MISSING_EXPECTED_PARM 102 /**< missing expected parameter */
142 #define SMS_ERR_CLASS23_MISSING_MANDATORY_PARM 103 /**< missing mandatory parameter value */
143 #define SMS_ERR_CLASS23_UNRECOGNIZED_PARM_VALUE 104 /**< unrecognized parameter value */
144 #define SMS_ERR_CLASS23_UNEXPECTED_PARM_VALUE 105 /**< unexpected parameter value */
145 #define SMS_ERR_CLASS23_USER_DATA_SIZE_ERROR 106 /**< user data size error */
146 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS 107 /**< other general problem */
147 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS_MORE_FIRST 108 /**< other general problem first */
148 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS_MORE_LAST 255 /**< other general problem last */
150 #define SMS_ERR_CLASS4_WAITING_FOR_TL_ACK 1 /**< waiting for transport ack */
151 #define SMS_ERR_CLASS4_OUT_OF_RESOURCES 2 /**< out of resource */
152 #define SMS_ERR_CLASS4_ACCESS_TOO_LARGE 3 /**< access to large */
153 #define SMS_ERR_CLASS4_DTC_TOO_LARGE 4 /**< DTC too large */
154 #define SMS_ERR_CLASS4_DTC_CONNECTED 5 /**< DTC connected */
155 #define SMS_ERR_CLASS4_NETWORK_NOT_READY 6 /**< network not ready */
156 #define SMS_ERR_CLASS4_NO_SVC 7 /**< no service */
157 #define SMS_ERR_CLASS4_PHONE_NOT_READY 8 /**< phone not ready */
158 #define SMS_ERR_CLASS4_NOT_ALLOWED_IN_AMPS 9 /**< fail to allowed in amps */
159 #define SMS_ERR_CLASS4_CANNOT_SEND_BROADCAST 10 /**< fail to send broadcast */
160 #define SMS_ERR_CLASS4_INVALID_TRANSACTION_ID
161 // ********************************************************************//
163 /*==================================================================================================
165 ==================================================================================================*/
167 * @enum telephony_sms_MsgStatus_t
168 * This enumeration defines the network text status type.
170 enum telephony_sms_MsgStatus {
171 SMS_STATUS_READ, /**< MT message, stored and read */
172 SMS_STATUS_UNREAD, /**< MT message, stored and unread */
173 SMS_STATUS_SENT, /**< MO message, stored and sent */
174 SMS_STATUS_UNSENT, /**< MO message, stored but not sent */
175 SMS_STATUS_DELIVERED, /**< delivered destination */
176 SMS_STATUS_DELIVERY_UNCONFIRMED, /**< Service centre forwarded message but is unable to confirm delivery*/
177 SMS_STATUS_MESSAGE_REPLACED, /**< Message has been replaced*/
178 SMS_STATUS_RESERVED /**< Reserved for future use*/
182 * @enum telephony_sms_MemStatusType
183 * This enumeration defines the memory status type.
185 enum telephony_sms_MemStatusType {
186 SMS_PDA_MEMORY_STATUS_AVAILABLE = 0x01, /**< PDA Memory Available */
187 SMS_PDA_MEMORY_STATUS_FULL = 0x02, /**< PDAMemory is Full */
188 SMS_PHONE_MEMORY_STATUS_AVAILABLE = 0x03, /**< Phone memory Available */
189 SMS_PHONE_MEMORY_STATUS_FULL = 0x04, /**< phone memory is full */
193 * @enum telephony_sms_BearerType_t
194 * This enum defines the different bearer types
196 enum telephony_sms_BearerType {
197 SMS_BEARER_PS_ONLY = 0x01, /**< Send SMS only on PS Bearer */
198 SMS_BEARER_CS_ONLY, /**< Send SMS only on CS Bearer */
199 SMS_BEARER_PS_PREFERRED, /**<Send SMS preferably on PS Bearer*/
200 SMS_BEARER_CS_PREFERRED , /**<Send SMS preferably on CS Bearer*/
201 SMS_NO_PREFERRED_BEARER /**<SMS is sent based on default preferred bearer set at OEM based on vendor/operator preference*/
206 * @enum telephony_sms_CbMsgType_t
207 * This enumeration defines the different CB message types.
209 enum telephony_sms_CbMsgType {
210 SMS_CB_MSG_GSM = 1, /**< GSM Cell broadcast message */
211 SMS_CB_MSG_UMTS /**< UMTS Cell broadcast message */
215 * @enum telephony_sms_etws_type
216 * This enumeration defines the different ETWS message types.
218 enum telephony_sms_etws_type {
219 SMS_ETWS_MSG_PRIMARY = 0, /**< PRIMARY ETWS Message */
220 SMS_ETWS_MSG_SECONDARY_GSM, /**< SECONDARY GSM ETWS Message */
221 SMS_ETWS_MSG_SECONDARY_UMTS /**< SECONDARY UMTS ETWS Message */
225 * @enum telephony_sms_Response_t
226 * This enum defines the different response types that come in the
227 * sent status acknowledgement/notification after sending a message to the network
229 enum telephony_sms_Response {
230 SMS_SENDSMS_SUCCESS = 0x00, /**<Message send success*/
231 SMS_ROUTING_NOT_AVAILABLE, /**< Message routing not available*/
232 SMS_INVALID_PARAMETER, /**< Invalid parameter present in TPDU*/
233 SMS_DEVICE_FAILURE, /**< Device failure*/
234 SMS_SERVICE_RESERVED, /**< Reserved Service*/
235 SMS_INVALID_LOCATION, /**< Invalid location*/
236 SMS_NO_SIM, /**< No SIM error*/
237 SMS_SIM_NOT_READY, /**< SIM not ready error*/
238 SMS_NO_NETWORK_RESP, /**< No response from network*/
239 SMS_DEST_ADDRESS_FDN_RESTRICTED, /**< Destination address restricted*/
240 SMS_SCADDRESS_FDN_RESTRICTED, /**< Service center address restricted*/
241 SMS_RESEND_ALREADY_DONE, /**< Resend a operation already done*/
242 SMS_SCADDRESS_NOT_AVAILABLE, /**< SCA address not available*/
243 SMS_UNASSIGNED_NUMBER = 0x8001, /**< Unassigned number*/
244 SMS_OPERATOR_DETERMINED_BARRING = 0x8008, /**< Operator determined barring*/
245 SMS_CALL_BARRED = 0x800A, /**< Call barred*/
246 SMS_MESSAGE_TRANSFER_REJECTED = 0x8015, /**< Message transfer rejected*/
247 SMS_MEMORY_CAPACITY_EXCEEDED = 0x8016, /**< Memory capacity exceeded/memory full*/
248 SMS_DESTINAITION_OUTOFSERVICE = 0x801B, /**< Destination number/address out of service*/
249 SMS_UNSPECIFIED_SUBSCRIBER = 0x801C, /**< Unspecified subscriber*/
250 SMS_FACILITY_REJECTED = 0x801D, /**< Facility rejected*/
251 SMS_UNKNOWN_SUBSCRIBER = 0x801E, /**< Unknown subscriber*/
252 SMS_NETWORK_OUTOFORDER = 0x8026, /**< Network out of order*/
253 SMS_TEMPORARY_FAILURE = 0x8029, /**< Temporary failure*/
254 SMS_CONGESTION = 0x802A, /**< Congestion happened*/
255 SMS_RESOURCES_UNAVAILABLE = 0x802F, /**< Resource unavailable*/
256 SMS_FACILITY_NOT_SUBSCRIBED = 0x8032, /**< Facility not subscribed by the user*/
257 SMS_FACILITY_NOT_IMPLEMENTED = 0x8045, /**< Facility not implemented*/
258 SMS_INVALID_REF_VALUE = 0x8051, /**< Invalid reference value*/
259 SMS_INVALID_MSG = 0x805F, /**< Invalid message*/
260 SMS_INVALID_MANDATORY_INFO = 0x8060, /**< Invalid Mandatory information*/
261 SMS_MESSAGE_TYPE_NOT_IMPLEMENTED = 0x8061, /**< Message type not implemented*/
262 SMS_MESSAGE_NOT_COMPAT_PROTOCOL = 0x8062, /**< Message not compact protocol*/
263 SMS_IE_NOT_IMPLEMENTED = 0x8063, /**< Information element not implemented*/
264 SMS_PROTOCOL_ERROR = 0x806F, /**< Protocol error*/
265 SMS_INTERWORKING = 0x807F, /**< Networking error*/
266 SMS_ME_FULL = 0x8080, /**< SMS ME FULL */
267 SMS_SIM_FULL = 0x8081, /**< SMS SIM FULL */
268 SMS_TIMEOUT /**< Timeout error */
271 /** @enum telephony_sms_Cause_t
272 * This enum defines the different cause types that come in the
273 * sent status acknowledgement/notification after sending a message to the network
276 enum telephony_sms_Cause {
278 SMS_SUCCESS, /**< SMS Operation successful*/
279 SMS_INVALID_PARAMETER_FORMAT, /**< Invalid format for some parameters passed in Data package information(TPDU)*/
280 SMS_PHONE_FAILURE, /**<SMS operation failed due to Modem failure*/
281 SMS_SIM_BUSY, /**< SMS SIM operation cannot be performed as SIM is busy with some other operation*/
282 SMS_SIM_FAILURE, /**< SMS SIM operation cannot be performed due to SIM failure */
283 SMS_UNKNOWN, /**< unknown error*/
284 SMS_MEMORY_FAILURE, /**< Error while accessing memory or allocation of memory for SMS operation.*/
285 SMS_OPERATION_NOT_SUPPORTED /**< operation not allowed/supported*/
289 * @enum telephony_sms_SetResponse
290 * This defines the response values
292 enum telephony_sms_SetResponse {
293 SMS_CBSETCONFIG_RSP, /**< cellbroadcast config response */
294 SMS_SETPREFERREDBEARER_RSP, /**< set preferred bearer response */
295 SMS_SETPARAMETERS_RSP, /**< set parameter response */
296 SMS_SETMEMORYSTATUS_RSP, /**< set memory status response*/
297 SMS_SETMESSAGESTATUS_RSP, /**< set message status response*/
298 SMS_SETDEVICESTATUS_RSP, /**< set device status response*/
299 SMS_SETSCADDR_RSP, /**< set SCA address response */
300 SMS_SET_RSP_MAX /**< maximum limit*/
304 * @enum telephony_sms_3gpp_type
305 * This defines the type of 3gpp
307 enum telephony_sms_3gpp_type {
308 SMS_NETTYPE_3GPP = 0x01, /**< 3gpp type */
309 SMS_NETTYPE_3GPP2, /**< 3gpp2 type (CDMA) */
314 * This structure defines the fields related to an Sms like SIM index, TPDU
317 struct telephony_sms_DataPackageInfo {
319 * Service Centre address - an optional parameter. If this parameter
320 * is not present, then this field will be Null.If present, the valid
321 * service centre address information is filled as per 3GPP TS23.040
322 * 9.1.2.5 Address fields
324 unsigned char sca[SMS_ENCODED_SCA_LEN_MAX];
325 /* Size of array szData (which is actual TPDU message) */
327 /* SMS TPDU message */
328 unsigned char tpduData[SMS_SMDATA_SIZE_MAX + 1];
332 *This structure defines the data Related to SimIndex,MessageStatus and SMS Data Stored.
334 struct telephony_sms_Data {
335 int simIndex; /**< Index where SMS is stored. */
336 enum telephony_sms_MsgStatus msgStatus; /**< Message status.*/
337 struct telephony_sms_DataPackageInfo smsData; /**<SMS message */
340 struct telephony_sms_AddressInfo {
341 unsigned int dialNumLen; /* length of address. If Service center address is not set, then this will be zero */
342 int typeOfNum; /* Type of number*/
343 int numPlanId; /* Numbering plan identification*/
344 unsigned char diallingNum[SMS_SMSP_ADDRESS_LEN + 1]; /* destination address. If Address not set, then set to 0xFF */
348 * This structure defines different fields involved in setting the parameters of
349 * a particular sms in EFsmsp.
351 struct telephony_sms_Params {
353 unsigned char recordIndex; /**< Index*/
354 unsigned char recordLen; /**< SMS Parameter Record length*/
355 unsigned long alphaIdLen; /**< Alpha id length */
356 char szAlphaId[SMS_SMSP_ALPHA_ID_LEN_MAX + 1]; /**< Alpha id .It is a unique identifier for each row/record in EFsmsp */ //JYGU: TAPI_SIM_SMSP_ALPHA_ID_LEN_MAX 128
357 unsigned char paramIndicator; /**< SMS parameter indicator is a 1 byte value. Each bit in this value indicates the presence/absence of the sms header parameters.If the parameter is present the corresponding bit value is set to 0.If the parameter is absent then it is set as 1.Refer 3GPP TS 31.02 :4.4.23 */
358 struct telephony_sms_AddressInfo tpDestAddr; /**< TP-destination address (TP-DA) */
359 struct telephony_sms_AddressInfo tpSvcCntrAddr; /**< TP-service center address */
360 unsigned short tpProtocolId; /**< TP-protocol Id */
361 unsigned short tpDataCodingScheme; /**< TP-data coding scheme */
362 unsigned short tpValidityPeriod; /**< TP-validity period */
366 * This structure defines the different parameters that are related to the message count
367 *in a particular memory(Phone/SIM)
369 struct telephony_sms_StoredMsgCountInfo {
370 unsigned int totalCount; /**< Total count of messages stored in SIM*/
371 int usedCount; /**< Stored message count in SIM in SIM*/
372 int indexList[SMS_GSM_SMS_MSG_NUM_MAX]; /**< Message index list stored in SIM. And the maximum size of this array can be of totalCount.This array contains the list of index values in which the messages are stored.i.e. index_list[totalcount] = [2,3] denotes that indexs 2 and 3 are stored(valid) and others not(empty).*/
376 * This structure defines a cell broadcast message.
378 struct telephony_sms_CbMsg {
380 enum telephony_sms_CbMsgType cbMsgType; /**< Cell Broadcast message type */
381 unsigned short length; /**<Size of array szMsgData (which is actual TPDU message) */
382 char msgData[SMS_CB_SIZE_MAX + 1]; /**<Cell broadcast message data[Refer 3GPP TS 23.041 9.4.1]*/
385 struct telephony_sms_etws_msg {
387 enum telephony_sms_etws_type etwsMsgType; /**< ETWS message type */
388 unsigned short length; /**<Size of array msgData (which is actual TPDU message) */
389 char msgData[SMS_ETWS_SIZE_MAX + 1]; /**< ETWS message data[Refer 3GPP TS 23.041 9.4.1.3]*/
392 struct telephony_sms_cb_msg_info_3gpp {
393 unsigned short fromMsgId; /**< Starting point of the range of CBS message ID */
394 unsigned short toMsgId; /**< Ending point of the range of CBS message ID */
395 unsigned char selected; /**< 0x00 . Not selected. 0x01 . Selected */
398 struct telephony_sms_cb_msg_info_3gpp2 {
399 unsigned short cbCategory; /**< CB Service category */
400 unsigned short cbLanguage; /**< Language indicator value
401 . 0x00 . LANGUAGE_UNKNOWN .
402 Unknown or Unspecified
403 . 0x01 . LANGUAGE_ENGLISH . English
404 . 0x02 . LANGUAGE_FRENCH . French
405 . 0x03 . LANGUAGE_SPANISH . Spanish
406 . 0x04 . LANGUAGE_JAPANESE . Japanese
407 . 0x05 . LANGUAGE_KOREAN . Korean
408 . 0x06 . LANGUAGE_CHINESE . Chinese
409 . 0x07 . LANGUAGE_HEBREW . Hebrew*/
410 unsigned char selected; /**< 0x00 . Not selected. 0x01 . Selected */
413 union telephony_sms_cb_msg_info_u {
414 struct telephony_sms_cb_msg_info_3gpp net3gpp; /**< 3GPP Broadcast Configuration Information */
415 struct telephony_sms_cb_msg_info_3gpp2 net3gpp2; /**< 3GPP2 Broadcast Configuration Information, CDMA*/
418 struct telephony_sms_CbConfig {
419 int net3gppType; /**< Type of 3gpp, 0x01 . 3gpp. 0x02 . 3gpp2(CDMA) */
420 int cbEnabled; /**< CB service state. If cb_enabled is true then cell broadcast service will be enabled and underlying modem will enable CB Channel to receiving CB messages. Otherwise CB service will be disabled, underlying modem will deactivate the CB channel. (enabled/disabled) */
421 unsigned char msgIdMaxCount; /**< CB Channel List Max Count For Response */
422 int msgIdRangeCount; /**< Range of CB message ID count */
423 union telephony_sms_cb_msg_info_u msgIDs[SMS_GSM_SMS_CBMI_LIST_SIZE_MAX]; /**< Range of CB message ID information */
427 // ************************ CDMA Features **************************//
428 /** @enum telephony_sms_Is637AlertPriority_t
429 * This enum defines the type of alerts used to distinguish different priorities
432 enum telephony_sms_Is637AlertPriority {
433 SMS_ALERT_PRIORITY_DEFAULT = 0, /* Mobile default alert */
434 SMS_ALERT_PRIORITY_LOW, /* Low priority alert */
435 SMS_ALERT_PRIORITY_MEDIUM, /* Medium priority alert */
436 SMS_ALERT_PRIORITY_HIGH, /* High priority alert */
439 /** @enum telephony_sms_Is637Privacy_t
440 * This enum defines the desired privacy level of the message
442 enum telephony_sms_Is637Privacy {
443 SMS_PRIVACY_NOT_RESTRICTED = 0, /* Not restricted */
444 SMS_PRIVACY_RESTRICTED, /* Restricted */
445 SMS_PRIVACY_CONFIDENTIAL, /* Confidential */
446 SMS_PRIVACY_SECRET, /* Secret */
449 /** @enum telephony_sms_Is637Priority_t
450 * This enum defines the priority level of the message
452 enum telephony_sms_Is637Priority {
453 SMS_PRIORITY_NORMAL = 0, /* Normal */
454 SMS_PRIORITY_INTERACTIVE, /* Interactive */
455 SMS_PRIORITY_URGENT, /* Urgent */
456 SMS_PRIORITY_EMERGENCY, /* Emergency */
459 /** @enum telephony_sms_Is637LangIndicator_t
460 * This enum defines the language of the message so that the receiving mobile station can
461 * discard those messages that are not in the user's preferred language
463 enum telephony_sms_Is637LangIndicator {
464 SMS_LANG_UNKNOWN = 0x0, /* Unknown or unspecified */
465 SMS_LANG_ENGLISH, /* English */
466 SMS_LANG_FRENCH, /* French */
467 SMS_LANG_SPANISH, /* Spanish */
468 SMS_LANG_JAPANESE, /* Japanese */
469 SMS_LANG_KOREAN, /* Korean */
470 SMS_LANG_CHINESE, /* Chinese */
471 SMS_LANG_HEBREW, /* Hebrew */
474 /** @enum telephony_sms_Is637MsgDisplayMode_t
475 * This enum defines the display mode to the mobile station when to display the received message
477 enum telephony_sms_Is637MsgDisplayMode {
478 SMS_MSG_DISPLAY_IMMEDIATE = 0x0, /* The mobile station is to display the received message as soon as possible */
479 SMS_MSG_DISPLAY_DEFAULT, /* he mobile station is to display the received message based on a pre-defined mode in the mobile station. */
480 SMS_MSG_DISPLAY_USER_INVOKE = 0x3, /* The mobile station is to display the received message based on the mode selected by the user. */
481 SMS_MSG_DISPLAY_RESERVED, /* Reserved */
484 /** @enum telephony_sms_Is637ErrorClass_t
485 * This enum defines the error report class
487 enum telephony_sms_Is637ErrorClass {
488 SMS_MSG_ERROR_CLASS_NONE = 0x0, /* None error(for SMS ack) */
489 SMS_MSG_ERROR_CLASS_TEMPORARY_ERROR = 0x2, /* Temporary error(for SMS ack) */
490 SMS_MSG_ERROR_CLASS_PERMANENT_ERROR = 0x3, /* Permanent error(for SMS ack) */
491 SMS_MSG_ERROR_CLASS_PHONE_INTERNAL_ERROR = 0x4, /* Phone Internal Status (for Send status) */
494 /** @enum telephony_sms_BroadCastCategory_t
495 * This enum defines the Broadcast Service Category
497 enum telephony_sms_BroadCastCategory {
498 SMS_CATEGORY_UNKNOWN = 0x00, /* Unknown category */
499 SMS_CATEGORY_EMERGENCY = 0x01, /* Emergency category */
500 SMS_CATEGORY_ADMIN = 0x02, /* Admin category */
501 SMS_CATEGORY_MAINTENANCE = 0x03, /* Maintenance category */
502 SMS_CATEGORY_GEN_NEWS_LOC = 0x04, /* General News(Local) category */
503 SMS_CATEGORY_GEN_NEWS_REG = 0x05, /* General News(Regional) category */
504 SMS_CATEGORY_GEN_NEWS_NAT = 0x06, /* General News(National) category */
505 SMS_CATEGORY_GEN_NEWS_INT = 0x07, /* General News(International) category */
506 SMS_CATEGORY_FIN_NEWS_LOC = 0x08, /* Business/Financial News(Local) category */
507 SMS_CATEGORY_FIN_NEWS_REG = 0x09, /* Business/Financial News(Regional) category */
508 SMS_CATEGORY_FIN_NEWS_NAT = 0x0A, /* Business/Financial News(National) category */
509 SMS_CATEGORY_FIN_NEWS_INT = 0x0B, /* Business/Financial News(International) category */
510 SMS_CATEGORY_SPT_NEWS_LOC = 0x0C, /* Sports News(Local) category */
511 SMS_CATEGORY_SPT_NEWS_REG = 0x0D, /* Sports News(Regional) category */
512 SMS_CATEGORY_SPT_NEWS_NAT = 0x0E, /* Sports News(National) category */
513 SMS_CATEGORY_SPT_NEWS_INT = 0x0F, /* Sports News(International) category */
514 SMS_CATEGORY_ENT_NEWS_LOC = 0x10, /* Entertainment News(Local) category */
515 SMS_CATEGORY_ENT_NEWS_REG = 0x11, /* Entertainment News(Regional) category */
516 SMS_CATEGORY_ENT_NEWS_NAT = 0x12, /* Entertainment News(National) category */
517 SMS_CATEGORY_ENT_NEWS_INT = 0x13, /* Entertainment News(International) category */
518 SMS_CATEGORY_LOC_WEATHER = 0x14, /* Local Weather category */
519 SMS_CATEGORY_AREA_TRAFFIC = 0x15, /* Area Traffic Reports category */
520 SMS_CATEGORY_AIRPORT_SCHED = 0x16, /* Local Airport Flight Schedules category */
521 SMS_CATEGORY_RESTAURANTS = 0x17, /* Restaurants category */
522 SMS_CATEGORY_LODGINGS = 0x18, /* Lodgings category */
523 SMS_CATEGORY_RETAILS = 0x19, /* Retail Directory category */
524 SMS_CATEGORY_ADS = 0x1A, /* Advertisements category */
525 SMS_CATEGORY_STOCK_QUOTES = 0x1B, /* Stock Quotes category */
526 SMS_CATEGORY_JOBS = 0x1C, /* Employment Opportunities category */
527 SMS_CATEGORY_MEDICAL = 0x1D, /* Medical/Health/Hospitals category */
528 SMS_CATEGORY_TECH_NEWS = 0x1E, /* Technology News category */
529 SMS_CATEGORY_MULTI = 0x1F, /* Multi-category */
532 /** @enum telephony_sms_MsgType_t
533 * This enum defines the type of IS637 message
535 enum telephony_sms_CdmaMsgType {
536 SMS_MESSAGETYPE_DELIVER = 0x01, /* sms deliver message */
537 SMS_MESSAGETYPE_SUBMIT = 0x02, /* sms submit message */
538 SMS_MESSAGETYPE_CANCEL = 0x03, /* sms cancellation message */
539 SMS_MESSAGETYPE_DELIVERY_ACK = 0x04, /* sms delivery acknowledgment message */
540 SMS_MESSAGETYPE_USER_ACK = 0x05, /* sms user acknowledgment message */
541 } telephony_sms_CdmaMsgType_e;
543 /** @enum telephony_sms_Is637DigitMode_t
544 * This enum defines the type of address whether it is 4-bit mode or 8-bit mode
546 enum telephony_sms_Is637DigitMode {
547 SMS_DIGITMODE_4BITDTMF = 0x00, /* 4-bit mode */
548 SMS_DIGITMODE_8BITCODE = 0x01, /* 8-bit mode */
551 /** @enum telephony_sms_Is637NumberMode_t
552 * This enum defines the mode of address number to indicate whether the address type is as defined in ANSI TI.607 or is a data network address
554 enum telephony_sms_Is637NumberMode {
555 SMS_NUMMODE_NONE_DATANETWORK = 0x00, /* in ANSI TI.607 */
556 SMS_NUMMODE_DATANETWORK = 0x01, /* in Data Network */
559 /** @enum telephony_sms_Is637NumberType_t
560 * This enum defines the type of address
562 enum telephony_sms_Is637NumberType {
563 SMS_NUMBER_TYPE_UNKNOWN = 0x00, /* Unknown */
564 SMS_NUMBER_TYPE_INTERNATIONAL = 0x01, /* International number*/
565 SMS_NUMBER_TYPE_NATIONAL = 0x02, /* National number */
566 SMS_NUMBER_TYPE_NETWORK = 0x03, /* Abbreviated number */
567 SMS_NUMBER_TYPE_SUBSCRIBER = 0x04, /* Abbreviated number */
568 SMS_NUMBER_TYPE_RESERVED_5 = 0x05, /* Reserved */
569 SMS_NUMBER_TYPE_ABBREVIATED = 0x06, /* Abbreviated number */
570 SMS_NUMBER_TYPE_RESERVED_7 = 0x07, /* Reserved */
571 SMS_NUMBER_TYPE_IP = 0x11, /* Internet Protocol(RFC 791) */
572 SMS_NUMBER_TYPE_EMAILADDR = 0x12, /* Internet Email Address(RFC 822) */
573 } telephony_sms_Is637NumberType_e;
575 /** @enum telephony_sms_Is637NumberPlan_t
576 * This enum defines the plan of address
578 enum telephony_sms_Is637NumberPlan {
579 SMS_NUMBER_PLAN_UNKNOWN = 0x00, /* Unknown */
580 SMS_NUMBER_PLAN_TELEPHONY = 0x01, /* ISDN/Telephony numbering plan */
581 SMS_NUMBER_PLAN_RESERVED_2 = 0x02, /* Reserved */
582 SMS_NUMBER_PLAN_DATA = 0x03, /* Data numbering plan */
583 SMS_NUMBER_PLAN_TELEX = 0x04, /* CTelex numbering plan */
584 SMS_NUMBER_PLAN_RESERVED_5 = 0x05, /* Reserved */
585 SMS_NUMBER_PLAN_RESERVED_6 = 0x06, /* Reserved */
586 SMS_NUMBER_PLAN_RESERVED_7 = 0x07, /* Reserved */
587 SMS_NUMBER_PLAN_RESERVED_8 = 0x08, /* Reserved */
588 SMS_NUMBER_PLAN_PRIVATE = 0x09, /* Private numbering plan */
589 SMS_NUMBER_PLAN_RESERVED_10 = 0x0A, /* Reserved */
590 SMS_NUMBER_PLAN_RESERVED_11 = 0x0B, /* Reserved */
591 SMS_NUMBER_PLAN_RESERVED_12 = 0x0C, /* Reserved */
592 SMS_NUMBER_PLAN_RESERVED_13 = 0x0D, /* Reserved */
593 SMS_NUMBER_PLAN_RESERVED_14 = 0x0E, /* Reserved */
594 SMS_NUMBER_PLAN_RESERVED_15 = 0x0F, /* Reserved */
597 /** @enum telephony_sms_Is637SubAddressType_t
598 * This enum defines the plan of address
600 enum telephony_sms_Is637SubAddressType {
602 SMS_SUBADDR_NSAP = 0x00, /**< NSAP ( CCITT Recommendation X.213 or ISO 8348 AD2 ) */
603 SMS_SUBADDR_USER_SPECIFIED = 0x01, /**< User-specified */
607 * This structure defines cause code as an indication whether an SMS error has occurred and
608 * if so, whether the condition is considered temporary or permanent
610 struct telephony_sms_Is637CauseCode {
611 unsigned char ReplySeqNumber; /* Reply sequence number */
612 enum telephony_sms_Is637ErrorClass ErrClass; /* Error report class */
613 unsigned char Cause; /* Error cause identifier */
617 * This structure defines the parameters of address and its type
619 struct telephony_sms_Is637Address {
620 enum telephony_sms_Is637DigitMode Digit; /* Digit mode indicator (0x00:4bit_dtmf, 0x01:8bit_code) */
621 enum telephony_sms_Is637NumberMode NumberMode; /* Number mode indicator (0x00:ANSI TI607, 0x01:Data network) */
622 enum telephony_sms_Is637NumberType NumberType; /* Type of number */
623 enum telephony_sms_Is637NumberPlan NumberPlan; /* Numbering plan */
624 unsigned char szAddrLength; /* The number of CHARi */
625 unsigned char szAddress[SMS_MAXLENGTH_SMS_ADDRESS]; /* The address digit or character */
629 * This structure defines the parameters of subaddress of originator and destination
631 struct telephony_sms_Is637SubAddress {
632 enum telephony_sms_Is637SubAddressType SubType; /* Subaddress type */
633 unsigned char Odd; /* Odd/even indicator */
634 unsigned char szAddrLength; /* The number of CHARi */
635 unsigned char szAddress[SMS_MAXLENGTH_SMS_ADDRESS]; /* A subaddress octet */
639 * This structure defines the message center time stamp may be include
640 * with SMS message sent from a message center
642 struct telephony_sms_TimeStamp {
643 unsigned int year; /* Year - if the year is 2002, the year field contains 0x02 */
644 unsigned int month; /* Month (1 ~ 12) */
645 unsigned int day; /* Day (1 ~ 31) */
646 unsigned int hours; /* Hours (0 ~ 23) */
647 unsigned int minutes; /* Minute (0 ~ 59) */
648 unsigned int seconds; /* Seconds (0 ~ 59) */
652 * The structure defines the parameter of SMS submit message
654 struct telephony_sms_Is637OutSubmit {
655 struct telephony_sms_Is637Address DstAddr; /* Destination address */
656 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
657 unsigned short TeleService; /* Teleservice Identifier */
658 int bBearerReplySeqRequest; /* Bearer reply sequence request */
659 unsigned char ReplySeqNumber; /* Reply sequence number */
660 unsigned short MsgId; /* Message identifier */
661 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
662 unsigned short MsgLength; /* Message length */
663 unsigned char szData[SMS_MAXLENGTH_SMS_MO_USER_DATA]; /* SMS user data */
664 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute (not supported) */
665 unsigned char ValidityPeriodRel; /* Validity period - Relative (not supported) */
666 struct telephony_sms_TimeStamp DeferredDelTimeAbs; /* Deferred delivery time - Absolute */
667 unsigned char DeferredDelTimeRel; /* Deferred delivery time - Relative */
668 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
669 enum telephony_sms_Is637Privacy Privacy; /* Privacy indicator */
670 int bUserAckRequest; /* User acknowledge request */
671 int bDeliveryAckRequest; /* Delivery acknowledge request */
672 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
673 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
674 struct telephony_sms_Is637Address CallBackNumber; /* Callback number address */
678 * The structure defines the parameter of SMS acknowledgement message for submit
680 struct telephony_sms_Is637OutAck {
681 struct telephony_sms_Is637Address DstAddr; /* Destination address */
682 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
683 unsigned short TeleService; /* Teleservice Identifier */
684 int bBearerReplySeqRequest; /* Bearer reply sequence request */
685 unsigned char ReplySeqNumber; /* Reply sequence number */
686 unsigned short MsgId; /* Message identifier */
687 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
688 unsigned short MsgLength; /* Message length */
689 unsigned char szData[SMS_MAXLENGTH_SMS_MO_USER_DATA]; /* SMS user data */
690 unsigned char UserResponseCode; /* User response code */
694 * The structure defines the parameter of SMS cancellation message
696 struct telephony_sms_Is637OutCancel {
697 struct telephony_sms_Is637Address DstAddr; /* Destination address */
698 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
699 unsigned short TeleService; /* Teleservice Identifier */
700 int bBearerReplySeqRequest; /* Bearer reply sequence request */
701 unsigned char ReplySeqNumber; /* Reply sequence number */
702 unsigned short MsgId; /* Message identifier */
706 * The structure defines the parameter of SMS devivery message
708 struct telephony_sms_Is637InDeliver {
709 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
710 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
711 unsigned short TeleService; /* Teleservice Identifier */
712 int bBearerReplySeqRequest; /* Bearer reply sequence request */
713 unsigned char ReplySeqNumber; /* Reply sequence number */
714 unsigned short MsgId; /* Message identifier */
715 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
716 unsigned short MsgLength; /* Message length */
717 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
718 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
719 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute */
720 unsigned char ValidityPeriodRel; /* Validity period - Relative */
721 struct telephony_sms_TimeStamp DeferredDelTimeAbs; /* Deferred delivery time - Absolute (not supported) */
722 unsigned char DeferredDelTimeRel; /* Deferred delivery time - Relative (not supported) */
723 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
724 enum telephony_sms_Is637Privacy Privacy; /* Privacy indicator */
725 unsigned char NumMsg; /* Number of voice mail (0-99) */
726 int bUserAckRequest; /* User acknowledge request */
727 int bDeliveryAckRequest; /* Delivery acknowledge request */
728 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
729 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
730 struct telephony_sms_Is637Address CallBackNumer; /* Callback number address */
731 enum telephony_sms_Is637MsgDisplayMode Display; /* Message display mode */
735 * The structure defines the parameter of SMS acknowledge message for deliver
737 struct telephony_sms_Is637InAck {
738 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
739 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
740 unsigned short TeleService; /* Teleservice Identifier */
741 int bBearerReplySeqRequest; /* Bearer reply sequence request */
742 unsigned char ReplySeqNumber; /* Reply sequence number */
743 unsigned short MsgId; /* Message identifier */
744 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
745 unsigned short MsgLength; /* Message length */
746 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
747 unsigned char UserResponseCode; /* User response code */
748 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
752 * The structure defines the parameter of SMS acknowledge message from message center
754 struct telephony_sms_Is637InDeliverAck {
755 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
756 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
757 unsigned short TeleService; /* Teleservice Identifier */
758 int bBearerReplySeqRequest; /* Bearer reply sequence request */
759 unsigned char ReplySeqNumber; /* Reply sequence number */
760 unsigned short MsgId; /* Message identifier */
761 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
762 unsigned short MsgLength; /* Message length */
763 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
764 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
768 * The structure defines the parameter of SMS broadcast message
770 struct telephony_sms_Is637InBroadCast {
771 enum telephony_sms_BroadCastCategory ServiceCategory; /* Broadcast service category */
772 unsigned short MsgId; /* Message identifier */
773 int bBearerReplySeqRequest; /* Bearer reply sequence request */
774 unsigned char ReplySeqNumber; /* Reply sequence number */
775 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
776 unsigned short MsgLength; /* Message length */
777 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
778 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
779 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute */
780 unsigned char ValidityPeriodRel; /* Validity period - Relative */
781 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
782 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
783 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
784 enum telephony_sms_Is637MsgDisplayMode Display; /* Message display mode */
785 } telephony_sms_Is637InBroadCast_t;
789 * The structure defines the type of SMS message as union
791 union telephony_sms_CdmaMessage_u {
792 struct telephony_sms_Is637OutSubmit outSubmit; /* Outgoing Submit message */
793 struct telephony_sms_Is637OutAck outAck; /* Outgoing Acknowledge message */
794 struct telephony_sms_Is637OutCancel outCancel; /* Outgoing Cancel message */
795 struct telephony_sms_Is637InDeliver inDeliver; /* Incoming Delivery message */
796 struct telephony_sms_Is637InAck inAck; /* Incoming Acknowledge message */
797 struct telephony_sms_Is637InDeliverAck inDeliverAck; /* Incoming Delivery Acknowledge message */
798 struct telephony_sms_Is637InBroadCast inBc; /* Incoming Broadcast message */
802 * The structure defines the parameter of entire SMS message of each type
804 struct telephony_sms_CdmaMsgInfo {
805 int ParamMask; /**< Parameter ID mask */
806 enum telephony_sms_CdmaMsgType MsgType; /**< Message type */
807 union telephony_sms_CdmaMessage_u MsgData; /**< Message data */
810 /*-----------------------------------------------------------------------------------------------------------------*/
811 /*-----------------------------------------------------------------------------------------------------------------*/
812 /*-----------------------------------------------------------------------------------------------------------------*/
813 /*-----------------------------------------------------------------------------------------------------------------*/
814 /*-----------------------------------------------------------------------------------------------------------------*/
817 /*---------------------------------*/
818 /* Structs of Requests */
819 /*---------------------------------*/
820 struct treq_sms_send_umts_msg {
821 struct telephony_sms_DataPackageInfo msgDataPackage;
825 struct treq_sms_send_cdma_msg {
826 struct telephony_sms_CdmaMsgInfo cdmaMsgInfo;
830 struct treq_sms_read_msg {
834 struct treq_sms_save_msg {
835 int simIndex; /* Index where SMS is stored. */
836 enum telephony_sms_MsgStatus msgStatus;
837 struct telephony_sms_DataPackageInfo msgDataPackage;
840 struct treq_sms_delete_msg {
844 struct treq_sms_get_msg_count {
847 struct treq_sms_get_sca {
851 struct treq_sms_set_sca {
852 struct telephony_sms_AddressInfo scaInfo;
856 struct treq_sms_get_cb_config {
859 struct treq_sms_set_cb_config {
860 int net3gppType; /**< Type of 3gpp, 0x01 . 3gpp. 0x02 . 3gpp2(CDMA) */
861 int cbEnabled; /**< CB service state. If cb_enabled is true then cell broadcast service will be enabled and underlying modem will enable CB Channel to receiving CB messages. Otherwise CB service will be disabled, underlying modem will deactivate the CB channel. (enabled/disabled) */
862 unsigned char msgIdMaxCount; /**< CB Channel List Max Count For Response */
863 int msgIdRangeCount; /**< Range of CB message ID count */
864 union telephony_sms_cb_msg_info_u msgIDs[SMS_GSM_SMS_CBMI_LIST_SIZE_MAX]; /**< Range of CB message ID information */
867 struct treq_sms_set_mem_status {
871 struct treq_sms_get_pref_bearer {
874 struct treq_sms_set_pref_bearer {
878 struct treq_sms_set_delivery_report {
879 struct telephony_sms_DataPackageInfo dataInfo;
883 struct treq_sms_set_msg_status {
885 enum telephony_sms_MsgStatus msgStatus;
888 struct treq_sms_get_params {
892 struct treq_sms_set_params {
893 struct telephony_sms_Params params;
896 struct treq_sms_get_paramcnt {
900 /* Structs of Responses */
901 struct tresp_sms_send_umts_msg {
905 struct tresp_sms_read_msg {
906 struct telephony_sms_Data dataInfo;
910 struct tresp_sms_save_msg {
915 struct tresp_sms_delete_msg {
920 struct tresp_sms_get_storedMsgCnt {
921 struct telephony_sms_StoredMsgCountInfo storedMsgCnt;
925 struct tresp_sms_get_sca {
926 struct telephony_sms_AddressInfo scaAddress;
930 struct tresp_sms_set_sca {
934 struct tresp_sms_get_cb_config {
935 struct telephony_sms_CbConfig cbConfig;
939 struct tresp_sms_set_cb_config {
943 struct tresp_sms_set_mem_status {
947 struct tresp_sms_get_pref_bearer {
951 struct tresp_sms_set_pref_bearer {
955 struct tresp_sms_set_delivery_report {
959 struct tresp_sms_set_msg_status {
963 struct tresp_sms_get_params {
964 struct telephony_sms_Params paramsInfo;
968 struct tresp_sms_set_params {
972 struct tresp_sms_get_paramcnt {
977 struct tresp_sms_send_cdma_msg {
978 struct telephony_sms_Is637CauseCode causeCode;
982 /*-----------------------------------*/
983 /* Structs of Notifications */
984 /*-----------------------------------*/
985 struct tnoti_sms_umts_msg {
986 struct telephony_sms_DataPackageInfo msgInfo;
989 struct tnoti_sms_cdma_msg {
990 struct telephony_sms_CdmaMsgInfo cdmaMsg;
993 struct tnoti_sms_cellBroadcast_msg {
994 struct telephony_sms_CbMsg cbMsg;
997 struct tnoti_sms_etws_msg {
998 struct telephony_sms_etws_msg etwsMsg;
1001 struct tnoti_sms_memory_status {
1005 struct tnoti_sms_ready_status {