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 1252 /** Maximum CB Message Size */
67 #define SMS_ETWS_SIZE_MAX 1252 /** Maximum ETWS Message Size */
69 #define SMS_ADDRESS_LEN_MAX 20 /* Nettext Address Length */
70 #define SMS_SCADDRESS_LEN_MAX 18 /* SC Address Length */
72 #define SMS_CB_PAGE_SIZE_MAX 9 /**< CB maximum page size*/
73 #define SMS_GSM_SMS_MSG_NUM_MAX 255 /**< Maximum GSM SMS message number*/
74 #define SMS_GSM_SMS_CBMI_LIST_SIZE_MAX 50 /**< Maximum GSM SMS CBMI list size*/
75 #define SMS_SMDATA_SIZE_MAX 255 /**< Maximum SMS data size that can be stored*/
76 #define SMS_MAX_SMS_SERVICE_CENTER_ADDR 12 /**<Maximum SMS service center address*/
77 #define SMS_MAX_INDEX 255 /**< Maximum index value for SMS */
79 #define SMS_SMSP_PARAMS_MAX_LEN 28
81 // ************************ CDMA Features **************************//
82 #define SMS_PARAM_TELESERVICE_MASK 1 << 0 /**< Teleservice parameter bit position */
83 #define SMS_PARAM_SERVICE_CATEGORY_MASK 1 << 1 /**< Service Category parameter bit position */
84 #define SMS_PARAM_ADDRESS_MASK 1 << 2 /**< Address parameter bit position */
85 #define SMS_PARAM_SUBADDRESS_MASK 1 << 3 /**< Subaddress parameter bit position */
86 #define SMS_PARAM_BEARER_REPLY_MASK 1 << 4 /**< Bearer reply parameter bit position */
87 #define SMS_PARAM_CAUSE_CODES_MASK 1 << 5 /**< Cause Code parameter bit position */
88 #define SMS_PARAM_MESSAGE_ID_MASK 1 << 6 /**< Message ID parameter bit position */
89 #define SMS_PARAM_USER_DATA_MASK 1 << 7 /**< User Data parameter bit position */
90 #define SMS_PARAM_USER_RESPONSE_CODE_MASK 1 << 8 /**< User Response Code parameter bit position */
91 #define SMS_PARAM_MC_TIME_STAMP_MASK 1 << 9 /**< Message Center Timestamp parameter bit position */
92 #define SMS_PARAM_VALIDITY_PERIOD_ABS_MASK 1 << 10 /**< Valid period Absolute parameter bit position */
93 #define SMS_PARAM_VALIDITY_PERIOD_REL_MASK 1 << 11 /**< Valid period Relative parameter bit position */
94 #define SMS_PARAM_DEFERRED_DELIVERY_ABS_MASK 1 << 12 /**< Deferred delivery absolute parameter bit position */
95 #define SMS_PARAM_DEFERRED_DELIVERY_REL_MASK 1 << 13 /**< Deferred delivery relative parameter bit position */
96 #define SMS_PARAM_PRIORITY_MASK 1 << 14 /**< Priority parameter bit position */
97 #define SMS_PARAM_PRIVACY_MASK 1 << 15 /**< Privacy parameter bit position */
98 #define SMS_PARAM_REPLY_OPTION_MASK 1 << 16 /**< Reply Option parameter bit position */
99 #define SMS_PARAM_NUMBER_OF_MESSAGE_MASK 1 << 17 /**< Number of message parameter bit position */
100 #define SMS_PARAM_ALERT_ON_DELIVERY_MASK 1 << 18 /**< Alert on delivery parameter bit position */
101 #define SMS_PARAM_LANGUAGE_MASK 1 << 19 /**< Language parameter bit position */
102 #define SMS_PARAM_CALLBACK_MASK 1 << 20 /**< Callback Number parameter bit position */
103 #define SMS_PARAM_DISPLAY_MODE_MASK 1 << 21 /**< Display mode parameter bit position */
104 #define SMS_PARAM_MULTI_ENCODING_USER_DATA_MASK 1 << 22 /**< Multi Encoding user data parameter bit position */
106 #define SMS_MAXLENGTH_SMS_MT_USER_DATA 160 /**< Maximum MT user data size*/
107 #define SMS_MAXLENGTH_SMS_MO_USER_DATA 160 /**< Maximum MO user data size*/
109 #define SMS_MAXLENGTH_SMS_ADDRESS 32 /**< MAX sms destination(or origination ) address /call back number */
111 #define SMS_ERR_CLASS0_STATUS_SEND_OK 0 /**< send success */
112 #define SMS_ERR_CLASS23_ADDRESS_VACANT 0 /**< address vacant */
113 #define SMS_ERR_CLASS23_ADDRESS_TRANSLATION_FAILURE 1 /**< address translation failure */
114 #define SMS_ERR_CLASS23_NETWORK_RESOURCE_SHORTAGE 2 /**< network resource shortage */
115 #define SMS_ERR_CLASS23_NETWORK_FAILURE 3 /**< network failure */
116 #define SMS_ERR_CLASS23_INVALID_TELESERVICE_ID 4 /**< invalid teleservice id */
117 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM 5 /**< other network problem */
118 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM_MORE_FIRST 6 /**< other network problem more first */
119 #define SMS_ERR_CLASS23_OTHER_NETWORK_PROBLEM_MORE_LAST 31 /**< other network problem more last */
120 #define SMS_ERR_CLASS23_NO_PAGE_RESPONSE 32 /**< no page response */
121 #define SMS_ERR_CLASS23_DESTINATION_BUSY 33 /**< destination busy */
122 #define SMS_ERR_CLASS23_NO_ACK 34 /**< no ack */
123 #define SMS_ERR_CLASS23_DESTINATION_RESOURCE_SHORTAGE 35 /**< destination resource shortage */
124 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED 36 /**< sms delivery postponed */
125 #define SMS_ERR_CLASS23_DESTINATION_OUT_OF_SERVICE 37 /**< destination out of service */
126 #define SMS_ERR_CLASS23_DESTINATION_NO_LONGER_AT_THIS_ADDRESS 38 /**< destination no longer at this address */
127 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM 39 /**< other terminal problem */
128 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM_MORE_FIRST 40 /**< other terminal problem more first */
129 #define SMS_ERR_CLASS23_OTHER_TERMINAL_PROBLEM_MORE_LAST 47 /**< other terminal problem more last */
130 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED_MORE_FIRST 48 /**< sms delivery postpone more first */
131 #define SMS_ERR_CLASS23_SMS_DELIVERY_POSTPONED_MORE_LAST 63 /**< sms delivery postpone more last */
132 #define SMS_ERR_CLASS23_RADIO_IF_RESOURCE_SHORTAGE 64 /**< radio interface resource shortage */
133 #define SMS_ERR_CLASS23_RADIO_IF_INCOMPATIBLE 65 /**< radio interface incompatible */
134 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM 66 /**< other radio interface problem */
135 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM_MORE_FIRST 67 /**< other radio interface problem more first */
136 #define SMS_ERR_CLASS23_OTHER_RADIO_IF_PROBLEM_MORE_LAST 95 /**< other radio interface problem more last */
137 #define SMS_ERR_CLASS23_UNEXPECTED_PARM_SIZE 96 /**< unexpected parameter size */
138 #define SMS_ERR_CLASS23_SMS_ORIGINATION_DENIED 97 /**< sms origination denied */
139 #define SMS_ERR_CLASS23_SMS_TERMINATION_DENIED 98 /**< sms termination denied */
140 #define SMS_ERR_CLASS23_SUPPL_SERVICE_NOT_SUPPORTED 99 /**< supplementary service not supported */
141 #define SMS_ERR_CLASS23_SMS_NOT_SUPPORTED 100 /**< sms not supported */
142 #define SMS_ERR_CLASS23_RESERVED_101 101 /**< reserved 101 */
143 #define SMS_ERR_CLASS23_MISSING_EXPECTED_PARM 102 /**< missing expected parameter */
144 #define SMS_ERR_CLASS23_MISSING_MANDATORY_PARM 103 /**< missing mandatory parameter value */
145 #define SMS_ERR_CLASS23_UNRECOGNIZED_PARM_VALUE 104 /**< unrecognized parameter value */
146 #define SMS_ERR_CLASS23_UNEXPECTED_PARM_VALUE 105 /**< unexpected parameter value */
147 #define SMS_ERR_CLASS23_USER_DATA_SIZE_ERROR 106 /**< user data size error */
148 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS 107 /**< other general problem */
149 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS_MORE_FIRST 108 /**< other general problem first */
150 #define SMS_ERR_CLASS23_OTHER_GENERAL_PROBLEMS_MORE_LAST 255 /**< other general problem last */
152 #define SMS_ERR_CLASS4_WAITING_FOR_TL_ACK 1 /**< waiting for transport ack */
153 #define SMS_ERR_CLASS4_OUT_OF_RESOURCES 2 /**< out of resource */
154 #define SMS_ERR_CLASS4_ACCESS_TOO_LARGE 3 /**< access to large */
155 #define SMS_ERR_CLASS4_DTC_TOO_LARGE 4 /**< DTC too large */
156 #define SMS_ERR_CLASS4_DTC_CONNECTED 5 /**< DTC connected */
157 #define SMS_ERR_CLASS4_NETWORK_NOT_READY 6 /**< network not ready */
158 #define SMS_ERR_CLASS4_NO_SVC 7 /**< no service */
159 #define SMS_ERR_CLASS4_PHONE_NOT_READY 8 /**< phone not ready */
160 #define SMS_ERR_CLASS4_NOT_ALLOWED_IN_AMPS 9 /**< fail to allowed in amps */
161 #define SMS_ERR_CLASS4_CANNOT_SEND_BROADCAST 10 /**< fail to send broadcast */
162 #define SMS_ERR_CLASS4_INVALID_TRANSACTION_ID
163 // ********************************************************************//
165 /*==================================================================================================
167 ==================================================================================================*/
169 * @enum telephony_sms_MsgStatus_t
170 * This enumeration defines the network text status type.
172 enum telephony_sms_MsgStatus {
173 SMS_STATUS_READ, /**< MT message, stored and read */
174 SMS_STATUS_UNREAD, /**< MT message, stored and unread */
175 SMS_STATUS_SENT, /**< MO message, stored and sent */
176 SMS_STATUS_UNSENT, /**< MO message, stored but not sent */
177 SMS_STATUS_DELIVERED, /**< delivered destination */
178 SMS_STATUS_DELIVERY_UNCONFIRMED, /**< Service centre forwarded message but is unable to confirm delivery*/
179 SMS_STATUS_MESSAGE_REPLACED, /**< Message has been replaced*/
180 SMS_STATUS_RESERVED /**< Reserved for future use*/
184 * @enum telephony_sms_MemStatusType
185 * This enumeration defines the memory status type.
187 enum telephony_sms_MemStatusType {
188 SMS_PDA_MEMORY_STATUS_AVAILABLE = 0x01, /**< PDA Memory Available */
189 SMS_PDA_MEMORY_STATUS_FULL = 0x02, /**< PDAMemory is Full */
190 SMS_PHONE_MEMORY_STATUS_AVAILABLE = 0x03, /**< Phone memory Available */
191 SMS_PHONE_MEMORY_STATUS_FULL = 0x04, /**< phone memory is full */
195 * @enum telephony_sms_BearerType_t
196 * This enum defines the different bearer types
198 enum telephony_sms_BearerType {
199 SMS_BEARER_PS_ONLY = 0x01, /**< Send SMS only on PS Bearer */
200 SMS_BEARER_CS_ONLY, /**< Send SMS only on CS Bearer */
201 SMS_BEARER_PS_PREFERRED, /**<Send SMS preferably on PS Bearer*/
202 SMS_BEARER_CS_PREFERRED , /**<Send SMS preferably on CS Bearer*/
203 SMS_NO_PREFERRED_BEARER /**<SMS is sent based on default preferred bearer set at OEM based on vendor/operator preference*/
208 * @enum telephony_sms_CbMsgType_t
209 * This enumeration defines the different CB message types.
211 enum telephony_sms_CbMsgType {
212 SMS_CB_MSG_GSM = 1, /**< GSM Cell broadcast message */
213 SMS_CB_MSG_UMTS /**< UMTS Cell broadcast message */
217 * @enum telephony_sms_etws_type
218 * This enumeration defines the different ETWS message types.
220 enum telephony_sms_etws_type {
221 SMS_ETWS_MSG_PRIMARY = 0, /**< PRIMARY ETWS Message */
222 SMS_ETWS_MSG_SECONDARY_GSM, /**< SECONDARY GSM ETWS Message */
223 SMS_ETWS_MSG_SECONDARY_UMTS /**< SECONDARY UMTS ETWS Message */
227 * @enum telephony_sms_Response_t
228 * This enum defines the different response types that come in the
229 * sent status acknowledgement/notification after sending a message to the network
231 enum telephony_sms_Response {
232 SMS_SENDSMS_SUCCESS = 0x00, /**<Message send success*/
233 SMS_ROUTING_NOT_AVAILABLE, /**< Message routing not available*/
234 SMS_INVALID_PARAMETER, /**< Invalid parameter present in TPDU*/
235 SMS_DEVICE_FAILURE, /**< Device failure*/
236 SMS_SERVICE_RESERVED, /**< Reserved Service*/
237 SMS_INVALID_LOCATION, /**< Invalid location*/
238 SMS_NO_SIM, /**< No SIM error*/
239 SMS_SIM_NOT_READY, /**< SIM not ready error*/
240 SMS_NO_NETWORK_RESP, /**< No response from network*/
241 SMS_DEST_ADDRESS_FDN_RESTRICTED, /**< Destination address restricted*/
242 SMS_SCADDRESS_FDN_RESTRICTED, /**< Service center address restricted*/
243 SMS_RESEND_ALREADY_DONE, /**< Resend a operation already done*/
244 SMS_SCADDRESS_NOT_AVAILABLE, /**< SCA address not available*/
245 SMS_UNASSIGNED_NUMBER = 0x8001, /**< Unassigned number*/
246 SMS_OPERATOR_DETERMINED_BARRING = 0x8008, /**< Operator determined barring*/
247 SMS_CALL_BARRED = 0x800A, /**< Call barred*/
248 SMS_MESSAGE_TRANSFER_REJECTED = 0x8015, /**< Message transfer rejected*/
249 SMS_MEMORY_CAPACITY_EXCEEDED = 0x8016, /**< Memory capacity exceeded/memory full*/
250 SMS_DESTINAITION_OUTOFSERVICE = 0x801B, /**< Destination number/address out of service*/
251 SMS_UNSPECIFIED_SUBSCRIBER = 0x801C, /**< Unspecified subscriber*/
252 SMS_FACILITY_REJECTED = 0x801D, /**< Facility rejected*/
253 SMS_UNKNOWN_SUBSCRIBER = 0x801E, /**< Unknown subscriber*/
254 SMS_NETWORK_OUTOFORDER = 0x8026, /**< Network out of order*/
255 SMS_TEMPORARY_FAILURE = 0x8029, /**< Temporary failure*/
256 SMS_CONGESTION = 0x802A, /**< Congestion happened*/
257 SMS_RESOURCES_UNAVAILABLE = 0x802F, /**< Resource unavailable*/
258 SMS_FACILITY_NOT_SUBSCRIBED = 0x8032, /**< Facility not subscribed by the user*/
259 SMS_FACILITY_NOT_IMPLEMENTED = 0x8045, /**< Facility not implemented*/
260 SMS_INVALID_REF_VALUE = 0x8051, /**< Invalid reference value*/
261 SMS_INVALID_MSG = 0x805F, /**< Invalid message*/
262 SMS_INVALID_MANDATORY_INFO = 0x8060, /**< Invalid Mandatory information*/
263 SMS_MESSAGE_TYPE_NOT_IMPLEMENTED = 0x8061, /**< Message type not implemented*/
264 SMS_MESSAGE_NOT_COMPAT_PROTOCOL = 0x8062, /**< Message not compact protocol*/
265 SMS_IE_NOT_IMPLEMENTED = 0x8063, /**< Information element not implemented*/
266 SMS_PROTOCOL_ERROR = 0x806F, /**< Protocol error*/
267 SMS_INTERWORKING = 0x807F, /**< Networking error*/
268 SMS_ME_FULL = 0x8080, /**< SMS ME FULL */
269 SMS_SIM_FULL = 0x8081, /**< SMS SIM FULL */
270 SMS_TIMEOUT /**< Timeout error */
273 /** @enum telephony_sms_Cause_t
274 * This enum defines the different cause types that come in the
275 * sent status acknowledgement/notification after sending a message to the network
278 enum telephony_sms_Cause {
280 SMS_SUCCESS, /**< SMS Operation successful*/
281 SMS_INVALID_PARAMETER_FORMAT, /**< Invalid format for some parameters passed in Data package information(TPDU)*/
282 SMS_PHONE_FAILURE, /**<SMS operation failed due to Modem failure*/
283 SMS_SIM_BUSY, /**< SMS SIM operation cannot be performed as SIM is busy with some other operation*/
284 SMS_SIM_FAILURE, /**< SMS SIM operation cannot be performed due to SIM failure */
285 SMS_UNKNOWN, /**< unknown error*/
286 SMS_MEMORY_FAILURE, /**< Error while accessing memory or allocation of memory for SMS operation.*/
287 SMS_OPERATION_NOT_SUPPORTED /**< operation not allowed/supported*/
291 * @enum telephony_sms_SetResponse
292 * This defines the response values
294 enum telephony_sms_SetResponse {
295 SMS_CBSETCONFIG_RSP, /**< cellbroadcast config response */
296 SMS_SETPREFERREDBEARER_RSP, /**< set preferred bearer response */
297 SMS_SETPARAMETERS_RSP, /**< set parameter response */
298 SMS_SETMEMORYSTATUS_RSP, /**< set memory status response*/
299 SMS_SETMESSAGESTATUS_RSP, /**< set message status response*/
300 SMS_SETDEVICESTATUS_RSP, /**< set device status response*/
301 SMS_SETSCADDR_RSP, /**< set SCA address response */
302 SMS_SET_RSP_MAX /**< maximum limit*/
306 * @enum telephony_sms_3gpp_type
307 * This defines the type of 3gpp
309 enum telephony_sms_3gpp_type {
310 SMS_NETTYPE_3GPP = 0x01, /**< 3gpp type */
311 SMS_NETTYPE_3GPP2, /**< 3gpp2 type (CDMA) */
316 * This structure defines the fields related to an Sms like SIM index, TPDU and length
318 struct telephony_sms_DataPackageInfo {
319 unsigned char sca[SMS_SMSP_ADDRESS_LEN]; /* Service Centre address - an optional parameter. If this parameter is not present, then this field will be Null.If present, the valid service centre address information is filled as per 3GPP TS23.040 9.1.2.5 Address fields */
320 int msgLength; /* Size of array szData (which is actual TPDU message) */
321 unsigned char tpduData[SMS_SMDATA_SIZE_MAX + 1]; /* SMS TPDU message */
325 *This structure defines the data Related to SimIndex,MessageStatus and SMS Data Stored.
327 struct telephony_sms_Data {
328 int simIndex; /**< Index where SMS is stored. */
329 enum telephony_sms_MsgStatus msgStatus; /**< Message status.*/
330 struct telephony_sms_DataPackageInfo smsData; /**<SMS message */
333 struct telephony_sms_AddressInfo {
334 unsigned int dialNumLen; /* length of address. If Service center address is not set, then this will be zero */
335 int typeOfNum; /* Type of number*/
336 int numPlanId; /* Numbering plan identification*/
337 unsigned char diallingNum[SMS_SMSP_ADDRESS_LEN + 1]; /* destination address. If Address not set, then set to 0xFF */
341 * This structure defines different fields involved in setting the parameters of
342 * a particular sms in EFsmsp.
344 struct telephony_sms_Params {
346 unsigned char recordIndex; /**< Index*/
347 unsigned char recordLen; /**< SMS Parameter Record length*/
348 unsigned long alphaIdLen; /**< Alpha id length */
349 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
350 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 */
351 struct telephony_sms_AddressInfo tpDestAddr; /**< TP-destination address (TP-DA) */
352 struct telephony_sms_AddressInfo tpSvcCntrAddr; /**< TP-service center address */
353 unsigned short tpProtocolId; /**< TP-protocol Id */
354 unsigned short tpDataCodingScheme; /**< TP-data coding scheme */
355 unsigned short tpValidityPeriod; /**< TP-validity period */
359 * This structure defines the different parameters that are related to the message count
360 *in a particular memory(Phone/SIM)
362 struct telephony_sms_StoredMsgCountInfo {
363 unsigned int totalCount; /**< Total count of messages stored in SIM*/
364 int usedCount; /**< Stored message count in SIM in SIM*/
365 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).*/
369 * This structure defines a cell broadcast message.
371 struct telephony_sms_CbMsg {
373 enum telephony_sms_CbMsgType cbMsgType; /**< Cell Broadcast message type */
374 unsigned short length; /**<Size of array szMsgData (which is actual TPDU message) */
375 char msgData[SMS_CB_SIZE_MAX + 1]; /**<Cell broadcast message data[Refer 3GPP TS 23.041 9.4.1]*/
378 struct telephony_sms_etws_msg {
380 enum telephony_sms_etws_type etwsMsgType; /**< ETWS message type */
381 unsigned short length; /**<Size of array msgData (which is actual TPDU message) */
382 char msgData[SMS_ETWS_SIZE_MAX + 1]; /**< ETWS message data[Refer 3GPP TS 23.041 9.4.1.3]*/
385 struct telephony_sms_cb_msg_info_3gpp {
386 unsigned short fromMsgId; /**< Starting point of the range of CBS message ID */
387 unsigned short toMsgId; /**< Ending point of the range of CBS message ID */
388 unsigned char selected; /**< 0x00 . Not selected. 0x01 . Selected */
391 struct telephony_sms_cb_msg_info_3gpp2 {
392 unsigned short cbCategory; /**< CB Service category */
393 unsigned short cbLanguage; /**< Language indicator value
394 . 0x00 . LANGUAGE_UNKNOWN .
395 Unknown or Unspecified
396 . 0x01 . LANGUAGE_ENGLISH . English
397 . 0x02 . LANGUAGE_FRENCH . French
398 . 0x03 . LANGUAGE_SPANISH . Spanish
399 . 0x04 . LANGUAGE_JAPANESE . Japanese
400 . 0x05 . LANGUAGE_KOREAN . Korean
401 . 0x06 . LANGUAGE_CHINESE . Chinese
402 . 0x07 . LANGUAGE_HEBREW . Hebrew*/
403 unsigned char selected; /**< 0x00 . Not selected. 0x01 . Selected */
406 union telephony_sms_cb_msg_info_u {
407 struct telephony_sms_cb_msg_info_3gpp net3gpp; /**< 3GPP Broadcast Configuration Information */
408 struct telephony_sms_cb_msg_info_3gpp2 net3gpp2; /**< 3GPP2 Broadcast Configuration Information, CDMA*/
411 struct telephony_sms_CbConfig {
412 int net3gppType; /**< Type of 3gpp, 0x01 . 3gpp. 0x02 . 3gpp2(CDMA) */
413 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) */
414 unsigned char msgIdMaxCount; /**< CB Channel List Max Count For Response */
415 int msgIdRangeCount; /**< Range of CB message ID count */
416 union telephony_sms_cb_msg_info_u msgIDs[SMS_GSM_SMS_CBMI_LIST_SIZE_MAX]; /**< Range of CB message ID information */
420 // ************************ CDMA Features **************************//
421 /** @enum telephony_sms_Is637AlertPriority_t
422 * This enum defines the type of alerts used to distinguish different priorities
425 enum telephony_sms_Is637AlertPriority {
426 SMS_ALERT_PRIORITY_DEFAULT = 0, /* Mobile default alert */
427 SMS_ALERT_PRIORITY_LOW, /* Low priority alert */
428 SMS_ALERT_PRIORITY_MEDIUM, /* Medium priority alert */
429 SMS_ALERT_PRIORITY_HIGH, /* High priority alert */
432 /** @enum telephony_sms_Is637Privacy_t
433 * This enum defines the desired privacy level of the message
435 enum telephony_sms_Is637Privacy {
436 SMS_PRIVACY_NOT_RESTRICTED = 0, /* Not restricted */
437 SMS_PRIVACY_RESTRICTED, /* Restricted */
438 SMS_PRIVACY_CONFIDENTIAL, /* Confidential */
439 SMS_PRIVACY_SECRET, /* Secret */
442 /** @enum telephony_sms_Is637Priority_t
443 * This enum defines the priority level of the message
445 enum telephony_sms_Is637Priority {
446 SMS_PRIORITY_NORMAL = 0, /* Normal */
447 SMS_PRIORITY_INTERACTIVE, /* Interactive */
448 SMS_PRIORITY_URGENT, /* Urgent */
449 SMS_PRIORITY_EMERGENCY, /* Emergency */
452 /** @enum telephony_sms_Is637LangIndicator_t
453 * This enum defines the language of the message so that the receiving mobile station can
454 * discard those messages that are not in the user's preferred language
456 enum telephony_sms_Is637LangIndicator {
457 SMS_LANG_UNKNOWN = 0x0, /* Unknown or unspecified */
458 SMS_LANG_ENGLISH, /* English */
459 SMS_LANG_FRENCH, /* French */
460 SMS_LANG_SPANISH, /* Spanish */
461 SMS_LANG_JAPANESE, /* Japanese */
462 SMS_LANG_KOREAN, /* Korean */
463 SMS_LANG_CHINESE, /* Chinese */
464 SMS_LANG_HEBREW, /* Hebrew */
467 /** @enum telephony_sms_Is637MsgDisplayMode_t
468 * This enum defines the display mode to the mobile station when to display the received message
470 enum telephony_sms_Is637MsgDisplayMode {
471 SMS_MSG_DISPLAY_IMMEDIATE = 0x0, /* The mobile station is to display the received message as soon as possible */
472 SMS_MSG_DISPLAY_DEFAULT, /* he mobile station is to display the received message based on a pre-defined mode in the mobile station. */
473 SMS_MSG_DISPLAY_USER_INVOKE = 0x3, /* The mobile station is to display the received message based on the mode selected by the user. */
474 SMS_MSG_DISPLAY_RESERVED, /* Reserved */
477 /** @enum telephony_sms_Is637ErrorClass_t
478 * This enum defines the error report class
480 enum telephony_sms_Is637ErrorClass {
481 SMS_MSG_ERROR_CLASS_NONE = 0x0, /* None error(for SMS ack) */
482 SMS_MSG_ERROR_CLASS_TEMPORARY_ERROR = 0x2, /* Temporary error(for SMS ack) */
483 SMS_MSG_ERROR_CLASS_PERMANENT_ERROR = 0x3, /* Permanent error(for SMS ack) */
484 SMS_MSG_ERROR_CLASS_PHONE_INTERNAL_ERROR = 0x4, /* Phone Internal Status (for Send status) */
487 /** @enum telephony_sms_BroadCastCategory_t
488 * This enum defines the Broadcast Service Category
490 enum telephony_sms_BroadCastCategory {
491 SMS_CATEGORY_UNKNOWN = 0x00, /* Unknown category */
492 SMS_CATEGORY_EMERGENCY = 0x01, /* Emergency category */
493 SMS_CATEGORY_ADMIN = 0x02, /* Admin category */
494 SMS_CATEGORY_MAINTENANCE = 0x03, /* Maintenance category */
495 SMS_CATEGORY_GEN_NEWS_LOC = 0x04, /* General News(Local) category */
496 SMS_CATEGORY_GEN_NEWS_REG = 0x05, /* General News(Regional) category */
497 SMS_CATEGORY_GEN_NEWS_NAT = 0x06, /* General News(National) category */
498 SMS_CATEGORY_GEN_NEWS_INT = 0x07, /* General News(International) category */
499 SMS_CATEGORY_FIN_NEWS_LOC = 0x08, /* Business/Financial News(Local) category */
500 SMS_CATEGORY_FIN_NEWS_REG = 0x09, /* Business/Financial News(Regional) category */
501 SMS_CATEGORY_FIN_NEWS_NAT = 0x0A, /* Business/Financial News(National) category */
502 SMS_CATEGORY_FIN_NEWS_INT = 0x0B, /* Business/Financial News(International) category */
503 SMS_CATEGORY_SPT_NEWS_LOC = 0x0C, /* Sports News(Local) category */
504 SMS_CATEGORY_SPT_NEWS_REG = 0x0D, /* Sports News(Regional) category */
505 SMS_CATEGORY_SPT_NEWS_NAT = 0x0E, /* Sports News(National) category */
506 SMS_CATEGORY_SPT_NEWS_INT = 0x0F, /* Sports News(International) category */
507 SMS_CATEGORY_ENT_NEWS_LOC = 0x10, /* Entertainment News(Local) category */
508 SMS_CATEGORY_ENT_NEWS_REG = 0x11, /* Entertainment News(Regional) category */
509 SMS_CATEGORY_ENT_NEWS_NAT = 0x12, /* Entertainment News(National) category */
510 SMS_CATEGORY_ENT_NEWS_INT = 0x13, /* Entertainment News(International) category */
511 SMS_CATEGORY_LOC_WEATHER = 0x14, /* Local Weather category */
512 SMS_CATEGORY_AREA_TRAFFIC = 0x15, /* Area Traffic Reports category */
513 SMS_CATEGORY_AIRPORT_SCHED = 0x16, /* Local Airport Flight Schedules category */
514 SMS_CATEGORY_RESTAURANTS = 0x17, /* Restaurants category */
515 SMS_CATEGORY_LODGINGS = 0x18, /* Lodgings category */
516 SMS_CATEGORY_RETAILS = 0x19, /* Retail Directory category */
517 SMS_CATEGORY_ADS = 0x1A, /* Advertisements category */
518 SMS_CATEGORY_STOCK_QUOTES = 0x1B, /* Stock Quotes category */
519 SMS_CATEGORY_JOBS = 0x1C, /* Employment Opportunities category */
520 SMS_CATEGORY_MEDICAL = 0x1D, /* Medical/Health/Hospitals category */
521 SMS_CATEGORY_TECH_NEWS = 0x1E, /* Technology News category */
522 SMS_CATEGORY_MULTI = 0x1F, /* Multi-category */
525 /** @enum telephony_sms_MsgType_t
526 * This enum defines the type of IS637 message
528 enum telephony_sms_CdmaMsgType {
529 SMS_MESSAGETYPE_DELIVER = 0x01, /* sms deliver message */
530 SMS_MESSAGETYPE_SUBMIT = 0x02, /* sms submit message */
531 SMS_MESSAGETYPE_CANCEL = 0x03, /* sms cancellation message */
532 SMS_MESSAGETYPE_DELIVERY_ACK = 0x04, /* sms delivery acknowledgment message */
533 SMS_MESSAGETYPE_USER_ACK = 0x05, /* sms user acknowledgment message */
534 } telephony_sms_CdmaMsgType_e;
536 /** @enum telephony_sms_Is637DigitMode_t
537 * This enum defines the type of address whether it is 4-bit mode or 8-bit mode
539 enum telephony_sms_Is637DigitMode {
540 SMS_DIGITMODE_4BITDTMF = 0x00, /* 4-bit mode */
541 SMS_DIGITMODE_8BITCODE = 0x01, /* 8-bit mode */
544 /** @enum telephony_sms_Is637NumberMode_t
545 * 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
547 enum telephony_sms_Is637NumberMode {
548 SMS_NUMMODE_NONE_DATANETWORK = 0x00, /* in ANSI TI.607 */
549 SMS_NUMMODE_DATANETWORK = 0x01, /* in Data Network */
552 /** @enum telephony_sms_Is637NumberType_t
553 * This enum defines the type of address
555 enum telephony_sms_Is637NumberType {
556 SMS_NUMBER_TYPE_UNKNOWN = 0x00, /* Unknown */
557 SMS_NUMBER_TYPE_INTERNATIONAL = 0x01, /* International number*/
558 SMS_NUMBER_TYPE_NATIONAL = 0x02, /* National number */
559 SMS_NUMBER_TYPE_NETWORK = 0x03, /* Abbreviated number */
560 SMS_NUMBER_TYPE_SUBSCRIBER = 0x04, /* Abbreviated number */
561 SMS_NUMBER_TYPE_RESERVED_5 = 0x05, /* Reserved */
562 SMS_NUMBER_TYPE_ABBREVIATED = 0x06, /* Abbreviated number */
563 SMS_NUMBER_TYPE_RESERVED_7 = 0x07, /* Reserved */
564 SMS_NUMBER_TYPE_IP = 0x11, /* Internet Protocol(RFC 791) */
565 SMS_NUMBER_TYPE_EMAILADDR = 0x12, /* Internet Email Address(RFC 822) */
566 } telephony_sms_Is637NumberType_e;
568 /** @enum telephony_sms_Is637NumberPlan_t
569 * This enum defines the plan of address
571 enum telephony_sms_Is637NumberPlan {
572 SMS_NUMBER_PLAN_UNKNOWN = 0x00, /* Unknown */
573 SMS_NUMBER_PLAN_TELEPHONY = 0x01, /* ISDN/Telephony numbering plan */
574 SMS_NUMBER_PLAN_RESERVED_2 = 0x02, /* Reserved */
575 SMS_NUMBER_PLAN_DATA = 0x03, /* Data numbering plan */
576 SMS_NUMBER_PLAN_TELEX = 0x04, /* CTelex numbering plan */
577 SMS_NUMBER_PLAN_RESERVED_5 = 0x05, /* Reserved */
578 SMS_NUMBER_PLAN_RESERVED_6 = 0x06, /* Reserved */
579 SMS_NUMBER_PLAN_RESERVED_7 = 0x07, /* Reserved */
580 SMS_NUMBER_PLAN_RESERVED_8 = 0x08, /* Reserved */
581 SMS_NUMBER_PLAN_PRIVATE = 0x09, /* Private numbering plan */
582 SMS_NUMBER_PLAN_RESERVED_10 = 0x0A, /* Reserved */
583 SMS_NUMBER_PLAN_RESERVED_11 = 0x0B, /* Reserved */
584 SMS_NUMBER_PLAN_RESERVED_12 = 0x0C, /* Reserved */
585 SMS_NUMBER_PLAN_RESERVED_13 = 0x0D, /* Reserved */
586 SMS_NUMBER_PLAN_RESERVED_14 = 0x0E, /* Reserved */
587 SMS_NUMBER_PLAN_RESERVED_15 = 0x0F, /* Reserved */
590 /** @enum telephony_sms_Is637SubAddressType_t
591 * This enum defines the plan of address
593 enum telephony_sms_Is637SubAddressType {
595 SMS_SUBADDR_NSAP = 0x00, /**< NSAP ( CCITT Recommendation X.213 or ISO 8348 AD2 ) */
596 SMS_SUBADDR_USER_SPECIFIED = 0x01, /**< User-specified */
600 * This structure defines cause code as an indication whether an SMS error has occurred and
601 * if so, whether the condition is considered temporary or permanent
603 struct telephony_sms_Is637CauseCode {
604 unsigned char ReplySeqNumber; /* Reply sequence number */
605 enum telephony_sms_Is637ErrorClass ErrClass; /* Error report class */
606 unsigned char Cause; /* Error cause identifier */
610 * This structure defines the parameters of address and its type
612 struct telephony_sms_Is637Address {
613 enum telephony_sms_Is637DigitMode Digit; /* Digit mode indicator (0x00:4bit_dtmf, 0x01:8bit_code) */
614 enum telephony_sms_Is637NumberMode NumberMode; /* Number mode indicator (0x00:ANSI TI607, 0x01:Data network) */
615 enum telephony_sms_Is637NumberType NumberType; /* Type of number */
616 enum telephony_sms_Is637NumberPlan NumberPlan; /* Numbering plan */
617 unsigned char szAddrLength; /* The number of CHARi */
618 unsigned char szAddress[SMS_MAXLENGTH_SMS_ADDRESS]; /* The address digit or character */
622 * This structure defines the parameters of subaddress of originator and destination
624 struct telephony_sms_Is637SubAddress {
625 enum telephony_sms_Is637SubAddressType SubType; /* Subaddress type */
626 unsigned char Odd; /* Odd/even indicator */
627 unsigned char szAddrLength; /* The number of CHARi */
628 unsigned char szAddress[SMS_MAXLENGTH_SMS_ADDRESS]; /* A subaddress octet */
632 * This structure defines the message center time stamp may be include
633 * with SMS message sent from a message center
635 struct telephony_sms_TimeStamp {
636 unsigned int year; /* Year - if the year is 2002, the year field contains 0x02 */
637 unsigned int month; /* Month (1 ~ 12) */
638 unsigned int day; /* Day (1 ~ 31) */
639 unsigned int hours; /* Hours (0 ~ 23) */
640 unsigned int minutes; /* Minute (0 ~ 59) */
641 unsigned int seconds; /* Seconds (0 ~ 59) */
645 * The structure defines the parameter of SMS submit message
647 struct telephony_sms_Is637OutSubmit {
648 struct telephony_sms_Is637Address DstAddr; /* Destination address */
649 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
650 unsigned short TeleService; /* Teleservice Identifier */
651 int bBearerReplySeqRequest; /* Bearer reply sequence request */
652 unsigned char ReplySeqNumber; /* Reply sequence number */
653 unsigned short MsgId; /* Message identifier */
654 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
655 unsigned short MsgLength; /* Message length */
656 unsigned char szData[SMS_MAXLENGTH_SMS_MO_USER_DATA]; /* SMS user data */
657 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute (not supported) */
658 unsigned char ValidityPeriodRel; /* Validity period - Relative (not supported) */
659 struct telephony_sms_TimeStamp DeferredDelTimeAbs; /* Deferred delivery time - Absolute */
660 unsigned char DeferredDelTimeRel; /* Deferred delivery time - Relative */
661 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
662 enum telephony_sms_Is637Privacy Privacy; /* Privacy indicator */
663 int bUserAckRequest; /* User acknowledge request */
664 int bDeliveryAckRequest; /* Delivery acknowledge request */
665 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
666 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
667 struct telephony_sms_Is637Address CallBackNumber; /* Callback number address */
671 * The structure defines the parameter of SMS acknowledgement message for submit
673 struct telephony_sms_Is637OutAck {
674 struct telephony_sms_Is637Address DstAddr; /* Destination address */
675 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
676 unsigned short TeleService; /* Teleservice Identifier */
677 int bBearerReplySeqRequest; /* Bearer reply sequence request */
678 unsigned char ReplySeqNumber; /* Reply sequence number */
679 unsigned short MsgId; /* Message identifier */
680 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
681 unsigned short MsgLength; /* Message length */
682 unsigned char szData[SMS_MAXLENGTH_SMS_MO_USER_DATA]; /* SMS user data */
683 unsigned char UserResponseCode; /* User response code */
687 * The structure defines the parameter of SMS cancellation message
689 struct telephony_sms_Is637OutCancel {
690 struct telephony_sms_Is637Address DstAddr; /* Destination address */
691 struct telephony_sms_Is637SubAddress DstSubAddr; /* Destination subaddress */
692 unsigned short TeleService; /* Teleservice Identifier */
693 int bBearerReplySeqRequest; /* Bearer reply sequence request */
694 unsigned char ReplySeqNumber; /* Reply sequence number */
695 unsigned short MsgId; /* Message identifier */
699 * The structure defines the parameter of SMS devivery message
701 struct telephony_sms_Is637InDeliver {
702 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
703 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
704 unsigned short TeleService; /* Teleservice Identifier */
705 int bBearerReplySeqRequest; /* Bearer reply sequence request */
706 unsigned char ReplySeqNumber; /* Reply sequence number */
707 unsigned short MsgId; /* Message identifier */
708 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
709 unsigned short MsgLength; /* Message length */
710 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
711 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
712 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute */
713 unsigned char ValidityPeriodRel; /* Validity period - Relative */
714 struct telephony_sms_TimeStamp DeferredDelTimeAbs; /* Deferred delivery time - Absolute (not supported) */
715 unsigned char DeferredDelTimeRel; /* Deferred delivery time - Relative (not supported) */
716 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
717 enum telephony_sms_Is637Privacy Privacy; /* Privacy indicator */
718 unsigned char NumMsg; /* Number of voice mail (0-99) */
719 int bUserAckRequest; /* User acknowledge request */
720 int bDeliveryAckRequest; /* Delivery acknowledge request */
721 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
722 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
723 struct telephony_sms_Is637Address CallBackNumer; /* Callback number address */
724 enum telephony_sms_Is637MsgDisplayMode Display; /* Message display mode */
728 * The structure defines the parameter of SMS acknowledge message for deliver
730 struct telephony_sms_Is637InAck {
731 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
732 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
733 unsigned short TeleService; /* Teleservice Identifier */
734 int bBearerReplySeqRequest; /* Bearer reply sequence request */
735 unsigned char ReplySeqNumber; /* Reply sequence number */
736 unsigned short MsgId; /* Message identifier */
737 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
738 unsigned short MsgLength; /* Message length */
739 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
740 unsigned char UserResponseCode; /* User response code */
741 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
745 * The structure defines the parameter of SMS acknowledge message from message center
747 struct telephony_sms_Is637InDeliverAck {
748 struct telephony_sms_Is637Address OrigAddr; /* Origination address */
749 struct telephony_sms_Is637SubAddress OrigSubAddr; /* Origination subaddress */
750 unsigned short TeleService; /* Teleservice Identifier */
751 int bBearerReplySeqRequest; /* Bearer reply sequence request */
752 unsigned char ReplySeqNumber; /* Reply sequence number */
753 unsigned short MsgId; /* Message identifier */
754 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
755 unsigned short MsgLength; /* Message length */
756 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
757 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
761 * The structure defines the parameter of SMS broadcast message
763 struct telephony_sms_Is637InBroadCast {
764 enum telephony_sms_BroadCastCategory ServiceCategory; /* Broadcast service category */
765 unsigned short MsgId; /* Message identifier */
766 int bBearerReplySeqRequest; /* Bearer reply sequence request */
767 unsigned char ReplySeqNumber; /* Reply sequence number */
768 unsigned short MsgEncoding; /* Message encoding (defined in TSB-58A) */
769 unsigned short MsgLength; /* Message length */
770 unsigned char szData[SMS_MAXLENGTH_SMS_MT_USER_DATA]; /* SMS user data */
771 struct telephony_sms_TimeStamp MessageCenterTimeStamp; /* Message center time stamp */
772 struct telephony_sms_TimeStamp ValidityPeriodAbs; /* Validity period - Absolute */
773 unsigned char ValidityPeriodRel; /* Validity period - Relative */
774 enum telephony_sms_Is637Priority Priority; /* Priority indicator */
775 enum telephony_sms_Is637AlertPriority AlertPriority; /* Alert priority of message */
776 enum telephony_sms_Is637LangIndicator MsgLang; /* Language indicator */
777 enum telephony_sms_Is637MsgDisplayMode Display; /* Message display mode */
778 } telephony_sms_Is637InBroadCast_t;
782 * The structure defines the type of SMS message as union
784 union telephony_sms_CdmaMessage_u {
785 struct telephony_sms_Is637OutSubmit outSubmit; /* Outgoing Submit message */
786 struct telephony_sms_Is637OutAck outAck; /* Outgoing Acknowledge message */
787 struct telephony_sms_Is637OutCancel outCancel; /* Outgoing Cancel message */
788 struct telephony_sms_Is637InDeliver inDeliver; /* Incoming Delivery message */
789 struct telephony_sms_Is637InAck inAck; /* Incoming Acknowledge message */
790 struct telephony_sms_Is637InDeliverAck inDeliverAck; /* Incoming Delivery Acknowledge message */
791 struct telephony_sms_Is637InBroadCast inBc; /* Incoming Broadcast message */
795 * The structure defines the parameter of entire SMS message of each type
797 struct telephony_sms_CdmaMsgInfo {
798 int ParamMask; /**< Parameter ID mask */
799 enum telephony_sms_CdmaMsgType MsgType; /**< Message type */
800 union telephony_sms_CdmaMessage_u MsgData; /**< Message data */
803 /*-----------------------------------------------------------------------------------------------------------------*/
804 /*-----------------------------------------------------------------------------------------------------------------*/
805 /*-----------------------------------------------------------------------------------------------------------------*/
806 /*-----------------------------------------------------------------------------------------------------------------*/
807 /*-----------------------------------------------------------------------------------------------------------------*/
810 /*---------------------------------*/
811 /* Structs of Requests */
812 /*---------------------------------*/
813 struct treq_sms_send_umts_msg {
814 struct telephony_sms_DataPackageInfo msgDataPackage;
818 struct treq_sms_send_cdma_msg {
819 struct telephony_sms_CdmaMsgInfo cdmaMsgInfo;
823 struct treq_sms_read_msg {
827 struct treq_sms_save_msg {
828 int simIndex; /* Index where SMS is stored. */
829 enum telephony_sms_MsgStatus msgStatus;
830 struct telephony_sms_DataPackageInfo msgDataPackage;
833 struct treq_sms_delete_msg {
837 struct treq_sms_get_msg_count {
840 struct treq_sms_get_sca {
844 struct treq_sms_set_sca {
845 struct telephony_sms_AddressInfo scaInfo;
849 struct treq_sms_get_cb_config {
852 struct treq_sms_set_cb_config {
853 int net3gppType; /**< Type of 3gpp, 0x01 . 3gpp. 0x02 . 3gpp2(CDMA) */
854 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) */
855 unsigned char msgIdMaxCount; /**< CB Channel List Max Count For Response */
856 int msgIdRangeCount; /**< Range of CB message ID count */
857 union telephony_sms_cb_msg_info_u msgIDs[SMS_GSM_SMS_CBMI_LIST_SIZE_MAX]; /**< Range of CB message ID information */
860 struct treq_sms_set_mem_status {
864 struct treq_sms_get_pref_bearer {
867 struct treq_sms_set_pref_bearer {
871 struct treq_sms_set_delivery_report {
872 struct telephony_sms_DataPackageInfo dataInfo;
876 struct treq_sms_set_msg_status {
878 enum telephony_sms_MsgStatus msgStatus;
881 struct treq_sms_get_params {
885 struct treq_sms_set_params {
886 struct telephony_sms_Params params;
889 struct treq_sms_get_paramcnt {
892 /*----------------------------------*/
893 /* Structs of Responses */
894 /*----------------------------------*/
895 struct tresp_sms_send_umts_msg {
899 struct tresp_sms_read_msg {
900 struct telephony_sms_Data dataInfo;
904 struct tresp_sms_save_msg {
909 struct tresp_sms_delete_msg {
914 struct tresp_sms_get_storedMsgCnt {
915 struct telephony_sms_StoredMsgCountInfo storedMsgCnt;
919 struct tresp_sms_get_sca {
920 struct telephony_sms_AddressInfo scaAddress;
924 struct tresp_sms_set_sca {
928 struct tresp_sms_get_cb_config {
929 struct telephony_sms_CbConfig cbConfig;
933 struct tresp_sms_set_cb_config {
937 struct tresp_sms_set_mem_status {
941 struct tresp_sms_get_pref_bearer {
945 struct tresp_sms_set_pref_bearer {
950 struct tresp_sms_set_delivery_report {
954 struct tresp_sms_set_msg_status {
958 struct tresp_sms_get_params {
959 struct telephony_sms_Params paramsInfo;
963 struct tresp_sms_set_params {
967 struct tresp_sms_get_paramcnt {
972 struct tresp_sms_send_cdma_msg {
973 struct telephony_sms_Is637CauseCode causeCode;
977 /*-----------------------------------*/
978 /* Structs of Notifications */
979 /*-----------------------------------*/
980 struct tnoti_sms_umts_msg {
981 struct telephony_sms_DataPackageInfo msgInfo;
984 struct tnoti_sms_cdma_msg {
985 struct telephony_sms_CdmaMsgInfo cdmaMsg;
988 struct tnoti_sms_cellBroadcast_msg {
989 struct telephony_sms_CbMsg cbMsg;
992 struct tnoti_sms_etws_msg {
993 struct telephony_sms_etws_msg etwsMsg;
996 struct tnoti_sms_memory_status {
1000 struct tnoti_sms_ready_status {