4 * Copyright (c) 2011 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.
23 * @ingroup TelephonyAPI
24 * @addtogroup NetText_TAPI NetText(SMS)
27 * @file ITapiNettext.h
29 @brief This file serves as a "C" header file defines functions for Tapi Nettext\n
30 It contains a sample set of function prototypes that would be required by applications.
34 #ifndef _ITAPI_NETTEXT_H_
35 #define _ITAPI_NETTEXT_H_
37 #include <TapiCommon.h>
38 #include <TelNetText.h>
46 * @enum TelSmsDeviceStatus
47 * This defines the enumeration for device ready value
50 TAPI_NETTEXT_DEVICE_READY = 0x01, /**< device is ready */
51 TAPI_NETTEXT_DEVICE_NOT_READY = 0x02 /**< Device not ready */
55 * @brief This API is used to send an SMS message to the network. This API interface allows transmitting SMS PDU as defined by
56 * 3GPP TS 23.040 (SMS-SUBMIT, SMS-COMMAND) to lower layers. This API allows keeping the dedicated link at lower layers
57 * by passing information as more messages to send in parameters. This will enable not to release if a dedicated connection is
58 * used for transmission. Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
60 * @par Sync (or) Async:
61 * This is an Asynchronous API.
63 * @par Important Notes:
70 * @param [in] pDataPackage
71 * - Contains SMS-SUBMIT TPDU
73 * @param [in] bMoreMsgToSend
74 * - will be set to TRUE when there are more than one message to be send or Multiple segmented concatenated
75 * message to be send, otherwise FALSE. This flag indicates OEM that more messages to send.
77 * @param [out] pRequestId
78 * - Unique identifier for a particular request.
79 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
80 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
83 * @par Async Response Message:
84 * SMS sent status is returned in this event TAPI_EVENT_NETTEXT_SENTSTATUS_CNF and the event data associated with this event
85 * is #TelSmsDatapackageInfo_t that has SMS PDU as defined by 3GPP TS 23.040(SMS-SUBMIT-REPORT). Asynchronous return status is indicated by #TelSmsResponse_t.
93 * @return Return Type (int) \n
94 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
95 * - Else it will return failure and error code (Refer #TapiResult_t)
97 * @par Prospective Clients:
101 * #include <ITapiNetText.h>
103 * TelSmsDatapackageInfo_t *pDataPackage;
107 * pDataPackage = (TelSmsDatapackageInfo_t*) malloc(sizeof(TelSmsDatapackageInfo_t));
108 * // fill the structure appropriately
109 * // Sca parameter is optional. If you don't provide Service center address, you should fill "00" in sca array.
110 * // MsgLength is length of szData//fill the szData in TelSmsDatapackageInfo_t with SMS-SUBMIT or SMS-COMMAND TPDU.
111 * ret_status = tel_send_sms (pDataPackage, 0, &RequestId);
122 /*================================================================================================*/
123 int tel_send_sms(const TelSmsDatapackageInfo_t *pDataPackage, int bMoreMsgToSend, int *pRequestId);
126 * @brief This API is used to send an SMS message to the network. This API interface allows transmitting SMS PDU as defined by
127 * 3GPP2 C.S0015 (SMS-SUBMIT, SMS-ACK, SMS-CANCEL) to lower layers. This API allows keeping the dedicated link at lower layers
128 * by passing information as more messages to send in parameters. This will enable not to release if a dedicated connection is
129 * used for transmission. Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
131 * @par Sync (or) Async:
132 * This is an Asynchronous API.
134 * @par Important Notes:
141 * @param [in] pSmsMsgInfo
142 * - Contains parameter mask, message type and data.
144 * @param [in] MoreMsgToSend
145 * - will be set to TRUE when there are more than one message to be send or Multiple segmented concatenated
146 * message to be send, otherwise FALSE. This flag indicates OEM that more messages to send.
148 * @param [out] pRequestId
149 * - Unique identifier for a particular request.
150 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
151 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
154 * @par Async Response Message:
155 * SMS sent status is returned in this event TAPI_EVENT_NETTEXT_SENTSTATUS_EX_CNF and the event data associated with this event
156 * is #TelSmsIs637CauseCode_t. Asynchronous return status is indicated by #TelSmsResponse_t.
164 * @return Return Type (int) \n
165 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
166 * - Else it will return failure and error code (Refer #TapiResult_t)
168 * @par Prospective Clients:
172 * #include <ITapiNetText.h>
173 * int ret_status = TAPI_API_SUCCESS;
175 * TelSmsMsgInfo_t pMsgInfo={0,};
178 * TelSmsMsgInfo_t *pDataPackage = malloc(sizeof(TelSmsMsgInfo_t));
180 * memset(pDataPackage, 0, sizeof(TelSmsMsgInfo_t));
181 * pDataPackage->MsgType = TAPI_NETTEXT_MESSAGETYPE_SUBMIT; //fill structure appropriately
182 * pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_TELESERVICE_MASK;
184 * ret_status = tel_send_sms_msg(pDataPackage, 0 ,&requestId);
196 /*================================================================================================*/
197 int tel_send_sms_msg(const TelSmsMsgInfo_t *pSmsMsgInfo, int MoreMsgToSend, int *pRequestId);
200 * @brief This function reads a message from SIM card storage. SIM index (index used when storing the SMS) number to be passed to in order
201 * to read particular SMS message. Total number of messages can be retrieved by #TelTapiSmsGetCount function.
202 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
204 * @par Sync (or) Async:
205 * This is an Asynchronous API.
207 * @par Important Notes:
214 * - Index number of the message to be read
216 * @param [out] pRequestId
217 * - Unique identifier for a particular request.
218 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
219 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
221 * @par Async Response Message:
222 * The event associated is TAPI_EVENT_NETTEXT_READ_SMS_CNF and the event data is #TelSmsData_t. Asynchronous return status is indicated
231 * @return Return Type (int) \n
232 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
233 * - Else it will return failure and error code (Refer #TapiResult_t)
235 * @par Prospective Clients:
239 * #include <ITapiNetText.h>
240 * int ret_status = TAPI_API_SUCCESS;
243 * ret_status = tel_read_sms_in_sim(0, &RequestId); //index value which is located in SIM
255 /*================================================================================================*/
256 int tel_read_sms_in_sim(int Index, int* pRequestId);
259 * @brief This function writes a message to SIM storage area.
260 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
262 * @par Sync (or) Async:
263 * This is an Asynchronous API.
265 * @par Important Notes:
272 * @param [in] pWriteData
273 * - SMS message structure.
275 * @param [out] pRequestId
276 * - Unique identifier for a particular request.
277 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
278 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
280 * @par Async Response Message:
281 * TAPI library will send TAPI_EVENT_NETTEXT_SAVE_STATUS_CNF asynchronous event for this request when received from TS.
282 * The associated data is SIM Index in which the message stored. Asynchronous return status is indicated by #TelSmsCause_t.
290 * @return Return Type (int) \n
291 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
292 * - Else it will return failure and error code (Refer #TapiResult_t)
294 * @par Prospective Clients:
298 * #include <ITapiNetText.h>
300 * int ret_status = TAPI_API_SUCCESS;
302 * TelSmsData_t *pWriteData;
303 * char *msg = "This is an Test SMS";
304 * char *SCA = "821091";
306 * pWriteData = malloc(sizeof(TelSmsData_t));
308 * conv_service_center_address(pWriteData->SmsData.Sca, SCA); //convert service center address
309 * conv_msg_into_tpdu(pWriteData->SmsData.szData, pWriteData->SmsData.MsgLength, msg); // convert message into TPDU
310 * pWrite->MsgStatus = TAPI_NETTEXT_STATUS_READ;
311 * pWrite->SimIndex = -1;
313 * ret_status = tel_write_sms_in_sim (pWriteData, &RequestId);
324 /*================================================================================================*/
325 int tel_write_sms_in_sim(const TelSmsData_t *pWriteData, int *pRequestId);
328 * @brief This function deletes a message specified by index (SIM index used when storing the SMS)
329 * number from the SIM storage area. Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
331 * @par Sync (or) Async:
332 * This is an Asynchronous API.
334 * @par Important Notes:
342 * - Message index to delete.
344 * @param [out] pRequestId
345 * - Unique identifier for a particular request.
346 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
347 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
349 * @par Async Response Message:
350 * The asynchronous event associated is TAPI_EVENT_NETTEXT_DELETE_STATUS_CNF and the event data is SIM index from which
351 * the message has been deleted. Asynchronous return status is indicated by #TelSmsCause_t.
359 * @return Return Type (int) \n
360 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
361 * - Else it will return failure and error code (Refer #TapiResult_t).\n
362 * @par Prospective Clients:
366 * #include <ITapiNetText.h>
368 * int ret_status = TAPI_API_SUCCESS;
371 * ret_status = tel_delete_sms_in_sim(1, &RequestId); //index which is located in SIM
383 /*================================================================================================*/
384 int tel_delete_sms_in_sim(int Index, int *pRequestId);
387 * @brief This function is used to retrieve message count information like Total record count,
388 * used record count and the indices list for SIM Storage. This is an asynchronous function and
389 * the response will be sent back by event notification. Access to this API is limited, we recommend you use Message Framework API(MAPI) besides.
390 * Access to this API is limited to in-house application.
392 * @par Sync (or) Async:
393 * This is an Asynchronous API.
395 * @par Important Notes:
402 * @param [out] pRequestId
403 * - Unique identifier for a particular request.
404 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
405 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
407 * @par Async Response Message:
408 * The event associated is TAPI_EVENT_NETTEXT_GET_COUNT_CNF and the event data is #TelSmsStoredMsgCountInfo_t.
409 * Asynchronous return status is indicated by #TelSmsCause_t.
417 * @return Return Type (int) \n
418 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
419 * - Else it will return failure and error code (Refer #TapiResult_t)
420 * @par Prospective Clients:
424 * #include <ITapiNetText.h>
426 * int ret_status = TAPI_API_SUCCESS;
429 * ret_status = tel_get_sms_count (&RequestId); //get sms count in SIM
440 /*================================================================================================*/
441 int tel_get_sms_count(int *pRequestId);
444 * @brief This function is used to set SMS CB Message Identifiers in the appropriate EF-CBMI/EF-CBMIR file in (U)SIM.
445 * This function also indicates underlying provider to enable or disable CB Channel on which CB messages are received.
446 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI) besides.
448 * @par Sync (or) Async:
449 * This is an Asynchronous API.
451 * @par Important Notes:
458 * @param [in] pCBConfig
459 * - This structure contains parameters to set SMS CB configuration \n
460 * (i) Cell broadcast service state. (Enabled/disabled.) \n
461 * (ii) Cell broadcast message identifier, which denotes whether all cell broadcast message identifiers are selected or only
463 * (iii) The list count of message identifiers to be set.\n
464 * (iv) The actual list of message identifiers to be set. Each identifier occupies 2 bytes. And the list ranges from 0x00 to 0xff. \n
465 * These message identifiers denote the source and type of the CB message. Based on the message identifiers set in the SIM,
466 * the ME receives CB messages with selected message identifiers.
468 * @param [out] pRequestId
469 * - Unique identifier for a particular request.
470 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
471 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
473 * @par Async Response Message:
474 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no data associated with this event.
475 * Asynchronous return status is indicated by #TelSmsCause_t.
483 * @return Return Type (int) \n
484 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
485 * - Else it will return failure and error code (Refer #TapiResult_t)
487 * @par Prospective Clients:
491 * #include <ITapiNetText.h>
493 * int ret_status = TAPI_API_SUCCESS;
495 * TelSmsCbConfig_t *pCBConfig = NULL;
497 * pCBConfig = (TelSmsCbConfig_t *)malloc(sizeof(TelSmsCbConfig_t));
498 * pCBConfig->bCBEnabled = 1; //fill structure appropriately
499 * pCBConfig->SelectedId = 0x01;
500 * pCBConfig->MsgIdCount = 0x02;
502 * pCBConfig->MsgIDs[0] = 0x0c;
503 * pCBConfig->MsgIDs[1] = 0x0c;
504 * pCBConfig->MsgIDs[2] = 0xdf;
505 * pCBConfig->MsgIDs[3] = 0x00;
507 * ret_status = tel_set_sms_cb_config(pCBConfig, &RequestId);
519 /*================================================================================================*/
520 int tel_set_sms_cb_config(const TelSmsCbConfig_t *pCBConfig, int *pRequestId);
523 * @brief This function is used to retrieve SMS CB configuration options from EFcbmi file in the SIM.
524 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
526 * @par Sync (or) Async:
527 * This is an Asynchronous API.
529 * @par Important Notes:
536 * @param [out] pRequestId
537 * - Unique identifier for a particular request.
538 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
539 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
541 * @par Async Response Message:
542 * The event associated is TAPI_EVENT_NETTEXT_GET_CB_CONFIG_CNF and the event data is #TelSmsCbConfig_t.
543 * Asynchronous return status is indicated by #TelSmsCause_t.
551 * @return Return Type (int) \n
552 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
553 * - Else it will return failure and error code (Refer #TapiResult_t)
554 * @par Prospective Clients:
558 * #include <ITapiNetText.h>
560 * int ret_status = TAPI_API_SUCCESS;
563 * ret_status = tel_get_sms_cb_config (&RequestId); //result will come with async response
574 /*================================================================================================*/
575 int tel_get_sms_cb_config(int *pRequestId);
579 * @brief This function is used to set SMS preferred bearer on which SMS has to be transmitted.
580 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
582 * @par Sync (or) Async:
583 * This is an Asynchronous API.
585 * @par Important Notes:
592 * @param [in] BearerType
593 * - Specifies the bearer type.
595 * @param [out] pRequestId
596 * - Unique identifier for a particular request.
597 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
598 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
600 * @par Async Response Message:
601 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no data associated with this event.
602 * Asynchronous return status is indicated by #TelSmsCause_t
610 * @return Return Type (int) \n
611 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
612 * - Else it will return failure and error code (Refer #TapiResult_t)
613 * @par Prospective Clients:
617 * #include <ITapiNetText.h>
618 * int ret_status = TAPI_API_SUCCESS;
620 * TelSmsBearerType_t BearerType = TAPI_NETTEXT_BEARER_PS_ONLY;
622 * ret_status = tel_set_sms_preferred_bearer(BearerType, &RequestId); //result will come with async response
634 /*================================================================================================*/
635 int tel_set_sms_preferred_bearer(TelSmsBearerType_t BearerType, int *pRequestId);
638 * @brief This function is used to get SMS preferred bearer on which SMS has to be transmitted.
639 * This is an asynchronous function. Access to this API is limited to in-house application and , we recommend you use Message Framework API(MAPI).
641 * @par Sync (or) Async:
642 * This is an Asynchronous API.
644 * @par Important Notes:
651 * @param [out] pRequestId
652 * - Unique identifier for a particular request.
653 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
654 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
656 * @par Async Response Message:
657 * The event associated is TAPI_EVENT_NETTEXT_GET_SMSBEARER_CNF and the associated event data is #TelSmsBearerType_t.
658 * Asynchronous return status is indicated by #TelSmsCause_t.
666 * @return Return Type (int) \n
667 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
668 * - Else it will return failure and error code (Refer #TapiResult_t)
669 * @par Prospective Clients:
673 * #include <ITapiNetText.h>
675 * int ret_status = TAPI_API_SUCCESS;
678 * ret_status = tel_get_sms_preferred_bearer(&RequestId); //result will come with async response
690 /*================================================================================================*/
691 int tel_get_sms_preferred_bearer(int *pRequestId);
694 * @brief This function is used to get the SMS parameters for a particular SMS (sent/received)
695 * based on the SIM index where it is stored. This is an asynchronous function. Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
697 * @par Sync (or) Async:
698 * This is an Asynchronous API.
700 * @par Important Notes:
708 * - SIM index where the SMS is stored
710 * @param [out] pRequestId
711 * - Unique identifier for a particular request.
712 * - pRequest Id value can be any value from 0 to 255 if the API is returned successfully
713 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
715 * @par Async Response Message:
716 * The event associated is TAPI_EVENT_NETTEXT_GET_PARAM_CNF and the event data is #TelSmsParams_t. Asynchronous return status
717 * is indicated by #TelSmsCause_t
725 * @return Return Type (int) \n
726 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
727 * - Else it will return failure and error code (Refer #TapiResult_t)
728 * @par Prospective Clients:
732 * #include <ITapiNetText.h>
734 * int ret_status = TAPI_API_SUCCESS;
737 * ret_status = tel_get_sms_parameters(1, &RequestId); //result will come with async response
749 /*================================================================================================*/
750 int tel_get_sms_parameters(int index, int *pRequestId);
753 * @brief This function is used to set the short message service header parameters which are
754 * used in the origination of MO messages. Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
756 * @par Sync (or) Async:
757 * This is an Asynchronous API.
759 * @par Important Notes:
760 * - This API updates/sets SMS Parameters in EFsmsp file in the SIM storage
766 * @param [in] pSmsSetParameters
767 * - Contains SMS header Parameter information like service center address, destination address, validity period, protocol identifier,
768 * data coding scheme.
770 * @param [out] pRequestId
771 * - Unique identifier for a particular request.
772 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
773 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
775 * @par Async Response Message:
776 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no data associated with this event. Asynchronous
777 * return status is indicated by #TelSmsCause_t
785 * @return Return Type (int) \n
786 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
787 * - Else it will return failure and error code (Refer #TapiResult_t)
788 * @par Prospective Clients:
792 * #include <ITapiNetText.h>
794 * int ret_status = TAPI_API_SUCCESS;
796 * TelSmsParams_t SmsSetParameters = {0,};
798 * SmsSetParameters.RecordIndex = 0x01;
799 * SmsSetParameters.RecordLen = 28;
800 * memcpy(SmsSetParameters.TpDestAddr.szDiallingNum, "9986529874", 10);
801 * printf("\ndial no is %s\n", SmsSetParameters.TpDestAddr.szDiallingNum);
802 * SmsSetParameters.TpDestAddr.DialNumLen = 10;
803 * SmsSetParameters.TpDestAddr.Ton = TAPI_SIM_TON_NATIONAL;//national no
804 * SmsSetParameters.TpDestAddr.Npi = TAPI_SIM_NPI_NATIONAL;
806 * ret_status = tel_set_sms_parameters(SmsSetParameters, &RequestId); //result will come with async response
818 /*================================================================================================*/
819 int tel_set_sms_parameters(const TelSmsParams_t *pSmsSetParameters, int *pRequestId);
822 * @brief This function is used to send a delivery report for the received incoming SMS to the network.
823 * Access to this API is limited to in-house application.
825 * @par Sync (or) Async:
826 * This is a Asynchronous API.
828 * @par Important Notes:
835 * @param [in] pDataPackage
836 * - Contains SMS Data package..
838 * @param [in] RPCause
839 * - Indicates the reason for SMS-DELIVER failure
841 * @param [out] pRequestId
842 * - Unique identifier for a particular request.
843 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
844 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
846 * @par Async Response Message:
847 * The event associated is TAPI_EVENT_NETTEXT_DELIVERY_REPORT_CNF and there is no associated event data. Asynchronous return status
848 * is indicated by #TelSmsResponse_t
851 * - SMS-DELIVER-REPORT message structure should be in TPDU format as specified by 3GPP TS 23.040 SMS TPDU.
856 * @return Return Type (int) \n
857 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
858 * - Else it will return failure and error code (Refer #TapiResult_t)
859 * @par Prospective Clients:
863 * #include <ITapiNetText.h>
865 * int ret_status = 0;
866 * Int requestId = -1;
867 * TelSmsResponse_t RPCause;
868 * TelSmsDatapackageInfo_t *del_report = NULL;
870 * del_report = malloc(sizeof(TelSmsDatapackageInfo_t));
871 * memset(del_report, 0, sizeof(TelSmsDatapackageInfo_t));
872 * //Encode Send Delivery Report here
873 * //EncodeSmsDeliveryReportTpdu();
875 * RPCause = TAPI_NETTEXT_SENDSMS_SUCCESS;
876 * printf("***receive message (Api:SendDeliverreport)****\n");
878 * ret_status = tel_send_sms_deliver_report(del_report, RPCause, &requestId);
890 /*================================================================================================*/
891 int tel_send_sms_deliver_report(const TelSmsDatapackageInfo_t *pDataPackage, TelSmsResponse_t RPCause, int *pRequestId);
894 * @brief This function is used to set SMS Service Centre Address information in order to send the SMS.
895 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
897 * @par Sync (or) Async:
898 * This is an Asynchronous API.
900 * @par Important Notes:
901 * - This API updates/sets service center address in EFsmsp file in the SIM storage.
908 * - Contains the service centre address informations.
911 * - Contains the record index of the Service center address information in the EF.
913 * @param [out] pRequestId
914 * - Unique identifier for a particular request.
915 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
916 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
918 * @par Async Response Message:
919 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no data associated with this event.
920 * Asynchronous return status is indicated by #TelSmsResponse_t.
928 * @return Return Type (int) \n
929 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
930 * - Else it will return failure and error code (Refer #TapiResult_t).
931 * @par Prospective Clients:
935 * #include <ITapiNetText.h>
940 * char scaNum[TAPI_NETTEXT_SCADDRESS_LEN_MAX];
941 * BYTE scaNum_len =0;
942 * TelSmsAddressInfo_t *sc_addr = NULL;
947 * printf("***Setting the SCA(Api:SetSCA)****\n");
948 * sc_addr = (TelSmsAddressInfo_t *)malloc(sizeof(TelSmsAddressInfo_t));
949 * memset(sc_addr, 0, sizeof(sc_addr));
950 * memset(scaNum, 0, sizeof(scaNum));
951 * memset(scabuf, 0, sizeof(scabuf));
952 * sprintf(scaNum, "821091");
953 * scaNum_len = strlen(scaNum);
954 * scaNum_len = strlen(scaNum);
955 * scaNum[scaNum_len] = 0;
956 * scaNum_len = scaNum_len - 1;
958 * //idx = SmsUtilEncodeAddrField(packet, scaNum, scaNum_len, 0x01, 0x01);
960 * sc_addr->DialNumLen = idx ;
961 * memcpy(sc_addr->szDiallingNum, packet, (unsigned int)idx);
962 * ret_status = tel_set_sms_sca(sc_addr, 0, &RequestId); //result will come with async response
974 /*================================================================================================*/
975 int tel_set_sms_sca(const TelSmsAddressInfo_t *pSCA, int Index, int *pRequestId);
978 * @brief This function is used to get current SMS Service Centre Address information.
979 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
981 * @par Sync (or) Async:
982 * This is a Asynchronous API.
984 * @par Important Notes:
991 * - Contains the record index of the Service center address information in the EF.
993 * @param [out] pRequestId
994 * - Unique identifier for a particular request.
995 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
996 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
998 * @par Async Response Message:
999 * The event associated is TAPI_EVENT_NETTEXT_GET_SCA_CNF and there is no data associated with this event.
1000 * Asynchronous return status is indicated by #TelSmsResponse_t.
1008 * @return Return Type (int) \n
1009 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1010 * - Else it will return failure and error code (Refer #TapiResult_t)
1011 * @par Prospective Clients:
1015 * #include <ITapiNetText.h>
1017 * int ret_status = TAPI_API_SUCCESS;
1018 * int RequestId = 0;
1020 * ret_status = tel_get_sms_sca(0, &RequestId); //result will come with async response
1032 /*================================================================================================*/
1033 int tel_get_sms_sca(int Index, int *pRequestId);
1036 * @brief This function is used by the applications to inform modem about the memory status of PDA (whether FULL or AVAILABLE) so that modem can inform network .
1037 * Access to this API is limited to in-house application.
1039 * @par Sync (or) Async:
1040 * This is a Asynchronous API.
1042 * @par Important Notes:
1049 * @param [in] memoryStatus
1050 * - Contains Memory Status
1052 * @param [out] pRequestId
1053 * - Unique identifier for a particular request.
1054 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
1055 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
1057 * @par Async Response Message:
1058 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no associated event data. Asynchronous return status
1059 * is indicated by #TelSmsResponse_t
1067 * @return Return Type (int) \n
1068 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1069 * - Else it will return failure and error code (Refer #TapiResult_t)
1070 * @par Prospective Clients:
1074 * #include <ITapiNetText.h>
1076 * int ret_status = TAPI_API_SUCCESS;
1077 * int RequestId = 0;
1078 * int MemoryStatus = TAPI_NETTEXT_PDA_MEMORY_STATUS_AVAILABLE;
1080 * ret_status = tel_set_sms_memory_status(MemoryStatus, &RequestId); //result will come with async response
1092 /*================================================================================================*/
1093 int tel_set_sms_memory_status(int memoryStatus, int *pRequestId);
1096 * @brief This function is used by the applications to set the message status in the SIM EF.
1097 * Access to this API is limited to in-house application and we recommend you use Message Framework API(MAPI).
1099 * @par Sync (or) Async:
1100 * This is a Asynchronous API.
1102 * @par Important Notes:
1110 * - Index of the message whose status has to be set.
1113 * @param [in] msgStatus
1114 * - Status of the message to be set.
1116 * @param [out] pRequestId
1117 * - Unique identifier for a particular request.
1118 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
1119 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
1121 * @par Async Response Message:
1122 * The event associated is TAPI_EVENT_NETTEXT_SET_REQUEST_CNF and there is no associated event data. Asynchronous return status
1123 * is indicated by #TelSmsResponse_t
1131 * @return Return Type (int) \n
1132 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1133 * - Else it will return failure and error code (Refer #TapiResult_t)
1134 * @par Prospective Clients:
1138 * #include <ITapiNetText.h>
1140 * int ret_status = TAPI_API_SUCCESS;
1141 * int RequestId = 0;
1143 * int MemoryStatus = TAPI_NETTEXT_PDA_MEMORY_STATUS_AVAILABLE;
1145 * ret_status = tel_set_sms_memory_status(index, MemoryStatus, &RequestId); //result will come with async response
1157 /*================================================================================================*/
1158 int tel_set_sms_message_status(int Index, TelSmsMsgStatus_t msgStatus, int *pRequestId);
1161 * @brief This function is used by the applications to get the count of SMS parameter records stored in SIM EF.
1162 * Access to this API is limited to in-house application.
1164 * @par Sync (or) Async:
1165 * This is a Asynchronous API.
1167 * @par Important Notes:
1173 * @param [out] pRequestId
1174 * - Unique identifier for a particular request.
1175 * - pRequestId value can be any value from 0 to 255 if the API is returned successfully
1176 * - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
1178 * @par Async Response Message:
1179 * The event associated is TAPI_EVENT_NETTEXT_PARAM_COUNT_IND and there is no associated event data. Asynchronous return status
1180 * is indicated by #TelSmsResponse_t
1188 * @return Return Type (int) \n
1189 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1190 * - Else it will return failure and error code (Refer #TapiResult_t)
1191 * @par Prospective Clients:
1195 * #include <ITapiNetText.h>
1197 * int ret_status = TAPI_API_SUCCESS;
1198 * int RequestId = 0;
1200 * ret_status = tel_get_sms_parameter_count (&RequestId); //result will come with async response
1211 /*================================================================================================*/
1212 int tel_get_sms_parameter_count(int *pRequestId);
1216 * @brief This function is used by the applications check the device status (whether ready or not) .
1218 * @par Sync (or) Async:
1219 * This is a Synchronous API.
1221 * @par Important Notes:
1231 * @param [out] pDeviceStatus
1232 * - Contains Device Status
1234 * @par Async Response Message:
1243 * @return Return Type (int) \n
1244 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1245 * - Else it will return failure and error code (Refer #TapiResult_t)
1246 * @par Prospective Clients:
1250 int tel_check_sms_device_status(int *pDeviceStatus);
1253 * @brief This function is used by the applications to inform modem about the PDA status(whether PDA is ready to
1254 * recieve messages from network or not).
1257 * @par Sync (or) Async:
1258 * This is a Asynchronous API.
1260 * @par Important Notes:
1273 * @par Async Response Message:
1282 * @return Return Type (int) \n
1283 * - TAPI_API_SUCCESS - indicating that the operation has completed successfully. \n
1284 * - Else it will return failure and error code (Refer #TapiResult_t)
1285 * @par Prospective Clients:
1289 int tel_set_sms_device_status(void);
1295 #endif /* _ITAPI_NETTEXT_H_ */