upload tizen1.0 source
authorKim Kibum <kb0929.kim@samsung.com>
Sun, 29 Apr 2012 08:01:28 +0000 (17:01 +0900)
committerKim Kibum <kb0929.kim@samsung.com>
Sun, 29 Apr 2012 08:01:28 +0000 (17:01 +0900)
81 files changed:
debian/changelog
include/SLP_TelephonyFW_PG.h
include/common/TapiCommon.h
include/common/TapiEvent.h
include/common/TapiUtility.h
include/common/TelCall.h
include/common/TelData.h
include/common/TelDefines.h
include/common/TelDisplay.h
include/common/TelErr.h
include/common/TelMisc.h
include/common/TelNetText.h
include/common/TelNetwork.h
include/common/TelPower.h
include/common/TelSat.h
include/common/TelSatEnvelope.h
include/common/TelSatObj.h
include/common/TelSatProactvCmd.h
include/common/TelSim.h
include/common/TelSs.h
include/common/TelUtility.h
include/common/tel_cs_conn.h
include/porting/tel_marshaler.h
include/tapi/.gitignore [deleted file]
include/tapi/ITapiCall.h
include/tapi/ITapiCfg.h
include/tapi/ITapiData.h
include/tapi/ITapiGps.h
include/tapi/ITapiMisc.h
include/tapi/ITapiNetText.h
include/tapi/ITapiNetwork.h
include/tapi/ITapiOmadm.h
include/tapi/ITapiPS.h
include/tapi/ITapiPower.h
include/tapi/ITapiProductivity.h
include/tapi/ITapiSat.h
include/tapi/ITapiSim.h
include/tapi/ITapiSound.h
include/tapi/ITapiSs.h
include/tapi/tapi_proxy.h
include/tapi/tapi_proxy_internal.h
packaging/libslp-tapi.spec
src/common_tapi_lib.c
src/common_tapi_lib_internal.c
src/porting/tel_marshaler.c
src/tapi_proxy_call.c
src/tapi_proxy_cfg.c
src/tapi_proxy_common.c
src/tapi_proxy_data.c
src/tapi_proxy_gprs.c
src/tapi_proxy_gps.c
src/tapi_proxy_misc.c
src/tapi_proxy_nettext.c
src/tapi_proxy_network.c
src/tapi_proxy_omadm.c
src/tapi_proxy_power.c
src/tapi_proxy_productivity.c
src/tapi_proxy_sat.c
src/tapi_proxy_sim.c
src/tapi_proxy_sound.c
src/tapi_proxy_ss.c
src/test_apps/Makefile [deleted file]
src/test_apps/tapi_call_test.c [deleted file]
src/test_apps/tapi_cdma_data_test.c [deleted file]
src/test_apps/tapi_cfg_test.c [deleted file]
src/test_apps/tapi_gps_test.c [deleted file]
src/test_apps/tapi_misc_test.c [deleted file]
src/test_apps/tapi_nw_test.c [deleted file]
src/test_apps/tapi_power_test.c [deleted file]
src/test_apps/tapi_ps_test.c [deleted file]
src/test_apps/tapi_sat_test.c [deleted file]
src/test_apps/tapi_sim_test.c [deleted file]
src/test_apps/tapi_sms_test.c [deleted file]
src/test_apps/tapi_sms_test.h [deleted file]
src/test_apps/tapi_sms_util.c [deleted file]
src/test_apps/tapi_sms_util.h [deleted file]
src/test_apps/tapi_sound_test.c [deleted file]
src/test_apps/tapi_ss_test.c [deleted file]
src/test_apps/tapi_svc_test.c [deleted file]
src/test_apps/tapi_test_app.c [deleted file]
src/test_apps/tapi_test_utility.h [deleted file]

index 956d667..21c8583 100644 (file)
@@ -1,3 +1,19 @@
+libslp-tapi (0.5.81) unstable; urgency=low
+
+  * add defence code in case of api return error
+  * Git: pkgs/l/libslp-tapi
+  * Tag: libslp-tapi_0.5.81
+
+ -- Kyeongchul Kim <kyeongchul.kim@samsung.com>  Wed, 21 Mar 2012 21:52:04 +0900
+
+libslp-tapi (0.5.80) unstable; urgency=low
+
+  * Remove useless comments and update phonebook record data struct 
+  * Git: pkgs/l/libslp-tapi
+  * Tag: libslp-tapi_0.5.80
+
+ -- Kyeongchul Kim <kyeongchul.kim@samsung.com>  Tue, 20 Mar 2012 15:48:23 +0900
+
 libslp-tapi (0.5.79) unstable; urgency=low
 
   * code clean up and update SIM-authentication feature 
index cef60f4..0d0ea5a 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -229,7 +229,7 @@ void registerevent()
 
        printf("MISC Event registeration is Done: sub id is %d, api_err is %d\n", subscription_id, api_err);
 
-       tel_register_app_name("org.tizen.appname");
+       tel_register_app_name("com.samsung.appname");
 }
 
 void app_callback(TelTapiEvent_t *event)
@@ -275,7 +275,7 @@ void registerevent()
        api_err = tel_register_event (TAPI_EVENT_CALL_SETUP_CNF, &subscription_id, (TelAppCallback)&app_callback);
        printf("MISC Event registeration is Done: sub id is %d, api_err is %d\n",subscription_id,api_err);
 
-       tel_register_app_name("org.tizen.appname");
+       tel_register_app_name("com.samsung.appname");
 
        // DEREGISTER EVENT
        api_err = tel_deregister_event (subscription_id);
@@ -384,7 +384,7 @@ void registereventecore()
        }
        printf("RegisterEventEcore done with subscription_id:%d and return Status:%d\n", subscription_id, api_err);
 
-       tel_register_app_name("org.tizen.appname");
+       tel_register_app_name("com.samsung.appname");
 }
 
 void app_callback(TelTapiEvent_t *event)
@@ -424,7 +424,7 @@ Void deregistereventecore()
        api_err = tel_register_event_at_ecore_loop (TAPI_EVENT_CALL_SETUP_CNF, &subscription_id, (TellAppCallback)&app_callback);
        printf("RegisterEventEcore done with subscription_id:%d and return Status:%d\n", subscription_id, api_err);
 
-       tel_register_app_name("org.tizen.appname");
+       tel_register_app_name("com.samsung.appname");
 
        // DEREGISTER EVENT
        api_err = tel_deregister_event_at_ecore_loop (subscription_id);
@@ -459,7 +459,7 @@ Void register_app_name()
        //register telephony event
        tel_register_event(...);
        //...
-       tel_register_app_name("org.tizen.appname");
+       tel_register_app_name("com.samsung.appname");
        GMainLoop *loop = g_main_loop_new(NULL, false);
        g_main_loop_run(loop);
 }
@@ -550,7 +550,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event (TAPI_EVENT_CALL_CALL_SETUP_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("VOICE CALL Event registration is Done: sub id is %d, api_err is %d\n",subscription_id,api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event (subscription_id);
@@ -1625,7 +1625,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event (TAPI_EVENT_SS_WAITING_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("SS Event registration is Done: sub id is %d, api_err is %d\n",subscription_id,api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event(subscription_id);
@@ -2698,7 +2698,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event(TAPI_EVENT_NETTEXT_SENTSTATUS_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("Nettext Class registration is Done: sub id is %d, api_err is %d\n", subscription_id, api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event(subscription_id);
@@ -4299,7 +4299,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event(TAPI_EVENT_NETWORK_GETNWBAND_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("Network Event registration is Done: sub id is %d, api_err is %d\n", subscription_id, api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event (subscription_id);
@@ -7977,7 +7977,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event (TAPI_EVENT_SOUND_VOLUMECTRL_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("VSOUND Event registration is Done: sub id is %d, api_err is %d\n",subscription_id,api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event (subscription_id);
@@ -8001,6 +8001,7 @@ This API provides an interface for controlling voice path via application.
 int tel_set_sound_path (tapi_sound_audio_path_t  vc_path, int *pRequestId);
 @endcode
 
+<strong>This API is permitted for Samsung in-house applications only</strong>
 @}
 @defgroup Use_Cases6_3 Volume control
 @ingroup Use_Cases6_SOUND
@@ -8015,6 +8016,7 @@ int     tel_set_sound_volume_info (tapi_sound_volume_control_t vol_control, int
 int     tel_get_sound_volume_info (tapi_sound_volume_type_t vol_control, int *pRequestId);
 @endcode
 
+<strong>This API is permitted for Samsung in-house applications only</strong>
 @}
 @defgroup Use_Cases6_4 Mic mute control
 @ingroup Use_Cases6_SOUND
@@ -8028,6 +8030,7 @@ This API provides an interface for mute/unmute mic via application.
 int  tel_set_sound_mute_status(tapi_sound_mic_mute_t micmute_set, int * pRequestId);
 @endcode
 
+<strong>This API is permitted for Samsung in-house applications only</strong>
 
 SAMPLE CODE
 @code
@@ -8245,7 +8248,7 @@ if (api_err != TAPI_API_SUCCESS)
 api_err = tel_register_event(TAPI_EVENT_SAT_MENU_SELECTION_CNF, &subscription_id, (TelAppCallback)&app_callback);
 printf("SAT Event registration is Done: sub id is %d, api_err is %d\n",subscription_id,api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 // DEREGISTER EVENT
 api_err = tel_deregister_event(subscription_id);
@@ -8436,6 +8439,7 @@ static void app_callback(TelTapiEvent_t *event)
 
 Telephony provides APIs for retreiving SAT Main Menu Information.
 
+<strong>This API is permitted for Samsung in-house applications only</strong>
 
 @code
 int tel_get_sat_main_menu_info(TelSatSetupMenuInfo_t* pMainMenu)
@@ -8479,6 +8483,7 @@ void mainmenuinformation()
 
 This API sends a USIM application toolkit command to the USIM, using the envelope mechanism of USIM application toolkit. (See GSM TS 31.111)
 
+<strong>These APIs are permitted for Samsung in-house applications only</strong>
 
 @code
 int tel_select_sat_menu(TelSatMenuSelectionReqInfo_t* pMenuSelect, int* pRequestId);
@@ -8588,6 +8593,7 @@ static void  SatAppCallback  (TelTapiEvent_t *event)
 
 Telephony provides this API to get the Application execution result.
 
+<strong>This API is permitted for Samsung in-house applications only</strong>
 
 @code
 Int tel_send_sat_app_exec_result(TelSatAppsRetInfo_t* pAppRetInfo);
@@ -8628,6 +8634,7 @@ void sendappexecutionresult()
 
 Send user’s confirmation message to the USIM application
 
+<strong>These APIs are permitted for Samsung in-house applications only</strong>
 
 @code
 int tel_send_sat_ui_display_status(int commandId, TelSatUiDisplayStatusType_t status);
@@ -8710,7 +8717,7 @@ if (api_err != 0)
 api_err = tel_register_event(TAPI_EVENT_PS_PDP_ACT_RSP, &subscription_id , (TelAppCallback)&app_callback);
 printf("Power Event registeration is Done: sub id is %d, api_err is %d\n", subscription_id, api_err);
 
-tel_register_app_name("org.tizen.appname");
+tel_register_app_name("com.samsung.appname");
 
 void app_callback(TelTapiEvent_t *event)
 {
@@ -8966,6 +8973,201 @@ void  ps_app_callback (TelTapiEvent_t *event)
 }
 @endcode
 @}
+@defgroup Use_Cases8_5 DataEnterDormantState
+@ingroup Use_Cases8_GPRS
+@{
+
+
+               <h3 class="pg">DataEnterDormantState</h3>
+This API is used to set the modem’s data channels to the dormant state for power saving when there is no data flowing for certain time.
+
+Precondition:
+@n GPRS session must be started before executing this API.
+
+@code
+int     tel_set_gprs_dormant (int * pRequestID);
+@endcode
+
+<strong>This API is restricted for direct use. Use the Data Network API instead.</strong>
+
+SAMPLE CODE
+@code
+#include <stdio.h>
+#include <TapiCommon.h>
+#include <ITapiPS.h>
+
+void enterdormantstate()
+{
+       int ret_status;
+       int request_id = 0;
+
+       ret_status = TelTapiDataEnterDormantState(&request_id);
+       if (ret_status == TAPI_API_SUCCESS)
+       {
+               printf("/n/ Entered Dormant State successfully \\n");
+       }
+       else
+       {
+               printf("/nerror:%d  \\n", ret_status);
+       }
+}
+//WAIT FOR EVENT HERE
+
+//CALLBACK FUNCTION TO BE USED
+void  ps_app_callback  (TelTapiEvent_t *event)
+{
+       int eventClass;
+       int eventType;
+       int  requestId;
+       int  status;
+       void  *EventData = NULL;
+
+       eventClass = event->EventClass;
+       eventType = event->EventType;
+       requestId = event->RequestId;
+       status = event->Status;
+       EventData = event->pData;
+       printf(" app _callback is called \n");
+
+       switch (eventClass)
+       {
+               case TAPI_EVENT_CLASS_DATA:
+                       switch (eventType)
+                       {
+                               case TAPI_EVENT_PS_DATA_DORMANT_RESP:
+                                       TelTapiGprsDataDormancy_t resp;
+                                       memcpy(&resp, psEvent->pData, sizeof(TelTapiGprsDataDormancy_t));
+                                       printf("TAPI_EVENT_PS_DATA_DORMANT_RESP\n");
+                                       break;
+                       }
+       }
+}
+@endcode
+@}
+@defgroup Use_Cases8_6 SetPortlist
+@ingroup Use_Cases8_GPRS
+@{
+
+
+               <h3 class="pg">SetPortlist</h3>
+This API is used to set white or black port list
+
+@code
+int tel_set_gprs_port_list(int *pRequestID);
+@endcode
+
+<strong>This API is restricted for direct use. Use the Data Network API instead.</strong>
+
+SAMPLE CODE
+@code
+#include <stdio.h>
+#include <TapiCommon.h>
+#include <ITapiPS.h>
+
+void setportlist()
+{
+       int ret_val;
+       int requestId = 0;
+       tapi_gprs_pdp_port_list_setting_info_t test;
+
+       memset(&test, 0, sizeof(tapi_gprs_pdp_port_list_setting_info_t));
+       test.tcp_list.type = TAPI_GPRS_PORT_LIST_NOT_USE;
+       test.tcp_list.len = 1;
+       test.tcp_list.list[0] = 1004;
+       test.udp_list.type = TAPI_GPRS_PORT_LIST_NOT_USE;
+       test.udp_list.len = 1;
+       test.udp_list.list[i] = 1111;
+
+       ret_val = tel_set_gprs_port_list(&test, &requestId);
+}
+//CALLBACK FUNCTION TO BE USED
+void  ps_app_callback  (TelTapiEvent_t *event)
+{
+       int eventClass;
+       int eventType;
+       int requestId;
+       int status;
+       void *EventData = NULL;
+
+       eventClass = event->EventClass;
+       eventType = event->EventType;
+       requestId = event->RequestId;
+       status = event->Status;
+       EventData = event->pData;
+       printf(" app _callback is called \n");
+
+       switch (eventClass)
+       {
+               case TAPI_EVENT_CLASS_DATA:
+                       switch (eventType)
+                       {
+                               case TAPI_EVENT_PS_DATA_DORMANT_RESP:
+                                       printf("TAPI_EVENT_PS_DATA_DORMANT_RESP\n");
+                                       break;
+                       }
+       }
+}
+@endcode
+@}
+@defgroup Use_Cases8_7 GetPortlist
+@ingroup Use_Cases8_GPRS
+@{
+
+
+               <h3 class="pg">GetPortlist</h3>
+This function is used to get white or black port list from modem
+
+@code
+int tel_get_gprs_port_list(int *pRequestID);
+@endcode
+
+<strong>This API is restricted for direct use. Use the Data Network API instead.</strong>
+
+SAMPLE CODE
+@code
+#include <stdio.h>
+#include <TapiCommon.h>
+#include <ITapiPS.h>
+
+Void getportlist()
+{
+       int ret_val;
+       int requestId = 0;
+       ret_val = tel_get_gprs_port_list(&requestId);
+}
+
+//CALLBACK FUNCTION TO BE USED
+void  ps_app_callback  (TelTapiEvent_t *event)
+{
+       int eventClass;
+       int eventType;
+       int requestId;
+       int status;
+       void *EventData = NULL;
+
+       eventClass = event->EventClass;
+       eventType = event->EventType;
+       requestId = event->RequestId;
+       status = event->Status;
+       EventData = event->pData;
+       printf(" app _callback is called \n");
+
+       switch (eventClass)
+       {
+               case TAPI_EVENT_CLASS_DATA:
+                       switch (eventType)
+                       {
+                               case TAPI_EVENT_PS_DATA_DORMANT_RESP:
+                                       tapi_gprs_pdp_port_list_setting_info_t *info;
+                                       memcpy(info, psEvent->pData, sizeof(tapi_gprs_pdp_port_list_setting_info_t));
+                                       printf("TAPI_EVENT_PS_DATA_DORMANT_RESP\n");
+                                       break;
+                       }
+       }
+}
+@endcode
+@}
+
 @defgroup Appendixes1 Appendix A. Sample Codes
 @ingroup Appendix
 @{
index 93ddbd0..937898c 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -34,9 +34,6 @@
 #ifndef _TAPI_COMMON_H_
 #define _TAPI_COMMON_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelUtility.h>
 #include <TapiEvent.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
 #define TAPI_EVENT_NAME_MAX_LEN                        128             /**< Maximum length of theevent name */
 #define TAPI_REQUEST_NOTI_ID                   0xff    /**< Request id for notification message */
 #define TAPI_REQUEST_INVALID_ID                        -1              /**< Invalid request id */
 #define TAPI_DBUS_CONNECTION_NAME_LEN_MAX      255
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  *This structure retrieves current application name registered in DBUS.
  */
@@ -82,10 +63,6 @@ typedef struct {
        void *pTunnelData; /**<Tunneling information exchanged between OEM and application(Not Null terminated string)*/
 } TelTunnelInfo_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  * @brief This API shall be used to initialize TAPI library.
  *  This API internally initiate a D-bus shared connection to communicate with Telephony Server.
@@ -481,7 +458,7 @@ int tel_check_service_ready(int *bStatus);
  * GMainLoop *loop = g_main_loop_new(NULL, false);
  *
  * tel_init();
- * tel_register_app_name("org.tizen.test"); //register application name. the format of name is not fixed
+ * tel_register_app_name("com.samsung.test"); //register application name. the format of name is not fixed
  * g_main_loop_run(loop);
  *
  * @endcode
@@ -612,4 +589,3 @@ int tel_request_tunnel(const TelTunnelInfo_t *pTunnelInfo, int *pRequestId);
 /**
  *  @}
  */
-
index 0213085..bf7f76a 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TAPI_EVENT_H_
 #define _TAPI_EVENT_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
 /**
  *   This value defines the Telephony Event Class. Class is nothing but a group of events
  *   related to a particular subsystem. Example of one Event Class is TAPI_EVENT_CLASS_CALL_VOICE.
@@ -319,6 +312,9 @@ extern "C" {
 #define TAPI_EVENT_PS_CONFIRMATION                             (TAPI_EVENT_TYPE_CONFIRMATION + (TAPI_EVENT_CLASS_DATA << 8))
 #define TAPI_EVENT_PS_PDP_ACT_RSP                              (TAPI_EVENT_PS_CONFIRMATION + 0)                        /**< 0x0B00,   -  PDP activation response event */
 #define TAPI_EVENT_PS_PDP_DEACT_RSP                            (TAPI_EVENT_PS_CONFIRMATION + 1)                        /**<      PDP deactivation response event */
+#define TAPI_EVENT_PS_DATA_DORMANT_RESP                        (TAPI_EVENT_PS_CONFIRMATION + 2)                        /**<  Dormant response event  */
+#define TAPI_EVENT_PS_PDP_SET_PORTLIST_RSP             (TAPI_EVENT_PS_CONFIRMATION + 3)                        /**<  Port List set response event  */
+#define TAPI_EVENT_PS_PDP_GET_PORTLIST_RSP             (TAPI_EVENT_PS_CONFIRMATION + 4)                        /**<  Port List get response event  */
 #define TAPI_EVENT_PS_CNF_MAX                                  (TAPI_EVENT_PS_CONFIRMATION + 5)
 
 #define TAPI_EVENT_PS_NOTIFICATION                             (TAPI_EVENT_TYPE_NOTIFICATION + (TAPI_EVENT_CLASS_DATA << 8))
@@ -534,18 +530,6 @@ extern "C" {
 #define        TAPI_EVENT_DATA_DS_TE2_DATA_RATE_INFO_NOTI      (TAPI_EVENT_CDMA_DATA_NOTIFICATION + 1)         /**< CDMA Data DS TE2 Data Rate changed indication event type. */
 #define        TAPI_EVENT_DATA_INTERNAL_IND_MAX                        (TAPI_EVENT_CDMA_DATA_NOTIFICATION + 2)
 
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  *This structure defines the Telephony Event.
  */
@@ -594,10 +578,6 @@ typedef struct TapiSubscription {
        struct TapiSubscription * next; /**< Link to the next subscription */
 } TapiSubscriptionList;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -607,4 +587,3 @@ typedef struct TapiSubscription {
 /**
  *  @}
  */
-
index fa45172..739acec 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TAPI_UTILITY_H_
 #define _TAPI_UTILITY_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <dlog.h>
-
 #include <TapiEvent.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/**
- * Log levels, refer man syslog()
- *
- * LOG_EMERG   A panic condition.  This is normally broadcast to all users.
- * LOG_ALERT   A condition that should be corrected immediately, such as a corrupted system database.
- * LOG_CRIT    Critical conditions, e.g., hard device errors.
- * LOG_ERR             Errors.
- * LOG_WARNING Warning messages.
- * LOG_NOTICE  Conditions that are not error conditions, but should possibly be handled specially.
- * LOG_INFO    Informational messages.
- * LOG_DEBUG   Messages that contain information normally of use only when debugging a program.
- */
 #define LEVEL_DEBUG            LOG_DEBUG
 #define LEVEL_INFO             LOG_DEBUG
 #define LEVEL_NOTICE   LOG_DEBUG
@@ -417,21 +393,8 @@ extern "C" {
                        } \
                }
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
 
 #endif /* _TAPI_UTILITY_H_     */
-
index 8d2ca5f..b79de3d 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,7 @@
 
 #ifndef _TEL_CALL_H_
 #define _TEL_CALL_H_
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
+
 #include <TelSs.h>
 #include <TelUtility.h>
 #include <TelDefines.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_CALLING_NAME_SIZE_MAX      80      /**< The maximum length of the string for calling party name.   */
 #define TAPI_CALL_UUS_DATA_LEN_MAX      131     /**< The Maximum length of the user to user singnalling data string.   */
 #define TAPI_CALL_DISPLAY_RECORD_MAX    32      /**< The maximum length of the string for display record in CDMA   */
@@ -68,11 +59,6 @@ extern "C" {
 #define TAPI_INVALID_CONTEXTHANDLE             (HTapiContext)-1
 #define TAPI_CLIENT_SIZE_MAX                   30
 
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * @enum TelCallCause_t
  * This structure defines the values for Call Cause.
@@ -629,11 +615,6 @@ typedef enum {
        TAPI_CALL_TSTATE_DTMF_PENDING,          /**< DTMF Timer */
 } TelTapiCallTimerState;
 
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 typedef struct {
        TS_BOOL bRequestedBySAT;                        /** This flag is to indicate whether the request has been initiated by SAT or not.Possible values are 0 and 1. This flag should be updated only when originating a setup request */
        TelCallIdentityMode_t IdentityMode; /**< Sets Calling Line Identity mode. If default value  TAPI_IDENTITY_DEFAULT is set, OEM will set the default value. */
@@ -832,10 +813,6 @@ typedef struct {
        TelCallActiveLine_t active_line;
 } TelCallAllContext_info_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -844,4 +821,3 @@ typedef struct {
 /**
  * @}
  */
-
index c706a53..a24748e 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TEL_DATA_H
 #define _TEL_DATA_H
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_DATA_MAX_DIAL_NUM_LEN                             32              /** Maximum length of dial number */
 #define TAPI_DATA_MIP_CONNECT_SUCCESS                  0xFF    /** For Sprint */
 #define TAPI_DATA_MAX_USER_NAI_LEN                             72              /** Maximum length of user NAI */
@@ -57,10 +47,6 @@ extern "C" {
 #define TAPI_DATA_MAX_PAP_USER_ID_LEN                  64              /** Maximum length of Packet PAP user ID */
 #define TAPI_DATA_MAX_PAP_USER_PASSWORD_LEN            14              /** Maximum length of Packet PAP password */
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 typedef enum {
        TAPI_DATA_NO_ERR = 0x00, /**< There is no error for any data operation. */
        TAPI_DATA_PARAMETER_ERR, /**< There is no error for any data operation. */
@@ -90,6 +76,16 @@ typedef enum {
        TAPI_DATA_SIGNAL_STATUS_ON = 0x01   /**< Signal Status On */
 } TelDataSignalStatus_t;
 
+/**
+ * @enum TelDataDormantStatus_t
+ * This enumeration defines Status of Dormant Mode.
+ */
+typedef enum {
+       TAPI_DATA_DORMANT_STATUS_DISABLE = 0x00, /**< Dormant Mode Disabled */
+       TAPI_DATA_DORMANT_STATUS_ENABLE = 0x01, /**< Dormant Mode Enabled */
+       TAPI_DATA_DORMANT_STATUS_3G_DATA_ACTIVE = 0x02 /**< 3G Data Call Activated */
+} TelDataDormantStatus_t;
+
 typedef enum {
        TAPI_DATA_TE2_TYPE_UART = 0x00,
        TAPI_DATA_TE2_TYPE_USB = 0x01,
@@ -232,11 +228,6 @@ typedef enum {
        TAPI_DATA_CALL_TYPE_HSPD = 0x02
 } TelDataPacketDataCallType_t;
 
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * This structure contains Data pin control information.
  *
@@ -307,10 +298,6 @@ typedef struct {
 }TelDataPacketDataCallConfig_t;
 
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -319,4 +306,3 @@ typedef struct {
 /**
  * @}
  */
-
index 72d639f..a303c99 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 extern "C" {
 #endif
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
 /* Machine independence */
 typedef long TS_INT32;
 typedef unsigned long TS_UINT32;
@@ -88,10 +69,6 @@ typedef unsigned short TS_USHORT;
 
 typedef int HObj;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -101,4 +78,3 @@ typedef int HObj;
 /**
  *  @}
  */
-
index 8204e32..82eeda1 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TEL_DISPLAY_H_
 #define _TEL_DISPLAY_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #include <TelDefines.h>
 #include <TelUtility.h>
 
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_MAX_DISP_O2_HOMEZONE_TAG_LEN      13      /** Maximum number of bytes Home Zone Tag name */
 #define TAPI_MAX_DISP_ROAM_INFO_LEN                            49      /* Roaming location information Maximum length is 32 bytes, But, 49 bytes in Modem code*/
 #define TAPI_MAX_DISP_PHONE_FATAL_ERR_MSG_LEN  64      /* Phone fatal error message length */
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * This defines the RSSI levels.
  * In GSM, this field represent the radio signal strength in  dBm , but in the CDMA this field represents
@@ -150,10 +135,6 @@ typedef enum {
        TAPI_DISPLAY_USER_IND_AUTHENTICATION_REQUIRED = 0x04 /**< Authentication Required */
 } tapi_display_user_ind_message_t;
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * This structure defines the display icon information
  */
@@ -208,10 +189,6 @@ typedef struct {
        unsigned char text[TAPI_MAX_DISP_ROAM_INFO_LEN];
 } tapi_display_ext_roam_info_noti_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -221,4 +198,3 @@ typedef struct {
 /**
  *  @}
  */
-
index 3424db2..0b25164 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 
 #ifndef _TEL_ERR_H_
 #define _TEL_ERR_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 
 #ifdef __cplusplus
 extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
 /************************************************************
 **    Errors defined in  "+CME ERROR" ,
 **    - see 3GPP TS 27.007
@@ -192,17 +175,6 @@ typedef enum {
        TAPI_PDP_FAILURE_CAUSE_MAX ,
 } tapi_pdp_err_t;
 
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
-
 #ifdef __cplusplus
 }
 #endif
@@ -212,4 +184,3 @@ typedef enum {
 /**
 * @}
 */
-
index b8d4651..8e4a8c4 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TEL_MISC_H_
 #define _TEL_MISC_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #include <sys/time.h>
 #include <TelDefines.h>
 
 extern "C" {
 #endif
 
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
 #define MAX_VERSION_LEN        32    /**< Maximum version length *///sw version, hw version, rf cal date, me sn
 #define FUS_DUMMY_DATA_SIZE 2     /**< Data Size*/
 
@@ -68,10 +60,6 @@ extern "C" {
 #define TAPI_MISC_MDN_LEN_MAX                          15
 #define TAPI_MISC_NAME_LEN_MAX                         17
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * @enum TelMiscApplicationKey_t
  * This enumeration defines mmi check key values
@@ -251,11 +239,6 @@ typedef enum {
        TAPI_MISC_NITZ_NO_TIME_INFO     = 0x05  /**< No time info */
 } tapi_misc_nitz_timeinfo_t;
 
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * Mobile Equipment Version Information
  */
@@ -356,10 +339,6 @@ typedef struct {
        unsigned long plmn; /**< day of week */
 } tapi_misc_time_zone_info_type;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -368,4 +347,3 @@ typedef struct {
 /**
  *  @}
  */
-
index 2798f2b..8bed006 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -33,9 +33,6 @@
 #ifndef _TEL_NETTEXT_H_
 #define _TEL_NETTEXT_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelSim.h>
 #include <TapiCommon.h>
 
@@ -44,14 +41,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 /* NetText */
 #define TAPI_NETTEXT_MSG_SIZE_MAX              918 /**< Maximum Message Size */
 #define TAPI_NETTEXT_CB_SIZE_MAX                       93 /** Maximum CB Message Size */
@@ -151,9 +140,6 @@ extern "C"
 #define TAPI_NETTEXT_ERR_CLASS4_INVALID_TRANSACTION_ID
 // ********************************************************************//
 
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
  * @enum TelSmsMsgStatus_t
  * This enumeration defines the network text status type.
@@ -471,9 +457,6 @@ typedef enum{
 
 // ********************************************************************//
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
 /**
  * This structure defines the different parameters of  CB configuration
  */
@@ -757,11 +740,6 @@ typedef struct {
 } TelSmsMsgInfo_t;
 // ********************************************************************//
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
-
 #ifdef __cplusplus
 }
 #endif
@@ -772,4 +750,3 @@ typedef struct {
 /**
  * @}
 */
-
index 6a61dcd..e439cc2 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,7 @@
 
 #ifndef _TEL_NETWORK_H_
 #define _TEL_NETWORK_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
+
 #include <TapiCommon.h>
 
 #ifdef __cplusplus
@@ -42,15 +40,6 @@ extern "C"
 {
 #endif
 
-
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 #define TAPI_NETWORK_ORDER_MAX                                 5               /**< Maximum network order */
 #define TAPI_NETWORK_LIST_MAX                                  15              /**< Maximum network list */
 #define TAPI_NETWORK_NAME_LEN_MAX                              40              /**< Maximum network name or PLMN name length*/
@@ -66,11 +55,6 @@ extern "C"
 #define TAPI_NETWORK_SUBS_NUM_LEN_MAX                  40              /**< Maximum Subscriber Number Length */
 #define TAPI_NETWORK_SUBS_ALPHA_LEN_MAX                        16              /**< Maximum Subscriber Name Length */
 
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
 /**
  * @enum TelNetworkSelectionMode_t
  *  This enumeration defines the network selection modes.
@@ -375,10 +359,6 @@ typedef enum
     TAPI_NETWORK_CDMA_EVDO_ONLY,               /**< 0x03 : EVDO ONLY */
 }TelNetworkCDMAHybridMode_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
 /**
  * This structure defines the network time and zone information.
  */
@@ -595,10 +575,6 @@ typedef struct {
        TelNetworkPrlPrefOnly_t prl_pref_only; /**< CDMA PRL Preferred Only */
 } TelNetworkRoamingMode_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -608,4 +584,3 @@ typedef struct {
 /**
 * @}
 */
-
index 1b551f0..ccb02ea 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TEL_POWER_H_
 #define _TEL_POWER_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #include <TelDefines.h>
 #include <TelUtility.h>
 
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * This defines the phone power reset commands.
  */
@@ -102,14 +86,6 @@ typedef enum {
        TAPI_POWER_BATT_STAT_NORMAL_LEVEL = 0x04 /**< Normal Level */
 } tapi_power_battery_status_level_t;
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -119,4 +95,3 @@ typedef enum {
 /**
  * @}
  */
-
index 191c060..505ed28 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -35,9 +35,6 @@
 #ifndef _TEL_SAT_H_
 #define _TEL_SAT_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelDefines.h>
 #include <TelCall.h>
 #include <TelSs.h>
@@ -50,16 +47,6 @@ extern "C"
 {
 #endif
 
-
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
 #define TAPI_SAT_DEF_TITLE_LEN_MAX                     50 /**< max length for Menu Title */
 #define TAPI_SAT_DEF_ITEM_STR_LEN_MAX          50 /**< max length for Menu Item  */
 #define TAPI_SAT_DEF_TEXT_STRING_LEN_MAX       500 /**< max length for Text String  */
@@ -70,13 +57,7 @@ extern "C"
 #define TAPI_SAT_DEF_SS_LEN_MAX             250
 #define TAPI_SAT_DEF_USSD_LEN_MAX           250
 
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony UI USER CONFIRM TYPE
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatUiUserConfirmType_t
  * This enumeration defines the UI User Confirm Type.
@@ -90,10 +71,7 @@ typedef enum
        TAPI_SAT_USER_CONFIRM_TIMEOUT,                                  /**<This enum informs that user did not respond */
 }TelSatUiUserConfirmType_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony UI INKEY TYPE
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatUiInkeyYesNoCaseType_t
  * This enumeration defines the UI Inkey Type Yes or No.
@@ -104,10 +82,7 @@ typedef enum
        TAPI_SAT_INKEY_CONFIRM_YES                              = 0x01,                 /**<Yes*/
 }TelSatUiInkeyYesNoCaseType_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony UI DISPLAY STATUS
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatUiDisplayStatusType_t
  * This enumeration defines the UI Display Status.
@@ -118,10 +93,7 @@ typedef enum
        TAPI_SAT_DISPLAY_FAIL                                   = 0x01,                                 /**<This enum informs  UI display failure*/
 }TelSatUiDisplayStatusType_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     TELEPHONY REFRESH APPLICATION TYPE
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatRefreshAppType_t
  * This enumeration defines the Refresh Application Type.
@@ -134,10 +106,7 @@ typedef enum
        TAPI_SAT_REFRESH_MAX,                                                   /**<Maximum Enumeration Value*/
 }TelSatRefreshAppType_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony COMMAND PERFORMED RESULT
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatCommandPerformResultType_t
  * This enumeration defines the Result of Proactive Command execution.
@@ -149,9 +118,7 @@ typedef enum
        TAPI_SAT_CMD_PERFORM_MAX,                                       /**<Maximum Enumeration Value*/
 }TelSatCommandPerformResultType_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony CALL CONTROL TYPE
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * @enum TelSatCallCtrlType_t
  * This enumeration defines Call Control Type.
@@ -165,13 +132,7 @@ typedef enum
        TAPI_SAT_CALL_CNF_MAX,                          /**<Maximum Enumeration Value*/
 }TelSatCallCtrlType_t;
 
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-///////////////////////////////////////////////////////////////////////////////////////////
 //     SAT UI USER CONFIRMATION INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the user confirmation data.
  */
@@ -184,9 +145,7 @@ typedef struct
        int                                                     dataLen;                                /**<Additional Data Length*/
 }TelSatUiUserConfirmInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony TEXT INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the character data for sat engine data structure.
  */
@@ -196,10 +155,7 @@ typedef struct
        unsigned char           string[TAPI_SAT_DEF_TEXT_STRING_LEN_MAX+1];             /**<character data*/
 }TelSatTextInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony MAIN MENU TITLE INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the main menu title to check sat menu.
  */
@@ -209,9 +165,7 @@ typedef struct
        TelSatTextInfo_t        mainMenuTitle;                  /**<main menu title data*/
 }TelSatMainMenuTitleInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony DISPLAY TEXT DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the display text proactive command for sat ui.
  */
@@ -225,9 +179,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                                         /**< Icon Identifier */
 }TelSatDisplayTextInd_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony INKEY DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the get inkey proactive command data for sat ui.
  */
@@ -243,10 +195,7 @@ typedef struct
        TelSatIconIdentifierInfo_t              iconId;                                 /**<Icon Identifier*/
 }TelSatGetInkeyInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony GET INPUT DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the get input proactive command data for sat ui.
  */
@@ -263,10 +212,7 @@ typedef struct
        TelSatIconIdentifierInfo_t              iconId;                                 /**<Icon Identifier*/
 }TelSatGetInputInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony PLAY TONE DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the play tone proactive command data for application.
  */
@@ -279,10 +225,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;         /**<Icon Identifier*/
 }TelSatPlayToneInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND SMS DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send sms proactive command data for sat ui.
  */
@@ -293,10 +236,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 }TelSatSendSmsIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony  SEND SS DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send ss proactive command data for sat ui.
  */
@@ -307,10 +247,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 } TelSatSendSsIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND USSD DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send ussd proactive command data for sat ui.
  */
@@ -321,10 +258,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 }TelSatSendUssdIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND DTMF DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send dtmf proactive command data for sat ui.
  */
@@ -335,10 +269,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 }TelSatSendDtmfIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony LAUNCH BROWSER  DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the launch browser proactive command data for sat ui.
  */
@@ -349,10 +280,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 }TelSatLaunchBrowserIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SETUP CALL DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the setup call proactive command data for sat ui.
  */
@@ -363,10 +291,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;                 /**<Icon Identifier*/
 } TelSatSetupCallIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony MENU ITEM DATA FOR SETUP MENU
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the menu item info for setup menu.
  */
@@ -376,9 +301,7 @@ typedef struct
        char itemId;                                                                                    /**<identifies the item on the menu that user selected*/
 }TelSatMenuInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SETUP MENU INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the sat main menu info.
  */
@@ -395,10 +318,7 @@ typedef struct
        TelSatIconIdentifierListInfo_t iconIdList;      /**<List of Icon Identifiers*/
 }TelSatSetupMenuInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SELECT ITEM DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the select item proactive command data for sat ui.
  */
@@ -415,11 +335,7 @@ typedef struct
 
 }TelSatSelectItemInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony IDLE MODE TEXT DATA
-///////////////////////////////////////////////////////////////////////////////////////////
-
 /**
  * This structure defines the setup idle mode text proactive command for idle application.
  */
@@ -430,10 +346,7 @@ typedef struct
        TelSatIconIdentifierInfo_t      iconId;
 } TelSatSetupIdleModeTextInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony REFRESH DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the refresh proactive command data for sat ui.
  */
@@ -443,11 +356,7 @@ typedef struct
        TelSatCmdQualiRefresh_t         refreshType;            /**<refresh mode*/
 }TelSatRefreshIndUiInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony REFRESH DATA
-///////////////////////////////////////////////////////////////////////////////////////////
-
 /**
  * This structure defines the refresh proactive command data for applications which are concerned with files resident on USIM .
  */
@@ -460,10 +369,7 @@ typedef struct
        TelSimFileID_t                          fileId[TAPI_SAT_REFRESH_FILE_LIST];             /**<refresh file identifier*/
 }TelSatRefreshInd_t;
 
-
-//////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony END PROACTIVE COMMAND INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the data objects to indicate to sat ui, the end of execution of a specific proactive command by other application.
  */
@@ -474,9 +380,7 @@ typedef struct
        TelSatCommandPerformResultType_t                result;                         /**<result of command execution by application*/
 }TelSatProactiveCmdEndIndInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND SMS DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send sms proactive command data for sms application.
  */
@@ -488,9 +392,7 @@ typedef struct
        TelSatSmsTpduInfo_t     smsTpdu;                                /**<SMS TPDU data*/
 } TelSatSendSmsIndSmsData_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND SS DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send ss proactive command data for ss application.
  */
@@ -501,10 +403,7 @@ typedef struct
        unsigned char           ssString[TAPI_SAT_DEF_SS_LEN_MAX+1];
 }TelSatSendSsIndSsData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony USSD DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send ussd proactive command data for ussd application.
  */
@@ -516,9 +415,7 @@ typedef struct
        unsigned char           ussdString[TAPI_SAT_DEF_USSD_LEN_MAX+1];
 }TelSatSendUssdIndUssdData_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SEND DTMF DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the send dtmf proactive command data for dtmf application.
  */
@@ -529,10 +426,7 @@ typedef struct
        TelSatTextInfo_t                dtmfString;                     /**<dtmf string data*/
 }TelSatSendDtmfIndDtmfData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SETUP CALL  DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the setup call proactive command data for call application.
  */
@@ -546,10 +440,7 @@ typedef struct
        TelSatIconIdentifierInfo_t              iconId;                 /**<icon identifier for call application*/
 }TelSatSetupCallIndCallData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony LAUNCH BROWSER DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the launch browser proactive command data for browser application.
  */
@@ -561,27 +452,20 @@ typedef struct
        TelSatBrowserIdentityType_t     IdentityType;   /**<Browser Identity -default, html, etc*/
 }TelSatLaunchBrowserIndBrowserData_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony PROVIDE LOCAL INFO DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the provide local info proactive command data for application.
  */
-
 typedef struct
 {
        int commandId;                                                                          /**<Proactive Command Number sent by USIM*/
        TelSatCmdQualiProvideLocalInfo_t localInfoType;         /**<Provide Local Information Type*/
 }TelSatProvideLocalInfoInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony LANGUAGE NOTIFICATION DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the language notification proactive command data for application.
  */
-
 typedef struct
 {
        int                                                     commandId;                                              /**<Proactive Command Number sent by USIM*/
@@ -589,10 +473,7 @@ typedef struct
        TelSatLanguageInfo_t                    language;                                       /**<language info from USIM application */
 }TelSatLanguageNotiInfoInd_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony PLAY TONE RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for Play Tone proactive command.
  */
@@ -601,10 +482,7 @@ typedef struct
        TelSatResultType_t      resp;                   /**<result response value*/
 }TelSatSetupMenuRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony REFRESH RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for refresh proactive command.
  */
@@ -614,11 +492,7 @@ typedef struct
        TelSatResultType_t              resp;                           /**<result response value*/
 }TelSatRefreshRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony CALL RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
-
 /**
  * This structure defines the return result data for setup call proactive command.
  */
@@ -636,10 +510,7 @@ typedef struct
        TelSatTextTypeInfo_t                    text;                                                   /**<call control envelope display data*/
 }TelSatCallRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SS RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for send ss proactive command.
  */
@@ -655,10 +526,7 @@ typedef struct
        TelSatResultInfo_t                                      result2;                                                /**<call control envelope result value*/
 }TelSatSsRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony USSD RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for send ussd proactive command.
  */
@@ -677,10 +545,7 @@ typedef struct
        TelSatTextTypeInfo_t                            text2;                                                  /**<cc envelope display data */
 }TelSatUssdRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SMS RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for send sms proactive command.
  */
@@ -689,10 +554,7 @@ typedef struct
        TelSatResultType_t      resp;                   /**<result response value*/
 }TelSatSmsRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony DTMF RETUEN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for send dtmf proactive command.
  */
@@ -701,10 +563,7 @@ typedef struct
        TelSatResultType_t      resp;                   /**<result response value*/
 }TelSatDtmfRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony BROWSER RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for launch browser proactive command.
  */
@@ -714,10 +573,7 @@ typedef struct
        TelSatLaunchBrowserProblemType_t    browserProblem;     /**<specific browser problem*/
 }TelSatBrowserRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony SETUP IDLE MODE TEXT RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for setup idle mode text proactive command.
  */
@@ -726,9 +582,7 @@ typedef struct
        TelSatResultType_t      resp;                   /**<result response value*/
 }TelSatIdleTextRetInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony PLAY TONE RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for Play Tone proactive command.
  */
@@ -737,9 +591,7 @@ typedef struct
        TelSatResultType_t      resp;                   /**<result response value*/
 }TelSatPlayToneRetInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony  PROVIDE LOCAL INFO RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for setup idle mode text proactive command.
  */
@@ -755,10 +607,7 @@ typedef struct
        }u;                                                                                                     /**<    Union*/
 }TelSatProvideLocalRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony LANGUAGE NOTI RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for setup idle mode text proactive command.
  */
@@ -767,10 +616,7 @@ typedef struct
                TelSatResultType_t               resp;                          /**<result response value*/
        }TelSatLanguageNotiRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony DISPLAY TEXT RETURN INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the return result data for setup idle mode text proactive command.
  */
@@ -780,9 +626,7 @@ typedef struct
                TelSatMeProblemType_t    meProblem;                     /**<Me Problem Type */
        }TelSatDiplayTextRetInfo_t;
 
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony APPLICATIONS RETURN DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the common return result data for applications proactive command.
  */
@@ -808,10 +652,7 @@ typedef struct
                }appsRet;                                                                                               /**< common union result value */
 }TelSatAppsRetInfo_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony CALL CONTROL CONFIRM  DATA FOR CALL
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the call control confirm data for call.
  */
@@ -824,10 +665,7 @@ typedef struct
        TelSatTextInfo_t                                ccp2;                                           /**< Configuration Capability Parameter 2*/
 } TelSatCallCtrlIndCallData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony CALL CONTROL CONFIRM  DATA FOR SS
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the call control confirm data for ss.
  */
@@ -840,10 +678,7 @@ typedef struct
        TelSatTextInfo_t                                ccp2;                                           /**< Configuration Capability Parameter 2*/
 } TelSatCallCtrlIndSsData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony CALL CONTROL CONFIRM  DATA FOR USSD
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the call control confirm data for ussd.
  */
@@ -852,10 +687,7 @@ typedef struct
        TelSatTextInfo_t                ussdString;                     /**< ussd destination address*/
 } TelSatCallCtrlIndUssdData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony READ FILE REQUEST DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the common call control confirm data.
  */
@@ -874,10 +706,7 @@ typedef struct
                }u;                                                                                                                             /**<   Union*/
 } TelSatCallCtrlIndData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony MO SMS CONTROL CONFIRMATION DATA
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the mo sms control confirm data.
  */
@@ -890,10 +719,7 @@ typedef struct
        TelSatTextTypeInfo_t                    tpDestAddr;                                     /**<the TP_Destination_Address */
 } TelSatMoSmCtrlIndData_t;
 
-
-///////////////////////////////////////////////////////////////////////////////////////////
 //     Telephony EVENT LIST INFO
-///////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure defines the Event List Info.
  */
@@ -931,11 +757,6 @@ typedef struct
        } u;                                                                                                                                            /**<Union*/
 } TelSatEventDownloadReqInfo_t;
 
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -945,4 +766,3 @@ typedef struct
 /**
 * @}
 */
-
index 044788c..0232bff 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 
      @brief This file serves as a "C" header file defines structures for Tapi Sat envelope command Services. \n
       It contains a sample set of constants, enums, structs that would be required by applications.
-
-
  */
 
 #ifndef _TEL_SAT_ENVELOPE_H_
 #define _TEL_SAT_ENVELOPE_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelSatObj.h>
 
 #ifdef __cplusplus
@@ -45,20 +40,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
 /**
  * @enum TelSatCallType_t
  * This enum indicates the SAT call type
@@ -98,13 +79,7 @@ typedef enum
 
 }TelSatEnvelopeResp_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-//////////////////////////////////////////////////////////////////////////////////////////
 //     8.      MENU SELECTION
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure contains the data objects for MENU SELECTION envelope.
  */
@@ -114,9 +89,7 @@ typedef struct
        int                             bIsHelpRequested;       /**<    flag to check whether help information required or not  */
 } TelSatMenuSelectionReqInfo_t;
 
-//////////////////////////////////////////////////////////////////////////////////////////
 //     9.1 CALL CONTROL BY SIM
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This struct contains the data objects for Call Control result data sent by USIM.
  */
@@ -168,9 +141,7 @@ typedef struct
        }u;                                                                                                     /**<    Union           */
 } TelSatCallCtrlIndInfo_t;
 
-//////////////////////////////////////////////////////////////////////////////////////////
 //     9.2 MO SHORT MESSAGE CONTROL BY SIM RESULT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This struct contains SAT mo ss control request data
  */
@@ -181,9 +152,7 @@ typedef struct
        TelSatMoSmsCtrlIndInfo_t                smsData;                        /**<    sms control data        */
 }TelSatMoSMCtrlResult_t;
 
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.5 EVENT DOWNLOAD - USER ACTIVITY EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This struct contains SAT user activity event request data
  */
@@ -194,9 +163,7 @@ typedef struct
 
 } TelSatUserActivityEventReqInfo_t;
 
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.6 EVENT DOWNLOAD - IDLE SCREEN AVAILABLE EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure contains the data objects for IDLE SCREEN AVAILABLE event download.
  */
@@ -205,10 +172,7 @@ typedef struct
        TelSatEventDownloadType_t       eventData;      /**<    event type      */
 } TelSatIdleScreenAvailableEventReqInfo_t;
 
-
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.8 EVENT DOWNLOAD - LANGUAGE SELECTION EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure contains the data objects for LANGUAGE SELECTION event download.
  */
@@ -217,10 +181,7 @@ typedef struct
        TelSatLanguageType_t     language;              /**<    selected language info  */
 } TelSatLanguageSelectionEventReqInfo_t;
 
-
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.9 EVENT DOWNLOAD - BROWSER TERMINATION EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This structure contains the data objects for BROWSER TERMINATION event download.
  */
@@ -229,10 +190,7 @@ typedef struct
        TelSatBrowserTerminationCauseType_t             browserTerminationCause;        /**<    browser Termination Cause       */
 } TelSatBrowserTerminationEventReqInfo_t;
 
-
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.10 EVENT DOWNLOAD - DATA AVAILABLE EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This struct contains SAT data available event request data
  */
@@ -245,9 +203,7 @@ typedef struct
 
 } TelSatDataAvailableEventReqInfo_t;
 
-//////////////////////////////////////////////////////////////////////////////////////////
 //     11.11 EVENT DOWNLOAD - CHANNEL STATUS EVENT
-//////////////////////////////////////////////////////////////////////////////////////////
 /**
  * This struct contains SAT channel status even request data
  */
@@ -258,10 +214,6 @@ typedef struct
        TelSatChannelStatusInfo_t               channelStatus;          /**<    channel Status  */
 } TelSatChannelStatusEventReqInfo_t;
 
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -271,4 +223,3 @@ typedef struct
 /**
  * @}
  */
-
index 146a89f..43e95db 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 /**
-* @open
-* @ingroup             TelephonyAPI
-* @addtogroup  SAT_TAPI        SAT
-* @{
-*
-* @file TelSatObj.h
+ * @open
+ * @ingroup            TelephonyAPI
+ * @addtogroup         SAT_TAPI        SAT
+ * @{
+ *
+ * @file TelSatObj.h
 
-     @brief This file serves as a "C" header file defines structures for Telephony SAT Services. \n
-      It contains a sample set of constants, enums, structs that would be required by applications.
-            
-            
+ @brief This file serves as a "C" header file defines structures for Telephony SAT Services. \n
+ It contains a sample set of constants, enums, structs that would be required by applications.
  */
 
 #ifndef _TEL_SAT_OBJ_H_
 #define _TEL_SAT_OBJ_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelDefines.h>
 #include <TelSim.h>
 
@@ -46,14 +41,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 #define EXTENDED_ASCII 1
 
 #define TAPI_SAT_DIALLING_NUMBER_LEN_MAX                               200      /**<   max length of dialing number            */
@@ -92,364 +79,326 @@ extern "C"
 #define TAPI_SAT_LAC_CODE_LEN                                                  2        /**<   max length of lac               */
 #define TAPI_SAT_CELL_ID_LEN                                                   2        /**<   max length of cell id   */
 
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
 /**
  * @enum TelSatAlphabetFormatType_t
  * This enum lists the Alphabet Format.
  */
-typedef enum
-{
-       TAPI_SAT_ALPHABET_FORMAT_SMS_DEFAULT    = 0x00, /**<    ALPHABET FROMAT SMS DEFAULT             */
-       TAPI_SAT_ALPHABET_FORMAT_8BIT_DATA              = 0x01, /**<    ALPHABET FROMAT 8BIT DATA               */
-       TAPI_SAT_ALPHABET_FORMAT_UCS2                   = 0x02, /**<    ALPHABET FROMAT UCS2            */
-       TAPI_SAT_ALPHABET_FORMAT_RESERVED               = 0x03  /**<    ALPHABET FROMAT RESERVED                */
+typedef enum {
+       TAPI_SAT_ALPHABET_FORMAT_SMS_DEFAULT = 0x00, /**<       ALPHABET FROMAT SMS DEFAULT             */
+       TAPI_SAT_ALPHABET_FORMAT_8BIT_DATA = 0x01, /**< ALPHABET FROMAT 8BIT DATA               */
+       TAPI_SAT_ALPHABET_FORMAT_UCS2 = 0x02, /**<      ALPHABET FROMAT UCS2            */
+       TAPI_SAT_ALPHABET_FORMAT_RESERVED = 0x03 /**<   ALPHABET FROMAT RESERVED                */
 } TelSatAlphabetFormatType_t;
 
 /**
  * @enum TelSatMsgClassType_t
  * This enum lists the message class.
  */
-typedef enum
-{
-       TAPI_SAT_MSG_CLASS_NONE                                 = 0x00, /**<    none    */
-       TAPI_SAT_MSG_CLASS_0                                    = 0x01, /**<    class 0                 */
-       TAPI_SAT_MSG_CLASS_1,                                                   /**<    class 1 Default meaning:ME-specific             */
-       TAPI_SAT_MSG_CLASS_2,                                                   /**<    class 2 SIM specific message            */
-       TAPI_SAT_MSG_CLASS_3,                                                   /**<    class 3 Default meaning: TE specific            */
-       TAPI_SAT_MSG_CLASS_RESERVED                             = 0xFF  /**<    class reserved          */
-
+typedef enum {
+       TAPI_SAT_MSG_CLASS_NONE = 0x00, /**<    none    */
+       TAPI_SAT_MSG_CLASS_0 = 0x01, /**<       class 0                 */
+       TAPI_SAT_MSG_CLASS_1, /**<      class 1 Default meaning:ME-specific             */
+       TAPI_SAT_MSG_CLASS_2, /**<      class 2 SIM specific message            */
+       TAPI_SAT_MSG_CLASS_3, /**<      class 3 Default meaning: TE specific            */
+       TAPI_SAT_MSG_CLASS_RESERVED = 0xFF /**< class reserved          */
 } TelSatMsgClassType_t;
 
 /**
  * @enum TelSatCommandType_t
  * This enum lists the type of command and the next action indicator.
  */
-typedef enum
-{
-       TAPI_SAT_CMD_TYPE_NONE                                          = 0x00, /**<    command type - None             */
-               
-       TAPI_SAT_CMD_TYPE_REFRESH                                       = 0x01, /**<    command type - refresh          */
-       TAPI_SAT_CMD_TYPE_MORE_TIME                                     = 0x02, /**<    command type - more time                */
-       TAPI_SAT_CMD_TYPE_SETUP_EVENT_LIST                      = 0x05, /**<    command type - setup event list                 */
-       TAPI_SAT_CMD_TYPE_SETUP_CALL                            = 0x10, /**<    command type - setup call               */
-       TAPI_SAT_CMD_TYPE_SEND_SS                                       = 0x11, /**<    command type - send ss          */
-       TAPI_SAT_CMD_TYPE_SEND_USSD                                     = 0x12, /**<    command type - send ussd                */
-       TAPI_SAT_CMD_TYPE_SEND_SMS                                      = 0x13, /**<    command type - send sms                 */
-       TAPI_SAT_CMD_TYPE_SEND_DTMF                     = 0x14, /**<    command type - send dtmf                */
-       TAPI_SAT_CMD_TYPE_LAUNCH_BROWSER                        = 0x15, /**<    command type - launch browser           */
-       TAPI_SAT_CMD_TYPE_PLAY_TONE                                     = 0x20, /**<    command type - play tone                */
-       TAPI_SAT_CMD_TYPE_DISPLAY_TEXT                          = 0x21, /**<    command type - display text             */
-       TAPI_SAT_CMD_TYPE_GET_INKEY                                     = 0x22, /**<    command type - get inkey                */
-       TAPI_SAT_CMD_TYPE_GET_INPUT                                     = 0x23, /**<    command type - get input                */
-       TAPI_SAT_CMD_TYPE_SELECT_ITEM                           = 0x24, /**<    command type - select item              */
-       TAPI_SAT_CMD_TYPE_SETUP_MENU                            = 0x25, /**<    command type - setup menu               */
-       TAPI_SAT_CMD_TYPE_PROVIDE_LOCAL_INFO            = 0x26, /**<    command type - provide local info               */
-       TAPI_SAT_CMD_TYPE_SETUP_IDLE_MODE_TEXT          = 0x28, /**<    command type - setup idle mode text             */
-       TAPI_SAT_CMD_TYPE_LANGUAGE_NOTIFICATION         = 0x35, /**<    command type - language notification            */
-       TAPI_SAT_CMD_TYPE_OPEN_CHANNEL                          = 0x40, /**<    command type - open channel -class e            */
-       TAPI_SAT_CMD_TYPE_CLOSE_CHANNEL                         = 0x41, /**<    command type - close channel - class e          */
-       TAPI_SAT_CMD_TYPE_RECEIVE_DATA                          = 0x42, /**<    command type - receive data -class e            */
-       TAPI_SAT_CMD_TYPE_SEND_DATA                                     = 0x43, /**<    command type - send data                */
-       TAPI_SAT_CMD_TYPE_GET_CHANNEL_STATUS            = 0x44, /**<    command type - get channel status -class e              */
-       TAPI_SAT_CMD_TYPE_END_OF_APP_EXEC                       = 0xFD, /**<    inform to End the execution of a Proactive Command*/
-       TAPI_SAT_CMD_TYPE_END_PROACTIVE_SESSION         = 0xFE, /**<    inform end proactive session            */
-       TAPI_SAT_CMD_TYPE_RESERVED                                      = 0xFF  /**<    command type - reserved         */
+typedef enum {
+       TAPI_SAT_CMD_TYPE_NONE = 0x00, /**<     command type - None             */
+
+       TAPI_SAT_CMD_TYPE_REFRESH = 0x01, /**<  command type - refresh          */
+       TAPI_SAT_CMD_TYPE_MORE_TIME = 0x02, /**<        command type - more time                */
+       TAPI_SAT_CMD_TYPE_SETUP_EVENT_LIST = 0x05, /**< command type - setup event list                 */
+       TAPI_SAT_CMD_TYPE_SETUP_CALL = 0x10, /**<       command type - setup call               */
+       TAPI_SAT_CMD_TYPE_SEND_SS = 0x11, /**<  command type - send ss          */
+       TAPI_SAT_CMD_TYPE_SEND_USSD = 0x12, /**<        command type - send ussd                */
+       TAPI_SAT_CMD_TYPE_SEND_SMS = 0x13, /**< command type - send sms                 */
+       TAPI_SAT_CMD_TYPE_SEND_DTMF = 0x14, /**<        command type - send dtmf                */
+       TAPI_SAT_CMD_TYPE_LAUNCH_BROWSER = 0x15, /**<   command type - launch browser           */
+       TAPI_SAT_CMD_TYPE_PLAY_TONE = 0x20, /**<        command type - play tone                */
+       TAPI_SAT_CMD_TYPE_DISPLAY_TEXT = 0x21, /**<     command type - display text             */
+       TAPI_SAT_CMD_TYPE_GET_INKEY = 0x22, /**<        command type - get inkey                */
+       TAPI_SAT_CMD_TYPE_GET_INPUT = 0x23, /**<        command type - get input                */
+       TAPI_SAT_CMD_TYPE_SELECT_ITEM = 0x24, /**<      command type - select item              */
+       TAPI_SAT_CMD_TYPE_SETUP_MENU = 0x25, /**<       command type - setup menu               */
+       TAPI_SAT_CMD_TYPE_PROVIDE_LOCAL_INFO = 0x26, /**<       command type - provide local info               */
+       TAPI_SAT_CMD_TYPE_SETUP_IDLE_MODE_TEXT = 0x28, /**<     command type - setup idle mode text             */
+       TAPI_SAT_CMD_TYPE_LANGUAGE_NOTIFICATION = 0x35, /**<    command type - language notification            */
+       TAPI_SAT_CMD_TYPE_OPEN_CHANNEL = 0x40, /**<     command type - open channel -class e            */
+       TAPI_SAT_CMD_TYPE_CLOSE_CHANNEL = 0x41, /**<    command type - close channel - class e          */
+       TAPI_SAT_CMD_TYPE_RECEIVE_DATA = 0x42, /**<     command type - receive data -class e            */
+       TAPI_SAT_CMD_TYPE_SEND_DATA = 0x43, /**<        command type - send data                */
+       TAPI_SAT_CMD_TYPE_GET_CHANNEL_STATUS = 0x44, /**<       command type - get channel status -class e              */
+       TAPI_SAT_CMD_TYPE_END_OF_APP_EXEC = 0xFD, /**<  inform to End the execution of a Proactive Command*/
+       TAPI_SAT_CMD_TYPE_END_PROACTIVE_SESSION = 0xFE, /**<    inform end proactive session            */
+       TAPI_SAT_CMD_TYPE_RESERVED = 0xFF /**<  command type - reserved         */
 } TelSatCommandType_t;
 
 /**
  * @enum TelSatCmdQualiRefresh_t
  * This enum lists the Command qualifier values for Refresh command.
  */
-typedef enum
-{
-       TAPI_SAT_REFRESH_SIM_INIT_AND_FULL_FCN  = 0x00, /**<    command qualifier for REFRESH SIM INIT AND FULL FILE CHANGE_NOTIFICATION                */
-       TAPI_SAT_REFRESH_FCN                                    = 0x01, /**<    command qualifier for REFRESH FILE CHANGE NOTIFICATION          */
-       TAPI_SAT_REFRESH_SIM_INIT_AND_FCN               = 0x02, /**<    command qualifier for REFRESH SIM INIT AND FILE CHANGE NOTIFICATION             */
-       TAPI_SAT_REFRESH_SIM_INIT                               = 0x03, /**<    command qualifier for REFRESH SIM INIT          */
-       TAPI_SAT_REFRESH_SIM_RESET                              = 0x04, /**<    command qualifier for REFRESH SIM RESET         */
-       TAPI_SAT_REFRESH_3G_APPLICATION_RESET   = 0x05, /**<    command qualifier for REFRESH 3G APPLICATION RESET              */
-       TAPI_SAT_REFRESH_3G_SESSION_RESET               = 0x06, /**<    command qualifier for REFRESH 3G SESSION RESET          */
-       TAPI_SAT_REFRESH_RESERVED                               = 0xFF  /**<    command qualifier for REFRESH RESERVED          */
+typedef enum {
+       TAPI_SAT_REFRESH_SIM_INIT_AND_FULL_FCN = 0x00, /**<     command qualifier for REFRESH SIM INIT AND FULL FILE CHANGE_NOTIFICATION                */
+       TAPI_SAT_REFRESH_FCN = 0x01, /**<       command qualifier for REFRESH FILE CHANGE NOTIFICATION          */
+       TAPI_SAT_REFRESH_SIM_INIT_AND_FCN = 0x02, /**<  command qualifier for REFRESH SIM INIT AND FILE CHANGE NOTIFICATION             */
+       TAPI_SAT_REFRESH_SIM_INIT = 0x03, /**<  command qualifier for REFRESH SIM INIT          */
+       TAPI_SAT_REFRESH_SIM_RESET = 0x04, /**< command qualifier for REFRESH SIM RESET         */
+       TAPI_SAT_REFRESH_3G_APPLICATION_RESET = 0x05, /**<      command qualifier for REFRESH 3G APPLICATION RESET              */
+       TAPI_SAT_REFRESH_3G_SESSION_RESET = 0x06, /**<  command qualifier for REFRESH 3G SESSION RESET          */
+       TAPI_SAT_REFRESH_RESERVED = 0xFF /**<   command qualifier for REFRESH RESERVED          */
 } TelSatCmdQualiRefresh_t;
 
 /**
  * @enum TelSatCmdQualiSetupCall_t
  * This enum lists the Command qualifier values for setup call command.
  */
-typedef enum
-{
-       TAPI_SAT_SETUP_CALL_IF_ANOTHER_CALL_NOT_BUSY                            = 0x00, /**<    command qualifier for SETUP CALL IF ANOTHER CALL NOT BUSY               */
-       TAPI_SAT_SETUP_CALL_IF_ANOTHER_CALL_NOT_BUSY_WITH_REDIAL        = 0x01, /**<    command qualifier for SETUP CALL IF ANOTHER CALL NOT BUSY WITH REDIAL           */
-       TAPI_SAT_SETUP_CALL_PUT_ALL_OTHER_CALLS_ON_HOLD                         = 0x02, /**<    command qualifier for SETUP CALL PUTTING ALL OTHER CALLS ON HOLD                */
-       TAPI_SAT_SETUP_CALL_PUT_ALL_OTHER_CALLS_ON_HOLD_WITH_REDIAL     = 0x03, /**<    command qualifier for SETUP CALL PUTTING ALL OTHER CALLS ON HOLD WITH REDIAL            */
-       TAPI_SAT_SETUP_CALL_DISCONN_ALL_OTHER_CALLS                                     = 0x04, /**<    command qualifier for SETUP CALL DISCONNECTING ALL OTHER CALLS          */
-       TAPI_SAT_SETUP_CALL_DISCONN_ALL_OTHER_CALLS_WITH_REDIAL         = 0x05, /**<    command qualifier for SETUP CALL DISCONNECTING ALL OTHER CALLS WITH REDIAL              */
-       TAPI_SAT_SETUP_CALL_RESERVED                                                            = 0xFF  /**<    command qualifier for SETUP CALL RESERVED               */
+typedef enum {
+       TAPI_SAT_SETUP_CALL_IF_ANOTHER_CALL_NOT_BUSY = 0x00, /**<       command qualifier for SETUP CALL IF ANOTHER CALL NOT BUSY               */
+       TAPI_SAT_SETUP_CALL_IF_ANOTHER_CALL_NOT_BUSY_WITH_REDIAL = 0x01, /**<   command qualifier for SETUP CALL IF ANOTHER CALL NOT BUSY WITH REDIAL           */
+       TAPI_SAT_SETUP_CALL_PUT_ALL_OTHER_CALLS_ON_HOLD = 0x02, /**<    command qualifier for SETUP CALL PUTTING ALL OTHER CALLS ON HOLD                */
+       TAPI_SAT_SETUP_CALL_PUT_ALL_OTHER_CALLS_ON_HOLD_WITH_REDIAL = 0x03, /**<        command qualifier for SETUP CALL PUTTING ALL OTHER CALLS ON HOLD WITH REDIAL            */
+       TAPI_SAT_SETUP_CALL_DISCONN_ALL_OTHER_CALLS = 0x04, /**<        command qualifier for SETUP CALL DISCONNECTING ALL OTHER CALLS          */
+       TAPI_SAT_SETUP_CALL_DISCONN_ALL_OTHER_CALLS_WITH_REDIAL = 0x05, /**<    command qualifier for SETUP CALL DISCONNECTING ALL OTHER CALLS WITH REDIAL              */
+       TAPI_SAT_SETUP_CALL_RESERVED = 0xFF /**<        command qualifier for SETUP CALL RESERVED               */
 } TelSatCmdQualiSetupCall_t;
 
 /**
  * @enum TelSatDisplayTextPriorityType_t
  * This is associated with the command qualifier for display text.
  */
-typedef enum
-{
-       TAPI_SAT_MSG_PRIORITY_NORMAL    = 0,    /**<    MSG PRIORITY NORMAL             */
-       TAPI_SAT_MSG_PRIORITY_HIGH              = 1             /**<    MSG PRIORITY HIGH               */
+typedef enum {
+       TAPI_SAT_MSG_PRIORITY_NORMAL = 0, /**<  MSG PRIORITY NORMAL             */
+       TAPI_SAT_MSG_PRIORITY_HIGH = 1 /**<     MSG PRIORITY HIGH               */
 } TelSatDisplayTextPriorityType_t;
 
 /**
  * @enum TelSatDisplayTextMsgClearType_t
  * This is associated with the command qualifier for display text.
  */
-typedef enum
-{
-       TAPI_SAT_AUTO_CLEAR_MSG_AFTER_A_DELAY           = 0,    /**<    message clear type -  AUTO CLEAR MSG AFTER A DELAY              */
-       TAPI_SAT_WAIT_FOR_USER_TO_CLEAR_MSG                     = 1             /**<    message clear type -  WAIT FOR USER TO CLEAR MSG                */
+typedef enum {
+       TAPI_SAT_AUTO_CLEAR_MSG_AFTER_A_DELAY = 0, /**< message clear type -  AUTO CLEAR MSG AFTER A DELAY              */
+       TAPI_SAT_WAIT_FOR_USER_TO_CLEAR_MSG = 1 /**<    message clear type -  WAIT FOR USER TO CLEAR MSG                */
 } TelSatDisplayTextMsgClearType_t;
 
 /**
  * @enum TelSatInkeyType_t
  * This is associated with the command qualifier for get inkey.
  */
-typedef enum
-{
-       TAPI_SAT_INKEY_TYPE_CHARACTER_SET_ENABLED       = 0,    /**<    command qualifier for  INKEY TYPE CHARACTER SET ENABLED         */
-       TAPI_SAT_INKEY_TYPE_YES_NO_REQUESTED            = 1             /**<    command qualifier for  INKEY TYPE YES NO REQUESTED              */
-
+typedef enum {
+       TAPI_SAT_INKEY_TYPE_CHARACTER_SET_ENABLED = 0, /**<     command qualifier for  INKEY TYPE CHARACTER SET ENABLED         */
+       TAPI_SAT_INKEY_TYPE_YES_NO_REQUESTED = 1 /**<   command qualifier for  INKEY TYPE YES NO REQUESTED              */
 } TelSatInkeyType_t;
 
 /**
  * @enum TelSatUseInputAlphabetType_t
  * This is associated with the command qualifier for get input.
  */
-typedef enum
-{
-       TAPI_SAT_USER_INPUT_ALPHABET_TYPE_SMS_DEFAULT   = 1,    /**<    command qualifier for  ALPHABET TYPE SMS DEFAULT                */
-       TAPI_SAT_USER_INPUT_ALPHABET_TYPE_UCS2                  = 2             /**<    command qualifier for  ALPHABET TYPE UCS2               */
+typedef enum {
+       TAPI_SAT_USER_INPUT_ALPHABET_TYPE_SMS_DEFAULT = 1, /**< command qualifier for  ALPHABET TYPE SMS DEFAULT                */
+       TAPI_SAT_USER_INPUT_ALPHABET_TYPE_UCS2 = 2 /**< command qualifier for  ALPHABET TYPE UCS2               */
 } TelSatUseInputAlphabetType_t;
 
 /**
  * @enum TelSatDisplayVibrateAlertType_t
  * This is associated with the command qualifier for play tone command.
  */
-typedef enum
-{
-       TAPI_SAT_VIBRATE_ALERT_OPTIONAL = 0,    /**<    VIBRATE ALERT UPTO THE TERMINAL         */
-       TAPI_SAT_VIBRATE_ALERT_REQUIRED = 1             /**<    VIBRATE, IF AVAILABLE, WITH TONE.               */
+typedef enum {
+       TAPI_SAT_VIBRATE_ALERT_OPTIONAL = 0, /**<       VIBRATE ALERT UPTO THE TERMINAL         */
+       TAPI_SAT_VIBRATE_ALERT_REQUIRED = 1 /**<        VIBRATE, IF AVAILABLE, WITH TONE.               */
 } TelSatDisplayVibrateAlertType_t;
 
 /**
  * @enum TelSatPresentationType_t
  * This is associated with the command qualifier for select item command.
  */
-typedef enum
-{
-       TAPI_SAT_PRESENTATION_TYPE_NOT_SPECIFIED         = 0x00,        /**<    command qualifier for PRESENTATION TYPE NOT SPECIFIED */
-       TAPI_SAT_PRESENTATION_TYPE_DATA_VALUE                    = 0x01,        /**<    command qualifier for PRESENTATION TYPE DATA VALUE              */
-       TAPI_SAT_PRESENTATION_TYPE_NAVIGATION_OPTION     = 0x02         /**<    command qualifier for PRESENTATION TYPE NAVIGATION OPTION       */
-
+typedef enum {
+       TAPI_SAT_PRESENTATION_TYPE_NOT_SPECIFIED = 0x00, /**<   command qualifier for PRESENTATION TYPE NOT SPECIFIED */
+       TAPI_SAT_PRESENTATION_TYPE_DATA_VALUE = 0x01, /**<      command qualifier for PRESENTATION TYPE DATA VALUE              */
+       TAPI_SAT_PRESENTATION_TYPE_NAVIGATION_OPTION = 0x02 /**<        command qualifier for PRESENTATION TYPE NAVIGATION OPTION       */
 } TelSatPresentationType_t;
 
 /**
  * @enum TelSatSelectionPreferenceType_t
  * This is associated with the command qualifier for select item command.
  */
-typedef enum
-{
-       TAPI_SAT_SELECTION_PREFERENCE_NONE_REQUESTED    = 0,    /**<    command qualifier for SELECTION PREFERENCE NONE REQUESTED               */
-       TAPI_SAT_SELECTION_PREFERENCE_USING_SOFT_KEY    = 1             /**<    command qualifier for SELECTION PREFERENCE USING SOFT KEY               */
+typedef enum {
+       TAPI_SAT_SELECTION_PREFERENCE_NONE_REQUESTED = 0, /**<  command qualifier for SELECTION PREFERENCE NONE REQUESTED               */
+       TAPI_SAT_SELECTION_PREFERENCE_USING_SOFT_KEY = 1 /**<   command qualifier for SELECTION PREFERENCE USING SOFT KEY               */
 } TelSatSelectionPreferenceType_t;
 
-
 /**
  * @enum TelSatCmdQualiProvideLocalInfo_t
  * This enum defines the Command qualifier values for provide local info command.
  */
-typedef enum
-{
-       TAPI_SAT_PROVIDE_DATE_TIME_AND_TIME_ZONE                = 0x03, /**<    command qualifier for PROVIDE DATE TIME AND TIME ZONE           */
-       TAPI_SAT_PROVIDE_LANGUAGE_SETTING                               = 0x04, /**<    command qualifier for PROVIDE LANGUAGE SETTING          */
-       TAPI_SAT_PROVIDE_IMEISV                                                 = 0x08,
-       TAPI_SAT_PROVIDE_RESERVED                                               = 0xFF  /**<    reserved                */
+typedef enum {
+       TAPI_SAT_PROVIDE_DATE_TIME_AND_TIME_ZONE = 0x03, /**<   command qualifier for PROVIDE DATE TIME AND TIME ZONE           */
+       TAPI_SAT_PROVIDE_LANGUAGE_SETTING = 0x04, /**<  command qualifier for PROVIDE LANGUAGE SETTING          */
+       TAPI_SAT_PROVIDE_IMEISV = 0x08, TAPI_SAT_PROVIDE_RESERVED = 0xFF /**<   reserved                */
 } TelSatCmdQualiProvideLocalInfo_t;
 
 /**
  * @enum TelSatCmdQualiLaunchBrowser_t
  * This enum defines the Command qualifier values for launch browser command.
  */
-typedef enum
-{
-       TAPI_SAT_LAUNCH_BROWSER                                 = 0,    /**<    command qualifier for  LAUNCH BROWSER           */
-       TAPI_SAT_NOT_USED                                               = 1,    /**<    command qualifier for  NOT USED         */
-       TAPI_SAT_USE_EXISTING_BROWSER                   = 2,    /**<    command qualifier for  USE EXISTING BROWSER if secure session, do not use it.           */
-       TAPI_SAT_CLOSE_AND_LAUNCH_NEW_BROWSER   = 3,    /**<    command qualifier for CLOSE AND LAUNCH NEW BROWSER              */
-       TAPI_SAT_NOT_USED2                                              = 4,    /**<    command qualifier for  NOT USED2                */
-       TAPI_SAT_LB_RESERVED                                    = 0xFF  /**<    reserved        */
-
+typedef enum {
+       TAPI_SAT_LAUNCH_BROWSER = 0, /**<       command qualifier for  LAUNCH BROWSER           */
+       TAPI_SAT_NOT_USED = 1, /**<     command qualifier for  NOT USED         */
+       TAPI_SAT_USE_EXISTING_BROWSER = 2, /**< command qualifier for  USE EXISTING BROWSER if secure session, do not use it.           */
+       TAPI_SAT_CLOSE_AND_LAUNCH_NEW_BROWSER = 3, /**< command qualifier for CLOSE AND LAUNCH NEW BROWSER              */
+       TAPI_SAT_NOT_USED2 = 4, /**<    command qualifier for  NOT USED2                */
+       TAPI_SAT_LB_RESERVED = 0xFF /**<        reserved        */
 } TelSatCmdQualiLaunchBrowser_t;
 
 /**
  * @enum TelSatDeviceIdentitiesTagType_t
  * This enum lists the device identity tag value IDs.
  */
-typedef enum
-{
-       TAPI_SAT_DEVICE_ID_KEYPAD                       = 0x01, /**<    DEVICE ID KEYPAD                */
-       TAPI_SAT_DEVICE_ID_DISPLAY                      = 0x02, /**<    DEVICE ID DISPLAY               */
-       TAPI_SAT_DEVICE_ID_EARPIECE                     = 0x03, /**<    DEVICE ID EARPIECE              */
+typedef enum {
+       TAPI_SAT_DEVICE_ID_KEYPAD = 0x01, /**<  DEVICE ID KEYPAD                */
+       TAPI_SAT_DEVICE_ID_DISPLAY = 0x02, /**< DEVICE ID DISPLAY               */
+       TAPI_SAT_DEVICE_ID_EARPIECE = 0x03, /**<        DEVICE ID EARPIECE              */
 
-       TAPI_SAT_DEVICE_ID_SIM                          = 0x81, /**<    DEVICE ID SIM           */
-       TAPI_SAT_DEVICE_ID_ME                           = 0x82, /**<    DEVICE ID ME            */
-       TAPI_SAT_DEVICE_ID_NETWORK                      = 0x83, /**<    DEVICE ID NETWORK               */
+       TAPI_SAT_DEVICE_ID_SIM = 0x81, /**<     DEVICE ID SIM           */
+       TAPI_SAT_DEVICE_ID_ME = 0x82, /**<      DEVICE ID ME            */
+       TAPI_SAT_DEVICE_ID_NETWORK = 0x83, /**< DEVICE ID NETWORK               */
 
-       TAPI_SAT_DEVICE_ID_RESERVED                     = 0XFF  /**<    reserved        */
+       TAPI_SAT_DEVICE_ID_RESERVED = 0XFF /**< reserved        */
 } TelSatDeviceIdentitiesTagType_t;
 
 /**
  * @enum TelSatTimeUnitType_t
  * This enum lists the time units for the duration data object.
  */
-typedef enum
-{
-       TAPI_SAT_TIME_UNIT_MINUTES                                              = 0x0,  /**<    time unit - minutes             */
-       TAPI_SAT_TIME_UNIT_SECONDS                                              = 0x01, /**<    time unit - second              */
-       TAPI_SAT_TIME_UNIT_TENTHS_OF_SECONDS                    = 0x02, /**<    time unit - tenths of seconds           */
-       TAPI_SAT_TIME_UNIT_RESERVED                                             = 0xFF  /**<    reserved        */
-
+typedef enum {
+       TAPI_SAT_TIME_UNIT_MINUTES = 0x0, /**<  time unit - minutes             */
+       TAPI_SAT_TIME_UNIT_SECONDS = 0x01, /**< time unit - second              */
+       TAPI_SAT_TIME_UNIT_TENTHS_OF_SECONDS = 0x02, /**<       time unit - tenths of seconds           */
+       TAPI_SAT_TIME_UNIT_RESERVED = 0xFF /**< reserved        */
 } TelSatTimeUnitType_t;
 
 /**
  * @enum TelSatResultType_t
  * This enum lists the values for the RESULT data object - General Response.
  */
-typedef enum
-{
-       TAPI_SAT_R_SUCCESS                                                                                      = 0x0,  /**<    command performed successfully */
-       TAPI_SAT_R_SUCCESS_WITH_PARTIAL_COMPREHENSION                           = 0x01, /**<    command performed with partial comprehension    */
-       TAPI_SAT_R_SUCCESS_WITH_MISSING_INFO                                            = 0x02, /**<    command performed, with missing information     */
-
-       TAPI_SAT_R_REFRESH_PERFORMED_WITH_ADDITIONAL_EFS_READ           = 0x03, /**<    REFRESH PERFORMED WITH ADDITIONAL EFS READ              */
-       TAPI_SAT_R_SUCCESS_BUT_REQUESTED_ICON_NOT_DISPLAYED                     = 0x04, /**<    command performed but REQUESTED ICON NOT DISPLAYED                      */
-       TAPI_SAT_R_SUCCESS_BUT_MODIFIED_BY_CALL_CONTROL_BY_SIM          = 0x05, /**<    command performed but MODIFIED BY CALL CONTROL BY SIM           */
-       TAPI_SAT_R_SUCCESS_LIMITED_SERVICE                                                      = 0x06, /**<    command performed with LIMITED SERVICE          */
-       TAPI_SAT_R_SUCCESS_WITH_MODIFICATION                                            = 0x07, /**<    command performed with MODIFICATION             */
-       TAPI_SAT_R_REFRESH_PRFRMD_BUT_INDICATED_USIM_NOT_ACTIVE         = 0x08, /**<    REFRESH PERFORMED BUT INDICATED USIM NOT ACTIVE                 */
-
-       TAPI_SAT_R_PROACTIVE_SESSION_TERMINATED_BY_USER                         = 0x10, /**<    proactive sim application session terminated by user            */
-       TAPI_SAT_R_BACKWARD_MOVE_BY_USER                                                        = 0x11, /**<    backward move in the proactive sim application session request by the user              */
-       TAPI_SAT_R_NO_RESPONSE_FROM_USER                                                        = 0x12, /**<    no response from user           */
-
-       TAPI_SAT_R_HELP_INFO_REQUIRED_BY_USER                                           = 0x13, /**<    HELP INFO REQUIRED BY USER              */
-       TAPI_SAT_R_USSD_OR_SS_TRANSACTION_TERMINATED_BY_USER            = 0x14, /**<    USSD OR SS TRANSACTION TERMINATED BY USER       */
-
-       TAPI_SAT_R_ME_UNABLE_TO_PROCESS_COMMAND                                         = 0x20, /**<    ME currently unable to process command          */
-       TAPI_SAT_R_NETWORK_UNABLE_TO_PROCESS_COMMAND                            = 0x21, /**<    Network currently unable to process command             */
-       TAPI_SAT_R_USER_DID_NOT_ACCEPT_CALL_SETUP_REQ                           = 0x22, /**<    User did not accept call setup request          */
-       TAPI_SAT_R_USER_CLEAR_DOWN_CALL_BEFORE_CONN                                     = 0x23, /**<    User cleared down call before connection or network released            */
-
-       TAPI_SAT_R_INTERACTION_WITH_CC_BY_SIM_IN_TMP_PRBLM                      = 0x25, /**<    INTERACTION WITH CALL CONTROL BY SIM IN TEMPORARY PROBLEM               */
-       TAPI_SAT_R_LAUNCH_BROWSER_GENERIC_ERROR_CODE                            = 0x26, /**<    LAUNCH BROWSER GENERIC ERROR CODE               */
-
-       TAPI_SAT_R_BEYOND_ME_CAPABILITIES                                                       = 0x30, /**<    command beyond ME's capabilities                */
-       TAPI_SAT_R_COMMAND_TYPE_NOT_UNDERSTOOD_BY_ME                            = 0x31, /**<    command type not understood by ME               */
-       TAPI_SAT_R_COMMAND_DATA_NOT_UNDERSTOOD_BY_ME                            = 0x32, /**<    command data not understood by ME               */
-       TAPI_SAT_R_COMMAND_NUMBER_NOT_KNOWN_BY_ME                                       = 0x33, /**<    command number not known by ME          */
-       TAPI_SAT_R_SS_RETURN_ERROR                                                                      = 0x34, /**<    SS return error         */
-       TAPI_SAT_R_SMS_RP_ERROR                                                                         = 0x35, /**<    SMS rp-error            */
-       TAPI_SAT_R_ERROR_REQUIRED_VALUES_ARE_MISSING                            = 0x36, /**<    Error, required values are missing              */
-
-       TAPI_SAT_R_USSD_RETURN_ERROR                                                            = 0x37, /**<    USSD_RETURN_ERROR               */
-       TAPI_SAT_R_INTRCTN_WITH_CC_OR_SMS_CTRL_PRMNT_PRBLM                      = 0x39, /**<    INTERACTION WITH CALL CONTROL OR SMS CONTROL PERMANENT PROBLEM          */
-       TAPI_SAT_R_BEARER_INDEPENDENT_PROTOCOL_ERROR                            = 0x3A, /**<    BEARER INDEPENDENT PROTOCOL ERROR               */
-       TAPI_SAT_R_FRAMES_ERROR                                                                         = 0x3C  /**<    FRAMES ERROR            */
+typedef enum {
+       TAPI_SAT_R_SUCCESS = 0x0, /**<  command performed successfully */
+       TAPI_SAT_R_SUCCESS_WITH_PARTIAL_COMPREHENSION = 0x01, /**<      command performed with partial comprehension    */
+       TAPI_SAT_R_SUCCESS_WITH_MISSING_INFO = 0x02, /**<       command performed, with missing information     */
+
+       TAPI_SAT_R_REFRESH_PERFORMED_WITH_ADDITIONAL_EFS_READ = 0x03, /**<      REFRESH PERFORMED WITH ADDITIONAL EFS READ              */
+       TAPI_SAT_R_SUCCESS_BUT_REQUESTED_ICON_NOT_DISPLAYED = 0x04, /**<        command performed but REQUESTED ICON NOT DISPLAYED                      */
+       TAPI_SAT_R_SUCCESS_BUT_MODIFIED_BY_CALL_CONTROL_BY_SIM = 0x05, /**<     command performed but MODIFIED BY CALL CONTROL BY SIM           */
+       TAPI_SAT_R_SUCCESS_LIMITED_SERVICE = 0x06, /**< command performed with LIMITED SERVICE          */
+       TAPI_SAT_R_SUCCESS_WITH_MODIFICATION = 0x07, /**<       command performed with MODIFICATION             */
+       TAPI_SAT_R_REFRESH_PRFRMD_BUT_INDICATED_USIM_NOT_ACTIVE = 0x08, /**<    REFRESH PERFORMED BUT INDICATED USIM NOT ACTIVE                 */
+
+       TAPI_SAT_R_PROACTIVE_SESSION_TERMINATED_BY_USER = 0x10, /**<    proactive sim application session terminated by user            */
+       TAPI_SAT_R_BACKWARD_MOVE_BY_USER = 0x11, /**<   backward move in the proactive sim application session request by the user              */
+       TAPI_SAT_R_NO_RESPONSE_FROM_USER = 0x12, /**<   no response from user           */
+
+       TAPI_SAT_R_HELP_INFO_REQUIRED_BY_USER = 0x13, /**<      HELP INFO REQUIRED BY USER              */
+       TAPI_SAT_R_USSD_OR_SS_TRANSACTION_TERMINATED_BY_USER = 0x14, /**<       USSD OR SS TRANSACTION TERMINATED BY USER       */
+
+       TAPI_SAT_R_ME_UNABLE_TO_PROCESS_COMMAND = 0x20, /**<    ME currently unable to process command          */
+       TAPI_SAT_R_NETWORK_UNABLE_TO_PROCESS_COMMAND = 0x21, /**<       Network currently unable to process command             */
+       TAPI_SAT_R_USER_DID_NOT_ACCEPT_CALL_SETUP_REQ = 0x22, /**<      User did not accept call setup request          */
+       TAPI_SAT_R_USER_CLEAR_DOWN_CALL_BEFORE_CONN = 0x23, /**<        User cleared down call before connection or network released            */
+
+       TAPI_SAT_R_INTERACTION_WITH_CC_BY_SIM_IN_TMP_PRBLM = 0x25, /**< INTERACTION WITH CALL CONTROL BY SIM IN TEMPORARY PROBLEM               */
+       TAPI_SAT_R_LAUNCH_BROWSER_GENERIC_ERROR_CODE = 0x26, /**<       LAUNCH BROWSER GENERIC ERROR CODE               */
+
+       TAPI_SAT_R_BEYOND_ME_CAPABILITIES = 0x30, /**<  command beyond ME's capabilities                */
+       TAPI_SAT_R_COMMAND_TYPE_NOT_UNDERSTOOD_BY_ME = 0x31, /**<       command type not understood by ME               */
+       TAPI_SAT_R_COMMAND_DATA_NOT_UNDERSTOOD_BY_ME = 0x32, /**<       command data not understood by ME               */
+       TAPI_SAT_R_COMMAND_NUMBER_NOT_KNOWN_BY_ME = 0x33, /**<  command number not known by ME          */
+       TAPI_SAT_R_SS_RETURN_ERROR = 0x34, /**< SS return error         */
+       TAPI_SAT_R_SMS_RP_ERROR = 0x35, /**<    SMS rp-error            */
+       TAPI_SAT_R_ERROR_REQUIRED_VALUES_ARE_MISSING = 0x36, /**<       Error, required values are missing              */
+
+       TAPI_SAT_R_USSD_RETURN_ERROR = 0x37, /**<       USSD_RETURN_ERROR               */
+       TAPI_SAT_R_INTRCTN_WITH_CC_OR_SMS_CTRL_PRMNT_PRBLM = 0x39, /**< INTERACTION WITH CALL CONTROL OR SMS CONTROL PERMANENT PROBLEM          */
+       TAPI_SAT_R_BEARER_INDEPENDENT_PROTOCOL_ERROR = 0x3A, /**<       BEARER INDEPENDENT PROTOCOL ERROR               */
+       TAPI_SAT_R_FRAMES_ERROR = 0x3C /**<     FRAMES ERROR            */
 } TelSatResultType_t;
 
-
 /**
  * @enum TelSatMeProblemType_t
  * This enum lists the values for the Additional response for the RESULT object and specifies a particular ME PROBLEM.
  */
-typedef enum
-{
-       TAPI_SAT_ME_PROBLEM_NO_SPECIFIC_CAUSE                                   = 0x0,  /**<    ME problem with NO SPECIFIC CAUSE               */
-       TAPI_SAT_ME_PROBLEM_SCREEN_BUSY                                                 = 0x01, /**<    ME problem with SCREEN BUSY             */
-       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_CALL                                             = 0x02, /**<    ME problem with ME BUSY ON CALL         */
-       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_SS                                               = 0x03, /**<    ME problem with ME_BUSY ON SS           */
-       TAPI_SAT_ME_PROBLEM_NO_SERVICE                                                  = 0x04, /**<    ME problem with NO SERVICE              */
-       TAPI_SAT_ME_PROBLEM_ACCESS_CONTROL_CLASS_BAR                    = 0x05, /**<    ME problem with ACCESS CONTROL CLASS BAR                */
-       TAPI_SAT_ME_PROBLEM_RADIO_RES_NOT_GRANTED                               = 0x06, /**<    ME problem with RADIO RES NOT GRANTED           */
-       TAPI_SAT_ME_PROBLEM_NOT_IN_SPEECH_CALL                                  = 0x07, /**<    ME problem with NOT IN SPEECH CALL      */
-       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_USSD                                             = 0x08, /**<    ME problem with ME BUSY ON USSD         */
-       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_SEND_DTMF_CMD                    = 0x09, /**<    ME problem with ME BUSY ON SEND DTMF CMD        */
-       TAPI_SAT_ME_PROBLEM_NO_USIM_ACTIVE                                              = 0x0A, /**<    ME problem with NO USIM ACTIVE          */
-       TAPI_SAT_ME_PROBLEM_INVALID                                                     = 0xFF  /**<    ME problem with INVALID                 */
+typedef enum {
+       TAPI_SAT_ME_PROBLEM_NO_SPECIFIC_CAUSE = 0x0, /**<       ME problem with NO SPECIFIC CAUSE               */
+       TAPI_SAT_ME_PROBLEM_SCREEN_BUSY = 0x01, /**<    ME problem with SCREEN BUSY             */
+       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_CALL = 0x02, /**<        ME problem with ME BUSY ON CALL         */
+       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_SS = 0x03, /**<  ME problem with ME_BUSY ON SS           */
+       TAPI_SAT_ME_PROBLEM_NO_SERVICE = 0x04, /**<     ME problem with NO SERVICE              */
+       TAPI_SAT_ME_PROBLEM_ACCESS_CONTROL_CLASS_BAR = 0x05, /**<       ME problem with ACCESS CONTROL CLASS BAR                */
+       TAPI_SAT_ME_PROBLEM_RADIO_RES_NOT_GRANTED = 0x06, /**<  ME problem with RADIO RES NOT GRANTED           */
+       TAPI_SAT_ME_PROBLEM_NOT_IN_SPEECH_CALL = 0x07, /**<     ME problem with NOT IN SPEECH CALL      */
+       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_USSD = 0x08, /**<        ME problem with ME BUSY ON USSD         */
+       TAPI_SAT_ME_PROBLEM_ME_BUSY_ON_SEND_DTMF_CMD = 0x09, /**<       ME problem with ME BUSY ON SEND DTMF CMD        */
+       TAPI_SAT_ME_PROBLEM_NO_USIM_ACTIVE = 0x0A, /**< ME problem with NO USIM ACTIVE          */
+       TAPI_SAT_ME_PROBLEM_INVALID = 0xFF /**< ME problem with INVALID                 */
 } TelSatMeProblemType_t;
 
 /**
  * @enum TelSatNetworkProblemType_t
  * This enum lists the values for the Additional response for the RESULT object and specifies a particular network PROBLEM.
  */
-typedef enum
-{
-       TAPI_SAT_NETWORK_PROBLEM_NO_SPECIFIC_CAUSE              = 0x0,  /**<    Network problem with no specific cause          */
-       TAPI_SAT_NETWORK_PROBLEM_USER_BUSY                              = 0x91  /**<    Network problem with USER BUSY          */
+typedef enum {
+       TAPI_SAT_NETWORK_PROBLEM_NO_SPECIFIC_CAUSE = 0x0, /**<  Network problem with no specific cause          */
+       TAPI_SAT_NETWORK_PROBLEM_USER_BUSY = 0x91 /**<  Network problem with USER BUSY          */
 } TelSatNetworkProblemType_t;
 
 /**
  * @enum TelSatSsProblemType_t
  * This enum lists the values for the Additional response for the RESULT object related to SEND SS.
  */
-typedef enum
-{
-       TAPI_SAT_SS_PROBLEM_NO_SPECIFIC_CAUSE                   = 0,    /**<    SS problem with no specific cause               */
-       TAPI_SAT_SS_PROBLEM_FACILITY_NOT_SUPPORTED              = 0x15  /**<    SS problem with FACILITY NOT SUPPORTED          */
+typedef enum {
+       TAPI_SAT_SS_PROBLEM_NO_SPECIFIC_CAUSE = 0, /**< SS problem with no specific cause               */
+       TAPI_SAT_SS_PROBLEM_FACILITY_NOT_SUPPORTED = 0x15 /**<  SS problem with FACILITY NOT SUPPORTED          */
 } TelSatSsProblemType_t;
 
 /**
  * @enum TelSatSmsProblemType_t
  * This enum lists the values for the Additional response for the RESULT object related to SEND SMS.
  */
-typedef enum
-{
-       TAPI_SAT_SMS_PROBLEM_NO_SPECIFIC_CAUSE                  = 0     /**<    SMS problem with no specific cause              */
+typedef enum {
+       TAPI_SAT_SMS_PROBLEM_NO_SPECIFIC_CAUSE = 0 /**< SMS problem with no specific cause              */
 } TelSatSmsProblemType_t;
 
 /**
  * @enum TelSatUssdProblemType_t
  * This enum lists the values for the Additional response for the RESULT object related to SEND USSD STRING.
  */
-typedef enum
-{
-       TAPI_SAT_USSD_PROBLEM_NO_SPECIFIC_CAUSE                 = 0,    /**<    USSD problem with no specific cause             */
-       TAPI_SAT_USSD_PROBLEM_UNKNOWN_ALPHABET                  = 0x47  /**<    USSD problem with UNKNOWN ALPHABET              */
-
+typedef enum {
+       TAPI_SAT_USSD_PROBLEM_NO_SPECIFIC_CAUSE = 0, /**<       USSD problem with no specific cause             */
+       TAPI_SAT_USSD_PROBLEM_UNKNOWN_ALPHABET = 0x47 /**<      USSD problem with UNKNOWN ALPHABET              */
 } TelSatUssdProblemType_t;
 
 /**
  * @enum TelSatCallCtrlProblemType_t
  * This enum lists the values for the Additional response for the RESULT object related to CALL CONTROL or MO SMS CONTROL.
  */
-typedef enum
-{
-       TAPI_SAT_CC_PROBLEM_NO_SPECIFIC_CAUSE                   = 0,    /**<    Call Control problem with no specific cause             */
-       TAPI_SAT_CC_PROBLEM_ACTION_NOT_ALLOWED                  = 1,    /**<    Call Control problem with action not allowed    */
-       TAPI_SAT_CC_PROBLEM_REQUEST_TYPE_HAS_CHANGED    = 2             /**<    Call Control problem with request type has changed      */
+typedef enum {
+       TAPI_SAT_CC_PROBLEM_NO_SPECIFIC_CAUSE = 0, /**< Call Control problem with no specific cause             */
+       TAPI_SAT_CC_PROBLEM_ACTION_NOT_ALLOWED = 1, /**<        Call Control problem with action not allowed    */
+       TAPI_SAT_CC_PROBLEM_REQUEST_TYPE_HAS_CHANGED = 2 /**<   Call Control problem with request type has changed      */
 } TelSatCallCtrlProblemType_t;
 
 /**
  * @enum TelSatLaunchBrowserProblemType_t
  * This enum lists the values for the Additional response for the RESULT object related to LAUNCH BROWSER PROBLEM
  */
-typedef enum
-{
-       TAPI_SAT_BROWSER_PROBLEM_NO_SPECIFIC_CAUSE                      = 0,    /**<    Browser problem with no specific cause          */
-       TAPI_SAT_BROWSER_PROBLEM_BEARER_UNAVAILABLE                     = 1,    /**<    Browser problem with bearer unavailable         */
-       TAPI_SAT_BROWSER_PROBLEM_BROWSER_UNAVAILABLE            = 2,    /**<    Browser problem with browser unavailable                */
-       TAPI_SAT_BROWSER_PRBLM_ME_UNABLE_TO_READ_PROV_DATA      = 3             /**<    Browser problem with ME unable to read provisioning data                */
-
+typedef enum {
+       TAPI_SAT_BROWSER_PROBLEM_NO_SPECIFIC_CAUSE = 0, /**<    Browser problem with no specific cause          */
+       TAPI_SAT_BROWSER_PROBLEM_BEARER_UNAVAILABLE = 1, /**<   Browser problem with bearer unavailable         */
+       TAPI_SAT_BROWSER_PROBLEM_BROWSER_UNAVAILABLE = 2, /**<  Browser problem with browser unavailable                */
+       TAPI_SAT_BROWSER_PRBLM_ME_UNABLE_TO_READ_PROV_DATA = 3 /**<     Browser problem with ME unable to read provisioning data                */
 } TelSatLaunchBrowserProblemType_t;
 
 /**
@@ -457,490 +406,438 @@ typedef enum
  * This enum lists the values for the Additional response for the RESULT object.
  *  Permanent Problems  ::: 12.12.11 ADDITIONAL INFORMATION :  BEARER INDEPENDENT PROTOCOL
  */
-typedef enum
-{
-       TAPI_SAT_BIP_PROBLEM_NO_SPECIFIC_CAUSE                  = 0x00, /**<    BIP problem with no specific cause      */
-       TAPI_SAT_BIP_PROBLEM_NO_CHANNEL_AVAILABLE               = 0x01, /**<    BIP problem with no channel available           */
-       TAPI_SAT_BIP_PROBLEM_CHANNEL_CLOSED                             = 0x02, /**<    BIP problem with channel closed                 */
-       TAPI_SAT_BIP_PROBLEM_CHANNEL_ID_NOT_VALID               = 0x03, /**<    BIP problem with channel id not valid           */
-       TAPI_SAT_BIP_PROBLEM_BUF_SIZE_NOT_AVAILABLE             = 0x04, /**<    BIP problem with buffer size not available              */
-       TAPI_SAT_BIP_PROBLEM_SECURITY_ERROR                             = 0x05, /**<    BIP problem with security error                 */
-       TAPI_SAT_BIP_PRBLM_SIM_ME_IF_TRNSPRT_LEVEL_NOT_AVL      = 0x06, /**<    BIP problem with SIM ME interface transport level not available         */
-       TAPI_SAT_BIP_REMOTE_DEV_NOT_REACHABLE                           = 0x07, /**<    BIP problem with remote device not reachable            */
-       TAPI_SAT_BIP_SERVICE_ERROR                                                      = 0x08, /**<    BIP service error               */
-       TAPI_SAT_BIP_SERVICE_IDENTIFIER_UNKNOWN                         = 0x09  /**<    BIP service identifier unknown          */
-
+typedef enum {
+       TAPI_SAT_BIP_PROBLEM_NO_SPECIFIC_CAUSE = 0x00, /**<     BIP problem with no specific cause      */
+       TAPI_SAT_BIP_PROBLEM_NO_CHANNEL_AVAILABLE = 0x01, /**<  BIP problem with no channel available           */
+       TAPI_SAT_BIP_PROBLEM_CHANNEL_CLOSED = 0x02, /**<        BIP problem with channel closed                 */
+       TAPI_SAT_BIP_PROBLEM_CHANNEL_ID_NOT_VALID = 0x03, /**<  BIP problem with channel id not valid           */
+       TAPI_SAT_BIP_PROBLEM_BUF_SIZE_NOT_AVAILABLE = 0x04, /**<        BIP problem with buffer size not available              */
+       TAPI_SAT_BIP_PROBLEM_SECURITY_ERROR = 0x05, /**<        BIP problem with security error                 */
+       TAPI_SAT_BIP_PRBLM_SIM_ME_IF_TRNSPRT_LEVEL_NOT_AVL = 0x06, /**< BIP problem with SIM ME interface transport level not available         */
+       TAPI_SAT_BIP_REMOTE_DEV_NOT_REACHABLE = 0x07, /**<      BIP problem with remote device not reachable            */
+       TAPI_SAT_BIP_SERVICE_ERROR = 0x08, /**< BIP service error               */
+       TAPI_SAT_BIP_SERVICE_IDENTIFIER_UNKNOWN = 0x09 /**<     BIP service identifier unknown          */
 } TelSatBipProblemType_t;
 
 /**
  * @enum TelSatSmsTpduType_t
  * This enum lists the values for the SMS TPDU type.
  */
-typedef enum
-{
-       TAPI_SAT_SMS_TPDU_TYPE_DELIVER_TPDU             = 0,    /**<    sms tpdu type - DELIVER TPDU    */
-       TAPI_SAT_SMS_TPDU_TYPE_DELIVER_RPT              = 1,    /**<    sms tpdu type - DELIVER RPT     */
-       TAPI_SAT_SMS_TPDU_TYPE_SUBMIT_TPDU              = 2,    /**<    sms tpdu type - SUBMIT TPDU             */
-       TAPI_SAT_SMS_TPDU_TYPE_SUBMIT_RPT               = 3,    /**<    sms tpdu type - SUBMIT RPT      */
-       TAPI_SAT_SMS_TPDU_TYPE_STATUS_RPT               = 4,    /**<    sms tpdu type - STATUS RPT      */
-       TAPI_SAT_SMS_TPDU_TYPE_TPDU_CMD                 = 5             /**<    sms tpdu type - TPDU CMD        */
-
+typedef enum {
+       TAPI_SAT_SMS_TPDU_TYPE_DELIVER_TPDU = 0, /**<   sms tpdu type - DELIVER TPDU    */
+       TAPI_SAT_SMS_TPDU_TYPE_DELIVER_RPT = 1, /**<    sms tpdu type - DELIVER RPT     */
+       TAPI_SAT_SMS_TPDU_TYPE_SUBMIT_TPDU = 2, /**<    sms tpdu type - SUBMIT TPDU             */
+       TAPI_SAT_SMS_TPDU_TYPE_SUBMIT_RPT = 3, /**<     sms tpdu type - SUBMIT RPT      */
+       TAPI_SAT_SMS_TPDU_TYPE_STATUS_RPT = 4, /**<     sms tpdu type - STATUS RPT      */
+       TAPI_SAT_SMS_TPDU_TYPE_TPDU_CMD = 5 /**<        sms tpdu type - TPDU CMD        */
 } TelSatSmsTpduType_t;
 
 /**
  * @enum TelSatToneType_t
  * This enum lists the values tones type.
  */
-typedef enum
-{
+typedef enum {
        // standard supervisory tones
-       TAPI_SAT_DIAL_TONE                                      = 0x01, /**<    TONE TYPE DIAL TONE             */
-       TAPI_SAT_CALLED_SUBSCRIBER_BUSY         = 0x02, /**<    TONE TYPE CALLED SUBSCRIBER BUSY                */
-       TAPI_SAT_CONGESTION                                     = 0x03, /**<    TONE TYPE CONGESTION    */
-       TAPI_SAT_RADIO_PATH_ACK                         = 0x04, /**<    TONE TYPE RADIO PATH ACK        */
-       TAPI_SAT_RADIO_PATH_NOT_AVAILABLE_CALL_DROPPED  = 0x05, /**<    TONE TYPE RADIO PATH NOT AVAILABLE CALL DROPPED */
-       TAPI_SAT_ERR_SPECIAL_INFO                                               = 0x06, /**<    TONE TYPE ERR SPECIAL INFO      */
-       TAPI_SAT_CALL_WAITING_TONE                                              = 0x07, /**<    TONE TYPE CALL WAITING TONE             */
-       TAPI_SAT_RINGING_TONE                                                   = 0x08, /**<    TONE TYPE RINGING TONE  */
+       TAPI_SAT_DIAL_TONE = 0x01, /**< TONE TYPE DIAL TONE             */
+       TAPI_SAT_CALLED_SUBSCRIBER_BUSY = 0x02, /**<    TONE TYPE CALLED SUBSCRIBER BUSY                */
+       TAPI_SAT_CONGESTION = 0x03, /**<        TONE TYPE CONGESTION    */
+       TAPI_SAT_RADIO_PATH_ACK = 0x04, /**<    TONE TYPE RADIO PATH ACK        */
+       TAPI_SAT_RADIO_PATH_NOT_AVAILABLE_CALL_DROPPED = 0x05, /**<     TONE TYPE RADIO PATH NOT AVAILABLE CALL DROPPED */
+       TAPI_SAT_ERR_SPECIAL_INFO = 0x06, /**<  TONE TYPE ERR SPECIAL INFO      */
+       TAPI_SAT_CALL_WAITING_TONE = 0x07, /**< TONE TYPE CALL WAITING TONE             */
+       TAPI_SAT_RINGING_TONE = 0x08, /**<      TONE TYPE RINGING TONE  */
 
        // ME proprietary tones
-       TAPI_SAT_GENERAL_BEEP                                   = 0x10, /**<    TONE TYPE GENERAL BEEP          */
-       TAPI_SAT_POSITIVE_ACK_TONE                              = 0x11, /**<    TONE TYPE POSITIVE ACK TONE             */
-       TAPI_SAT_NEGATIVE_ACK_OR_ERROR_TONE             = 0x12, /**<    TONE TYPE NEGATIVE ACK OR ERROR TONE            */
-       TAPI_SAT_RINGING_TONE_SLCTD_BY_USR_FOR_INCOM_SPEECH_CALL         = 0x13,        /**<    TONE TYPE RINGING TONE SELECTED BY USER FOR INCOMING SPEECH CALL                */
-       TAPI_SAT_ALERT_TONE_SELECTED_BY_USER_FOR_INCOMING_SMS            = 0x14,        /**<    TONE TYPE ALERT TONE SELECTED BY USER FOR INCOMING SMS          */
-       TAPI_SAT_CRITICAL_ALERT                                 = 0x15, /**<    TONE TYPE CRITICAL ALERT                */
+       TAPI_SAT_GENERAL_BEEP = 0x10, /**<      TONE TYPE GENERAL BEEP          */
+       TAPI_SAT_POSITIVE_ACK_TONE = 0x11, /**< TONE TYPE POSITIVE ACK TONE             */
+       TAPI_SAT_NEGATIVE_ACK_OR_ERROR_TONE = 0x12, /**<        TONE TYPE NEGATIVE ACK OR ERROR TONE            */
+       TAPI_SAT_RINGING_TONE_SLCTD_BY_USR_FOR_INCOM_SPEECH_CALL = 0x13, /**<   TONE TYPE RINGING TONE SELECTED BY USER FOR INCOMING SPEECH CALL                */
+       TAPI_SAT_ALERT_TONE_SELECTED_BY_USER_FOR_INCOMING_SMS = 0x14, /**<      TONE TYPE ALERT TONE SELECTED BY USER FOR INCOMING SMS          */
+       TAPI_SAT_CRITICAL_ALERT = 0x15, /**<    TONE TYPE CRITICAL ALERT                */
 
        //Themed tones
-       TAPI_SAT_HAPPY_TONE                                             = 0x30, /**<    TONE TYPE HAPPY TONE            */
-       TAPI_SAT_SAD_TONE                                               = 0x31, /**<    TONE TYPE SAD TONE                      */
-       TAPI_SAT_URGENT_ACTION_TONE                             = 0x32, /**<    TONE TYPE URGENT ACTION TONE            */
-       TAPI_SAT_QUESTION_TONE                                  = 0x33, /**<    TONE TYPE QUESTION TONE                 */
-       TAPI_SAT_MESSAGE_RECEIVED_TONE                  = 0x34, /**<    TONE TYPE MESSAGE RECEIVED TONE                 */
+       TAPI_SAT_HAPPY_TONE = 0x30, /**<        TONE TYPE HAPPY TONE            */
+       TAPI_SAT_SAD_TONE = 0x31, /**<  TONE TYPE SAD TONE                      */
+       TAPI_SAT_URGENT_ACTION_TONE = 0x32, /**<        TONE TYPE URGENT ACTION TONE            */
+       TAPI_SAT_QUESTION_TONE = 0x33, /**<     TONE TYPE QUESTION TONE                 */
+       TAPI_SAT_MESSAGE_RECEIVED_TONE = 0x34, /**<     TONE TYPE MESSAGE RECEIVED TONE                 */
 
        //Melody tones
-       TAPI_SAT_MELODY_1               = 0x40, /**<    TONE TYPE MELODY 1              */
-       TAPI_SAT_MELODY_2               = 0x41, /**<    TONE TYPE MELODY 2              */
-       TAPI_SAT_MELODY_3               = 0x42, /**<    TONE TYPE MELODY 3              */
-       TAPI_SAT_MELODY_4               = 0x43, /**<    TONE TYPE MELODY 4              */
-       TAPI_SAT_MELODY_5               = 0x44, /**<    TONE TYPE MELODY 5              */
-       TAPI_SAT_MELODY_6               = 0x45, /**<    TONE TYPE MELODY 6              */
-       TAPI_SAT_MELODY_7               = 0x46, /**<    TONE TYPE MELODY 7              */
-       TAPI_SAT_MELODY_8               = 0x47, /**<    TONE TYPE MELODY 8              */
-
-       TAPI_SAT_TONE_TYPE_RESERVED             = 0xFF  /**<    TONE TYPE RESERVED              */
+       TAPI_SAT_MELODY_1 = 0x40, /**<  TONE TYPE MELODY 1              */
+       TAPI_SAT_MELODY_2 = 0x41, /**<  TONE TYPE MELODY 2              */
+       TAPI_SAT_MELODY_3 = 0x42, /**<  TONE TYPE MELODY 3              */
+       TAPI_SAT_MELODY_4 = 0x43, /**<  TONE TYPE MELODY 4              */
+       TAPI_SAT_MELODY_5 = 0x44, /**<  TONE TYPE MELODY 5              */
+       TAPI_SAT_MELODY_6 = 0x45, /**<  TONE TYPE MELODY 6              */
+       TAPI_SAT_MELODY_7 = 0x46, /**<  TONE TYPE MELODY 7              */
+       TAPI_SAT_MELODY_8 = 0x47, /**<  TONE TYPE MELODY 8              */
+
+       TAPI_SAT_TONE_TYPE_RESERVED = 0xFF /**< TONE TYPE RESERVED              */
 } TelSatToneType_t;
 
 /**
  * @enum TelSatEventDownloadType_t
  * This enum lists event types required by ME to monitor and report to SIM.
  */
-typedef enum
-{
-       TAPI_EVENT_SAT_DW_TYPE_MT_CALL                                                  = 0,
-       TAPI_EVENT_SAT_DW_TYPE_CALL_CONNECTED                                   = 1,
-       TAPI_EVENT_SAT_DW_TYPE_CALL_DISCONNECTED                                = 2,
-       TAPI_EVENT_SAT_DW_TYPE_LOCATION_STATUS                                  = 3,
-       TAPI_EVENT_SAT_DW_TYPE_USER_ACTIVITY                                    = 4,    /**<    data download type - USER_ACTIVITY              */
-       TAPI_EVENT_SAT_DW_TYPE_IDLE_SCREEN_AVAILABLE                    = 5,    /**<    data download type - IDLE SCREEN AVAILABLE              */      
-       TAPI_EVENT_SAT_DW_TYPE_CARD_READER_STATUS                               = 6,
-       TAPI_EVENT_SAT_DW_TYPE_LANGUAGE_SELECTION                               = 7,    /**<    data download type - LANGUAGE SELECTION         */
-       TAPI_EVENT_SAT_DW_TYPE_BROWSER_TERMINATION                              = 8,    /**<    data download type - BROWSER TERMINATION                */
-       TAPI_EVENT_SAT_DW_TYPE_DATA_AVAILABLE                                   = 9,    /**<    data download type -DATA AVAILABLE              */
-       TAPI_EVENT_SAT_DW_TYPE_CHANNEL_STATUS                                   = 0x0A, /**<    data download type - CHANNEL STATUS             */
-       TAPI_EVENT_SAT_DW_TYPE_ACCESS_TECHNOLOGY_CHANGED                = 0x0B,
-       TAPI_EVENT_SAT_DW_TYPE_DISPLAY_PARAMETERS_CHANGED               = 0x0C,
-       TAPI_EVENT_SAT_DW_TYPE_LOCAL_CONNECTION                                 = 0x0D,
-       TAPI_EVENT_SAT_DW_TYPE_NW_SEARCH_MODE_CHANGED                   = 0X0E,
-       TAPI_EVENT_SAT_DW_TYPE_BROWSING_STATUS                                  = 0X0F,
-       TAPI_EVENT_SAT_DW_TYPE_FRAMES_INFORMATION_CHANGED               = 0X10,
-       TAPI_EVENT_SAT_DW_TYPE_RESERVED_FOR_3GPP                                = 0X11,
-       TAPI_EVENT_SAT_DW_TYPE_UNKNOWN                                                  = 0xFF  /**<    data download type - unknown            */
+typedef enum {
+       TAPI_EVENT_SAT_DW_TYPE_MT_CALL = 0,
+       TAPI_EVENT_SAT_DW_TYPE_CALL_CONNECTED = 1,
+       TAPI_EVENT_SAT_DW_TYPE_CALL_DISCONNECTED = 2,
+       TAPI_EVENT_SAT_DW_TYPE_LOCATION_STATUS = 3,
+       TAPI_EVENT_SAT_DW_TYPE_USER_ACTIVITY = 4, /**<  data download type - USER_ACTIVITY              */
+       TAPI_EVENT_SAT_DW_TYPE_IDLE_SCREEN_AVAILABLE = 5, /**<  data download type - IDLE SCREEN AVAILABLE              */
+       TAPI_EVENT_SAT_DW_TYPE_CARD_READER_STATUS = 6,
+       TAPI_EVENT_SAT_DW_TYPE_LANGUAGE_SELECTION = 7, /**<     data download type - LANGUAGE SELECTION         */
+       TAPI_EVENT_SAT_DW_TYPE_BROWSER_TERMINATION = 8, /**<    data download type - BROWSER TERMINATION                */
+       TAPI_EVENT_SAT_DW_TYPE_DATA_AVAILABLE = 9, /**< data download type -DATA AVAILABLE              */
+       TAPI_EVENT_SAT_DW_TYPE_CHANNEL_STATUS = 0x0A, /**<      data download type - CHANNEL STATUS             */
+       TAPI_EVENT_SAT_DW_TYPE_ACCESS_TECHNOLOGY_CHANGED = 0x0B,
+       TAPI_EVENT_SAT_DW_TYPE_DISPLAY_PARAMETERS_CHANGED = 0x0C,
+       TAPI_EVENT_SAT_DW_TYPE_LOCAL_CONNECTION = 0x0D,
+       TAPI_EVENT_SAT_DW_TYPE_NW_SEARCH_MODE_CHANGED = 0X0E,
+       TAPI_EVENT_SAT_DW_TYPE_BROWSING_STATUS = 0X0F,
+       TAPI_EVENT_SAT_DW_TYPE_FRAMES_INFORMATION_CHANGED = 0X10,
+       TAPI_EVENT_SAT_DW_TYPE_RESERVED_FOR_3GPP = 0X11,
+       TAPI_EVENT_SAT_DW_TYPE_UNKNOWN = 0xFF /**<      data download type - unknown            */
 } TelSatEventDownloadType_t;
 
 /**
  * @enum TelSatImageCodingSchemeType_t
  * This enum lists image coding scheme types required by ME to show.
  */
-typedef enum
-{
-       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_BASIC          = 0x11, /**<    IMAGE CODING SCHEME BASIC               */
-       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_COLOUR         = 0x21, /**<    IMAGE CODING SCHEME COLOUR              */
-       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_RESERVED       = 0xFF  /**<       RESERVED             */
-
+typedef enum {
+       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_BASIC = 0x11, /**<     IMAGE CODING SCHEME BASIC               */
+       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_COLOUR = 0x21, /**<    IMAGE CODING SCHEME COLOUR              */
+       TAPI_SAT_SIM_IMAGE_CODING_SCHEME_RESERVED = 0xFF /**<      RESERVED             */
 } TelSatImageCodingSchemeType_t;
 
 /**
  * @enum TelSatIconQualifierType_t
  * This enum defines the icon qualifier.
  */
-typedef enum
-{
-       TAPI_SAT_ICON_QUALI_SELF_EXPLANATORY            = 0,            /**<    ICON QUALI SELF EXPLANATORY     */
-       TAPI_SAT_ICON_QUALI_NOT_SELF_EXPLANATORY        = 1,            /**<    ICON QUALI NOT SELF EXPLANATORY         */
-       TAPI_SAT_ICON_QUALI_RESERVED                            = 0xFF          /**<      RESERVED      */
-
+typedef enum {
+       TAPI_SAT_ICON_QUALI_SELF_EXPLANATORY = 0, /**<  ICON QUALI SELF EXPLANATORY     */
+       TAPI_SAT_ICON_QUALI_NOT_SELF_EXPLANATORY = 1, /**<      ICON QUALI NOT SELF EXPLANATORY         */
+       TAPI_SAT_ICON_QUALI_RESERVED = 0xFF /**<          RESERVED      */
 } TelSatIconQualifierType_t;
 
 /**
  * @enum TelSatBcRepeatIndicatorType_t
  * This enum defines the SIM ATK BC repeat indicator type.
  */
-typedef enum
-{
-       TAPI_SAT_BC_REPEAT_INDI_ALTERNATE_MODE  = 0x01, /**<    BC REPEAT ALTERNATE MODE                */
-       TAPI_SAT_BC_REPEAT_INDI_SEQUENTIAL_MODE = 0x03, /**<    BC REPEAT SEQUENTIAL MODE               */
-       TAPI_SAT_BC_REPEAT_INDI_RESERVED                = 0xFF  /**<    RESERVED        */
-
+typedef enum {
+       TAPI_SAT_BC_REPEAT_INDI_ALTERNATE_MODE = 0x01, /**<     BC REPEAT ALTERNATE MODE                */
+       TAPI_SAT_BC_REPEAT_INDI_SEQUENTIAL_MODE = 0x03, /**<    BC REPEAT SEQUENTIAL MODE               */
+       TAPI_SAT_BC_REPEAT_INDI_RESERVED = 0xFF /**<    RESERVED        */
 } TelSatBcRepeatIndicatorType_t;
 
 /**
  * @enum TelSatCallCtrlStringType_t
  * This enum defines call control string type.
  */
-typedef enum
-{
-       TAPI_SAT_CC_VOICE                        = 0x00,        /**<    Call Control String Type - voice                */
-       TAPI_SAT_CC_SS                           = 0x01,        /**<    Call Control String Type - ss           */
-       TAPI_SAT_CC_USSD                         = 0x02,        /**<    Call Control String Type - ussd         */
-       TAPI_SAT_CC_NONE                     = 0xFF             /**<    Call Control String Type - none                 */
-}TelSatCallCtrlStringType_t;
+typedef enum {
+       TAPI_SAT_CC_VOICE = 0x00, /**<  Call Control String Type - voice                */
+       TAPI_SAT_CC_SS = 0x01, /**<     Call Control String Type - ss           */
+       TAPI_SAT_CC_USSD = 0x02, /**<   Call Control String Type - ussd         */
+       TAPI_SAT_CC_NONE = 0xFF /**<    Call Control String Type - none                 */
+} TelSatCallCtrlStringType_t;
 
 /**
  * @enum TelSatLanguageType_t
  * This enum lists the language values.
  */
-typedef enum
-{
-       TAPI_SAT_LP_GERMAN                              = 0x00, /**<    GERMAN          */
-       TAPI_SAT_LP_ENGLISH                             = 0x01, /**<    ENGLISH         */
-       TAPI_SAT_LP_ITALIAN                             = 0x02, /**<    ITALIAN         */
-       TAPI_SAT_LP_FRENCH                              = 0x03, /**<    FRENCH          */
-       TAPI_SAT_LP_SPANISH                             = 0x04, /**<    SPANISH         */
-       TAPI_SAT_LP_DUTCH                               = 0x05, /**<    DUTCH           */
-       TAPI_SAT_LP_SWEDISH                             = 0x06, /**<    SWEDISH */
-       TAPI_SAT_LP_DANISH                              = 0x07, /**<    DANISH  */
-       TAPI_SAT_LP_PORTUGUESE                  = 0x08, /**<    PORTUGUESE      */
-       TAPI_SAT_LP_FINNISH                             = 0x09, /**<    FINNISH */
-       TAPI_SAT_LP_NORWEGIAN                   = 0x0A, /**<    NORWEGIAN       */
-       TAPI_SAT_LP_GREEK                               = 0x0B, /**<    GREEK   */
-       TAPI_SAT_LP_TURKISH                             = 0x0C, /**<    TURKISH */
-       TAPI_SAT_LP_HUNGARIAN                   = 0x0D, /**<    HUNGARIAN       */
-       TAPI_SAT_LP_POLISH                              = 0x0E, /**<    POLISH  */
-       TAPI_SAT_LP_LANG_UNSPECIFIED    = 0x0F  /**<    LANGUAGE UNSPECIFIED    */
-}TelSatLanguageType_t;
+typedef enum {
+       TAPI_SAT_LP_GERMAN = 0x00, /**< GERMAN          */
+       TAPI_SAT_LP_ENGLISH = 0x01, /**<        ENGLISH         */
+       TAPI_SAT_LP_ITALIAN = 0x02, /**<        ITALIAN         */
+       TAPI_SAT_LP_FRENCH = 0x03, /**< FRENCH          */
+       TAPI_SAT_LP_SPANISH = 0x04, /**<        SPANISH         */
+       TAPI_SAT_LP_DUTCH = 0x05, /**<  DUTCH           */
+       TAPI_SAT_LP_SWEDISH = 0x06, /**<        SWEDISH */
+       TAPI_SAT_LP_DANISH = 0x07, /**< DANISH  */
+       TAPI_SAT_LP_PORTUGUESE = 0x08, /**<     PORTUGUESE      */
+       TAPI_SAT_LP_FINNISH = 0x09, /**<        FINNISH */
+       TAPI_SAT_LP_NORWEGIAN = 0x0A, /**<      NORWEGIAN       */
+       TAPI_SAT_LP_GREEK = 0x0B, /**<  GREEK   */
+       TAPI_SAT_LP_TURKISH = 0x0C, /**<        TURKISH */
+       TAPI_SAT_LP_HUNGARIAN = 0x0D, /**<      HUNGARIAN       */
+       TAPI_SAT_LP_POLISH = 0x0E, /**< POLISH  */
+       TAPI_SAT_LP_LANG_UNSPECIFIED = 0x0F /**<        LANGUAGE UNSPECIFIED    */
+} TelSatLanguageType_t;
 
 /**
  * @enum TelSatBrowserIdentityType_t
  * This enum lists the SAT browser identity type.
  */
-typedef enum
-{
-       TAPI_SAT_BROWSER_ID_DEFAULT                     = 0x0,  /**<    DEFAULT BROWSER                 */
-       TAPI_SAT_BROWSER_ID_WML,                                        /**<    BROWSER WML     */
-       TAPI_SAT_BROWSER_ID_HTML,                                       /**<    BROWSER HTML    */
-       TAPI_SAT_BROWSER_ID_XHTML,                                      /**<    BROWSER XHTML   */
-       TAPI_SAT_BROWSER_ID_CHTML,                                      /**<    BROWSER CHTML   */
-       TAPI_SAT_BROWSER_ID_RESERVED            = 0xFF  /**<    RESERVED        */
+typedef enum {
+       TAPI_SAT_BROWSER_ID_DEFAULT = 0x0, /**< DEFAULT BROWSER                 */
+       TAPI_SAT_BROWSER_ID_WML, /**<   BROWSER WML     */
+       TAPI_SAT_BROWSER_ID_HTML, /**<  BROWSER HTML    */
+       TAPI_SAT_BROWSER_ID_XHTML, /**< BROWSER XHTML   */
+       TAPI_SAT_BROWSER_ID_CHTML, /**< BROWSER CHTML   */
+       TAPI_SAT_BROWSER_ID_RESERVED = 0xFF /**<        RESERVED        */
 } TelSatBrowserIdentityType_t;
 
 /**
  * @enum TelSatBearerType_t
  * This enum lists the SAT bearer type.
  */
-typedef enum
-{
-       TAPI_SAT_BEARER_TYPE_SMS                        = 0x0,  /**<    BEARER SMS              */
-       TAPI_SAT_BEARER_TYPE_CSD                        = 0x1,  /**<    BEARER CSD              */
-       TAPI_SAT_BEARER_TYPE_USSD                       = 0x2,  /**<    BEARER USSD             */
-       TAPI_SAT_BEARER_TYPE_GPRS                       = 0x3,  /**<    BEARER GPRS             */
-       TAPI_SAT_BEARER_TYPE_RESERVED           = 0xFF  /**<    BEARER RESERVED         */
-
+typedef enum {
+       TAPI_SAT_BEARER_TYPE_SMS = 0x0, /**<    BEARER SMS              */
+       TAPI_SAT_BEARER_TYPE_CSD = 0x1, /**<    BEARER CSD              */
+       TAPI_SAT_BEARER_TYPE_USSD = 0x2, /**<   BEARER USSD             */
+       TAPI_SAT_BEARER_TYPE_GPRS = 0x3, /**<   BEARER GPRS             */
+       TAPI_SAT_BEARER_TYPE_RESERVED = 0xFF /**<       BEARER RESERVED         */
 } TelSatBearerType_t;
 
 /**
  * @enum TelSatBrowserTerminationCauseType_t
  * This enum lists the SAT browser termination cause type.
  */
-typedef enum
-{
-       TAPI_SAT_BROWSER_TERMINATED_BY_USER                     = 0,    /**<    BROWSER TERMINATED BY USER              */
-       TAPI_SAT_BROWSER_TERMINATED_BY_ERROR        = 1,        /**<    BROWSER TERMINATED BY ERROR             */
+typedef enum {
+       TAPI_SAT_BROWSER_TERMINATED_BY_USER = 0, /**<   BROWSER TERMINATED BY USER              */
+       TAPI_SAT_BROWSER_TERMINATED_BY_ERROR = 1, /**<  BROWSER TERMINATED BY ERROR             */
 } TelSatBrowserTerminationCauseType_t;
 
 /**
  * @enum TelSatBearerDescType_t
  * This enum lists the SAT bearer destination type.
  */
-typedef enum
-{
-       TAPI_SAT_BEARER_CSD                     = 0x1,  /**<    BEARER DESC CSD                 */
-       TAPI_SAT_BEARER_GPRS            = 0x2,  /**<    BEARER DESC GPRS                */
-       TAPI_SAT_BEARER_DEFAULT_BEARER_FROM_TRANSPORT_LAYER     = 0x3,  /**<    BEARER DESC DEFAULT BEARER FROM TRANSPORT LAYER         */
-       TAPI_SAT_BEARER_LOCAL_LINK_TECHNOLOGY_INDEPENDENT       = 0x4,  /**<    BEARER DESC LOCAL LINK TECHNOLOGY INDEPENDENT           */
-       TAPI_SAT_BEARER_BLUETOOTH   = 0x5,      /**<    BEARER DESC BLUETOOTH   */
-       TAPI_SAT_BEARER_IrDA            = 0x6,  /**<    BEARER DESC IrDA        */
-       TAPI_SAT_BEARER_RS232           = 0x7,  /**<    BEARER DESC RS232       */
-       TAPI_SAT_BEARER_USB             = 0x10, /**<    BEARER DESC USB */
-       TAPI_SAT_BEARER_RESERVED        = 0xFF  /**<    RESERVED        */
+typedef enum {
+       TAPI_SAT_BEARER_CSD = 0x1, /**< BEARER DESC CSD                 */
+       TAPI_SAT_BEARER_GPRS = 0x2, /**<        BEARER DESC GPRS                */
+       TAPI_SAT_BEARER_DEFAULT_BEARER_FROM_TRANSPORT_LAYER = 0x3, /**< BEARER DESC DEFAULT BEARER FROM TRANSPORT LAYER         */
+       TAPI_SAT_BEARER_LOCAL_LINK_TECHNOLOGY_INDEPENDENT = 0x4, /**<   BEARER DESC LOCAL LINK TECHNOLOGY INDEPENDENT           */
+       TAPI_SAT_BEARER_BLUETOOTH = 0x5, /**<   BEARER DESC BLUETOOTH   */
+       TAPI_SAT_BEARER_IrDA = 0x6, /**<        BEARER DESC IrDA        */
+       TAPI_SAT_BEARER_RS232 = 0x7, /**<       BEARER DESC RS232       */
+       TAPI_SAT_BEARER_USB = 0x10, /**<        BEARER DESC USB */
+       TAPI_SAT_BEARER_RESERVED = 0xFF /**<    RESERVED        */
 } TelSatBearerDescType_t;
 
-
 /**
  * @enum TelSatBearerParamCsdDataRateType_t
  * This enum lists the SAT bearer parameter csd data rate. refer TS 27.007
  */
-typedef enum
-{
-       TAPI_SAT_BIP_DR_AUTOBAUDING             = 0,    /**<    CSD data rate - AUTOBAUDING             */
-       TAPI_SAT_BIP_DR_300BPS_V21                      = 1,    /**<    CSD data rate -300BPS V21               */
-       TAPI_SAT_BIP_DR_1200BPS_V22                     = 2,    /**<    CSD data rate - 1200BPS V22             */
-       TAPI_SAT_BIP_DR_1200_75BPS_V23          = 3,    /**<    CSD data rate -1200 75BPS V23                   */
-       TAPI_SAT_BIP_DR_2400BPS_V22                     = 4,    /**<    CSD data rate -2400BPS V22              */
-       TAPI_SAT_BIP_DR_2400BPS_V26                     = 5,    /**<    CSD data rate - 2400BPS V26                     */
-       TAPI_SAT_BIP_DR_4800BPS_V32             = 6,    /**<    CSD data rate - 4800BPS V32             */
-       TAPI_SAT_BIP_DR_9600BPS_V32             = 7,    /**<    CSD data rate - 9600BPS V32             */
-       TAPI_SAT_BIP_DR_9600BPS_V34             = 12,   /**<    CSD data rate - 9600BPS_V34             */
-       TAPI_SAT_BIP_DR_14400BPS_V34            = 14,   /**<    CSD data rate -14400BPS V34             */
-       TAPI_SAT_BIP_DR_19200BPS_V34            = 15,   /**<    CSD data rate -19200BPS V34             */
-       TAPI_SAT_BIP_DR_28800BPS_V34            = 16,   /**<    CSD data rate -28800BPS V34             */
-       TAPI_SAT_BIP_DR_33600BPS_V34            = 17,   /**<    CSD data rate -33600BPS V34             */
-       TAPI_SAT_BIP_DR_1200BPS_V120            = 34,   /**<    CSD data rate -1200BPS V120             */
-       TAPI_SAT_BIP_DR_2400BPS_V120            = 36,   /**<    CSD data rate -2400BPS V120             */
-       TAPI_SAT_BIP_DR_4800BPS_V120            = 38,   /**<    CSD data rate -4800BPS V120             */
-       TAPI_SAT_BIP_DR_9600BPS_V120            = 39,   /**<    CSD data rate -9600BPS V120             */
-       TAPI_SAT_BIP_DR_14400BPS_V120           = 43,   /**<    CSD data rate -14400BPS V120            */
-       TAPI_SAT_BIP_DR_19200BPS_V120           = 47,   /**<    CSD data rate -19200BPS V120            */
-       TAPI_SAT_BIP_DR_28800BPS_V120           = 48,   /**<    CSD data rate -28800BPS V120            */
-       TAPI_SAT_BIP_DR_38400BPS_V120           = 49,   /**<    CSD data rate -38400BPS V120            */
-       TAPI_SAT_BIP_DR_48000BPS_V120           = 50,   /**<    CSD data rate -48000BPS V120            */
-       TAPI_SAT_BIP_DR_56000BPS_V120           = 51,   /**<    CSD data rate -56000BPS V120            */
-       TAPI_SAT_BIP_DR_300BPS_V110             = 65,   /**<    CSD data rate - 300BPS V110             */
-       TAPI_SAT_BIP_DR_1200BPS_V110            = 66,   /**<    CSD data rate -1200BPS V110             */
-       TAPI_SAT_BIP_DR_2400BPS_V110_OR_X31_FALG_STUFFING       = 68,   /**<    CSD data rate - 2400BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_4800BPS_V110_OR_X31_FALG_STUFFING       = 70,   /**<    CSD data rate - 4800BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_9600BPS_V110_OR_X31_FALG_STUFFING       = 71,   /**<    CSD data rate - 9600BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_14400BPS_V110_OR_X31_FALG_STUFFING  = 75,       /**<    CSD data rate - 14400BPS V110 OR X31 FALG STUFFING              */
-       TAPI_SAT_BIP_DR_19200BPS_V110_OR_X31_FALG_STUFFING  = 79,       /**<    CSD data rate -19200BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_28800BPS_V110_OR_X31_FALG_STUFFING  = 80,       /**<    CSD data rate -28800BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_38400BPS_V110_OR_X31_FALG_STUFFING  = 81,       /**<    CSD data rate -38400BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_48000BPS_V110_OR_X31_FALG_STUFFING  = 82,       /**<    CSD data rate -48000BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_56000BPS_V110_OR_X31_FALG_STUFFING  = 83,       /**<    CSD data rate -56000BPS V110 OR X31 FALG STUFFING               */
-       TAPI_SAT_BIP_DR_64000BPS                                        = 84,   /**<    CSD data rate -64000BPS                 */
-       TAPI_SAT_BIP_DR_56000BPS_BIT_TRANSPERENT        = 115,  /**<    CSD data rate -56000BPS BIT TRANSPERENT                 */
-       TAPI_SAT_BIP_DR_64000BPS_BIT_TRANSPERENT        = 116,  /**<    CSD data rate -64000BPS BIT TRANSPERENT                 */
-       TAPI_SAT_BIP_DR_32000BPS_PIAFS32K                       = 120,  /**<    CSD data rate -32000BPS PIAFS32K                */
-       TAPI_SAT_BIP_DR_64000BPS_PIAFS64K                       = 121,  /**<    CSD data rate - 64000BPS PIAFS64K               */
-       TAPI_SAT_BIP_DR_28800BPS_MULTIMEDIA                     = 130,  /**<    CSD data rate -28800BPS MULTIMEDIA              */
-       TAPI_SAT_BIP_DR_32000BPS_MULTIMEDIA                     = 131,  /**<    CSD data rate -32000BPS MULTIMEDIA              */
-       TAPI_SAT_BIP_DR_33600BPS_MULTIMEDIA                     = 132,  /**<    CSD data rate - 33600BPS MULTIMEDIA             */
-       TAPI_SAT_BIP_DR_56000BPS_MULTIMEDIA                     = 133,  /**<    CSD data rate -56000BPS MULTIMEDIA              */
-       TAPI_SAT_BIP_DR_64000BPS_MULTIMEDIA                     = 134   /**<    CSD data rate -64000BPS MULTIMEDIA              */
-
-}TelSatBearerParamCsdDataRateType_t;
+typedef enum {
+       TAPI_SAT_BIP_DR_AUTOBAUDING = 0, /**<   CSD data rate - AUTOBAUDING             */
+       TAPI_SAT_BIP_DR_300BPS_V21 = 1, /**<    CSD data rate -300BPS V21               */
+       TAPI_SAT_BIP_DR_1200BPS_V22 = 2, /**<   CSD data rate - 1200BPS V22             */
+       TAPI_SAT_BIP_DR_1200_75BPS_V23 = 3, /**<        CSD data rate -1200 75BPS V23                   */
+       TAPI_SAT_BIP_DR_2400BPS_V22 = 4, /**<   CSD data rate -2400BPS V22              */
+       TAPI_SAT_BIP_DR_2400BPS_V26 = 5, /**<   CSD data rate - 2400BPS V26                     */
+       TAPI_SAT_BIP_DR_4800BPS_V32 = 6, /**<   CSD data rate - 4800BPS V32             */
+       TAPI_SAT_BIP_DR_9600BPS_V32 = 7, /**<   CSD data rate - 9600BPS V32             */
+       TAPI_SAT_BIP_DR_9600BPS_V34 = 12, /**<  CSD data rate - 9600BPS_V34             */
+       TAPI_SAT_BIP_DR_14400BPS_V34 = 14, /**< CSD data rate -14400BPS V34             */
+       TAPI_SAT_BIP_DR_19200BPS_V34 = 15, /**< CSD data rate -19200BPS V34             */
+       TAPI_SAT_BIP_DR_28800BPS_V34 = 16, /**< CSD data rate -28800BPS V34             */
+       TAPI_SAT_BIP_DR_33600BPS_V34 = 17, /**< CSD data rate -33600BPS V34             */
+       TAPI_SAT_BIP_DR_1200BPS_V120 = 34, /**< CSD data rate -1200BPS V120             */
+       TAPI_SAT_BIP_DR_2400BPS_V120 = 36, /**< CSD data rate -2400BPS V120             */
+       TAPI_SAT_BIP_DR_4800BPS_V120 = 38, /**< CSD data rate -4800BPS V120             */
+       TAPI_SAT_BIP_DR_9600BPS_V120 = 39, /**< CSD data rate -9600BPS V120             */
+       TAPI_SAT_BIP_DR_14400BPS_V120 = 43, /**<        CSD data rate -14400BPS V120            */
+       TAPI_SAT_BIP_DR_19200BPS_V120 = 47, /**<        CSD data rate -19200BPS V120            */
+       TAPI_SAT_BIP_DR_28800BPS_V120 = 48, /**<        CSD data rate -28800BPS V120            */
+       TAPI_SAT_BIP_DR_38400BPS_V120 = 49, /**<        CSD data rate -38400BPS V120            */
+       TAPI_SAT_BIP_DR_48000BPS_V120 = 50, /**<        CSD data rate -48000BPS V120            */
+       TAPI_SAT_BIP_DR_56000BPS_V120 = 51, /**<        CSD data rate -56000BPS V120            */
+       TAPI_SAT_BIP_DR_300BPS_V110 = 65, /**<  CSD data rate - 300BPS V110             */
+       TAPI_SAT_BIP_DR_1200BPS_V110 = 66, /**< CSD data rate -1200BPS V110             */
+       TAPI_SAT_BIP_DR_2400BPS_V110_OR_X31_FALG_STUFFING = 68, /**<    CSD data rate - 2400BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_4800BPS_V110_OR_X31_FALG_STUFFING = 70, /**<    CSD data rate - 4800BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_9600BPS_V110_OR_X31_FALG_STUFFING = 71, /**<    CSD data rate - 9600BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_14400BPS_V110_OR_X31_FALG_STUFFING = 75, /**<   CSD data rate - 14400BPS V110 OR X31 FALG STUFFING              */
+       TAPI_SAT_BIP_DR_19200BPS_V110_OR_X31_FALG_STUFFING = 79, /**<   CSD data rate -19200BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_28800BPS_V110_OR_X31_FALG_STUFFING = 80, /**<   CSD data rate -28800BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_38400BPS_V110_OR_X31_FALG_STUFFING = 81, /**<   CSD data rate -38400BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_48000BPS_V110_OR_X31_FALG_STUFFING = 82, /**<   CSD data rate -48000BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_56000BPS_V110_OR_X31_FALG_STUFFING = 83, /**<   CSD data rate -56000BPS V110 OR X31 FALG STUFFING               */
+       TAPI_SAT_BIP_DR_64000BPS = 84, /**<     CSD data rate -64000BPS                 */
+       TAPI_SAT_BIP_DR_56000BPS_BIT_TRANSPERENT = 115, /**<    CSD data rate -56000BPS BIT TRANSPERENT                 */
+       TAPI_SAT_BIP_DR_64000BPS_BIT_TRANSPERENT = 116, /**<    CSD data rate -64000BPS BIT TRANSPERENT                 */
+       TAPI_SAT_BIP_DR_32000BPS_PIAFS32K = 120, /**<   CSD data rate -32000BPS PIAFS32K                */
+       TAPI_SAT_BIP_DR_64000BPS_PIAFS64K = 121, /**<   CSD data rate - 64000BPS PIAFS64K               */
+       TAPI_SAT_BIP_DR_28800BPS_MULTIMEDIA = 130, /**< CSD data rate -28800BPS MULTIMEDIA              */
+       TAPI_SAT_BIP_DR_32000BPS_MULTIMEDIA = 131, /**< CSD data rate -32000BPS MULTIMEDIA              */
+       TAPI_SAT_BIP_DR_33600BPS_MULTIMEDIA = 132, /**< CSD data rate - 33600BPS MULTIMEDIA             */
+       TAPI_SAT_BIP_DR_56000BPS_MULTIMEDIA = 133, /**< CSD data rate -56000BPS MULTIMEDIA              */
+       TAPI_SAT_BIP_DR_64000BPS_MULTIMEDIA = 134 /**<  CSD data rate -64000BPS MULTIMEDIA              */
+} TelSatBearerParamCsdDataRateType_t;
 
 /**
  * @enum TelSatBearerParamCsdBearerServiceType_t
  * This enum lists the SAT bearer parameter csd bearer service
  */
-typedef enum
-{
-       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_ASYNC_UDI      =0,     /**<    CSD Bearer service - DATA CIRCUIT ASYNCHRONOUS UDI              */
-       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_SYNC           =1,     /**<    CSD Bearer service - DATA CIRCUIT SYNCHRONOUS UDI               */
-       TAPI_SAT_BIP_CSD_BS_PAD_ACCESS_ASYNC_UDI        =2,     /**<    CSD Bearer service - PAD ACCESS ASYNCHRONOUS UDI                        */
-       TAPI_SAT_BIP_CSD_BS_PACKET_ACCESS_SYNC          =3,     /**<    CSD Bearer service - PACKET ACCESS SYNCHRONOUS UDI              */
-       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_ASYNC_RDI      =4,     /**<    CSD Bearer service - DATA CIRCUIT ASYNCHRONOUS RDI              */
-       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_SYNC_RDI       =5,     /**<    CSD Bearer service - DATA CIRCUIT SYNCHRONOUS RDI               */
-       TAPI_SAT_BIP_CSD_BS_PAD_ACCESS_ASYNC_RDI        =6,     /**<    CSD Bearer service - PAD ACCESS ASYNCHRONOUS RDI                */
-       TAPI_SAT_BIP_CSD_BS_PACKET_ACCESS_SYNC_RDI      =7      /**<    CSD Bearer service - PACKET ACCESS SYNCHRONOUS RDI              */
-
-}TelSatBearerParamCsdBearerServiceType_t;
+typedef enum {
+       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_ASYNC_UDI = 0, /**<    CSD Bearer service - DATA CIRCUIT ASYNCHRONOUS UDI              */
+       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_SYNC = 1, /**< CSD Bearer service - DATA CIRCUIT SYNCHRONOUS UDI               */
+       TAPI_SAT_BIP_CSD_BS_PAD_ACCESS_ASYNC_UDI = 2, /**<      CSD Bearer service - PAD ACCESS ASYNCHRONOUS UDI                        */
+       TAPI_SAT_BIP_CSD_BS_PACKET_ACCESS_SYNC = 3, /**<        CSD Bearer service - PACKET ACCESS SYNCHRONOUS UDI              */
+       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_ASYNC_RDI = 4, /**<    CSD Bearer service - DATA CIRCUIT ASYNCHRONOUS RDI              */
+       TAPI_SAT_BIP_CSD_BS_DATA_CIRCUIT_SYNC_RDI = 5, /**<     CSD Bearer service - DATA CIRCUIT SYNCHRONOUS RDI               */
+       TAPI_SAT_BIP_CSD_BS_PAD_ACCESS_ASYNC_RDI = 6, /**<      CSD Bearer service - PAD ACCESS ASYNCHRONOUS RDI                */
+       TAPI_SAT_BIP_CSD_BS_PACKET_ACCESS_SYNC_RDI = 7 /**<     CSD Bearer service - PACKET ACCESS SYNCHRONOUS RDI              */
+} TelSatBearerParamCsdBearerServiceType_t;
 
 /**
  * @enum TelSatBearerParamCsdConnectionElementType_t
  * This enum lists the SAT bearer parameter csd connection element
  */
-typedef enum
-{
-       TAPI_SAT_BIP_CSD_CONN_ELEM_TRANSPARENT                                  = 0,    /**<    CSD connection element - TRANSPARENT            */
-       TAPI_SAT_BIP_CSD_CONN_ELEM_NON_TRANSPARENT                              = 1,    /**<    CSD connection element - NON TRANSPARENT                */
-       TAPI_SAT_BIP_CSD_CONN_ELEM_BOTH_TRANSPARENT_PREF                = 2,    /**<    CSD connection element -BOTH TRANSPARENT PREFFERED              */
-       TAPI_SAT_BIP_CSD_CONN_ELEM_BOTH_NON_TRANSPARENT_PREF    = 3             /**<    CSD connection element -  NON TRANSPARENT PREFFERED             */
-
-}TelSatBearerParamCsdConnectionElementType_t;
+typedef enum {
+       TAPI_SAT_BIP_CSD_CONN_ELEM_TRANSPARENT = 0, /**<        CSD connection element - TRANSPARENT            */
+       TAPI_SAT_BIP_CSD_CONN_ELEM_NON_TRANSPARENT = 1, /**<    CSD connection element - NON TRANSPARENT                */
+       TAPI_SAT_BIP_CSD_CONN_ELEM_BOTH_TRANSPARENT_PREF = 2, /**<      CSD connection element -BOTH TRANSPARENT PREFFERED              */
+       TAPI_SAT_BIP_CSD_CONN_ELEM_BOTH_NON_TRANSPARENT_PREF = 3 /**<   CSD connection element -  NON TRANSPARENT PREFFERED             */
+} TelSatBearerParamCsdConnectionElementType_t;
 
 /**
  * @enum TelSatBearerParamGprsPrecedenceClassType_t
  * This enum lists the SAT bearer parameter GPRS precedence class. refer  TS 23.107
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_PRECED_CLASS_HIGH_PRIORITY = 0x01,    /**<    GPRS precedence class -HIGH PRIORITY            */
-       TAPI_SAT_BIP_GPRS_PRECED_CLASS_NORM_PRIORITY = 0x02,    /**<    GPRS precedence class -NORM PRIORITY            */
-       TAPI_SAT_BIP_GPRS_PRECED_CLASS_LOW_PRIORITY  = 0x03             /**<    GPRS precedence class - LOW PRIORITY            */
-
-}TelSatBearerParamGprsPrecedenceClassType_t;
-
+typedef enum {
+       TAPI_SAT_BIP_GPRS_PRECED_CLASS_HIGH_PRIORITY = 0x01, /**<       GPRS precedence class -HIGH PRIORITY            */
+       TAPI_SAT_BIP_GPRS_PRECED_CLASS_NORM_PRIORITY = 0x02, /**<       GPRS precedence class -NORM PRIORITY            */
+       TAPI_SAT_BIP_GPRS_PRECED_CLASS_LOW_PRIORITY = 0x03 /**< GPRS precedence class - LOW PRIORITY            */
+} TelSatBearerParamGprsPrecedenceClassType_t;
 
 /**
  * @enum TelSatBearerParamGprsDelayClassType_t
  * This enum lists the SAT bearer parameter GPRS delay class.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_DELAY_CLASS_1 = 0x01, /**<    GPRS delay class - 1            */
-       TAPI_SAT_BIP_GPRS_DELAY_CLASS_2 = 0x02, /**<    GPRS delay class -      2       */
-       TAPI_SAT_BIP_GPRS_DELAY_CLASS_3 = 0x03, /**<    GPRS delay class -      3       */
-       TAPI_SAT_BIP_GPRS_DELAY_CLASS_4 = 0x04  /**<    GPRS delay class - 4            */
-
-}TelSatBearerParamGprsDelayClassType_t;
-
+typedef enum {
+       TAPI_SAT_BIP_GPRS_DELAY_CLASS_1 = 0x01, /**<    GPRS delay class - 1            */
+       TAPI_SAT_BIP_GPRS_DELAY_CLASS_2 = 0x02, /**<    GPRS delay class -      2       */
+       TAPI_SAT_BIP_GPRS_DELAY_CLASS_3 = 0x03, /**<    GPRS delay class -      3       */
+       TAPI_SAT_BIP_GPRS_DELAY_CLASS_4 = 0x04 /**<     GPRS delay class - 4            */
+} TelSatBearerParamGprsDelayClassType_t;
 
 /**
  * @enum TelSatBearerParamGprsReliabilityClassType_t
  * This enum lists the SAT bearer parameter GPRS Reliability class.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_1   = 0x01, /**<    GPRS Reliability class -1               */
-       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_2   = 0x02, /**<    GPRS Reliability class -2               */
-       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_3   = 0x03, /**<    GPRS Reliability class -3               */
-       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_4   = 0x04, /**<    GPRS Reliability class -4               */
-       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_5   = 0x05  /**<    GPRS Reliability class -5               */
-
-}TelSatBearerParamGprsReliabilityClassType_t;
-
+typedef enum {
+       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_1 = 0x01, /**<      GPRS Reliability class -1               */
+       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_2 = 0x02, /**<      GPRS Reliability class -2               */
+       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_3 = 0x03, /**<      GPRS Reliability class -3               */
+       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_4 = 0x04, /**<      GPRS Reliability class -4               */
+       TAPI_SAT_BIP_GPRS_RELIABILITY_CLASS_5 = 0x05 /**<       GPRS Reliability class -5               */
+} TelSatBearerParamGprsReliabilityClassType_t;
 
 /**
  * @enum TelSatBearerParamGprsPeakThroughputClassType_t
  * This enum lists the SAT bearer parameter GPRS peak throughput class.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_8KBPS          = 0x01,     /**<    GPRS peak throughput class- UPTO 8KBPS          */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_16KBPS             = 0x02, /**<    GPRS peak throughput class- UPTO 16KBPS         */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_32KBPS             = 0x03, /**<    GPRS peak throughput class-UPTO 32KBPS          */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_64KBPS             = 0x04, /**<    GPRS peak throughput class-UPTO 64KBPS          */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_128KBPS    = 0x05, /**<    GPRS peak throughput class- UPTO 128KBPS                        */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_256KBPS    = 0x06, /**<    GPRS peak throughput class- UPTO 256KBPS                        */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_512KBPS    = 0x07, /**<    GPRS peak throughput class- UPTO 512KBPS                */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_1024KBPS   = 0x08, /**<    GPRS peak throughput class-UPTO 1024KBPS                */
-       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_2048KBPS   = 0x09  /**<    GPRS peak throughput class- UPTO 2048KBPS               */
-
-}TelSatBearerParamGprsPeakThroughputClassType_t;
+typedef enum {
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_8KBPS = 0x01, /**< GPRS peak throughput class- UPTO 8KBPS          */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_16KBPS = 0x02, /**<        GPRS peak throughput class- UPTO 16KBPS         */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_32KBPS = 0x03, /**<        GPRS peak throughput class-UPTO 32KBPS          */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_64KBPS = 0x04, /**<        GPRS peak throughput class-UPTO 64KBPS          */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_128KBPS = 0x05, /**<       GPRS peak throughput class- UPTO 128KBPS                        */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_256KBPS = 0x06, /**<       GPRS peak throughput class- UPTO 256KBPS                        */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_512KBPS = 0x07, /**<       GPRS peak throughput class- UPTO 512KBPS                */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_1024KBPS = 0x08, /**<      GPRS peak throughput class-UPTO 1024KBPS                */
+       TAPI_SAT_BIP_GPRS_PEAK_THROUGHPUT_CLASS_UPTO_2048KBPS = 0x09 /**<       GPRS peak throughput class- UPTO 2048KBPS               */
+} TelSatBearerParamGprsPeakThroughputClassType_t;
 
 /**
  * @enum TelSatBearerParamGprsMeanThroughputClassType_t
  * This enum lists the SAT bearer parameter GPRS mean throughput class.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_22_BPS              = 0x01, /**<    GPRS mean throughput class - DOT 22 BPS         */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_44_BPS              = 0x02, /**<    GPRS mean throughput class - DOT 44 BPS         */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_1_DOT_11_BPS    = 0x03, /**<    GPRS mean throughput class -1 DOT 11 BPS                */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_2_BPS             = 0x04, /**<    GPRS mean throughput class -2 DOT 2 BPS         */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_4_BPS             = 0x05, /**<    GPRS mean throughput class -2 DOT 4 BPS                 */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_11_DOT_1_BPS    = 0x06, /**<    GPRS mean throughput class - 11 DOT 1 BPS               */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_22BPS                   = 0x07, /**<    GPRS mean throughput class -22BPS               */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_44BPS                   = 0x08, /**<    GPRS mean throughput class - 44BPS              */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_111BPS                  = 0x09, /**<    GPRS mean throughput class - 111BPS             */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_22_KBPS             = 0x0A, /**<    GPRS mean throughput class - DOT 22 KBPS                */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_44_KBPS             = 0x0B, /**<    GPRS mean throughput class -DOT 44 KBPS                 */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_1_DOT_11_KBPS   = 0x0C, /**<    GPRS mean throughput class -1 DOT 11 KBPS               */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_2_KBPS    = 0x0D, /**<    GPRS mean throughput class -2 DOT 2 KBPS                */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_4_DOT_4_KBPS    = 0x0E, /**<    GPRS mean throughput class - 4 DOT 4 KBPS               */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_11_DOT_1_KBPS   = 0x0F, /**<    GPRS mean throughput class -11 DOT 1 KBPS               */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_22KBPS                  = 0x10, /**<    GPRS mean throughput class - 22KBPS             */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_44KBPS                  = 0x11, /**<    GPRS mean throughput class - 44KBPS             */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_111KBPS                 = 0x12, /**<    GPRS mean throughput class -111KBPS             */
-       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_BEST_EFFORT     = 0x13  /**<    GPRS mean throughput class - BEST EFFORT                */
-
-}TelSatBearerParamGprsMeanThroughputClassType_t;
+typedef enum {
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_22_BPS = 0x01, /**< GPRS mean throughput class - DOT 22 BPS         */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_44_BPS = 0x02, /**< GPRS mean throughput class - DOT 44 BPS         */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_1_DOT_11_BPS = 0x03, /**<       GPRS mean throughput class -1 DOT 11 BPS                */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_2_BPS = 0x04, /**<        GPRS mean throughput class -2 DOT 2 BPS         */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_4_BPS = 0x05, /**<        GPRS mean throughput class -2 DOT 4 BPS                 */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_11_DOT_1_BPS = 0x06, /**<       GPRS mean throughput class - 11 DOT 1 BPS               */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_22BPS = 0x07, /**<      GPRS mean throughput class -22BPS               */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_44BPS = 0x08, /**<      GPRS mean throughput class - 44BPS              */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_111BPS = 0x09, /**<     GPRS mean throughput class - 111BPS             */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_22_KBPS = 0x0A, /**<        GPRS mean throughput class - DOT 22 KBPS                */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_DOT_44_KBPS = 0x0B, /**<        GPRS mean throughput class -DOT 44 KBPS                 */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_1_DOT_11_KBPS = 0x0C, /**<      GPRS mean throughput class -1 DOT 11 KBPS               */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_2_DOT_2_KBPS = 0x0D, /**<       GPRS mean throughput class -2 DOT 2 KBPS                */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_4_DOT_4_KBPS = 0x0E, /**<       GPRS mean throughput class - 4 DOT 4 KBPS               */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_11_DOT_1_KBPS = 0x0F, /**<      GPRS mean throughput class -11 DOT 1 KBPS               */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_22KBPS = 0x10, /**<     GPRS mean throughput class - 22KBPS             */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_44KBPS = 0x11, /**<     GPRS mean throughput class - 44KBPS             */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_111KBPS = 0x12, /**<    GPRS mean throughput class -111KBPS             */
+       TAPI_SAT_BIP_GPRS_MEAN_THROUGHPUT_CLASS_BEST_EFFORT = 0x13 /**< GPRS mean throughput class - BEST EFFORT                */
+} TelSatBearerParamGprsMeanThroughputClassType_t;
 
 /**
  * @enum TelSatBearerParamGprsPdpType_t
  * This enum lists the SAT bearer parameter GPRS pdp type.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_GPRS_PDP_TYPE_IP           = 0x02, /**<    bearer parameter GPRS pdp type - IP             */
-       TAPI_SAT_BIP_GPRS_PDP_TYPE_RESERVED = 0xff      /**<    reserved                */
-}TelSatBearerParamGprsPdpType_t;
+typedef enum {
+       TAPI_SAT_BIP_GPRS_PDP_TYPE_IP = 0x02, /**<      bearer parameter GPRS pdp type - IP             */
+       TAPI_SAT_BIP_GPRS_PDP_TYPE_RESERVED = 0xff /**< reserved                */
+} TelSatBearerParamGprsPdpType_t;
 
 /**
  * @enum TelSatBearerParamLocalLinksServiceIdentityType_t
  * This enum lists the SAT bearer parameters local links service identity.
  */
-typedef enum
-{
-       TAPI_SAT_BIP_LL_SERVICE_IDENT_VALUE_ASSIGNED_BY_USIM                    = 0x00, /**<    local links service identity - value assigned by USIM           */
-       TAPI_SAT_BIP_LL_SERVICE_IDENT_VALUE_ASSIGNED_BY_REMOTED_DEVICE  = 0xFF  /**<    local links service identity - value assigned by remote service */
-
-}TelSatBearerParamLocalLinksServiceIdentityType_t;
+typedef enum {
+       TAPI_SAT_BIP_LL_SERVICE_IDENT_VALUE_ASSIGNED_BY_USIM = 0x00, /**<       local links service identity - value assigned by USIM           */
+       TAPI_SAT_BIP_LL_SERVICE_IDENT_VALUE_ASSIGNED_BY_REMOTED_DEVICE = 0xFF /**<      local links service identity - value assigned by remote service */
+} TelSatBearerParamLocalLinksServiceIdentityType_t;
 
 /**
  * @enum TelSatChannelStatusType_t
  * This enum lists the SAT channel status type.
  */
-typedef enum
-{
-       TAPI_SAT_CS_LINK_ESTABLISHED_OR_PDP_CTX_NOT_ACTIVATED,  /**<    channel status type-CS LINK ESTABLISHED OR PDP CTX NOT ACTIVATED                */
-       TAPI_SAT_CS_LINK_ESTABLISHED_OR_PDP_CTX_ACTIVATED,              /**<    channel status type-CS LINK ESTABLISHED OR PDP CTX ACTIVATED            */
-       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_CLOSED_STATE,                  /**<    channel status type-UICC SERVER MODE TCP IN CLOSED STATE                */
-       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_LISTEN_STATE,                  /**<    channel status type-UICC SERVER MODE TCP IN LISTEN STATE                */
-       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_ESTABLISHED_STATE,             /**<    channel status type-UICC SERVER MODE TCP IN ESTABLISHED STATE           */
-       TAPI_SAT_UICC_SERVER_MODE_RESERVED                                              /**<    reserved                */
+typedef enum {
+       TAPI_SAT_CS_LINK_ESTABLISHED_OR_PDP_CTX_NOT_ACTIVATED, /**<     channel status type-CS LINK ESTABLISHED OR PDP CTX NOT ACTIVATED                */
+       TAPI_SAT_CS_LINK_ESTABLISHED_OR_PDP_CTX_ACTIVATED, /**< channel status type-CS LINK ESTABLISHED OR PDP CTX ACTIVATED            */
+       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_CLOSED_STATE, /**<     channel status type-UICC SERVER MODE TCP IN CLOSED STATE                */
+       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_LISTEN_STATE, /**<     channel status type-UICC SERVER MODE TCP IN LISTEN STATE                */
+       TAPI_SAT_UICC_SERVER_MODE_TCP_IN_ESTABLISHED_STATE, /**<        channel status type-UICC SERVER MODE TCP IN ESTABLISHED STATE           */
+       TAPI_SAT_UICC_SERVER_MODE_RESERVED /**< reserved                */
 } TelSatChannelStatusType_t;
 
 /**
  * @enum TelSatChannelStatusInfoType_t
  * This enum lists the SAT channel status info type.
  */
-typedef enum
-{
-       TAPI_SAT_CHANNEL_STATUS_NO_FURTHER_INFO_AVAILABLE = 0,  /**<    CHANNEL STATUS NO FURTHER INFO AVAILABLE                */
-       TAPI_SAT_CHANNEL_STATUS_NOT_USED                                  = 1,  /**<    CHANNEL STATUS NOT USED                 */
-       TAPI_SAT_CHANNEL_STATUS_LINK_DROPPED                      = 5   /**<    CHANNEL STATUS LINK DROPPED     */
-}TelSatChannelStatusInfoType_t;
+typedef enum {
+       TAPI_SAT_CHANNEL_STATUS_NO_FURTHER_INFO_AVAILABLE = 0, /**<     CHANNEL STATUS NO FURTHER INFO AVAILABLE                */
+       TAPI_SAT_CHANNEL_STATUS_NOT_USED = 1, /**<      CHANNEL STATUS NOT USED                 */
+       TAPI_SAT_CHANNEL_STATUS_LINK_DROPPED = 5 /**<   CHANNEL STATUS LINK DROPPED     */
+} TelSatChannelStatusInfoType_t;
 
 /**
  * @enum TelSatAddressType_t
  * This enum lists the SAT address type.
  */
-typedef enum
-{
-       TAPI_SAT_ADDR_TYPE_IPv4                                 = 0x21, /**<    address type - IPv4     */
-       TAPI_SAT_ADDR_TYPE_IPv6                                 = 0x57, /**<    address type - IPv6     */
-       TAPI_SAT_ADDR_RESERVED                                  = 0xFF  /**<    reserved                */
-
+typedef enum {
+       TAPI_SAT_ADDR_TYPE_IPv4 = 0x21, /**<    address type - IPv4     */
+       TAPI_SAT_ADDR_TYPE_IPv6 = 0x57, /**<    address type - IPv6     */
+       TAPI_SAT_ADDR_RESERVED = 0xFF /**<      reserved                */
 } TelSatAddressType_t;
 
 /**
  * @enum TelSatTransportProtocolType_t
  * This enum lists the SAT transport protocol type.
  */
-typedef enum
-{
-       TAPI_SAT_TP_TYPE_UDP_UICC_CLIENT                = 0x01, /**<    transport protocol type- UDP UICC CLIENT        */
-       TAPI_SAT_TP_TYPE_TCP_UICC_CLIENT                = 0x02, /**<    transport protocol type-TCP UICC CLIENT         */
-       TAPI_SAT_TP_TYPE_TCP_UICC_SERVER                = 0x03  /**<    transport protocol type- TCP UICC SERVER        */
+typedef enum {
+       TAPI_SAT_TP_TYPE_UDP_UICC_CLIENT = 0x01, /**<   transport protocol type- UDP UICC CLIENT        */
+       TAPI_SAT_TP_TYPE_TCP_UICC_CLIENT = 0x02, /**<   transport protocol type-TCP UICC CLIENT         */
+       TAPI_SAT_TP_TYPE_TCP_UICC_SERVER = 0x03 /**<    transport protocol type- TCP UICC SERVER        */
 } TelSatTransportProtocolType_t;
 
 /**
  * @enum TelSatRemoteEntityAddrCodingType_t
  * This enum lists the SAT remote entity address coding type.
  */
-typedef enum
-{
-       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_IEEE802_48BIT   = 0,    /**<    remote entity address coding type- IEEE802 48BIT                */
-       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_IRDA_32BIT              = 1,    /**<    remote entity address coding type- IRDA 32BIT           */
-       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_RESERVED                = 0xFF  /**<    reserved                */
+typedef enum {
+       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_IEEE802_48BIT = 0, /**< remote entity address coding type- IEEE802 48BIT                */
+       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_IRDA_32BIT = 1, /**<    remote entity address coding type- IRDA 32BIT           */
+       TAPI_SAT_REMOTE_ENTITY_ADDR_CODING_TYPE_RESERVED = 0xFF /**<    reserved                */
 } TelSatRemoteEntityAddrCodingType_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
 /**
  * This structure defines the Address data object.
  */
@@ -1011,7 +908,6 @@ typedef struct {
        TelSatUseInputAlphabetType_t alphabetType; /**< alphabet type           */
        int bIsImmediateResponseRequired;/**<   flag for checking whether immediate response required or not            */
        int bIsHelpInfoAvailable; /**<  flag for checking whether help info available or not. if FALSE, no help information available   */
-
 } TelSatCmdQualiGetInkey_t;
 
 /**
@@ -1023,7 +919,6 @@ typedef struct {
        int bIsMeEchoUserInput; /**<    flag for checking whether ME should echo user input. if FALSE, user input shall not be displayed*/
        int bIsUserInputUnpackedFormat; /**<    flag for checking whether user input is in unpacked format or not.  if FALSE, user input in SMS packed format   */
        int bIsHelpInfoAvailable; /**<  flag to verify if help info available or not. if FALSE, no help information available   */
-
 } TelSatCmdQualiGetInput_t;
 
 /**
@@ -1048,7 +943,6 @@ typedef struct {
 typedef struct {
        TelSatSelectionPreferenceType_t selectionPreference; /**<       type of selection preference            */
        int bIsHelpInfoAvailable; /**<  flag to verify help info available or not. if FALSE, no help information available      */
-
 } TelSatCmdQualiSetupMenu_t;
 
 /**
@@ -1105,7 +999,6 @@ typedef struct {
 typedef struct {
        TelSatDeviceIdentitiesTagType_t source; /**<    device identity tag for source  */
        TelSatDeviceIdentitiesTagType_t destination; /**<       device identity for destination */
-
 } TelSatDeviceIdentitiesInfo_t;
 
 /**
@@ -1114,7 +1007,6 @@ typedef struct {
 typedef struct {
        TelSatTimeUnitType_t timeUnit; /**<     time units for the duration data                */
        unsigned char timeInterval; /**<        time interval           */
-
 } TelSatDurationInfo_t;
 
 /**
@@ -1124,7 +1016,6 @@ typedef struct {
        unsigned char itemId; /**<      item identifier                 */
        unsigned char textLen; /**<     text length             */
        unsigned char text[TAPI_SAT_ITEM_TEXT_LEN_MAX + 1]; /**<        text information                */
-
 } TelSatMenuItemInfo_t;
 
 /**
@@ -1132,7 +1023,6 @@ typedef struct {
  */
 typedef struct {
        unsigned char selectedItemIdentifier; /**<      selected item identifier                */
-
 } TelSatItemIdentifierInfo_t;
 
 /**
@@ -1158,7 +1048,6 @@ typedef struct {
        TelSatSmsTpduType_t tpduType; /**<      SMS TPDU TYPE   */
        unsigned char dataLen; /**<     SMS TPDU DATA LENGTH    */
        unsigned char data[TAPI_SAT_SMS_TPDU_SMS_DATA_LEN_MAX]; /**< SMS TPDU DATA*/
-
 } TelSatSmsTpduInfo_t;
 
 /**
@@ -1313,7 +1202,6 @@ typedef struct {
 typedef struct {
        unsigned char stringLen; /**<   dtmf string lengh       */
        char dtmfTone[TAPI_SAT_DTMF_STRING_LEN_MAX]; /**<       dtmf tone data  */
-
 } TelSatDtmfStringInfo_t;
 
 /**
@@ -1363,7 +1251,6 @@ typedef struct {
  */
 typedef struct {
        char provisioningFilePath[TAPI_SAT_PROVISIONING_FILE_PATH_LEN_MAX]; /**<        provisioning file path  */
-
 } TelSatProvisioningRefInfo_t;
 
 /**
@@ -1501,11 +1388,6 @@ typedef struct {
        TelSatTextAttributeInfo_t list[TAPI_SAT_ITEM_TEXT_ATTRIBUTES_LIST_MAX_COUNT]; /**<      text attribute list info        */
 } TelSatTextAttributeListInfo_t;
 
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
@@ -1515,4 +1397,3 @@ typedef struct {
 /**
  * @}
  */
-
index b200b7f..86ad042 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 /**
-* @open
-* @ingroup             TelephonyAPI
-* @addtogroup  SAT_TAPI        SAT
-* @{
-*
-* @file TelSatProactvCmd.h
+ * @open
+ * @ingroup            TelephonyAPI
+ * @addtogroup SAT_TAPI        SAT
+ * @{
+ *
+ * @file TelSatProactvCmd.h
 
    @brief This file serves as a "C" header file defines structures for Tapi SAT Proactive commands and terminal response Services. \n
     It contains a sample set of constants, enums, structs that would be required by applications.
+ @brief This file serves as a "C" header file defines structures for Tapi SAT Proactive commands and terminal response Services. \n
+ It contains a sample set of constants, enums, structs that would be required by applications.
  */
 
 #ifndef _TEL_SAT_PROACTV_CMD_H_
 #define _TEL_SAT_PROACTV_CMD_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
+
 #include <TelSatObj.h>
 
 #ifdef __cplusplus
@@ -42,735 +40,658 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 #define TAPI_SAT_MENU_ITEM_COUNT_MAX                   40      /**<    max count of sat menu items     */
 #define TAPI_SAT_PROVISIONING_REF_MAX_COUNT            10      /**<    max count of sat provisioning reference */
 
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
 /**
  * This structure contains the data objects for DISPLAY TEXT proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;               /**<    device identities info. includes source and destination devices */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
 } TelSatMoreTimeIndInfo_t;
 
 /**
  * This structure contains the data objects for DISPLAY TEXT proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatTextTypeInfo_t                            text;                           /**<    display text info       */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       int                                                             bImmediateRespRequested;        /**<    flag for checking whether immediate response required or not    */
-       TelSatDurationInfo_t                            duration;                       /**<    duration for which text should be displayed     */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatTextTypeInfo_t text; /**< display text info       */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       int bImmediateRespRequested; /**<       flag for checking whether immediate response required or not    */
+       TelSatDurationInfo_t duration; /**<     duration for which text should be displayed     */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatDisplayTextIndInfo_t;
 
 /**
  * This structure contains the data objects for GET INKEY proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;   /**<        device identities info. includes source and destination devices */
-       TelSatTextTypeInfo_t                            text;                           /**<    display text info       */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatDurationInfo_t                            duration;                       /**<    duration for which text should be displayed     */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatTextTypeInfo_t text; /**< display text info       */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatDurationInfo_t duration; /**<     duration for which text should be displayed     */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatGetInkeyIndInfo_t;
 
 /**
  * This structure contains the data objects for GET INPUT proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatTextTypeInfo_t                            text;                           /**<    display text info       */
-       TelSatRespLenInfo_t                                     respLen;                        /**<    input response length   */
-       TelSatTextTypeInfo_t                            defaultText;            /**<    default text info       */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatTextTypeInfo_t text; /**< display text info       */
+       TelSatRespLenInfo_t respLen; /**<       input response length   */
+       TelSatTextTypeInfo_t defaultText; /**<  default text info       */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatGetInputIndInfo_t;
 
 /**
  * This structure contains the data objects for PLAY TONE proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatToneInfo_t                                tone;                                   /**<    tone info       */
-       TelSatDurationInfo_t                    duration;                               /**<    duration for which tone should be played        */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatToneInfo_t tone; /**<     tone info       */
+       TelSatDurationInfo_t duration; /**<     duration for which tone should be played        */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatPlayToneIndInfo_t;
 
 /**
  * This structure contains the data objects for SETUP MENU proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t                     alphaId;                        /**<    alpha identifier(string) info   */
-       unsigned char                                           menuItemCount;          /**<    count of menu items     */
-       TelSatMenuItemInfo_t                            menuItem[TAPI_SAT_MENU_ITEM_COUNT_MAX]; /**<    menu item data  */
-       TelSatItemsNextActionIndiListInfo_t     itemNextActionIndList;                                  /**<    next action indication list     */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatIconIdentifierListInfo_t          iconIdList;                     /**<    icon identifier list info       */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
-       TelSatTextAttributeListInfo_t           itemTextAttributeList;                                  /**<    item text attribute list        */
-
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       unsigned char menuItemCount; /**<       count of menu items     */
+       TelSatMenuItemInfo_t menuItem[TAPI_SAT_MENU_ITEM_COUNT_MAX]; /**<       menu item data  */
+       TelSatItemsNextActionIndiListInfo_t itemNextActionIndList; /**< next action indication list     */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatIconIdentifierListInfo_t iconIdList; /**< icon identifier list info       */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
+       TelSatTextAttributeListInfo_t itemTextAttributeList; /**<       item text attribute list        */
 } TelSatSetupMenuIndInfo_t;
 
 /**
  * This structure contains the data objects for SELECT ITEM proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t                     alphaId;                        /**<    alpha identifier(string) info   */
-       TelSatItemsNextActionIndiListInfo_t     itemNextActionIndList;  /**<    next action indication list     */
-       unsigned char                                                           defaultItemIdentifier;  /**<    default item identifier(default selected item id)       */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatIconIdentifierListInfo_t          iconIdList;                     /**<    icon identifier list info       */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
-       TelSatTextAttributeListInfo_t           itemTextAttributeList;  /**<    item text attribute list        */
-       unsigned char                                                           menuItemCount;                  /**<    count of menu items     */
-       TelSatMenuItemInfo_t                            menuItem[TAPI_SAT_MENU_ITEM_COUNT_MAX]; /**<    menu item data  */
-
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatItemsNextActionIndiListInfo_t itemNextActionIndList; /**< next action indication list     */
+       unsigned char defaultItemIdentifier; /**<       default item identifier(default selected item id)       */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatIconIdentifierListInfo_t iconIdList; /**< icon identifier list info       */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
+       TelSatTextAttributeListInfo_t itemTextAttributeList; /**<       item text attribute list        */
+       unsigned char menuItemCount; /**<       count of menu items     */
+       TelSatMenuItemInfo_t menuItem[TAPI_SAT_MENU_ITEM_COUNT_MAX]; /**<       menu item data  */
 } TelSatSelectItemIndInfo_t;
 
 /**
  * This structure contains the data objects for SEND SHORT MESSAGE proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                        /**<    alpha identifier(string) info   */
-       TelSatAddressInfo_t                             address;                        /**<    address for sending sms */
-       TelSatSmsTpduInfo_t                             smsTpdu;                        /**<    sms tpdu info   */
-       TelSatIconIdentifierInfo_t              iconId;                         /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatAddressInfo_t address; /**<       address for sending sms */
+       TelSatSmsTpduInfo_t smsTpdu; /**<       sms tpdu info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatSendSmsIndInfo_t;
 
 /**
  * This structure contains the data objects for SEND SS proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatSsStringInfo_t                    ssString;                               /**<    ss string       */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatSsStringInfo_t ssString; /**<     ss string       */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatSendSsIndInfo_t;
 
 /**
  * This structure contains the data objects for SEND USSD proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                        /**<    alpha identifier(string) info   */
-       TelSatUssdStringInfo_t                  ussdString;                     /**<    ussd string info        */
-       TelSatIconIdentifierInfo_t              iconId;                         /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatUssdStringInfo_t ussdString; /**< ussd string info        */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatSendUssdIndInfo_t;
 
 /**
  * This structure contains the data objects for SETUP CALL proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatAddressInfo_t                             address;                                /**<    setup call address info*/
-       TelSatCapaConfigParamInfo_t             ccp;                                    /**<    capability configuration parameter      */
-       TelSatSubAddressInfo_t                  subAddress;                             /**<    setup call sub address  */
-       TelSatDurationInfo_t                    duration;                               /**<    command execution time duration */
-       TelSatAlphaIdentifierInfo_t             userConfirmPhaseAlphaId;/**<    user Confirmation Phase AlphaId */
-       TelSatAlphaIdentifierInfo_t             callSetupPhaseAlphaId;  /**<    call Setup Phase AlphaId        */
-       TelSatIconIdentifierInfo_t              userConfirmPhaseIconId; /**<    user Confirmation Phase IconId  */
-       TelSatIconIdentifierInfo_t              callSetupPhaseIconId;   /**<    call Setup Phase IconId */
-       TelSatTextAttributeInfo_t               userConfirmPhaseTextAttribute;          /**<    user Confirmation Phase Text Attribute  */
-       TelSatTextAttributeInfo_t               callSetupPhaseTextAttribute;            /**<    call Setup PhaseText Attribute  */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAddressInfo_t address; /**<       setup call address info*/
+       TelSatCapaConfigParamInfo_t ccp; /**<   capability configuration parameter      */
+       TelSatSubAddressInfo_t subAddress; /**< setup call sub address  */
+       TelSatDurationInfo_t duration; /**<     command execution time duration */
+       TelSatAlphaIdentifierInfo_t userConfirmPhaseAlphaId;/**<        user Confirmation Phase AlphaId */
+       TelSatAlphaIdentifierInfo_t callSetupPhaseAlphaId; /**< call Setup Phase AlphaId        */
+       TelSatIconIdentifierInfo_t userConfirmPhaseIconId; /**< user Confirmation Phase IconId  */
+       TelSatIconIdentifierInfo_t callSetupPhaseIconId; /**<   call Setup Phase IconId */
+       TelSatTextAttributeInfo_t userConfirmPhaseTextAttribute; /**<   user Confirmation Phase Text Attribute  */
+       TelSatTextAttributeInfo_t callSetupPhaseTextAttribute; /**<     call Setup PhaseText Attribute  */
 } TelSatSetupCallIndInfo_t;
 
 /**
  * This structure contains the data objects for REFRESH proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatFileListInfo_t                            fileList;                       /**<    file list for refresh   */
-       TelSatAidInfo_t                                         aid;                            /**<    application Id  */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatFileListInfo_t fileList; /**<     file list for refresh   */
+       TelSatAidInfo_t aid; /**<       application Id  */
 } TelSatRefreshIndInfo_t;
 
 /**
  * This structure contains the data objects for PROVIDE LOCAL INFO proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
 
 } TelSatProvideLocalInfoIndInfo_t;
 
 /**
  * This structure contains the data objects for SETUP EVENT LIST proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatEventListInfo_t                           eventList;                      /**<    event list contains events which are required by USIM application       */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatEventListInfo_t eventList; /**<   event list contains events which are required by USIM application       */
 
 } TelSatSetupEventListIndInfo_t;
 
 /**
  * This structure contains the data objects for SETUP IDLE MODE TEXT proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatTextTypeInfo_t                            text;                           /**<    text to be shown on idle screen */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatTextTypeInfo_t text; /**< text to be shown on idle screen */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatSetupIdleModeTextIndInfo_t;
 
 /**
  * This structure contains the data objects for SEND DTMF COMMAND proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t                     alphaId;                        /**<    alpha identifier(string) info   */
-       TelSatDtmfStringInfo_t                          dtmfString;                     /**<    dtmf string     */
-       TelSatIconIdentifierInfo_t                      iconId;                         /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t                       textAttribute;          /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatDtmfStringInfo_t dtmfString; /**< dtmf string     */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatSendDtmfIndInfo_t;
 
 /**
  * This structure contains the data objects for LANGUAGE NOTIFICATION proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatLanguageInfo_t                            language;                       /**<    language info from USIM application     */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatLanguageInfo_t language; /**<     language info from USIM application     */
 } TelSatLanguageNotificationIndInfo_t;
 
 /**
  * This structure contains the data objects for LAUNCH BROWSER proactive command indication.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatBrowserIdentitiesInfo_t   browserId;                              /**<    browser identity        */
-       TelSatUrlInfo_t                                 url;                                    /**<    url     */
-       TelSatBearerInfo_t                              bearer;                                 /**<    bearer which is used by browser */
-       unsigned char                                   provisioningRefCount;   /**<    provisioning reference count    */
-       TelSatProvisioningRefInfo_t             provisioningRef[TAPI_SAT_PROVISIONING_REF_MAX_COUNT];   /**<    provisioning reference data     */
-       TelSatTextTypeInfo_t                    text;                                   /**<    display text info       */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatBrowserIdentitiesInfo_t browserId; /**<   browser identity        */
+       TelSatUrlInfo_t url; /**<       url     */
+       TelSatBearerInfo_t bearer; /**< bearer which is used by browser */
+       unsigned char provisioningRefCount; /**<        provisioning reference count    */
+       TelSatProvisioningRefInfo_t provisioningRef[TAPI_SAT_PROVISIONING_REF_MAX_COUNT]; /**<  provisioning reference data     */
+       TelSatTextTypeInfo_t text; /**< display text info       */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatLaunchBrowserIndInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL CSB proactive command indication data.
  */
-typedef struct
-{
-       TelSatAddressInfo_t                                                     address;                        /**<    channel address */
-       TelSatSubAddressInfo_t                                          subAddress;                     /**<    channel sub address     */
-       TelSatDurationInfo_t                                            duration1;                      /**<    connection require time */
-       TelSatDurationInfo_t                                            duration2;                      /**<    connection require time2        */
-       TelSatBearerParametersCsdInfo_t                         bearerParamsCsd;        /**<    csd info        */
-       TelSatBufferSizeInfo_t                                          bufferSize;                     /**<    bufferSize      */
-       TelSatOtherAddressInfo_t                                        otherAddress;           /**<    otherAddress    */
-       TelSatTextTypeInfo_t                                            userLogin;                      /**<    userLogin       */
-       TelSatTextTypeInfo_t                                            userPassword;           /**<    userPassword    */
-       TelSatSimMeInterfaceTransportLevelInfo_t        simMeInterfaceTransportLevel;   /**<    simMeInterfaceTransportLevel    */
-       TelSatOtherAddressInfo_t                                        dataDestinationAddress;                 /**<    dataDestinationAddress  */
+typedef struct {
+       TelSatAddressInfo_t address; /**<       channel address */
+       TelSatSubAddressInfo_t subAddress; /**< channel sub address     */
+       TelSatDurationInfo_t duration1; /**<    connection require time */
+       TelSatDurationInfo_t duration2; /**<    connection require time2        */
+       TelSatBearerParametersCsdInfo_t bearerParamsCsd; /**<   csd info        */
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+       TelSatOtherAddressInfo_t otherAddress; /**<     otherAddress    */
+       TelSatTextTypeInfo_t userLogin; /**<    userLogin       */
+       TelSatTextTypeInfo_t userPassword; /**< userPassword    */
+       TelSatSimMeInterfaceTransportLevelInfo_t simMeInterfaceTransportLevel; /**<     simMeInterfaceTransportLevel    */
+       TelSatOtherAddressInfo_t dataDestinationAddress; /**<   dataDestinationAddress  */
 } TelSatOpenChannelCsbInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL (packet) proactive command indication data.
  */
-typedef struct
-{
-       TelSatBearerParametersGprsInfo_t                        bearerParamsGprs;               /**<    gprs info       */
-       TelSatBufferSizeInfo_t                                          bufferSize;                             /**<    bufferSize      */
-       TelSatnetworkAccessNameInfo_t                           networkAccessName;              /**<    networkAccessName       */
-       TelSatOtherAddressInfo_t                                        otherAddress;                   /**<    otherAddress    */
-       TelSatTextTypeInfo_t                                            userLogin;                              /**<    userLogin       */
-       TelSatTextTypeInfo_t                                            userPassword;                   /**<    userPassword    */
-       TelSatSimMeInterfaceTransportLevelInfo_t        simMeInterfaceTransportLevel;   /**<    simMeInterfaceTransportLevel    */
-       TelSatOtherAddressInfo_t                                        dataDestinationAddress;                 /**<    dataDestinationAddress  */
-       TelSatTextAttributeInfo_t                                       textAttribute;                                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatBearerParametersGprsInfo_t bearerParamsGprs; /**< gprs info       */
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+       TelSatnetworkAccessNameInfo_t networkAccessName; /**<   networkAccessName       */
+       TelSatOtherAddressInfo_t otherAddress; /**<     otherAddress    */
+       TelSatTextTypeInfo_t userLogin; /**<    userLogin       */
+       TelSatTextTypeInfo_t userPassword; /**< userPassword    */
+       TelSatSimMeInterfaceTransportLevelInfo_t simMeInterfaceTransportLevel; /**<     simMeInterfaceTransportLevel    */
+       TelSatOtherAddressInfo_t dataDestinationAddress; /**<   dataDestinationAddress  */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatOpenChannelpdbInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL LOCAL LINK proactive command indication data.
  */
-typedef struct
-{
-       TelSatDurationInfo_t                                            duration1;                                      /**<    command execution time duration1        */
-       TelSatDurationInfo_t                                            duration2;                                      /**<    command execution time duration2        */
-       TelSatBearerParametersLocalLinksInfo_t          bearerParamsLocalLinks;         /**<    local link info */
-       TelSatBufferSizeInfo_t                                          bufferSize;                                     /**<    bufferSize      */
-       TelSatTextTypeInfo_t                                            userPassword;                           /**<    userPassword    */
-       TelSatSimMeInterfaceTransportLevelInfo_t        simMeInterfaceTransportLevel;   /**<    simMeInterfaceTransportLevel    */
-       TelSatOtherAddressInfo_t                                        dataDestinationAddress;                 /**<    dataDestinationAddress  */
-       TelSatRemoteEntityAddressInfo_t                         remoteEntityAddress;                    /**<    remoteEntityAddress     */
-       TelSatTextAttributeInfo_t                                       textAttribute;                                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatDurationInfo_t duration1; /**<    command execution time duration1        */
+       TelSatDurationInfo_t duration2; /**<    command execution time duration2        */
+       TelSatBearerParametersLocalLinksInfo_t bearerParamsLocalLinks; /**<     local link info */
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+       TelSatTextTypeInfo_t userPassword; /**< userPassword    */
+       TelSatSimMeInterfaceTransportLevelInfo_t simMeInterfaceTransportLevel; /**<     simMeInterfaceTransportLevel    */
+       TelSatOtherAddressInfo_t dataDestinationAddress; /**<   dataDestinationAddress  */
+       TelSatRemoteEntityAddressInfo_t remoteEntityAddress; /**<       remoteEntityAddress     */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatOpenChannelLocalBearerInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL (DEFAULT BEARER) proactive command indication data.
  */
-typedef struct
-{
-       TelSatBufferSizeInfo_t                                          bufferSize;                                     /**<    bufferSize      */
-       TelSatOtherAddressInfo_t                                        otherAddress;                           /**<    otherAddress    */
-       TelSatTextTypeInfo_t                                            userLogin;                                      /**<    userLogin       */
-       TelSatTextTypeInfo_t                                            userPassword;                           /**<    userPassword    */
-       TelSatSimMeInterfaceTransportLevelInfo_t        simMeInterfaceTransportLevel;/**<       simMeInterfaceTransportLevel    */
-       TelSatOtherAddressInfo_t                                        dataDestinationAddress;         /**<    dataDestinationAddress  */
+typedef struct {
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+       TelSatOtherAddressInfo_t otherAddress; /**<     otherAddress    */
+       TelSatTextTypeInfo_t userLogin; /**<    userLogin       */
+       TelSatTextTypeInfo_t userPassword; /**< userPassword    */
+       TelSatSimMeInterfaceTransportLevelInfo_t simMeInterfaceTransportLevel;/**<      simMeInterfaceTransportLevel    */
+       TelSatOtherAddressInfo_t dataDestinationAddress; /**<   dataDestinationAddress  */
 } TelSatOpenChannelDefaultBearerInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL (UICC Server Mode) proactive command indication data.
  */
-typedef struct
-{
-       TelSatBufferSizeInfo_t                                          bufferSize;                                             /**<    bufferSize      */
-       TelSatSimMeInterfaceTransportLevelInfo_t        simMeInterfaceTransportLevel;   /**<    simMeInterfaceTransportLevel    */
+typedef struct {
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+       TelSatSimMeInterfaceTransportLevelInfo_t simMeInterfaceTransportLevel; /**<     simMeInterfaceTransportLevel    */
 } TelSatOpenChannelUiccServerModeInfo_t;
 
 /**
  * This structure contains the data objects for OPEN CHANNEL proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       int                                             bIsUiccServerMode;              /**<    flag whether UICC server mode or not    */
-       TelSatBearerDescType_t                  bearerType;                             /**<    bearer destination type */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       union
-       {
-               TelSatOpenChannelCsbInfo_t                              csBearer;               /**<    cs info */
-               TelSatOpenChannelpdbInfo_t                              pdBearer;               /**<    pbd info        */
-               TelSatOpenChannelLocalBearerInfo_t              locBearer;              /**<    local link info */
-               TelSatOpenChannelDefaultBearerInfo_t    defaultBearer;  /**<    defaultBearer   */
-               TelSatOpenChannelUiccServerModeInfo_t   uiccServerMode; /**<    uiccServerMode  */
-       }details;                /**< Open Channel Details */
-}TelSatOpenChannelIndInfo_t;
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       int bIsUiccServerMode; /**<     flag whether UICC server mode or not    */
+       TelSatBearerDescType_t bearerType; /**< bearer destination type */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       union {
+               TelSatOpenChannelCsbInfo_t csBearer; /**<       cs info */
+               TelSatOpenChannelpdbInfo_t pdBearer; /**<       pbd info        */
+               TelSatOpenChannelLocalBearerInfo_t locBearer; /**<      local link info */
+               TelSatOpenChannelDefaultBearerInfo_t defaultBearer; /**<        defaultBearer   */
+               TelSatOpenChannelUiccServerModeInfo_t uiccServerMode; /**<      uiccServerMode  */
+       } details; /**< Open Channel Details */
+} TelSatOpenChannelIndInfo_t;
 
 /**
  * This structure contains the data objects for CLOSE CHANNEL proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       TelSatTextAttributeInfo_t               textAttribute;                  /**<    text attribute info -e.g. bold, center align    */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatTextAttributeInfo_t textAttribute; /**<   text attribute info -e.g. bold, center align    */
 } TelSatCloseChannelIndInfo_t;
 
 /**
  * This structure contains the data objects for RECEIVE DATA proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;                  /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;               /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                                /**<    alpha identifier(string) info   */
-       TelSatIconIdentifierInfo_t              iconId;                                 /**<    icon identifier info    */
-       TelSatChannelDataLengthInfo_t   channelDataLen;                 /**<    channel data length     */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatChannelDataLengthInfo_t channelDataLen; /**<      channel data length     */
 } TelSatReceiveDataIndInfo_t;
 
 /**
  * This structure contains the data objects for SEND DATA proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t               commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t    deviceIdentities;       /**<    device identities info. includes source and destination devices */
-       TelSatAlphaIdentifierInfo_t             alphaId;                        /**<    alpha identifier(string) info   */
-       TelSatIconIdentifierInfo_t              iconId;                         /**<    icon identifier info    */
-       TelSatChannelDataInfo_t                 channel_data;           /**<    channel data for sending        */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
+       TelSatAlphaIdentifierInfo_t alphaId; /**<       alpha identifier(string) info   */
+       TelSatIconIdentifierInfo_t iconId; /**< icon identifier info    */
+       TelSatChannelDataInfo_t channel_data; /**<      channel data for sending        */
 } TelSatSendDataIndInfo_t;
 
 /**
  * This structure contains the data objects for GET CHANNEL STATUS proactive command indication data.
  */
-typedef struct
-{
-       TelSatCommandDetailInfo_t                       commandDetail;          /**<    command detail info. includes command number, type, qualifier   */
-       TelSatDeviceIdentitiesInfo_t            deviceIdentities;       /**<    device identities info. includes source and destination devices */
+typedef struct {
+       TelSatCommandDetailInfo_t commandDetail; /**<   command detail info. includes command number, type, qualifier   */
+       TelSatDeviceIdentitiesInfo_t deviceIdentities; /**<     device identities info. includes source and destination devices */
 } TelSatGetChannelStatusIndInfo_t;
 
 /**
  * This structure contains the data object for END PROACTIVE SESSION command indication.
  */
-typedef struct
-{
-       TelSatCommandType_t             commandType;            /**<    proactive command type  */
+typedef struct {
+       TelSatCommandType_t commandType; /**<   proactive command type  */
 } TelSatEndProactiveSessionIndInfo_t;
 
 /**
  * This structure contains the data objects for PROACTIVE command indication union data.
  */
-typedef struct
-{
-       union
-       {
-               TelSatMoreTimeIndInfo_t                         moreTime;
-               TelSatDisplayTextIndInfo_t                      displayText;            /**<    Parsed proactive command info from TLV to Telephony data type - display text    */
-               TelSatGetInkeyIndInfo_t                         getInkey;                       /**<    Parsed proactive command info from TLV to Telephony data type - getInkey        */
-               TelSatGetInputIndInfo_t                         getInput;                       /**<    Parsed proactive command info from TLV to Telephony data type - getInput        */
-               TelSatPlayToneIndInfo_t                         playTone;                       /**<    Parsed proactive command info from TLV to Telephony data type - play tone       */
-               TelSatSetupMenuIndInfo_t                        setupMenu;                      /**<    Parsed proactive command info from TLV to Telephony data type - setup menu      */
-               TelSatSelectItemIndInfo_t                       selectItem;                     /**<    Parsed proactive command info from TLV to Telephony data type - select item     */
-               TelSatSendSmsIndInfo_t                          sendSms;                        /**<    Parsed proactive command info from TLV to Telephony data type - send sms        */
-               TelSatSendSsIndInfo_t                           sendSs;                         /**<    Parsed proactive command info from TLV to Telephony data type - send ss */
-               TelSatSendUssdIndInfo_t                         sendUssd;                       /**<    Parsed proactive command info from TLV to Telephony data type - send  ussd      */
-               TelSatSetupCallIndInfo_t                        setupCall;                      /**<    Parsed proactive command info from TLV to Telephony data type - setup call      */
-               TelSatRefreshIndInfo_t                          refresh;                        /**<    Parsed proactive command info from TLV to Telephony data type - refresh */
-               TelSatProvideLocalInfoIndInfo_t         provideLocInfo;         /**<    Parsed proactive command info from TLV to Telephony data type - provide local info      */
-               TelSatLaunchBrowserIndInfo_t            launchBrowser;          /**<    Parsed proactive command info from TLV to Telephony data type - launch browser  */
-               TelSatSetupIdleModeTextIndInfo_t        idleText;                       /**<    Parsed proactive command info from TLV to Telephony data type - setup idle mode text    */
-               TelSatSendDtmfIndInfo_t                         sendDtmf;                       /**<    Parsed proactive command info from TLV to Telephony data type - send dtmf       */
-               TelSatLanguageNotificationIndInfo_t     languageNotification;/**<       Parsed proactive command info from TLV to Telephony data type - language notification   */
-               TelSatSetupEventListIndInfo_t           setupEventList;         /**<    Parsed proactive command info from TLV to Telephony data type - setup event list        */
-               TelSatOpenChannelIndInfo_t                      openChannel;            /**<    Parsed proactive command info from TLV to Telephony data type - open channel    */
-               TelSatCloseChannelIndInfo_t                     closeChannel;           /**<    Parsed proactive command info from TLV to Telephony data type - close channel   */
-               TelSatReceiveDataIndInfo_t                      receiveData;            /**<    Parsed proactive command info from TLV to Telephony data type - receive data    */
-               TelSatSendDataIndInfo_t                         sendData;                       /**<    Parsed proactive command info from TLV to Telephony data type - send data       */
-               TelSatGetChannelStatusIndInfo_t         getChannelStatus;       /**<    Parsed proactive command info from TLV to Telephony data type - get channel status      */
-       }cmdInfo;                                                                                                       /**<    Union   */
-}TelSatProactiveCmdData_t;
+typedef struct {
+       union {
+               TelSatMoreTimeIndInfo_t moreTime;
+               TelSatDisplayTextIndInfo_t displayText; /**<    Parsed proactive command info from TLV to Telephony data type - display text    */
+               TelSatGetInkeyIndInfo_t getInkey; /**<  Parsed proactive command info from TLV to Telephony data type - getInkey        */
+               TelSatGetInputIndInfo_t getInput; /**<  Parsed proactive command info from TLV to Telephony data type - getInput        */
+               TelSatPlayToneIndInfo_t playTone; /**<  Parsed proactive command info from TLV to Telephony data type - play tone       */
+               TelSatSetupMenuIndInfo_t setupMenu; /**<        Parsed proactive command info from TLV to Telephony data type - setup menu      */
+               TelSatSelectItemIndInfo_t selectItem; /**<      Parsed proactive command info from TLV to Telephony data type - select item     */
+               TelSatSendSmsIndInfo_t sendSms; /**<    Parsed proactive command info from TLV to Telephony data type - send sms        */
+               TelSatSendSsIndInfo_t sendSs; /**<      Parsed proactive command info from TLV to Telephony data type - send ss */
+               TelSatSendUssdIndInfo_t sendUssd; /**<  Parsed proactive command info from TLV to Telephony data type - send  ussd      */
+               TelSatSetupCallIndInfo_t setupCall; /**<        Parsed proactive command info from TLV to Telephony data type - setup call      */
+               TelSatRefreshIndInfo_t refresh; /**<    Parsed proactive command info from TLV to Telephony data type - refresh */
+               TelSatProvideLocalInfoIndInfo_t provideLocInfo; /**<    Parsed proactive command info from TLV to Telephony data type - provide local info      */
+               TelSatLaunchBrowserIndInfo_t launchBrowser; /**<        Parsed proactive command info from TLV to Telephony data type - launch browser  */
+               TelSatSetupIdleModeTextIndInfo_t idleText; /**< Parsed proactive command info from TLV to Telephony data type - setup idle mode text    */
+               TelSatSendDtmfIndInfo_t sendDtmf; /**<  Parsed proactive command info from TLV to Telephony data type - send dtmf       */
+               TelSatLanguageNotificationIndInfo_t languageNotification;/**<   Parsed proactive command info from TLV to Telephony data type - language notification   */
+               TelSatSetupEventListIndInfo_t setupEventList; /**<      Parsed proactive command info from TLV to Telephony data type - setup event list        */
+               TelSatOpenChannelIndInfo_t openChannel; /**<    Parsed proactive command info from TLV to Telephony data type - open channel    */
+               TelSatCloseChannelIndInfo_t closeChannel; /**<  Parsed proactive command info from TLV to Telephony data type - close channel   */
+               TelSatReceiveDataIndInfo_t receiveData; /**<    Parsed proactive command info from TLV to Telephony data type - receive data    */
+               TelSatSendDataIndInfo_t sendData; /**<  Parsed proactive command info from TLV to Telephony data type - send data       */
+               TelSatGetChannelStatusIndInfo_t getChannelStatus; /**<  Parsed proactive command info from TLV to Telephony data type - get channel status      */
+       } cmdInfo; /**< Union   */
+} TelSatProactiveCmdData_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of DISPLAY TEXT proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t      result;                         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatDisplayTextRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatDisplayTextRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of GET INKEY proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;         /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatTextTypeInfo_t            text;           /**<    inserted key info       */
-       TelSatDurationInfo_t            duration;
-}TelSatGetInkeyRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatTextTypeInfo_t text; /**< inserted key info       */
+       TelSatDurationInfo_t duration;
+} TelSatGetInkeyRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of PLAY TONE proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatPlayToneRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatPlayToneRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of MORE TIME proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatMoreTimeRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatMoreTimeRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SETUP MENU proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatSetupMenuRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatSetupMenuRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of GET INPUT proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;         /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatTextTypeInfo_t            text;           /**<    inserted string info    */
-}TelSatGetInputRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatTextTypeInfo_t text; /**< inserted string info    */
+} TelSatGetInputRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SELECT ITEM proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t              result;                         /**<    result whether current proactive command request was executed successfully or not       */
-       int                                     bOtherInfo;                     /**<    flag to check whether other information is required or not      */
-       unsigned char                   itemIdentifier;         /**<    item identifier */
-}TelSatSelectItemRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag to check whether other information is required or not      */
+       unsigned char itemIdentifier; /**<      item identifier */
+} TelSatSelectItemRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of PROVIDE LOCAL INFORMATION proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                                      result;                 /**<    result whether current proactive command request was executed successfully or not       */
-       int                                                             bOtherInfo;             /**<    flag to check whether other information is required or not      */
-       TelSatCmdQualiProvideLocalInfo_t        infoType;               /**<    local info type - e.g. time zone or language info, etc  */
-       union
-       {
-               TelSatDataTimeZoneInfo_t        timeZoneInfo;           /**<    current time zone info  */
-               TelSatLanguageInfo_t            languageInfo;           /**<    current ME language setting info        */
-       }u;                                                                                                     /**<    Union   */
-}TelSatProvideLocalInfoRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag to check whether other information is required or not      */
+       TelSatCmdQualiProvideLocalInfo_t infoType; /**< local info type - e.g. time zone or language info, etc  */
+       union {
+               TelSatDataTimeZoneInfo_t timeZoneInfo; /**<     current time zone info  */
+               TelSatLanguageInfo_t languageInfo; /**< current ME language setting info        */
+       } u; /**<       Union   */
+} TelSatProvideLocalInfoRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SETUP EVENT LIST proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t              result;                                         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatSetupEventListRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatSetupEventListRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SEND SMS proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                              result;                                                         /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatCallCtrlProblemType_t             additionalCallCtrlProblemInfo;          /**<    call control problem    */
-}TelSatSendSmsRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatCallCtrlProblemType_t additionalCallCtrlProblemInfo; /**< call control problem    */
+} TelSatSendSmsRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SET UP CALL proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                                      result;                                         /**<    result whether current proactive command request was executed successfully or not       */
-       int                                                             bOtherInfo;                                     /**<    flag to check whether other information are required or not     */
-       TelSatNetworkProblemType_t                      networkProblem;                         /**<    network problem during setup call       */
-       TelSatCallCtrlProblemType_t                     permanentCallCtrlProblem;       /**<    permanent call control problem  */
-       TelSatCallCtrlRequestedActionInfo_t     callCtrlRequestedAction;        /**<    call control requested action info      */
-       TelSatResultInfo_t                                      result2;                                        /**<    additional response on general result   */
-       TelSatTextTypeInfo_t                            text;                                           /**<    text string info        */
-       int                                                             bIsTapiCause;                           /**<    flag to check whether tapi makes problem or not */
-       unsigned long                                           tapiCause;                                      /**<    tapi call level cause   */
-       unsigned long                                           tapiSsCause;                            /**<    tapi ss level cause     */
-       }TelSatSetupCallRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag to check whether other information are required or not     */
+       TelSatNetworkProblemType_t networkProblem; /**< network problem during setup call       */
+       TelSatCallCtrlProblemType_t permanentCallCtrlProblem; /**<      permanent call control problem  */
+       TelSatCallCtrlRequestedActionInfo_t callCtrlRequestedAction; /**<       call control requested action info      */
+       TelSatResultInfo_t result2; /**<        additional response on general result   */
+       TelSatTextTypeInfo_t text; /**< text string info        */
+       int bIsTapiCause; /**<  flag to check whether tapi makes problem or not */
+       unsigned long tapiCause; /**<   tapi call level cause   */
+       unsigned long tapiSsCause; /**< tapi ss level cause     */
+} TelSatSetupCallRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SEND SS proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                                      result;                 /**<    result whether current proactive command request was executed successfully or not       */
-       int                                                             bOtherInfo;             /**<    flag to check whether whether other information is required or not      */
-       TelSatSsProblemType_t                           additionalSsProblemInfo;                /**<    additional ss problem */
-       TelSatCallCtrlProblemType_t                     additionalCallCtrlProblemInfo;  /**<    additional call control problem */
-       TelSatCallCtrlRequestedActionInfo_t     callCtrlRequestedAction;                /**<    call control requested action info      */
-       TelSatResultInfo_t                                      result2;                /**<    additional response on general result   */
-       TelSatTextTypeInfo_t                            text;                   /**<    text string info        */
-}TelSatSendSsRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag to check whether whether other information is required or not      */
+       TelSatSsProblemType_t additionalSsProblemInfo; /**<     additional ss problem */
+       TelSatCallCtrlProblemType_t additionalCallCtrlProblemInfo; /**< additional call control problem */
+       TelSatCallCtrlRequestedActionInfo_t callCtrlRequestedAction; /**<       call control requested action info      */
+       TelSatResultInfo_t result2; /**<        additional response on general result   */
+       TelSatTextTypeInfo_t text; /**< text string info        */
+} TelSatSendSsRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SEND USSD proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                                      result;                 /**<    result whether current proactive command request was executed successfully or not       */
-       int                                                             bOtherInfo;             /**<    flag to check whether other information is required or not      */
-       TelSatUssdProblemType_t                         additionalUssdProblemInfo;              /**<    additional ussd problem */
-       TelSatCallCtrlProblemType_t                     additionalCallCtrlProblemInfo;  /**<    additional call control problem */
-       int                                                             bCallCtrlHasModification;               /**<    flag to check whether modification happens during call control  */
-       TelSatTextTypeInfo_t                            text;                                                   /**<    text string info        */
-       TelSatCallCtrlRequestedActionInfo_t     callCtrlRequestedAction;                /**<    call control requested action info      */
-       TelSatResultInfo_t                                      result2;                /**<    additional response on general result   */
-       TelSatTextTypeInfo_t                            text2;                  /**<    text string info        */
-}TelSatSendUssdRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag to check whether other information is required or not      */
+       TelSatUssdProblemType_t additionalUssdProblemInfo; /**< additional ussd problem */
+       TelSatCallCtrlProblemType_t additionalCallCtrlProblemInfo; /**< additional call control problem */
+       int bCallCtrlHasModification; /**<      flag to check whether modification happens during call control  */
+       TelSatTextTypeInfo_t text; /**< text string info        */
+       TelSatCallCtrlRequestedActionInfo_t callCtrlRequestedAction; /**<       call control requested action info      */
+       TelSatResultInfo_t result2; /**<        additional response on general result   */
+       TelSatTextTypeInfo_t text2; /**<        text string info        */
+} TelSatSendUssdRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of REFRESH proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                              result;         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatRefreshRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatRefreshRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of GET CHANNEL STATUS proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                         /**<    result whether current proactive command request was executed successfully or not       */
-       int                                             bOtherInfo;                     /**<    flag whether other information are required or not      */
-       TelSatBipProblemType_t  additionalProblemInfo;  /**<    bip specific problem info       */
-       TelSatChannelStatusInfo_t       channelStatus;          /**<    channel Status  */
-}TelSatGetChannelStatusRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag whether other information are required or not      */
+       TelSatBipProblemType_t additionalProblemInfo; /**<      bip specific problem info       */
+       TelSatChannelStatusInfo_t channelStatus; /**<   channel Status  */
+} TelSatGetChannelStatusRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of CLOSE CHANNEL proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                                 /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatBipProblemType_t          additionalProblemInfo;  /**<    bip specific problem info       */
-}TelSatCloseChannelRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatBipProblemType_t additionalProblemInfo; /**<      bip specific problem info       */
+} TelSatCloseChannelRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of OPEN CHANNEL proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                              result;                                 /**<    result whether current proactive command request was executed successfully or not       */
-       int                                                     bOtherInfo;                             /**<    flag whether other information are required or not */
-       TelSatBearerDescriptionInfo_t   bearerDescription;              /**<    bearerDescription       */
-       TelSatBipProblemType_t          additionalProblemInfo;  /**<    bip specific problem info       */
-       TelSatChannelStatusInfo_t               channelStatus;                  /**<    channelStatus   */
-       TelSatBufferSizeInfo_t                  bufferSize;                             /**<    bufferSize      */
-}TelSatOpenChannelRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       int bOtherInfo; /**<    flag whether other information are required or not */
+       TelSatBearerDescriptionInfo_t bearerDescription; /**<   bearerDescription       */
+       TelSatBipProblemType_t additionalProblemInfo; /**<      bip specific problem info       */
+       TelSatChannelStatusInfo_t channelStatus; /**<   channelStatus   */
+       TelSatBufferSizeInfo_t bufferSize; /**< bufferSize      */
+} TelSatOpenChannelRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of LANGAUGE NOTIFICATION proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                              result;                                 /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatLanguageNotificationRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatLanguageNotificationRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of LAUNCH BROWSER proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                                      result;                                 /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatLaunchBrowserProblemType_t        additionalProblemInfo;  /**<    browser specific problem info   */
-}TelSatLaunchBrowserRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatLaunchBrowserProblemType_t additionalProblemInfo; /**<    browser specific problem info   */
+} TelSatLaunchBrowserRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of RECEIVE DATA proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                                 /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatBipProblemType_t  additionalProblemInfo;  /**<    bip specific problem info       */
-       int                                                     bOtherInfo;                             /**<    flag whether other information are required or not      */
-       TelSatChannelDataInfo_t         channel_data;                   /**<    channel data    */
-       unsigned char                                   channelDataLen;                 /**<    channel data length     */
-}TelSatReceiveDataRespInfo_t;
-
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatBipProblemType_t additionalProblemInfo; /**<      bip specific problem info       */
+       int bOtherInfo; /**<    flag whether other information are required or not      */
+       TelSatChannelDataInfo_t channel_data; /**<      channel data    */
+       unsigned char channelDataLen; /**<      channel data length     */
+} TelSatReceiveDataRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SEND DATA proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                                         /**<    result whether current proactive command request was executed successfully or not       */
-       TelSatBipProblemType_t  additionalProblemInfo;          /**<    bip specific problem info       */
-       unsigned char                           channelDataLen;                         /**<    channel data length     */
-}TelSatSendDataRespInfo_t;
-
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+       TelSatBipProblemType_t additionalProblemInfo; /**<      bip specific problem info       */
+       unsigned char channelDataLen; /**<      channel data length     */
+} TelSatSendDataRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SETUP IDLE MODE TEXT proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                                         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatSetupIdlemodeTextRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatSetupIdlemodeTextRespInfo_t;
 
 /**
  * This structure contains the data objects for the Terminal Response of SEND DTMF proactive command.
  */
-typedef struct
-{
-       TelSatResultInfo_t                      result;                                         /**<    result whether current proactive command request was executed successfully or not       */
-}TelSatSendDtmfRespInfo_t;
+typedef struct {
+       TelSatResultInfo_t result; /**< result whether current proactive command request was executed successfully or not       */
+} TelSatSendDtmfRespInfo_t;
 
 /**
  * This contains the data structures to be used to send proactive command response.
  */
-typedef struct
-{
-       unsigned char                                   commandNumber;          /**<      proactive command number      */
-       TelSatCommandType_t                     commandType;            /**<      proactive command type        */
-       union
-       {
-               TelSatMoreTimeRespInfo_t                                moreTime;
-               TelSatDisplayTextRespInfo_t                             displayText;    /**<    terminal response info from displayText proactive command       */
-               TelSatGetInkeyRespInfo_t                                getInkey;               /**<    terminal response info from getInkey proactive command  */
-               TelSatGetInputRespInfo_t                                getInput;               /**<    terminal response info from getInput proactive command  */
-               TelSatPlayToneRespInfo_t                                playTone;               /**<    terminal response info from playTone proactive command  */
-               TelSatSetupMenuRespInfo_t                               setupMenu;              /**<    terminal response info from setupMenu proactive command */
-               TelSatSelectItemRespInfo_t                              selectItem;             /**<    terminal response info from selectItem proactive command        */
-               TelSatSendSmsRespInfo_t                                 sendSms;                /**<    terminal response info from sendSms proactive command   */
-               TelSatSendSsRespInfo_t                                  sendSs;                 /**<    terminal response info from sendSs proactive command    */
-               TelSatSendUssdRespInfo_t                                sendUssd;               /**<    terminal response info from sendUssd proactive command  */
-               TelSatSetupCallRespInfo_t                               setupCall;              /**<    terminal response info from setupCall proactive command */
-               TelSatRefreshRespInfo_t                                 refresh;                /**<    terminal response info from refresh proactive command   */
-               TelSatProvideLocalInfoRespInfo_t                provideLocInfo; /**<    terminal response info from provide Local Info proactive command        */
-               TelSatLaunchBrowserRespInfo_t                   launchBrowser;  /**<    terminal response info from launch Browser proactive command    */
-               TelSatSetupIdlemodeTextRespInfo_t               idleText;               /**<    terminal response info from setup idle mode text proactive command      */
-               TelSatSendDtmfRespInfo_t                                sendDtmf;               /**<    terminal response info from send Dtmf proactive command */
-               TelSatLanguageNotificationRespInfo_t    languageNotification;   /**<    terminal response info from language Notification proactive command     */
-               TelSatSetupEventListRespInfo_t                  setupEventList;                 /**<    terminal response info from setup Event List proactive command  */
-               TelSatOpenChannelRespInfo_t                             openChannel;                    /**<    terminal response info from openChannel proactive command       */
-       }terminalRespInfo;                                                                                                      /**<    Union   */
-}TelSatRespInfo_t;
+typedef struct {
+       unsigned char commandNumber; /**<         proactive command number      */
+       TelSatCommandType_t commandType; /**<     proactive command type        */
+       union {
+               TelSatMoreTimeRespInfo_t moreTime;
+               TelSatDisplayTextRespInfo_t displayText; /**<   terminal response info from displayText proactive command       */
+               TelSatGetInkeyRespInfo_t getInkey; /**< terminal response info from getInkey proactive command  */
+               TelSatGetInputRespInfo_t getInput; /**< terminal response info from getInput proactive command  */
+               TelSatPlayToneRespInfo_t playTone; /**< terminal response info from playTone proactive command  */
+               TelSatSetupMenuRespInfo_t setupMenu; /**<       terminal response info from setupMenu proactive command */
+               TelSatSelectItemRespInfo_t selectItem; /**<     terminal response info from selectItem proactive command        */
+               TelSatSendSmsRespInfo_t sendSms; /**<   terminal response info from sendSms proactive command   */
+               TelSatSendSsRespInfo_t sendSs; /**<     terminal response info from sendSs proactive command    */
+               TelSatSendUssdRespInfo_t sendUssd; /**< terminal response info from sendUssd proactive command  */
+               TelSatSetupCallRespInfo_t setupCall; /**<       terminal response info from setupCall proactive command */
+               TelSatRefreshRespInfo_t refresh; /**<   terminal response info from refresh proactive command   */
+               TelSatProvideLocalInfoRespInfo_t provideLocInfo; /**<   terminal response info from provide Local Info proactive command        */
+               TelSatLaunchBrowserRespInfo_t launchBrowser; /**<       terminal response info from launch Browser proactive command    */
+               TelSatSetupIdlemodeTextRespInfo_t idleText; /**<        terminal response info from setup idle mode text proactive command      */
+               TelSatSendDtmfRespInfo_t sendDtmf; /**< terminal response info from send Dtmf proactive command */
+               TelSatLanguageNotificationRespInfo_t languageNotification; /**< terminal response info from language Notification proactive command     */
+               TelSatSetupEventListRespInfo_t setupEventList; /**<     terminal response info from setup Event List proactive command  */
+               TelSatOpenChannelRespInfo_t openChannel; /**<   terminal response info from openChannel proactive command       */
+       } terminalRespInfo; /**<        Union   */
+} TelSatRespInfo_t;
 
 /*
-*SAT Icon Data
-*/
-
-typedef  struct{
-  unsigned char                        iconId;
-  unsigned char              imgType;
-  unsigned char                        imgLen;
-  unsigned char              imgData[256];
-} TelSatIconDataResp_t;
+ *SAT Icon Data
+ */
 
-typedef  struct{
-  unsigned char                        iconId;
-  unsigned char                        imgType;
-  unsigned char                        fileId[2];
-  unsigned char                        reqDataLen[2];
-  unsigned char                        offset[2];
-}TelsatIconDataGet_t;
+typedef struct {
+       unsigned char iconId;
+       unsigned char imgType;
+       unsigned char imgLen;
+       unsigned char imgData[256];
+} TelSatIconDataResp_t;
 
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
+typedef struct {
+       unsigned char iconId;
+       unsigned char imgType;
+       unsigned char fileId[2];
+       unsigned char reqDataLen[2];
+       unsigned char offset[2];
+} TelsatIconDataGet_t;
 
 #ifdef __cplusplus
 }
@@ -781,4 +702,3 @@ typedef  struct{
 /**
  * @}
  */
-
index 4a2004e..84812a1 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 /**
-* @open
-* @ingroup             TelephonyAPI
-* @addtogroup  SIM_TAPI        SIM
-* @{
-*
-* @file TelSim.h
+ * @open
+ * @ingroup            TelephonyAPI
+ * @addtogroup SIM_TAPI        SIM
+ * @{
+ *
+ * @file TelSim.h
 
    @brief This file serves as a "C" header file defines structures for Tapi SIM Services. \n
     It contains a sample set of constants, enums, structs that would be required by applications.
-*/
+ @brief This file serves as a "C" header file defines structures for Tapi SIM Services. \n
+ It contains a sample set of constants, enums, structs that would be required by applications.
+ */
 
 #ifndef _TELSIM_H_
 #define _TELSIM_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
+
 #include <TelDefines.h>
 #include <TapiCommon.h>
 
@@ -43,14 +41,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 /** max length for PIN */
 #define TAPI_SIM_PIN_LENGTH    8
 
@@ -116,7 +106,6 @@ extern "C"
 
 /** SAP APDU max length */
 #define TAPI_SIM_APDU_MAX_LEN 256+2 // to be fine tuned according to lower layers, 2bytes for SW1 & SW2 should be added
-
 /** EF-SMSP digit length */
 #define TAPI_SIM_SMSP_ADDRESS_LEN 20
 
@@ -137,423 +126,400 @@ extern "C"
 
 #define TAPI_SIM_LOCK_TYPE_INFO_MAX  8
 
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
  * @enum TelSimCardType_t
  * This enumeration defines the card type.
  */
-typedef enum
-{
-       TAPI_SIM_CARD_TYPE_UNKNOWN,             /**< Unknown card */
-       TAPI_SIM_CARD_TYPE_GSM,                 /**< SIm(GSM) card*/
-       TAPI_SIM_CARD_TYPE_USIM,                        /**< USIM card */
-
+typedef enum {
+       TAPI_SIM_CARD_TYPE_UNKNOWN, /**< Unknown card */
+       TAPI_SIM_CARD_TYPE_GSM, /**< SIm(GSM) card*/
+       TAPI_SIM_CARD_TYPE_USIM, /**< USIM card */
 } TelSimCardType_t;
 
 /**
  * @enum TelSimFileName_t
  * This enumeration defines the file id.
  */
-typedef enum
-{
-    /* common Elementary files */
-       TAPI_SIM_EFILE_DIR                              = 0x2F00,               /**< Root Directory for the USIM */
-       TAPI_SIM_EFILE_ICCID                    = 0x2FE2,               /**< the ICC Identification file        */
-       TAPI_SIM_EFILE_ADN                      = 0x6F3A,               /**< the Abbrv. Dialing Number file */
-       TAPI_SIM_EFILE_FDN                      = 0x6F3B,               /**< the Fixed Dialing Number file  */
-       TAPI_SIM_EFILE_SMS                      = 0x6F3C,               /**< the Short Messages file      */
-       TAPI_SIM_EFILE_CCP                      = 0x6F3D,               /**< the Capab. Config Parameters file */
-       TAPI_SIM_EFILE_IMSI                     = 0x6F07,               /**< the IMSI file                */
-       TAPI_SIM_EFILE_SST                      = 0x6F38,               /**< the SIM Service Table file   */
-       TAPI_SIM_EFILE_EST                      = 0x6F56,               /**< the Enabled Service Table file   */
-       TAPI_SIM_EFILE_ACM                      = 0x6F39,               /**< the Accumul. Call Meter file */
-       TAPI_SIM_EFILE_OPLMN_ACT        = 0x6F61,               /**< the OPLMN List file*/
-       TAPI_SIM_EFILE_MBDN                     = 0x6FC7,               /** < SIM Mail Box Dialing Number file */
-
-       TAPI_SIM_EFILE_GID1                     = 0x6F3E,               /**< the Group Identifier Level 1 */
-       TAPI_SIM_EFILE_GID2                     = 0x6F3F,               /**< the Group Identifier Level 2 */
+typedef enum {
+       /* common Elementary files */
+       TAPI_SIM_EFILE_DIR = 0x2F00, /**< Root Directory for the USIM */
+       TAPI_SIM_EFILE_ICCID = 0x2FE2, /**< the ICC Identification file */
+       TAPI_SIM_EFILE_ADN = 0x6F3A, /**< the Abbrv. Dialing Number file */
+       TAPI_SIM_EFILE_FDN = 0x6F3B, /**< the Fixed Dialing Number file  */
+       TAPI_SIM_EFILE_SMS = 0x6F3C, /**< the Short Messages file      */
+       TAPI_SIM_EFILE_CCP = 0x6F3D, /**< the Capab. Config Parameters file */
+       TAPI_SIM_EFILE_IMSI = 0x6F07, /**< the IMSI file                */
+       TAPI_SIM_EFILE_SST = 0x6F38, /**< the SIM Service Table file   */
+       TAPI_SIM_EFILE_EST = 0x6F56, /**< the Enabled Service Table file   */
+       TAPI_SIM_EFILE_ACM = 0x6F39, /**< the Accumul. Call Meter file */
+       TAPI_SIM_EFILE_OPLMN_ACT = 0x6F61, /**< the OPLMN List file*/
+       TAPI_SIM_EFILE_MBDN = 0x6FC7, /** < SIM Mail Box Dialing Number file */
+
+       TAPI_SIM_EFILE_GID1 = 0x6F3E, /**< the Group Identifier Level 1 */
+       TAPI_SIM_EFILE_GID2 = 0x6F3F, /**< the Group Identifier Level 2 */
 
        /* For PHASE 2 only */
-       TAPI_SIM_EFILE_MSISDN                   = 0x6F40,               /**< the MSISDN file              */
-       TAPI_SIM_EFILE_SMSP                     = 0x6F42,               /**< the Short Msg Srv. Parameters file*/
-       TAPI_SIM_EFILE_SMSS                     = 0x6F43,               /**< the SMS Status               */
-       TAPI_SIM_EFILE_EXT1                     = 0x6F4A,               /**< the Extension 1 file         */
-       TAPI_SIM_EFILE_EXT2                     = 0x6F4B,               /**< the Extension 2 file         */
-       TAPI_SIM_EFILE_ELP                              = 0x2F05,               /**< the Extended Language Preference file */
-       TAPI_SIM_EFILE_LP                       = 0x6F05,               /**< SIM: Language preference */
-       TAPI_SIM_EFILE_ACM_MAX          = 0x6F37,               /**< the ACM maximum value file   */
-       TAPI_SIM_EFILE_PUCT                     = 0x6F41,               /**< the Price per Unit and. file */
-       TAPI_SIM_EFILE_CBMI                     = 0x6F45,               /**< the Cell Brd msg Id sel file */
-       TAPI_SIM_EFILE_PHASE                    = 0x6FAE,               /**< the PHASE identification file*/
+       TAPI_SIM_EFILE_MSISDN = 0x6F40, /**< the MSISDN file              */
+       TAPI_SIM_EFILE_SMSP = 0x6F42, /**< the Short Msg Srv. Parameters file*/
+       TAPI_SIM_EFILE_SMSS = 0x6F43, /**< the SMS Status               */
+       TAPI_SIM_EFILE_EXT1 = 0x6F4A, /**< the Extension 1 file         */
+       TAPI_SIM_EFILE_EXT2 = 0x6F4B, /**< the Extension 2 file         */
+       TAPI_SIM_EFILE_ELP = 0x2F05, /**< the Extended Language Preference file */
+       TAPI_SIM_EFILE_LP = 0x6F05, /**< SIM: Language preference */
+       TAPI_SIM_EFILE_ACM_MAX = 0x6F37, /**< the ACM maximum value file   */
+       TAPI_SIM_EFILE_PUCT = 0x6F41, /**< the Price per Unit and. file */
+       TAPI_SIM_EFILE_CBMI = 0x6F45, /**< the Cell Brd msg Id sel file */
+       TAPI_SIM_EFILE_PHASE = 0x6FAE, /**< the PHASE identification file*/
 
        /* For Phase 2+ */
-       TAPI_SIM_EFILE_SDN                      = 0x6F49,               /**< the Service Dialing Numbers */
-       TAPI_SIM_EFILE_EXT3                     = 0x6F4C,               /**< the Extension 3 file         */
-       TAPI_SIM_EFILE_BDN                      = 0x6F4D,               /**< the BDN file                 */
-       TAPI_SIM_EFILE_EXT4                     = 0x6F4E,               /**< the Extension 4 file         */
-       TAPI_SIM_EFILE_ECC                      = 0x6FB7,               /**< the Emergency Call Codes     */
-       TAPI_SIM_EFILE_SPN                      = 0x6F46,               /**< the Service Provider Name    */
-       TAPI_SIM_EFILE_SPDI                     = 0x6FCD,               /**< the Service provider display information*/
-       TAPI_SIM_EFILE_PNN                      = 0x6FC5        ,               /**< the PLMN Network Name File*/
-       TAPI_SIM_EFILE_OPL                      = 0x6FC6        ,               /**< the Operator PLMN List File*/
+       TAPI_SIM_EFILE_SDN = 0x6F49, /**< the Service Dialing Numbers */
+       TAPI_SIM_EFILE_EXT3 = 0x6F4C, /**< the Extension 3 file         */
+       TAPI_SIM_EFILE_BDN = 0x6F4D, /**< the BDN file                 */
+       TAPI_SIM_EFILE_EXT4 = 0x6F4E, /**< the Extension 4 file         */
+       TAPI_SIM_EFILE_ECC = 0x6FB7, /**< the Emergency Call Codes     */
+       TAPI_SIM_EFILE_SPN = 0x6F46, /**< the Service Provider Name    */
+       TAPI_SIM_EFILE_SPDI = 0x6FCD, /**< the Service provider display information*/
+       TAPI_SIM_EFILE_PNN = 0x6FC5, /**< the PLMN Network Name File*/
+       TAPI_SIM_EFILE_OPL = 0x6FC6, /**< the Operator PLMN List File*/
 
        /* Contents of files at the DF GRAPHICS level */
-       TAPI_SIM_EFILE_IMG                      = 0x4F20,               /**< image */
+       TAPI_SIM_EFILE_IMG = 0x4F20, /**< image */
 
        /* 4.2 Contents of files at the SIM ADF (Application DF) level */
-       TAPI_SIM_EFILE_USIM_LI                  = 0x6A05,               /**< USIM: Language Indication */
-       TAPI_SIM_EFILE_USIM_PL                  = 0x2A05,       /**< the Language Preference file of USIM */
-       TAPI_SIM_EFILE_USIM_IMSI                        = 0x6A07,       /**< IMSI */
-       TAPI_SIM_EFILE_USIM_ACM_MAX             = 0x6A37,       /**< ACM maximum value */
-       TAPI_SIM_EFILE_USIM_UST                 = 0x6A38,       /**< USIM Service Table */
-       TAPI_SIM_EFILE_USIM_ACM                 = 0x6A39,       /**< Accumulated Call Meter */
-       TAPI_SIM_EFILE_USIM_SPN                 = 0x6A46,       /**< Service Provider Name */
-       TAPI_SIM_EFILE_USIM_PUCT                        = 0x6A41,       /**< Price per Unit and Currency Table */
-       TAPI_SIM_EFILE_USIM_CBMI                        = 0x6A45,       /**< Cell Broadcaster Message Identifier selection */
-       TAPI_SIM_EFILE_USIM_ECC                 = 0x6AB7,       /**< Emergency Call Codes */
-       TAPI_SIM_EFILE_USIM_FDN                 = 0x6A3B,       /**< Fixed Dialing Number */
-       TAPI_SIM_EFILE_USIM_SMS                 = 0x6A3C,       /**< SMS */
-       TAPI_SIM_EFILE_USIM_MSISDN              = 0x6A40,       /**< My own number */
-       TAPI_SIM_EFILE_USIM_SMSP                        = 0x6A42,       /** < SMS parameter */
-       TAPI_SIM_EFILE_USIM_SMSS                        = 0x6A43,       /** < SMS status */
-       TAPI_SIM_EFILE_USIM_SDN                 = 0x6A49,       /** < Service dialing number */
-       TAPI_SIM_EFILE_USIM_EXT1                        = 0X6A4A,       /** < EXT1 record file */
-       TAPI_SIM_EFILE_USIM_EXT2                        = 0x6A4B,       /** < EXT2 record file */
-       TAPI_SIM_EFILE_USIM_EXT3                        = 0x6A4C,       /** < EXT3 record file */
-       TAPI_SIM_EFILE_USIM_EXT4                        = 0x6A55,       /** < EXT4 record file */
-       TAPI_SIM_EFILE_USIM_EXT5                        = 0x6A4E,       /** < EXT5 record file */
-       TAPI_SIM_EFILE_USIM_EXT6                        = 0x6FC8,       /** < EXT6 record file */
-       TAPI_SIM_EFILE_USIM_EXT7                        = 0x6FCC,       /** < EXT7 record file */
-
-       TAPI_SIM_EFILE_USIM_CCP2                        = 0x6A4F,       /**< Capability Configuration Parameters 2 */
-       TAPI_SIM_EFILE_USIM_HIDDEN_KEY  = 0x6FC3,       /**< Key for hidden phonebook entries */
-       TAPI_SIM_EFILE_USIM_BDN                 = 0x6A4D,       /**< Barred Dialing Numbers */
-
-       TAPI_SIM_EFILE_USIM_MBDN                        = 0x6FC7,       /** < Mailbox dialing number -linear fixed*/
-       TAPI_SIM_EFILE_USIM_MBI                 = 0x6FC9,       /** < Mailbox Identifier -linear fixed*/
-
-       TAPI_SIM_EFILE_USIM_MWIS                        = 0x6FCA,       /** < Message Waiting Indication Status -linear fixed*/
-       TAPI_SIM_EFILE_USIM_CFIS                        = 0x6FCB,       /** < Call forward indication status -linear fixed*/
-
-       TAPI_SIM_EFILE_USIM_APN_ACL             = 0x6F57,       /** < Access point name control list */
+       TAPI_SIM_EFILE_USIM_LI = 0x6A05, /**< USIM: Language Indication */
+       TAPI_SIM_EFILE_USIM_PL = 0x2A05, /**< the Language Preference file of USIM */
+       TAPI_SIM_EFILE_USIM_IMSI = 0x6A07, /**< IMSI */
+       TAPI_SIM_EFILE_USIM_ACM_MAX = 0x6A37, /**< ACM maximum value */
+       TAPI_SIM_EFILE_USIM_UST = 0x6A38, /**< USIM Service Table */
+       TAPI_SIM_EFILE_USIM_ACM = 0x6A39, /**< Accumulated Call Meter */
+       TAPI_SIM_EFILE_USIM_SPN = 0x6A46, /**< Service Provider Name */
+       TAPI_SIM_EFILE_USIM_PUCT = 0x6A41, /**< Price per Unit and Currency Table */
+       TAPI_SIM_EFILE_USIM_CBMI = 0x6A45, /**< Cell Broadcaster Message Identifier selection */
+       TAPI_SIM_EFILE_USIM_ECC = 0x6AB7, /**< Emergency Call Codes */
+       TAPI_SIM_EFILE_USIM_FDN = 0x6A3B, /**< Fixed Dialing Number */
+       TAPI_SIM_EFILE_USIM_SMS = 0x6A3C, /**< SMS */
+       TAPI_SIM_EFILE_USIM_MSISDN = 0x6A40, /**< My own number */
+       TAPI_SIM_EFILE_USIM_SMSP = 0x6A42, /** < SMS parameter */
+       TAPI_SIM_EFILE_USIM_SMSS = 0x6A43, /** < SMS status */
+       TAPI_SIM_EFILE_USIM_SDN = 0x6A49, /** < Service dialing number */
+       TAPI_SIM_EFILE_USIM_EXT1 = 0X6A4A, /** < EXT1 record file */
+       TAPI_SIM_EFILE_USIM_EXT2 = 0x6A4B, /** < EXT2 record file */
+       TAPI_SIM_EFILE_USIM_EXT3 = 0x6A4C, /** < EXT3 record file */
+       TAPI_SIM_EFILE_USIM_EXT4 = 0x6A55, /** < EXT4 record file */
+       TAPI_SIM_EFILE_USIM_EXT5 = 0x6A4E, /** < EXT5 record file */
+       TAPI_SIM_EFILE_USIM_EXT6 = 0x6FC8, /** < EXT6 record file */
+       TAPI_SIM_EFILE_USIM_EXT7 = 0x6FCC, /** < EXT7 record file */
+
+       TAPI_SIM_EFILE_USIM_CCP2 = 0x6A4F, /**< Capability Configuration Parameters 2 */
+       TAPI_SIM_EFILE_USIM_HIDDEN_KEY = 0x6FC3, /**< Key for hidden phonebook entries */
+       TAPI_SIM_EFILE_USIM_BDN = 0x6A4D, /**< Barred Dialing Numbers */
+
+       TAPI_SIM_EFILE_USIM_MBDN = 0x6FC7, /** < Mailbox dialing number -linear fixed*/
+       TAPI_SIM_EFILE_USIM_MBI = 0x6FC9, /** < Mailbox Identifier -linear fixed*/
+
+       TAPI_SIM_EFILE_USIM_MWIS = 0x6FCA, /** < Message Waiting Indication Status -linear fixed*/
+       TAPI_SIM_EFILE_USIM_CFIS = 0x6FCB, /** < Call forward indication status -linear fixed*/
+
+       TAPI_SIM_EFILE_USIM_APN_ACL = 0x6F57, /** < Access point name control list */
 
        /* Contents of files at USIM ADF PHONEBOOK level */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBR       = 0x4FF0,       /**< Phonebook Reference File */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_CCP1      = 0x4FFE,       /**< Capability Configuration Parameters 1 */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_UID       = 0x4FF8,       /**< unique identifier */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_PSC       = 0x4FFF,       /**< phonebook synchronization counter */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_CC        = 0x4FEF,       /**< change counter */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_PUID      = 0x4FEE,       /**< previous unique identifier */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ADN       = 0x4FF1,       /**< Abbreviated Dialing Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_IAP       = 0x4FF2,       /**< Index Administration Phonebook */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBC       = 0x4FF3,       /**< Phonebook Control */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_EXT1      = 0x4FFB,       /**< Extension 1 */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_GRP       = 0x4FF7,       /**< Grouping File */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_AAS       = 0x4FFC,       /**< Additional number Alpha String */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_AAS1      = 0x4FFD,       /**< Additional number Alpha String */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_GAS       = 0x4F0E,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_GAS1      = 0x4F0F,       /**< Second Name Entry */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANR       = 0x4FF4,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_SNE       = 0x4FF9,       /**< Second Name Entry */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_EMAIL     = 0x4FFA,       /**< e-mail address */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRA      = 0x4F13,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRB      = 0x4F14,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRC      = 0x4F15,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANR1      = 0x4F16,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRA1     = 0x4F17,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRB1     = 0x4F18,       /**< Additional Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRC1     = 0x4F21,       /**< Additional Number */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_ADN1      = 0x4F1A,       /**< Abbreviated Dialing Number */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBC1      = 0x4F1B,       /**< Phonebook Control */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_GRP1      = 0x4F1C,       /**< Grouping File */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_SNE1      = 0x4F1D,       /**< Second Name Entry */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_UID1      = 0x4F1E,       /**< unique identifier */
-
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_EMAIL1    = 0x4F1F,       /**< e-mail address */
-       TAPI_SIM_EFILE_USIM_PHONEBOOK_IAP1      = 0x4FF5,       /**< Index Administration Phonebook */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBR = 0x4FF0, /**< Phonebook Reference File */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_CCP1 = 0x4FFE, /**< Capability Configuration Parameters 1 */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_UID = 0x4FF8, /**< unique identifier */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_PSC = 0x4FFF, /**< phonebook synchronization counter */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_CC = 0x4FEF, /**< change counter */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_PUID = 0x4FEE, /**< previous unique identifier */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ADN = 0x4FF1, /**< Abbreviated Dialing Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_IAP = 0x4FF2, /**< Index Administration Phonebook */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBC = 0x4FF3, /**< Phonebook Control */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_EXT1 = 0x4FFB, /**< Extension 1 */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_GRP = 0x4FF7, /**< Grouping File */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_AAS = 0x4FFC, /**< Additional number Alpha String */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_AAS1 = 0x4FFD, /**< Additional number Alpha String */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_GAS = 0x4F0E, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_GAS1 = 0x4F0F, /**< Second Name Entry */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANR = 0x4FF4, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_SNE = 0x4FF9, /**< Second Name Entry */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_EMAIL = 0x4FFA, /**< e-mail address */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRA = 0x4F13, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRB = 0x4F14, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRC = 0x4F15, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANR1 = 0x4F16, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRA1 = 0x4F17, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRB1 = 0x4F18, /**< Additional Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ANRC1 = 0x4F21, /**< Additional Number */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_ADN1 = 0x4F1A, /**< Abbreviated Dialing Number */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_PBC1 = 0x4F1B, /**< Phonebook Control */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_GRP1 = 0x4F1C, /**< Grouping File */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_SNE1 = 0x4F1D, /**< Second Name Entry */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_UID1 = 0x4F1E, /**< unique identifier */
+
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_EMAIL1 = 0x4F1F, /**< e-mail address */
+       TAPI_SIM_EFILE_USIM_PHONEBOOK_IAP1 = 0x4FF5, /**< Index Administration Phonebook */
 
        /* Contents of files at TELECOM DF PHONEBOOK level */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR            = 0x4F30,       /**< Phonebook Reference File */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR1           = 0x4F29,       /**< Phonebook Reference File 1 */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR2           = 0x4F28,       /**< Phonebook Reference File 1 */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_CCP1           = 0x4F3D,       /**< Capability Configuration Parameters 1 */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_UID            = 0x4F00,       /**< unique identifier */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PSC            = 0x4F22,       /**< Phonebook synchronization counter */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_CC             = 0x4F23,       /**< change counter */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PUID           = 0x4F24,       /**< previous unique identifier */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ADN            = 0x4F3A,       /**< Abbreviated Dialing Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_IAP            = 0x4F25,       /**< Index Administration Phonebook */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBC            = 0x4F09,       /**< Phonebook Control */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EXT1           = 0x4F4A,       /**< Extension 1 */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GRP            = 0x4F26,       /**< Grouping File */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_AAS            = 0x4F4B,       /**< Additional number Alpha String */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GAS            = 0x4F4C,       /**< Additional Number */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANR            = 0x4F11,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_SNE            = 0x4F19,       /**< Second Name Entry */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EMAIL          = 0x4F50,       /**< e-mail address */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRA           = 0x4F31,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRB           = 0x4F32,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRC           = 0x4F40,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANR1           = 0x4F33,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRA1  = 0x4F34,       /**< Additional Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRB1  = 0x4F35,       /**< Additional Number */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ADN1           = 0x4F36,       /**< Abbreviated Dialing Number */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBC1           = 0x4F37,       /**< Phonebook Control */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GRP1           = 0x4F38,       /**< Grouping File */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_SNE1           = 0x4F39,       /**< Second Name Entry */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_UID1           = 0x4F3B,       /**< unique identifier */
-
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EMAIL1 = 0x4F3C,       /**< e-mail address */
-       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_IAP1           = 0x4F3E,       /**< Index Administration Phonebook */
-
-       TAPI_SIM_EFILE_MSG_WAITING_INDICATION_STATUS                    =0x6FCA,                /** < MSG waiting indication  *///WILL BE REMOVED
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR = 0x4F30, /**< Phonebook Reference File */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR1 = 0x4F29, /**< Phonebook Reference File 1 */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBR2 = 0x4F28, /**< Phonebook Reference File 1 */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_CCP1 = 0x4F3D, /**< Capability Configuration Parameters 1 */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_UID = 0x4F00, /**< unique identifier */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PSC = 0x4F22, /**< Phonebook synchronization counter */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_CC = 0x4F23, /**< change counter */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PUID = 0x4F24, /**< previous unique identifier */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ADN = 0x4F3A, /**< Abbreviated Dialing Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_IAP = 0x4F25, /**< Index Administration Phonebook */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBC = 0x4F09, /**< Phonebook Control */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EXT1 = 0x4F4A, /**< Extension 1 */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GRP = 0x4F26, /**< Grouping File */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_AAS = 0x4F4B, /**< Additional number Alpha String */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GAS = 0x4F4C, /**< Additional Number */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANR = 0x4F11, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_SNE = 0x4F19, /**< Second Name Entry */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EMAIL = 0x4F50, /**< e-mail address */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRA = 0x4F31, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRB = 0x4F32, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRC = 0x4F40, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANR1 = 0x4F33, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRA1 = 0x4F34, /**< Additional Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ANRB1 = 0x4F35, /**< Additional Number */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_ADN1 = 0x4F36, /**< Abbreviated Dialing Number */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_PBC1 = 0x4F37, /**< Phonebook Control */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_GRP1 = 0x4F38, /**< Grouping File */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_SNE1 = 0x4F39, /**< Second Name Entry */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_UID1 = 0x4F3B, /**< unique identifier */
+
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_EMAIL1 = 0x4F3C, /**< e-mail address */
+       TAPI_SIM_EFILE_TELECOM_PHONEBOOK_IAP1 = 0x4F3E, /**< Index Administration Phonebook */
+
+       TAPI_SIM_EFILE_MSG_WAITING_INDICATION_STATUS = 0x6FCA, /** < MSG waiting indication  */ //WILL BE REMOVED
 
        /* CPHS FILE ID */
-       TAPI_SIM_EFILE_CPHS_VOICE_MSG_WAITING                                   = 0x6F11,       /** < CPHS voice MSG waiting indication  */
-       TAPI_SIM_EFILE_CPHS_SERVICE_STRING_TABLE                                = 0x6F12,       /** < CPHS service string table  */
-       TAPI_SIM_EFILE_CPHS_CALL_FORWARD_FLAGS                          = 0x6F13,               /** < CPHS call forward flags  */
-       TAPI_SIM_EFILE_CPHS_OPERATOR_NAME_STRING                                = 0x6F14,       /** < CPHS operator name string  */
-       TAPI_SIM_EFILE_CPHS_CUSTOMER_SERVICE_PROFILE                    = 0x6F15,       /** < CPHS customer service profile  */
-       TAPI_SIM_EFILE_CPHS_CPHS_INFO                                                   = 0x6F16,       /** < CPHS information  */
-       TAPI_SIM_EFILE_CPHS_MAILBOX_NUMBERS                                     = 0x6F17,       /** < CPHS mail box numbers  */
-       TAPI_SIM_EFILE_CPHS_OPERATOR_NAME_SHORT_FORM_STRING     = 0x6F18,       /** < CPHS operator name short form string  */
-       TAPI_SIM_EFILE_CPHS_INFORMATION_NUMBERS                         = 0x6F19,       /** < CPHS information numbers  */
+       TAPI_SIM_EFILE_CPHS_VOICE_MSG_WAITING = 0x6F11, /** < CPHS voice MSG waiting indication  */
+       TAPI_SIM_EFILE_CPHS_SERVICE_STRING_TABLE = 0x6F12, /** < CPHS service string table  */
+       TAPI_SIM_EFILE_CPHS_CALL_FORWARD_FLAGS = 0x6F13, /** < CPHS call forward flags  */
+       TAPI_SIM_EFILE_CPHS_OPERATOR_NAME_STRING = 0x6F14, /** < CPHS operator name string  */
+       TAPI_SIM_EFILE_CPHS_CUSTOMER_SERVICE_PROFILE = 0x6F15, /** < CPHS customer service profile  */
+       TAPI_SIM_EFILE_CPHS_CPHS_INFO = 0x6F16, /** < CPHS information  */
+       TAPI_SIM_EFILE_CPHS_MAILBOX_NUMBERS = 0x6F17, /** < CPHS mail box numbers  */
+       TAPI_SIM_EFILE_CPHS_OPERATOR_NAME_SHORT_FORM_STRING = 0x6F18, /** < CPHS operator name short form string  */
+       TAPI_SIM_EFILE_CPHS_INFORMATION_NUMBERS = 0x6F19, /** < CPHS information numbers  */
 
        /*  CPHS ALS FILE ID */
-       TAPI_SIM_CPHS_DYNAMICFLAGS                                                              = 0x6F9F,       /** < CPHS Dynamics flags  */
-       TAPI_SIM_CPHS_DYNAMIC2FLAG                                                              = 0x6F92,       /** < CPHS Dynamics2 flags  */
-       TAPI_SIM_CPHS_CUSTOMER_SERVICE_PROFILE_LINE2                    = 0x6F98,       /** < CPHS CSP2  */
+       TAPI_SIM_CPHS_DYNAMICFLAGS = 0x6F9F, /** < CPHS Dynamics flags  */
+       TAPI_SIM_CPHS_DYNAMIC2FLAG = 0x6F92, /** < CPHS Dynamics2 flags  */
+       TAPI_SIM_CPHS_CUSTOMER_SERVICE_PROFILE_LINE2 = 0x6F98, /** < CPHS CSP2  */
 
        /* ISIM files */
-       TAPI_SIM_EFILE_ISIM_IMPI                = 0x6F02,               /** < IMS private user identity   */
-       TAPI_SIM_EFILE_ISIM_DOMAIN      = 0x6F03,               /** < IMS Home Network Domain Name   */
-       TAPI_SIM_EFILE_ISIM_IMPU                = 0x6F04,               /** < IMS public user identity    */
-       TAPI_SIM_EFILE_ISIM_AD          = 0x6FAD,               /** < Administrative data     */  /* NOT implemented */
-       TAPI_SIM_EFILE_ISIM_ARR         = 0x6F06,               /** < Access control file     */  /* NOT implemented */
-
-       /* ID clashes with IMSI file Id so changed to  6FFF - actual Id is 0x6F07 */ /* modem no support ?*/
-       TAPI_SIM_EFILE_ISIM_IST         = 0x6FFF,               /** <ISIM keys     */
-       TAPI_SIM_EFILE_ISIM_KEYS                = 0x6F08,               /** < Access control file     */
-       TAPI_SIM_EFILE_ISIM_PCSCF               = 0x6F09,               /** < PCSCF address     */
-       TAPI_SIM_EFILE_ISIM_GBABP       = 0x6FD5,               /* support from IPC - NO RSIM access */
+       TAPI_SIM_EFILE_ISIM_IMPI = 0x6F02, /** < IMS private user identity   */
+       TAPI_SIM_EFILE_ISIM_DOMAIN = 0x6F03, /** < IMS Home Network Domain Name   */
+       TAPI_SIM_EFILE_ISIM_IMPU = 0x6F04, /** < IMS public user identity    */
+       TAPI_SIM_EFILE_ISIM_AD = 0x6FAD, /** < Administrative data     *//* NOT implemented */
+       TAPI_SIM_EFILE_ISIM_ARR = 0x6F06, /** < Access control file     *//* NOT implemented */
+
+       /* ID clashes with IMSI file Id so changed to  6FFF - actual Id is 0x6F07 *//* modem no support ?*/
+       TAPI_SIM_EFILE_ISIM_IST = 0x6FFF, /** <ISIM keys     */
+       TAPI_SIM_EFILE_ISIM_KEYS = 0x6F08, /** < Access control file     */
+       TAPI_SIM_EFILE_ISIM_PCSCF = 0x6F09, /** < PCSCF address     */
+       TAPI_SIM_EFILE_ISIM_GBABP = 0x6FD5, /* support from IPC - NO RSIM access */
 
        /* Root Certificates */
-       TAPI_SIM_EFILE_CA_TOKENINFO     = 0x5032,
-       TAPI_SIM_EFILE_CA_ODF           = 0x5031,
-       TAPI_SIM_EFILE_CA_CDFTRUSTED    = 0x4404,
-       TAPI_SIM_EFILE_CA_TRUSTCERT1    = 0x4424,
-       TAPI_SIM_EFILE_CA_TRUSTCERT2    = 0x4425,
-       TAPI_SIM_EFILE_CA_TRUSTCERT3    = 0x4426,
-       TAPI_SIM_EFILE_CA_DODFPROV      = 0x4407,
-       TAPI_SIM_EFILE_CA_BOOTSTRAP     = 0x4440,
-       TAPI_SIM_EFILE_CA_CONFIG1       = 0x4441,
+       TAPI_SIM_EFILE_CA_TOKENINFO = 0x5032,
+       TAPI_SIM_EFILE_CA_ODF = 0x5031,
+       TAPI_SIM_EFILE_CA_CDFTRUSTED = 0x4404,
+       TAPI_SIM_EFILE_CA_TRUSTCERT1 = 0x4424,
+       TAPI_SIM_EFILE_CA_TRUSTCERT2 = 0x4425,
+       TAPI_SIM_EFILE_CA_TRUSTCERT3 = 0x4426,
+       TAPI_SIM_EFILE_CA_DODFPROV = 0x4407,
+       TAPI_SIM_EFILE_CA_BOOTSTRAP = 0x4440,
+       TAPI_SIM_EFILE_CA_CONFIG1 = 0x4441,
 
        /* Invalid File ID, All the file ID are less than this Value*/
-       TAPI_SIM_EFILE_INVALID          =0xFFFF,                /**< Invalid file.*/
-       TAPI_SIM_EFILE_OTHERS   ,                                       /**< Element to indicate an unknown file.*/
-
+       TAPI_SIM_EFILE_INVALID = 0xFFFF, /**< Invalid file.*/
+       TAPI_SIM_EFILE_OTHERS, /**< Element to indicate an unknown file.*/
 } TelSimFileName_t;
 
 /**
  * @enum TelSimPinStatus_t
  * This enumeration defines the pin status.
  */
-typedef enum
-{
-       TAPI_SIM_PIN_STATUS_DISABLED            = 0x00,         /**< Pin1 or Pin2 Disabled */
-       TAPI_SIM_PIN_STATUS_ENABLED                     = 0x01,         /**< Pin1 or Pin2 Enabled */
-       TAPI_SIM_PIN_STATUS_BLOCKED                     = 0x02,         /**< SIM is present, but PIN1 or PIN2  is blocked. need unblocking by PUK or PUK2 */
-       TAPI_SIM_PIN_STATUS_PUK_BLOCKED         = 0x03,         /**< SIM is present, but PUK is blocked. */
-       TAPI_SIM_PIN_STATUS_UNKNOWN             = 0xFF          /**< SIM is in unknown state */
-
+typedef enum {
+       TAPI_SIM_PIN_STATUS_DISABLED = 0x00, /**< Pin1 or Pin2 Disabled */
+       TAPI_SIM_PIN_STATUS_ENABLED = 0x01, /**< Pin1 or Pin2 Enabled */
+       TAPI_SIM_PIN_STATUS_BLOCKED = 0x02, /**< SIM is present, but PIN1 or PIN2  is blocked. need unblocking by PUK or PUK2 */
+       TAPI_SIM_PIN_STATUS_PUK_BLOCKED = 0x03, /**< SIM is present, but PUK is blocked. */
+       TAPI_SIM_PIN_STATUS_UNKNOWN = 0xFF /**< SIM is in unknown state */
 } TelSimPinStatus_t;
 
 /**
  * @enum TelSimPinOperationResult_t
  * This enumeration defines the pin operation result from the lower layers.
  */
-typedef enum
-{
-       TAPI_SIM_PIN_OPERATION_SUCCESS,                 /**< Operation involving PIN (verification/change/enable/disable, etc) is successful.  */
-       TAPI_SIM_BUSY,                                                          /**< SIM is busy  */
-       TAPI_SIM_CARD_ERROR,                                            /**< SIM card error - Permanently blocked and general errors   */
-       TAPI_SIM_INCOMPATIBLE_PIN_OPERATION,    /**< SIM Incompatible pin operation that is in case when invalid SIM command is given or incorrect parameters are supplied to the SIM. */
-       TAPI_SIM_PIN_INCORRECT_PASSWORD,                /**< SIM PIN  Incorrect password */
-       TAPI_SIM_PUK_INCORRECT_PASSWORD,                /**< SIM PUK Incorrect Password */
-       TAPI_SIM_PUK_REQUIRED,                                  /**< PUK Required */
-       TAPI_SIM_PIN_REQUIRED   ,                                       /**< PIN Required */
-       TAPI_SIM_NCK_REQUIRED,                                  /**< Network Control Key Required */
-       TAPI_SIM_NSCK_REQUIRED,                                 /**< Network Subset Control Key Required */
-       TAPI_SIM_SPCK_REQUIRED,                                 /**< Service Provider Control Key Required */
-       TAPI_SIM_CCK_REQUIRED,                                  /**< Corporate Control Key Required */
-       TAPI_SIM_LOCK_REQUIRED,                                 /**<  PH-SIM (phone-SIM) locked state **/
-
-}TelSimPinOperationResult_t;
+typedef enum {
+       TAPI_SIM_PIN_OPERATION_SUCCESS, /**< Operation involving PIN (verification/change/enable/disable, etc) is successful.  */
+       TAPI_SIM_BUSY, /**< SIM is busy  */
+       TAPI_SIM_CARD_ERROR, /**< SIM card error - Permanently blocked and general errors   */
+       TAPI_SIM_INCOMPATIBLE_PIN_OPERATION, /**< SIM Incompatible pin operation that is in case when invalid SIM command is given or incorrect parameters are supplied to the SIM. */
+       TAPI_SIM_PIN_INCORRECT_PASSWORD, /**< SIM PIN  Incorrect password */
+       TAPI_SIM_PUK_INCORRECT_PASSWORD, /**< SIM PUK Incorrect Password */
+       TAPI_SIM_PUK_REQUIRED, /**< PUK Required */
+       TAPI_SIM_PIN_REQUIRED, /**< PIN Required */
+       TAPI_SIM_NCK_REQUIRED, /**< Network Control Key Required */
+       TAPI_SIM_NSCK_REQUIRED, /**< Network Subset Control Key Required */
+       TAPI_SIM_SPCK_REQUIRED, /**< Service Provider Control Key Required */
+       TAPI_SIM_CCK_REQUIRED, /**< Corporate Control Key Required */
+       TAPI_SIM_LOCK_REQUIRED, /**<  PH-SIM (phone-SIM) locked state **/
+} TelSimPinOperationResult_t;
 
 /**
  * @enum TelSimAccessResult_t
  * This enumeration defines the SIM access result from the lower layers.
  */
-typedef enum
-{
-       TAPI_SIM_ACCESS_SUCCESS,                                                                /**< Access to file successful.  */
-       TAPI_SIM_ACCESS_CARD_ERROR,                                                     /**< SIM card error    */
-       TAPI_SIM_ACCESS_FILE_NOT_FOUND,                                         /**< File not found  */
-       TAPI_SIM_ACCESS_ACCESS_CONDITION_NOT_SATISFIED, /**< Access condition is not fulfilled  */
-       TAPI_SIM_ACCESS_FAILED,                                                         /**< Access failed.  */
-
-}TelSimAccessResult_t;
+typedef enum {
+       TAPI_SIM_ACCESS_SUCCESS, /**< Access to file successful.  */
+       TAPI_SIM_ACCESS_CARD_ERROR, /**< SIM card error    */
+       TAPI_SIM_ACCESS_FILE_NOT_FOUND, /**< File not found  */
+       TAPI_SIM_ACCESS_ACCESS_CONDITION_NOT_SATISFIED, /**< Access condition is not fulfilled  */
+       TAPI_SIM_ACCESS_FAILED, /**< Access failed.  */
+} TelSimAccessResult_t;
 
 /**
  * @enum TelSimPinType_t
  * This enumeration defines the pin type.
  */
-typedef enum
-{
-    TAPI_SIM_PTYPE_PIN1                = 0x00,         /**< PIN 1 code */
-    TAPI_SIM_PTYPE_PIN2                = 0x01,         /**< PIN 2 code */
-    TAPI_SIM_PTYPE_PUK1        = 0x02,         /**< PUK 1 code */
-    TAPI_SIM_PTYPE_PUK2        = 0x03,         /**< PUK 2 code */
-    TAPI_SIM_PTYPE_UPIN               = 0x04,          /**< Universal PIN - Unused now */
-    TAPI_SIM_PTYPE_ADM         = 0x05,         /**< Administrator - Unused now */
-    TAPI_SIM_PTYPE_SIM         = 0x06          /**< SIM Lock code */
+typedef enum {
+       TAPI_SIM_PTYPE_PIN1 = 0x00, /**< PIN 1 code */
+       TAPI_SIM_PTYPE_PIN2 = 0x01, /**< PIN 2 code */
+       TAPI_SIM_PTYPE_PUK1 = 0x02, /**< PUK 1 code */
+       TAPI_SIM_PTYPE_PUK2 = 0x03, /**< PUK 2 code */
+       TAPI_SIM_PTYPE_UPIN = 0x04, /**< Universal PIN - Unused now */
+       TAPI_SIM_PTYPE_ADM = 0x05, /**< Administrator - Unused now */
+       TAPI_SIM_PTYPE_SIM = 0x06 /**< SIM Lock code */
 } TelSimPinType_t;
 
 /**
-* @enum TelSimPersType_t
-*      This structure gives security lock type information enum values
-*/
-typedef enum
-{
-       TAPI_SIM_PERS_NET               = 0x00, /**< Network Lock */
-       TAPI_SIM_PERS_NS                = 0x01, /**< Network Subset Lock */
-       TAPI_SIM_PERS_SP                = 0x02, /**< Service Provider Lock */
-       TAPI_SIM_PERS_CP                = 0x03, /**< Corporate Lock */
+ * @enum TelSimPersType_t
+ *     This structure gives security lock type information enum values
+ */
+typedef enum {
+       TAPI_SIM_PERS_NET = 0x00, /**< Network Lock */
+       TAPI_SIM_PERS_NS = 0x01, /**< Network Subset Lock */
+       TAPI_SIM_PERS_SP = 0x02, /**< Service Provider Lock */
+       TAPI_SIM_PERS_CP = 0x03, /**< Corporate Lock */
 } TelSimPersType_t;
 
 /**
  * @enum TelSimTypeOfNum_t
  * This enumeration defines the type of number.
  */
-typedef enum
-{
-       TAPI_SIM_TON_UNKNOWN                            = 0,            /**< unknown */
-       TAPI_SIM_TON_INTERNATIONAL                      = 1,            /**< international number */
-       TAPI_SIM_TON_NATIONAL                           = 2,            /**< national number */
-       TAPI_SIM_TON_NETWORK_SPECIFIC           = 3,            /**< network specific number */
-       TAPI_SIM_TON_DEDICATED_ACCESS           = 4,            /**< subscriber number */
-       TAPI_SIM_TON_ALPHA_NUMERIC                      = 5,            /**< alphanumeric, GSM 7-bit default alphabet) */
-       TAPI_SIM_TON_ABBREVIATED_NUMBER = 6,            /**< abbreviated number */
-       TAPI_SIM_TON_RESERVED_FOR_EXT           = 7             /**< reserved for extension */
+typedef enum {
+       TAPI_SIM_TON_UNKNOWN = 0, /**< unknown */
+       TAPI_SIM_TON_INTERNATIONAL = 1, /**< international number */
+       TAPI_SIM_TON_NATIONAL = 2, /**< national number */
+       TAPI_SIM_TON_NETWORK_SPECIFIC = 3, /**< network specific number */
+       TAPI_SIM_TON_DEDICATED_ACCESS = 4, /**< subscriber number */
+       TAPI_SIM_TON_ALPHA_NUMERIC = 5, /**< alphanumeric, GSM 7-bit default alphabet) */
+       TAPI_SIM_TON_ABBREVIATED_NUMBER = 6, /**< abbreviated number */
+       TAPI_SIM_TON_RESERVED_FOR_EXT = 7 /**< reserved for extension */
 } TelSimTypeOfNum_t;
 
 /**
-*  @enum TelSimTextEncrypt_t
-*   This enumeration defines the text encryption types
-*/
-typedef enum
-{
-       TAPI_SIM_TEXT_ENC_ASCII,                /**< ASCII Encoding */
-       TAPI_SIM_TEXT_ENC_GSM7BIT,      /**< GSM 7 Bit Encoding */
-       TAPI_SIM_TEXT_ENC_UCS2,         /**< UCS2 Encoding */
-       TAPI_SIM_TEXT_ENC_HEX,          /**< HEX Encoding */
-}TelSimTextEncrypt_t;
+ *  @enum TelSimTextEncrypt_t
+ *   This enumeration defines the text encryption types
+ */
+typedef enum {
+       TAPI_SIM_TEXT_ENC_ASCII, /**< ASCII Encoding */
+       TAPI_SIM_TEXT_ENC_GSM7BIT, /**< GSM 7 Bit Encoding */
+       TAPI_SIM_TEXT_ENC_UCS2, /**< UCS2 Encoding */
+       TAPI_SIM_TEXT_ENC_HEX, /**< HEX Encoding */
+} TelSimTextEncrypt_t;
 
 /**
-* @enum TelSimPbFileType_t
-* This enumeration defines  different storage types to be selected in SIM or USIM
-*/
-typedef enum
-{
-       TAPI_SIM_PB_FDN,                                /**< Fixed Dialing Number */
-       TAPI_SIM_PB_LDN,                                /**< last dialed number  - WILL BE REMOVED */
-       TAPI_SIM_PB_MSISDN,                     /**< my own number - MSISDN list */
-       TAPI_SIM_PB_ADN,                                /**< SIM - ADN   */
-       TAPI_SIM_PB_SDN,                             /**< Service Dialing Number  */
-       TAPI_SIM_PB_EN,                         /**< Emergency number  - WILL BE REMOVED*/
-       TAPI_SIM_PB_3GSIM,                      /**< USIM - 3G phone book */
-       TAPI_SIM_PB_AAS,                                /**< Additional number Alpha String */
-       TAPI_SIM_PB_GAS,                                /**< Grouping identifier Alpha String */
-       TAPI_SIM_PB_UNKNOWNN = 0xFF,    /**< Unknown file type */
-}TelSimPbFileType_t;
+ * @enum TelSimPbFileType_t
+ * This enumeration defines  different storage types to be selected in SIM or USIM
+ */
+typedef enum {
+       TAPI_SIM_PB_FDN, /**< Fixed Dialing Number */
+       TAPI_SIM_PB_LDN, /**< last dialed number  - WILL BE REMOVED */
+       TAPI_SIM_PB_MSISDN, /**< my own number - MSISDN list */
+       TAPI_SIM_PB_ADN, /**< SIM - ADN  */
+       TAPI_SIM_PB_SDN, /**< Service Dialing Number  */
+       TAPI_SIM_PB_EN, /**< Emergency number  - WILL BE REMOVED*/
+       TAPI_SIM_PB_3GSIM, /**< USIM - 3G phone book */
+       TAPI_SIM_PB_AAS, /**< Additional number Alpha String */
+       TAPI_SIM_PB_GAS, /**< Grouping identifier Alpha String */
+       TAPI_SIM_PB_UNKNOWNN = 0xFF, /**< Unknown file type */
+} TelSimPbFileType_t;
 
 /**
  * @enum tapi_pb_storage_field_tag_type_t
-*  This enumeration defines the different storage field types in 3G Phone book.
-*/
-typedef enum
-{
+ *  This enumeration defines the different storage field types in 3G Phone book.
+ */
+typedef enum {
        /* for 3G phone storage field type */
-       TAPI_PB_3G_NAME         = 0x01,         /**< Name */
-       TAPI_PB_3G_NUMBER,                              /**< Number */
-       TAPI_PB_3G_ANR,                                 /**< Another number */
-       TAPI_PB_3G_EMAIL,                                       /**< Email */
-       TAPI_PB_3G_SNE,                                 /**< Second name entry */
-       TAPI_PB_3G_GRP,                                 /**< Group file */
-       TAPI_PB_3G_PBC,                                 /** <1 byte control info and 1 byte hidden info*/
-       TAPI_PB_3G_ANRA,                                        /**< Another number */
-       TAPI_PB_3G_ANRB,                                        /**< Another number */
-}TelSimPb3GFileType_t;
+       TAPI_PB_3G_NAME = 0x01, /**< Name */
+       TAPI_PB_3G_NUMBER, /**< Number */
+       TAPI_PB_3G_ANR, /**< Another number */
+       TAPI_PB_3G_EMAIL, /**< Email */
+       TAPI_PB_3G_SNE, /**< Second name entry */
+       TAPI_PB_3G_GRP, /**< Group file */
+       TAPI_PB_3G_PBC, /** <1 byte control info and 1 byte hidden info*/
+       TAPI_PB_3G_ANRA, /**< Another number */
+       TAPI_PB_3G_ANRB, /**< Another number */
+} TelSimPb3GFileType_t;
 
 /**
  * @enum TelSimNumberingPlanIdentity_t
  * This enumeration defines the numbering plan identifier.
  */
 typedef enum {
-       TAPI_SIM_NPI_UNKNOWN                                            = 0,            /**< Unknown */
-       TAPI_SIM_NPI_ISDN_TEL                                           = 1,            /**< ISDN/Telephone numbering plan */
-       TAPI_SIM_NPI_DATA_NUMBERING_PLAN                = 3,            /**< Data numbering plan */
-       TAPI_SIM_NPI_TELEX                                              = 4,            /**< Telex numbering plan */
-       TAPI_SIM_NPI_SVC_CNTR_SPECIFIC_PLAN             = 5,            /**< Service Center Specific plan */
-       TAPI_SIM_NPI_SVC_CNTR_SPECIFIC_PLAN2    = 6,            /**< Service Center Specific plan */
-       TAPI_SIM_NPI_NATIONAL                                   = 8,            /**< National numbering plan */
-       TAPI_SIM_NPI_PRIVATE                                            = 9,            /**< Private numbering plan */
-       TAPI_SIM_NPI_ERMES_NUMBERING_PLAN               = 10,   /**< ERMES numbering plan */
-       TAPI_SIM_NPI_RESERVED_FOR_EXT                   = 0xF   /**< Reserved for extension */
+       TAPI_SIM_NPI_UNKNOWN = 0, /**< Unknown */
+       TAPI_SIM_NPI_ISDN_TEL = 1, /**< ISDN/Telephone numbering plan */
+       TAPI_SIM_NPI_DATA_NUMBERING_PLAN = 3, /**< Data numbering plan */
+       TAPI_SIM_NPI_TELEX = 4, /**< Telex numbering plan */
+       TAPI_SIM_NPI_SVC_CNTR_SPECIFIC_PLAN = 5, /**< Service Center Specific plan */
+       TAPI_SIM_NPI_SVC_CNTR_SPECIFIC_PLAN2 = 6, /**< Service Center Specific plan */
+       TAPI_SIM_NPI_NATIONAL = 8, /**< National numbering plan */
+       TAPI_SIM_NPI_PRIVATE = 9, /**< Private numbering plan */
+       TAPI_SIM_NPI_ERMES_NUMBERING_PLAN = 10, /**< ERMES numbering plan */
+       TAPI_SIM_NPI_RESERVED_FOR_EXT = 0xF /**< Reserved for extension */
 } TelSimNumberingPlanIdentity_t;
 
 /**
  * @enum TelSimEccEmergencyServiceInfo_t
  * This enumeration defines the emergency service type.
  */
-typedef enum
-{
-       TAPI_SIM_ECC_ESC_POLICE                 = 0x01, /**< Police */
-       TAPI_SIM_ECC_ESC_AMBULANCE              = 0x02, /**< Ambulance */
-       TAPI_SIM_ECC_ESC_FIREBRIGADE    = 0x04, /**< Fire brigade */
-       TAPI_SIM_ECC_ESC_MARAINEGUARD   = 0x08, /**< Marine guard */
-       TAPI_SIM_ECC_ESC_MOUTAINRESCUE  = 0x10, /**< Mountain rescue */
-       TAPI_SIM_ECC_ESC_SPARE                  = 0x00  /**< Spare */
- }TelSimEccEmergencyServiceInfo_t;
+typedef enum {
+       TAPI_SIM_ECC_ESC_POLICE = 0x01, /**< Police */
+       TAPI_SIM_ECC_ESC_AMBULANCE = 0x02, /**< Ambulance */
+       TAPI_SIM_ECC_ESC_FIREBRIGADE = 0x04, /**< Fire brigade */
+       TAPI_SIM_ECC_ESC_MARAINEGUARD = 0x08, /**< Marine guard */
+       TAPI_SIM_ECC_ESC_MOUTAINRESCUE = 0x10, /**< Mountain rescue */
+       TAPI_SIM_ECC_ESC_SPARE = 0x00 /**< Spare */
+} TelSimEccEmergencyServiceInfo_t;
 
 /**
  * @enum TelSimPbAccessResult_t
  * This enumeration defines the Phone book access result
  */
-typedef enum
-{
-       TAPI_SIM_PB_SUCCESS,                                                            /**< SIM phonebook operation successful. */
-       TAPI_SIM_PB_FAIL,                                                                       /**< SIM phonebook operation failure. */
-       TAPI_SIM_PB_INVALID_INDEX,                                              /**< The index passed was not a valid index. */
-       TAPI_SIM_PB_INVALID_NUMBER_LENGTH,                              /**< The number length is exceeds the max length allowed (or 0). */
-       TAPI_SIM_PB_INVALID_NAME_LENGTH,                                /**< The name length is exceeds the max length allowed (or 0). */
-       TAPI_SIM_PB_ACCESS_CONDITION_NOT_SATISFIED,     /**< Access condition for PB file is not satisfied. */
-
-}TelSimPbAccessResult_t;
+typedef enum {
+       TAPI_SIM_PB_SUCCESS, /**< SIM phonebook operation successful. */
+       TAPI_SIM_PB_FAIL, /**< SIM phonebook operation failure. */
+       TAPI_SIM_PB_INVALID_INDEX, /**< The index passed was not a valid index. */
+       TAPI_SIM_PB_INVALID_NUMBER_LENGTH, /**< The number length is exceeds the max length allowed (or 0). */
+       TAPI_SIM_PB_INVALID_NAME_LENGTH, /**< The name length is exceeds the max length allowed (or 0). */
+       TAPI_SIM_PB_ACCESS_CONDITION_NOT_SATISFIED, /**< Access condition for PB file is not satisfied. */
+} TelSimPbAccessResult_t;
 
 /**
  * @enum TelSimLanguagePreferenceCode_t
@@ -561,14 +527,14 @@ typedef enum
  */
 typedef enum {
        TAPI_SIM_LP_GERMAN = 0x00, /**< German */
-       TAPI_SIM_LP_ENGLISH = 0x01,     /**< English */
-       TAPI_SIM_LP_ITALIAN = 0x02,     /**< Italian */
+       TAPI_SIM_LP_ENGLISH = 0x01, /**< English */
+       TAPI_SIM_LP_ITALIAN = 0x02, /**< Italian */
        TAPI_SIM_LP_FRENCH = 0x03, /**< French */
        TAPI_SIM_LP_SPANISH = 0x04, /**< Spanish */
        TAPI_SIM_LP_DUTCH = 0x05, /**< Dutch */
        TAPI_SIM_LP_SWEDISH = 0x06, /**< Swedish */
        TAPI_SIM_LP_DANISH = 0x07, /**< Danish */
-       TAPI_SIM_LP_PORTUGUESE = 0x08,  /**< Portuguese */
+       TAPI_SIM_LP_PORTUGUESE = 0x08, /**< Portuguese */
        TAPI_SIM_LP_FINNISH = 0x09, /**< Finnish */
        TAPI_SIM_LP_NORWEGIAN = 0x0A, /**< Norwegian */
        TAPI_SIM_LP_GREEK = 0x0B, /**< Greek */
@@ -576,257 +542,235 @@ typedef enum {
        TAPI_SIM_LP_HUNGARIAN = 0x0D, /**< Hungarian */
        TAPI_SIM_LP_POLISH = 0x0E, /**< Polish */
        TAPI_SIM_LP_KOREAN = 0x0F, /**< Korean */
-       TAPI_SIM_LP_CHINESE = 0x10,     /**< Chinese */
-       TAPI_SIM_LP_RUSSIAN = 0x11,     /**< Russian */
+       TAPI_SIM_LP_CHINESE = 0x10, /**< Chinese */
+       TAPI_SIM_LP_RUSSIAN = 0x11, /**< Russian */
        TAPI_SIM_LP_JAPANESE = 0x12, /**< Japanese */
-       TAPI_SIM_LP_LANG_UNSPECIFIED = 0xFF     /**< Unspecified */
+       TAPI_SIM_LP_LANG_UNSPECIFIED = 0xFF /**< Unspecified */
 } TelSimLanguagePreferenceCode_t;
 
 /**
  * @enum TelSimAccessType_t
  * This enumeration defines the access type information.
  */
-typedef enum
-{
-       TAPI_SIM_READ_BINARY,                   /**< Read binary file */
-       TAPI_SIM_READ_RECORD,                   /**< Read record */
-       TAPI_SIM_READ_FILE_RAW,         /**< Read file and return raw data */
-       TAPI_SIM_GET_RESPONSE,          /**< Get response */
-       TAPI_SIM_UPDATE_BINARY,         /**< Update binary */
-       TAPI_SIM_UPDATE_RECORD,         /**< Update record */
-}TelSimAccessType_t;
+typedef enum {
+       TAPI_SIM_READ_BINARY, /**< Read binary file */
+       TAPI_SIM_READ_RECORD, /**< Read record */
+       TAPI_SIM_READ_FILE_RAW, /**< Read file and return raw data */
+       TAPI_SIM_GET_RESPONSE, /**< Get response */
+       TAPI_SIM_UPDATE_BINARY, /**< Update binary */
+       TAPI_SIM_UPDATE_RECORD, /**< Update record */
+} TelSimAccessType_t;
 
 /**
  * @enum TelSimCardStatus_t
  * This enumeration defines the SIM card status
  */
-typedef enum
-{
-       TAPI_SIM_STATUS_CARD_ERROR              = 0x00, /**< Bad card / On the fly SIM gone bad **/
-       TAPI_SIM_STATUS_CARD_NOT_PRESENT                = 0x01, /**<  Card not present **/
-       TAPI_SIM_STATUS_SIM_INITIALIZING                        = 0x02, /**<  SIM is Initializing state **/
-       TAPI_SIM_STATUS_SIM_INIT_COMPLETED              = 0x03, /**<  SIM Initialization ok **/
-       TAPI_SIM_STATUS_SIM_PIN_REQUIRED                = 0x04, /**<  PIN  required state **/
-       TAPI_SIM_STATUS_SIM_PUK_REQUIRED                = 0x05, /**<  PUK required state **/
-       TAPI_SIM_STATUS_CARD_BLOCKED                    = 0x06, /**<  PIN/PUK blocked(permanently blocked- All the attempts for PIN/PUK failed) **/
-       TAPI_SIM_STATUS_SIM_NCK_REQUIRED                = 0x07, /**<  Network Control Key required state **/
-       TAPI_SIM_STATUS_SIM_NSCK_REQUIRED               = 0x08, /**<  Network Subset Control Key required state **/
-       TAPI_SIM_STATUS_SIM_SPCK_REQUIRED               = 0x09, /**<  Service Provider Control Key required state **/
-       TAPI_SIM_STATUS_SIM_CCK_REQUIRED                = 0x0a, /**<  Corporate Control Key required state **/
-       TAPI_SIM_STATUS_CARD_REMOVED                    =0x0b,  /**<  Card removed **/
-       TAPI_SIM_STATUS_SIM_LOCK_REQUIRED               = 0x0c  /**<  PH-SIM (phone-SIM) locked state **/
-}TelSimCardStatus_t;
-
-/**
-* @enum TelSimCphsPhaseType_t
-* This enum gives the current CPHS phase of SIM card.
-*/
-typedef enum
-{
-       TAPI_SIM_CPHS_PHASE1            = 0x01, /**< phase1  */
-       TAPI_SIM_CPHS_PHASE2            = 0x02, /**< phase2  */
-       TAPI_SIM_CPHS_PHASE_RFU = 0xff  /**< RFU  */
-
-}TelSimCphsPhaseType_t;
+typedef enum {
+       TAPI_SIM_STATUS_CARD_ERROR = 0x00, /**< Bad card / On the fly SIM gone bad **/
+       TAPI_SIM_STATUS_CARD_NOT_PRESENT = 0x01, /**<  Card not present **/
+       TAPI_SIM_STATUS_SIM_INITIALIZING = 0x02, /**<  SIM is Initializing state **/
+       TAPI_SIM_STATUS_SIM_INIT_COMPLETED = 0x03, /**<  SIM Initialization ok **/
+       TAPI_SIM_STATUS_SIM_PIN_REQUIRED = 0x04, /**<  PIN  required state **/
+       TAPI_SIM_STATUS_SIM_PUK_REQUIRED = 0x05, /**<  PUK required state **/
+       TAPI_SIM_STATUS_CARD_BLOCKED = 0x06, /**<  PIN/PUK blocked(permanently blocked- All the attempts for PIN/PUK failed) **/
+       TAPI_SIM_STATUS_SIM_NCK_REQUIRED = 0x07, /**<  Network Control Key required state **/
+       TAPI_SIM_STATUS_SIM_NSCK_REQUIRED = 0x08, /**<  Network Subset Control Key required state **/
+       TAPI_SIM_STATUS_SIM_SPCK_REQUIRED = 0x09, /**<  Service Provider Control Key required state **/
+       TAPI_SIM_STATUS_SIM_CCK_REQUIRED = 0x0a, /**<  Corporate Control Key required state **/
+       TAPI_SIM_STATUS_CARD_REMOVED = 0x0b, /**<  Card removed **/
+       TAPI_SIM_STATUS_SIM_LOCK_REQUIRED = 0x0c /**<  PH-SIM (phone-SIM) locked state **/
+} TelSimCardStatus_t;
+
+/**
+ * @enum TelSimCphsPhaseType_t
+ * This enum gives the current CPHS phase of SIM card.
+ */
+typedef enum {
+       TAPI_SIM_CPHS_PHASE1 = 0x01, /**< phase1  */
+       TAPI_SIM_CPHS_PHASE2 = 0x02, /**< phase2  */
+       TAPI_SIM_CPHS_PHASE_RFU = 0xff /**< RFU  */
+} TelSimCphsPhaseType_t;
 
 /**
-* @enum TelSimCphsIndexLevelIndicator_t
-* This struct gives CPHS index level indication.
-*/
-typedef enum
-{
-       TAPI_SIM_CPHS_INDEX_LEVEL_ONE   = 0x01, /**< SIM cphs index level one */
-       TAPI_SIM_CPHS_INDEX_LEVEL_TWO   = 0x02, /**< SIM cphs index level two */
-       TAPI_SIM_CPHS_INDEX_LEVEL_THREE = 0x03, /**< SIM cphs index level three */
-       TAPI_SIM_CPHS_INDEX_LEVEL_RFU   = 0xff  /**< SIM cphs index level rfu */
-}TelSimCphsIndexLevelIndicator_t;
+ * @enum TelSimCphsIndexLevelIndicator_t
+ * This struct gives CPHS index level indication.
+ */
+typedef enum {
+       TAPI_SIM_CPHS_INDEX_LEVEL_ONE = 0x01, /**< SIM cphs index level one */
+       TAPI_SIM_CPHS_INDEX_LEVEL_TWO = 0x02, /**< SIM cphs index level two */
+       TAPI_SIM_CPHS_INDEX_LEVEL_THREE = 0x03, /**< SIM cphs index level three */
+       TAPI_SIM_CPHS_INDEX_LEVEL_RFU = 0xff /**< SIM cphs index level rfu */
+} TelSimCphsIndexLevelIndicator_t;
 
 /**
-* @enum TelSimCphsCustomerServiceGroup_t
-* This struct gives CPHS group service type information .
-*/
-typedef enum
-{
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_OFFERING                   = 0x01,         /**< Group csp offering*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_RESTRICTION                        = 0x02,         /**< Group csp restriction*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_OTHER_SUPP_SERVICES             = 0x03,         /**< Group csp supplementary services*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_COMPLETION                 = 0x04,         /**< Group csp completion*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_TELESERVICES                            = 0x05,         /**< Group csp teleservices*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CPHS_TELESERVICES               = 0x06,         /**< Group csp cphs teleservies*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CPHS_FEATURES                   = 0x07,         /**< Group csp cphs features*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_NUMBER_IDENTIFIERS              = 0x08,         /**< Group csp number identifiers*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_PHASE_SERVICES                  = 0x09,         /**< Group csp phase services*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_VALUE_ADDED_SERVICES    = 0xC0,         /**< Group csp value added services*/
-       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_INFORMATION_NUMBERS     = 0xD5          /**< Group csp information numbers*/
-}TelSimCphsCustomerServiceGroup_t;
-
-/**
-* @enum TelSimIndicationStatusType_t
-* This struct gives SIM Indication service information.
-*/
-typedef enum
-{
+ * @enum TelSimCphsCustomerServiceGroup_t
+ * This struct gives CPHS group service type information .
+ */
+typedef enum {
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_OFFERING = 0x01, /**< Group csp offering*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_RESTRICTION = 0x02, /**< Group csp restriction*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_OTHER_SUPP_SERVICES = 0x03, /**< Group csp supplementary services*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CALL_COMPLETION = 0x04, /**< Group csp completion*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_TELESERVICES = 0x05, /**< Group csp teleservices*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CPHS_TELESERVICES = 0x06, /**< Group csp cphs teleservies*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_CPHS_FEATURES = 0x07, /**< Group csp cphs features*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_NUMBER_IDENTIFIERS = 0x08, /**< Group csp number identifiers*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_PHASE_SERVICES = 0x09, /**< Group csp phase services*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_VALUE_ADDED_SERVICES = 0xC0, /**< Group csp value added services*/
+       TAPI_SIM_CPHS_CSP_SERVICE_GROUP_INFORMATION_NUMBERS = 0xD5 /**< Group csp information numbers*/
+} TelSimCphsCustomerServiceGroup_t;
+
+/**
+ * @enum TelSimIndicationStatusType_t
+ * This struct gives SIM Indication service information.
+ */
+typedef enum {
        TAPI_SIM_INDICATION_MW = 0x00, /**< Message Waiting indication status */
        TAPI_SIM_INDICATION_CF = 0x01, /**< Call Forwarding indication status */
-}TelSimIndicationStatusType_t;
+} TelSimIndicationStatusType_t;
 
 /**
-* @enum TelSimMsgWaitingGroup_t
-* This struct gives message waiting group type for mailbox,mwis and cfis.
-*/
-typedef enum
-{
-       TAPI_SIM_MWG_NONE       = 0x00,         /**< none*/
-       TAPI_SIM_MWG_VOICE      = 0x01,         /**< voice*/
-       TAPI_SIM_MWG_FAX                = 0x02,         /**< fax*/
-       TAPI_SIM_MWG_EMAIL      = 0x03,         /**< email*/
-       TAPI_SIM_MWG_OTHER      = 0x04,         /**< other*/
-       TAPI_SIM_MWG_VIDEO      = 0x05,         /**< video*/
-       TAPI_SIM_MWG_RFU                = 0xff          /**< rfu*/
-}TelSimMsgWaitingGroup_t;
-
-/**
-* @enum TelSimCallForwardUiIndicatorStatus_t
-* This struct gives call forward ui indicator status.
-*/
-typedef enum
-{
-       TAPI_SIM_CFIS_NONE      = 0x00,         /**< CFIS none*/
-       TAPI_SIM_CFIS_VOICE     = 0x01,         /**< CFIS voice*/
-       TAPI_SIM_CFIS_FAX               = 0x02,         /**< CFIS fax*/
-       TAPI_SIM_CFIS_DATA      = 0x04,         /**< CFIS data*/
-       TAPI_SIM_CFIS_RFU               = 0x08          /**< CFIS rfu*/
-}TelSimCallForwardUiIndicatorStatus_t;
-
-/**
-* @enum TelSimDynamicFlagsSelectedLineId_t
-* This enum gives dynamics flag selected line  information.
-*/
-typedef enum
-{
-       TAPI_SIM_DYNAMIC_FLAGS_LINE1    = 0x01, /**< line 1 */
-       TAPI_SIM_DYNAMIC_FLAGS_LINE2    = 0x00, /**< line 2*/
-       TAPI_SIM_DYNAMIC_FLAGS_RFU              = 0xff  /**< rfu*/
+ * @enum TelSimMsgWaitingGroup_t
+ * This struct gives message waiting group type for mailbox,mwis and cfis.
+ */
+typedef enum {
+       TAPI_SIM_MWG_NONE = 0x00, /**< none*/
+       TAPI_SIM_MWG_VOICE = 0x01, /**< voice*/
+       TAPI_SIM_MWG_FAX = 0x02, /**< fax*/
+       TAPI_SIM_MWG_EMAIL = 0x03, /**< email*/
+       TAPI_SIM_MWG_OTHER = 0x04, /**< other*/
+       TAPI_SIM_MWG_VIDEO = 0x05, /**< video*/
+       TAPI_SIM_MWG_RFU = 0xff /**< rfu*/
+} TelSimMsgWaitingGroup_t;
 
-}TelSimDynamicFlagsSelectedLineId_t;
+/**
+ * @enum TelSimCallForwardUiIndicatorStatus_t
+ * This struct gives call forward ui indicator status.
+ */
+typedef enum {
+       TAPI_SIM_CFIS_NONE = 0x00, /**< CFIS none*/
+       TAPI_SIM_CFIS_VOICE = 0x01, /**< CFIS voice*/
+       TAPI_SIM_CFIS_FAX = 0x02, /**< CFIS fax*/
+       TAPI_SIM_CFIS_DATA = 0x04, /**< CFIS data*/
+       TAPI_SIM_CFIS_RFU = 0x08 /**< CFIS rfu*/
+} TelSimCallForwardUiIndicatorStatus_t;
 
 /**
-* @enum tapi_sim_dynamic2_flag_als_status_t
-* This enum gives dynamics2 flag selected line  information.
-*/
-typedef enum
-{
-       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_LOCKED           = 0x01,   /**< Dynamic flags locked */
-       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_UNLOCKED = 0x00, /**< Dynamic flags unlocked */
-       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_RFU                      = 0xff  /**< rfu */
-}TelSimDynamic2FlagAlsStatus_t;
+ * @enum TelSimDynamicFlagsSelectedLineId_t
+ * This enum gives dynamics flag selected line  information.
+ */
+typedef enum {
+       TAPI_SIM_DYNAMIC_FLAGS_LINE1 = 0x01, /**< line 1 */
+       TAPI_SIM_DYNAMIC_FLAGS_LINE2 = 0x00, /**< line 2*/
+       TAPI_SIM_DYNAMIC_FLAGS_RFU = 0xff /**< rfu*/
+} TelSimDynamicFlagsSelectedLineId_t;
 
 /**
-* @enum TelSimSapMsgId_t
-* This enum gives the SAP message Ids between SAP client and SAP server.
-*/
-typedef enum
-{
-       TAPI_SIM_SAP_CONNECT_REQ                        = 0x00,                         /**< SAP connect request from client to server*/
-       TAPI_SIM_SAP_CONNECT_RESP                       = 0x01,                         /**< SAP connect response from server to client*/
-       TAPI_SIM_SAP_DISCONNECT_REQ                     = 0x02,                         /**< SAP disconnect request from client to server */
-       TAPI_SIM_SAP_DISCONNECT_RESP            = 0x03,                         /**< SAP disconnect response from server to client */
-       TAPI_SIM_SAP_DISCONNECT_IND                     = 0x04,                         /**< SAP disconnect indication from server to client */
-       TAPI_SIM_SAP_TRANSFER_APDU_REQ          = 0x05,                         /**< SAP transfer APDU(application protocol data unit) from client to server */
-       TAPI_SIM_SAP_TRANSFER_APDU_RESP = 0x06,                         /**< SAP response of transfer APDU */
-       TAPI_SIM_SAP_TRANSFER_ATR_REQ           = 0x07,                         /**< SAP Client request about Transfer ATR(Answer to Reset) procedure */
-       TAPI_SIM_SAP_TRANSFER_ATR_RESP          = 0x08,                         /**< SAP Server response after execution of ATR */
-       TAPI_SIM_SAP_POWER_SIM_OFF_REQ          = 0x09,                         /**< SAP Client request about power SIM off in Server */
-       TAPI_SIM_SAP_POWER_SIM_OFF_RESP = 0x0A,                         /**< SAP Server response the result about power SIM off in Server */
-       TAPI_SIM_SAP_POWER_SIM_ON_REQ           = 0x0B,                         /**< SAP Client request about power SIM on in Server */
-       TAPI_SIM_SAP_POWER_SIM_ON_RESP          = 0x0C,                         /**< SAP Server response the result about power SIM on in Server */
-       TAPI_SIM_SAP_RESET_SIM_REQ                      = 0x0D,                         /**< SAP Client request about SIM reset in Server */
-       TAPI_SIM_SAP_RESET_SIM_RESP                     = 0x0E,                         /**< SAP Server response the result about SIM reset in Server */
-       TAPI_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ   = 0x0F, /**< SAP request current status about card reader(Client or Server) */
+ * @enum tapi_sim_dynamic2_flag_als_status_t
+ * This enum gives dynamics2 flag selected line  information.
+ */
+typedef enum {
+       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_LOCKED = 0x01, /**< Dynamic flags locked */
+       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_UNLOCKED = 0x00, /**< Dynamic flags unlocked */
+       TAPI_SIM_PIN2_ACCESSIBLE_FLAGS_RFU = 0xff /**< rfu */
+} TelSimDynamic2FlagAlsStatus_t;
+
+/**
+ * @enum TelSimSapMsgId_t
+ * This enum gives the SAP message Ids between SAP client and SAP server.
+ */
+typedef enum {
+       TAPI_SIM_SAP_CONNECT_REQ = 0x00, /**< SAP connect request from client to server*/
+       TAPI_SIM_SAP_CONNECT_RESP = 0x01, /**< SAP connect response from server to client*/
+       TAPI_SIM_SAP_DISCONNECT_REQ = 0x02, /**< SAP disconnect request from client to server */
+       TAPI_SIM_SAP_DISCONNECT_RESP = 0x03, /**< SAP disconnect response from server to client */
+       TAPI_SIM_SAP_DISCONNECT_IND = 0x04, /**< SAP disconnect indication from server to client */
+       TAPI_SIM_SAP_TRANSFER_APDU_REQ = 0x05, /**< SAP transfer APDU(application protocol data unit) from client to server */
+       TAPI_SIM_SAP_TRANSFER_APDU_RESP = 0x06, /**< SAP response of transfer APDU */
+       TAPI_SIM_SAP_TRANSFER_ATR_REQ = 0x07, /**< SAP Client request about Transfer ATR(Answer to Reset) procedure */
+       TAPI_SIM_SAP_TRANSFER_ATR_RESP = 0x08, /**< SAP Server response after execution of ATR */
+       TAPI_SIM_SAP_POWER_SIM_OFF_REQ = 0x09, /**< SAP Client request about power SIM off in Server */
+       TAPI_SIM_SAP_POWER_SIM_OFF_RESP = 0x0A, /**< SAP Server response the result about power SIM off in Server */
+       TAPI_SIM_SAP_POWER_SIM_ON_REQ = 0x0B, /**< SAP Client request about power SIM on in Server */
+       TAPI_SIM_SAP_POWER_SIM_ON_RESP = 0x0C, /**< SAP Server response the result about power SIM on in Server */
+       TAPI_SIM_SAP_RESET_SIM_REQ = 0x0D, /**< SAP Client request about SIM reset in Server */
+       TAPI_SIM_SAP_RESET_SIM_RESP = 0x0E, /**< SAP Server response the result about SIM reset in Server */
+       TAPI_SIM_SAP_TRANSFER_CARD_READER_STATUS_REQ = 0x0F, /**< SAP request current status about card reader(Client or Server) */
        TAPI_SIM_SAP_TRANSFER_CARD_READER_STATUS_RESP = 0x10, /**< SAP response current status about card reader(Client or Server) */
-       TAPI_SIM_SAP_STATUS_IND                         = 0x11,                         /**< SAP indication of Server`s current status*/
-       TAPI_SIM_SAP_ERROR_RESP                         = 0x12,                         /**< SAP Server send error message when error occur */
-       TAPI_SIM_SAP_SET_TRANSPORT_PROTOCOL_REQ = 0x13,         /**< SAP Client request Transport Protocol type(T0 or T1)*/
-       TAPI_SIM_SAP_SET_TRANSPORT_PROTOCOL_RESP = 0x14         /**< SAP Server response the result after changing Transport Protocol*/
-}TelSimSapMsgId_t;
+       TAPI_SIM_SAP_STATUS_IND = 0x11, /**< SAP indication of Server`s current status*/
+       TAPI_SIM_SAP_ERROR_RESP = 0x12, /**< SAP Server send error message when error occur */
+       TAPI_SIM_SAP_SET_TRANSPORT_PROTOCOL_REQ = 0x13, /**< SAP Client request Transport Protocol type(T0 or T1)*/
+       TAPI_SIM_SAP_SET_TRANSPORT_PROTOCOL_RESP = 0x14 /**< SAP Server response the result after changing Transport Protocol*/
+} TelSimSapMsgId_t;
 
 /**
  * @enum TelSimSapConnectionStatus_t
  * This enum gives the SAP connection status information .
  */
-typedef enum
-{
-       TAPI_SIM_SAP_CONNECTION_STATUS_OK = 0x00,                                       /**< connect successfully */
-       TAPI_SIM_SAP_CONNECTION_STATUS_UNABLE_TO_ESTABLISH,             /**< unable to establish connection */
-       TAPI_SIM_SAP_CONNECTION_STATUS_NOT_SUPPORT_MAX_SIZE,    /**< when server does not support message length that client want send */
-       TAPI_SIM_SAP_CONNECTION_STATUS_TOO_SMALL_MAX_SIZE               /**< when client want to connect with very small message length which is not supported by Server */
-}TelSimSapConnectionStatus_t;
+typedef enum {
+       TAPI_SIM_SAP_CONNECTION_STATUS_OK = 0x00, /**< connect successfully */
+       TAPI_SIM_SAP_CONNECTION_STATUS_UNABLE_TO_ESTABLISH, /**< unable to establish connection */
+       TAPI_SIM_SAP_CONNECTION_STATUS_NOT_SUPPORT_MAX_SIZE, /**< when server does not support message length that client want send */
+       TAPI_SIM_SAP_CONNECTION_STATUS_TOO_SMALL_MAX_SIZE /**< when client want to connect with very small message length which is not supported by Server */
+} TelSimSapConnectionStatus_t;
 
 /**
  * @enum TelSimSapDissconnectType_t
  * This enum gives the SAP  disconnect type information.
  */
-typedef enum
-{
-       TAPI_SIM_SAP_DISCONNECT_TYPE_GRACEFUL=0x00,     /**< disconnection procedure ends after finishing current work */
-       TAPI_SIM_SAP_DISCONNECT_TYPE_IMMEDIATE          /**<  disconnection procedure ends immediately*/
-}TelSimSapDissconnectType_t;
+typedef enum {
+       TAPI_SIM_SAP_DISCONNECT_TYPE_GRACEFUL = 0x00, /**< disconnection procedure ends after finishing current work */
+       TAPI_SIM_SAP_DISCONNECT_TYPE_IMMEDIATE /**<  disconnection procedure ends immediately*/
+} TelSimSapDissconnectType_t;
 
 /**
  * @enum TelSimSapStatusInfo_t
  * This enum gives the SAP current connection status information
  */
-typedef enum
-{
-        TAPI_SIM_SAP_STATUS_UNKNOWN=0x00,  /**<  SAP server connection status - unknown*/
-        TAPI_SIM_SAP_STATUS_NO_SIM,            /**<  SAP server connection status - no SIM*/
-        TAPI_SIM_SAP_STATUS_NOT_READY,         /**<  SAP server connection status - not ready*/
-        TAPI_SIM_SAP_STATUS_READY,                     /**<  SAP server connection status - ready*/
-        TAPI_SIM_SAP_STATUS_CONNECTED          /**<  SAP server connection status - connected*/
-
-}TelSimSapStatusInfo_t;
+typedef enum {
+       TAPI_SIM_SAP_STATUS_UNKNOWN = 0x00, /**<  SAP server connection status - unknown*/
+       TAPI_SIM_SAP_STATUS_NO_SIM, /**<  SAP server connection status - no SIM*/
+       TAPI_SIM_SAP_STATUS_NOT_READY, /**<  SAP server connection status - not ready*/
+       TAPI_SIM_SAP_STATUS_READY, /**<  SAP server connection status - ready*/
+       TAPI_SIM_SAP_STATUS_CONNECTED /**<  SAP server connection status - connected*/
+} TelSimSapStatusInfo_t;
 
 /**
  * @enum TelSimSapCardStatus_t
  * This enum gives the SIM card status if server`s status changed about connection with subscription module
  */
-typedef enum
-{
-        TAPI_SIM_SAP_CARD_STATUS_UNKNOWN=0x00, /**<  SAP server status(card reader status) - unknown*/
-        TAPI_SIM_SAP_CARD_STATUS_RESET,                        /**<  SAP server status(card reader status) - reset*/
-        TAPI_SIM_SAP_CARD_STATUS_NOT_ACCESSIBLE,       /**<  SAP server status(card reader status) - not accessible*/
-        TAPI_SIM_SAP_CARD_STATUS_REMOVED,              /**<  SAP server status(card reader status) - removed*/
-        TAPI_SIM_SAP_CARD_STATUS_INSERTED,             /**<  SAP server status(card reader status) - inserted*/
-        TAPI_SIM_SAP_CARD_STATUS_RECOVERED             /**<  SAP server status(card reader status) - recovered*/
-
-}TelSimSapCardStatus_t;
+typedef enum {
+       TAPI_SIM_SAP_CARD_STATUS_UNKNOWN = 0x00, /**<  SAP server status(card reader status) - unknown*/
+       TAPI_SIM_SAP_CARD_STATUS_RESET, /**<  SAP server status(card reader status) - reset*/
+       TAPI_SIM_SAP_CARD_STATUS_NOT_ACCESSIBLE, /**<  SAP server status(card reader status) - not accessible*/
+       TAPI_SIM_SAP_CARD_STATUS_REMOVED, /**<  SAP server status(card reader status) - removed*/
+       TAPI_SIM_SAP_CARD_STATUS_INSERTED, /**<  SAP server status(card reader status) - inserted*/
+       TAPI_SIM_SAP_CARD_STATUS_RECOVERED /**<  SAP server status(card reader status) - recovered*/
+} TelSimSapCardStatus_t;
 
 /**
  * @enum TelSimSapResultCode_t
  * This enum gives the SAP result information.
  */
-typedef enum
-{
-         TAPI_SIM_SAP_RESULT_CODE_OK=0x00,                                             /**<  SAP operation result - ok*/
-         TAPI_SIM_SAP_RESULT_CODE_NO_REASON,                                   /**<  SAP operation result - no reason*/
-         TAPI_SIM_SAP_RESULT_CODE_CARD_NOT_ACCESSIBLE,         /**<  SAP operation result - not accessible*/
-         TAPI_SIM_SAP_RESULT_CODE_CARD_ALREADY_POWER_OFF,      /**<  SAP operation result - card already power off*/
-         TAPI_SIM_SAP_RESULT_CODE_CARD_REMOVED,                                /**<  SAP operation result - card removed*/
-         TAPI_SIM_SAP_RESULT_CODE_CARD_ALREADY_POWER_ON,       /**<  SAP operation result - card already power on*/
-         TAPI_SIM_SAP_RESULT_CODE_DATA_NOT_AVAILABLE,          /**<  SAP operation result - data not available*/
-         TAPI_SIM_SAP_RESULT_CODE_NOT_SUPPORT                          /**<  SAP operation result - not support*/
-
-}TelSimSapResultCode_t;
+typedef enum {
+       TAPI_SIM_SAP_RESULT_CODE_OK = 0x00, /**<  SAP operation result - ok*/
+       TAPI_SIM_SAP_RESULT_CODE_NO_REASON, /**<  SAP operation result - no reason*/
+       TAPI_SIM_SAP_RESULT_CODE_CARD_NOT_ACCESSIBLE, /**<  SAP operation result - not accessible*/
+       TAPI_SIM_SAP_RESULT_CODE_CARD_ALREADY_POWER_OFF, /**<  SAP operation result - card already power off*/
+       TAPI_SIM_SAP_RESULT_CODE_CARD_REMOVED, /**<  SAP operation result - card removed*/
+       TAPI_SIM_SAP_RESULT_CODE_CARD_ALREADY_POWER_ON, /**<  SAP operation result - card already power on*/
+       TAPI_SIM_SAP_RESULT_CODE_DATA_NOT_AVAILABLE, /**<  SAP operation result - data not available*/
+       TAPI_SIM_SAP_RESULT_CODE_NOT_SUPPORT /**<  SAP operation result - not support*/
+} TelSimSapResultCode_t;
 
 /**
  * @enum TelSimSapProtocol_t
  * This enum gives SAP transport protocol type
  */
-typedef enum
-{
-       TAPI_SIM_SAP_PROTOCOL_T0,       /**< T = 0, character*/
-       TAPI_SIM_SAP_PROTOCOL_T1                /**< T = 1, block*/
-}TelSimSapProtocol_t;
+typedef enum {
+       TAPI_SIM_SAP_PROTOCOL_T0, /**< T = 0, character*/
+       TAPI_SIM_SAP_PROTOCOL_T1 /**< T = 1, block*/
+} TelSimSapProtocol_t;
 
 /**
  * @enum TelSimAuthenticationType_t
@@ -901,20 +845,18 @@ typedef enum {
        TAPI_SIM_NO_SIM = 0x80, /**< SIM not inserted */
        TAPI_SIM_UNAVAIL = 0x81, /** < SIM interface error - SIM inserted but cannot communicate */
        TAPI_SIM_INIT_COMPLETE = 0x82, /** < SIM initialization completed */
-       TAPI_SIM_PB_INIT_COMPLETE = 0x83,       /**< PB initialization completed */
+       TAPI_SIM_PB_INIT_COMPLETE = 0x83, /**< PB initialization completed */
 } TelSimLockType_t;
 
-
 /**
  *     This will be used to get or set locks - PIN, FDN etc.
  */
 typedef enum {
        TAPI_SIM_LOCK_MODE_UNLOCK, /**< unlock */
-       TAPI_SIM_LOCK_MODE_LOCK,        /**< lock */
-       TAPI_SIM_LOCK_MODE_GET  /**< get */
+       TAPI_SIM_LOCK_MODE_LOCK, /**< lock */
+       TAPI_SIM_LOCK_MODE_GET /**< get */
 } tapi_sim_sec_lock_mode_t;
 
-
 /**
  * @enum tapi_sim_acl_t
  * This enumeration defines the ACL( Access Condition Level).
@@ -928,7 +870,6 @@ typedef enum {
        TAPI_SIM_ACL_NEVER = 0xFF /** Never */
 } TelSimAcl_t;
 
-
 /**
  * @enum TelSimRecordMode_t
  * This enumeration defines the record mode.
@@ -943,7 +884,6 @@ typedef enum {
        TAPI_SIM_RECORD_FROM_THE_FIRST = 0x06 /**< All records from the first record to the one specified by record_index will be read from the first */
 } TelSimRecordMode_t;
 
-
 /**
  * @enum TelSimLockKey_t
  *     This structure gives security lock key information enum values
@@ -956,58 +896,49 @@ typedef enum {
        TAPI_SIM_LOCK_KEY_PUK2 = 0x04, /**< PUK2 required */
        TAPI_SIM_LOCK_PERM_BLOCKED = 0x05, /**< Permanent block SIM */
        TAPI_SIM_LOCK_DISABLE = 0x06, /**< Lock disable */
-       TAPI_SIM_LOCK_KEY_SIMLOCK = 0x07,       /**< SIM Lock key required */
+       TAPI_SIM_LOCK_KEY_SIMLOCK = 0x07, /**< SIM Lock key required */
 } TelSimLockKey_t;
 
-
 /**
  * @enum TelSimPbAccessMode_t
  * This enumeration defines  modes to add, delete, edit for phone book access
  */
 typedef enum {
        TAPI_SIM_PB_ACCESS_MODE_ADD = 0x01, /**< Phone Book Access mode - Add entry */
-       TAPI_SIM_PB_ACCESS_MODE_DEL = 0x02,     /**< Phone Book Access mode - Delete entry */
-       TAPI_SIM_PB_ACCESS_MODE_EDIT = 0x03,    /**< Phone Book Access mode - edit entry */
+       TAPI_SIM_PB_ACCESS_MODE_DEL = 0x02, /**< Phone Book Access mode - Delete entry */
+       TAPI_SIM_PB_ACCESS_MODE_EDIT = 0x03, /**< Phone Book Access mode - edit entry */
 } TelSimPbAccessMode_t;
 
 
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
 /**
  * This structure contains information about pin data.
  * SIM PIN DATA. For PIN handling (Change, UnBlock) & for Type of PIN information.
  */
-typedef struct
-{
-       TelSimPinType_t type;   /**< Pin type */
-       unsigned char*  pw;             /**< PIN code */
-       unsigned int            pw_len; /**< PIN code length*/
+typedef struct {
+       TelSimPinType_t type; /**< Pin type */
+       unsigned char* pw; /**< PIN code */
+       unsigned int pw_len; /**< PIN code length*/
 } TelSimSecPw_t;
 
 /**
  * This structure contains information about personalization data.
  */
-typedef struct
-{
-       TelSimPersType_t        type;   /**< Personalization type */
-       unsigned char*  pw;             /**< Password */
-       unsigned int            pw_len; /**< Password length*/
+typedef struct {
+       TelSimPersType_t type; /**< Personalization type */
+       unsigned char* pw; /**< Password */
+       unsigned int pw_len; /**< Password length*/
 } TelSimPersPw_t;
 
 /**
  * This data structure defines the data for the Read file result information.
  */
-typedef struct
-{
-       TelSimFileName_t        file_id;                                /**< rsim access : SIM file id to access */
-       TelSimAccessType_t      rsim_cmd;               /**< rsim access : get response, read, update available*/
-       unsigned char   p1;                                             /**< rsim access : offset(bin), record num(record)*/
-       unsigned char   p2;                                             /**< rsim access : offset low(bin), mode(record)*/
-       unsigned char   p3;                                             /**< Number of bytes to be read(read case) or Length of the subsequent data field(update case) */
-       char* data;                                                     /**< Only update case. Optional*/
+typedef struct {
+       TelSimFileName_t file_id; /**< rsim access : SIM file id to access */
+       TelSimAccessType_t rsim_cmd; /**< rsim access : get response, read, update available*/
+       unsigned char p1; /**< rsim access : offset(bin), record num(record)*/
+       unsigned char p2; /**< rsim access : offset low(bin), mode(record)*/
+       unsigned char p3; /**< Number of bytes to be read(read case) or Length of the subsequent data field(update case) */
+       char* data; /**< Only update case. Optional*/
 } TelSimRSimReq_t;
 
 /**
@@ -1017,7 +948,6 @@ typedef struct {
        unsigned short file_id;
        char data_len;
        unsigned char pData[1];
-
 } TelSimReadFileRawData_t;
 
 /**
@@ -1030,7 +960,6 @@ typedef struct {
        unsigned char *pData;
 } TelSimReadFileRawResonse_t;
 
-
 /**
  * This data structure defines the data for the apdu.
  */
@@ -1047,7 +976,6 @@ typedef struct {
        unsigned char apdu_resp[TAPI_SIM_APDU_MAX_LEN];
 } TelSimApduResp_t;
 
-
 /**
  * This data structure defines the data for the Response of sending apdu.
  */
@@ -1056,15 +984,12 @@ typedef struct {
        unsigned char atr_resp[TAPI_SIM_APDU_MAX_LEN];
 } TelSimAtrResp_t;
 
-
 /**
  * This structure contains information about File name and path.
  */
-typedef struct
-{
-       TelSimFileName_t  FileName;             /**< Elementary FileName enumeration */
-       unsigned char   szPath[128];            /**< Absolute szPath of the elementary file. [Null Terminated] */
-
+typedef struct {
+       TelSimFileName_t FileName; /**< Elementary FileName enumeration */
+       unsigned char szPath[128]; /**< Absolute szPath of the elementary file. [Null Terminated] */
 } TelSimFileID_t;
 
 /**
@@ -1075,7 +1000,6 @@ typedef struct {
        TelSimAccessType_t AccessType; /**< Access type */
 } TelSimFileAccessGeneralResp_t;
 
-
 /**
  * This structure defines the SIM device Elementary file information read
  */
@@ -1092,7 +1016,6 @@ typedef struct {
        unsigned long FileSize; /**< File size */
 } TelSimFileInfo_t;
 
-
 /**
  * This data structure defines the data for the Read file result information.
  */
@@ -1105,10 +1028,8 @@ typedef struct {
        unsigned long RecordIndexTo; /**< end index to */
        TelSimRecordMode_t RecordMode; /**< record mode if read record */
        unsigned long DataLength; /**< data length to read */
-
 } TelSimReadFileRequestData_t;
 
-
 /*
  * This is the RAW data sent to Porting Layer after converting it to SIM specific data by Codecs
  */
@@ -1122,35 +1043,31 @@ typedef struct {
        unsigned char pData[1];
 } TelSimUpdateFileReqRawData_t;
 
-
 /**
  *This data structure defines the data which is provided a unique identification number for the (U)ICC.
  */
-typedef struct
-{
-       int icc_length; /**< Integrated Circuit Card number length */
-       char icc_num[TAPI_SIM_ICCID_LEN_MAX];   /**< Integrated Circuit Card number */
+typedef struct {
+       int icc_length; /**< Integrated Circuit Card number length */
+       char icc_num[TAPI_SIM_ICCID_LEN_MAX]; /**< Integrated Circuit Card number */
 } TelSimIccIdInfo_t;
 
 /**
  * This data structure defines the data for the Imsi information.
  */
-typedef struct
-{
-       int     bValid;                                         /**< Valid(ACTIVATE) IMSI (TRUE) or Deactivated (FALSE) */
-       char    szMcc[TAPI_SIM_MCC_CODE_LEN+1]; /**< mobile country code */
-       char    szMnc[TAPI_SIM_MNC_CODE_LEN+1]; /**< mobile network code */
-       char    szMsin[TAPI_SIM_MSIN_CODE_LEN+1];       /**< mobile station identification number */
+typedef struct {
+       int bValid; /**< Valid(ACTIVATE) IMSI (TRUE) or Deactivated (FALSE) */
+       char szMcc[TAPI_SIM_MCC_CODE_LEN + 1]; /**< mobile country code */
+       char szMnc[TAPI_SIM_MNC_CODE_LEN + 1]; /**< mobile network code */
+       char szMsin[TAPI_SIM_MSIN_CODE_LEN + 1]; /**< mobile station identification number */
 } TelSimImsiInfo_t;
 
 /**
  * This data structure defines the data for the PIN Information.
  */
-typedef struct
-{
-       TelSimPinType_t type;           /**< Specifies the PIN or PUK type.*/
-       int retry_count;        /**< Number of attempts remaining for PIN/PUK verification.*/
-}TelSimSecResult_t;
+typedef struct {
+       TelSimPinType_t type; /**< Specifies the PIN or PUK type.*/
+       int retry_count; /**< Number of attempts remaining for PIN/PUK verification.*/
+} TelSimSecResult_t;
 
 /**
  * This data structure defines the data for the PIN Information.
@@ -1169,7 +1086,6 @@ typedef struct {
        tapi_sim_sec_lock_mode_t LockMode;
 } LockStatus_t;
 
-
 /**
  *
  * This structure is used to get information about LOCK_TYPE
@@ -1180,7 +1096,6 @@ typedef struct {
        unsigned char RemainingAttempts; /**< retry counts */
 } TelSimLockInfoElement_t;
 
-
 /**
  *
  *This structure is used to get information about LOCK_TYPE
@@ -1191,324 +1106,322 @@ typedef struct {
        TelSimLockInfoElement_t LockTypeInfo[TAPI_SIM_LOCK_TYPE_INFO_MAX]; /**< Lock info according to Requested Lock Count *//* max of 8 supported */
 } TelSimLockInfo_t;
 
-
 /**
-* This data structure gives the phone book availability of current SIM.
-*/
-typedef struct
-{
-       int b_fdn;      /**< Fixed Dialing Number */
+ * This data structure gives the phone book availability of current SIM.
+ */
+typedef struct {
+       int b_fdn; /**< Fixed Dialing Number */
        int b_msisdn; /**< my own number - MSISDN list */
-       int b_adn;      /**< SIM - ADN(2G phonebook      */
-       int b_sdn;      /**< Service Dialing Number  */
-       int b_3g;               /**< USIM - 3G phonebook */
-       int b_aas;      /**< Additional number Alpha String phonebook */
-       int b_gas;      /**< Grouping information Alpha String phonebook */
-}TelSimPbList_t;
+       int b_adn; /**< SIM - ADN(2G phonebook   */
+       int b_sdn; /**< Service Dialing Number  */
+       int b_3g; /**< USIM - 3G phonebook */
+       int b_aas; /**< Additional number Alpha String phonebook */
+       int b_gas; /**< Grouping information Alpha String phonebook */
+} TelSimPbList_t;
 
 /**
-*  This data struture defines the 2G phone book data storage.
-*/
-typedef struct
-{
-       unsigned short  NumLen;                                                         /**< Number length*/
-       unsigned short  NumType;                                                                /**< Number type [refer to TelSimTypeOfNum_t]*/
-       unsigned short  NameLen;                                                                /**< Name string length*/
-       unsigned short  NameEncryptType;                                                /**< Name string encryption type [refer to TelSimTextEncrypt_t]*/
-       unsigned short  Number[TAPI_SIM_NUM_TEXT_LEN_MAX];              /**< Number data*/
-       unsigned short  Name[TAPI_SIM_NUM_TEXT_LEN_MAX];                /**< Name string*/
-}TelSimPb2GData_t;
+ *  This data struture defines the 2G phone book data storage.
+ */
+typedef struct {
+       unsigned short NumLen; /**< Number length*/
+       unsigned short NumType; /**< Number type [refer to TelSimTypeOfNum_t]*/
+       unsigned short NameLen; /**< Name string length*/
+       unsigned short NameEncryptType; /**< Name string encryption type [refer to TelSimTextEncrypt_t]*/
+       unsigned short Number[TAPI_SIM_NUM_TEXT_LEN_MAX]; /**< Number data*/
+       unsigned short Name[TAPI_SIM_NUM_TEXT_LEN_MAX]; /**< Name string*/
+} TelSimPb2GData_t;
 
 /**
  *
-*   This is union defines either type of number or defines the text encryption types
-*/
-typedef union
-{
-       TelSimTypeOfNum_t NumType;                      /**< Type of number */
-       TelSimTextEncrypt_t EncryptionType;     /**< Encryption type */
-}TelSimPbFileDataType_t;
+ *   This is union defines either type of number or defines the text encryption types
+ */
+typedef union {
+       TelSimTypeOfNum_t NumType; /**< Type of number */
+       TelSimTextEncrypt_t EncryptionType; /**< Encryption type */
+} TelSimPbFileDataType_t;
 
 /**
  *
-*  if tapi_sim_pb_storage_type_t value is TAPI_SIM_PB_3GSIM(0x0C)
-*  SUB_PARAMETERs are as follows
-*/
-typedef struct
-{
-       TelSimPb3GFileType_t            FileType;                                                               /**< SM PB File */
-       TelSimPbFileDataType_t          FileDataType;                                                   /**< Type of num or encryption type */
-       unsigned short                  FileDataLength;                                                 /**< Length of data*/
-       unsigned char                   AasRecordIdentifier;                                    /**< To be used only for ANR tag type*/
-       unsigned char                           FileData[TAPI_SIM_NUM_TEXT_LEN_MAX];    /**< file data */
-}TelSimPb3GFileDataInfo_t;
+ *  if tapi_sim_pb_storage_type_t value is TAPI_SIM_PB_3GSIM(0x0C)
+ *  SUB_PARAMETERs are as follows
+ */
+typedef struct {
+       TelSimPb3GFileType_t FileType; /**< SM PB File */
+       TelSimPbFileDataType_t FileDataType; /**< Type of num or encryption type */
+       unsigned short FileDataLength; /**< Length of data*/
+       unsigned char AasRecordIdentifier; /**< To be used only for ANR tag type*/
+       unsigned char FileData[TAPI_SIM_NUM_TEXT_LEN_MAX]; /**< file data */
+} TelSimPb3GFileDataInfo_t;
 
 /**
  *
-* This structure is used for tapi_sim_pb_storage_type_t value is TAPI_SIM_PB_AAS(0x0F) or TAPI_SIM_PB_GAS(0x10)
-*  SUB PRAMETERs are as follows
-*/
-typedef struct
-{
-       unsigned short          TextLength;                                                             /**< text length */
-       TelSimTextEncrypt_t     EncryptionType;                                                 /**< Encryption type */
-       unsigned char                   TextData[TAPI_SIM_NUM_TEXT_LEN_MAX];    /**< text data */
-}TelSimPbAdditionalNumString_t;
+ * This structure is used for tapi_sim_pb_storage_type_t value is TAPI_SIM_PB_AAS(0x0F) or TAPI_SIM_PB_GAS(0x10)
+ *  SUB PRAMETERs are as follows
+ */
+typedef struct {
+       unsigned short TextLength; /**< text length */
+       TelSimTextEncrypt_t EncryptionType; /**< Encryption type */
+       unsigned char TextData[TAPI_SIM_NUM_TEXT_LEN_MAX]; /**< text data */
+} TelSimPbAdditionalNumString_t;
 
 /**
  *
-* This structure contains the information about 3g phonebook
-*/
-typedef struct
-{
-       unsigned char                           FileTypeCount;  /**<Number of SIM PB EFs */
-       TelSimPb3GFileDataInfo_t        PbFileDataInfo[TAPI_SIM_PB_3G_FILE_MAX_COUNT];  /**< max of 13 array of structures */
-}TelSimPb3GData_t;
+ * This structure contains the information about 3g phonebook
+ */
+typedef struct {
+       unsigned char FileTypeCount; /**<Number of SIM PB EFs */
+       TelSimPb3GFileDataInfo_t PbFileDataInfo[TAPI_SIM_PB_3G_FILE_MAX_COUNT]; /**< max of 13 array of structures */
+} TelSimPb3GData_t;
 
 /**
  *
-* This structure contains the information about phonebook contact
-*/
-typedef union
-{
-       TelSimPb2GData_t                                Pb2GData;       /**<2G PB*/
-       TelSimPb3GData_t                                Pb3GData;       /**<3G PB*/
-       TelSimPbAdditionalNumString_t   PbAdditionalNumStringData; /**<Additional number*/
-}TelSimPbContactInfo_t;
+ * This structure contains the information about phonebook contact
+ */
+typedef union {
+       TelSimPb2GData_t Pb2GData; /**<2G PB*/
+       TelSimPb3GData_t Pb3GData; /**<3G PB*/
+       TelSimPbAdditionalNumString_t PbAdditionalNumStringData; /**<Additional number*/
+} TelSimPbContactInfo_t;
 
 /**
  *
-* This data structure defines the main structure for adding,edit, delete SIM phone book entry
-*/
-typedef struct
-{
-       TelSimPbFileType_t      StorageFileType;        /**< Storage file type */
-       unsigned short          Index;                          /**< Index of the record being read/updated. */
-       unsigned short          NextIndex;                      /**<  used only in read; ignored for write */
-       TelSimPbContactInfo_t   ContactInfo;                    /**< Contact Info can be 2G data or 3G data or AAS, GAS*/
+ * This data structure defines the main structure for adding,edit, delete SIM phone book entry
+ */
+typedef struct {
+       TelSimPbFileType_t StorageFileType; /**< Storage file type */
+       unsigned short Index; /**< Index of the record being read/updated. */
+       unsigned short NextIndex; /**<  used only in read; ignored for write */
+       TelSimPbContactInfo_t ContactInfo; /**< Contact Info can be 2G data or 3G data or AAS, GAS*/
 } TelSimPbRecordData_t;
 
+
+typedef struct {
+       TelSimPbFileType_t phonebook_type;
+       unsigned short index;
+       unsigned short next_index;
+
+       unsigned char name[60];
+       TelSimTextEncrypt_t dcs;
+
+       unsigned char number[40];
+       TelSimTypeOfNum_t ton;
+
+       /* following field is valid in only USIM*/
+       unsigned char anr1[40];
+       TelSimTypeOfNum_t anr1_ton;
+       unsigned char anr2[40];
+       TelSimTypeOfNum_t anr2_ton;
+       unsigned char anr3[40];
+       TelSimTypeOfNum_t anr3_ton;
+
+       unsigned char email1[60];
+       unsigned char email2[60];
+       unsigned char email3[60];
+       unsigned char email4[60];
+
+       unsigned short group_index; //GRP
+       unsigned short pb_control; //PBC
+} TelSimPbRecord_t;
+
 /**
  * This enumeration defines the Ecc information.
  */
-typedef struct
-{
-       char    szEcc1[TAPI_SIM_ECC_CODE_LEN*2 +1];             /**< Emergency Call Code 1 info. ECC is coded in BCD format. Unused bytes is set to 0xFF. */
-       char    szEcc2[TAPI_SIM_ECC_CODE_LEN*2 +1];             /**< Emergency Call Code  2 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
-       char    szEcc3[TAPI_SIM_ECC_CODE_LEN*2 +1];             /**< Emergency Call Code  3 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
-       char    szEcc4[TAPI_SIM_ECC_CODE_LEN*2 +1];             /**< Emergency Call Code  4 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
-       char    szEcc5[TAPI_SIM_ECC_CODE_LEN*2 +1];             /**< Emergency Call Code  5 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
-
+typedef struct {
+       char szEcc1[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code 1 info. ECC is coded in BCD format. Unused bytes is set to 0xFF. */
+       char szEcc2[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code  2 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
+       char szEcc3[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code  3 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
+       char szEcc4[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code  4 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
+       char szEcc5[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code  5 info ECC is coded in BCD format. Unused bytes is set to 0xFF. */
 } TelSimEccInfo_t;
 
 /**
  * This data structure defines the data for the USim emergency call code information.
  */
-typedef struct
-{
-       int     bUsed;                                                                  /**< Used or not */
-       char    szEcc[TAPI_SIM_ECC_CODE_LEN*2+1];               /**< Emergency Call Code info-ECC is coded in BCD format. Unused bytes is set to 0xFF.*/
-       unsigned short  EccLen;                                                                 /**< Ecc length */
-       char    szEccAlphaIdentifier[TAPI_SIM_ECC_ALPHA_STRING_LEN_MAX];                /**< Alphabet identifier */
-       TelSimEccEmergencyServiceInfo_t EccEmergencyServiceInfo;        /**< ECC emergency service information */
+typedef struct {
+       int bUsed; /**< Used or not */
+       char szEcc[TAPI_SIM_ECC_CODE_LEN * 2 + 1]; /**< Emergency Call Code info-ECC is coded in BCD format. Unused bytes is set to 0xFF.*/
+       unsigned short EccLen; /**< Ecc length */
+       char szEccAlphaIdentifier[TAPI_SIM_ECC_ALPHA_STRING_LEN_MAX]; /**< Alphabet identifier */
+       TelSimEccEmergencyServiceInfo_t EccEmergencyServiceInfo; /**< ECC emergency service information */
 } TelUsimEccInfo_t;
 
 /**
-*      This data structure defines the phone book storage count information.
-*/
-typedef struct
-{
-       TelSimPbFileType_t              StorageFileType;        /**< Storage  file type */
-       unsigned short          TotalRecordCount;       /**< Total record count */
-       unsigned short          UsedRecordCount;        /**< Used record count */
-}TelSimPbStorageInfo_t;
+ *     This data structure defines the phone book storage count information.
+ */
+typedef struct {
+       TelSimPbFileType_t StorageFileType; /**< Storage  file type */
+       unsigned short TotalRecordCount; /**< Total record count */
+       unsigned short UsedRecordCount; /**< Used record count */
+} TelSimPbStorageInfo_t;
 
 /**
-* This data structure gives the phone book entry information.
-*/
-typedef struct
-{
-       TelSimPbFileType_t      StorageFileType;        /**< Storage  file type */
-       unsigned short          PbIndexMin;                     /**< Phone book minimum index*/
-       unsigned short          PbIndexMax;             /**< Phone book maximum index */
-       unsigned short          PbNumLenMax;            /**< Phone number maximum length */
-       unsigned short          PbTextLenMax;           /**< Text maximum length */
-}TelSimPbEntryInfo_t;
+ * This data structure gives the phone book entry information.
+ */
+typedef struct {
+       TelSimPbFileType_t StorageFileType; /**< Storage  file type */
+       unsigned short PbIndexMin; /**< Phone book minimum index*/
+       unsigned short PbIndexMax; /**< Phone book maximum index */
+       unsigned short PbNumLenMax; /**< Phone number maximum length */
+       unsigned short PbTextLenMax; /**< Text maximum length */
+} TelSimPbEntryInfo_t;
 
 /**
-* This data structure gives the phone book update(add/edit/delete) response.
-*/
-typedef struct
-{
-       TelSimPbStorageInfo_t           PbStorageInfo;  /**< Indicates the total and used phonebook entries for the updated storage type (ADN/FDN, etc). */
-       unsigned short                  PbIndex;                /**< Phone book record index that was updated/deleted. */
-}TelSimPbUpdateResp_t;
+ * This data structure gives the phone book update(add/edit/delete) response.
+ */
+typedef struct {
+       TelSimPbStorageInfo_t PbStorageInfo; /**< Indicates the total and used phonebook entries for the updated storage type (ADN/FDN, etc). */
+       unsigned short PbIndex; /**< Phone book record index that was updated/deleted. */
+} TelSimPbUpdateResp_t;
 
 /**
  * This data structure defines the data for the Language information.
  */
-typedef struct
-{
-       unsigned long                                           LpCount;                                        /**< Language preference count; zero indicates that the LP file is not available or it doesn't have any data.*/
-       TelSimLanguagePreferenceCode_t  Lp[TAPI_SIM_LP_LEN_MAX];                /**< Language preference code */
+typedef struct {
+       unsigned long LpCount; /**< Language preference count; zero indicates that the LP file is not available or it doesn't have any data.*/
+       TelSimLanguagePreferenceCode_t Lp[TAPI_SIM_LP_LEN_MAX]; /**< Language preference code */
 } TelSimLanguageInfo_t;
 
 /**
  * This data structure defines the data for the group identifier information.
  */
-typedef struct
-{
-       unsigned short  GroupIdentifierLen;                                                             /**< Group identifier length */
-       char    szGroupIdentifier[TAPI_SIM_GROUP_IDENTIFIER_LEN_MAX];   /**< Group identifier */
+typedef struct {
+       unsigned short GroupIdentifierLen; /**< Group identifier length */
+       char szGroupIdentifier[TAPI_SIM_GROUP_IDENTIFIER_LEN_MAX]; /**< Group identifier */
 } TelSimGroupIdentifierInfo_t;
 
 /**
  * This data structure defines the data for the ECC information.
  */
-typedef struct
-{
-       TelUsimEccInfo_t        UeccInfo [TAPI_SIM_UECC_RECORD_COUNT_MAX];      /**< USIM Emergency Call Code information structure*/
-       TelSimEccInfo_t EccInfo;                                                                                /**< Emergency Call Code information*/
-}TelSimEccData_t;
+typedef struct {
+       TelUsimEccInfo_t UeccInfo[TAPI_SIM_UECC_RECORD_COUNT_MAX]; /**< USIM Emergency Call Code information structure*/
+       TelSimEccInfo_t EccInfo; /**< Emergency Call Code information*/
+} TelSimEccData_t;
 
 /**
-* This structure contains all read SIM elementary file information.
-*/
-typedef struct
-{
+ * This structure contains all read SIM elementary file information.
+ */
+typedef struct {
        unsigned char sw1;
        unsigned char sw2;
-       unsigned char   DataLen;        /**<Data Length*/
+       unsigned char DataLen; /**<Data Length*/
        unsigned char Data[TAPI_SIM_DATA_LEN_MAX];
 } TelSimReadFileRaw_t;
 
 /**
-*      This will be used to get / set lock status of PIN or FDN etc.
-*/
-typedef struct
-{
+ *     This will be used to get / set lock status of PIN or FDN etc.
+ */
+typedef struct {
        TelSimPersType_t type;
        int mode;
-}TelSimPersStatus_t;
+} TelSimPersStatus_t;
 
 /**
  *
-This structure gives 3G phone book capability information.
-*/
-typedef struct
-{
-       TelSimPb3GFileType_t    FileType3G;             /**< 3G phonebook file type */
-       unsigned short          PbIndexMax;     /**< max index */
-       unsigned short          PbTextMax;              /**< max text length */
-       unsigned short          TotalRecordCount;       /**< total record count */
-}TelSimPb3GFileTypeCapabiltyInfo_t;
+ This structure gives 3G phone book capability information.
+ */
+typedef struct {
+       TelSimPb3GFileType_t FileType3G; /**< 3G phonebook file type */
+       unsigned short PbIndexMax; /**< max index */
+       unsigned short PbTextMax; /**< max text length */
+       unsigned short TotalRecordCount; /**< total record count */
+} TelSimPb3GFileTypeCapabiltyInfo_t;
 
 /**
  *
  * This data structure defines the data for the SIM PHONEBOOK & ITS CAPABILITIES information.
  * It refers to EF_PBR
  */
-typedef struct
-{
-       unsigned char                                           FileTypeCount;  /**< phonebook file type count */
-       TelSimPb3GFileTypeCapabiltyInfo_t       FileTypeInfo[TAPI_SIM_PB_3G_FILE_MAX_COUNT] ;   /**< phonebook file type information */
-}TelSimPbCapabilityInfo_t;
-
+typedef struct {
+       unsigned char FileTypeCount; /**< phonebook file type count */
+       TelSimPb3GFileTypeCapabiltyInfo_t FileTypeInfo[TAPI_SIM_PB_3G_FILE_MAX_COUNT]; /**< phonebook file type information */
+} TelSimPbCapabilityInfo_t;
 
 /**CPHS related structs **/
 
 /**
-*      This sturcture gives information of available optional CPHS SIM files.
-*/
-typedef struct
-{
+ *     This sturcture gives information of available optional CPHS SIM files.
+ */
+typedef struct {
        /* Byte 2 - bit1 & 2*/
-       int      bCustomerServiceProfile;       /**< Customer Service Profile (CSP)  */
+       int bCustomerServiceProfile; /**< Customer Service Profile (CSP)  */
        /* Byte 2 - bit3 & 4*/
-       int     bServiceStringTable;                    /**< Service String Table (SST) */
+       int bServiceStringTable; /**< Service String Table (SST) */
        /* Byte 2 - bit5 & 6*/
-       int     bMailBoxNumbers;                        /**< MailBoxNumbers */
+       int bMailBoxNumbers; /**< MailBoxNumbers */
        /* Byte 2 - bit7 & 8*/
-       int     bOperatorNameShortForm; /**< Short form of operator name */
+       int bOperatorNameShortForm; /**< Short form of operator name */
        /* Byte 3 - bit1 & 2*/
-       int     bInformationNumbers; /**< Information numbers */
-
-}TelSimCphsServiceTable_t;
-
-/*******************************************************************************
+       int bInformationNumbers; /**< Information numbers */
+} TelSimCphsServiceTable_t;
 
-These requirements are additional to the GSM 900 and DCS1800 recommendations.
-They apply to all products which are to be compliant with the CPHS specification.
+/*
+ These requirements are additional to the GSM 900 and DCS1800 recommendations.
+ They apply to all products which are to be compliant with the CPHS specification.
 
-In addition to those SIM storage fields previously defined in DCS1800 to support
-existing MS features and services, the Association has defined the following fields  :-
+ In addition to those SIM storage fields previously defined in DCS1800 to support
+ existing MS features and services, the Association has defined the following fields  :-
 
-1)     Call Forwarding flag                                            (mandatory)
-2)     Voice message waiting flag                                      (mandatory)
-3)     PLMN operator name                                              (mandatory)
-4)     Customer Service Profile (CSP)                          (optional)
-5)     CPHS Information                                                        (mandatory)
-6)     Mailbox Numbers                                                 (optional)
-7)     Information Numbers                                             (optional)
+ 1)    Call Forwarding flag                                            (mandatory)
+ 2)    Voice message waiting flag                                      (mandatory)
+ 3)    PLMN operator name                                              (mandatory)
+ 4)    Customer Service Profile (CSP)                          (optional)
+ 5)    CPHS Information                                                        (mandatory)
+ 6)    Mailbox Numbers                                                 (optional)
+ 7)    Information Numbers                                             (optional)
 
-********************************************************************************/
+ */
 
-/*******************************************************************************
-DATA FIELD - 6F 16: CPHS INFORMATION
-Access Conditions:
      READ    CHV1
      UPDATE  ADM
-********************************************************************************/
+/*
+ DATA FIELD - 6F 16: CPHS INFORMATION
+ Access Conditions:
READ  CHV1
UPDATE        ADM
+ */
 /**
  *
-*This structure gives CPHS information data.
-*/
-typedef struct
-{
-       TelSimCphsPhaseType_t   CphsPhase;                      /**< CPHS phase type */
-       TelSimCphsServiceTable_t        CphsServiceTable;       /**< CPHS service table */
-}TelSimCphsInfo_t;
+ *This structure gives CPHS information data.
+ */
+typedef struct {
+       TelSimCphsPhaseType_t CphsPhase; /**< CPHS phase type */
+       TelSimCphsServiceTable_t CphsServiceTable; /**< CPHS service table */
+} TelSimCphsInfo_t;
 
-/*******************************************************************************
-DATA FIELD - 6F 14: OPERATOR NAME STRING
-Access Conditions:
      READ    CHV1
      UPDATE  ADM
-********************************************************************************/
+/*
+ DATA FIELD - 6F 14: OPERATOR NAME STRING
+ Access Conditions:
READ  CHV1
UPDATE        ADM
+ */
 /**
  *
-* This struct gives CPHS operator name information.
-*/
-typedef struct
-{
-       unsigned char           NameLength;                                             /**< CPHS operator name length */
-       unsigned char   OperatorName[TAPI_SIM_CPHS_OPERATOR_NAME_LEN_MAX+1]; /**< CPHS operator name */
-}TelSimCphsOperatorName_t;
-
+ * This struct gives CPHS operator name information.
+ */
+typedef struct {
+       unsigned char NameLength; /**< CPHS operator name length */
+       unsigned char OperatorName[TAPI_SIM_CPHS_OPERATOR_NAME_LEN_MAX + 1]; /**< CPHS operator name */
+} TelSimCphsOperatorName_t;
 
-/*******************************************************************************
-DATA FIELD - 6F 18: OPERATOR NAME SHORTFORM
-Access Conditions:
      READ    CHV1
      UPDATE  ADM
-********************************************************************************/
+/*
+ DATA FIELD - 6F 18: OPERATOR NAME SHORTFORM
+ Access Conditions:
READ  CHV1
UPDATE        ADM
+ */
 /**
  *
-* This struct gives CPHS operator short form name information.
-*/
-typedef struct
-{
-       unsigned char           ShortNameLength; /**< CPHS operator short name length */
-       unsigned char           OperatorShortName[TAPI_SIM_CPHS_OPERATOR_NAME_SHORT_FORM_LEN_MAX+1]; /**< CPHS short operator name */
-}TelSimCphsOperatorShortName_t;
-
+ * This struct gives CPHS operator short form name information.
+ */
+typedef struct {
+       unsigned char ShortNameLength; /**< CPHS operator short name length */
+       unsigned char OperatorShortName[TAPI_SIM_CPHS_OPERATOR_NAME_SHORT_FORM_LEN_MAX + 1]; /**< CPHS short operator name */
+} TelSimCphsOperatorShortName_t;
 
-/*******************************************************************************
-Data field 6F 17 in CPHS, 6F C7 in 3GPP : Mailbox Numbers
-Access Conditions:
      READ    CHV1
      UPDATE  CHV1
-********************************************************************************/
+/*
+ Data field 6F 17 in CPHS, 6F C7 in 3GPP : Mailbox Numbers
+ Access Conditions:
READ  CHV1
UPDATE        CHV1
+ */
 
 /**
  * This data structure defines the data for the dialing number information.
@@ -1527,369 +1440,338 @@ typedef struct {
        unsigned char Ext1RecordId; /**< Extensiion1 Record Identifier */
 } TelSimDialingNumberInfo_t;
 
-
 /**
-* This struct gives mailbox number(including CPHS case).
-*/
-typedef struct
-{
+ * This struct gives mailbox number(including CPHS case).
+ */
+typedef struct {
        int b_cphs; /**< current data is from CPHS SIM or not*/
        TelSimDialingNumberInfo_t voice_line1; /**< voice line1 mailbox number */
        TelSimDialingNumberInfo_t voice_line2; /**< voice line2 mailbox number (only available in CPHS)*/
        TelSimDialingNumberInfo_t video; /**< video mailbox number */
        TelSimDialingNumberInfo_t fax; /**< fax mailbox number */
        TelSimDialingNumberInfo_t email; /**< email mailbox number */
-}TelSimMailboxNumbers_s;
-
+} TelSimMailboxNumbers_s;
 
-/*******************************************************************************
-DATA FIELD -6F 11: Voice message waiting flag
-Access Conditions:
      READ    CHV1
      UPDATE  CHV1
-********************************************************************************/
+/*
+ DATA FIELD -6F 11: Voice message waiting flag
+ Access Conditions:
READ  CHV1
UPDATE        CHV1
+ */
 /**
  *
-* This struct gives CPHS voice message waiting flag information .
-*/
-typedef struct
-{
-       int     bWaitVoiceMsgLine1; /**< VoiceMsgLine 1 */
-       int     bWaitVoiceMsgLine2; /**< VoiceMsgLine 2 */
-       int     bWaitFaxMsg; /**< FAX Msg */
-       int     bWaitDataMsg; /**< Data Msg */
-}TelSimCphsVoiceMsgWaitFlagInfo_t;
-
-/*******************************************************************************
-DATA FIELD -6F 13: Call forwarding flags
-Access Conditions:
-       READ    CHV1
-       UPDATE  CHV1
-********************************************************************************/
-/**
-* This struct gives CPHS call forwarding flag information.
-*/
-typedef struct
-{
-       int     bCallForwardUnconditionalLine1; /**< CallForwardUnconditionalLine 1 */
-       int     bCallForwardUnconditionalLine2; /**< CallForwardUnconditionalLine 2 */
-       int     bCallForwardUnconditionalFax; /**< CallForwardUnconditional FAX */
-       int     bCallForwardUnconditionalData; /**<CallForwardUnconditional data*/
-       int     bCallForwardUnconditionalSms; /**< CallForwardUnconditional SMS */
-       int     bCallForwardUnconditionalBearer; /**< CallForwardUnconditional bearer*/
-}TelSimCphsCallForwardingFlagInfo_t;
-
-/*******************************************************************************
-DATA FIELD -6F 19: Information Numbers
-Access Conditions:
-       READ    CHV1
-       UPDATE  CHV1
-********************************************************************************/
-/**
-* This struct gives CPHS information numbers data.
-*/
-typedef struct
-{
-       int     bUsed; /**< SIM CPHS index level one */
+ * This struct gives CPHS voice message waiting flag information .
+ */
+typedef struct {
+       int bWaitVoiceMsgLine1; /**< VoiceMsgLine 1 */
+       int bWaitVoiceMsgLine2; /**< VoiceMsgLine 2 */
+       int bWaitFaxMsg; /**< FAX Msg */
+       int bWaitDataMsg; /**< Data Msg */
+} TelSimCphsVoiceMsgWaitFlagInfo_t;
+
+/*
+ DATA FIELD -6F 13: Call forwarding flags
+ Access Conditions:
+ READ  CHV1
+ UPDATE        CHV1
+ */
+/**
+ * This struct gives CPHS call forwarding flag information.
+ */
+typedef struct {
+       int bCallForwardUnconditionalLine1; /**< CallForwardUnconditionalLine 1 */
+       int bCallForwardUnconditionalLine2; /**< CallForwardUnconditionalLine 2 */
+       int bCallForwardUnconditionalFax; /**< CallForwardUnconditional FAX */
+       int bCallForwardUnconditionalData; /**<CallForwardUnconditional data*/
+       int bCallForwardUnconditionalSms; /**< CallForwardUnconditional SMS */
+       int bCallForwardUnconditionalBearer; /**< CallForwardUnconditional bearer*/
+} TelSimCphsCallForwardingFlagInfo_t;
+
+/*
+ DATA FIELD -6F 19: Information Numbers
+ Access Conditions:
+ READ  CHV1
+ UPDATE        CHV1
+ */
+/**
+ * This struct gives CPHS information numbers data.
+ */
+typedef struct {
+       int bUsed; /**< SIM CPHS index level one */
        unsigned char AlphaIdLength; /**< length of alpha identifier */
 
-       TelSimCphsIndexLevelIndicator_t IndexLevelIndicator; /**< SIM CPHS index level one */
-       int     PremiumServiceIndicator; /**< SIM CPHS index level one */
-       int     NetworkSpecificIndicator; /**< SIM CPHS index level one */
-       unsigned char Alpha_id[TAPI_SIM_XDN_ALPHA_ID_MAX_LEN+1]; /**<  Alpha Identifier */
+       TelSimCphsIndexLevelIndicator_t IndexLevelIndicator; /**< SIM CPHS index level one */
+       int PremiumServiceIndicator; /**< SIM CPHS index level one */
+       int NetworkSpecificIndicator; /**< SIM CPHS index level one */
+       unsigned char Alpha_id[TAPI_SIM_XDN_ALPHA_ID_MAX_LEN + 1]; /**<  Alpha Identifier */
 
        unsigned long DiallingnumLength; /**< Length of BCD number/SSC contents */
        TelSimTypeOfNum_t TypeOfNumber; /**< TON */
        TelSimNumberingPlanIdentity_t NumberingPlanIdentity; /**< NPI */
-       char DiallingNum[TAPI_SIM_XDN_DIALING_NUMBER_LEN+1]; /**< dialing Number/SSC String */
+       char DiallingNum[TAPI_SIM_XDN_DIALING_NUMBER_LEN + 1]; /**< dialing Number/SSC String */
        unsigned char Ext1RecordId; /**< Extensiion1 Record Identifier */
-}TelSimCphsInformationNum_t;
+} TelSimCphsInformationNum_t;
 
-
-/*******************************************************************************
-DATA FIELD- 6F 15: Customer Service Profile (Storing a list of service options which are relevant to that specific customer)
-Access Conditions:
-       READ    CHV1
-       UPDATE  CHV1
-********************************************************************************/
+/*
+ DATA FIELD- 6F 15: Customer Service Profile (Storing a list of service options which are relevant to that specific customer)
+ Access Conditions:
+ READ  CHV1
+ UPDATE        CHV1
+ */
 /**
  *
-* This struct gives CPHS service call offering information.
-*/
-typedef struct
-{
-       int     bCallForwardingUnconditional;   /**< CallForwarding Unconditional */
-       int     bCallForwardingOnUserBusy;              /**< CallForwarding On UserBusy */
-       int     bCallForwardingOnNoReply;               /**< CallForwarding On NoReply */
-       int     bCallForwardingOnUserNotReachable;      /**< CallForwarding On User Not Reachable */
-       int     bCallTransfer;                                          /**< Call Transfer */
-}TelSimCphsServiceCallOffering_t;
+ * This struct gives CPHS service call offering information.
+ */
+typedef struct {
+       int bCallForwardingUnconditional; /**< CallForwarding Unconditional */
+       int bCallForwardingOnUserBusy; /**< CallForwarding On UserBusy */
+       int bCallForwardingOnNoReply; /**< CallForwarding On NoReply */
+       int bCallForwardingOnUserNotReachable; /**< CallForwarding On User Not Reachable */
+       int bCallTransfer; /**< Call Transfer */
+} TelSimCphsServiceCallOffering_t;
 
 /**
  *
-* This struct gives CPHS service call restriction information.
-*/
-typedef struct
-{
-       int     bBarringOfAllOutgoingCalls;                                             /**< Barring Of All Outgoing Calls*/
-       int     bBarringOfOutgoingInternationalCalls;                           /**< Barring Of Outgoing International Calls */
-       int     bBarringOfOutgoingInternationalCallsExceptHplmn;        /**< Barring Of Outgoing International Calls Except HPLMN */
-       int     bBarringOfAllIncomingCallsRoamingOutsideHplmn;  /**< Barring Of All Incoming Calls Roaming Outside HPLMN */
-       int     bBarringOfIncomingCallsWhenRoaming;                     /**< Barring Of IncomingCalls When Roaming */
-}TelSimCphsServiceCallRestriction_t;
+ * This struct gives CPHS service call restriction information.
+ */
+typedef struct {
+       int bBarringOfAllOutgoingCalls; /**< Barring Of All Outgoing Calls*/
+       int bBarringOfOutgoingInternationalCalls; /**< Barring Of Outgoing International Calls */
+       int bBarringOfOutgoingInternationalCallsExceptHplmn; /**< Barring Of Outgoing International Calls Except HPLMN */
+       int bBarringOfAllIncomingCallsRoamingOutsideHplmn; /**< Barring Of All Incoming Calls Roaming Outside HPLMN */
+       int bBarringOfIncomingCallsWhenRoaming; /**< Barring Of IncomingCalls When Roaming */
+} TelSimCphsServiceCallRestriction_t;
 
 /**
  *
-* This struct gives CPHS service SS  information.
-*/
-typedef struct
-{
-       int     bMultiPartyService;     /**< MultiPartyService*/
-       int     bClosedUserGroup;       /**< ClosedUserGroup*/
-       int     bAdviceOfCharge;        /**< AdviceOfCharge*/
-       int     bPreferentialClosedUserGroup;   /**< PreferentialClosedUserGroup*/
-       int     bClosedUserGroupOutgoingAccess; /**< ClosedUserGroupOutgoingAccess*/
-}TelSimCphsServiceOtherSupplimentaryService_t;
+ * This struct gives CPHS service SS  information.
+ */
+typedef struct {
+       int bMultiPartyService; /**< MultiPartyService*/
+       int bClosedUserGroup; /**< ClosedUserGroup*/
+       int bAdviceOfCharge; /**< AdviceOfCharge*/
+       int bPreferentialClosedUserGroup; /**< PreferentialClosedUserGroup*/
+       int bClosedUserGroupOutgoingAccess; /**< ClosedUserGroupOutgoingAccess*/
+} TelSimCphsServiceOtherSupplimentaryService_t;
 
 /**
  *
-* This struct gives CPHS service call complete information.
-*/
-typedef struct
-{
-       int     bCallHold;                                              /**< Call Hold*/
-       int     bCallWaiting;                                   /**< Call Waiting*/
-       int     bCompletionOfCallToBusySubscriber;      /**< Completion Of Call To Busy Subscriber*/
-       int     bUserUserSignalling;                                    /**< User User Signaling*/
-}TelSimCphsServiceCallComplete_t;
+ * This struct gives CPHS service call complete information.
+ */
+typedef struct {
+       int bCallHold; /**< Call Hold*/
+       int bCallWaiting; /**< Call Waiting*/
+       int bCompletionOfCallToBusySubscriber; /**< Completion Of Call To Busy Subscriber*/
+       int bUserUserSignalling; /**< User User Signaling*/
+} TelSimCphsServiceCallComplete_t;
 
 /**
  *
-* This struct gives CPHS service teleservices  information.
-*/
-typedef struct
-{
-       int     bShortMessageMobileOriginated;          /**< Short Message Mobile Originated*/
-       int     bShortMessageMobileTerminated;          /**< Short Message Mobile Terminated*/
-       int     bShortMessageCellBroadcast;                     /**< Short Message Cell Broadcast*/
-       int     bShortMessageReplyPath;                 /**< Short  Message Reply Path*/
-       int     bShortMessageDeliveryConf;                      /**< Short Message Delivery Conf*/
-       int     bShortMessageProtocolIdentifier;                /**< Short Message Protocol Identifier*/
-       int     bShortMessageValidityPeriod;                    /**< Short Message Validity Period*/
-}TelSimCphsServiceTeleservices_t;
+ * This struct gives CPHS service teleservices  information.
+ */
+typedef struct {
+       int bShortMessageMobileOriginated; /**< Short Message Mobile Originated*/
+       int bShortMessageMobileTerminated; /**< Short Message Mobile Terminated*/
+       int bShortMessageCellBroadcast; /**< Short Message Cell Broadcast*/
+       int bShortMessageReplyPath; /**< Short  Message Reply Path*/
+       int bShortMessageDeliveryConf; /**< Short Message Delivery Conf*/
+       int bShortMessageProtocolIdentifier; /**< Short Message Protocol Identifier*/
+       int bShortMessageValidityPeriod; /**< Short Message Validity Period*/
+} TelSimCphsServiceTeleservices_t;
 
 /**
  *
-* This struct gives CPHS alternative line service  information.
-*/
-typedef struct
-{
-       int     bAlternativeLineService;   /**< Alternative Line Service*/
-}TelSimCphsServiceCphsTeleservices_t;
+ * This struct gives CPHS alternative line service  information.
+ */
+typedef struct {
+       int bAlternativeLineService; /**< Alternative Line Service*/
+} TelSimCphsServiceCphsTeleservices_t;
 
 /**
  *
-* This struct gives CPHS string service table information.
-*/
-typedef struct
-{
-       int     bStringServiceTable;    /**< String Service Table*/
-}TelSimCphsServiceCphsFeatures_t;
+ * This struct gives CPHS string service table information.
+ */
+typedef struct {
+       int bStringServiceTable; /**< String Service Table*/
+} TelSimCphsServiceCphsFeatures_t;
 
 /**
  *
-* This struct gives CPHS service number identifier  information.
-*/
-typedef struct
-{
-       int     bCallingLineIdentificationPresent;                      /**< Calling Line Identification Present*/
-       int     bConnectedLineIdentificationRestrict;           /**< Connected Line Identification Restrict*/
-       int     bConnectedLineIdentificationPresent;            /**< Connected Line Identification Present*/
-       int     bMaliciousCallIdentifier;                                       /**< Malicious Call Identifier*/
-       int     bCallingLineIdentificationSend;                 /**< Calling Line Identification Send*/
-       int     bCallingLineIdentificationBlock;                        /**< Calling Line Identification Block*/
-}TelSimCphsServiceNumberIdentifier_t;
+ * This struct gives CPHS service number identifier  information.
+ */
+typedef struct {
+       int bCallingLineIdentificationPresent; /**< Calling Line Identification Present*/
+       int bConnectedLineIdentificationRestrict; /**< Connected Line Identification Restrict*/
+       int bConnectedLineIdentificationPresent; /**< Connected Line Identification Present*/
+       int bMaliciousCallIdentifier; /**< Malicious Call Identifier*/
+       int bCallingLineIdentificationSend; /**< Calling Line Identification Send*/
+       int bCallingLineIdentificationBlock; /**< Calling Line Identification Block*/
+} TelSimCphsServiceNumberIdentifier_t;
 
 /**
  *
-* This struct gives CPHS service phase services information.
-*/
-typedef struct
-{
-       int     bMenuForGprs;                                                   /**< Menu For GPRS*/
-       int     bMenuForHighSpeedCsd;                                   /**< Menu For HighSpeedCsd*/
-       int     bMenuForVoiceGroupCall;                                 /**< Menu For VoiceGroupCall*/
-       int     bMenuForVoiceBroadcastService;                  /**< Menu For VoiceBroadcastService*/
-       int     bMenuForMultipleSubscriberProfile;              /**< Menu For MultipleSubscriberProfile*/
-       int     bMenuForMultipleBand;                                   /**< Menu For MultipleBand*/
-}TelSimCphsServicePhaseServices_t;
+ * This struct gives CPHS service phase services information.
+ */
+typedef struct {
+       int bMenuForGprs; /**< Menu For GPRS*/
+       int bMenuForHighSpeedCsd; /**< Menu For HighSpeedCsd*/
+       int bMenuForVoiceGroupCall; /**< Menu For VoiceGroupCall*/
+       int bMenuForVoiceBroadcastService; /**< Menu For VoiceBroadcastService*/
+       int bMenuForMultipleSubscriberProfile; /**< Menu For MultipleSubscriberProfile*/
+       int bMenuForMultipleBand; /**< Menu For MultipleBand*/
+} TelSimCphsServicePhaseServices_t;
 
 /**
  *
-* This struct gives CPHS value added service   information.
-*/
-typedef struct
-{
-       int     bRestrictMenuForManualSelection;                /**< RestrictMenu For ManualSelection*/
-       int     bRestrictMenuForVoiceMail;                              /**< RestrictMenu For VoiceMail*/
-       int     bRestrictMenuForMoSmsAndPaging;         /**< RestrictMenu For MoSmsAndPaging*/
-       int     bRestrictMenuForMoSmsWithEmialType;     /**< RestrictMenu For MoSmsWithEmialType*/
-       int     bRestrictMenuForFaxCalls;                               /**< RestrictMenu For FaxCalls*/
-       int     bRestrictMenuForDataCalls;                              /**< RestrictMenu For DataCalls*/
-       int     bRestrictMenuForChangeLanguage;         /**< RestrictMenu For ChangeLanguage*/
-}TelSimCphsServiceValueAddedServices_t;
+ * This struct gives CPHS value added service   information.
+ */
+typedef struct {
+       int bRestrictMenuForManualSelection; /**< RestrictMenu For ManualSelection*/
+       int bRestrictMenuForVoiceMail; /**< RestrictMenu For VoiceMail*/
+       int bRestrictMenuForMoSmsAndPaging; /**< RestrictMenu For MoSmsAndPaging*/
+       int bRestrictMenuForMoSmsWithEmialType; /**< RestrictMenu For MoSmsWithEmialType*/
+       int bRestrictMenuForFaxCalls; /**< RestrictMenu For FaxCalls*/
+       int bRestrictMenuForDataCalls; /**< RestrictMenu For DataCalls*/
+       int bRestrictMenuForChangeLanguage; /**< RestrictMenu For ChangeLanguage*/
+} TelSimCphsServiceValueAddedServices_t;
 
 /**
  *
-* This struct gives CPHS service information number data.
-*/
-typedef struct
-{
-       int     bInformationNumbers;                                    /**< Information Numbers*/
-}TelSimCphsServiceInformationNumbers_t;
+ * This struct gives CPHS service information number data.
+ */
+typedef struct {
+       int bInformationNumbers; /**< Information Numbers*/
+} TelSimCphsServiceInformationNumbers_t;
 
 /**
  *
-* This struct gives CPHS service profile entry  information.
-*/
-typedef struct
-{
-       TelSimCphsCustomerServiceGroup_t                                        CustomerServiceGroup;           /**< customer service group*/
-       union
-       {
-               TelSimCphsServiceCallOffering_t                                 CallOffering;                                   /**< call offering*/
-               TelSimCphsServiceCallRestriction_t                              CallRestriction;                                /**< call restriction*/
-               TelSimCphsServiceOtherSupplimentaryService_t    OtherSuppServices;                      /**< other SS services*/
-               TelSimCphsServiceCallComplete_t                         CallComplete;                           /**< call complete*/
-               TelSimCphsServiceTeleservices_t                                 Teleservices;                           /**< teleservices*/
-               TelSimCphsServiceCphsTeleservices_t                             CphsTeleservices;                       /**< CPHS teleservices*/
-               TelSimCphsServiceCphsTeleservices_t                             CphsFeatures;                           /**< CPHS features*/
-               TelSimCphsServiceNumberIdentifier_t                             NumberIdentifiers;                      /**< number identifiers*/
-               TelSimCphsServicePhaseServices_t                                PhaseServices;                          /**< phase services*/
-               TelSimCphsServiceValueAddedServices_t                   ValueAddedServices;                     /**< value added services*/
-               TelSimCphsServiceInformationNumbers_t                   InformationNumbers;             /**< information numbers*/
-       }u;
-}TelSimCphsCustomerServiceProfileEntry_t;
+ * This struct gives CPHS service profile entry  information.
+ */
+typedef struct {
+       TelSimCphsCustomerServiceGroup_t CustomerServiceGroup; /**< customer service group*/
+       union {
+               TelSimCphsServiceCallOffering_t CallOffering; /**< call offering*/
+               TelSimCphsServiceCallRestriction_t CallRestriction; /**< call restriction*/
+               TelSimCphsServiceOtherSupplimentaryService_t OtherSuppServices; /**< other SS services*/
+               TelSimCphsServiceCallComplete_t CallComplete; /**< call complete*/
+               TelSimCphsServiceTeleservices_t Teleservices; /**< teleservices*/
+               TelSimCphsServiceCphsTeleservices_t CphsTeleservices; /**< CPHS teleservices*/
+               TelSimCphsServiceCphsTeleservices_t CphsFeatures; /**< CPHS features*/
+               TelSimCphsServiceNumberIdentifier_t NumberIdentifiers; /**< number identifiers*/
+               TelSimCphsServicePhaseServices_t PhaseServices; /**< phase services*/
+               TelSimCphsServiceValueAddedServices_t ValueAddedServices; /**< value added services*/
+               TelSimCphsServiceInformationNumbers_t InformationNumbers; /**< information numbers*/
+       } u;
+} TelSimCphsCustomerServiceProfileEntry_t;
 
 /**
  *
-* This struct gives CPHS service profile information.
-*/
-typedef struct
-{
-       TelSimCphsCustomerServiceProfileEntry_t         ServiceProfileEntry[TAPI_SIM_CPHS_CUSTOMER_SERVICE_PROFILE_ENTRY_COUNT_MAX]; /**< service profile entry*/
-}TelSimCphsCustomerServiceProfileInfo_t;
-
+ * This struct gives CPHS service profile information.
+ */
+typedef struct {
+       TelSimCphsCustomerServiceProfileEntry_t ServiceProfileEntry[TAPI_SIM_CPHS_CUSTOMER_SERVICE_PROFILE_ENTRY_COUNT_MAX]; /**< service profile entry*/
+} TelSimCphsCustomerServiceProfileInfo_t;
 
-/*******************************************************************************
-Identifier: '6FCA'     Structure: linear fixed Optional
-Record length: X bytes, X>=5   Update activity: low
-Access Conditions:
      READ    PIN
      UPDATE  PIN
-********************************************************************************/
+/*
+ Identifier: '6FCA'    Structure: linear fixed Optional
+ Record length: X bytes, X>=5  Update activity: low
+ Access Conditions:
READ  PIN
UPDATE        PIN
+ */
 /**
  *
-* This struct gives message waiting indication status information.
-*/
-typedef struct
-{
-       unsigned char           IndicatorType;          /**< Indicator Type*/
-       unsigned char           VoiceMailCount;         /**< VoiceMail Count*/
-       unsigned char           FaxCount;                       /**< FAX Count*/
-       unsigned char           EmailCount;                     /**< Email Count*/
-       unsigned char           OtherCount;                     /**< Other Count*/
-       unsigned char           VideoMailCount;         /**< VideoMail Count*/
-}TelSimMsgWaitingIndicationStatus_t;
-
-
-/*******************************************************************************
-Identifier: '6FCB'     Structure: linear fixed Optional
-Record length: 16 bytes,       Update activity: low
-Access Conditions:
-       READ    PIN
-       UPDATE  PIN
-********************************************************************************/
+ * This struct gives message waiting indication status information.
+ */
+typedef struct {
+       unsigned char IndicatorType; /**< Indicator Type*/
+       unsigned char VoiceMailCount; /**< VoiceMail Count*/
+       unsigned char FaxCount; /**< FAX Count*/
+       unsigned char EmailCount; /**< Email Count*/
+       unsigned char OtherCount; /**< Other Count*/
+       unsigned char VideoMailCount; /**< VideoMail Count*/
+} TelSimMsgWaitingIndicationStatus_t;
+
+/*
+ Identifier: '6FCB'    Structure: linear fixed Optional
+ Record length: 16 bytes,      Update activity: low
+ Access Conditions:
+ READ  PIN
+ UPDATE        PIN
+ */
 /**
  *
-* This struct gives call forwarding indication  information.
-*/
-typedef struct
-{
-       int                                             bUsed;                          /**< used or not*/
-       unsigned char                                   MspNumber;              /**< MSP number*/
-       unsigned char                                   Status;                         /**< call forwarding indication status*/
-       unsigned long                                   DiallingnumLen;         /**< Length of BCD number/SSC contents*/
-       TelSimTypeOfNum_t                       TypeOfNumber;           /**< TON*/
-       TelSimNumberingPlanIdentity_t   NumberingPlanIdent;     /**< NPI*/
-       char                                                    DiallingNum[TAPI_SIM_XDN_DIALING_NUMBER_LEN+1];/**< Dialing Number/SSC String*/
-}TelSimCallForwardingIndicationStatus_t;
-
-/**
-* This struct gives Call Forwarding Indication information including CPHS case.
-*/
-typedef struct
-{
+ * This struct gives call forwarding indication  information.
+ */
+typedef struct {
+       int bUsed; /**< used or not*/
+       unsigned char MspNumber; /**< MSP number*/
+       unsigned char Status; /**< call forwarding indication status*/
+       unsigned long DiallingnumLen; /**< Length of BCD number/SSC contents*/
+       TelSimTypeOfNum_t TypeOfNumber; /**< TON*/
+       TelSimNumberingPlanIdentity_t NumberingPlanIdent; /**< NPI*/
+       char DiallingNum[TAPI_SIM_XDN_DIALING_NUMBER_LEN + 1];/**< Dialing Number/SSC String*/
+} TelSimCallForwardingIndicationStatus_t;
+
+/**
+ * This struct gives Call Forwarding Indication information including CPHS case.
+ */
+typedef struct {
        int b_cphs; /**< current data is from CPHS SIM or not*/
-       union{
-               TelSimCphsCallForwardingFlagInfo_t cphs_cf;     /**< information from CPHS SIM*/
-               TelSimCallForwardingIndicationStatus_t cf;      /**< information from 3GPP SIM*/
-       }cf_data_u;
-}TelSimCallForwarding_s;
+       union {
+               TelSimCphsCallForwardingFlagInfo_t cphs_cf; /**< information from CPHS SIM*/
+               TelSimCallForwardingIndicationStatus_t cf; /**< information from 3GPP SIM*/
+       } cf_data_u;
+} TelSimCallForwarding_s;
 
 /**
-* This struct gives Message Waiting Indication information including CPHS case.
-*/
-typedef struct
-{
+ * This struct gives Message Waiting Indication information including CPHS case.
+ */
+typedef struct {
        int b_cphs; /**< current data is from CPHS SIM or not*/
-       union{
-               TelSimCphsVoiceMsgWaitFlagInfo_t cphs_mw;       /**< information from CPHS SIM*/
-               TelSimMsgWaitingIndicationStatus_t mw;  /**< information from 3GPP SIM*/
-       }mw_data_u;
-}TelSimMessageWaiting_s;
+       union {
+               TelSimCphsVoiceMsgWaitFlagInfo_t cphs_mw; /**< information from CPHS SIM*/
+               TelSimMsgWaitingIndicationStatus_t mw; /**< information from 3GPP SIM*/
+       } mw_data_u;
+} TelSimMessageWaiting_s;
 
 /**
  *
-* This struct gives dynamics flag selected line  information.
-*/
-typedef struct
-{
-       TelSimDynamicFlagsSelectedLineId_t       DynamicFlags;  /**< Dynamic flags information */
-}TelSimDynamicFlagsInfo_t;
+ * This struct gives dynamics flag selected line  information.
+ */
+typedef struct {
+       TelSimDynamicFlagsSelectedLineId_t DynamicFlags; /**< Dynamic flags information */
+} TelSimDynamicFlagsInfo_t;
 
 /**
  *
-* This struct gives dynamics flag selected line  information.
-*/
-typedef struct
-{
-       TelSimDynamic2FlagAlsStatus_t    Dynamic2Flag;          /**< Dynamic flags status */
-}TelSimDynamic2FlagsInfo_t;
+ * This struct gives dynamics flag selected line  information.
+ */
+typedef struct {
+       TelSimDynamic2FlagAlsStatus_t Dynamic2Flag; /**< Dynamic flags status */
+} TelSimDynamic2FlagsInfo_t;
 
 /**
  *     This data structure represents the CPHS specific information
  */
-typedef struct
-{
+typedef struct {
        int b_used; /**< used or not */
-       TelSimCphsInfo_t cphsinfo;      /**< CPHS information */
-       TelSimCphsCustomerServiceProfileInfo_t csp;     /**< customer service profile */
-       TelSimCphsInformationNum_t infn;        /**< information numbers */
-       TelSimCphsOperatorName_t opname;        /**< operator name */
-       TelSimCphsOperatorShortName_t opshortform;      /**< operator short form */
+       TelSimCphsInfo_t cphsinfo; /**< CPHS information */
+       TelSimCphsCustomerServiceProfileInfo_t csp; /**< customer service profile */
+       TelSimCphsInformationNum_t infn; /**< information numbers */
+       TelSimCphsOperatorName_t opname; /**< operator name */
+       TelSimCphsOperatorShortName_t opshortform; /**< operator short form */
        TelSimDynamicFlagsInfo_t dflagsinfo; /**< Dynamic flags */
        TelSimDynamic2FlagsInfo_t d2flagsinfo; /**< Dynamic2 flags */
-}TelSimCphsLocalInfo_t;
+} TelSimCphsLocalInfo_t;
 
 /**
  *     This data structure represents MSISDN information
  */
-typedef struct
-{
-       char num[TAPI_SIM_XDN_DIALING_NUMBER_LEN+1]; /**< MSISDN number. If not exist, Null string will be returned*/
-       char name[TAPI_SIM_XDN_ALPHA_ID_MAX_LEN+1]; /**< MSISDN name. If not exist, Null string will be returned*/
-}TelSimSubscriberInfo_t;
+typedef struct {
+       char num[TAPI_SIM_XDN_DIALING_NUMBER_LEN + 1]; /**< MSISDN number. If not exist, Null string will be returned*/
+       char name[TAPI_SIM_XDN_ALPHA_ID_MAX_LEN + 1]; /**< MSISDN name. If not exist, Null string will be returned*/
+} TelSimSubscriberInfo_t;
 
 /**
  *This is used for authentication request procedure.
@@ -1919,73 +1801,66 @@ typedef struct {
 } TelSimAuthenticationResponse_t;
 
 /**OPLMN list**/
-typedef struct
-{
-       char    szMcc[TAPI_SIM_MCC_CODE_LEN+1];         /**< mobile country code */
-       char    szMnc[TAPI_SIM_MNC_CODE_LEN+1];         /**< mobile network code */
+typedef struct {
+       char szMcc[TAPI_SIM_MCC_CODE_LEN + 1]; /**< mobile country code */
+       char szMnc[TAPI_SIM_MNC_CODE_LEN + 1]; /**< mobile network code */
 
-}TelSimOplmnlistInfo_t;
+} TelSimOplmnlistInfo_t;
 
 /*OPLMN Access technology Identifiers*/
-typedef struct
-{
-       int bACT_RFU1;  /**<act rfu1 */
-       int bACT_RFU2;  /**<act rfu2 */
-       int bACT_RFU3;  /**<act rfu3 */
-       int bACT_RFU4;  /**<act rfu4 */
-       int bACT_RFU5;  /**<act rfu5 */
-       int bACT_RFU6;  /**<act rfu6 */
-       int bACT_RFU7;  /**<act rfu7 */
-       int bACT_UTRAN;  /**<act UTRAN */
-       int bACT_RFU9;  /**<act rfu9 */
-       int bACT_RFU10;  /**<act rfu10 */
-       int bACT_RFU11;  /**<act rfu11 */
-       int bACT_RFU12;  /**<act rfu12 */
-       int bACT_RFU13;  /**<act rfu13 */
-       int bACT_RFU15;  /**<act rfu15 */
-       int bACT_GSMCOMPACT;  /**<act GSM compact */
+typedef struct {
+       int bACT_RFU1; /**<act rfu1 */
+       int bACT_RFU2; /**<act rfu2 */
+       int bACT_RFU3; /**<act rfu3 */
+       int bACT_RFU4; /**<act rfu4 */
+       int bACT_RFU5; /**<act rfu5 */
+       int bACT_RFU6; /**<act rfu6 */
+       int bACT_RFU7; /**<act rfu7 */
+       int bACT_UTRAN; /**<act UTRAN */
+       int bACT_RFU9; /**<act rfu9 */
+       int bACT_RFU10; /**<act rfu10 */
+       int bACT_RFU11; /**<act rfu11 */
+       int bACT_RFU12; /**<act rfu12 */
+       int bACT_RFU13; /**<act rfu13 */
+       int bACT_RFU15; /**<act rfu15 */
+       int bACT_GSMCOMPACT; /**<act GSM compact */
        int bACT_GSM; /**<act GSM */
-}TelSimOplmnActInfo_t;
+} TelSimOplmnActInfo_t;
 
 /*OpLMNWACT  File data*/
-typedef struct
-{
-       TelSimOplmnlistInfo_t           OplmnList;       /**<oplmn list information */
-       TelSimOplmnActInfo_t            ActIdentifier;  /**<act identifier*/
-}TelSimOplmnWactInfo_t;
+typedef struct {
+       TelSimOplmnlistInfo_t OplmnList; /**<oplmn list information */
+       TelSimOplmnActInfo_t ActIdentifier; /**<act identifier*/
+} TelSimOplmnWactInfo_t;
 
 /* OPLMNWACT  list */
-typedef struct
-{
-       TelSimOplmnWactInfo_t OplmnList[TAPI_SIM_OPLMNWACT_MAX_LEN];    /**<oplmnwact list information */
-       int     OplmnListCnt; /**<oplmnwact list count */
-}TelSimOplmnWactList_t;
-
+typedef struct {
+       TelSimOplmnWactInfo_t OplmnList[TAPI_SIM_OPLMNWACT_MAX_LEN]; /**<oplmnwact list information */
+       int OplmnListCnt; /**<oplmnwact list count */
+} TelSimOplmnWactList_t;
 
 /* SAP (SIM Access Profile) related interface structures and enum */
 /**
  *
  * This struct gives the SAP ATR response data information.
  */
-typedef struct
-{
-       TelSimSapResultCode_t AtrResult;                                                /**<  SAP result of transfer ATR request */
-       unsigned long                   AtrLength;                                              /**<  SAP ATR response data length */
-       unsigned char                   AtrData[TAPI_SIM_SAP_ATR_DATA]; /**<  SAP ATR response data */
-}TelSimSapAtrInfo_t;
+typedef struct {
+       TelSimSapResultCode_t AtrResult; /**<  SAP result of transfer ATR request */
+       unsigned long AtrLength; /**<  SAP ATR response data length */
+       unsigned char AtrData[TAPI_SIM_SAP_ATR_DATA]; /**<  SAP ATR response data */
+} TelSimSapAtrInfo_t;
 
 /**
  *
  * This data structure gives the SAP ATR response data information.
  */
 
-typedef struct
-{
-       TelSimSapMsgId_t                                MsgId;                          /**< connect or disconnect request /response */ /* 1 byte  at lower level */
-       TelSimSapConnectionStatus_t     ConnectionStatus;       /**< used only in response from tapi */
-       unsigned short                          MaxMsgSize;                     /**< request from app or set by lower layer*/
+typedef struct {
+       TelSimSapMsgId_t MsgId; /**< connect or disconnect request /response *//* 1 byte  at lower level */
+       TelSimSapConnectionStatus_t ConnectionStatus; /**< used only in response from tapi */
+       unsigned short MaxMsgSize; /**< request from app or set by lower layer*/
 
-}TelSimSapConnect_t;
+} TelSimSapConnect_t;
 
 /* SAP transfer APDU request */
 
@@ -1993,43 +1868,34 @@ typedef struct
  *
  * This data structure gives the SAP APDU data information.
  */
-typedef struct
-{
-       unsigned char   ApduLength;                                             /**<  SAP APDU length */
-       unsigned char           Apdu[TAPI_SIM_APDU_MAX_LEN];    /**<  SAP APDU data */
-}TelSimSapApduData_t;
+typedef struct {
+       unsigned char ApduLength; /**<  SAP APDU length */
+       unsigned char Apdu[TAPI_SIM_APDU_MAX_LEN]; /**<  SAP APDU data */
+} TelSimSapApduData_t;
 
 /**
  *
  * This data structure gives SAP SIM power response
  */
-typedef struct
-{
-       TelSimSapMsgId_t                        MsgId;                  /**<  SAP operation Id */
-       TelSimSapResultCode_t   SimPowerResult; /**<  SAP result of operation */
-}TelSimSapPower_t;
+typedef struct {
+       TelSimSapMsgId_t MsgId; /**<  SAP operation Id */
+       TelSimSapResultCode_t SimPowerResult; /**<  SAP result of operation */
+} TelSimSapPower_t;
 
 /**
  *
  * This data structure gives SAP SIM card reader status
  */
-typedef struct
-{
-       TelSimSapResultCode_t   CardReaderResult; /**< SAP result of operation */
-       char                                    CardReaderStatus; /**< bit wise encoded information */
-}TelSimCardReaderStatus_t;
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
+typedef struct {
+       TelSimSapResultCode_t CardReaderResult; /**< SAP result of operation */
+       char CardReaderStatus; /**< bit wise encoded information */
+} TelSimCardReaderStatus_t;
 
 #ifdef __cplusplus
 }
 #endif
 
 #endif // _TELSIM_H_
-
 /**
-* @}
-*/
-
+ * @}
+ */
index 3d9abda..4e097a1 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 /**
-* @open
-* @ingroup             TelephonyAPI
-* @addtogroup  SS_TAPI SS(Supplementary services)
-* @{
-*
-* @file TelSs.h
+ * @open
+ * @ingroup            TelephonyAPI
+ * @addtogroup  SS_TAPI        SS(Supplementary services)
+ * @{
+ *
+ * @file TelSs.h
 
    @brief This file serves as a "C" header file and defines structures for Tapi Supplementary Services\n
     It contains a sample set of constants, enums, structs that would be required by applications.
+ @brief This file serves as a "C" header file and defines structures for Tapi Supplementary Services\n
+ It contains a sample set of constants, enums, structs that would be required by applications.
  */
 
 #ifndef _TEL_SS_H_
 #define _TEL_SS_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
+
 #include <TelDefines.h>
 #include <TelErr.h>
 
@@ -43,15 +41,6 @@ extern "C"
 {
 #endif
 
-
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 /** maximum length of barring password */
 #define TAPI_SS_GSM_BARR_PW_LEN_MAX                            4 /**<Maximum length of barring password */
 
@@ -71,528 +60,484 @@ extern "C"
 #define TAPI_MAX_RELEASE_COMPLETE_DATA_LEN             260
 #define TAPI_MAX_ULONG                                                 0xffffffff
 
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
  *  This enumeration defines the call forwarding flavor.
  */
-typedef enum
-{
-       TAPI_SS_FORWARD_WHEN_UNCONDITIONAL_EV ,                 /**< Unconditional */
-       TAPI_SS_FORWARD_WHEN_BUSY_EV ,                                          /**< When Busy */
-       TAPI_SS_FORWARD_WHEN_NO_ANSWER_EV ,                                     /**< When No Reply */
-       TAPI_SS_FORWARD_WHEN_NOT_REACHABLE_EV ,                         /**< When Not Reachable */
-       TAPI_SS_FORWARD_WHEN_ALL_FORWARDING_EV ,                        /**< Forward All Calls */
-       TAPI_SS_FORWARD_WHEN_ALL_CONDITIONAL_EV  ,                      /**< Conditional */
+typedef enum {
+       TAPI_SS_FORWARD_WHEN_UNCONDITIONAL_EV, /**< Unconditional */
+       TAPI_SS_FORWARD_WHEN_BUSY_EV, /**< When Busy */
+       TAPI_SS_FORWARD_WHEN_NO_ANSWER_EV, /**< When No Reply */
+       TAPI_SS_FORWARD_WHEN_NOT_REACHABLE_EV, /**< When Not Reachable */
+       TAPI_SS_FORWARD_WHEN_ALL_FORWARDING_EV, /**< Forward All Calls */
+       TAPI_SS_FORWARD_WHEN_ALL_CONDITIONAL_EV, /**< Conditional */
 } TelSsForwardWhen_t;
 
 /**
  * The various types of call barring. Note, only one type of incoming barring and only one type of outgoing barring may be active at any time.
  */
-typedef enum
-{
-       TAPI_CALL_BARRING_ALL  ,                                                                /**< Barring all outgoing and incoming calls */
-       TAPI_CALL_BARRING_OUTGOING ,                                                    /**< Barring outgoing call */
-       TAPI_CALL_BARRING_ALL_OUTGOING_CALLS ,                                  /**< Barring all outgoing calls */
-       TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL ,                    /**< Barring all outgoing international calls */
-       TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL_EXCEPT ,     /**< Barring all international outgoing */
-       TAPI_CALL_BARRING_INCOMING ,                                                    /**< Barring the incoming call */
-       TAPI_CALL_BARRING_ALL_INCOMING_CALLS ,                                  /**< Barring all incoming calls */
-       TAPI_CALL_BARRING_ALL_INCOMING_CALLS_ROAMING ,                  /**< Barring all incoming calls while roaming */
-       TAPI_CALL_BARRING_ALL_INCOMING_CALLS_INSIM ,                    /**< Barring Incoming Calls from numbers which is not stored in the SIM memory */
+typedef enum {
+       TAPI_CALL_BARRING_ALL, /**< Barring all outgoing and incoming calls */
+       TAPI_CALL_BARRING_OUTGOING, /**< Barring outgoing call */
+       TAPI_CALL_BARRING_ALL_OUTGOING_CALLS, /**< Barring all outgoing calls */
+       TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL, /**< Barring all outgoing international calls */
+       TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL_EXCEPT, /**< Barring all international outgoing */
+       TAPI_CALL_BARRING_INCOMING, /**< Barring the incoming call */
+       TAPI_CALL_BARRING_ALL_INCOMING_CALLS, /**< Barring all incoming calls */
+       TAPI_CALL_BARRING_ALL_INCOMING_CALLS_ROAMING, /**< Barring all incoming calls while roaming */
+       TAPI_CALL_BARRING_ALL_INCOMING_CALLS_INSIM, /**< Barring Incoming Calls from numbers which is not stored in the SIM memory */
 } TelSsCallBarType_t;
 
 /*
  * The types of telecommunication services are used for setting the statuses of supplementary services.
  * They are typically not supported in IS-2000 or IS-136. See GSM 02.30 Annex C and GSM 22.030 Annex C.
  */
-typedef enum
-{
-       TAPI_SS_TS_NONE = 0x00,                 /**< Teleservice None*/
-
-       TAPI_SS_TS_ALL_TELESERVICES,                                                    /**< All Teleservices */
-       TAPI_SS_TS_ALL_SPEECH ,                                         /**< All Speech Services */
-       TAPI_SS_TS_ALL_DATA_TELESERVICES,                                               /**< All Data Teleservices */
-       TAPI_SS_TS_FACS ,                                                                               /**< All Fax Service */
-       TAPI_SS_TS_SMS ,                                                                        /**< SMS service         */
-
-       TAPI_SS_TS_ALL_TELESERVICES_EXCEPT_SMS,                                 /**< All teleservice except SMS */
-       TAPI_SS_TS_ALL_PLMN_SPEC_TELE,                                          /**< PLMN specific teleservices*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_1,                                            /**< PLMN specific teleservice 1*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_2 ,                                           /**< PLMN specific teleservice 2*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_3 ,                                                   /**< PLMN specific teleservice 3*/
-
-       TAPI_SS_TS_PLMN_SPEC_TELE_4,                                                    /**< PLMN specific teleservice 4*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_5,                                                    /**< PLMN specific teleservice 5*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_6,                                                    /**< PLMN specific teleservice 6*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_7,                                                    /**< PLMN specific teleservice 7*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_8,                                                    /**< PLMN specific teleservice 8*/
-
-       TAPI_SS_TS_PLMN_SPEC_TELE_9,                                                    /**< PLMN specific teleservice 9*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_A,                                                    /**< PLMN specific teleservice 10*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_B,                                                    /**< PLMN specific teleservice 11*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_C,                                                    /**< PLMN specific teleservice 12*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_D,                                                    /**< PLMN specific teleservice 13*/
-
-       TAPI_SS_TS_PLMN_SPEC_TELE_E,                                                    /**< PLMN specific teleservice 14*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_F,                                                    /**< PLMN specific teleservice 15*/
-       TAPI_SS_TS_PLMN_SPEC_TELE_,                                                             /**< PLMN specific teleservice*/
-       TAPI_SS_BS_ALL_BEARER_SERVICES,                                                 /**< All PLMN specific bearer services*/
-       TAPI_SS_BS_ALL_DATA_CDA,                                                        /**< All Data CDA*/
-
-       TAPI_SS_BS_ALL_DATA_CDS,                                                                /**< All Data CDS*/
-       TAPI_SS_BS_ALL_ASYNCHRONOUS,                                                    /**< All  Asynchronous */
-       TAPI_SS_BS_ALL_SYNCHRONOUS,                                                             /**< All  Synchronous */
-       TAPI_SS_BS_DATA_CIRCUIT_SYNC,                                                   /**< All Data Circuit Synchronous */
-       TAPI_SS_BS_DATA_CIRCUIT_ASYNC,                                                  /**< All Data Circuit Asynchronous */
-
-       TAPI_SS_BS_DATA_ALL_PDS,                                                                /**< All Data PDS */
-       TAPI_SS_BS_ALL_DATA_PADCA,                                                              /**< All Data PADCA */
-       TAPI_SS_BS_ALL_PLMN_SPEC_BS,                                                    /**< All PLMN SPEC BS */
-       TAPI_SS_BS_PLMN_SPEC_TELE_1,                                                    /**< PLMN specific bearer service 1*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_2,                                                    /**< PLMN specific bearer service 2*/
-
-       TAPI_SS_BS_PLMN_SPEC_TELE_3,                                                    /**< PLMN specific bearer service 3*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_4,                                                    /**< PLMN specific bearer service 4*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_5,                                                    /**< PLMN specific bearer service 5*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_6,                                                    /**< PLMN specific bearer service 6*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_7,                                                    /**< PLMN specific bearer service 7*/
-
-       TAPI_SS_BS_PLMN_SPEC_TELE_8,                                                    /**< PLMN specific bearer service 8*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_9,                                                    /**< PLMN specific bearer service 9*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_A,                                                    /**< PLMN specific bearer service 10*/
-       TAPI_SS_BS_PLMN_SPEC_TELE_B,                                                    /**< PLMN specific bearer service 11 */
-       TAPI_SS_BS_PLMN_SPEC_TELE_C,                                                    /**< PLMN specific bearer service 12 */
-
-       TAPI_SS_BS_PLMN_SPEC_TELE_D,                                                    /**< PLMN specific bearer service 13 */
-       TAPI_SS_BS_PLMN_SPEC_TELE_E,                                                    /**< PLMN specific bearer service 14 */
-       TAPI_SS_BS_PLMN_SPEC_TELE_F,                                                    /**< PLMN specific bearer service 15*/
-       TAPI_SS_TS_ALL_DATA,                                                                    /**< All Data*/
-       TAPI_SS_TS_DATA_CIRCUIT_SYNC,                                                   /**< Data Circuit Sync*/
-
-       TAPI_SS_TS_MULTIPLE,                                                                    /**< multiple*/
-       TAPI_SS_TS_TELEPHONY,                                                                   /**< Telephony */
-       TAPI_SS_TS_DATA_CIRCUIT_ASYNC,                                                  /**< Data Circuit Async */
-       TAPI_SS_TS_DATA_PACKET,                                                                 /**< Data packet */
+typedef enum {
+       TAPI_SS_TS_NONE = 0x00, /**< Teleservice None*/
+
+       TAPI_SS_TS_ALL_TELESERVICES, /**< All Teleservices */
+       TAPI_SS_TS_ALL_SPEECH, /**< All Speech Services */
+       TAPI_SS_TS_ALL_DATA_TELESERVICES, /**< All Data Teleservices */
+       TAPI_SS_TS_FACS, /**< All Fax Service */
+       TAPI_SS_TS_SMS, /**< SMS service         */
+
+       TAPI_SS_TS_ALL_TELESERVICES_EXCEPT_SMS, /**< All teleservice except SMS */
+       TAPI_SS_TS_ALL_PLMN_SPEC_TELE, /**< PLMN specific teleservices*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_1, /**< PLMN specific teleservice 1*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_2, /**< PLMN specific teleservice 2*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_3, /**< PLMN specific teleservice 3*/
+
+       TAPI_SS_TS_PLMN_SPEC_TELE_4, /**< PLMN specific teleservice 4*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_5, /**< PLMN specific teleservice 5*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_6, /**< PLMN specific teleservice 6*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_7, /**< PLMN specific teleservice 7*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_8, /**< PLMN specific teleservice 8*/
+
+       TAPI_SS_TS_PLMN_SPEC_TELE_9, /**< PLMN specific teleservice 9*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_A, /**< PLMN specific teleservice 10*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_B, /**< PLMN specific teleservice 11*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_C, /**< PLMN specific teleservice 12*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_D, /**< PLMN specific teleservice 13*/
+
+       TAPI_SS_TS_PLMN_SPEC_TELE_E, /**< PLMN specific teleservice 14*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_F, /**< PLMN specific teleservice 15*/
+       TAPI_SS_TS_PLMN_SPEC_TELE_, /**< PLMN specific teleservice*/
+       TAPI_SS_BS_ALL_BEARER_SERVICES, /**< All PLMN specific bearer services*/
+       TAPI_SS_BS_ALL_DATA_CDA, /**< All Data CDA*/
+
+       TAPI_SS_BS_ALL_DATA_CDS, /**< All Data CDS*/
+       TAPI_SS_BS_ALL_ASYNCHRONOUS, /**< All  Asynchronous */
+       TAPI_SS_BS_ALL_SYNCHRONOUS, /**< All  Synchronous */
+       TAPI_SS_BS_DATA_CIRCUIT_SYNC, /**< All Data Circuit Synchronous */
+       TAPI_SS_BS_DATA_CIRCUIT_ASYNC, /**< All Data Circuit Asynchronous */
+
+       TAPI_SS_BS_DATA_ALL_PDS, /**< All Data PDS */
+       TAPI_SS_BS_ALL_DATA_PADCA, /**< All Data PADCA */
+       TAPI_SS_BS_ALL_PLMN_SPEC_BS, /**< All PLMN SPEC BS */
+       TAPI_SS_BS_PLMN_SPEC_TELE_1, /**< PLMN specific bearer service 1*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_2, /**< PLMN specific bearer service 2*/
+
+       TAPI_SS_BS_PLMN_SPEC_TELE_3, /**< PLMN specific bearer service 3*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_4, /**< PLMN specific bearer service 4*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_5, /**< PLMN specific bearer service 5*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_6, /**< PLMN specific bearer service 6*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_7, /**< PLMN specific bearer service 7*/
+
+       TAPI_SS_BS_PLMN_SPEC_TELE_8, /**< PLMN specific bearer service 8*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_9, /**< PLMN specific bearer service 9*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_A, /**< PLMN specific bearer service 10*/
+       TAPI_SS_BS_PLMN_SPEC_TELE_B, /**< PLMN specific bearer service 11 */
+       TAPI_SS_BS_PLMN_SPEC_TELE_C, /**< PLMN specific bearer service 12 */
+
+       TAPI_SS_BS_PLMN_SPEC_TELE_D, /**< PLMN specific bearer service 13 */
+       TAPI_SS_BS_PLMN_SPEC_TELE_E, /**< PLMN specific bearer service 14 */
+       TAPI_SS_BS_PLMN_SPEC_TELE_F, /**< PLMN specific bearer service 15*/
+       TAPI_SS_TS_ALL_DATA, /**< All Data*/
+       TAPI_SS_TS_DATA_CIRCUIT_SYNC, /**< Data Circuit Sync*/
+
+       TAPI_SS_TS_MULTIPLE, /**< multiple*/
+       TAPI_SS_TS_TELEPHONY, /**< Telephony */
+       TAPI_SS_TS_DATA_CIRCUIT_ASYNC, /**< Data Circuit Async */
+       TAPI_SS_TS_DATA_PACKET, /**< Data packet */
 
        /* CPHS - AUXILIARY SERVICE */
-       TAPI_SS_TS_AUX_VOICE ,                                                  /**< All Auxiliary Voice ( Auxiliary telephony ) */
+       TAPI_SS_TS_AUX_VOICE, /**< All Auxiliary Voice ( Auxiliary telephony ) */
 
-       TAPI_SS_ALL_TELE_BEARER,                                /**< all tele and bearer services */
-       TAPI_SS_TS_ALL_TELE_AND_BEARER_SERVICES,                                /**< Teleservices & Bearer Services */
-}TelSsTeleService_t;
+       TAPI_SS_ALL_TELE_BEARER, /**< all tele and bearer services */
+       TAPI_SS_TS_ALL_TELE_AND_BEARER_SERVICES, /**< Teleservices & Bearer Services */
+} TelSsTeleService_t;
 
 /**
  * This enumeration defines the ussd response type
  */
-typedef enum
-{
-       TAPI_USSD_RES_UNKNOWN_ALPHABET,                                         /**< USSD data is unknown */
-       TAPI_USSD_RES_DISPL_BUSY,                                               /**< USSD Data response is display busy  */
-       TAPI_USSD_RES_OK,                                               /**< USSD Data is encoded and properly propagated */
-       TAPI_USSD_RES_NONE                                              /**< NO USSD Response from client */
+typedef enum {
+       TAPI_USSD_RES_UNKNOWN_ALPHABET, /**< USSD data is unknown */
+       TAPI_USSD_RES_DISPL_BUSY, /**< USSD Data response is display busy  */
+       TAPI_USSD_RES_OK, /**< USSD Data is encoded and properly propagated */
+       TAPI_USSD_RES_NONE /**< NO USSD Response from client */
 } TelSsUssdRespType_t;
 
 /**
  * This enumeration defines the ussd Indication Type
  */
-typedef enum
-{
-       TAPI_USSD_IND_NOTIFY                    = 0x00,                                 /**< notify : to display USSD data to user */
-       TAPI_USSD_IND_NO_ACTION_REQUIRE = 0x01,                                 /**< No further user action required */
-       TAPI_USSD_IND_ACTION_REQUIRE    = 0x02,                                 /**< Further user action required*/
-       TAPI_USSD_IND_TERMINATED_BY_NET = 0x03,                         /**< 0x03 : USSD terminated by network */
-       TAPI_USSD_IND_OTHER_CLIENT              = 0x04,                 /**< 0x04 : other local client has responded */
-       TAPI_USSD_IND_NOT_SUPPORT               = 0x05,                 /**< 0x05 : operation not supported */
-       TAPI_USSD_IND_TIME_OUT                  = 0x06          /**< 0x06 : Time out when there is no response from network */
-}TelSsUssdIndType_t;
+typedef enum {
+       TAPI_USSD_IND_NOTIFY = 0x00, /**< notify : to display USSD data to user */
+       TAPI_USSD_IND_NO_ACTION_REQUIRE = 0x01, /**< No further user action required */
+       TAPI_USSD_IND_ACTION_REQUIRE = 0x02, /**< Further user action required*/
+       TAPI_USSD_IND_TERMINATED_BY_NET = 0x03, /**< 0x03 : USSD terminated by network */
+       TAPI_USSD_IND_OTHER_CLIENT = 0x04, /**< 0x04 : other local client has responded */
+       TAPI_USSD_IND_NOT_SUPPORT = 0x05, /**< 0x05 : operation not supported */
+       TAPI_USSD_IND_TIME_OUT = 0x06 /**< 0x06 : Time out when there is no response from network */
+} TelSsUssdIndType_t;
 
 /**
  *
  * This enum defines the values for USSD type.
  */
-typedef enum
-{
-       TAPI_USSD_USER_INIT = 0x01,     /**< USSD request type User Initiated. */
-       TAPI_USSD_USER_RSP,                     /**< USSD request type User Response. */
-       TAPI_USSD_USER_REL                      /**< USSD request type User Release. */
+typedef enum {
+       TAPI_USSD_USER_INIT = 0x01, /**< USSD request type User Initiated. */
+       TAPI_USSD_USER_RSP, /**< USSD request type User Response. */
+       TAPI_USSD_USER_REL /**< USSD request type User Release. */
 } TelSsUssdType_t;
 
 /**
  *  This enumeration defines the call barring operation mode .
  */
-typedef enum
-{
-       TAPI_SS_CALL_BAR_ACTIVATE,              /**< Activate call barring  */
-       TAPI_SS_CALL_BAR_DEACTIVATE,            /**< De Activate call barring */
-}TelSsCallBarOperationMode_t;
+typedef enum {
+       TAPI_SS_CALL_BAR_ACTIVATE, /**< Activate call barring  */
+       TAPI_SS_CALL_BAR_DEACTIVATE, /**< De Activate call barring */
+} TelSsCallBarOperationMode_t;
 
 /**
  *  This enumeration defines the call barring operation mode .
  */
-typedef enum
-{
-       TAPI_SS_CW_ACTIVATE,            /**< Activate call barring  */
-       TAPI_SS_CW_DEACTIVATE,          /**< De Activate call barring */
-}TelSsCallWaitOperationMode_t;
+typedef enum {
+       TAPI_SS_CW_ACTIVATE, /**< Activate call barring  */
+       TAPI_SS_CW_DEACTIVATE, /**< De Activate call barring */
+} TelSsCallWaitOperationMode_t;
 
 /**
  *  This enumeration defines the call type .
  */
-typedef enum
-{
-       TAPI_CALL_TYPE_VOICE_EV ,                               /**< Voice Call */
-       TAPI_CALL_TYPE_DATA_EV ,                                /**< Data Call */
-       TAPI_CALL_TYPE_FAX_EV ,                                 /**< FAX   Call */
-       TAPI_CALL_TYPE_SHORT_MESS_EV ,          /**< Short Message */
-       TAPI_CALL_TYPE_ALL_ASYNC_EV,    /**< All Async services */
-       TAPI_CALL_TYPE_ALL_SYNC_EV,     /**< All sync services */
-       TAPI_CALL_TYPE_DATA_CIRCUIT_SYNC_EV,    /**< Data Circuit Sync */
-       TAPI_CALL_TYPE_ALL_TELE_BEARER, /**< all tele and bearer services */
-       TAPI_CALL_TYPE_ALL_TELE,                /**< All tele services */
-}TelSsCallType_t;
+typedef enum {
+       TAPI_CALL_TYPE_VOICE_EV, /**< Voice Call */
+       TAPI_CALL_TYPE_DATA_EV, /**< Data Call */
+       TAPI_CALL_TYPE_FAX_EV, /**< FAX   Call */
+       TAPI_CALL_TYPE_SHORT_MESS_EV, /**< Short Message */
+       TAPI_CALL_TYPE_ALL_ASYNC_EV, /**< All Async services */
+       TAPI_CALL_TYPE_ALL_SYNC_EV, /**< All sync services */
+       TAPI_CALL_TYPE_DATA_CIRCUIT_SYNC_EV, /**< Data Circuit Sync */
+       TAPI_CALL_TYPE_ALL_TELE_BEARER, /**< all tele and bearer services */
+       TAPI_CALL_TYPE_ALL_TELE, /**< All tele services */
+} TelSsCallType_t;
 
 /**
  *  This enumeration defines the forward mode .
  */
-typedef enum
-{
-       TAPI_CALL_FORWARD_MODE_DISABLE_EV ,             /**< Deactivate call forwarding  */
-       TAPI_CALL_FORWARD_MODE_ENABLE_EV ,                              /**< Activate call forwarding */
-       TAPI_CALL_FORWARD_MODE_REGISTRATION_EV ,                /**< Register Call forwarding  */
-       TAPI_CALL_FORWARD_MODE_ERASURE_EV ,                             /**< De-register call forwarding */
-
-}TelSsForwardMode_t;
+typedef enum {
+       TAPI_CALL_FORWARD_MODE_DISABLE_EV, /**< Deactivate call forwarding  */
+       TAPI_CALL_FORWARD_MODE_ENABLE_EV, /**< Activate call forwarding */
+       TAPI_CALL_FORWARD_MODE_REGISTRATION_EV, /**< Register Call forwarding  */
+       TAPI_CALL_FORWARD_MODE_ERASURE_EV, /**< De-register call forwarding */
+} TelSsForwardMode_t;
 
 /**
  *  This enumeration defines the forward type .
  */
-typedef enum
-{
-       TAPI_CS_FORWARD_TYPE_VOICE_EV =0,                       /**< Voice call forward */
-       TAPI_CS_FORWARD_TYPE_ALL_ASYNC_EV,          /**< All Async services */
-       TAPI_CS_FORWARD_TYPE_ALL_SYNC_EV,                       /**< All sync services */
-       TAPI_CS_FORWARD_TYPE_DATA_EV ,                          /**< Data call forward */
-       TAPI_CS_FORWARD_TYPE_FAX_EV,                            /**< Fax call forward */
-    TAPI_CS_FORWARD_TYPE_ALL_TELE_BEARER,      /**< All tele and bearer services */
-    TAPI_CS_FORWARD_TYPE_ALL_TELE,             /**< All tele services */
-    TAPI_CS_FORWARD_TYPE_AUX_VOICE,            /**< AUX Voice */
-}TelSsForwardType_t;
-
-typedef enum
-{
-       TAPI_SS_CF_NO_REPLY_TIME_5_SECS = 5,                    /**< Timer value set to 5secs*/
-       TAPI_SS_CF_NO_REPLY_TIME_10_SECS        = 10,                   /**< Timer value set to 10secs*/
-       TAPI_SS_CF_NO_REPLY_TIME_15_SECS        = 15,                   /**< Timer value set to 15secs*/
-       TAPI_SS_CF_NO_REPLY_TIME_20_SECS        = 20,                   /**< Timer value set to 20secs*/
-       TAPI_SS_CF_NO_REPLY_TIME_25_SECS        = 25,                   /**< Timer value set to 25secs*/
-       TAPI_SS_CF_NO_REPLY_TIME_30_SECS        = 30,                   /**< Timer value set to 30secs*/
-}TelSsNoReplyTime_t;
+typedef enum {
+       TAPI_CS_FORWARD_TYPE_VOICE_EV = 0, /**< Voice call forward */
+       TAPI_CS_FORWARD_TYPE_ALL_ASYNC_EV, /**< All Async services */
+       TAPI_CS_FORWARD_TYPE_ALL_SYNC_EV, /**< All sync services */
+       TAPI_CS_FORWARD_TYPE_DATA_EV, /**< Data call forward */
+       TAPI_CS_FORWARD_TYPE_FAX_EV, /**< Fax call forward */
+       TAPI_CS_FORWARD_TYPE_ALL_TELE_BEARER, /**< All tele and bearer services */
+       TAPI_CS_FORWARD_TYPE_ALL_TELE, /**< All tele services */
+       TAPI_CS_FORWARD_TYPE_AUX_VOICE, /**< AUX Voice */
+} TelSsForwardType_t;
+
+typedef enum {
+       TAPI_SS_CF_NO_REPLY_TIME_5_SECS = 5, /**< Timer value set to 5secs*/
+       TAPI_SS_CF_NO_REPLY_TIME_10_SECS = 10, /**< Timer value set to 10secs*/
+       TAPI_SS_CF_NO_REPLY_TIME_15_SECS = 15, /**< Timer value set to 15secs*/
+       TAPI_SS_CF_NO_REPLY_TIME_20_SECS = 20, /**< Timer value set to 20secs*/
+       TAPI_SS_CF_NO_REPLY_TIME_25_SECS = 25, /**< Timer value set to 25secs*/
+       TAPI_SS_CF_NO_REPLY_TIME_30_SECS = 30, /**< Timer value set to 30secs*/
+} TelSsNoReplyTime_t;
 
 /**
  *  This enumeration type defines the Supplementary service types
  */
-typedef enum
-{
-       TAPI_SS_TYPE_BARRING,                /**< Barring SS */
-       TAPI_SS_TYPE_FORWARDING,                         /**<  Forward SS  */
-       TAPI_SS_TYPE_WAITING,                            /**<  Waiting SS */
-       TAPI_SS_TYPE_IDENTIFICATION,             /**< Identification SS  */
-       TAPI_SS_TYPE_CNAP,                                       /**< CNAP SS */
-       TAPI_SS_TYPE_USSD,                                       /**<  Unstructured supplementary data SS  */
-       TAPI_SS_TYPE_AOC,                                        /**< AOC SS*/
-}TelSsType_t;
-
-/**
-*  Describes whether a supplementary service request was a success or a failure; and if it failed, why.
-*/
-typedef enum
-{
- TAPI_SS_SUCCESS ,                                                     /**<  SS operation was successful */
- TAPI_SS_TIMEREXPIRE ,                                         /**< SS operation timer expired on network. */
- TAPI_SS_UNKNOWNSUBSCRIBER,                                    /**< SS error indicating unknown/illegal subscriber.  */
- TAPI_SS_BEARERSERVICENOTPROVISIONED,                  /**<The network returns this error when it is requested to  @n
-                                                                               perform an operation on a supplementary service  */
- TAPI_SS_TELESERVICENOTPROVISIONED,                    /**<The network returns this error when it is requested to perform  @n
-                                                                       an operation on a supplementary service  */
- TAPI_SS_ILLEGALSSOPERATION,   /**<This error is returned by the network when it is requested to perform an illegal operation @n
-                                                                               which is defined as not applicable for the relevant supplementary service */
- TAPI_SS_ERRORSTATUS,          /**<This error is returned by the network when it is requested to perform an operation @n
-                                                                               which is not compatible with the current status of the relevant supplementary service. */
- TAPI_SS_NOTAVAILABLE,                                         /**< SS not available in network */
- TAPI_SS_SUBSCRIPTIONVIOLATION,                                /**< SS service subscription violation. */
- TAPI_SS_INCOMPATIBILITY,                                              /**< This error is returned by the network when it is requested for a supplementary service operation incompatible with the @n
-                                                                                        status of another supplementary service or with the teleservice or bearer service for which the operation is requested */
- TAPI_SS_SYSTEMFAILURE,                                /**< This error is returned by the network, when it cannot perform an operation because of a failure in the network */
- TAPI_SS_DATAMISSING,                          /**< This error is returned by the network when an optional parameter is missing in an invoke component @n
-                                                                                       or an inner data structure, while it is required by the context of the request. */
- TAPI_SS_UNEXPECTEDDATAVALUE,                                  /**< SS error indicating unexpected data value on network side */   /**< SS operation barred.  */
- TAPI_SS_PWREGISTRATIONFAILURE,                                /**< SS error indicating change password failure. */
- TAPI_SS_NEGATIVEPWCHECK,                                      /**< SS error indicating negative password check.  */
- TAPI_SS_FACILITYNOTSUPPORTED,                         /**< SS service facility not supported  */
- TAPI_SS_RESOURCESNOTAVAILABLE,                                /**< SS error indicating resources not available in network.  */
- TAPI_SS_MAXNOMPTYEXCEEDED,                                    /**< SS error indicating Maximum MPTY is reached.  */
- TAPI_SS_CALLBARRED,   /**< This error is returned by the network to the MS when call independent subscriber control procedures are barred by the operator */
- TAPI_SS_NUMBEROFPWATTEMPTSVIOLATION,                  /**< SS error indicating barring password attempts violated.  */
- TAPI_SS_ABSENTSUBSCRIBER,                                     /**< This error is returned when the subscriber has activated the detach service or the system detects the absence condition */
- TAPI_SS_ILLEGALSUBSCRIBER,                                    /**<This error is returned when illegality of the access has been @n
-                                                                               established by use of authentication procedure. */
- TAPI_SS_ILLEGALEQUIPMENT,                                     /**<This error is returned when the IMEI check procedure has shown that  @n
-                                                                               the IMEI is blacklisted or not whitelisted  */
- TAPI_SS_USSDBUSY,                                             /**< SS error indicating USSD Busy(Already SS / USSD is ongoing).  */
- TAPI_SS_UNKNOWNALPHABET,                                      /**< SS error indicating unknown SS data coding of alphabet */
- TAPI_SS_INVALIDDEFLECTEDTONUMBER,                             /**< SS error indicating the invalid deflected to number.  */
- TAPI_SS_DEFLECTIONTOSERVEDSUBSCRIBER,                 /**< This error is returned if a diversion to the served  @n
-                                                                               subscriber's number was requested.  */
- TAPI_SS_SPECIALSERVICECODE,                                   /**< This error is returned if diversion to a special service code was requested.  */
- TAPI_SS_REJECTEDBYUSER,                                       /**< SS operation rejected by user.  */
- TAPI_SS_REJECTEDBYNETWORK,                                    /**< SS operation rejected by network.  */
- TAPI_SS_NET_NOT_ALLOWED_EMERGENCY_CALLS_ONLY, /**< SS operation is not allowed by network.  */
- TAPI_SS_UNKNOWNERROR  ,                                               /**< SS error indicating unknown error  */
- TAPI_SS_OEM_NOT_SUPPORTED                                     /**< If oem do not support any of SS requests, then this error will be returned back */
+typedef enum {
+       TAPI_SS_TYPE_BARRING, /**< Barring SS */
+       TAPI_SS_TYPE_FORWARDING, /**<  Forward SS  */
+       TAPI_SS_TYPE_WAITING, /**<  Waiting SS */
+       TAPI_SS_TYPE_IDENTIFICATION, /**< Identification SS  */
+       TAPI_SS_TYPE_CNAP, /**< CNAP SS */
+       TAPI_SS_TYPE_USSD, /**<  Unstructured supplementary data SS  */
+       TAPI_SS_TYPE_AOC, /**< AOC SS*/
+} TelSsType_t;
+
+/**
+ *  Describes whether a supplementary service request was a success or a failure; and if it failed, why.
+ */
+typedef enum {
+       TAPI_SS_SUCCESS, /**<  SS operation was successful */
+       TAPI_SS_TIMEREXPIRE, /**< SS operation timer expired on network. */
+       TAPI_SS_UNKNOWNSUBSCRIBER, /**< SS error indicating unknown/illegal subscriber.  */
+       TAPI_SS_BEARERSERVICENOTPROVISIONED, /**<The network returns this error when it is requested to  @n
+        perform an operation on a supplementary service  */
+       TAPI_SS_TELESERVICENOTPROVISIONED, /**<The network returns this error when it is requested to perform  @n
+        an operation on a supplementary service  */
+       TAPI_SS_ILLEGALSSOPERATION, /**<This error is returned by the network when it is requested to perform an illegal operation @n
+        which is defined as not applicable for the relevant supplementary service */
+       TAPI_SS_ERRORSTATUS, /**<This error is returned by the network when it is requested to perform an operation @n
+        which is not compatible with the current status of the relevant supplementary service. */
+       TAPI_SS_NOTAVAILABLE, /**< SS not available in network */
+       TAPI_SS_SUBSCRIPTIONVIOLATION, /**< SS service subscription violation. */
+       TAPI_SS_INCOMPATIBILITY, /**< This error is returned by the network when it is requested for a supplementary service operation incompatible with the @n
+        status of another supplementary service or with the teleservice or bearer service for which the operation is requested */
+       TAPI_SS_SYSTEMFAILURE, /**< This error is returned by the network, when it cannot perform an operation because of a failure in the network */
+       TAPI_SS_DATAMISSING, /**< This error is returned by the network when an optional parameter is missing in an invoke component @n
+        or an inner data structure, while it is required by the context of the request. */
+       TAPI_SS_UNEXPECTEDDATAVALUE, /**< SS error indicating unexpected data value on network side *//**< SS operation barred.  */
+       TAPI_SS_PWREGISTRATIONFAILURE, /**< SS error indicating change password failure. */
+       TAPI_SS_NEGATIVEPWCHECK, /**< SS error indicating negative password check.  */
+       TAPI_SS_FACILITYNOTSUPPORTED, /**< SS service facility not supported  */
+       TAPI_SS_RESOURCESNOTAVAILABLE, /**< SS error indicating resources not available in network.  */
+       TAPI_SS_MAXNOMPTYEXCEEDED, /**< SS error indicating Maximum MPTY is reached.  */
+       TAPI_SS_CALLBARRED, /**< This error is returned by the network to the MS when call independent subscriber control procedures are barred by the operator */
+       TAPI_SS_NUMBEROFPWATTEMPTSVIOLATION, /**< SS error indicating barring password attempts violated.  */
+       TAPI_SS_ABSENTSUBSCRIBER, /**< This error is returned when the subscriber has activated the detach service or the system detects the absence condition */
+       TAPI_SS_ILLEGALSUBSCRIBER, /**<This error is returned when illegality of the access has been @n
+        established by use of authentication procedure. */
+       TAPI_SS_ILLEGALEQUIPMENT, /**<This error is returned when the IMEI check procedure has shown that  @n
+        the IMEI is blacklisted or not whitelisted  */
+       TAPI_SS_USSDBUSY, /**< SS error indicating USSD Busy(Already SS / USSD is ongoing).  */
+       TAPI_SS_UNKNOWNALPHABET, /**< SS error indicating unknown SS data coding of alphabet */
+       TAPI_SS_INVALIDDEFLECTEDTONUMBER, /**< SS error indicating the invalid deflected to number.  */
+       TAPI_SS_DEFLECTIONTOSERVEDSUBSCRIBER, /**< This error is returned if a diversion to the served  @n
+        subscriber's number was requested.  */
+       TAPI_SS_SPECIALSERVICECODE, /**< This error is returned if diversion to a special service code was requested.  */
+       TAPI_SS_REJECTEDBYUSER, /**< SS operation rejected by user.  */
+       TAPI_SS_REJECTEDBYNETWORK, /**< SS operation rejected by network.  */
+       TAPI_SS_NET_NOT_ALLOWED_EMERGENCY_CALLS_ONLY, /**< SS operation is not allowed by network.  */
+       TAPI_SS_UNKNOWNERROR, /**< SS error indicating unknown error  */
+       TAPI_SS_OEM_NOT_SUPPORTED /**< If oem do not support any of SS requests, then this error will be returned back */
 } TelSsCause_t;
 
 /**
-*   The status of a supplementary service feature (e.g. Call Forwarding or Call Barring). @n
-*   These enumerated values should be used as masks
-*/
-typedef enum
-{
-       TAPI_SS_STATUS_ACTIVE ,                 /**< Provisioned & registered & active */
-       TAPI_SS_STATUS_REGISTERED ,             /**< Provisioned & registered (but not active/active-quiescent */
-       TAPI_SS_STATUS_PROVISIONED ,    /**<Provisioned but not registered (or active/active-quiescent) */
-       TAPI_SS_STATUS_QUIESCENT ,              /**< Provisioned & registered & active but quiescent */
-       TAPI_SS_STATUS_NOTHING                  /**< Not provisioned */
+ *   The status of a supplementary service feature (e.g. Call Forwarding or Call Barring). @n
+ *   These enumerated values should be used as masks
+ */
+typedef enum {
+       TAPI_SS_STATUS_ACTIVE, /**< Provisioned & registered & active */
+       TAPI_SS_STATUS_REGISTERED, /**< Provisioned & registered (but not active/active-quiescent */
+       TAPI_SS_STATUS_PROVISIONED, /**<Provisioned but not registered (or active/active-quiescent) */
+       TAPI_SS_STATUS_QUIESCENT, /**< Provisioned & registered & active but quiescent */
+       TAPI_SS_STATUS_NOTHING /**< Not provisioned */
 } TelSsStatus_t;
 
 /**
-* These are the four types of identity presentation / restriction services.
-*/
-typedef enum
-{
-       TAPI_CALLING_LINE_IDENTITY_PRESENTATION  ,      /**< identify the party calling this phone */
-       TAPI_CALLING_LINE_IDENTITY_RESTRICTION,         /**< hide the identity of this phone when calling others */
-       TAPI_CONNECTED_LINE_IDENTITY_PRESENTATION , /**< identify the party to whom the calling party (this phone) is connected */
-       TAPI_CONNECTED_LINE_IDENTITY_RESTRICTION ,      /**< restrict yourself from being identified by incoming calls, such as forwarded calls */
-       TAPI_CALLED_LINE_IDENTITY_PRESENTATION ,        /**< Called line identity presentation  */
-       TAPI_CALLING_NAME_PRESENTATION                          /**< Calling Name Presentation */
-}TelSsLineIdentificationType_t;
-
-/**
-*  This enumeration defines the cli service status .
-*/
-typedef enum{
-       TAPI_CLI_STATUS_NOT_PROVISONED =0x01,           /**<Service not provided by the service provider */
-       TAPI_CLI_STATUS_PROVISIONED,                            /**<Service is provided by the service provider */
-       TAPI_CLI_STATUS_ACTIVATED,                                      /**<Service is activated at the network */
-       TAPI_CLI_STATUS_UNKOWN,                                         /**<Service status is unknown*/
-       TAPI_CLI_STATUS_TEMP_RESTRICTED,                        /**<Service is temporarily restricted */
-       TAPI_CLI_STATUS_TEMP_ALLOWED                            /**<Service is temporarily allowed */
+ * These are the four types of identity presentation / restriction services.
+ */
+typedef enum {
+       TAPI_CALLING_LINE_IDENTITY_PRESENTATION, /**< identify the party calling this phone */
+       TAPI_CALLING_LINE_IDENTITY_RESTRICTION, /**< hide the identity of this phone when calling others */
+       TAPI_CONNECTED_LINE_IDENTITY_PRESENTATION, /**< identify the party to whom the calling party (this phone) is connected */
+       TAPI_CONNECTED_LINE_IDENTITY_RESTRICTION, /**< restrict yourself from being identified by incoming calls, such as forwarded calls */
+       TAPI_CALLED_LINE_IDENTITY_PRESENTATION, /**< Called line identity presentation  */
+       TAPI_CALLING_NAME_PRESENTATION /**< Calling Name Presentation */
+} TelSsLineIdentificationType_t;
+
+/**
+ *  This enumeration defines the cli service status .
+ */
+typedef enum {
+       TAPI_CLI_STATUS_NOT_PROVISONED = 0x01, /**<Service not provided by the service provider */
+       TAPI_CLI_STATUS_PROVISIONED, /**<Service is provided by the service provider */
+       TAPI_CLI_STATUS_ACTIVATED, /**<Service is activated at the network */
+       TAPI_CLI_STATUS_UNKOWN, /**<Service status is unknown*/
+       TAPI_CLI_STATUS_TEMP_RESTRICTED, /**<Service is temporarily restricted */
+       TAPI_CLI_STATUS_TEMP_ALLOWED /**<Service is temporarily allowed */
 } TelSsCliStatus_t;
 
 /**
  *  This enumeration defines the values for Cli service type .
  */
-typedef enum
-{
-       TAPI_SS_CLI_CLIP = 0x01,        /**< Calling Line Identification Presentation. */
-       TAPI_SS_CLI_CLIR = 0x02,        /**<  Calling Line Identification Restriction. */
-       TAPI_SS_CLI_COLP = 0x03,        /**<  Connected Line Identification Presentation. */
-       TAPI_SS_CLI_COLR = 0x04,        /**<  Connected Line Identification Restriction. */
-       TAPI_SS_CLI_CDIP = 0x05,                /**<  Called Line Identification Presentation. */
-       TAPI_SS_CLI_CNAP = 0x06,        /**<  Calling Name Presentation.*/
-}TelSsCliType_t;
+typedef enum {
+       TAPI_SS_CLI_CLIP = 0x01, /**< Calling Line Identification Presentation. */
+       TAPI_SS_CLI_CLIR = 0x02, /**<  Calling Line Identification Restriction. */
+       TAPI_SS_CLI_COLP = 0x03, /**<  Connected Line Identification Presentation. */
+       TAPI_SS_CLI_COLR = 0x04, /**<  Connected Line Identification Restriction. */
+       TAPI_SS_CLI_CDIP = 0x05, /**<  Called Line Identification Presentation. */
+       TAPI_SS_CLI_CNAP = 0x06, /**<  Calling Name Presentation.*/
+} TelSsCliType_t;
 
 /**
  * This enum defines the values for AOC type.
  */
-typedef enum
-{
-       TAPI_SS_AOC_TYPE_RESET  = 0x00, /**< Specifies the Reset MAXACM Value. */
-       TAPI_SS_AOC_TYPE_ACM    = 0x01, /**< Specifies the Accumulated call meter. */
-       TAPI_SS_AOC_TYPE_CCM    = 0x02, /**< Specifies the Current call meter. */
-       TAPI_SS_AOC_TYPE_MAXACM = 0x04, /**< Specifies the Max accumulated call meter. */
-       TAPI_SS_AOC_TYPE_PUC    = 0x08  /**< Specifies the Price per unit and currency.*/
-}TelSsAocType_t;
+typedef enum {
+       TAPI_SS_AOC_TYPE_RESET = 0x00, /**< Specifies the Reset MAXACM Value. */
+       TAPI_SS_AOC_TYPE_ACM = 0x01, /**< Specifies the Accumulated call meter. */
+       TAPI_SS_AOC_TYPE_CCM = 0x02, /**< Specifies the Current call meter. */
+       TAPI_SS_AOC_TYPE_MAXACM = 0x04, /**< Specifies the Max accumulated call meter. */
+       TAPI_SS_AOC_TYPE_PUC = 0x08 /**< Specifies the Price per unit and currency.*/
+} TelSsAocType_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
 /**
  *  This structure  defines the different parameters related to forward info.
  */
-typedef struct
-{
-       TelSsForwardMode_t      Mode;           /**< Forward Mode */
-       TelSsForwardType_t      Type;           /**< Forward Type */
-       TelSsForwardWhen_t      Condition;      /**< Forward Condition */
-       char                            szPhoneNumber[TAPI_CALL_DIALDIGIT_LEN_MAX];     /**< Phone Number*/
-       TelSsNoReplyTime_t      NoReplyConditionTimer;                                          /**< No reply wait time 5-30 secs in intervals of 5. */
+typedef struct {
+       TelSsForwardMode_t Mode; /**< Forward Mode */
+       TelSsForwardType_t Type; /**< Forward Type */
+       TelSsForwardWhen_t Condition; /**< Forward Condition */
+       char szPhoneNumber[TAPI_CALL_DIALDIGIT_LEN_MAX]; /**< Phone Number*/
+       TelSsNoReplyTime_t NoReplyConditionTimer; /**< No reply wait time 5-30 secs in intervals of 5. */
 } TelSsForwardInfo_t;
 
 /**
  *  This structure defines the values for USSD request type.
  */
-typedef struct
-{
-       int                     UssdStringLength;       /**< USSD  String Length */
-       char                    szUssdString[TAPI_SS_USSD_DATA_SIZE_MAX];       /**< USSD  String */
-}TelSsUssdMsgInfo_t;
+typedef struct {
+       int UssdStringLength; /**< USSD  String Length */
+       char szUssdString[TAPI_SS_USSD_DATA_SIZE_MAX]; /**< USSD  String */
+} TelSsUssdMsgInfo_t;
 
 /**
-*This structure defines the UssdMessageResponse Information
-*/
+ *This structure defines the UssdMessageResponse Information
+ */
 typedef struct {
-       TelSsUssdRespType_t     SsRespType;                     /**< USSD Response Type*/
-       TelSsUssdIndType_t      IndType;                        /**< USSD Indication Type*/
-       TelSsUssdMsgInfo_t  UssdInfo;           /**< USSD Data*/
-}TelSsUssdMsgRspInfo_t;
+       TelSsUssdRespType_t SsRespType; /**< USSD Response Type*/
+       TelSsUssdIndType_t IndType; /**< USSD Indication Type*/
+       TelSsUssdMsgInfo_t UssdInfo; /**< USSD Data*/
+} TelSsUssdMsgRspInfo_t;
 
 typedef struct {
-       TelSsUssdIndType_t IndType;     /**< USSD Indication Type*/
-       TelSsUssdMsgInfo_t UssdInfo;    /**< USSD Data */
+       TelSsUssdIndType_t IndType; /**< USSD Indication Type*/
+       TelSsUssdMsgInfo_t UssdInfo; /**< USSD Data */
 } TelSsUssdMsgIndInfo_t;
 
 /**
  *  This structure  defines the different parameters related to call barring.
  */
-typedef struct
-{
-       TelSsCallBarOperationMode_t     Mode;           /**< Barring mode  */
-       TelSsCallBarType_t                      Type;           /**< Barring type */
-       TelSsCallType_t                 CallType;       /**< Call type */
-       char                                            szPassword[TAPI_SS_GSM_BARR_PW_LEN_MAX];  /**< password */
+typedef struct {
+       TelSsCallBarOperationMode_t Mode; /**< Barring mode  */
+       TelSsCallBarType_t Type; /**< Barring type */
+       TelSsCallType_t CallType; /**< Call type */
+       char szPassword[TAPI_SS_GSM_BARR_PW_LEN_MAX]; /**< password */
 } TelSsCallBarringInfo_t;
 
 /**
  *  This structure  defines the different parameters related to call waiting.
  */
-typedef struct
-{
-       TelSsCallWaitOperationMode_t    Mode;           /**< Waiting mode  */
-       TelSsCallType_t                         CallType;       /**< Call type */
+typedef struct {
+       TelSsCallWaitOperationMode_t Mode; /**< Waiting mode  */
+       TelSsCallType_t CallType; /**< Call type */
 } TelSsWaitingInfo_t;
 
 /**
-* This structure defines the values for Calling line identity service
-*/
-typedef struct
-{
-        TelSsLineIdentificationType_t  IdentificationType;     /**< Various line identification types */
-        TelSsCliStatus_t                               CliStatus;                      /**< Line identification status from network */
-}TelSsCliRecord_t;
+ * This structure defines the values for Calling line identity service
+ */
+typedef struct {
+       TelSsLineIdentificationType_t IdentificationType; /**< Various line identification types */
+       TelSsCliStatus_t CliStatus; /**< Line identification status from network */
+} TelSsCliRecord_t;
 
 /**
  * This structure defines the release complete message notification type.
  */
-typedef struct{
-       unsigned char   RelCompMsgLen;                                                                          /**< Specifies the Release complete msg length.*/
-    unsigned char      szRelCompMsg[ TAPI_MAX_RELEASE_COMPLETE_DATA_LEN ];     /**<  Specifies the Release complete msg. */
+typedef struct {
+       unsigned char RelCompMsgLen; /**< Specifies the Release complete msg length.*/
+       unsigned char szRelCompMsg[TAPI_MAX_RELEASE_COMPLETE_DATA_LEN]; /**<  Specifies the Release complete msg. */
 } TelSsRelCompMsgInfo_t;
 
 /**
  * This structure defines the values for AOC request type.
  */
 
-typedef struct
-{
-    float PPM;
-    unsigned char CharTypeOfCurrency;
-    unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX];
+typedef struct {
+       float PPM;
+       unsigned char CharTypeOfCurrency;
+       unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX];
 } TelAocPucInfo_t;
 
-typedef struct
-{
-       TelSsAocType_t AocType;                         /**< Specifies the AOC type. */
-       unsigned int    ACM;                                    /**< Specifies the accumulated call meter value. */
-       unsigned int    MaxAcm;                         /**< Specifies the maximum value of ACM . */
-       float   CCM;                                            /**< Specifies the Current call meter value. */
-       float   PPM;                                            /**< Specifies the Price per unit value. */
-       unsigned char CharTypeOfCurrency;                       /**< Specifies the Char type of currency. */
-       unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX];                 /**< Specifies the Currency characters. */
+typedef struct {
+       TelSsAocType_t AocType; /**< Specifies the AOC type. */
+       unsigned int ACM; /**< Specifies the accumulated call meter value. */
+       unsigned int MaxAcm; /**< Specifies the maximum value of ACM . */
+       float CCM; /**< Specifies the Current call meter value. */
+       float PPM; /**< Specifies the Price per unit value. */
+       unsigned char CharTypeOfCurrency; /**< Specifies the Char type of currency. */
+       unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX]; /**< Specifies the Currency characters. */
 } TelCallAocInfo_t;
 
 /**
-* This structure defines the values for ss call barring record
-*/
-typedef struct
-{
-       struct{
-       TelSsStatus_t                           Status;                                 /**< SS status  */
-       TelSsCallBarType_t                      Flavour;                                /**< Call barring types providing various barring conditions on that basis call be barred */
-       TelSsTeleService_t                      TeleCommService;                /**<  Teleservice */
-       } rec_class[TAPI_SS_RECORD_NUM_MAX];                            /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
-} TelSsCallBarringRecord_t ;
+ * This structure defines the values for ss call barring record
+ */
+typedef struct {
+       struct {
+               TelSsStatus_t Status; /**< SS status  */
+               TelSsCallBarType_t Flavour; /**< Call barring types providing various barring conditions on that basis call be barred */
+               TelSsTeleService_t TeleCommService; /**<  Teleservice */
+       } rec_class[TAPI_SS_RECORD_NUM_MAX]; /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
+} TelSsCallBarringRecord_t;
 
 /**
-* This structure defines the values for ss call forwarding record
-*/
-typedef struct
-{
-      struct{
-       TelSsStatus_t                   Status;                                                 /**< Call forwarding SS status */
-       TelSsForwardWhen_t              ForwardCondition;                               /**< Call forward types providing various conditions when call can be forwarded */
-       TelSsTeleService_t              TeleCommService;                                /**< Teleservice type */
-       int                                             bCallForwardingNumberPresent;   /**< Call forwarding number present or not */
-       unsigned char                   NoReplyWaitTime;
-       unsigned char                   szCallForwardingNumber[TAPI_CALL_DIALDIGIT_LEN_MAX]; /**< forwarded number.[Null Terminated string]*/
-       } rec_class[TAPI_SS_RECORD_NUM_MAX];                                    /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
+ * This structure defines the values for ss call forwarding record
+ */
+typedef struct {
+       struct {
+               TelSsStatus_t Status; /**< Call forwarding SS status */
+               TelSsForwardWhen_t ForwardCondition; /**< Call forward types providing various conditions when call can be forwarded */
+               TelSsTeleService_t TeleCommService; /**< Teleservice type */
+               int bCallForwardingNumberPresent; /**< Call forwarding number present or not */
+               unsigned char NoReplyWaitTime;
+               unsigned char szCallForwardingNumber[TAPI_CALL_DIALDIGIT_LEN_MAX]; /**< forwarded number.[Null Terminated string]*/
+       } rec_class[TAPI_SS_RECORD_NUM_MAX]; /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
 
 } TelSsForwardRecord_t;
 
 /**
-* This structure defines the values for ss call waiting record
-*/
-typedef struct
-{
+ * This structure defines the values for ss call waiting record
+ */
+typedef struct {
        struct {
-        TelSsStatus_t                  Status;                  /**< SS status */
-        TelSsTeleService_t             TeleCommService;                 /**< Teleservice */
-        } rec_class[TAPI_SS_RECORD_NUM_MAX];                    /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
+               TelSsStatus_t Status; /**< SS status */
+               TelSsTeleService_t TeleCommService; /**< Teleservice */
+       } rec_class[TAPI_SS_RECORD_NUM_MAX]; /**< Specifies the  Maximum of TAPI_SS_RECORD_NUM_MAX records. */
 } TelSsCallWaitingRecord_t;
 
 /**
-*This structure defines the parameters for SS record type
-*/
-typedef union
-{
-       TelSsCallWaitingRecord_t                WaitingRecord;          /**< Call waiting information */
-       TelSsCallBarringRecord_t                BarringRecord;          /**< Call barring information*/
-       TelSsCliRecord_t                                CliRecord;                      /**< Line identification information */
-       TelSsForwardRecord_t                    ForwardingRecord;       /**< Call forward record information */
-}TelSsRecord_t;
+ *This structure defines the parameters for SS record type
+ */
+typedef union {
+       TelSsCallWaitingRecord_t WaitingRecord; /**< Call waiting information */
+       TelSsCallBarringRecord_t BarringRecord; /**< Call barring information*/
+       TelSsCliRecord_t CliRecord; /**< Line identification information */
+       TelSsForwardRecord_t ForwardingRecord; /**< Call forward record information */
+} TelSsRecord_t;
 
 /**
-* related all kind of SS information
-*/
-typedef struct
-{
-       TelSsType_t                             SsType;                         /**< Supplementary service type */
-       TelSsStatus_t                           SsStatus;                       /**<SS status information */
-       unsigned int                            NumberOfRecords;        /**< Number of records present for Call Barring / Call forwarding / Call waiting. In case of any error, this parameter value will be set to zero.*/
-       TelSsRecord_t                           SsRecord;       /**< SS record (Union of Call Barring / Call Forwarding/Call waiting / line identification information). This structure can be Null when number_of_records parameter is zero.*/
-       TelSsTeleService_t                      SsTeleserviceType;      /**< Teleservice type */
+ * related all kind of SS information
+ */
+typedef struct {
+       TelSsType_t SsType; /**< Supplementary service type */
+       TelSsStatus_t SsStatus; /**<SS status information */
+       unsigned int NumberOfRecords; /**< Number of records present for Call Barring / Call forwarding / Call waiting. In case of any error, this parameter value will be set to zero.*/
+       TelSsRecord_t SsRecord; /**< SS record (Union of Call Barring / Call Forwarding/Call waiting / line identification information). This structure can be Null when number_of_records parameter is zero.*/
+       TelSsTeleService_t SsTeleserviceType; /**< Teleservice type */
 } TelSsInfo_t;
 
-typedef struct
-{
-       float   PPM;                                    /**< Specifies the Price per unit value. */
-       unsigned char CharTypeOfCurrency;                       /**< Specifies the Char type of currency. */
-       unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX];         /**< Specifies the Currency characters. */
+typedef struct {
+       float PPM; /**< Specifies the Price per unit value. */
+       unsigned char CharTypeOfCurrency; /**< Specifies the Char type of currency. */
+       unsigned char szCurrency[TAPI_SS_AOC_CURRENCY_LEN_MAX]; /**< Specifies the Currency characters. */
 } TelSsAoc_ppm_info_t;
 
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
 
 #endif // _TEL_SS_H_
-
 /**
-* @}
-*/
-
+ * @}
+ */
index 5831ee2..77cefdc 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  */
 
 /**
-* @open
-* @ingroup             TelephonyAPI
-* @addtogroup  COMMON_TAPI     COMMON
-* @{
-*
-* @file TelUtility.h
-
    @brief This file serves as a "C" header file defines structures for Utility Services. \n
     It contains a sample set of constants, enums, structs that would be required by applications.
+ * @open
+ * @ingroup            TelephonyAPI
+ * @addtogroup COMMON_TAPI     COMMON
+ * @{
+ *
+ * @file TelUtility.h
+
+ @brief This file serves as a "C" header file defines structures for Utility Services. \n
+ It contains a sample set of constants, enums, structs that would be required by applications.
  */
 
 #ifndef _TEL_UTILITY_H_
 #define _TEL_UTILITY_H_
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
+
 #ifdef __cplusplus
 extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 #define INVALID_REQUEST_ID     -1    /**< Invalid RequestId Value */
 
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
-* @enum TapiResult_t
-* Below enumerations are the return codes of TAPI API's
-*/
-typedef enum
-{
-       TAPI_API_SUCCESS                                                =  0,   /**<No Error occurred */
-       TAPI_API_INVALID_INPUT                                  = -1,   /**<input values are not correct in TAPI Library */
-       TAPI_API_INVALID_PTR                    = -2,   /**<invalid pointer */
-       TAPI_API_NOT_SUPPORTED                  = -3,   /**<The feature corresponding to requested API is not supported. This may be due to market/network/vendor reasons such as the feature is not available in the network. */
-       TAPI_API_DEPRICATED                                             = -4,   /**<This API is deprecated and will be so in future also */
-       TAPI_API_SYSTEM_OUT_OF_MEM                              = -5,   /**<Out of memory */
-       TAPI_API_SYSTEM_RPC_LINK_DOWN                   = -6,   /**<RPC link down */
-       TAPI_API_SERVICE_NOT_READY                              = -7,   /**<Phone was powered on, but yet to receive the power up completed notification */
-       TAPI_API_SERVER_FAILURE         = -8,   /**<error occurred in Telephony server  */
-       TAPI_API_OEM_PLUGIN_FAILURE     = -9,   /**<Plug-in layer failure */
-       TAPI_API_TRANSPORT_LAYER_FAILURE                = -10,  /**<Transport layer Failure*/
-       TAPI_API_INVALID_DATA_LEN                               = -11,  /**<Invalid data length */
-       TAPI_API_REQUEST_MAX_IN_PROGRESS                = -12,  /**<Maximum number of API Request for the same service are already in progress */
-       TAPI_API_OFFLINE_MODE_ERROR                     = -13,  /**<OEM Telephony Provider is in Offline mode. */
-       TAPI_EVENT_CLASS_UNKNOWN                                = -14,  /**<Event class specified is not present in Event Class list. - 20*/
-       TAPI_EVENT_UNKNOWN                              = -15,  /**<Event specified is not present in TAPI Unsolicited Event list. */
-       TAPI_REGISTRATION_OP_FAILED                             = -16,  /**<Callback Registration/De-registration failed */
-       TAPI_API_OPERATION_FAILED                               = -17,  /**<API operation failed*/
-       TAPI_API_INVALID_OPERATION                              = -18,  /**<API Invalid Operation */
-
-       TAPI_API_SYSTEM_RPC_LINK_NOT_EST                = -100, /**< RPC link down */
-       TAPI_API_API_NOT_SUPPORTED                              = -101, /**<API not supported */
-       TAPI_API_SERVER_LAYER_FAILURE                   = -102, /**< Server layer failure*/
+ * @enum TapiResult_t
+ * Below enumerations are the return codes of TAPI API's
+ */
+typedef enum {
+       TAPI_API_SUCCESS = 0, /**<No Error occurred */
+       TAPI_API_INVALID_INPUT = -1, /**<input values are not correct in TAPI Library */
+       TAPI_API_INVALID_PTR = -2, /**<invalid pointer */
+       TAPI_API_NOT_SUPPORTED = -3, /**<The feature corresponding to requested API is not supported. This may be due to market/network/vendor reasons such as the feature is not available in the network. */
+       TAPI_API_DEPRICATED = -4, /**<This API is deprecated and will be so in future also */
+       TAPI_API_SYSTEM_OUT_OF_MEM = -5, /**<Out of memory */
+       TAPI_API_SYSTEM_RPC_LINK_DOWN = -6, /**<RPC link down */
+       TAPI_API_SERVICE_NOT_READY = -7, /**<Phone was powered on, but yet to receive the power up completed notification */
+       TAPI_API_SERVER_FAILURE = -8, /**<error occurred in Telephony server  */
+       TAPI_API_OEM_PLUGIN_FAILURE = -9, /**<Plug-in layer failure */
+       TAPI_API_TRANSPORT_LAYER_FAILURE = -10, /**<Transport layer Failure*/
+       TAPI_API_INVALID_DATA_LEN = -11, /**<Invalid data length */
+       TAPI_API_REQUEST_MAX_IN_PROGRESS = -12, /**<Maximum number of API Request for the same service are already in progress */
+       TAPI_API_OFFLINE_MODE_ERROR = -13, /**<OEM Telephony Provider is in Offline mode. */
+       TAPI_EVENT_CLASS_UNKNOWN = -14, /**<Event class specified is not present in Event Class list. - 20*/
+       TAPI_EVENT_UNKNOWN = -15, /**<Event specified is not present in TAPI Unsolicited Event list. */
+       TAPI_REGISTRATION_OP_FAILED = -16, /**<Callback Registration/De-registration failed */
+       TAPI_API_OPERATION_FAILED = -17, /**<API operation failed*/
+       TAPI_API_INVALID_OPERATION = -18, /**<API Invalid Operation */
+
+       TAPI_API_SYSTEM_RPC_LINK_NOT_EST = -100, /**< RPC link down */
+       TAPI_API_API_NOT_SUPPORTED = -101, /**<API not supported */
+       TAPI_API_SERVER_LAYER_FAILURE = -102, /**< Server layer failure*/
 
        /*      CALL */
-       TAPI_API_INVALID_CALL_ID                                = -200, /**< Invalid call ID*/
-       TAPI_API_CALL_CTXT_OVERFLOW                             = -201, /**<Call context overflow */
-       TAPI_API_COULD_NOT_GET_CALL_CTXT                = -202, /**< Could not get call  context*/
-       TAPI_API_CTXT_SEARCH_RET_NON_CALL_CTXT  = -203, /**< Context search returned non-call context*/
-       TAPI_API_COULD_NOT_DESTROY_CTXT                 = -204, /**< could not destroy context*/
-       TAPI_API_INVALID_LINE_ID                                = -205, /**< invalid line ID*/
-       TAPI_API_INVALID_CALL_HANDLE                    = -206, /**<Invalid call handle  - 35*/
-       TAPI_API_INVALID_CALL_STATE                             = -207, /**<Invalid call state- Newly added. Need to raise a CR for this */
-       TAPI_API_CALL_PRE_COND_FAILED                   = -208, /**<Pre condition like MO call can not be established now.*/
-       TAPI_API_CALL_SAME_REQ_PENDING                  = -209, /**<  Can not accept same request multiple times  */
+       TAPI_API_INVALID_CALL_ID = -200, /**< Invalid call ID*/
+       TAPI_API_CALL_CTXT_OVERFLOW = -201, /**<Call context overflow */
+       TAPI_API_COULD_NOT_GET_CALL_CTXT = -202, /**< Could not get call  context*/
+       TAPI_API_CTXT_SEARCH_RET_NON_CALL_CTXT = -203, /**< Context search returned non-call context*/
+       TAPI_API_COULD_NOT_DESTROY_CTXT = -204, /**< could not destroy context*/
+       TAPI_API_INVALID_LINE_ID = -205, /**< invalid line ID*/
+       TAPI_API_INVALID_CALL_HANDLE = -206, /**<Invalid call handle  - 35*/
+       TAPI_API_INVALID_CALL_STATE = -207, /**<Invalid call state- Newly added. Need to raise a CR for this */
+       TAPI_API_CALL_PRE_COND_FAILED = -208, /**<Pre condition like MO call can not be established now.*/
+       TAPI_API_CALL_SAME_REQ_PENDING = -209, /**<  Can not accept same request multiple times  */
 
        /*      POWER   */
-       TAPI_API_MODEM_POWERED_OFF                              = -300, /**<The Modem is powered off */
-       TAPI_API_MODEM_ALREADY_ON                               = -301, /**<Modem already on */
-       TAPI_API_MODEM_ALREADY_OFF                              = -302, /**<Modem already off */
+       TAPI_API_MODEM_POWERED_OFF = -300, /**<The Modem is powered off */
+       TAPI_API_MODEM_ALREADY_ON = -301, /**<Modem already on */
+       TAPI_API_MODEM_ALREADY_OFF = -302, /**<Modem already off */
 
        /* NETTEXT */
-       TAPI_API_NETTEXT_DEVICE_NOT_READY               = -400, /**<Nettext device not ready */
-       TAPI_API_NETTEXT_SCADDR_NOT_SET                 = -401, /**<Nettext SCA address not set */
-       TAPI_API_NETTEXT_INVALID_DATA_LEN               = -402, /**<Nettext Invalid data length */
-       TAPI_NETTEXT_SCADDRESS_NOT_SET                  = -403, /**<Nettext SCA address not set*/
+       TAPI_API_NETTEXT_DEVICE_NOT_READY = -400, /**<Nettext device not ready */
+       TAPI_API_NETTEXT_SCADDR_NOT_SET = -401, /**<Nettext SCA address not set */
+       TAPI_API_NETTEXT_INVALID_DATA_LEN = -402, /**<Nettext Invalid data length */
+       TAPI_NETTEXT_SCADDRESS_NOT_SET = -403, /**<Nettext SCA address not set*/
 
        /* SIM  */
-       TAPI_API_SIM_BUSY                                               = -500, /**<SIM is busy  */
-       TAPI_API_SIM_CARD_PERMANENT_ERROR               = -501, /**<SIM error/blocked state */
-       TAPI_API_SIM_NOT_INITIALIZED                    = -502, /**<SIM has not initialized yet (waiting for PIN verification, etc) */
-       TAPI_API_SIM_NOT_FOUND                                  = -503, /**<SIM is not present / removed */
-       TAPI_API_SIM_SIM_SESSION_FULL                   = -504, /**< SIM session full*/
-       TAPI_API_SIM_INVALID_CARD_TYPE                  = -505, /**< SIM Invalid Application ID*/
-       TAPI_API_SIM_INVALID_SESSION                    = -506, /**<SIM Invalid Session */
-       TAPI_API_SIM_FILE_TYPE_WRONG                    = -507, /**<SIM file type wrong */
-       TAPI_API_SIM_FILE_ENCODE_FAIL                   = -508, /**<SIM file encode fail */
-       TAPI_API_SIM_FILE_DECODE_FAIL                   = -509, /**< SIM file decode fail*/
-       TAPI_API_SIM_FILE_INVALID_ENCODE_LEN    = -510, /**< SIM invalid encode length*/
-       TAPI_API_SIM_INVALID_RECORD_NUM         = -511, /**<SIM Invalid record number */
-       TAPI_API_SIM_CASE_NOT_HANDLED                   = -512, /**< SIM case not handled*/
-       TAPI_API_SIM_OEM_UNKNOWN_SIM_CARD               = -513, /**<SIM OEM unknown SIM card */
-       TAPI_API_SIM_SEC_UKNOWN_PIN_TYPE                = -514, /**<SIM unknown pin type */
-       TAPI_API_SIM_SEC_INVALID_PIN_TYPE               = -515, /**<SIM invalid pin type */
-       TAPI_API_SIM_SEC_LOCK_PERS_ENABLED              = -516, /**<SIM Lock Personalization status(PN/PU/PP/PC) */
-       TAPI_API_SIM_PB_INVALID_STORAGE_TYPE    = -517, /**<SIM phonebook invalid storage type */
+       TAPI_API_SIM_BUSY = -500, /**<SIM is busy  */
+       TAPI_API_SIM_CARD_PERMANENT_ERROR = -501, /**<SIM error/blocked state */
+       TAPI_API_SIM_NOT_INITIALIZED = -502, /**<SIM has not initialized yet (waiting for PIN verification, etc) */
+       TAPI_API_SIM_NOT_FOUND = -503, /**<SIM is not present / removed */
+       TAPI_API_SIM_SIM_SESSION_FULL = -504, /**< SIM session full*/
+       TAPI_API_SIM_INVALID_CARD_TYPE = -505, /**< SIM Invalid Application ID*/
+       TAPI_API_SIM_INVALID_SESSION = -506, /**<SIM Invalid Session */
+       TAPI_API_SIM_FILE_TYPE_WRONG = -507, /**<SIM file type wrong */
+       TAPI_API_SIM_FILE_ENCODE_FAIL = -508, /**<SIM file encode fail */
+       TAPI_API_SIM_FILE_DECODE_FAIL = -509, /**< SIM file decode fail*/
+       TAPI_API_SIM_FILE_INVALID_ENCODE_LEN = -510, /**< SIM invalid encode length*/
+       TAPI_API_SIM_INVALID_RECORD_NUM = -511, /**<SIM Invalid record number */
+       TAPI_API_SIM_CASE_NOT_HANDLED = -512, /**< SIM case not handled*/
+       TAPI_API_SIM_OEM_UNKNOWN_SIM_CARD = -513, /**<SIM OEM unknown SIM card */
+       TAPI_API_SIM_SEC_UKNOWN_PIN_TYPE = -514, /**<SIM unknown pin type */
+       TAPI_API_SIM_SEC_INVALID_PIN_TYPE = -515, /**<SIM invalid pin type */
+       TAPI_API_SIM_SEC_LOCK_PERS_ENABLED = -516, /**<SIM Lock Personalization status(PN/PU/PP/PC) */
+       TAPI_API_SIM_PB_INVALID_STORAGE_TYPE = -517, /**<SIM phonebook invalid storage type */
 
        /* SAT  */
-       TAPI_API_SAT_INVALID_COMMAND_ID                 = -600, /**<Command Number Invalid      */
-       TAPI_API_SAT_COMMAND_TYPE_MISMATCH              = -601, /**<    Command Type Mismatch   */
-       TAPI_API_SAT_EVENT_NOT_REQUIRED_BY_USIM = -602, /**< Event Not Requested by USIM*/
+       TAPI_API_SAT_INVALID_COMMAND_ID = -600, /**<Command Number Invalid      */
+       TAPI_API_SAT_COMMAND_TYPE_MISMATCH = -601, /**< Command Type Mismatch   */
+       TAPI_API_SAT_EVENT_NOT_REQUIRED_BY_USIM = -602, /**< Event Not Requested by USIM*/
 
        /* Network */
-       TAPI_API_NETWORK_INVALID_CTXT                   = -700, /**< Network invalid context*/
+       TAPI_API_NETWORK_INVALID_CTXT = -700, /**< Network invalid context*/
 
        /*Misc */
-       TAPI_API_MISC_RETURN_NULL                               = -800, /**< MISC return NULL*/
-       TAPI_API_MISC_VALIDITY_ERROR                    = -801, /**< MISC validity error*/
-       TAPI_API_MISC_INPUTPARM_ERROR                   = -802, /**< MISC input parameter error*/
-       TAPI_API_MISC_OUTPARAM_NULL                             = -803, /**< MISC output parameter null*/
-
+       TAPI_API_MISC_RETURN_NULL = -800, /**< MISC return NULL*/
+       TAPI_API_MISC_VALIDITY_ERROR = -801, /**< MISC validity error*/
+       TAPI_API_MISC_INPUTPARM_ERROR = -802, /**< MISC input parameter error*/
+       TAPI_API_MISC_OUTPARAM_NULL = -803, /**< MISC output parameter null*/
 } TapiResult_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
 
 #endif //_TEL_UTILITY_H_
-
 /**
-* @}
-*/
-
+ * @}
+ */
index 47ad0ab..c741a50 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _TEL_CS_CONN_H_
 #define _TEL_CS_CONN_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #include <TapiCommon.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
 #define TAPI_CS_TYPE_ASYNC                                     (0 << 24)
 #define TAPI_CS_TYPE_SYNC                                      (1 << 24)
 
@@ -196,8 +188,12 @@ extern "C" {
 #define        TAPI_CS_SIMATK_SEND_APP_EXEC_RESULT                     (TAPI_EVENT_SAT_CNF_MAX + 4)
 
 // GPRS Service
+#define        TAPI_CS_GPRS_EVENT_MAX                          TAPI_EVENT_PS_PDP_GET_PORTLIST_RSP
 #define        TAPI_CS_GPRS_STARTNETWORK                       TAPI_EVENT_PS_PDP_ACT_RSP
 #define        TAPI_CS_GPRS_PDP_DEACTIVATION_SET       TAPI_EVENT_PS_PDP_DEACT_RSP
+#define        TAPI_CS_GPRS_DATA_DORMANT                       TAPI_EVENT_PS_DATA_DORMANT_RESP
+#define        TAPI_CS_GPRS_PORT_LIST_SET                      TAPI_EVENT_PS_PDP_SET_PORTLIST_RSP
+#define        TAPI_CS_GPRS_PORT_LIST_GET                      TAPI_EVENT_PS_PDP_GET_PORTLIST_RSP
 #define        TAPI_CS_GPRS_BTDUN_PINCTRL_GET          (TAPI_EVENT_PS_CNF_MAX + 1)
 
 // Sound Service
@@ -330,25 +326,8 @@ extern "C" {
 #define TAPI_CS_FACTORY_OMISSION_AVOIDANCE_SET (TAPI_CS_INTERNAL|(TAPI_EVENT_FACTORY_OMISSION_AVOIDANCE_SET_CNF))
 #define TAPI_CS_FACTORY_OMISSION_AVOIDANCE_GET (TAPI_CS_INTERNAL|(TAPI_EVENT_FACTORY_OMISSION_AVOIDANCE_GET_CNF))
 
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 #ifdef __cplusplus
 }
 #endif
 
 #endif /*_TEL_CS_CONN_H_ */
-
index 48034e1..4f5e6c7 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
diff --git a/include/tapi/.gitignore b/include/tapi/.gitignore
deleted file mode 100644 (file)
index 3c5a81e..0000000
+++ /dev/null
@@ -1 +0,0 @@
-tapi-lib-proxy.h
index 8903a4d..3424984 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -39,9 +39,6 @@
 #ifndef _ITAPI_CALL_H_
 #define _ITAPI_CALL_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelCall.h>
 #include <TelUtility.h>
 #include <TelDefines.h>
@@ -51,29 +48,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
  /**
  * @brief  This function originates MO call setup. This is an asynchronous function. The function completes immediately and
  * call setup proceeds in background.
@@ -1875,4 +1849,3 @@ int tel_retrieve_call(unsigned int CallHandle, int * pRequestId);
  /**
 * @}
 */
-
index fea046f..288dea3 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -31,9 +31,6 @@
 #ifndef _ITAPI_CFG_H_
 #define _ITAPI_CFG_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelErr.h>
 #include <TelUtility.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_CFG_A_KEY_DIGITS_MAX                      26      /**< Maximum length of A-Key Digits */
 #define TAPI_CFG_MSL_CODE_MAX                          6       /**< Maximum length of MSL codes */
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /* DEFAULT_MODE field */
 typedef enum {
        TAPI_CFG_DEFAULT_FULL = 0x01, /* 0x01 : Full reset */
@@ -153,10 +139,6 @@ typedef enum {
        TAPI_CFG_TTY_MODE_ENABLE_FULL /**< 0x01 : TTY mode full */
 } TelCfgTTYMode_t;
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * This structure contains A-Key information.
  */
@@ -198,10 +180,6 @@ typedef struct {
        unsigned char second; /**< Second (0 ~ 59) */
 } TelCfgReconditionedInfo_t;
 
-/*==================================================================================================
-  FUNCTION PROTOTYPES
-  ==================================================================================================*/
-
 /**
  * @brief  This function is used to set Modem default configuration,
  *           Telephony will send Get operation to modem to get the items from Modem.
@@ -710,4 +688,3 @@ int tel_set_cfg_tty_mode(TelCfgTTYMode_t Mode);
 /**
  * @}
  */
-
index 1f90704..6504461 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,6 @@
 #ifndef _ITAPI_DATA_H_
 #define _ITAPI_DATA_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelUtility.h>
 #include <TelData.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  *
  * @brief  Request current MIP NAI index
@@ -630,4 +611,3 @@ int tel_set_data_ddtm_config(TelDataDDTMStatus_t *pDDTMStatus, int *pRequestID);
 /**
  * @}
  */
-
index 0a87fc4..386ef75 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _ITAPI_GPS_H_
 #define _ITAPI_GPS_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TapiCommon.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define        TAPI_GPS_FIX_PARAM_TAG_MAX              0x0F
 #define        TAPI_GPS_PARAMETERS_TAG_MAX             0x11
 #define        TAPI_GPS_ADDR_LEN_MAX                   16
@@ -69,9 +59,6 @@ extern "C" {
 #define        TAPI_GPS_MAX_SATELLITES                 12
 #define        TAPI_GPS_DNS_LEN_MAX                    256
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
 typedef enum {
        TAPI_GPS_FIX_REQ_SESSION_TYPE                   = 0x01,
        TAPI_GPS_FIX_REQ_SESSION_OPERATION,
@@ -504,10 +491,7 @@ typedef enum {
 } tapi_gps_error_code_t;
 
 
-/*****************************************************************************************************/
 /*                                    GPS Chipset on AP - START                                      */
-/*****************************************************************************************************/
-
 //GPS CP MO Location
 
 /* MOLR Type */
@@ -701,15 +685,8 @@ typedef enum {
        TAPI_GPS_FREQ_AIDING_ENABLE,
 } tapi_gps_freq_aiding_e_type;
 
-
-/*****************************************************************************************************/
 /*                                     GPS Chipset on AP - END                                       */
-/*****************************************************************************************************/
-
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
 typedef struct {
        unsigned char NumOfRecord;
        tapi_gps_fix_req_param_type_t ParamType[TAPI_GPS_FIX_PARAM_TAG_MAX];
@@ -893,10 +870,7 @@ typedef struct {
        int pd_cmd_err;
 } tapi_gps_pd_cmd_callback_t;
 
-/*****************************************************************************************************/
 /*                                    GPS Chipset on AP - START                                      */
-/*****************************************************************************************************/
-
 typedef struct {
        unsigned long int qosFlag;
        unsigned char horizontalAccuracy;
@@ -1047,9 +1021,7 @@ typedef struct {
 }__attribute__ ((packed)) tapi_gps_mtlr_notification_confirm_t; //AGPS - MTLR Notification message - confirm
 
 
-/**********************************************************************/
 //RX part
-/**********************************************************************/
 typedef struct {
        unsigned short arfcn; //ARFCN of GSM network
        unsigned char bsic; //Base Station Identity Code
@@ -1332,14 +1304,7 @@ typedef struct {
        tapi_gps_r_time_int_t r_time_int;
 }__attribute__ ((packed)) tapi_gps_assist_data_noti_t; //APGPS -  GPS Assist Data Message - Notification
 
-
-/*****************************************************************************************************/
 /*                                     GPS Chipset on AP - END                                       */
-/*****************************************************************************************************/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
 
 /**
  *
@@ -1849,4 +1814,3 @@ int tel_set_gps_frequency_aiding(unsigned char state);
 /**
  * @}
  */
-
index 8637bf1..72464ad 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #ifndef _ITAPI_MISC_H_
 #define _ITAPI_MISC_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
-
 #include <TelDefines.h>
 #include <TelUtility.h>
 #include <TelMisc.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  *
  * @brief  This function is invoked to Confirm Time zone Info.
@@ -433,4 +409,3 @@ int tel_get_misc_emergency_mode(int *mode);
 /**
  * @}
  */
-
index 8a66b96..5d045e9 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -34,9 +34,6 @@
 #ifndef _ITAPI_NETTEXT_H_
 #define _ITAPI_NETTEXT_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TapiCommon.h>
 #include <TelNetText.h>
 
@@ -45,18 +42,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
  * @enum TelSmsDeviceStatus
  * This defines the enumeration for device ready value
@@ -66,17 +51,6 @@ typedef enum {
        TAPI_NETTEXT_DEVICE_NOT_READY = 0x02 /**< Device not ready */
 } TelSmsDeviceStatus;
 
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
-/*================================================================================================*/
  /**
  * @brief  This API is used to send an SMS message to the network.  This API interface allows transmitting SMS PDU as defined by
  *             3GPP TS 23.040 (SMS-SUBMIT, SMS-COMMAND) to lower layers. This API allows keeping the dedicated link at lower layers
@@ -1323,4 +1297,3 @@ int tel_set_sms_device_status(void);
 /**
 * @}
 */
-
index 9aadf49..d87512a 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,7 @@
 
 #ifndef _ITAPI_NETWORK_H_
 #define _ITAPI_NETWORK_H_
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
+
 #include <TelErr.h>
 #include <TelDefines.h>
 #include <TelNetwork.h>
@@ -45,26 +43,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  * @brief  This function requests the lower layers to select the network automatically
  *
index 8781377..5ceda3b 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,6 @@
 #ifndef _ITAPI_OMADM_H_
 #define _ITAPI_OMADM_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelUtility.h>
 
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_OMADM_MAX_PRL_SIZE_LEN            17              /** Maximum length of PRL size string */
 #define TAPI_OMADM_MAX_MODEL_NAME_LEN  17              /** Maximum length of Model name string */
 #define TAPI_OMADM_MAX_OEM_NAME_LEN            65              /** Maximum length of OEM name string */
 #define TAPI_OMADM_MAX_SW_VER_LEN              17              /** Maximum length of SW version string */
 #define TAPI_OMADM_MAX_PRL_DATA_LEN            237             /** Maximum length of PRL data */
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * @enum TelDataSignalType
  * Data Signal Type
@@ -69,10 +55,6 @@ typedef enum {
        TAPI_OMADM_PRL_WRITE_FAIL = 0x02 /**< Fail */
 } TelOMADMPRLWriteStatus_t;
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * This structure contains PRL size string.
  */
@@ -111,10 +93,6 @@ typedef struct {
        unsigned char prl_data[TAPI_OMADM_MAX_PRL_DATA_LEN]; /**< PRL data information */
 } TelOMADMPRLData_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  * @brief This function requests PRL size.
  *
index 1b9f312..feba384 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -32,9 +32,6 @@
 #ifndef        _ITAPI_PS_H_
 #define _ITAPI_PS_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelDefines.h>
 #include <TelErr.h>
 #include <TelUtility.h>
@@ -44,15 +41,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
 /* Defining macros for PSMAN profiles */
 #define TAPI_PDP_ADDR_LEN_MAX          20
 #define TAPI_PDP_APN_LEN_MAX           101
@@ -61,10 +49,7 @@ extern "C"
 #define TAPI_PDP_MAX_PASSWORD_LEN      32
 #define TAPI_PDP_MAX_DNS_LEN           16
 #define MAX_PDP_CONTEXTS_ALLOWED       3
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
+#define MAX_GPRS_PORT_LIST                     200
 
 typedef enum {
      TAPI_GPRS_DEFINE_PDP_CONTEXT=0x01,                /* 0x01 : Define PDP Context */
@@ -80,8 +65,10 @@ typedef enum {
      TAPI_GSM_GPRS_TFT,                                                        /* 0X0B : AT+CGTFT      05.10.07 ky.doo EDIT */
      TAPI_GSM_GPRS_HSDPA_STATUS,                               /* 0x0C : HSDPA status */
      TAPI_GSM_GPRS_CURRENT_SESSION_DATA_COUNTER,/* 0x0D : Current data session tx/rx total bytes */
+     TAPI_GSM_GPRS_DATA_DORMANT,                /* 0x0E : Force to set Dormant */
      TAPI_GSM_GPRS_DUN_PIN_CTRL ,               /* 0x0F : Dial up Networking Pin Control Message */
      TAPI_GSM_GPRS_CALL_STATUS,                            /* 0x10 : DS TE2 Data Call result(Multiple PDP) */
+     TAPI_GSM_GPRS_PORT_SEL,                           /* 0x11 : PORT SEL */
      TAPI_GSM_GPRS_MAX
 } tapi_gprs_type_t;
 
@@ -204,6 +191,12 @@ typedef enum {
        PDP_DEVICE_INFO_SET = 0x01
 } tapi_gprs_device_info;
 
+typedef enum{
+    TAPI_GPRS_PORT_LIST_NOT_USE,    // 0x00
+       TAPI_GPRS_PORT_LIST_WHITE,      // 0x01
+       TAPI_GPRS_PORT_LIST_BLACK,      // 0x02
+} tapi_gprs_port_list_type;
+
 typedef enum {
        TAPI_PDP_STATE_NONE,             /* 0x00 Default state for a given PDP context*/
     TAPI_PDP_STATE_ACTIVATING,          /* 0x01 TS will be in this state when there is a START PDP Request until it is  activated by modem - This state PDP is not yet UP*/
@@ -229,10 +222,6 @@ typedef enum {
   TAPI_PDP_TRANSFER_STATUS_MAX
 } tapi_gprs_suspend_type;
 
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
 typedef struct {
        tapi_gprs_type_t type;
        tapi_phone_err_t cause;
@@ -359,10 +348,16 @@ typedef struct {
        unsigned char                           external;
 } tapi_gprs_pdp_status_reason_info;
 
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
+typedef struct {
+    tapi_gprs_port_list_type type;
+    unsigned char len;
+    unsigned short list[MAX_GPRS_PORT_LIST];
+} tapi_gprs_port_list;
 
+typedef struct {
+    tapi_gprs_port_list tcp_list;
+    tapi_gprs_port_list udp_list;
+} tapi_gprs_pdp_port_list_setting_info_t;
 
 /**
  * @brief  This API is used to request to Telephony Server to set PDP context define info, PDP activation.
@@ -500,6 +495,197 @@ int       tel_activate_gprs_pdp(const tapi_ps_net_start_req_t *pNet_start_req_info, in
 int    tel_deactivate_gprs_pdp(const tapi_ps_net_stop_req_t *net_stop_req_info, int *pRequestID);
 
 /**
+ * @brief  This API is used to send modem data channels to dormant state for power saving when there is no data flowing for certain time
+ *         Access to this API is limited, we recommend you use Data Network API
+ *
+ * This function makes Dbus method call to Telephony Sever and returns immediate value.
+ * However it just means that the API request has been transfered to the CP successfully.
+ * The actual operation result is being delivered in the corresponding event asynchronously.
+ *
+ * @par Sync (or) Async:
+ * This is an Asynchronous API.
+ *
+ * @par Important Notes:
+ * -NONE
+ *
+ * @warning
+ * - None.
+ *
+ * @param [out] pRequestID
+ *   - Unique identifier for a particular request.
+ *   - request_id value can be any value from 0 to 255 if the API is returned successfully
+ *   - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
+ *
+ * @par Async Response Message:
+ *  -The event associated is TAPI_EVENT_PS_DATA_DORMANT_RESP  and the event data is #TelTapiGprsDataDormancy_t.
+ *
+ * @pre
+ *  - A dbus connection is established with #tel_init
+ *  - The application name is registered with #tel_register_app_name
+ *  - The application is registered events to listen asynchronous response with #tel_register_event
+ *  - A event loop is running to listen events
+ *
+ * @post
+ *  - None.
+ *
+ * @return Return Type (int) \n
+ * - Integer '0' - indicating that the operation has completed successfully. \n
+ * - Negative integer : it provides an error code (Refer #TapiResult_t)
+ *
+ * @par Prospective Clients:
+ * External Apps.
+ *
+ * @code
+ * #include <ITapiPS.h>
+ *
+ * int ret_status;
+ * int request_id = 0;
+ *
+ * ret_status = tel_set_gprs_dormant(&request_id); //if user want to dormant state
+ * @endcode
+ *
+ * @see
+ *  - None.
+ *
+ * @remarks
+ *  - None.
+ */
+/*================================================================================================*/
+int    tel_set_gprs_dormant(int *pRequestID);
+
+/**
+ * @brief  This API is used to get port list
+ *         Access to this API is limited, we recommend you use Data Network API
+ *
+ * This function makes Dbus method call to Telephony Sever and returns immediate value.
+ * However it just means that the API request has been transfered to the CP successfully.
+ * The actual operation result is being delivered in the corresponding event asynchronously.
+ *
+ * @par Sync (or) Async:
+ * This is an Asynchronous API.
+ *
+ * @par Important Notes:
+ * -NONE
+ *
+ * @warning
+ * - None.
+ *
+ * @param [out] pRequestID
+ *   - Unique identifier for a particular request.
+ *   - request_id value can be any value from 0 to 255 if the API is returned successfully
+ *   - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
+ *
+ * @par Async Response Message:
+ *  -The event associated is TAPI_EVENT_PS_PDP_GET_PORTLIST_RSP  and the event data is #tapi_gprs_pdp_port_list_setting_info_t.
+ *
+ * @pre
+ *  - A dbus connection is established with #tel_init
+ *  - The application name is registered with #tel_register_app_name
+ *  - The application is registered events to listen asynchronous response with #tel_register_event
+ *  - A event loop is running to listen events
+ *
+ * @post
+ *  - None.
+ *
+ * @return Return Type (int) \n
+ * - Integer '0' - indicating that the operation has completed successfully. \n
+ * - Negative integer : it provides an error code (Refer #TapiResult_t)
+ *
+ * @par Prospective Clients:
+ * External Apps.
+ *
+ * @code
+ * #include <ITapiPS.h>
+ *
+ * int ret_val;
+ * int requestId = 0;
+ *
+ * ret_val = tel_get_gprs_port_list(&requestId); //get port list with async response. current return value means whether request send low layer properly or not
+ * @endcode
+ *
+ * @see
+ *  - None.
+ *
+ * @remarks
+ *  - None.
+ */
+/*================================================================================================*/
+int    tel_get_gprs_port_list(int *pRequestID);
+
+/**
+ * @brief  This API is used to set port list
+ *         Access to this API is limited, we recommend you use Data Network API
+ *
+ * This function makes Dbus method call to Telephony Sever and returns immediate value.
+ * However it just means that the API request has been transfered to the CP successfully.
+ * The actual operation result is being delivered in the corresponding event asynchronously.
+ *
+ * @par Sync (or) Async:
+ * This is an Asynchronous API.
+ *
+ * @par Important Notes:
+ * -NONE
+ *
+ * @warning
+ * - None.
+ *
+ * @param[in] info
+ * - This input has the TCP/UDP port list information info #tapi_gprs_pdp_port_list_setting_info_t
+ *
+ * @param [out] pRequestID
+ *   - Unique identifier for a particular request.
+ *   - request_id value can be any value from 0 to 255 if the API is returned successfully
+ *   - -1 (INVALID_REQUEST_ID) will be sent in case of failure.
+ *
+ * @par Async Response Message:
+ *  -None
+ *
+ * @pre
+ *  - A dbus connection is established with #tel_init
+ *  - The application name is registered with #tel_register_app_name
+ *  - The application is registered events to listen asynchronous response with #tel_register_event
+ *  - A event loop is running to listen events
+ *
+ * @post
+ *  - None.
+ *
+ * @return Return Type (int) \n
+ * - Integer '0' - indicating that the operation has completed successfully. \n
+ * - Negative integer : it provides an error code (Refer #TapiResult_t)
+ *
+ * @par Prospective Clients:
+ * External Apps.
+ *
+ * @code
+ * #include <ITapiPS.h>
+ *
+ * int ret_val;
+ * int requestId = 0;
+ * tapi_gprs_pdp_port_list_setting_info_t test;
+ *
+ * memset(&test, 0, sizeof(tapi_gprs_pdp_port_list_setting_info_t));
+ * test.tcp_list.type = TAPI_GPRS_PORT_LIST_NOT_USE;
+ * test.tcp_list.len = 1;
+ * test.tcp_list.list[0] = 1004;
+ * test.udp_list.type = TAPI_GPRS_PORT_LIST_NOT_USE;
+ * test.udp_list.len = 1;
+ * test.udp_list.list[i] = 1111;
+ *
+ * ret_val = tel_set_gprs_port_list(&test, &requestId); //get operation result with async response. current return value means whether request send low layer properly or not
+ *
+ * @endcode
+ *
+ * @see
+ *  - None.
+ *
+ * @remarks
+ *  - None.
+ */
+/*================================================================================================*/
+int    tel_set_gprs_port_list(tapi_gprs_pdp_port_list_setting_info_t *info, int *pRequestID);
+
+
+/**
  * @brief  This API is used to request BT Dun enable or disable
  *         Access to this API is limited, we recommend you use Data Network API
  *
@@ -576,4 +762,3 @@ int tel_control_gprs_btdun_pin(tapi_ps_btdun_pincontrol pincontrol, int *pReques
 /**
    *  @}
    */
-
index 2c5e4a1..427ccbc 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -33,9 +33,6 @@
 #ifndef _ITAPI_POWER_H_
 #define _ITAPI_POWER_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelUtility.h>
 #include <TelPower.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
-
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  *
  * @brief  This API is used to turn power off or on the modem.
@@ -233,4 +210,3 @@ int tel_enforce_ramdump_of_modem(void);
 /**
  * @}
  */
-
index 91e8ebe..8d4225b 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -33,9 +33,6 @@
 #ifndef _ITAPI_SERVICE_MODE_H_
 #define _ITAPI_SERVICE_MODE_H_
 
-/*==================================================================================================
- INCLUDE FILES
- ==================================================================================================*/
 #include <TelDefines.h>
 #include <TelErr.h>
 #include <TelUtility.h>
 extern "C" {
 #endif
 
-/*==================================================================================================
- CONSTANTS
- ==================================================================================================*/
-
-/*==================================================================================================
- MACROS
- ==================================================================================================*/
 #define TAPI_MAX_SERVICE_LINES         16      /** service information display max length */
 #define TAPI_MAX_LCD_WIDTH                     31      /** LCD max width for display */
 
@@ -70,10 +60,6 @@ extern "C" {
 #define SMS_NUM_SIZE   64      /**< sms number max size for factory dft*/
 #define SMS_DATA_SIZE  255     /**< sms data max size for factory dft*/
 
-/*==================================================================================================
- ENUMS
- ==================================================================================================*/
-
 /**
  * @enum tapi_service_mode_t
  * This enumeration defines the service mode type for test mode.
@@ -240,10 +226,6 @@ typedef enum {
        TAPI_FACTORY_OMISSION_AVOIDANCE_FAILDATA_READ_FULL,
 } tapi_factory_omission_avoidance_read_cmd_t;
 
-/*==================================================================================================
- STRUCTURES AND OTHER TYPEDEFS
- ==================================================================================================*/
-
 /**
  * This structure contains service mode end information.
  */
@@ -312,10 +294,6 @@ typedef struct {
        tapi_factory_omission_avoidance_data_t data[MAX_FACTORY_OMISSION_AVOIDANCE_DATA_CNT];
 } tapi_factory_omission_avoidance_info_t;
 
-/*==================================================================================================
- FUNCTION PROTOTYPES
- ==================================================================================================*/
-
 /**
  *
  * @brief  This function is invoked to start service mode.
@@ -601,4 +579,3 @@ int tel_set_factory_omission_avoidance(tapi_factory_omission_avoidance_info_t *i
 /**
  * @}
  */
-
index 06f409b..8d91522 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -35,9 +35,6 @@
 #ifndef _ITAPI_SAT_H_
 #define _ITAPI_SAT_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelSat.h>
 #include <TelDefines.h>
 #include <TapiCommon.h>
@@ -47,38 +44,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                 GLOBAL VARIABLE DECLARATIONS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
-
-/*================================================================================================*/
-
  /**
  * @brief Sends the user choice of the main menu options to the USIM.
  *
@@ -424,4 +389,3 @@ int tel_send_sat_app_exec_result(TelSatAppsRetInfo_t* pAppRetInfo);
 /**
  * @}
  */
-
index ff2fd1b..03f6084 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -34,9 +34,6 @@
 #ifndef _ITAPI_SIM_H_
 #define _ITAPI_SIM_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelSim.h>
 #include <TelUtility.h>
 #include <TelDefines.h>
@@ -46,28 +43,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
-/*================================================================================================*/
-
 /**
 * @brief  This API is used to get SIM Card Initialization status and SIM Card Identification.
 * Most of modules which require SIM data should check SIM status before using it definitely.
@@ -2786,4 +2761,3 @@ int tel_req_sim_authentication( TelSimAuthenticationData_t *authentication_data,
 /**
 * @}
 */
-
index 8b506aa..3ae0a16 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -36,9 +36,6 @@
 #ifndef        _ITAPI_SOUND_H_
 #define _ITAPI_SOUND_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelDefines.h>
 #include <TelErr.h>
 #include <TelUtility.h>
@@ -48,18 +45,8 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
 #define TAPI_SOUND_VOLUME_TYPE         20      /**<Sound volume type   length is 20*/
 
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
 /**
 * @enum tapi_sound_type_t
 *Sound type
@@ -163,10 +150,6 @@ typedef struct {
        TelAudioLoopbackStatus_t status;
 } TelAudioLoopbackMode_t;
 
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
 /**
 * This structure defines sound volume info result control type.
 */
@@ -196,15 +179,11 @@ typedef struct {
        tapi_phone_err_t        cause;
 } tapi_sound_error_info_t;
 
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
 /**
  *
  * @brief  This function is used to send to Telephony Server to get the volume status of the phone.
  * Application can make use this API.
+ * This is permitted to the Samsung inhouse application only.
  *
  * This function makes Dbus method call to Telephony Sever and returns immediate value.
  * However it just means that the API request has been transfered to the CP successfully.
@@ -270,6 +249,7 @@ int tel_get_sound_volume_info(tapi_sound_volume_type_t vol_control_type, int *pR
  *
  * @brief  This function is used to send to Telephony Server to control the phone volume .
  * Application can make use this API.
+ * This is permitted to the Samsung inhouse application only.
  *
  * @par Sync (or) Async:
  * - This is an Asynchronous API
@@ -327,6 +307,7 @@ int tel_set_sound_volume_info(tapi_sound_volume_control_t vol_control, int *pReq
 /**
  * @brief  This function is used to Send to Telephony Server to set voice path .
  * Application can make use this API.
+ * This is permitted to the Samsung inhouse application only.
  *
  * @par Sync (or) Async:
  * - This is an Asynchronous API
@@ -382,6 +363,7 @@ int tel_set_sound_path(tapi_sound_audio_path_t  vc_path, int *pRequestId);
 /**
  * @brief  This function is used to Send to Telephony Server to control  the microphone as mute during the call.
  * Application can make use this API.
+ * This is permitted to the Samsung inhouse application only.
  *
  * @par Sync (or) Async:
  * - This is an Asynchronous API
@@ -566,6 +548,7 @@ int tel_set_sound_clock(int bEnable, int *pRequestId);
 /**
  * @brief  This function is used to send to Telephony Server to control whether Voice recording is started or not.
  * Application can make use this API.
+ * This is permitted to the Samsung inhouse application only.
  *
  * @par Sync (or) Async:
  * - This is an Asynchronous API
@@ -612,4 +595,3 @@ int tel_control_sound_voice_recording(tapi_sound_voice_recording_status_t voice_
 /**
 * @}
 */
-
index ddbbe67..0db1586 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -33,9 +33,6 @@
 #ifndef _ITAPI_SS_H_
 #define _ITAPI_SS_H_
 
- /*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <TelSs.h>
 #include <TelUtility.h>
 #include <TelDefines.h>
@@ -45,25 +42,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
-
  /**
  * @brief  This function sends a request to activate/deactivate call barring.
  *
@@ -1145,4 +1123,3 @@ int  tel_set_ss_aoc_info( TelCallAocInfo_t * AocSetInfo, int * RequestId);
 /**
 * @}
 */
-
index 6cc5b46..a945c7f 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -21,9 +21,6 @@
 #ifndef _TAPI_PROXY_H_
 #define _TAPI_PROXY_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <glib-2.0/glib.h>
 #include <dbus/dbus-protocol.h>
 #include <dbus/dbus-glib.h>
@@ -33,25 +30,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
 /*
  * This function is used to check the connection status with telephony server through DBUS.
  *
@@ -81,4 +59,3 @@ int tapi_send_request( int tapi_service, int tapi_service_function,
 #endif
 
 #endif /*_TAPI_PROXY_H_ */
-
index 29acefa..6995bed 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -21,9 +21,6 @@
 #ifndef _TAPI_PROXY_INTERNAL_H_
 #define _TAPI_PROXY_INTERNAL_H_
 
-/*==================================================================================================
-                                         INCLUDE FILES
-==================================================================================================*/
 #include <glib-2.0/glib.h>
 #include <dbus/dbus-protocol.h>
 #include <dbus/dbus-glib.h>
@@ -33,25 +30,6 @@ extern "C"
 {
 #endif
 
-/*==================================================================================================
-                                           CONSTANTS
-==================================================================================================*/
-
-/*==================================================================================================
-                                            MACROS
-==================================================================================================*/
-
-/*==================================================================================================
-                                             ENUMS
-==================================================================================================*/
-
-/*==================================================================================================
-                                 STRUCTURES AND OTHER TYPEDEFS
-==================================================================================================*/
-
-/*==================================================================================================
-                                     FUNCTION PROTOTYPES
-==================================================================================================*/
 /*
  * This function is used to check the connection status with telephony server through DBUS.
  *
@@ -82,4 +60,3 @@ int tapi_send_request_internal( int tapi_service, int tapi_service_function,
 #endif
 
 #endif /*_TAPI_PROXY_H_ */
-
index ab02080..60d4a0b 100644 (file)
@@ -1,6 +1,6 @@
 Name:       libslp-tapi
 Summary:    Telephony client API
-Version:    0.5.79
+Version:    0.5.81
 Release:    1
 Group:      System/Libraries
 License:    Apache-2.0
index af81b8a..51fa5bf 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index c39331c..21aedbf 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 1589480..4c01c65 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 4e8b989..0906180 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 94cc601..272fb49 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 3263cd0..d617fec 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 69ee00e..abc9d83 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 727bd58..f494128 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -237,3 +237,162 @@ EXPORT_API int tel_control_gprs_btdun_pin(tapi_ps_btdun_pincontrol pincontrol, i
 
        return ret_val;
 }
+
+/**
+ * This function is used to set white or black port list to the modem
+ *
+ * @return             TAPI_API_SUCCESS on success and one of the enum types of  TapiResult_t on failure
+ * @param[in]
+ * @remark
+ *
+ */
+EXPORT_API int tel_set_gprs_port_list(tapi_gprs_pdp_port_list_setting_info_t *info, int *pRequestID)
+{
+       TS_BOOL ret;
+       int ret_val;
+
+       TAPI_LIB_DEBUG(LEVEL_DEBUG,"Func Entrance ");
+
+       TAPI_RETURN_VAL_IF_FAIL((pRequestID&&info) , TAPI_API_INVALID_PTR);
+
+       if (conn_name.length_of_name == 0) {
+               TAPI_LIB_DEBUG(LEVEL_ERR, "No dbus connection name");
+               return TAPI_API_OPERATION_FAILED;
+       }
+
+       if (info->tcp_list.len == 0 && info->udp_list.len == 0) {
+               return TAPI_API_INVALID_DATA_LEN;
+       }
+
+       if (((info->tcp_list.type >= TAPI_GPRS_PORT_LIST_NOT_USE) && (info->tcp_list.type <= TAPI_GPRS_PORT_LIST_BLACK))
+                       && ((info->udp_list.type >= TAPI_GPRS_PORT_LIST_NOT_USE) && (info->udp_list.type <= TAPI_GPRS_PORT_LIST_BLACK))) {
+               TAPI_GLIB_INIT_PARAMS();
+
+               TAPI_RET_ERR_NUM_IF_FAIL(tapi_check_dbus_status(), TAPI_API_SYSTEM_RPC_LINK_NOT_EST);
+
+               TAPI_GLIB_ALLOC_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                               out_param1,out_param2,out_param3,out_param4);
+
+               g_array_append_vals(in_param1, info, sizeof(tapi_gprs_pdp_port_list_setting_info_t));
+               g_array_append_vals(in_param4, &conn_name, sizeof(tapi_dbus_connection_name));
+
+               ret = tapi_send_request(TAPI_CS_SERVICE_GPRS, TAPI_CS_GPRS_PORT_LIST_SET, in_param1, in_param2, in_param3,
+                               in_param4, &out_param1, &out_param2, &out_param3, &out_param4);
+
+               if (ret) {
+                       ret_val = g_array_index(out_param1, int, 0);
+                       *pRequestID = g_array_index(out_param2, int, 0);
+               }
+               else {
+                       ret_val = TAPI_API_SYSTEM_RPC_LINK_DOWN;
+                       TAPI_LIB_DEBUG(LEVEL_DEBUG,"Proxy error =%d ",ret_val);
+               }
+
+               TAPI_GLIB_FREE_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                               out_param1,out_param2,out_param3,out_param4);
+       }
+       else {
+               ret_val = TAPI_API_INVALID_INPUT;
+               TAPI_LIB_DEBUG(LEVEL_DEBUG,"Invalid PTR  =%d ",ret_val);
+       }
+
+       return ret_val;
+}
+
+/**
+ * This function is used to get white or black port list from modem
+ *
+ * @return             TAPI_API_SUCCESS on success and one of the enum types of  TapiResult_t on failure
+ * @param[in]
+ * @remark
+ *
+ */
+EXPORT_API int tel_get_gprs_port_list(int *pRequestID)
+{
+       TS_BOOL ret;
+       int ret_val;
+
+       TAPI_LIB_DEBUG(LEVEL_DEBUG,"Func Entrance ");
+
+       TAPI_RETURN_VAL_IF_FAIL(pRequestID , TAPI_API_INVALID_PTR);
+
+       if (conn_name.length_of_name == 0) {
+               TAPI_LIB_DEBUG(LEVEL_ERR, "No dbus connection name");
+               return TAPI_API_OPERATION_FAILED;
+       }
+       TAPI_GLIB_INIT_PARAMS();
+
+       TAPI_RET_ERR_NUM_IF_FAIL(tapi_check_dbus_status(), TAPI_API_SYSTEM_RPC_LINK_NOT_EST);
+
+       TAPI_GLIB_ALLOC_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                       out_param1,out_param2,out_param3,out_param4);
+
+       g_array_append_vals(in_param4, &conn_name, sizeof(tapi_dbus_connection_name));
+
+       ret = tapi_send_request(TAPI_CS_SERVICE_GPRS, TAPI_CS_GPRS_PORT_LIST_GET, in_param1, in_param2, in_param3,
+                       in_param4, &out_param1, &out_param2, &out_param3, &out_param4);
+
+       if (ret) {
+               ret_val = g_array_index(out_param1, int, 0);
+               *pRequestID = g_array_index(out_param2, int, 0);
+       }
+       else {
+               ret_val = TAPI_API_SYSTEM_RPC_LINK_DOWN;
+
+               TAPI_LIB_DEBUG(LEVEL_DEBUG,"Proxy error =%d ",ret_val);
+       }
+
+       TAPI_GLIB_FREE_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                       out_param1,out_param2,out_param3,out_param4);
+
+       return ret_val;
+}
+
+/**
+ * This function is used to send modem data channels to dormant state for power saving when there is no data flowing for certain time
+ *
+ * @return             TAPI_API_SUCCESS on success and one of the enum types of  TapiResult_t on failure
+ * @param[in]
+ * @remark
+ *
+ */
+EXPORT_API int tel_set_gprs_dormant(int *pRequestID)
+{
+       TS_BOOL ret;
+       int ret_val;
+
+       TAPI_LIB_DEBUG(LEVEL_DEBUG,"Func Entrance ");
+
+       TAPI_RETURN_VAL_IF_FAIL(pRequestID , TAPI_API_INVALID_PTR);
+
+       if (conn_name.length_of_name == 0) {
+               TAPI_LIB_DEBUG(LEVEL_ERR, "No dbus connection name");
+               return TAPI_API_OPERATION_FAILED;
+       }
+       TAPI_GLIB_INIT_PARAMS();
+
+       TAPI_RET_ERR_NUM_IF_FAIL(tapi_check_dbus_status(), TAPI_API_SYSTEM_RPC_LINK_NOT_EST);
+
+       TAPI_GLIB_ALLOC_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                       out_param1,out_param2,out_param3,out_param4);
+
+       g_array_append_vals(in_param4, &conn_name, sizeof(tapi_dbus_connection_name));
+
+       ret = tapi_send_request(TAPI_CS_SERVICE_GPRS, TAPI_CS_GPRS_DATA_DORMANT, in_param1, in_param2, in_param3,
+                       in_param4, &out_param1, &out_param2, &out_param3, &out_param4);
+
+       if (ret) {
+               ret_val = g_array_index(out_param1, int, 0);
+               *pRequestID = g_array_index(out_param2, int, 0);
+       }
+       else {
+               ret_val = TAPI_API_SYSTEM_RPC_LINK_DOWN;
+
+               TAPI_LIB_DEBUG(LEVEL_DEBUG,"Proxy error =%d ",ret_val);
+       }
+
+       TAPI_GLIB_FREE_PARAMS(in_param1,in_param2,in_param3,in_param4,
+                       out_param1,out_param2,out_param3,out_param4);
+
+       return ret_val;
+}
index 6da05b7..1d2c5b5 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 5d3022d..5a42a84 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 2a4ebf8..2b8730f 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 699be35..159ba6f 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 5a6d751..4e7ead0 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index cf2058d..0dfd7fb 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 25c2c09..b7d469b 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 34aadef..67378a5 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -46,6 +46,7 @@ EXPORT_API int tel_select_sat_menu(TelSatMenuSelectionReqInfo_t *pMenuSelect, in
 {
        int ret_val;
        TS_BOOL ret = FALSE;
+
        TAPI_GLIB_INIT_PARAMS();
 
        if (pMenuSelect == NULL)
@@ -109,6 +110,8 @@ EXPORT_API int tel_download_sat_event(TelSatEventDownloadReqInfo_t *pEventData,
        int ret_val;
        TS_BOOL ret = FALSE;
 
+       return TAPI_API_NOT_SUPPORTED;
+#if 0
        TAPI_GLIB_INIT_PARAMS();
 
        if (pEventData == NULL){
@@ -152,6 +155,7 @@ EXPORT_API int tel_download_sat_event(TelSatEventDownloadReqInfo_t *pEventData,
                        out_param1,out_param2,out_param3,out_param4);
 
        return ret_val;
+#endif
 }
 
 /**
@@ -169,6 +173,7 @@ EXPORT_API int tel_get_sat_main_menu_info(TelSatSetupMenuInfo_t *pMainMenu)
        TAPI_LIB_DEBUG(LEVEL_DEBUG, " Get Main Menu Information");
        int ret_val;
        TS_BOOL ret = FALSE;
+
        TAPI_GLIB_INIT_PARAMS();
 
        if (pMainMenu == NULL)
@@ -215,6 +220,7 @@ EXPORT_API int tel_send_sat_app_exec_result(TelSatAppsRetInfo_t *pAppRetInfo)
        TAPI_LIB_DEBUG(LEVEL_DEBUG, " tel_send_sat_app_exec_result");
        int ret_val;
        TS_BOOL ret = FALSE;
+
        TAPI_GLIB_INIT_PARAMS();
 
        if (pAppRetInfo == NULL)
@@ -261,6 +267,10 @@ EXPORT_API int tel_send_ui_display_status(int commandId, TelSatUiDisplayStatusTy
        TAPI_LIB_DEBUG(LEVEL_DEBUG,"status [%d]\n", status);
        int ret_val;
        TS_BOOL ret = FALSE;
+
+       return TAPI_API_NOT_SUPPORTED;
+
+#if 0
        TAPI_GLIB_INIT_PARAMS();
 
        if (commandId < 0) {
@@ -295,6 +305,7 @@ EXPORT_API int tel_send_ui_display_status(int commandId, TelSatUiDisplayStatusTy
                        out_param1,out_param2,out_param3,out_param4);
 
        return ret_val;
+#endif
 }
 
 /**
@@ -317,6 +328,7 @@ EXPORT_API int tel_send_sat_ui_user_confirm(TelSatUiUserConfirmInfo_t *pUserConf
        int ret_val;
        TS_BOOL ret = FALSE;
        TelSatTextInfo_t add_data;
+
        TAPI_GLIB_INIT_PARAMS();
 
        if (pUserConfirmData == NULL) {
index 6066dae..d7eb6ac 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -71,7 +71,6 @@ EXPORT_API int tel_get_sim_init_info(TelSimCardStatus_t *sim_status, int *card_c
 
        if (CardStatus != TAPI_SIM_STATUS_SIM_INIT_COMPLETED) {
                *sim_status = CardStatus;
-
                if (card_changed != NULL)
                        *card_changed = 0;
 
@@ -91,12 +90,12 @@ EXPORT_API int tel_get_sim_init_info(TelSimCardStatus_t *sim_status, int *card_c
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *sim_status = g_array_index(out_param2, TelSimCardStatus_t ,0);
-
-               if (card_changed != NULL)
-                       *card_changed = g_array_index(out_param3, int ,0);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS) {
+                       *sim_status = g_array_index(out_param2, TelSimCardStatus_t ,0);
+                       if (card_changed != NULL)
+                               *card_changed = g_array_index(out_param3, int ,0);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -154,13 +153,12 @@ EXPORT_API int tel_verifiy_sim_pins(const TelSimSecPw_t *pin_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
 
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -226,13 +224,11 @@ EXPORT_API int tel_verify_sim_puks(const TelSimSecPw_t *puk_data, const TelSimSe
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -301,13 +297,11 @@ EXPORT_API int tel_change_sim_pins(const TelSimSecPw_t *old_pin, const TelSimSec
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -345,11 +339,11 @@ EXPORT_API int tel_get_sim_security_status(TelSimPinType_t type, TelSimPinStatus
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *status = g_array_index(out_param2,TelSimPinStatus_t ,0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "api_err[%d],PIN type[%d], Status[%d]",api_err, type,*status);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ) {
+                       *status = g_array_index(out_param2,TelSimPinStatus_t ,0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "api_err[%d],PIN type[%d], Status[%d]",api_err, type,*status);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -403,13 +397,11 @@ EXPORT_API int tel_disable_sim_security(TelSimSecPw_t *sec_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -463,13 +455,11 @@ EXPORT_API int tel_enable_sim_security(TelSimSecPw_t *sec_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -512,13 +502,11 @@ EXPORT_API int tel_get_sim_personalization_status(TelSimPersType_t type, int *re
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -574,13 +562,11 @@ EXPORT_API int tel_disable_sim_personalization(TelSimPersPw_t *pers_data, int *r
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -636,13 +622,11 @@ EXPORT_API int tel_enable_sim_personalization(TelSimPersPw_t *pers_data, int *re
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -674,9 +658,10 @@ EXPORT_API int tel_get_sim_fdn_status(int *fdn_status)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *fdn_status = g_array_index(out_param2,TS_BOOL ,0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "FDN Status [%d]", *fdn_status);
+               if(api_err == TAPI_API_SUCCESS) {
+                       *fdn_status = g_array_index(out_param2,TS_BOOL ,0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "FDN Status [%d]", *fdn_status);
+               }
        }
        else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
@@ -726,13 +711,11 @@ EXPORT_API int tel_disable_sim_fdn(const unsigned char *pin2, int *pin2_len, int
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -781,13 +764,11 @@ EXPORT_API int tel_enable_sim_fdn(const unsigned char *pin2, int *pin2_len, int
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -833,13 +814,11 @@ EXPORT_API int tel_req_sim_access(const TelSimRSimReq_t *rsim_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -882,13 +861,11 @@ EXPORT_API int tel_req_sim_apdu(TelSimApdu_t* apdu_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -928,13 +905,11 @@ EXPORT_API int tel_req_sim_atr(int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -967,14 +942,15 @@ EXPORT_API int tel_get_sim_ecc(TelSimEccData_t *ecc_data, int *ecc_count)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *ecc_data = g_array_index(out_param2, TelSimEccData_t ,0);
-               *ecc_count = g_array_index(out_param3, int ,0);
+               if(api_err == TAPI_API_SUCCESS ){
+                       *ecc_data = g_array_index(out_param2, TelSimEccData_t ,0);
+                       *ecc_count = g_array_index(out_param3, int ,0);
 
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "ECC count [%d]", *ecc_count);
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "1st ECC data is  [%s]", ecc_data->EccInfo.szEcc1);
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "1st UECC data is  [%s]", ecc_data->UeccInfo[0].szEcc);
-       }
-       else {
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "ECC count [%d]", *ecc_count);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "1st ECC data is  [%s]", ecc_data->EccInfo.szEcc1);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "1st UECC data is  [%s]", ecc_data->UeccInfo[0].szEcc);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1005,11 +981,11 @@ EXPORT_API int tel_get_sim_language(TelSimLanguageInfo_t *sim_language)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *sim_language = g_array_index(out_param2, TelSimLanguageInfo_t ,0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "Language count [%lu]", sim_language->LpCount);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ){
+                       *sim_language = g_array_index(out_param2, TelSimLanguageInfo_t ,0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "Language count [%lu]", sim_language->LpCount);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1051,13 +1027,11 @@ EXPORT_API int tel_set_sim_language(TelSimLanguagePreferenceCode_t language, int
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1089,11 +1063,11 @@ EXPORT_API int tel_get_sim_type(TelSimCardType_t *card_type)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *card_type = g_array_index(out_param2,int ,0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "Card type [%d]", *card_type);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ) {
+                       *card_type = g_array_index(out_param2,int ,0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "Card type [%d]", *card_type);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1125,11 +1099,11 @@ EXPORT_API int tel_get_sim_imsi(TelSimImsiInfo_t *imsi)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *imsi = g_array_index(out_param2, TelSimImsiInfo_t ,0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "IMSI valid [%d]", imsi->bValid);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ) {
+                       *imsi = g_array_index(out_param2, TelSimImsiInfo_t ,0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "IMSI valid [%d]", imsi->bValid);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1161,19 +1135,13 @@ EXPORT_API int tel_get_sim_iccid(TelSimIccIdInfo_t *iccid)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-
-               if(api_err == TAPI_API_SUCCESS)
-               {
+               if(api_err == TAPI_API_SUCCESS) {
                        *iccid = g_array_index(out_param2, TelSimIccIdInfo_t ,0);
                        TAPI_LIB_DEBUG(LEVEL_ALERT, "ICCID length[%d]", iccid->icc_length);
-               }
-               else
-               {
+               } else {
                        TAPI_LIB_DEBUG(LEVEL_ALERT, "api_err[%d]",api_err);
                }
-       }
-       else
-       {
+       } else  {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1205,10 +1173,11 @@ EXPORT_API int tel_get_sim_mailbox_info(TelSimMailboxNumbers_s *mbox)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *mbox = g_array_index(out_param2, TelSimMailboxNumbers_s ,0);
-               TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",mbox->b_cphs);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS) {
+                       *mbox = g_array_index(out_param2, TelSimMailboxNumbers_s ,0);
+                       TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",mbox->b_cphs);
+               }
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1240,10 +1209,11 @@ EXPORT_API int tel_get_sim_callforwarding_info(TelSimCallForwarding_s *cf)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *cf = g_array_index(out_param2, TelSimCallForwarding_s ,0);
-               TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",cf->b_cphs);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ) {
+                       *cf = g_array_index(out_param2, TelSimCallForwarding_s ,0);
+                       TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",cf->b_cphs);
+               }
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1275,10 +1245,11 @@ EXPORT_API int tel_get_sim_messagewaiting_info(TelSimMessageWaiting_s *mw)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *mw = g_array_index(out_param2, TelSimMessageWaiting_s ,0);
-               TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",mw->b_cphs);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS) {
+                       *mw = g_array_index(out_param2, TelSimMessageWaiting_s ,0);
+                       TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",mw->b_cphs);
+               }
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1310,10 +1281,11 @@ EXPORT_API int tel_get_sim_cphs_info(TelSimCphsLocalInfo_t *cphs)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *cphs = g_array_index(out_param2, TelSimCphsLocalInfo_t ,0);
-               TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",cphs->b_used);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ) {
+                       *cphs = g_array_index(out_param2, TelSimCphsLocalInfo_t ,0);
+                       TAPI_LIB_DEBUG(LEVEL_DEBUG, "chps?[%d]",cphs->b_used);
+               }
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1399,14 +1371,14 @@ EXPORT_API int tel_get_sim_pb_init_info(int *init_completed, TelSimPbList_t *pb_
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *init_completed = g_array_index(out_param2, int, 0);
-               *pb_list = g_array_index(out_param3, TelSimPbList_t, 0);
-               *first_index = g_array_index(out_param4, int, 0);
-
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "PB INIT Completed[%d]", *init_completed);
-               TAPI_LIB_DEBUG(LEVEL_ALERT, "First Valid Index [%d]", *first_index);
-       }
-       else {
+               if(api_err == TAPI_API_SUCCESS ){
+                       *init_completed = g_array_index(out_param2, int, 0);
+                       *pb_list = g_array_index(out_param3, TelSimPbList_t, 0);
+                       *first_index = g_array_index(out_param4, int, 0);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "PB INIT Completed[%d]", *init_completed);
+                       TAPI_LIB_DEBUG(LEVEL_ALERT, "First Valid Index [%d]", *first_index);
+               }
+       else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1454,13 +1426,11 @@ EXPORT_API int tel_get_sim_pb_count(TelSimPbFileType_t pb_type, int* req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1508,13 +1478,11 @@ EXPORT_API int tel_get_sim_pb_meta_info(TelSimPbFileType_t pb_type, int* req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1553,13 +1521,11 @@ EXPORT_API int tel_get_sim_pb_3g_meta_info(int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1613,13 +1579,11 @@ EXPORT_API int tel_read_sim_pb_record(TelSimPbFileType_t pb_type, unsigned short
                        &out_param1, &out_param2, &out_param3, &out_param4);
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1674,13 +1638,11 @@ EXPORT_API int tel_update_sim_pb_record(const TelSimPbRecordData_t *req_data, in
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1735,13 +1697,11 @@ EXPORT_API int tel_delete_sim_pb_record(TelSimPbFileType_t pb_type, unsigned sho
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1785,13 +1745,11 @@ EXPORT_API int tel_req_sap_connection(TelSimSapConnect_t *req_data, int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1830,13 +1788,11 @@ EXPORT_API int tel_req_sap_connection_status(int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1875,13 +1831,11 @@ EXPORT_API int tel_req_sap_transfer_atr(int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1924,13 +1878,11 @@ EXPORT_API int tel_req_sap_transfer_apdu(TelSimSapApduData_t *apdu_data, int *re
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -1976,13 +1928,11 @@ EXPORT_API int tel_req_sap_transport_protocol(TelSimSapProtocol_t protocol, int
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -2028,13 +1978,11 @@ EXPORT_API int tel_req_sap_power_operation(TelSimSapMsgId_t req_data, int *req_i
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -2073,13 +2021,11 @@ EXPORT_API int tel_req_sap_cardreader_status(int *req_id)
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS) {
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
-               }
-       }
-       else {
+       } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
        }
 
@@ -2136,9 +2082,9 @@ EXPORT_API int tel_req_sim_authentication(TelSimAuthenticationData_t *authentica
 
        if (TRUE == ret) {
                api_err = g_array_index(out_param1, int ,0);
-               *req_id = g_array_index(out_param2, int ,0);
-
-               if (api_err != TAPI_API_SUCCESS)
+               if(api_err == TAPI_API_SUCCESS )
+                       *req_id = g_array_index(out_param2, int ,0);
+               else
                        *req_id = INVALID_REQUEST_ID;
        } else {
                api_err = TAPI_API_SYSTEM_RPC_LINK_DOWN;
index cb7ed7f..d292275 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index 3ec1e70..5cf8f55 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
  *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
+ * Contact: Ja-young Gu <jygu@samsung.com>
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -597,6 +597,16 @@ EXPORT_API int tel_get_ss_cli_status(TelSsCliType_t CliType, int *req_id)
        return api_err;
 }
 
+/**********************************************************************************************
+ *
+ * This function is used to send a USSD string and also the User response for a NW intiated USSD.
+ *
+ * @param      pAppMsg[IN] of type TelSsUssdMsgInfo_t which specifies the USSD String,length of the string, format of the string.
+ * @return     enum type TapiResult_t Specifies the API's Return result.
+ * @remark     TelSsUssdMsgInfo_t ->IndType is not used while calling this function, This is used for sending the response.
+ *                     Limo standard defines only one structure for Request and response.
+ *
+ ***********************************************************************************************/
 EXPORT_API int tel_send_ss_ussd_request(const TelSsUssdMsgInfo_t *ussd_info, int *req_id)
 {
        TS_BOOL ret = FALSE;
diff --git a/src/test_apps/Makefile b/src/test_apps/Makefile
deleted file mode 100644 (file)
index 6c0cd14..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-export PKG_CONFIG_PATH=/usr/lib/pkgconfig\r
-\r
-TARGET := TAPITest\r
-\r
-SRCS   := \\r
-       tapi_call_test.c \\r
-       tapi_test_app.c \\r
-       tapi_nw_test.c \\r
-       tapi_power_test.c \\r
-       tapi_gps_test.c \\r
-       tapi_misc_test.c \\r
-       tapi_ps_test.c \\r
-       tapi_svc_test.c \\r
-       tapi_sms_util.c \\r
-       tapi_sim_test.c \\r
-       tapi_sms_test.c \\r
-       tapi_cdma_data_test.c \\r
-       tapi_cfg_test.c \\r
-       tapi_sound_test.c\r
-\r
-OBJS   := $(SRCS:.c=.o)\r
-CC             := gcc\r
-PKGS   := glib-2.0 dbus-1 dbus-glib-1 tapi dlog\r
-CFLAGS := -Wall -g `pkg-config --cflags $(PKGS)`\r
-LIBS   := `pkg-config --libs $(PKGS)`\r
-\r
-\r
-all: $(TARGET)\r
-\r
-$(TARGET): $(OBJS)\r
-       $(CC) $(OBJS) $(LIBS) -o $(TARGET)\r
-\r
-.c.o: $(SRCS)\r
-       $(CC) $(CFLAGS) -c $^ -o $@\r
-\r
-clean:\r
-       rm -f $(OBJS) $(TARGET)\r
diff --git a/src/test_apps/tapi_call_test.c b/src/test_apps/tapi_call_test.c
deleted file mode 100644 (file)
index a44b7e7..0000000
+++ /dev/null
@@ -1,2202 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <string.h>
-#include <sys/time.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include "assert.h"
-#include "glib.h"
-#include "unistd.h"
-
-#include "TelErr.h"
-#include "ITapiPower.h"
-#include "ITapiCall.h"
-#include "TapiCommon.h"
-#include "TelCall.h"
-#include "vconf.h"
-
-#ifndef false
-       #define false 0
-#endif
-#ifndef true
-       #define true  !0
-#endif
-#ifndef bool
-       #define bool  char
-#endif
-
-#define _CALL_TEST_KOREA_FMT_          4
-#define _CALL_TEST_INDIA_FMT_          10
-
-#define TEST_DEBUG(frmt, args...)      \
-       {do { fprintf(stderr, "[Call Test][%s:%04d] " frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-#define AUTO_LOG(frmt, args...)
-
-
-#define MAX_BURST_DTMF_STRLEN          32
-
-extern int EvtDeliveryHandle ;
-
-
-typedef struct
-{
-       TS_UINT handle;
-       TelTapiCallInfo_t       info;
-       TS_BOOL                 used;
-       int                             index;
-} call_ctxt_t;
-
-// same as tapi event
-typedef struct
-{
-       int group;
-       int type;
-       int ID;
-       int status;
-       void *dst;
-}data_t;
-
-int error_code;
-static TelCallActiveLine_t             _glob_test_curr_line = 0x00;
-//static TS_UINT               endHCall = -1;
-static long    __call_test_auto_mo = 0;
-static long    __call_test_auto_ans = 0;
-static long     _timer_exp_count = 0;
-
-call_ctxt_t            ctxt[TAPI_CONTEXT_CALL_SIZE_MAX];
-TelCallStatus_t        gcallStatus[TAPI_CONTEXT_CALL_SIZE_MAX];
-TS_UINT        incoming_handle= -1;
-TS_UINT        curr_handle= -1;
-int requestID;
-
-FILE *log_fd;
-
-TelCallSetupParams_t _glob_setup_info;
-
-struct sigaction sa;
-struct itimerval timer;
-
-/*     Success returns 0       */
-extern pthread_t         __glob_tapi_keypad_thread;
-
-//static int  _country_spc_num_ = 0;
-char pre_string[16] = {0, };
-int _auto_dtmf_send_count = 0;
-int _auto_dtmf_cnf_count = 0;
-
-static unsigned int *  CALL_subscription_id;
-
-void __PrintCallType(char* str, TelCallType_t eCallType)
-{
-       switch(eCallType)
-       {
-               case TAPI_CALL_TYPE_VOICE:
-                       fprintf(stderr, "%s [TAPI_CALL_TYPE_VOICE]", str);
-                       break;
-               case TAPI_CALL_TYPE_DATA:
-                       fprintf(stderr, "%s [TAPI_CALL_TYPE_DATA]", str);
-                       break;
-               case TAPI_CALL_TYPE_E911:
-                       fprintf(stderr, "%s [TAPI_CALL_TYPE_E911]", str);
-                       break;
-               default:
-                       fprintf(stderr, "%s Undefined Call Type:[0x%x]", str, eCallType);
-                       break;
-       }
-}
-
-void __PrintActiveCallState(char* str, TelCallActiveState_t eCallActiveState)
-{
-       switch(eCallActiveState)
-       {
-               case TAPI_CALL_CONNECT_IDLE:
-                       fprintf(stderr, "%s [TAPI_CALL_CONNECT_IDLE]", str);
-                       break;
-               case TAPI_CALL_CONNECT_ACTIVE:
-                       fprintf(stderr, "%s [TAPI_CALL_CONNECT_ACTIVE]", str);
-                       break;
-               case TAPI_CALL_CONNECT_HELD:
-                       fprintf(stderr, "%s [TAPI_CALL_CONNECT_HELD]", str);
-                       break;
-               default:
-                       fprintf(stderr, "%s Undefined Call Active State", str);
-                       break;
-       }
-}
-
-void __PrintCallState(char* str, TelCallStates_t eCallState)
-{
-       switch(eCallState)
-       {
-               case TAPI_CALL_STATE_IDLE:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_IDLE]", str);
-                       break;
-               case TAPI_CALL_STATE_ORIG:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_ORIG]", str);
-                       break;
-               case TAPI_CALL_STATE_SETUPIND:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_SETUPIND]", str);
-                       break;
-               case TAPI_CALL_STATE_CONNECTING:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_CONNECTING]", str);
-                       break;
-               case TAPI_CALL_STATE_ALERT:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_ALERT]", str);
-                       break;
-               case TAPI_CALL_STATE_INCOM:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_INCOM]", str);
-                       break;
-               case TAPI_CALL_STATE_ANSWER:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_ANSWER]", str);
-                       break;
-               case TAPI_CALL_STATE_CONV:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_CONV]", str);
-                       break;
-               case TAPI_CALL_STATE_ENDING:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_ENDING]", str);
-                       break;
-               case TAPI_CALL_STATE_INVALID:
-                       fprintf(stderr, "%s [TAPI_CALL_STATE_INVALID]", str);
-                       break;
-               default:
-                       fprintf(stderr, "%s Undefined Call State", str);
-                       break;
-       }
-}
-
-void __PrintCallFwType(char* str, TelCallForwardType_t eCallFwType)
-{
-       switch(eCallFwType)
-       {
-               case TAPI_CALL_OUTGOING_FWDED:
-                       fprintf(stderr, "%s [TAPI_CALL_OUTGOING_FWDED]", str);
-                       break;
-               case TAPI_CALL_INCOMMING_FWDED:
-                       fprintf(stderr, "%s [TAPI_CALL_INCOMMING_FWDED]", str);
-                       break;
-               default:
-                       fprintf(stderr, "%s Undefined Call ForwardType", str);
-                       break;
-       }
-}
-
-
-int call_test_ret_first_free_index(void);
-
-
-
-void timer_handler (int signum)
-{
-       TEST_DEBUG("Timer Expired [%ld] times", ++_timer_exp_count);
-
-       /*      Free the current call context   */
-
-}
-
-
-void timer_reset()
-{
-        /* Configure the timer to expire after 250 msec... */
-        timer.it_value.tv_sec = 60;
-        timer.it_value.tv_usec = 0;
-        /* ... and every 250 msec after that. */
-        timer.it_interval.tv_sec = 0;
-        timer.it_interval.tv_usec = 0;
-}
-
-
-void timer_start()
-{
-        /* Start a virtual timer. It counts down whenever this process is
-          executing. */
-        setitimer (ITIMER_REAL, &timer, NULL);
-}
-
-
-
-void call_test_auto_hold(void)
-{
-       TapiResult_t    api_err;
-
-       TEST_DEBUG("Request to Auto Hold call with Handle [%d]", curr_handle);
-
-       api_err = tel_hold_call(curr_handle, &requestID);
-
-       TEST_DEBUG("Tapi API Err Code [%x], Auto MO Count [%ld]", api_err, __call_test_auto_mo);
-       AUTO_LOG("API: tel_hold_call:-IN Handle [%d], Return [%d]", curr_handle, api_err);
-  }
-
-
-
-void call_test_auto_act(void)
-{
-       TapiResult_t    api_err;
-
-       TEST_DEBUG("Request to Auto Activate Call with Handle [%d]", curr_handle);
-
-       api_err = tel_retrieve_call(curr_handle, &requestID);
-
-       TEST_DEBUG("Tapi API Err Code [%x], Auto Count [%ld]", api_err, __call_test_auto_ans);
-       AUTO_LOG("API: tel_retrieve_call:-IN Handle [%d], Return [%d]", curr_handle, api_err);
-  }
-
-
-void call_test_auto_ans(void)
-{
-       TapiResult_t    api_err;
-
-       TEST_DEBUG("Request to Auto Ans call with Handle [%d]", incoming_handle);
-
-       __call_test_auto_ans++;
-
-       api_err = tel_answer_call(incoming_handle, TAPI_CALL_ANSWER_ACCEPT, &requestID);
-
-       TEST_DEBUG("Tapi API Err Code [%x], Auto Count [%ld]", api_err, __call_test_auto_ans);
-
-       AUTO_LOG("API: tel_answer_call:- IN Hanlde [%d] Return [%d]", incoming_handle, api_err);
-  }
-
-
-
-
-
-void call_test_auto_mo(void)
-{
-       int     free_id;
-       TapiResult_t    api_err;
-       int RequestId=0;
-
-       TEST_DEBUG("Request to Auto Setup call with Number ...%s", _glob_setup_info.szNumber);
-
-       __call_test_auto_mo++;
-
-       api_err = tel_exe_call_mo(&_glob_setup_info, &curr_handle, &RequestId);
-
-       TEST_DEBUG("After calling tel_exe_call_mo : Handle [%d]", curr_handle);
-
-       TEST_DEBUG("Tapi API Err Code [%x], Auto Count [%ld]", api_err, __call_test_auto_mo);
-
-       if(api_err == TAPI_API_SUCCESS)
-       {
-               free_id = call_test_ret_first_free_index();
-
-               if (free_id == -1)
-               {
-                       TEST_DEBUG("No Free Context ...");
-               }
-
-               else
-               {
-                       memcpy(&ctxt[free_id].info.callNumber, _glob_setup_info.szNumber, sizeof( _glob_setup_info.szNumber));
-                       ctxt[free_id].info.callState = TAPI_CALL_STATE_ORIG;
-                       ctxt[free_id].info.activeState = TAPI_CALL_CONNECT_IDLE;
-                       ctxt[free_id].info.isMobileOriginated = true;
-                       ctxt[free_id].handle = curr_handle;
-               }
-
-               AUTO_LOG("API: tel_exe_call_mo:- Return [%d], Handle [%d]", api_err, curr_handle);
-
-       }
-
-
-  }
-
-
-
-void call_test_count_mo()
-{
-       if (__call_test_auto_mo)
-               call_test_auto_mo();
-       else
-               TEST_DEBUG("Non Automated testing...");
-}
-
-
-void call_test_count_ans()
-{
-       if (__call_test_auto_ans)
-               call_test_auto_ans();
-       else
-               TEST_DEBUG("Non Automated testing...");
-}
-
-void call_test_auto_dtmf()
-{
-       int api_err = 0;
-       int RequestID;
-
-       api_err = tel_send_call_dtmf("9\0", &RequestID);
-    TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-    _auto_dtmf_send_count++;
-       AUTO_LOG("API: tel_send_call_dtmf: Send Count [%d]", _auto_dtmf_send_count);
-}
-
-
-TS_UINT  call_test_ret_handle_by_active_state(void)
-{
-       int start = 0;
-       int max = TAPI_CONTEXT_CALL_SIZE_MAX;
-
-       for (start = 0; start < max; start++)
-       {
-               if (ctxt[start].info.activeState == TAPI_CALL_CONNECT_ACTIVE)
-               {
-                       TEST_DEBUG("Current Active Call Handle is [%d]", ctxt[start].handle);
-                       return ctxt[start].handle;
-               }
-               else
-               {
-                       //
-               }
-       }
-
-       if (start == max)
-       {
-               TEST_DEBUG("Could not find Call with Active State")
-       }
-
-       return -1;
-
-}
-
-
-
-
-int call_test_ret_index_by_handle(TS_UINT handle)
-{
-       int start = 0;
-       int max = TAPI_CONTEXT_CALL_SIZE_MAX;
-
-       for (start = 0; start < max; start++)
-       {
-               if (ctxt[start].handle == handle)
-               {
-                       return start;
-               }
-               else
-               {
-                       //
-               }
-       }
-
-       if (start == max)
-       {
-               TEST_DEBUG("Could not find CTXT")
-       }
-
-       return -1;
-
-}
-
-
-
-int call_test_ret_first_free_index(void)
-{
-       int start = 0;
-       int max = TAPI_CONTEXT_CALL_SIZE_MAX;
-
-       for (start = 0; start < max; start++)
-       {
-               /*      by default they are free        */
-               if (ctxt[start].used == false)
-               {
-                       //TEST_DEBUG("Creating a Context with Index [%d]", start);
-
-                       ctxt[start].used = true;
-                       ctxt[start].index = start;
-
-                       return start;
-               }
-               else
-               {
-                       //
-               }
-       }
-
-       if (start == max)
-       {
-               TEST_DEBUG("Could not find FREE CTXT")
-       }
-
-       return -1;
-
-}
-
-
-/*     Create a context and populate the data  */
-void call_test_process_incom_ind(void *data)
-{
-       int free_id = -1;
-       TelCallIncomingCallInfo_t       IncomingInfo = {0, };
-       int len;
-
-       free_id = call_test_ret_first_free_index();
-
-       if (free_id == -1)
-       {
-               //
-       }
-       else
-       {
-               memcpy(&IncomingInfo, data, sizeof(TelCallIncomingCallInfo_t));
-
-               ctxt[free_id].handle = IncomingInfo.CallHandle;
-
-               len = strlen(IncomingInfo.szCallingPartyNumber);
-
-               memcpy(&ctxt[free_id].info.callNumber, IncomingInfo.szCallingPartyNumber, len);
-
-               ctxt[free_id].info.callState = TAPI_CALL_STATE_INCOM;
-               ctxt[free_id].info.callType = IncomingInfo.CallType;
-               //ctxt[free_id].info.CliCause = IncomingInfo.CliCause;
-
-               TEST_DEBUG("Incoming Call Information: call handle:[%d], Number [%s], Type [0x%x]",
-                       ctxt[free_id].handle, ctxt[free_id].info.callNumber, ctxt[free_id].info.callType);
-
-               TEST_DEBUG("No CLI Cause [0x%x]",  IncomingInfo.CliCause);
-
-               incoming_handle = ctxt[free_id].handle;
-
-               AUTO_LOG("EVENT: INCOMING IND:- Hanlde [%d], Number [%s]",
-                       incoming_handle, ctxt[free_id].info.callNumber);
-
-               /*      if the test is automated, then call ans api     */
-               call_test_count_ans();
-
-       }
-
-}
-
-//static void  call_test_process_events (TelTapiEventClass_t eventClass, int eventType, void * param2)
-static void  call_async_event_callback(TelTapiEvent_t  *event, void *data)
-{
-       TS_UINT temp_handle = -1;
-       int     RequestId=0;
-
-       TEST_DEBUG("EVENT TYPE:[0x%x], STATUS:[0x%x]", event->EventType, event->Status);
-
-       int *userdata;
-       userdata = (int *)data;
-
-       switch(event->EventClass)
-       {
-               case TAPI_EVENT_CLASS_CALL_VOICE:
-                       switch(event->EventType)
-                       {
-                               case TAPI_EVENT_CALL_SWAP_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_SWAP_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_ANSWER_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_ANSWER_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_RELEASE_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_RELEASE_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_RELEASE_ALL_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_RELEASE_ALL_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_RELEASE_ALL_ACTIVE_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_RELEASE_ALL_ACTIVE_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_RELEASE_ALL_HELD_CNF:
-                               {
-                                               TEST_DEBUG("TAPI_EVENT_CALL_RELEASE_ALL_HELD_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_GET_PRIVACYMODE_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_GET_PRIVACYMODE_CNF");
-                                       TelCallVoicePrivacyInfo_t vp_info={0,};
-                                       memcpy(&vp_info, event->pData, sizeof(TelCallVoicePrivacyInfo_t));
-                                       switch(vp_info.PrivacyType)
-                                       {
-                                               case TAPI_CALL_PRIVACY_TYPE_MS:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_MS");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_TYPE_BS:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_BS");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_TYPE_CURRENT:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_CURRENT");
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                                       switch(vp_info.PrivacyMode)
-                                       {
-                                               case TAPI_CALL_PRIVACY_MODE_STANDARD:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_MODE_STANDARD");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_MODE_ENHANCED:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_MODE_ENHANCED");
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_SET_PRIVACYMODE_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_SET_PRIVACYMODE_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_PRIVACYMODE_IND:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_PRIVACYMODE_IND");
-                                       TelCallVoicePrivacyInfo_t vp_info={0,};
-                                       memcpy(&vp_info, event->pData, sizeof(TelCallVoicePrivacyInfo_t));
-                                       switch(vp_info.PrivacyType)
-                                       {
-                                               case TAPI_CALL_PRIVACY_TYPE_MS:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_MS");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_TYPE_BS:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_BS");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_TYPE_CURRENT:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_TYPE_CURRENT");
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                                       switch(vp_info.PrivacyMode)
-                                       {
-                                               case TAPI_CALL_PRIVACY_MODE_STANDARD:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_MODE_STANDARD");
-                                                       break;
-                                               case TAPI_CALL_PRIVACY_MODE_ENHANCED:
-                                                       TEST_DEBUG("TAPI_CALL_PRIVACY_MODE_ENHANCED");
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_FLASHINFO_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_FLASHINFO_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_EXIT_EMERGENCYMODE_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_EXIT_EMERGENCYMODE_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_EMERGENCYMODE_IND:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_EMERGENCYMODE_IND");
-                                       TelCallEmergecyMode_t mode= 0;
-                                       memcpy(&mode, event->pData, sizeof(TelCallEmergecyMode_t));
-                                       switch(mode)
-                                       {
-                                               case TAPI_CALL_EMERGENCY_MODE_EXIT:
-                                                       TEST_DEBUG("TAPI_CALL_EMERGENCY_MODE_EXIT");
-                                                       break;
-                                               case TAPI_CALL_EMERGENCY_MODE_ENTER:
-                                                       TEST_DEBUG("TAPI_CALL_EMERGENCY_MODE_ENTER");
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_TIME_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_TIME_CNF");
-                                       TelCallTimeInfo_t calltime_info={0,};
-                                       memcpy(&calltime_info, event->pData, sizeof(TelCallTimeInfo_t));
-                                       TEST_DEBUG("req_type_mask = [0x%x]",calltime_info.req_type_mask);
-                                       TEST_DEBUG("TotalCallCnt = [%ld]",calltime_info.TotalCallCnt);
-                                       TEST_DEBUG("OutgoingCallCnt = [%ld]",calltime_info.OutgoingCallCnt);
-                                       TEST_DEBUG("IncomingCallCnt = [%ld]",calltime_info.IncomingCallCnt);
-                                       TEST_DEBUG("TotalCallTime = [%ld]",calltime_info.TotalCallTime);
-                                       TEST_DEBUG("OutgoingCallTime = [%ld]",calltime_info.OutgoingCallTime);
-                                       TEST_DEBUG("IncomingCallTime = [%ld]",calltime_info.IncomingCallTime);
-                                       TEST_DEBUG("LastCallTime = [%ld]",calltime_info.LastCallTime);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_TIME_IND:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_TIME_IND");
-                                       TelCallTimeInfo_t calltime_info={0,};
-                                       memcpy(&calltime_info, event->pData, sizeof(TelCallTimeInfo_t));
-                                       TEST_DEBUG("req_type_mask = [%d]",calltime_info.req_type_mask);
-                                       TEST_DEBUG("TotalCallCnt = [%ld]",calltime_info.TotalCallCnt);
-                                       TEST_DEBUG("OutgoingCallCnt = [%ld]",calltime_info.OutgoingCallCnt);
-                                       TEST_DEBUG("IncomingCallCnt = [%ld]",calltime_info.IncomingCallCnt);
-                                       TEST_DEBUG("TotalCallTime = [%ld]",calltime_info.TotalCallTime);
-                                       TEST_DEBUG("OutgoingCallTime = [%ld]",calltime_info.OutgoingCallTime);
-                                       TEST_DEBUG("IncomingCallTime = [%ld]",calltime_info.IncomingCallTime);
-                                       TEST_DEBUG("LastCallTime = [%ld]",calltime_info.LastCallTime);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_OTA_PROGRESS_IND:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_OTA_PROGRESS_IND");
-                                       TelCallOtaProgressInfo_t ota_info={0,};
-                                       memcpy(&ota_info, event->pData, sizeof(TelCallOtaProgressInfo_t));
-                                       switch(ota_info.OtaType)
-                                       {
-                                               case TAPI_CALL_OTATYPE_OTASP:
-                                               {
-                                                       TEST_DEBUG("TAPI_CALL_OTATYPE_OTASP");
-
-                                                       switch(ota_info.OtaspStatus)
-                                                       {
-                                                               case TAPI_CALL_OTASP_OK_SPL_UNLOCKED:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_SPL_UNLOCKED");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_AKEY_EXCESS:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_AKEY_EXCESS");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_SSD_UPDATE:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_SSD_UPDATE");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_NAM_DWNLD:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_NAM_DWNLD");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_MDN_DWNLD:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_MDN_DWNLD");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_IMSI_DWNLD:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_IMSI_DWNLD");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_PRL_DWNLD:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_PRL_DWNLD");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_COMMIT:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_COMMIT");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_PROGRAMMING:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_PROGRAMMING");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_SUCCESS:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_SUCCESS");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_UNSUCCESS:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_UNSUCCESS");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_OK_OTAPA_VERIFY:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_OK_OTAPA_VERIFY");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_PROGRESS:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_PROGRESS");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_FAILURES_EXCESS_SPC:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_FAILURES_EXCESS_SPC");
-                                                                       break;
-                                                               case TAPI_CALL_OTASP_LOCK_CODE_PW_SET:
-                                                                       TEST_DEBUG("TAPI_CALL_OTASP_LOCK_CODE_PW_SET");
-                                                                       break;
-                                                               default:
-                                                                       TEST_DEBUG("NONE");
-                                                                       break;
-                                                       }
-
-                                               }
-                                                       break;
-                                               case TAPI_CALL_OTATYPE_OTAPA:
-                                               {
-                                                       TEST_DEBUG("TAPI_CALL_OTATYPE_OTAPA");
-
-                                                       switch(ota_info.OtapaStatus)
-                                                       {
-                                                               case TAPI_CALL_OTAPA_STOP:
-                                                                       TEST_DEBUG("TAPI_CALL_OTAPA_STOP");
-                                                                       break;
-                                                               case TAPI_CALL_OTAPA_START:
-                                                                       TEST_DEBUG("TAPI_CALL_OTAPA_START");
-                                                                       break;
-                                                               default:
-                                                                       TEST_DEBUG("NONE");
-                                                                       break;
-                                                       }
-
-                                               }
-                                                       break;
-                                               default:
-                                                       TEST_DEBUG("NONE");
-                                                       break;
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_SETUP_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CALL_SETUP_CNF");
-                                       int     free_id;
-
-                                       if(event->Status == 0)
-                                       {
-                                               memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-                                               TEST_DEBUG("Received Call Setup for call Handle [%d]", temp_handle);
-
-                                               free_id = call_test_ret_first_free_index();
-
-                                               if (free_id == -1)
-                                               {
-                                                       TEST_DEBUG("No Free Context id ...");
-                                               }
-
-                                               else
-                                               {
-                                                       memcpy(&ctxt[free_id].info.callNumber, _glob_setup_info.szNumber, sizeof( _glob_setup_info.szNumber));
-                                                       ctxt[free_id].info.callState = TAPI_CALL_STATE_SETUPIND;
-                                                       ctxt[free_id].info.activeState = TAPI_CALL_CONNECT_IDLE;
-                                                       ctxt[free_id].info.isMobileOriginated = true;
-                                                       ctxt[free_id].handle = temp_handle;
-
-                                               }
-                                       }
-                                       else
-                                               TEST_DEBUG("event->Status is not zero..");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_ALERT_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_ALERT_IND");
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-                                       TEST_DEBUG("Received Alert for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.callState = TAPI_CALL_STATE_ALERT;
-
-                                       AUTO_LOG("EVENT: ALERT_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_INCOM_IND:
-                               {
-                                       TEST_DEBUG("\n$$$$$$$$$$$$$$    TAPI_EVENT_CALL_INCOM_IND       $$$$$$$$$$$$$$\n");
-                                       call_test_process_incom_ind(event->pData);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_WAITING_IND:
-                                       TEST_DEBUG("TAPI_EVENT_CALL_WAITING_IND");
-                                       break;
-
-                               case TAPI_EVENT_CALL_END_IND:
-                               {
-                                       int     index;
-                                       TelCallEndInfo_t EndInfo = {0, };
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_END_IND");
-
-                                       memcpy(&EndInfo, event->pData, sizeof(TelCallEndInfo_t));
-
-                                       TEST_DEBUG("Call Handle [%d], End Reason [%x]",
-                                               EndInfo.pCallHandle, EndInfo.CallEndCause);
-
-                                       index = call_test_ret_index_by_handle(EndInfo.pCallHandle);
-
-                                       /*      Free this context..     */
-                                       ctxt[index].used = false;
-
-                                       memset(&ctxt[index].info, 0, sizeof(TelTapiCallInfo_t));
-
-                                       AUTO_LOG("EVENT: END_IND:- Handle [%d] CauseX [%x]",
-                                               EndInfo.pCallHandle, EndInfo.CallEndCause);
-
-                                       /*      Continue Auto MO Call   */
-                                       call_test_count_mo();
-                               }
-
-                               break;
-
-                               case TAPI_EVENT_CALL_CONNECTED_IND:
-                               {
-                                       int     index;
-                                       //TapiResult_t  api_err = TAPI_API_SUCCESS;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_CONNECTED_IND");
-
-                                       /*      Stop the Timer..        */
-                                       //timer_reset();
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Connected Event  for call Handle [%d]", temp_handle);
-
-                                       curr_handle =  temp_handle;
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.callState = TAPI_CALL_STATE_CONV;
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_ACTIVE;
-
-                                       AUTO_LOG("EVENT: CONNECTED_IND:- Handle [%d]", temp_handle);
-
-                                       /*      Hold the Call after 10 sec      */
-                                       if(__call_test_auto_mo)
-                                       {
-                                               sleep(10);
-
-                                               call_test_auto_hold();
-                                       }
-
-                               }
-                                       break;
-
-
-                               case TAPI_EVENT_CALL_RETRIEVE_CNF:
-                               {
-                                       int             index;
-                                       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_RETRIEVE_CNF");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Activate Cnf Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_ACTIVE;
-
-                                       AUTO_LOG("EVENT: RETRIEVE_CNF:- Handle [%d]", temp_handle);
-
-                                       if(__call_test_auto_mo)
-                                       {
-                                               sleep(3);
-
-                                               TEST_DEBUG("### Drop the Call with handle [%d]", incoming_handle);
-
-                                               api_err = tel_release_call(temp_handle, &RequestId);
-
-                                               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-                                               AUTO_LOG("API: tel_release_call:- Handle [%d], Return [%d]", temp_handle, api_err);
-                                       }
-
-                               }
-                                       break;
-
-
-                               case TAPI_EVENT_CALL_HOLD_CNF:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_HOLD_CNF");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Hold Cnf Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_HELD;
-
-                                       AUTO_LOG("EVENT: HOLD_CNF:- Handle [%d]", temp_handle);
-
-                                       if(__call_test_auto_mo)
-                                       {
-                                               sleep(5);
-
-                                               call_test_auto_act();
-                                       }
-
-                               }
-                                       break;
-
-
-
-                               case TAPI_EVENT_CALL_SETUPCONFERENCE_CNF:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_SETUPCONFERENCE_CNF");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Conf Setup Cnf Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.conferenceState = TAPI_CALL_CONFERENCE_ACTIVE;
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_HELD;
-
-                                       AUTO_LOG("EVENT: SETUPCONFERENCE_CNF:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-
-
-                               case TAPI_EVENT_CALL_SPLITCONFERENCE_CNF:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_SPLITCONFERENCE_CNF");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-
-                                       TEST_DEBUG("Received Conf Split Cnf Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.conferenceState = TAPI_CALL_CONFERENCE_IDLE;
-                                       AUTO_LOG("EVENT: SPLITCONFERENCE_CNF:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-
-
-                               case TAPI_EVENT_CALL_TRANSFER_CNF:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_TRANSFER_CNF");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Tansfer Cnf Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.callState = TAPI_CALL_STATE_ENDING;
-                                       AUTO_LOG("EVENT: TRANSFER_CNF:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-
-                               case TAPI_EVENT_CALL_FORWARD_IND:
-                               {
-                                       int     index;
-                                       TelCallForwardType_t    type;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_FORWARD_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       memcpy(&type, event->pData+sizeof(TS_UINT), sizeof(TelCallForwardType_t ));
-
-                                       TEST_DEBUG("Received Fw Ind Event  for call Handle [%d]", temp_handle);
-                                       __PrintCallFwType("CallFwType: ", type);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-                                       AUTO_LOG("EVENT: FORWARD_IND::- Handle [%d]", temp_handle);
-                               }
-
-                                       break;
-
-                               case TAPI_EVENT_CALL_RETRIEVE_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_RETRIEVE_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Act Ind Event for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_ACTIVE;
-                                       AUTO_LOG("EVENT: RETRIEVE_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_HOLD_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_HOLD_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-
-                                       TEST_DEBUG("Received Held Ind Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-
-                                       ctxt[index].info.activeState = TAPI_CALL_CONNECT_HELD;
-                                       AUTO_LOG("EVENT: HOLD_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_TRANSFER_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_TRANSFER_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Tansfer Ind Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-                                       AUTO_LOG("EVENT: TRANSFER_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_SETUPCONFERENCE_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_SETUPCONFERENCE_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Conf Setup Ind Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-                                       AUTO_LOG("EVENT: SETUPCONFERENCE_IND:- Handle [%d]", temp_handle);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_BARRING_IND:
-                               {
-                                       int     index;
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_BARRING_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       TEST_DEBUG("Received Barr Ind Event  for call Handle [%d]", temp_handle);
-
-                                       index = call_test_ret_index_by_handle(temp_handle);
-                                       AUTO_LOG("EVENT: BARRING_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-
-
-                               case TAPI_EVENT_CALL_SEND_DTMF_CNF:
-                               {
-                                       TEST_DEBUG("Received TAPI_EVENT_CALL_SEND_DTMF_CNF");
-                                       AUTO_LOG("EVENT: DTMF_CNF: Cnf Count [%d]", _auto_dtmf_cnf_count++);
-                                       if((_auto_dtmf_send_count > 0) && (_auto_dtmf_send_count < 100))
-                                               call_test_auto_dtmf();
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_SET_LINEID_CNF:
-                               {
-                                       TEST_DEBUG("Received TAPI_EVENT_CALL_SET_LINEID_CNF");
-                                       AUTO_LOG("EVENT: SET_LINEID_CNF:");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_GET_LINEID_CNF:
-                               {
-                                       TEST_DEBUG("Received TAPI_EVENT_CALL_GET_LINEID_CNF");
-                                       AUTO_LOG("EVENT: GET_LINEID_CNF:");
-                               }
-                                       break;
-
-
-                               case TAPI_EVENT_CALL_AOCINFO_IND:
-                               {
-                                       TelCallAocInfo_t        info = {0, };
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_AOCINFO_IND");
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       memcpy(&info, event->pData+sizeof(TS_UINT), sizeof(TelCallAocInfo_t));
-
-                                       TEST_DEBUG("Received AOC Info Ind Event for call Handle [%d], acm [%u], max acm [%u]",
-                                               temp_handle, info.ACM, info.MaxAcm);
-                                       AUTO_LOG("EVENT: AOCINFO_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CALL_CONNECTEDNUMBERINFO_IND:
-                               {
-                                       TelCallConnectedNumberInfo_t    info = {0, };
-
-                                       TEST_DEBUG("TAPI_EVENT_CALL_CONNECTEDNUMBERINFO_IND");
-
-                                       memcpy(&temp_handle, event->pData, sizeof(TS_UINT));
-
-                                       memcpy(&info, event->pData+sizeof(TS_UINT), sizeof(TelCallConnectedNumberInfo_t));
-
-                                       TEST_DEBUG("Received SS Info Ind Event for call Handle [%d],  cli cause [%d], name mode [%d]",
-                                               temp_handle, info.no_cli_cause, info.name_mode);
-                                       AUTO_LOG("EVENT: CONNECTEDNUMBERINFO_IND:- Handle [%d]", temp_handle);
-                               }
-                                       break;
-
-
-                               default:
-                                       TEST_DEBUG("Undefined Event Type [%d] Received", event->EventType);
-                                       AUTO_LOG("EVENT: UNDEFINED EVENT:-TYPE [%d]", event->EventType);
-                                       break;
-
-                       }
-
-                       break;
-
-               default:
-                       TEST_DEBUG("*** Other TAPI EVENT received : class=%x type=%x ****",event->EventClass, event->EventType);
-                       break;
-
-       }
-       TEST_DEBUG("****************** End event *****************************");
-
-}
-
-int call_test_subscribe_tapi_events (void)
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfCALLEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int CALLEvtList[] =
-       {
-               TAPI_EVENT_CALL_SETUP_CNF,  /**<0x0000, This event indicates the Call Setup request triggered */
-               TAPI_EVENT_CALL_ALERT_IND,                      /**<    This event indicates the Call is in Alerting stage*/
-               TAPI_EVENT_CALL_CONNECTING_IND, /**<    This event indicates the Call is in Connecting stage*/
-               TAPI_EVENT_CALL_CONNECTED_IND,  /**<    This event indicates the Call is Connected */
-               TAPI_EVENT_CALL_INCOM_IND    ,          /**<    This event indicates Incoming Call indication to Application*/
-               TAPI_EVENT_CALL_ANSWER_CNF,     /**<    Incoming call was answered*/
-               TAPI_EVENT_CALL_RETRIEVE_CNF,   /**<    This event indicates Call is retrieved from held state*/
-               TAPI_EVENT_CALL_RETRIEVE_IND,   /**<    This event indicates that other party has retrieved the call from hold*/
-               TAPI_EVENT_CALL_HOLD_IND,               /**<    This event indicates that other party is has put the call on hold*/
-               TAPI_EVENT_CALL_HOLD_CNF ,              /**<    This event indicates is call is put on hold*/
-               TAPI_EVENT_CALL_TRANSFER_CNF,   /**<    This event indicates is call is explicitly transferred*/
-               TAPI_EVENT_CALL_TRANSFER_IND,   /**<    Call Transfer Indication*/
-               TAPI_EVENT_CALL_SETUPCONFERENCE_CNF,            /**<    This event indicates that Call is joined in a conference*/
-               TAPI_EVENT_CALL_SETUPCONFERENCE_IND,            /**<    Conference setup indication*/
-               TAPI_EVENT_CALL_SPLITCONFERENCE_CNF,            /**<    This event indicates Call is split from conference*/
-               TAPI_EVENT_CALL_SEND_DTMF_CNF,  /**<    This event indicates the confirmation for sending DTMF Digits to the network*/
-               TAPI_EVENT_CALL_WAITING_IND,                    /**<    Call waiting indication*/
-               TAPI_EVENT_CALL_FORWARD_IND,            /**<    This event indication for Call is forwarded */
-               TAPI_EVENT_CALL_RELEASE_CNF,            /**<    This event is indicated when a specific call is released requested by the application*/
-               TAPI_EVENT_CALL_RELEASE_ALL_CNF,        /**<    This event is indicated when all the calls released requested by the application*/
-               TAPI_EVENT_CALL_RELEASE_ALL_ACTIVE_CNF, /**<    This event is indicated when all the active calls released requested by the application*/
-               TAPI_EVENT_CALL_RELEASE_ALL_HELD_CNF,           /**<    This event is indicated when all the held calls released requested by the application*/
-               TAPI_EVENT_CALL_END_IND,                         /**<   This event indicates the Call is Ended. This event can be solicited/unsolicited.*/
-               TAPI_EVENT_CALL_GET_LINEID_CNF, /**<    Error in Get Line ID    */
-               TAPI_EVENT_CALL_SET_LINEID_CNF, /**<            Error in Set Line Id            */
-               TAPI_EVENT_CALL_SWAP_CNF, /**< Call Swap Confirmation */
-               TAPI_EVENT_CALL_GET_PRIVACYMODE_CNF,    /**<    Get Privacy mode        */
-               TAPI_EVENT_CALL_SET_PRIVACYMODE_CNF, /**<               Set Privacy mode        */
-               TAPI_EVENT_CALL_PRIVACYMODE_IND,        /**<    Privacy mode Indication */
-               TAPI_EVENT_CALL_FLASHINFO_CNF, /**<             Flash info      */
-               TAPI_EVENT_CALL_EXIT_EMERGENCYMODE_CNF, /**<            Exit Emergency mode     cnf */
-               TAPI_EVENT_CALL_EMERGENCYMODE_IND, /**<          Emergency mode ind */
-               TAPI_EVENT_CALL_TIME_CNF, /**<           call time cnf */
-               TAPI_EVENT_CALL_TIME_IND, /**<           call time ind */
-               TAPI_EVENT_CALL_OTA_PROGRESS_IND, /**<           ota progress ind */
-               TAPI_EVENT_CALL_DISPLAY_INFO_IND, /**<           display info ind */
-               TAPI_EVENT_CALL_BARRING_IND,                    /**<    This event indicates the Call is Barred*/
-               TAPI_EVENT_CALL_FORWARDED_INFO_IND,     /**<    This event indicates the MT call is Forwarded*/
-               TAPI_EVENT_CALL_AOCINFO_IND,    /**<    This event indicates the AOC Information*/
-               TAPI_EVENT_CALL_CALLINGNAMEINFO_IND,    /**<    This event indicates the Calling Name Information*/
-               TAPI_EVENT_CALL_CONNECTEDNUMBERINFO_IND,        /**<    This event indicates the Connected Number Information*/
-               TAPI_EVENT_CALL_CLISUPRESSIONREJ_IND,   /**<    This event indicates the CLI Suppression Indication*/
-               TAPI_EVENT_CALL_DEFLECTED_IND,  /**<    This event indicates the Call is Deflected*/
-               TAPI_EVENT_CALL_UNCOND_FORWARDING_IND,  /**<    This event indicates the Call is unconditionally forwarded*/
-               TAPI_EVENT_CALL_COND_FORWARDING_IND,    /**<    This event indicates the Call is conditionally forwarded*/
-               TAPI_EVENT_CALL_CONNECTED_ECT_REMOTE_IND,       /**<    This event indicates the ECT remote connection  */
-               TAPI_EVENT_CALL_ON_HOLD_RELEASED_IND,   /**<    This event indicates the Call on hold is released*/
-               TAPI_EVENT_CALL_ALERT_ECT_REMOTE_IND,   /**<    This event indicates the ECT remote alert*/
-               TAPI_EVENT_CALL_SS_FORWARDED_MSG_RXED_IND,      /**<    This event indicates that the forwarded msg has been received*/
-       };
-
-       iNumOfCALLEvt = sizeof(CALLEvtList)/sizeof(int);
-       CALL_subscription_id = (unsigned int *) calloc (iNumOfCALLEvt, sizeof (unsigned int));
-
-
-
-       for( i=0 ; i< iNumOfCALLEvt; i++ )
-       {
-               api_err = tel_register_event(CALLEvtList[i], &CALL_subscription_id[i],(TelAppCallback)&call_async_event_callback,NULL );
-               if(api_err != TAPI_API_SUCCESS)
-               {
-                       TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", CALLEvtList[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-
-
-
-#if 0
-       char *videocallEvents[] = {
-                       "Telephony.Call.Video.SetupCnf",
-                       "Telephony.Call.Video.AlertInd",
-                       "Telephony.Call.Video.ConnectedInd",
-                       "Telephony.Call.Video.IncomingInd",
-                       "Telephony.Call.Video.AnswerCnf",
-                       "Telephony.Call.Video.ForwardInd",
-                       "Telephony.Call.Video.ReleaseCnf",
-                       "Telephony.Call.Video.EndInd",
-                        "Telephony.Call.Video.BarringInd",
-                        "Telephony.Call.Video.ForwardedInfoInd",
-                        "Telephony.Call.Video.AocInfoInd",
-                       "Telephony.Call.Video.ConnectedNumberInfoInd",
-                       "Telephony.Call.Video.UncondforwardingActiveInd",
-                        "Telephony.Call.Video.CondforwardingActiveInd",
-                        "Telephony.Call.Video.ConnectedEctRemoteInd",
-       };
-
-       for(count =0;count  <  (sizeof(videocallEvents)/sizeof(*videocallEvents)) ; count++)
-       {
-               error_code = EvtSysEventSubscribe (
-                               EvtDeliveryHandle,
-                               videocallEvents[count],                         /* notification ID */
-                               NULL,                                           /*      filter expression       */
-                               (EvtSysEventCb)call_test_noti_cb,               /* notification handler */
-                               (void *)&sdata,                         /* local data */
-                               &subscription_id2                       /* subscription ID */
-                               );
-               if (error_code )
-               {
-                       TEST_DEBUG( " EvtSysEventSubscribe(): error [%#X] for event [%s]", error_code , videocallEvents[count]);
-               }
-       }
-
-
-       return 0;
-#endif
-}
-
-
-int call_test_exit(void)
-{
-       int result = 0;
-       return result;
-}
-
-
-
-int call_test_get_request(void)
-{
-       //char ch;
-       int ret;
-       //char callId=0;
-       //unsigned short len;
-       char buf[256];
-       char dtmfStr[16] = "1000103001";
-       //char normal[16] = "+91";
-       //unsigned short error;
-       TapiResult_t            api_err = TAPI_API_SUCCESS;
-       int index;
-       int RequestID;
-       _auto_dtmf_send_count = 0;
-       _auto_dtmf_cnf_count = 0;
-
-       for(index=0; index<TAPI_CONTEXT_CALL_SIZE_MAX; index++)
-       {
-               if(ctxt[index].used == true)
-               {
-                       api_err = tel_get_call_status( ctxt[index].handle, &gcallStatus[index]);
-
-                       if(api_err != TAPI_API_SUCCESS)
-                       {
-                               TEST_DEBUG("Get Call Status Failed: returnStatus value is [%x] for handle[%d] ", api_err, ctxt[index].handle);
-                       }
-               }
-       }
-
-
-       printf("\n -----------------------------------------------------------------------------");
-       printf("\n ############  For gsm/wcdma/cdma ############ ");
-       printf("\n tel_exe_call_mo              :       mo <Number>");
-       printf("\n tel_exe_call_mo (SOS)                                :       sos <Number>");
-       printf("\n tel_answer_call (Accept)             :       ans");
-       printf("\n tel_answer_call (Reject)                     :       rej");
-       printf("\n tel_send_call_dtmf                           :       dtmf <String>");
-       printf("\n tel_release_call                             :       drop <Call handle>");
-       printf("\n tel_release_call_all                         :       rall");
-       printf("\n tel_get_call_status  (SyncAPI)               :       status <Call handle>");
-       printf("\n tel_get_call_duration (SyncAPI)              :       duration <Call handle>");
-       printf("\n Get call state from NPS (SyncAPI)            :       state");
-
-       printf("\n ############  For only gsm/wcdma ############ ");
-       printf("\n tel_answer_call(Hold&Accept)                 :       hna");
-       printf("\n tel_answer_call(Replace)                     :       rep");
-       printf("\n tel_hold_call                                :       hld <Call handle>");
-       printf("\n tel_retrieve_call                            :       act <Call handle>");
-       printf("\n tel_swap_call                :       swap <Active Call handle> <Held Call handle>");
-       printf("\n tel_exe_call_explicit_transfer                       :       tran <Active Call handle>");
-       printf("\n tel_join_call                                :       join <Active Call handle> <Held Call handle>");
-       printf("\n tel_split_call                       :       split <Call handle>");
-       printf("\n tel_release_call_all_active                  :       ract");
-       printf("\n tel_release_call_all_held                    :       rhld");
-       printf("\n tel_activate_call_ccbs (not supported)               :       ccbs <Call handle>");
-       printf("\n tel_deflect_call (not supported)             :       defl <Number>");
-       printf("\n tel_get_call_act_line                :       lineg");
-       printf("\n tel_set_call_act_line                :       lines");
-       printf("\n tel_get_call_conf_list(SyncAPI)              :       conflist <Call handle>");
-
-       printf("\n ############  For only cdma ############ ");
-       printf("\n tel_exe_call_flash_info                              :       flash1  ");
-       printf("\n tel_exe_call_flash_info (with Number)                :       flash2 <Number>");
-       printf("\n tel_get_call_privacy_mode                    :       pmodeg <vp_type(1/2/3)>");
-       printf("\n tel_set_call_privacy_mode            :       pmodes <vp_type(1/2/3)> <vp_mode(0/1)>");
-       printf("\n tel_exit_call_emergency_mode                 :       xemer ");
-       printf("\n tel_get_call_time                    :       time <mask(count 1, total time 2 last time 4)>");
-
-       printf("\n\n quit                                               :        quit ");
-       printf("\n -----------------------------------------------------------------------------");
-
-
-       printf("\n########################################################\n\n");
-
-       for(index=0; index<TAPI_CONTEXT_CALL_SIZE_MAX; index++)
-       {
-               if(ctxt[index].used == true)
-               {
-                       fprintf(stderr, " Index:[%d], handle: [%d], [%s], [%s],[%s],",
-                               index, ctxt[index].handle, gcallStatus[index].pNumber, (gcallStatus[index].bMoCall)?"MO":"MT", (gcallStatus[index].bConferenceState)?"Conference":"Single");
-                       __PrintCallType(" ", gcallStatus[index].CallType);
-                       __PrintCallState("\n Call State:", gcallStatus[index].CallState);
-                       __PrintActiveCallState(" Active Call State:", gcallStatus[index].CallActiveState);
-                       fprintf(stderr, "\n");
-               }
-       }
-       printf("\n########################################################\n");
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0) {
-               if (errno == EINTR)
-               perror("read(1)");
-               return -1;
-       } else if (ret == 0) return ret;
-
-
-
-       TEST_DEBUG("Enter the API code: ");
-
-
-       /******************************************************************************
-       *
-       *                                                               C A L L  A P I
-       *
-       *******************************************************************************/
-
-       if(strncmp(buf, "flash1", 6) == 0)
-       {
-               TEST_DEBUG("###flash1 .... ");
-
-               api_err = tel_exe_call_flash_info(NULL,&RequestID);
-
-               TEST_DEBUG(" \n tel_exe_call_flash_info Tapi return returnStatus value is [%x]  RequestID : %d \n ", api_err, RequestID);
-      }
-
-
-       if(strncmp(buf, "flash2", 6) == 0)
-       {
-               char            tempNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               char    DialNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               int             length = 0;
-               strncpy(tempNum, &buf[7], TAPI_CALL_DIALDIGIT_LEN_MAX);
-               length = strlen(tempNum);
-               strncpy(DialNum,tempNum, length-1);  // removing '/n' form the end of the string
-               TEST_DEBUG("### dial number :[%s]", DialNum);
-
-               api_err = tel_exe_call_flash_info(DialNum, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "pmodeg", 6) == 0)
-       {
-               char temp[2];
-               int  vp_type= -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[7], 1);
-               vp_type = atoi(temp);
-
-               TEST_DEBUG("### tel_get_call_privacy_mode: vp_type [%d]", vp_type);
-
-               api_err = tel_get_call_privacy_mode(vp_type,&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "pmodes", 6) == 0)
-       {
-               TEST_DEBUG("### tel_set_call_privacy_mode");
-
-               char temp[2];
-               TelCallVoicePrivacyInfo_t vp_info = { 0, };
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[7], 1);
-               vp_info.PrivacyType = atoi(temp);
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[9], 1);
-               vp_info.PrivacyMode = atoi(temp);
-
-               TEST_DEBUG("### tel_set_call_privacy_mode: vp_type [%d] vp_mode [%d]", vp_info.PrivacyType, vp_info.PrivacyMode);
-
-               api_err = tel_set_call_privacy_mode(vp_info,&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "xemer", 5) == 0)
-       {
-               TEST_DEBUG("###tel_exit_call_emergency_mode");
-
-               api_err = tel_exit_call_emergency_mode(&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if(strncmp(buf, "time", 4) == 0)
-       {
-               TEST_DEBUG("###tel_get_call_time");
-               char temp[2];
-               unsigned short mask= -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[5], 1);
-               mask = atoi(temp);
-
-               TEST_DEBUG("###tel_get_call_time.. req mask type:[0x%x]",mask );
-
-               api_err = tel_get_call_time(mask, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-      }
-//######################################################################
-       if(strncmp(buf, "sos", 3) == 0)
-       {
-//             int     free_id;
-               char    tempNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               int             length = 0;
-
-               strncpy(tempNum, &buf[4], TAPI_CALL_DIALDIGIT_LEN_MAX);
-               length = strlen(tempNum);
-
-               memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-               strncpy(_glob_setup_info.szNumber,tempNum, length-1);  // removing '/n' form the end of the string
-
-       _glob_setup_info.CallType=TAPI_CALL_TYPE_E911;
-
-               TEST_DEBUG("Request to Setup call with Number [%s], type %d",   _glob_setup_info.szNumber, _glob_setup_info.CallType);
-
-               api_err = tel_exe_call_mo(&_glob_setup_info, &curr_handle, &RequestID);
-
-               TEST_DEBUG(" after calling tel_exe_call_mo : Handle [%d]", curr_handle);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-#if 0 // move to call setup cnf event
-               if(api_err == TAPI_API_SUCCESS)
-               {
-                       free_id = call_test_ret_first_free_index();
-
-                       if (free_id == -1)
-                       {
-                               TEST_DEBUG("No Free Context ...");
-                       }
-
-                       else
-                       {
-                               memcpy(&ctxt[free_id].info.callNumber, _glob_setup_info.szNumber, sizeof( _glob_setup_info.szNumber));
-                               ctxt[free_id].info.callState = TAPI_CALL_STATE_ORIG;
-                               ctxt[free_id].info.activeState = TAPI_CALL_CONNECT_IDLE;
-                               ctxt[free_id].info.isMobileOriginated = true;
-                               ctxt[free_id].handle = curr_handle;
-
-                       }
-               }
-#endif
-
-
-      }
-
-#if 0
-       if(strncmp(buf, "automo", 6) == 0)
-       {
-               char temp[16] = {0, };
-
-               memcpy(temp, &buf[7], _country_spc_num_);
-
-
-               memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-               _glob_setup_info.CallType=TAPI_CALL_TYPE_VOICE;
-               strncpy(_glob_setup_info.szNumber, pre_string, sizeof(pre_string));
-
-               strncat(_glob_setup_info.szNumber, temp, _country_spc_num_);
-
-               _glob_setup_info.IdentityMode = TAPI_CALL_IDENTITY_SHOW;
-
-               call_test_auto_mo();
-
-       }
-
-       if(strncmp(buf, "autoans", 7) == 0)
-       {
-               call_test_auto_ans();
-       }
-
-#endif
-       if(strncmp(buf, "vmo", 2) == 0)
-       {
-//             int     free_id;
-               char    tempNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               int             length = 0;
-
-               strncpy(tempNum, &buf[4], TAPI_CALL_DIALDIGIT_LEN_MAX);
-               length = strlen(tempNum);
-
-               memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-               strncpy(_glob_setup_info.szNumber,tempNum, length-1);  // removing '/n' form the end of the string
-
-               _glob_setup_info.CallType=TAPI_CALL_TYPE_DATA;
-
-               TEST_DEBUG("Request to Setup call with Number [%s], type %d",   _glob_setup_info.szNumber, _glob_setup_info.CallType);
-
-               api_err = tel_exe_call_mo(&_glob_setup_info, &curr_handle, &RequestID);
-
-               TEST_DEBUG(" after calling tel_exe_call_mo : Handle [%d]", curr_handle);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-#if 0 // move to call setup cnf event
-               if(api_err == TAPI_API_SUCCESS)
-               {
-                       free_id = call_test_ret_first_free_index();
-
-                       if (free_id == -1)
-                       {
-                               TEST_DEBUG("No Free Context ...");
-                       }
-
-                       else
-                       {
-                               memcpy(&ctxt[free_id].info.callNumber, _glob_setup_info.szNumber, sizeof( _glob_setup_info.szNumber));
-                               ctxt[free_id].info.callState = TAPI_CALL_STATE_ORIG;
-                               ctxt[free_id].info.activeState = TAPI_CALL_CONNECT_IDLE;
-                               ctxt[free_id].info.isMobileOriginated = true;
-                               ctxt[free_id].handle = curr_handle;
-
-                       }
-               }
-#endif
-
-      }
-
-       if(strncmp(buf, "mo", 2) == 0)
-       {
-//             int     free_id;
-               char    tempNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               int             length = 0;
-
-               strncpy(tempNum, &buf[3], TAPI_CALL_DIALDIGIT_LEN_MAX);
-               length = strlen(tempNum);
-
-               memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-               strncpy(_glob_setup_info.szNumber,tempNum, length-1);  // removing '/n' form the end of the string
-
-               _glob_setup_info.CallType=TAPI_CALL_TYPE_VOICE;
-               //_glob_setup_info.Ecc=TAPI_CALL_ECC_DEFAULT;
-
-               TEST_DEBUG("Request to Setup call with Number [%s], type %d",   _glob_setup_info.szNumber, _glob_setup_info.CallType);
-
-               api_err = tel_exe_call_mo(&_glob_setup_info, &curr_handle, &RequestID);
-
-               TEST_DEBUG(" after calling tel_exe_call_mo : Handle [%d]", curr_handle);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-#if 0 // move to call setup cnf event
-               if(api_err == TAPI_API_SUCCESS)
-               {
-                       free_id = call_test_ret_first_free_index();
-
-                       if (free_id == -1)
-                       {
-                               TEST_DEBUG("No Free Context ...");
-                       }
-
-                       else
-                       {
-                               memcpy(&ctxt[free_id].info.callNumber, _glob_setup_info.szNumber, sizeof( _glob_setup_info.szNumber));
-                               ctxt[free_id].info.callState = TAPI_CALL_STATE_ORIG;
-                               ctxt[free_id].info.activeState = TAPI_CALL_CONNECT_IDLE;
-                               ctxt[free_id].info.isMobileOriginated = true;
-                               ctxt[free_id].handle = curr_handle;
-
-                       }
-               }
-#endif
-
-      }
-
-
-       if( strncmp(buf, "ans", 3) == 0 )
-       {
-               TEST_DEBUG("###answer incoming call");
-
-               api_err = tel_answer_call(incoming_handle, TAPI_CALL_ANSWER_ACCEPT, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "hna", 3) == 0 )
-       {
-//             TS_UINT active_handle = -1;
-
-//             active_handle = call_test_ret_handle_by_active_state();
-
-//             TEST_DEBUG("### hold active call [%d] and accept waiting call", active_handle);
-
-               TEST_DEBUG("### hold active call and accept waiting call");
-
-               api_err = tel_answer_call(incoming_handle, TAPI_CALL_ANSWER_HOLD_AND_ACCEPT, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "rep", 3) == 0 )
-       {
-//             TS_UINT active_handle = -1;
-
-//             active_handle = call_test_ret_handle_by_active_state();
-
-//             TEST_DEBUG("### release active call [%d] and accept waiting call", active_handle);
-
-               TEST_DEBUG("### release active call and accept waiting call");
-
-               api_err = tel_answer_call(incoming_handle, TAPI_CALL_ANSWER_REPLACE, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-
-       if( strncmp(buf, "rej", 3) == 0 )
-       {
-               TEST_DEBUG("### reject waiting call ");
-
-               api_err = tel_answer_call(incoming_handle, TAPI_CALL_ANSWER_REJECT, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-//+++++++++++ Release
-       if( strncmp(buf, "rall", 4) == 0 )
-       {
-               TEST_DEBUG("### release all calls. ");
-
-               api_err = tel_release_call_all(&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "rall.e", 6) == 0 )
-       {
-               TEST_DEBUG("### release all calls.with err option ");
-
-               api_err = tel_release_call(curr_handle, &RequestID);
-
-               TEST_DEBUG(" Tapi returned api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "ract", 4) == 0 )
-       {
-               TEST_DEBUG("### release all active calls. ");
-
-               api_err = tel_release_call_all_active( &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "rhld", 4) == 0 )
-       {
-               TEST_DEBUG("### release all held calls. ");
-
-               api_err = tel_release_call_all_held( &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-       if( strncmp(buf, "drop", 4) == 0 )
-       {
-               char temp[2];
-               TS_UINT handle= -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[5], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG("### Drop the Call with handle [%d]", handle);
-
-               api_err = tel_release_call(handle,  &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-      }
-
-
-
-       if( strncmp(buf, "hld", 3) == 0 )
-       {
-               char temp[2];
-               TS_UINT handle= -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[4], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG("### Hold the call No. %d !!", handle);
-
-               api_err = tel_hold_call(handle, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-       }
-
-
-       if( strncmp(buf, "act", 3) == 0 )
-       {
-               char temp[2];
-               TS_UINT handle= -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[4], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG("### Activate the call No. %d !!", handle);
-
-               api_err = tel_retrieve_call(handle, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if( strncmp(buf, "swap", 4) == 0 )
-       {
-               char temp[2];
-               TS_UINT held_handle, active_handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[5], 1);
-               active_handle = atoi(temp);
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[7], 1);
-               held_handle = atoi(temp);
-
-               TEST_DEBUG("### Swap! Active call No, [%d], Hold the call No. [%d]",
-                       active_handle, held_handle);
-
-               api_err = tel_swap_call(active_handle, held_handle, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-
-       if( strncmp(buf, "join", 4) == 0 )
-       {
-               char temp[2];
-               TS_UINT held_handle, active_handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[5], 1);
-               active_handle = atoi(temp);
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[7], 1);
-               held_handle = atoi(temp);
-
-               TEST_DEBUG("Setup a Conference Call with Active & Held Handles [%d] [%d]",
-                       active_handle, held_handle);
-
-               api_err = tel_join_call(active_handle,  held_handle, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-       }
-
-
-       if( strncmp(buf, "split", 5) == 0 )
-       {
-               char temp[2];
-               TS_UINT  handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(temp, &buf[6], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG("Split Call Handle [%d] from Conference call", handle);
-
-               api_err = tel_split_call(handle, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "conflist", 8) == 0)
-       {
-               unsigned int  callList[10];
-               int  noOfCalls;
-               char temp[2];
-               int i=0;
-               TS_UINT  handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(temp, &buf[9], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG("Get Conference List for call handle [%d]", handle);
-
-               api_err = tel_get_call_conf_list(handle, callList, &noOfCalls);
-
-               if(api_err == TAPI_API_SUCCESS)
-               {
-                   TEST_DEBUG(" Get Conference List () - call handle : %d   No.of Calls %d",handle, noOfCalls );
-
-                   for(i=0;i<noOfCalls;i++)
-                   {
-                       TEST_DEBUG("Voice Test: Call Handle %d  : %d\n", i+1, callList[i]);
-                   }
-               }
-               else
-               {
-                   TEST_DEBUG("Voice Test: Get Conference List  Failed: returnStatus value is [%d]", api_err);
-               }
-
-       }
-
-
-       if(strncmp(buf, "status", 6) == 0)
-       {
-               TelCallStatus_t callStatus;
-               char temp[2];
-               TS_UINT  handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(temp, &buf[7], 1);
-               handle = atoi(temp);
-
-               TEST_DEBUG(" Get Call Status informaiton for call handle %d", handle);
-
-               api_err = tel_get_call_status(handle, &callStatus);
-
-               if(api_err == TAPI_API_SUCCESS)
-               {
-                       fprintf(stderr, "\n\t CallNumber             : %s",callStatus.pNumber);
-                       fprintf(stderr, "\n\t Is Mobile Originated   : %d(1:true, 0:false)", callStatus.bMoCall);
-                       __PrintCallType("\n\t CallType               :", callStatus.CallType);
-                       __PrintActiveCallState("\n\t CallActiveState        :", callStatus.CallActiveState);
-                       __PrintCallState("\n\t CallState              :", callStatus.CallState);
-                       fprintf(stderr, "\n\t isConferenceState : %d(1:true, 0:false)\n",callStatus.bConferenceState);
-               }
-               else
-               {
-                   TEST_DEBUG("Get Call Status Failed: returnStatus value is [%x] ", api_err);
-               }
-
-       }
-
-       if( strncmp(buf, "duration", 8) == 0 )
-       {
-               char temp[2];
-               unsigned int duration;
-               TS_UINT  handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(temp, &buf[9], 1);
-               handle = atoi(temp);
-
-
-               TEST_DEBUG("### Get Duration for  the call handle. %d !!", handle);
-
-               api_err = tel_get_call_duration(handle, &duration);
-               TEST_DEBUG("Call Duration for the Call handle [%d] is: [%d] sec  \n", handle, duration);
-       }
-
-
-       if(strncmp(buf, "tran", 4) == 0)
-       {
-               char temp[2];
-               TS_UINT active_handle = -1;
-
-               memset(temp, 0, 2);
-               memcpy(&temp, &buf[5], 1);
-               active_handle = atoi(temp);
-
-
-               TEST_DEBUG("Transfer calls with handles [%d]", active_handle);
-
-               api_err = tel_exe_call_explicit_transfer(active_handle,  &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-      }
-
-       if(strncmp(buf, "dtmf", 4) == 0)
-       {
-               char            tempStr[MAX_BURST_DTMF_STRLEN] ={0,};
-               char    str[MAX_BURST_DTMF_STRLEN] = {0,};
-               int             length = 0;
-               strncpy(tempStr, &buf[5], MAX_BURST_DTMF_STRLEN);
-               length = strlen(tempStr);
-               strncpy(str,tempStr, length-1);  // removing '/n' form the end of the string
-               TEST_DEBUG("### Send DTMF - [%s]", str);
-
-               api_err = tel_send_call_dtmf(str, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-       if(strncmp(buf, "clir", 4) == 0)
-       {
-//             int     free_id;
-               char    tempNum[TAPI_CALL_DIALDIGIT_LEN_MAX+1];
-               int             length = 0;
-
-               strncpy(tempNum, &buf[5], TAPI_CALL_DIALDIGIT_LEN_MAX);
-               length = strlen(tempNum);
-
-               memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-               strncpy(_glob_setup_info.szNumber,tempNum, length-1);  // removing '/n' form the end of the string
-
-               _glob_setup_info.CallType=TAPI_CALL_TYPE_VOICE;
-
-               TEST_DEBUG("Request to Setup CLIR call with Number [%s], type %d",      _glob_setup_info.szNumber, _glob_setup_info.CallType);
-
-               api_err = tel_exe_call_mo(&_glob_setup_info, &curr_handle, &RequestID);
-
-               TEST_DEBUG(" after calling tel_exe_call_mo : Handle [%d]", curr_handle);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-      }
-
-       if(strncmp(buf, "adtmf", 5) == 0)
-       {
-               char DtmfString[10] = {0, };
-               unsigned char length;
-
-                strcpy(DtmfString, "1234\0");
-                length = strlen(DtmfString);
-
-                TEST_DEBUG("Send DTMF digits [%s], length %d", DtmfString, length);
-
-               api_err = tel_send_call_dtmf(DtmfString, &RequestID);
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-               _auto_dtmf_send_count++;
-       }
-
-       if(strncmp(buf, "ds", 2) == 0)
-       {
-               strncat(dtmfStr, &buf[3], 16);
-               strncpy(_glob_setup_info.szNumber, dtmfStr, TAPI_CALL_DIALDIGIT_LEN_MAX);
-               TEST_DEBUG("### make a call for DTMF test....%s", _glob_setup_info.szNumber);
-
-               api_err=tel_exe_call_mo( &_glob_setup_info, &curr_handle,&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-      }
-
-
-       if(strncmp(buf, "lineg", 5) == 0)
-       {
-               TEST_DEBUG("### Get Current Active Line.");
-
-               api_err = tel_get_call_act_line(&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-               TEST_DEBUG("### Current Active Line : %d", _glob_test_curr_line);
-       }
-
-       if(strncmp(buf, "lines", 5) == 0)
-       {
-               TEST_DEBUG("### Set Current Active Line.");
-
-               if(_glob_test_curr_line == TAPI_CALL_ACTIVE_LINE1)
-                       _glob_test_curr_line = TAPI_CALL_ACTIVE_LINE2;
-
-               else
-                       _glob_test_curr_line = TAPI_CALL_ACTIVE_LINE1;
-
-               api_err = tel_set_call_act_line(_glob_test_curr_line,&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "ccbs", 4) == 0)
-       {
-               TEST_DEBUG("### Activate ccbs  call handle[%d]", curr_handle);
-
-               api_err = tel_activate_call_ccbs(curr_handle,&RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-       }
-
-       if(strncmp(buf, "defl", 4) == 0)
-       {
-               int             len1;
-               char    str[TAPI_CALL_DIALDIGIT_LEN_MAX] = {0, };
-               TelCallDeflectDstInfo_t dst;
-
-               memset(&dst, 0, sizeof(dst));
-
-               strncpy(str, &buf[5], TAPI_CALL_DIALDIGIT_LEN_MAX);
-
-               len1 = strlen(str);
-
-               strncpy((char*)dst.number, &str[0], (len1-1));
-
-               TEST_DEBUG("Deflect Call Handle [%d] to [%s]", incoming_handle, dst.number);
-
-               api_err = tel_deflect_call(incoming_handle,&dst, &RequestID);
-
-               TEST_DEBUG(" Tapi return api_err value is [%x] ", api_err);
-
-       }
-
-       if(strncmp(buf, "quit", 4) == 0)
-       {
-               TEST_DEBUG("quit..... ");
-
-               return -1;
-      }
-
-       /******************************************************************************
-       *
-       *                                       C O M M O N  A P I
-       *
-       *******************************************************************************/
-
-       if(strncmp(buf, "tapi", 4) == 0)
-        {
-       TS_BOOL status = FALSE;
-
-               api_err = tel_check_service_ready(&status);
-
-               TEST_DEBUG(" Current status of TAPI is:%d, api_err value is [%x]", status, api_err);
-        }
-
-
-       if(strncmp(buf, "state", 5) == 0)
-        {
-       unsigned char           call_state = 0;
-       api_err = vconf_get_int(VCONFKEY_TELEPHONY_CALL_STATE, (int*)&call_state);
-       TEST_DEBUG(" Current call state is:%s, api_err value is [%x]", call_state? "CONV" : "IDLE", api_err);
-        }
-
-       if(strncmp(buf, "menu", 4) == 0)
-        {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu\n");
-               //call_test_exit();
-               return -1;
-               //exit(0);
-        }
-
-       memset(buf, '\0', 256);
-
-    return ret;
-
-}
-
-
-void call_test_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-                ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-
-               if (ret)
-               {
-                   if (FD_ISSET(0, &readfds))
-                       {
-                                 if(call_test_get_request()<0)
-                                       break;
-                         }
-               }
-       }
-
-}
-
-void call_test_init(void)
-{
-       int count;
-
-       TEST_DEBUG("Please press enter...\n");
-
-       for( count = 0; count < TAPI_CONTEXT_CALL_SIZE_MAX; count++)
-       {
-               ctxt[count].handle = -1;
-               ctxt[count].used = false;
-       }
-
-       memset(&_glob_setup_info, 0, sizeof(_glob_setup_info));
-
-       _glob_setup_info.CallType=TAPI_CALL_TYPE_VOICE;
-       strncpy(_glob_setup_info.szNumber, pre_string, sizeof(pre_string));
-
-       call_test_loop();
-
-}
-
diff --git a/src/test_apps/tapi_cdma_data_test.c b/src/test_apps/tapi_cdma_data_test.c
deleted file mode 100644 (file)
index f7329a2..0000000
+++ /dev/null
@@ -1,926 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <pthread.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <string.h>
-#include <unistd.h>
-#include <assert.h>
-#include <glib.h>
-
-#include "TelUtility.h"
-#include "TapiEvent.h"
-#include "TapiCommon.h"
-#include "ITapiData.h"
-
-
-
-#ifndef false
-#define false 0
-#endif
-#ifndef true
-#define true  !0
-#endif
-#ifndef bool
-#define bool  char
-#endif
-
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}data_t;
-
-#define TEST_DEBUG(frmt, args...)      \
-{do { fprintf(stderr, "[CDMA-DATA Test][%s:%04d] "frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-
-#define TAPI_EVENT_CLASS_DATA_MAX_NUM 2
-#define        NUM_OF_CDMA_DATA_EVENT                  39
-
-// Global Variable
-int error_code;
-unsigned int cdma_data_subscription_id[NUM_OF_CDMA_DATA_EVENT] = {0, };
-
-void PrintNaiIndexType(TelDataNAIIndex_t NaiIndex)
-{
-       if(NaiIndex == TAPI_DATA_FACTORY_NAI)
-               printf(" NAI type : FACTORY \n");
-       else if(NaiIndex == TAPI_DATA_CUSTOM_NAI)
-               printf(" NAI type : Custom \n");
-       else
-               printf(" NAI type : Unknown [%d]\n", NaiIndex);
-
-       return;
-}
-
-void PrintPinControlInfo(TelDataPinControlInfo_t *pDsPin)
-{
-       printf(" Signal Type : ");
-       switch(pDsPin->signaltype)
-       {
-               case TAPI_DATA_SIGNAL_DCD:
-                       printf("DCD \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_DTR:
-                       printf("DTR \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_DSR:
-                       printf("DSR \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_RTS:
-                       printf("RTS \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_CTS:
-                       printf("CTS \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_RI:
-                       printf("RI \n");
-                       break;
-               default:
-                       printf("Unknown \n");
-                       break;
-       }
-
-       printf(" Signal Status : ");
-       switch(pDsPin->signalstatus)
-       {
-               case TAPI_DATA_SIGNAL_STATUS_OFF:
-                       printf("OFF \n");
-                       break;
-
-               case TAPI_DATA_SIGNAL_STATUS_ON:
-                       printf("ON \n");
-                       break;
-
-               default:
-                       printf("Unknown \n");
-                       break;
-       }
-
-       return;
-}
-
-void ComposeMobileIPNaiParametr(TelDataMipNaiParam_t *MipNaiParam)
-{
-       MipNaiParam->naiIndex = TAPI_DATA_FACTORY_NAI;
-       MipNaiParam->paramMask =        TAPI_DATA_NAI_MIP_MASK_REVERSE_TUNNEL + TAPI_DATA_NAI_MIP_MASK_HOME_ADDRESS + \
-                                       TAPI_DATA_NAI_MIP_MASK_PRIMARY_HOME_AGENT_IP;
-
-       MipNaiParam->genericInfo.revTunPreference = 0x3;
-       MipNaiParam->genericInfo.homeAddress = 0xA5D5E3E9;
-       MipNaiParam->genericInfo.primaryHaAddress = 0x5A5D3E9E;
-
-       return;
-}
-
-void EvtCurrentNaiIndexGetCnfCB(void *pData)
-{
-       TelDataNAIIndex_t *pNaiIndex;
-       pNaiIndex = (TelDataNAIIndex_t *)pData;
-
-       PrintNaiIndexType(*pNaiIndex);
-
-       return;
-}
-
-void EvtMipNaiGetCnfCB(void *pData)
-{
-       TelDataMipNaiParam_t *pMipNaiParam;
-       int i = 0;
-       pMipNaiParam = (TelDataMipNaiParam_t *)pData;
-
-       PrintNaiIndexType(pMipNaiParam->naiIndex);
-
-       printf(" Mask Value = %x\n", pMipNaiParam->paramMask);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_USER_NAI){
-               printf(" : User NAI Value");
-               for(i=0; i< pMipNaiParam->genericInfo.usrNaiLength; i++)
-                       printf("[0x%x] ", pMipNaiParam->genericInfo.usrNai[i]);
-               printf("\n");
-       }
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_SPI_MN_HA)
-               printf(" Mobile Node Home Agent Secure Parameter Index = [0x%x]\n", pMipNaiParam->genericInfo.mnHaSpi);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_SPI_MN_AAA)
-               printf(" Mobile Node AAA Secure Parameter Index = [0x%x]\n", pMipNaiParam->genericInfo.mnAaaSpi);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_REVERSE_TUNNEL)
-               printf(" Reverse Tunneling Preference = [0x%x]\n", pMipNaiParam->genericInfo.revTunPreference);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_HOME_ADDRESS)
-               printf(" Home Address = [0x%x]\n", pMipNaiParam->genericInfo.homeAddress);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_PRIMARY_HOME_AGENT_IP)
-               printf(" Primary Home Agent IP Address = [0x%x]\n", pMipNaiParam->genericInfo.primaryHaAddress);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_SECONDARY_HOME_AGENT_IP)
-               printf(" Secondary Home Agent IP Address = [0x%x]\n", pMipNaiParam->genericInfo.secondaryHaAddr);
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_MN_AAA_SS){
-               printf(" Mobile Node to AAA Shared Secret\n");
-               for(i=0; i< pMipNaiParam->ssInfo.mnHaSharedSecretLength; i++)
-                       printf("[0x%x] ", pMipNaiParam->ssInfo.mnHaSharedSecret[i]);
-               printf("\n");
-       }
-
-       if(pMipNaiParam->paramMask & TAPI_DATA_NAI_MIP_MASK_MN_HA_SS){
-               printf(" Mobile Node to Home Agent Shared Secret\n");
-               for(i=0; i< pMipNaiParam->ssInfo.mnAaaSharedSecretLength; i++)
-                       printf("[0x%x] ", pMipNaiParam->ssInfo.mnAaaSharedSecret[i]);
-               printf("\n");
-       }
-
-       return;
-}
-
-void EvtMipNaiChangedNotiCB(void *pData)
-{
-       TelDataNaiChangedItem_t *pChangedItem;
-       pChangedItem = (TelDataNaiChangedItem_t *)pData;
-
-       if(*pChangedItem == TAPI_DATA_NAI_GENERIC_INFO_CHANGED)
-               printf("[NAI Information]\n");
-       else if(*pChangedItem == TAPI_DATA_SHARED_SECRET_CHANGED)
-               printf("[Shared Screte]\n");
-
-       return;
-}
-
-void EvtTe2StatusDisplay(void *pData)
-{
-       TelDataTE2Status_t *pTe2Status;
-       pTe2Status= (TelDataTE2Status_t *)pData;
-
-       printf("Type[");
-       if(pTe2Status->type == TAPI_DATA_TE2_TYPE_UART)
-               printf("UART]\t");
-       else if(pTe2Status->type == TAPI_DATA_TE2_TYPE_USB)
-               printf("USB]\t");
-       else if(pTe2Status->type == TAPI_DATA_TE2_TYPE_BLUETOOTH)
-               printf("Bluetooth]\t");
-       else
-               printf("Unknown]\t");
-
-       printf("Status[");
-
-       if(pTe2Status->cable_status == TAPI_DATA_TE2_DETACHED)
-               printf("Detached]\n");
-       else if(pTe2Status->cable_status == TAPI_DATA_TE2_ATTACHED)
-               printf("Atached]\n");
-       else
-               printf("Unknown]\n");
-
-       return;
-}
-
-void EvtBytesCountDisplay(void *pData)
-{
-       TelDataPacketByteCounter_t *pByteCnt = NULL;
-       pByteCnt= (TelDataPacketByteCounter_t *)pData;
-
-       printf("Received Current Packet Bytes[%u]", pByteCnt->rx_curr_packet_bytes);
-       printf("Transmitted Current Packet Bytes[%u]", pByteCnt->tx_curr_packet_bytes);
-       printf("Received Total Packet Bytes[%llu]", pByteCnt->rx_total_packet_bytes);
-       printf("Transmitted Total Packet Bytes[%llu]", pByteCnt->tx_total_packet_bytes);
-
-       return;
-}
-
-void EvtIncomingCallTypeDisplay(void *pData)
-{
-       TelDataCallType_t *pCallType = NULL;
-       pCallType= (TelDataCallType_t *)pData;
-
-       printf("Incoming Call Type :[");
-       switch(*pCallType){
-               case TAPI_DATA_CALL_TYPE_DEFAULT:
-                       printf("Default]");
-                       break;
-               case TAPI_DATA_CALL_TYPE_FAX_FOR_NEXT_CALL:
-                       printf("FAX For Next Call]");
-                       break;
-               case TAPI_DATA_CALL_TYPE_FAX_FOR_ALL_CALLS:
-                       printf("FAX For All Calls]");
-                       break;
-               case TAPI_DATA_CALL_TYPE_ASYNC_FOR_NEXT_CALL:
-                       printf("Async For Next Call]");
-                       break;
-               case TAPI_DATA_CALL_TYPE_ASYNC_FOR_ALL_CALLS:
-                       printf("Async For All Call]");
-                       break;
-               default:
-                       printf("Unknown Incoming Call Type\n");
-                       break;
-       }
-       return;
-}
-
-void EvtDataRateInfoDisplay(void*pData)
-{
-       TelDataTE2DataRateInfo_t *pDataRate = NULL;
-       pDataRate= (TelDataTE2DataRateInfo_t *)pData;
-
-       printf("Transmitted Bytes[%u]", pDataRate->tx_bytes);
-       printf("Received Bytes[%u]", pDataRate->rx_bytes);
-       printf("Report Period [%d]", pDataRate->report_period);
-       printf("Channel Number [%d]", pDataRate->channel_num);
-       printf("Tx Number of Bar Level during the reporting period[%d]", pDataRate->tx_bar_level);
-       printf("Rx Number of Bar Level during the reporting period[%d]", pDataRate->rx_bar_level);
-
-       return;
-
-}
-
-void EvtBaudRateDisplay(void*pData)
-{
-       TelDataBaudRate_t *pBaudRate = NULL;
-       pBaudRate= (TelDataBaudRate_t *)pData;
-
-       printf("Baud Rate :[");
-       switch(*pBaudRate){
-               case TAPI_DATA_BAUDRATE_19200_BPS:
-                       printf("19200]");
-                       break;
-               case TAPI_DATA_BAUDRATE_38400_BPS:
-                       printf("38400]");
-                       break;
-               case TAPI_DATA_BAUDRATE_57600_BPS:
-                       printf("57600]");
-                       break;
-               case TAPI_DATA_BAUDRATE_115200_BPS:
-                       printf("115200]");
-                       break;
-               case TAPI_DATA_BAUDRATE_230400_BPS:
-                       printf("230400]");
-                       break;
-               default:
-                       printf("Unknown Baud Rate\n");
-                       break;
-       }
-       return;
-}
-
-void EvtRoamGuardDisplay(void *pData)
-{
-       TelDataRoamGuardMode_t *pMode = NULL;
-       pMode= (TelDataRoamGuardMode_t *)pData;
-
-       printf("Roam Guard Mode:[");
-       switch(*pMode){
-               case TAPI_DATA_ROAM_GUARD_DEFAULT:
-                       printf("Default]");
-                       break;
-               case TAPI_DATA_ROAM_GUARD_ALWAYS_ASK:
-                       printf("Always ASK]");
-                       break;
-               case TAPI_DATA_ROAM_ROAM_GUARD_NEVER_ASK:
-                       printf("Never ASK]");
-                       break;
-               case TAPI_DATA_ROAM_ROAM_GUARD_OFF:
-                       printf("OFF]");
-                       break;
-               case TAPI_DATA_ROAM_ROAM_GUARD_ON:
-                       printf("ON]");
-                       break;
-               default:
-                       printf("Unknown Roam Guard\n");
-                       break;
-       }
-       return;
-
-}
-
-void EvtModemNaiDisplay(void *pData)
-{
-       TelDataModemNAIMode_t *pMode = NULL;
-       pMode= (TelDataModemNAIMode_t *)pData;
-
-       printf("Modem NAI Mode:[");
-       switch(*pMode){
-               case TAPI_DATA_MODEM_NAI_OFF:
-                       printf("OFF]");
-                       break;
-               case TAPI_DATA_MODEM_NAI_ON:
-                       printf("ON]");
-                       break;
-               default:
-                       printf("Unknown Modem NAI Mode\n");
-                       break;
-       }
-       return;
-
-}
-
-void EvtModemBtModeDisplay(void *pData)
-{
-       TelDataDSType_t *pType = NULL;
-       pType= (TelDataDSType_t *)pData;
-
-       printf("Data Service Type :");
-       switch(*pType){
-               case TAPI_DATA_DS_TYPE_NORMAL:
-                       printf("DS TYPE : NORMAL");
-                       break;
-               case TAPI_DATA_DS_TYPE_DUN:
-                       printf("DS TYPE : DUN");
-                       break;
-               case TAPI_DATA_DS_TYPE_BTDUN:
-                       printf("DS TYPE : BTDUN");
-                       break;
-               case TAPI_DATA_DS_TYPE_IS:
-                       printf("DS TYPE : IS");
-                       break;
-               case TAPI_DATA_DS_TYPE_MMS:
-                       printf("DS TYPE : MMS");
-                       break;
-               default:
-                       printf("Unknown DS Type\n");
-                       break;
-       }
-       return;
-}
-
-void EvtForceRevAModeDisplay(void *pData)
-{
-       TelDataRevConfig_t *pMode = NULL;
-       pMode= (TelDataRevConfig_t *)pData;
-
-       printf("Forced RevA Mode :[");
-       switch(*pMode){
-               case TAPI_DATA_REVA:
-                       printf("REV-A]");
-                       break;
-               case TAPI_DATA_REV0:
-                       printf("REV-0]");
-                       break;
-               default:
-                       printf("Unknown Forced Rev Mode\n");
-                       break;
-       }
-       return;
-}
-
-void EvtPacketDataCallConfigDisplay(void *pData)
-{
-       TelDataPacketDataCallConfig_t *pPacketData = NULL;
-       TelDataPacketConfigType_t type;
-       TelDataPacketParam_t param;
-       pPacketData= (TelDataPacketDataCallConfig_t *)pData;
-
-       type = pPacketData->type;
-       memcpy(&param, &pPacketData->param, sizeof(TelDataPacketParam_t));
-
-       printf("Packet Data Call Type :");
-       switch(type){
-               case TAPI_DATA_PACKET_DATA_TYPE_QNC:
-                       printf("QNC");
-                       break;
-               case TAPI_DATA_PACKET_DATA_TYPE_MIP:
-                       printf("MIP");
-                       break;
-               case TAPI_DATA_PACKET_DATA_TYPE_CALL_TYPE:
-                       printf("Call Type");
-                       break;
-               case TAPI_DATA_PACKET_DATA_TYPE_PKT_ORIGIN_STRING:
-                       printf("ORG STRING");
-                       break;
-               case TAPI_DATA_PACKET_DATA_TYPE_PAP_USER_ID:
-                       printf("USER ID");
-                       break;
-               case TAPI_DATA_PACKET_DATA_TYPE_PAP_USER_PASSWORD:
-                       printf("USER PASSWORD");
-                       break;
-               default:
-                       printf("\nUnknown Type\n");
-                       break;
-       }
-
-       return;
-}
-
-void  cdma_data_async_event_callback(TelTapiEvent_t* event)
-{
-       printf("\n data_async_event_callback enter\n");
-
-       printf("Request ID : [0x%x]\n", event->RequestId);
-
-       printf("Status : [");
-       switch(event->Status)
-       {
-               case TAPI_DATA_NO_ERR:
-                       printf("No Err]\n");
-                       break;
-
-               case TAPI_DATA_PARAMETER_ERR:
-                       printf("Parameter Err]\n");
-                       break;
-
-               case TAPI_DATA_OFFLINE_ERR:
-                       printf("Phone Off]\n");
-                       break;
-
-               case TAPI_DATA_OTHER_ERR:
-               default:
-                       printf("Unknown Err]\n");
-                       break;
-       }
-
-       printf("event->EventType : %d\n", event->EventType);
-       printf("event->EventType : %d\n", TAPI_EVENT_DATA_PACKET_DATA_CALL_CONFIGURATION_GET_CNF);
-
-       switch(event->EventType)
-       {
-               case    TAPI_EVENT_DATA_MIP_NAI_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_MIP_NAI_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtMipNaiGetCnfCB(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_CURRENT_NAI_INDEX_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_CURRENT_NAI_INDEX_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtCurrentNaiIndexGetCnfCB(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_TE2_STATUS_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_TE2_STATUS_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtTe2StatusDisplay(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_TE2_STATUS_NOTI:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_TE2_STATUS_NOTI]\n");
-                               EvtTe2StatusDisplay(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_BYTES_COUNTER_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_BYTES_COUNTER_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtBytesCountDisplay(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_DS_TE2_DATA_RATE_INFO_NOTI:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_DS_TE2_DATA_RATE_INFO_NOTI]\n");
-                               EvtDataRateInfoDisplay(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_ROAM_GUARD_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_ROAM_GUARD_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtRoamGuardDisplay(event->pData);
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_MODEM_NAI_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_MODEM_NAI_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtModemNaiDisplay(event->pData);
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_EVDO_REV_CONFIG_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_EVDO_REV_CONFIG_GET_CNF]\n");
-                               if(event->Status ==TAPI_DATA_NO_ERR)
-                                       EvtForceRevAModeDisplay(event->pData);
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_DDTM_CONFIGURATION_GET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_DDTM_CONFIGURATION_GET_CNF]\n");
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_MIP_NAI_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_MIP_NAI_SET_CNF]\n");
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_BYTES_COUNTER_RESET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_BYTES_COUNTER_RESET_CNF]\n");
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_HDR_SESSION_CLEAR_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_HDR_SESSION_CLEAR_SET_CNF]\n");
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_ROAM_GUARD_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_ROAM_GUARD_SET_CNF]\n");
-                       }
-                       break;
-
-               case    TAPI_EVENT_DATA_EVDO_REV_CONFIG_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_FORCE_REVA_MODE_SET_CNF]\n");
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_DDTM_CONFIGURATION_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_DDTM_CONFIGURATION_SET_CNF]\n");
-                       }
-                       break;
-               case    TAPI_EVENT_DATA_RESTORE_NAI_SET_CNF:
-                       {
-                               printf("Event Type:  [TAPI_EVENT_DATA_RESTORE_NAI_SET_CNF]\n");
-                       }
-                       break;
-               case TAPI_EVENT_DATA_PACKET_DATA_CALL_CONFIGURATION_GET_CNF:
-                       {
-                               printf("Event Type: [TAPI_EVENT_DATA_PACKET_DATA_CALL_CONFIGURATION_GET_CNF]");
-                               EvtPacketDataCallConfigDisplay(event->pData);
-                       }
-                       break;
-
-               default:
-                       printf("Event Type: unknown event:[%d]\n", event->EventType);
-
-                       break;
-       }
-
-}
-
-
-int cdma_data_read_key_input(void)
-{
-       int ret;
-       char buf[512] = {0, };
-       char msg[512];
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-       int RequestID;
-
-       memset(buf,0, sizeof(buf));
-       memset(msg,0,sizeof(msg));
-
-       printf("*************** CDMA DATA TEST MENU ******************\n");
-       printf("0.  DSPin Control \n");
-       printf("3.  Get Mobile IP NAI \n");
-       printf("4.  Set Mobile IP NAI \n");
-       printf("5.  Get Current NAI Index \n");
-       printf("6.  Get TE2 Status \n");
-       //printf("7.  Reset Data bytes counter \n");
-       //printf("8.  Get Data bytes counter \n");
-       //printf("9.  Get Incoming Call Type \n");
-       //printf("10. Set Incoming Call Type \n");
-       printf("11. Get Data Service Baud Rate\n");
-       printf("12. Set Data Service Baud Rate\n");
-       //printf("13. Set HDR Session Clear\n");
-       printf("14. Get Roam Guard Mode\n");
-       printf("15. Set Roam Guard Mode\n");
-       printf("16. Get Modem NAI\n");
-       printf("17. Set Modem NAI\n");
-       printf("18. Get DS Type\n");
-       printf("19. Set DS Type\n");
-       printf("20. Get EVDO Rev Config\n");
-       printf("21. Set EVDO Rev Config(Rev-A or Rev-0)\n");
-       printf("22. Get Singed In State Mode\n");
-       printf("23. Set Singed In State Mode\n");
-       printf("24. Set the NAI value to factory setting\n");
-       printf("25. Get Dedicated Data Transmission Mode\n");
-       printf("26. Set Dedicated Data Transmission Mode\n");
-       printf("27. Get DSWorking Mode\n");
-       printf("28. Set DSWorking Mode\n");
-       printf("\n  BONUS!! ^^;;\n");
-       printf("29. Get Packet Data Call Configuration\n");
-       printf("29. Set Packet Data Call Configuration\n");
-       printf("q. quit\n");
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-
-       // Get Mobile IP NAI
-       if( memcmp(buf,"3",sizeof("3")-1) == 0 )
-       {
-               TelDataNAIIndex_t MipNaiIdx = TAPI_DATA_FACTORY_NAI;
-               unsigned short ParamMask = TAPI_DATA_NAI_MIP_MASK_REVERSE_TUNNEL + TAPI_DATA_NAI_MIP_MASK_HOME_ADDRESS + \
-                                          TAPI_DATA_NAI_MIP_MASK_PRIMARY_HOME_AGENT_IP;//TAPI_DATA_NAI_MIP_MASK_USER_NAI + TAPI_DATA_NAI_MIP_MASK_SPI_MN_HA + TAPI_DATA_NAI_MIP_MASK_SPI_MN_AAA;
-               ret_val = tel_get_data_mobile_ipnai (&MipNaiIdx, &ParamMask, &RequestID);
-               printf(" \n tel_get_data_mobile_ipnai Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Mobile IP NAI
-       if( memcmp(buf,"4",sizeof("4")-1) == 0 )
-       {
-               TelDataMipNaiParam_t MipNaiParam;
-               ComposeMobileIPNaiParametr(&MipNaiParam);
-               ret_val = tel_set_data_mobile_ipnai (&MipNaiParam, &RequestID);
-               printf(" \n tel_set_data_mobile_ipnai Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Current NAI Index
-       if( memcmp(buf,"5",sizeof("5")-1) == 0 )
-       {
-               ret_val = tel_get_data_current_nai_index(&RequestID);
-               printf(" \n tel_get_data_current_nai_index Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get TE2 Status
-       if( memcmp(buf,"6",sizeof("6")-1) == 0 )
-       {
-               ret_val = tel_get_data_te2_status(&RequestID);
-               printf(" \n tel_get_data_te2_status Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Roam Guard Mode
-       if( memcmp(buf,"14",sizeof("14")-1) == 0 )
-       {
-               ret_val = tel_get_data_roam_guard(&RequestID);
-               printf(" \n tel_get_data_roam_guard Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Roam Guard Mode
-       if( memcmp(buf,"15",sizeof("15")-1) == 0 )
-       {
-               TelDataRoamGuardMode_t RoamGuard = TAPI_DATA_ROAM_GUARD_DEFAULT;
-               ret_val = tel_set_data_roam_guard(&RoamGuard, &RequestID);
-               printf(" \n tel_set_data_roam_guard Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Modem NAI
-       if( memcmp(buf,"16",sizeof("16")-1) == 0 )
-       {
-               ret_val = tel_get_data_nai(&RequestID);
-               printf(" \n tel_get_data_nai Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Modem NAI
-       if( memcmp(buf,"17",sizeof("17")-1) == 0 )
-       {
-               TelDataModemNAIMode_t ModemNai = TAPI_DATA_MODEM_NAI_OFF;
-               ret_val = tel_set_data_nai(&ModemNai, &RequestID);
-               printf(" \n tel_set_data_nai Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // 20. Get EVDO Rev Config
-       if( memcmp(buf,"20",sizeof("20")-1) == 0 )
-       {
-               ret_val = tel_get_data_evdo_rev_config(&RequestID);
-               printf(" \n tel_get_data_evdo_rev_config Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set EVDO Rev Config(Rev-A or Rev-0)
-       if( memcmp(buf,"21",sizeof("21")-1) == 0 )
-       {
-               //TelDataRevConfig_t RevConfig = TAPI_DATA_REVA;
-               //ret_val = TelTapiDataSetEVDORevConfig (&RevConfig, &RequestID);
-               //printf(" \n TelTapiDataSetForceRevAMode Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Singed In State Mode
-       if( memcmp(buf,"22",sizeof("22")-1) == 0 )
-       {
-               //ret_val = tel_get_data_signed_in_sate (&RequestID);
-               printf(" \n tel_get_data_signed_in_sate Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Singed In State Mode
-       if( memcmp(buf,"23",sizeof("23")-1) == 0 )
-       {
-               //TelDataSignStatus_t SignStatus = TAPI_DATA_PACKET_NAI_SIGNIN_OUT;
-               //ret_val = tel_set_data_signed_in_sate (&SignStatus, &RequestID);
-               //printf(" \n tel_set_data_signed_in_sate Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set the NAI value to factory setting
-       if( memcmp(buf,"24",sizeof("24")-1) == 0 )
-       {
-               ret_val = tel_restore_data_nai(&RequestID);
-               printf(" \n tel_restore_data_nai Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Dedicated Data Transmission Mode
-       if( memcmp(buf,"25",sizeof("25")-1) == 0 )
-       {
-               ret_val = tel_get_data_ddtm_config(&RequestID);
-               printf(" \n tel_get_data_ddtm_cofig Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Dedicated Data Transmission Mode
-       if( memcmp(buf,"26",sizeof("26")-1) == 0 )
-       {
-               TelDataDDTMStatus_t DDTMStatus= TAPI_DATA_DDTM_MODE_OFF;
-               ret_val = tel_set_data_ddtm_config (&DDTMStatus, &RequestID);
-               printf(" \n tel_set_data_ddtm_cofig Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set DSWorking Mode
-       if( memcmp(buf,"28",sizeof("28")-1) == 0 )
-       {
-               //TelDataDSWorkingMode_t DSWorkingMode = TAPI_DATA_DSWORKING_MODE_OFF;
-               //ret_val = tel_set_data_ds_working_mode (&DSWorkingMode, &RequestID);
-               //printf(" \n tel_set_data_ds_working_mode Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Get Packet Data Call Config
-       if( memcmp(buf,"29",sizeof("29")-1) == 0 )
-       {
-               TelDataPacketConfigType_t Type;
-               int num;
-
-               printf("Select Config Type\n");
-               printf("0. QNC\n");
-               printf("1. Mobile IP\n");
-               printf("2. Packet Data Call Type\n");
-               printf("3. Packet Orig Str\n");
-               printf("4. Pap User ID\n");
-               printf("5. Pap Password\n");
-               printf(">> ");
-               scanf("%d", &num);
-
-               Type = num;
-
-               //ret_val = TelTapiDataGetPacketDataCallConfiguration(&Type, &RequestID);
-               printf(" \n TelTapiDataGetPacketDataCallConfiguration Tapi return returnStatus value is [%x]  RequestID : [%d] \n ", ret_val, RequestID);
-       }
-
-       // Set Packet Data Call Config
-       if( memcmp(buf,"30",sizeof("28")-1) == 0 )
-       {
-               printf("NOT YET\n");
-       }
-       // Exit
-       if( memcmp(buf,"q",sizeof("q")-1) == 0)
-       {
-               return -1;
-       }
-
-       return 0;
-}
-
-
-void cdma_data_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-               {
-                       if (FD_ISSET(0, &readfds))
-                       {
-                               if(cdma_data_read_key_input() < 0)
-                                       break;
-                       }
-               }
-       }
-}
-
-void cdma_data_test_unsubscribe_tapi_event(void)
-{
-       int i = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       for(i=0;i<NUM_OF_CDMA_DATA_EVENT; i++){
-               api_err = tel_deregister_event(cdma_data_subscription_id[i]);
-               if(api_err != TAPI_API_SUCCESS){
-                       TEST_DEBUG("tel_deregister_event isn't unsubscribed. sub id is %d api_err is %d\n",cdma_data_subscription_id[i],api_err);
-                       break;
-               }
-
-       }
-
-       tel_deinit();
-}
-
-void cdma_data_test_subscribe_tapi_events (void)
-{
-       int i = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       int CdmaDataEvt[NUM_OF_CDMA_DATA_EVENT] = {     TAPI_EVENT_DATA_MIP_NAI_GET_CNF,
-               TAPI_EVENT_DATA_MIP_NAI_SET_CNF,
-               TAPI_EVENT_DATA_CURRENT_NAI_INDEX_GET_CNF,
-               TAPI_EVENT_DATA_TE2_STATUS_GET_CNF,
-               TAPI_EVENT_DATA_TE2_STATUS_NOTI,
-               TAPI_EVENT_DATA_BYTES_COUNTER_RESET_CNF,
-               TAPI_EVENT_DATA_BYTES_COUNTER_GET_CNF,
-               TAPI_EVENT_DATA_DS_TE2_DATA_RATE_INFO_NOTI,
-               TAPI_EVENT_DATA_HDR_SESSION_CLEAR_SET_CNF,
-               TAPI_EVENT_DATA_ROAM_GUARD_GET_CNF,
-               TAPI_EVENT_DATA_ROAM_GUARD_SET_CNF,
-               TAPI_EVENT_DATA_MODEM_NAI_GET_CNF,
-               TAPI_EVENT_DATA_EVDO_REV_CONFIG_GET_CNF,
-               TAPI_EVENT_DATA_EVDO_REV_CONFIG_SET_CNF,
-               TAPI_EVENT_DATA_RESTORE_NAI_SET_CNF,
-               TAPI_EVENT_DATA_DDTM_CONFIGURATION_GET_CNF,
-               TAPI_EVENT_DATA_DDTM_CONFIGURATION_SET_CNF,
-               TAPI_EVENT_DATA_PACKET_DATA_CALL_CONFIGURATION_GET_CNF,
-
-       };
-
-       //TEST_DEBUG("########### CDMA DATA TEST #############\n");
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               for(i=0;i<NUM_OF_CDMA_DATA_EVENT; i++){
-                       api_err = tel_register_event(CdmaDataEvt[i], &cdma_data_subscription_id[i],(TelAppCallback)&cdma_data_async_event_callback, NULL);
-
-                       if(api_err != TAPI_API_SUCCESS){
-                               TEST_DEBUG("tel_register_event isn't subscribed. sub id is %d api_err is %d\n",cdma_data_subscription_id[i],api_err);
-                               break;
-                       }
-               }
-       }
-       else {
-
-               TEST_DEBUG("tel_init() failed");
-       }
-
-}
diff --git a/src/test_apps/tapi_cfg_test.c b/src/test_apps/tapi_cfg_test.c
deleted file mode 100644 (file)
index f8a02da..0000000
+++ /dev/null
@@ -1,855 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <string.h>
-#include <unistd.h>
-
-#include <assert.h>
-#include <glib.h>
-
-#include "ITapiCfg.h"
-#include "TapiCommon.h"
-#include "TelErr.h"
-#include "TelUtility.h"
-#include "vconf.h"
-#include "TapiEvent.h"
-
-//#include <ipcparam.h>
-
-#define TEST_MAX_CFG_AKEY_LEN 26
-
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}edata_t;
-
-#define TEST_DEBUG(frmt, args...) \
-       {do { fprintf(stderr, "\n[CFG Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-
-int error_code;
-extern int EvtDeliveryHandle ;
-static unsigned int *  Cfg_subscription_id;
-
-static int _PrintSIOMode(TelCfgSIOMode_t mode)
-{
-       switch(mode)
-       {
-               case TAPI_CFG_SIO_U1_DIAG_USB2_GPS:
-                       TEST_DEBUG("SIO mode: TAPI_CFG_SIO_U1_DIAG_USB2_GPS ");
-                       break;
-               case TAPI_CFG_SIO_U1_HFK_USB2_GPS:
-                       TEST_DEBUG("SIO mode: TAPI_CFG_SIO_U1_HFK_USB2_GPS ");
-                       break;
-               case TAPI_CFG_SIO_U1_HFK_USB2_DIAG:
-                       TEST_DEBUG("SIO mode: TAPI_CFG_SIO_U1_HFK_USB2_DIAG ");
-                       break;
-               default:
-                       TEST_DEBUG("SIO mode: None ");
-                       break;
-       }
-
-       return 0;
-}
-
-static int  tapi_cfg_callback  (TelTapiEvent_t *event)
-{
-       TEST_DEBUG("EVENT STATUS:[0x%x]", event->Status);
-
-       TEST_DEBUG("Status = [0x%x]", event->Status);
-
-       switch(event->EventClass)
-       {
-               case TAPI_EVENT_CLASS_CFG:
-               {
-                       switch(event->EventType)
-                       {
-                               case TAPI_EVENT_CFG_GET_A_KEY_CNF:
-                               {
-                                       TelCfgAKeyInfo_t Akey_info;
-                                       memset(&Akey_info, 0, sizeof(Akey_info));
-
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_A_KEY_CNF");
-
-                                       memcpy(&Akey_info, event->pData, sizeof(TelCfgAKeyInfo_t));
-
-                                       TEST_DEBUG("Akey:[%s]",Akey_info.A_key);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_VERIFY_A_KEY_CNF:
-                               {
-                                       TelCfgAKeyVerifyResult_t result;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_VERIFY_A_KEY_CNF");
-                                       memcpy(&result, event->pData, sizeof(TelCfgAKeyVerifyResult_t));
-                                       switch(result)
-                                       {
-                                               case TAPI_CFG_AKEY_VERIFY_FAIL:
-                                               {
-                                                       TEST_DEBUG("A-Key verify fail");
-                                               }
-                                                       break;
-
-                                               case TAPI_CFG_AKEY_VERIFY_OK:
-                                               {
-                                                       TEST_DEBUG("A-Key verify success");
-                                               }
-                                                       break;
-                                               default :
-                                                       TEST_DEBUG(" Unknown value : [%d] ", result);
-                                                       break;
-                                       }
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_MSL_INFO_CNF:
-                               {
-                                       TelCfgMSLInfo_t msl_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_MSL_INFO_CNF");
-                                       memcpy(&msl_info, event->pData, sizeof(TelCfgMSLInfo_t));
-                                       TEST_DEBUG("msl code:[%s]", msl_info.MslCode);
-                                       TEST_DEBUG("Otksl code:[%s]", msl_info.OtkslCode);
-                                       TEST_DEBUG("Otksl flag:[%d]", msl_info.bOtksl_flag);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_VOCODER_OPTION_CNF:
-                               {
-                                       TelCfgVocOption_t voc_option;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_VOCODER_OPTION_CNF");
-                                       memcpy(&voc_option, event->pData, sizeof(TelCfgVocOption_t));
-                                       TEST_DEBUG("vocoder option:[%d]", voc_option);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_VOCODER_OPTION_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_VOCODER_OPTION_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_HIDDEN_MENU_ACCESS_CNF:
-                               {
-                                       TelCfgHiddenMenuAccessType_t type;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_HIDDEN_MENU_ACCESS_CNF");
-                                       memcpy(&type, event->pData, sizeof(TelCfgHiddenMenuAccessType_t));
-                                       TEST_DEBUG("access type:[%d]", type);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_HIDDEN_MENU_ACCESS_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_HIDDEN_MENU_ACCESS_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_CURRENT_CARRIER_CNF:
-                               {
-                                       TelCfgCurrentCarrier_t carrier;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_CURRENT_CARRIER_CNF");
-                                       memcpy(&carrier, event->pData, sizeof(TelCfgCurrentCarrier_t));
-                                       TEST_DEBUG("carrier:[%d]", carrier);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_CURRENT_CARRIER_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_CURRENT_CARRIER_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_ACTIVATION_DATE_CNF:
-                               {
-                                       TelCfgActivationDateInfo_t date_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_ACTIVATION_DATE_CNF");
-                                       memcpy(&date_info, event->pData, sizeof(TelCfgActivationDateInfo_t));
-                                       TEST_DEBUG("year:[%d]", date_info.year);
-                                       TEST_DEBUG("month:[%d]", date_info.month);
-                                       TEST_DEBUG("day:[%d]", date_info.day);
-                                       TEST_DEBUG("hour:[%d]", date_info.hour);
-                                       TEST_DEBUG("minute:[%d]", date_info.minute);
-                                       TEST_DEBUG("second:[%d]", date_info.second);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_RECONDITIONED_DATE_CNF:
-                               {
-                                       TelCfgReconditionedInfo_t date_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_RECONDITIONED_DATE_CNF");
-                                       memcpy(&date_info, event->pData, sizeof(TelCfgReconditionedInfo_t));
-                                       TEST_DEBUG("status(0:NO, 1:YES):[%d]", date_info.status);
-                                       TEST_DEBUG("year:[%d]", date_info.year);
-                                       TEST_DEBUG("month:[%d]", date_info.month);
-                                       TEST_DEBUG("day:[%d]", date_info.day);
-                                       TEST_DEBUG("hour:[%d]", date_info.hour);
-                                       TEST_DEBUG("minute:[%d]", date_info.minute);
-                                       TEST_DEBUG("second:[%d]", date_info.second);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_SIO_MODE_CNF:
-                               {
-                                       TelCfgSIOMode_t mode;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_SIO_MODE_CNF");
-                                       memcpy(&mode, event->pData, sizeof(TelCfgSIOMode_t));
-                                       _PrintSIOMode(mode);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_SIO_MODE_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_SIO_MODE_CNF");
-                               }
-                                       break;
-                               case TAPI_CFG_EVENT_DEFAULTCFG_IND:
-                               {
-                                       TEST_DEBUG("TAPI_CFG_EVENT_DEFAULTCFG_IND");
-                               }
-                                       break;
-                               default :
-                                       TEST_DEBUG(" Unknown Event : [%d] ", event->EventType);
-                                       break;
-                       }
-                       break;
-               }
-
-               default:
-                       break;
-
-       }
-
-       TEST_DEBUG("###############    event processing is done....###############");
-       return 0;
-}
-
-
-int cfg_read_key_input(void)
-{
-       int ret;
-       char buf[512] = {0, };
-       char msg[512];
-       char  diallingNum[256];
-       int     diallingNum_len=0;
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-       memset(buf,0, sizeof(buf));
-       memset(diallingNum,0,sizeof(diallingNum));
-       memset(msg,0,sizeof(msg));
-       diallingNum_len=0;
-
-
-       TEST_DEBUG("*************** CFG TEST MENU     ***************");
-       TEST_DEBUG("1g.TelTapiCfgGetAKey");
-       TEST_DEBUG("1s.TelTapiCfgVerifyAKey");
-       TEST_DEBUG("2g.TelTapiCfgGetMSLInfo");
-       TEST_DEBUG("3g.TelTapiCfgGetVocoderOption");
-       TEST_DEBUG("3s.TelTapiCfgSetVocoderOption               <(default/evrc/13k/8k)>");
-       TEST_DEBUG("4g.TelTapiCfgGetHiddenMenuAccess");
-       TEST_DEBUG("4s.TelTapiCfgSetHiddenMenuAccess    <(disable/enable)>");
-       TEST_DEBUG("5g.TelTapiCfgGetCurrentCarrier");
-       TEST_DEBUG("5s.TelTapiCfgSetCurrentCarrier      <(test/skt/ktf/lgt/verizon/sprint)>");
-       TEST_DEBUG("6g.TelTapiCfgGetActivationDate");
-       TEST_DEBUG("7g.TelTapiCfgGetReconditionedDate");
-       TEST_DEBUG("8g.TelTapiCfgGetSIOMode");
-       TEST_DEBUG("8s.TelTapiCfgSetSIOMode     <mode(0/1/2)>");
-       TEST_DEBUG("9s.tapi_cfg_defaultconfiguration_set        FULL[0]FACTORY[1]SERVICE[2]CUSTOM[3]");
-       TEST_DEBUG("0.exit");
-       TEST_DEBUG("*****************************************************\n");
-
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       if( memcmp(buf,"0",sizeof("0")-1) == 0 )
-       {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu");
-               return -1;
-       }
-       else if( memcmp(buf,"1g",sizeof("1g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_akey....");
-               ret_val = tel_get_cfg_akey();
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"1s",sizeof("1s")-1) == 0 )
-       {
-               char    tempAkey[TAPI_CFG_A_KEY_DIGITS_MAX+1];
-               int             length = 0;
-               TelCfgAKeyInfo_t Akey_info;
-
-               strncpy(tempAkey, &buf[3], TAPI_CFG_A_KEY_DIGITS_MAX);
-
-               length = strlen(tempAkey);
-
-               memset(&Akey_info, 0, sizeof(Akey_info));
-
-               strncpy(Akey_info.A_key,tempAkey, length-1);  // removing '/n' form the end of the string
-
-               TEST_DEBUG("tel_verify_cfg_akey with AKey [%s]",Akey_info.A_key);
-
-               ret_val = tel_verify_cfg_akey(&Akey_info);
-
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"2g",sizeof("2g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_msl_info....");
-               ret_val = tel_get_cfg_msl_info();
-               TEST_DEBUG(" Tapi return value: [0x%x] ", ret_val);
-       }
-       else if( memcmp(buf,"3g",sizeof("3g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_vocoder_option....");
-               ret_val = tel_get_cfg_vocoder_option();
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"3s",sizeof("3s")-1) == 0 )
-       {
-               TelCfgVocOption_t voc_opt = 0;
-               if(memcmp(buf+3,"default",sizeof("default")-1) == 0 )
-                       voc_opt =TAPI_CFG_VOC_OPTION_DEFAULT;
-               else if(memcmp(buf+3,"evrc",sizeof("evrc")-1) == 0 )
-                       voc_opt =TAPI_CFG_VOC_OPTION_EVRC;
-               else if(memcmp(buf+3,"13k",sizeof("13k")-1) == 0 )
-                       voc_opt =TAPI_CFG_VOC_OPTION_13K;
-               else if(memcmp(buf+3,"8k",sizeof("8k")-1) == 0 )
-                       voc_opt =TAPI_CFG_VOC_OPTION_8K;
-               else{
-                       TEST_DEBUG("Unknown vocoder option");
-                       return 0;
-               }
-
-               TEST_DEBUG("tel_set_cfg_vocoder_option....voc_opt:[%d]",voc_opt);
-               ret_val = tel_set_cfg_vocoder_option(voc_opt);
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"4g",sizeof("4g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_hidden_menu_access....");
-               ret_val = tel_get_cfg_hidden_menu_access();
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"4s",sizeof("4s")-1) == 0 )
-       {
-               TelCfgHiddenMenuAccessType_t type = 0;
-               if(memcmp(buf+3,"disable",sizeof("disable")-1) == 0 )
-                       type =TAPI_CFG_HIDDEN_MENU_DISABLE;
-               else if(memcmp(buf+3,"enable",sizeof("enable")-1) == 0 )
-                       type =TAPI_CFG_HIDDEN_MENU_ENABLE;
-               else{
-                       TEST_DEBUG("Unknown type");
-                       return 0;
-               }
-
-               TEST_DEBUG("tel_set_cfg_hidden_menu_access....type:[%d]",type);
-               ret_val = tel_set_cfg_hidden_menu_access(type);
-               TEST_DEBUG(" Tapi return value: [0x%x] ", ret_val);
-       }
-       else if( memcmp(buf,"5g",sizeof("5g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_serving_carrier....");
-               ret_val = tel_get_cfg_serving_carrier();
-               TEST_DEBUG(" Tapi return value: [0x%x] ", ret_val);
-       }
-       else if( memcmp(buf,"5s",sizeof("5s")-1) == 0 )
-       {
-               TelCfgCurrentCarrier_t Carrier = 0;
-               TEST_DEBUG("buf :[%s]....",buf+3);
-               if(memcmp(buf+3,"test",sizeof("test")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_TEST;
-               else if(memcmp(buf+3,"skt",sizeof("skt")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_SKT;
-               else if(memcmp(buf+3,"ktf",sizeof("ktf")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_KTF;
-               else if(memcmp(buf+3,"lgt",sizeof("lgt")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_LGT;
-               else if(memcmp(buf+3,"verizon",sizeof("verizon")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_VERIZON;
-               else if(memcmp(buf+3,"sprint",sizeof("sprint")-1) == 0 )
-                       Carrier =TAPI_CFG_CARRIER_SPRINT;
-               else{
-                       TEST_DEBUG("Unknown Carrier....");
-                       return 0;
-               }
-
-               TEST_DEBUG("tel_set_cfg_serving_carrier....Carrier:[%d]",Carrier);
-               ret_val = tel_set_cfg_serving_carrier(Carrier);
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"6g",sizeof("6g")-1) == 0 )
-       {
-               TEST_DEBUG("TelTapiCfgGetActivationDate....");
-               ret_val = tel_get_cfg_activated_date_of_phone();
-               TEST_DEBUG(" Tapi return value: [0x%x]  ", ret_val);
-       }
-       else if( memcmp(buf,"7g",sizeof("7g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_reconditioned_data_of_phone....");
-               ret_val = tel_get_cfg_reconditioned_data_of_phone();
-               TEST_DEBUG(" Tapi return value: [0x%x]   ", ret_val);
-       }
-       else if( memcmp(buf,"8g",sizeof("8g")-1) == 0 )
-       {
-               TEST_DEBUG("tel_get_cfg_sio_mode....");
-               ret_val = tel_get_cfg_sio_mode();
-               TEST_DEBUG(" Tapi return value: [0x%x] ", ret_val);
-       }
-       else if( memcmp(buf,"8s",sizeof("8s")-1) == 0 )
-       {
-               TelCfgSIOMode_t mode = 0;
-               if(memcmp(buf+3,"0",sizeof("0")-1) == 0 )
-                       mode =TAPI_CFG_SIO_U1_DIAG_USB2_GPS;
-               else if(memcmp(buf+3,"1",sizeof("1")-1) == 0 )
-                       mode =TAPI_CFG_SIO_U1_HFK_USB2_GPS;
-               else if(memcmp(buf+3,"2",sizeof("2")-1) == 0 )
-                       mode =TAPI_CFG_SIO_U1_HFK_USB2_DIAG;
-               else{
-                       TEST_DEBUG("Unknown mode");
-                       return 0;
-               }
-               TEST_DEBUG("tel_set_cfg_sio_mode....mode:[%d]",mode);
-               ret_val = tel_set_cfg_sio_mode(mode);
-               TEST_DEBUG(" Tapi return value: [0x%x] ", ret_val);
-       }
-
-       else if( memcmp(buf,"9s",sizeof("9s")-1) == 0 )
-       {
-               TelDefaultCfg_t bType =0;
-
-               if(memcmp(buf+3,"0",sizeof("0")-1) == 0 )
-                       bType = TAPI_CFG_DEFAULT_FULL;
-               else if(memcmp(buf+3,"1",sizeof("1")-1) == 0 )
-                       bType = TAPI_CFG_DEFAULT_FACTORY;
-               else if(memcmp(buf+3,"2",sizeof("2")-1) == 0 )
-                       bType = TAPI_CFG_DEFAULT_SERVICE;
-               else if(memcmp(buf+3,"3",sizeof("3")-1) == 0 )
-                       bType = TAPI_CFG_DEFAULT_CUSTOM;
-
-               tel_set_cfg_default_configuration(bType);
-       }
-
-       return 0;
-}
-
-
-void cfg_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-               {
-                       if (FD_ISSET(0, &readfds))
-                       {
-                               if(cfg_read_key_input()<0)
-                                       break;
-                       }
-               }
-       }
-}
-
-#if 0
-static int  tapi_cfg_callback  (TelTapiEventClass_t    eventClass,int  eventType, int  param1,void * param2)
-{
-       TEST_DEBUG("EVENT STATUS:[%d]", param1);
-
-       switch(eventClass)
-       {
-               case TAPI_EVENT_CLASS_CFG:
-               {
-                       switch(eventType)
-                       {
-                               case TAPI_EVENT_CFG_GET_A_KEY_CNF:
-                               {
-                                       TelCfgAKeyInfo_t Akey_info;
-                                       memset(&Akey_info, 0, sizeof(Akey_info));
-
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_A_KEY_CNF");
-
-                                       memcpy(&Akey_info, param2, sizeof(TelCfgAKeyInfo_t));
-
-                                       TEST_DEBUG("Akey:[%s]",Akey_info.A_key);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_VERIFY_A_KEY_CNF:
-                               {
-                                       TelCfgAKeyVerifyResult_t result;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_VERIFY_A_KEY_CNF");
-                                       memcpy(&result, param2, sizeof(TelCfgAKeyVerifyResult_t));
-                                       switch(result)
-                                       {
-                                               case TAPI_CFG_AKEY_VERIFY_FAIL:
-                                               {
-                                                       TEST_DEBUG("A-Key verify fail");
-                                               }
-                                                       break;
-
-                                               case TAPI_CFG_AKEY_VERIFY_OK:
-                                               {
-                                                       TEST_DEBUG("A-Key verify success");
-                                               }
-                                                       break;
-                                               default :
-                                                       TEST_DEBUG(" Unknown value : [%d] ", result);
-                                                       break;
-                                       }
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_MSL_INFO_CNF:
-                               {
-                                       TelCfgMSLInfo_t msl_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_MSL_INFO_CNF");
-                                       memcpy(&msl_info, param2, sizeof(TelCfgMSLInfo_t));
-                                       TEST_DEBUG("msl code:[%s]", msl_info.MslCode);
-                                       TEST_DEBUG("Otksl code:[%s]", msl_info.OtkslCode);
-                                       TEST_DEBUG("Otksl flag:[%d]", msl_info.Otksl_flag);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_VOCODER_OPTION_CNF:
-                               {
-                                       TelCfgVocOption_t voc_option;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_VOCODER_OPTION_CNF");
-                                       memcpy(&voc_option, param2, sizeof(TelCfgVocOption_t));
-                                       TEST_DEBUG("vocoder option:[%d]", voc_option);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_VOCODER_OPTION_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_VOCODER_OPTION_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_HIDDEN_MENU_ACCESS_CNF:
-                               {
-                                       TelCfgHiddenMenuAccessType_t type;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_HIDDEN_MENU_ACCESS_CNF");
-                                       memcpy(&type, param2, sizeof(TelCfgHiddenMenuAccessType_t));
-                                       TEST_DEBUG("access type:[%d]", type);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_HIDDEN_MENU_ACCESS_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_HIDDEN_MENU_ACCESS_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_CURRENT_CARRIER_CNF:
-                               {
-                                       TelCfgCurrentCarrier_t carrier;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_CURRENT_CARRIER_CNF");
-                                       memcpy(&carrier, param2, sizeof(TelCfgCurrentCarrier_t));
-                                       TEST_DEBUG("carrier:[%d]", carrier);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_CURRENT_CARRIER_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_CURRENT_CARRIER_CNF");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_ACTIVATION_DATE_CNF:
-                               {
-                                       TelCfgActivationDateInfo_t date_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_ACTIVATION_DATE_CNF");
-                                       memcpy(&date_info, param2, sizeof(TelCfgActivationDateInfo_t));
-                                       TEST_DEBUG("year:[%d]", date_info.year);
-                                       TEST_DEBUG("month:[%d]", date_info.month);
-                                       TEST_DEBUG("day:[%d]", date_info.day);
-                                       TEST_DEBUG("hour:[%d]", date_info.hour);
-                                       TEST_DEBUG("minute:[%d]", date_info.minute);
-                                       TEST_DEBUG("second:[%d]", date_info.second);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_RECONDITIONED_DATE_CNF:
-                               {
-                                       TelCfgReconditionedInfo_t date_info;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_RECONDITIONED_DATE_CNF");
-                                       memcpy(&date_info, param2, sizeof(TelCfgReconditionedInfo_t));
-                                       TEST_DEBUG("status(0:NO, 1:YES):[%d]", date_info.status);
-                                       TEST_DEBUG("year:[%d]", date_info.year);
-                                       TEST_DEBUG("month:[%d]", date_info.month);
-                                       TEST_DEBUG("day:[%d]", date_info.day);
-                                       TEST_DEBUG("hour:[%d]", date_info.hour);
-                                       TEST_DEBUG("minute:[%d]", date_info.minute);
-                                       TEST_DEBUG("second:[%d]", date_info.second);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_GET_SIO_MODE_CNF:
-                               {
-                                       TelCfgSIOMode_t mode;
-                                       TEST_DEBUG("TAPI_EVENT_CFG_GET_SIO_MODE_CNF");
-                                       memcpy(&mode, param2, sizeof(TelCfgSIOMode_t));
-                                       _PrintSIOMode(mode);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_CFG_SET_SIO_MODE_CNF:
-                               {
-                                       TEST_DEBUG("TAPI_EVENT_CFG_SET_SIO_MODE_CNF");
-                               }
-                                       break;
-
-                               default :
-                                       TEST_DEBUG(" Unknown Event : [%d] ", eventType);
-                                       break;
-                       }
-                       break;
-               }
-
-               default:
-                       break;
-
-       }
-
-       TEST_DEBUG("###############    event processing is done....###############");
-       return 0;
-}
-
-bool on_cfg_event_received (EvtSysEventSourceId_t src_id, const char* noti_id, GArray* parameters, void* local_data)
-{
-       EvtSysEventProperty_t* e;
-       int len;
-       int group;
-       int type;
-       int reqid;
-       int status;
-
-       assert(parameters->len == 5);
-
-       /*      1 param is      tapi event group   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 0);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       group = e->value.i;
-       //TEST_DEBUG("received group is :%d ", group);
-
-       /*      2 param is      tapi event type   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 1);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       type = e->value.i;
-       //TEST_DEBUG("received event type is :%d ", type);
-
-       /*      3 param is      Response ID   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 2);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       reqid = e->value.i;
-       //TEST_DEBUG("received Request ID is :%d ", reqid);
-
-       /*      4 param is      Status   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 3);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       status = e->value.i;
-       //TEST_DEBUG("status is :%d ", status);
-
-
-       if (status != 0x00)
-       {
-               TEST_DEBUG(" ##### Received Error## status:[%d] for event type[0x%x]", status, type);
-               return true;
-       }
-
-       /*      over allocate this after receiving the len  */
-       char *data;
-       guchar *result;
-       size_t  out_len;
-
-       /*      5 param is      data   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 4);
-       assert(e->type == DBUS_TYPE_STRING);
-
-       data = (char *)e->value.i;
-
-       len = strlen(data);
-
-       TAPI_BASE64_DECODE(data, result, &out_len);
-
-       tapi_cfg_callback(group, type, status, result);
-
-       /* We've done with this notificaiton */
-       return true;
-
-}
-#endif
-
-//int misc_test_subscribe_tapi_events(void)
-int cfg_test_subscribe_tapi_events(void)
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfCfgEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int cfgEvents[] =
-       {
-               TAPI_CFG_EVENT_DEFAULTCFG_IND,
-               TAPI_EVENT_CFG_GET_A_KEY_CNF,                                        /**<     */
-               TAPI_EVENT_CFG_VERIFY_A_KEY_CNF,                                     /**<     */
-               TAPI_EVENT_CFG_GET_MSL_INFO_CNF,                                     /**<     */
-               TAPI_EVENT_CFG_GET_VOCODER_OPTION_CNF,                        /**<     */
-               TAPI_EVENT_CFG_SET_VOCODER_OPTION_CNF,                        /**<     */
-               TAPI_EVENT_CFG_GET_HIDDEN_MENU_ACCESS_CNF,            /**<     */
-               TAPI_EVENT_CFG_SET_HIDDEN_MENU_ACCESS_CNF,            /**<     */
-               TAPI_EVENT_CFG_GET_CURRENT_CARRIER_CNF,                       /**<     */
-               TAPI_EVENT_CFG_SET_CURRENT_CARRIER_CNF,                       /**<     */
-               TAPI_EVENT_CFG_GET_SIO_MODE_CNF,                              /**<     */
-               TAPI_EVENT_CFG_SET_SIO_MODE_CNF,                              /**<     */
-               TAPI_EVENT_CFG_GET_ACTIVATION_DATE_CNF,                       /**<     */
-               TAPI_EVENT_CFG_GET_RECONDITIONED_DATE_CNF,                            /**<     */
-               TAPI_EVENT_CFG_SET_TTY_MODE_CNF,                              /**<     */
-               TAPI_EVENT_CFG_GET_TTY_MODE_CNF,                              /**<     */
-       };
-
-       iNumOfCfgEvt = sizeof(cfgEvents)/sizeof(int);
-//     TAPI_CALLOC(Cfg_subscription_id, iNumOfCfgEvt, unsigned int)
-//#define TAPI_CALLOC(ptr, no_elements, type)
-       Cfg_subscription_id = (unsigned int *) calloc (iNumOfCfgEvt , sizeof (unsigned int));
-       if(Cfg_subscription_id == NULL)
-       {
-               TEST_DEBUG("calloc error -NULL, errno is [%d]", errno);
-       }
-
-
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               for( i=0 ; i< iNumOfCfgEvt; i++ )
-               {
-                       api_err = tel_register_event(cfgEvents[i], &Cfg_subscription_id[i],(TelAppCallback)&tapi_cfg_callback,NULL);
-                       if(api_err != TAPI_API_SUCCESS)
-                       {
-                               TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", cfgEvents[i],api_err);
-                               ret_val = FALSE;
-                               break;
-                       }
-               }
-       }
-       else
-       {
-               TEST_DEBUG("tel_init() failed");
-       }
-       return ret_val;
-
-#if 0
-       //GMainLoop *mainloop;
-       edata_t sdata;
-       noti_subscription_id_t subscription_id;
-       int count;
-
-       char *cfgEvents[] = {
-                                                                       "Telephony.User.Cfg.BtWifiTestInd",
-                                                                       "Telephony.User.Cfg.PdaCalibration",
-                                                                       "Telephony.Cfg.GetAKeyCnf",
-                                                                       "Telephony.Cfg.VerifyAKeyCnf",
-                                                                       "Telephony.Cfg.GetMslInfoCnf",
-                                                                       "Telephony.Cfg.GetVocoderOptionCnf",
-                                                                       "Telephony.Cfg.SetVocoderOptionCnf",
-                                                                       "Telephony.Cfg.GetHiddenMenuAccessCnf",
-                                                                       "Telephony.Cfg.SetHiddenMenuAccessCnf",
-                                                                       "Telephony.Cfg.GetCurrentCarrierCnf",
-                                                                       "Telephony.Cfg.SetCurrentCarrierCnf",
-                                                                       "Telephony.Cfg.GetSioModeCnf",
-                                                                       "Telephony.Cfg.SetSioModeCnf",
-                                                                       "Telephony.Cfg.GetUsbPathCnf",
-                                                                       "Telephony.Cfg.SetUsbPathCnf",
-                                                                       "Telephony.Cfg.GetActivationDateCnf",
-                                                                       "Telephony.Cfg.GetReconditionedDateCnf",
-                                                               };
-
-       for(count =0;count  <  (sizeof(cfgEvents)/sizeof(*cfgEvents)) ; count++)
-       {
-               error_code = EvtSysEventSubscribe (
-                                                                                       EvtDeliveryHandle,
-                                                                                       cfgEvents[count],                               /* notification ID */
-                                                                                       NULL,                                           /*      filter expression       */
-                                                                                       (EvtSysEventCb)on_cfg_event_received,           /* notification handler */
-                                                                                       (void *)&sdata,                         /* local data */
-                                                                                       &subscription_id                        /* subscription ID */
-                                                                               );
-               if (error_code )
-               {
-                       TEST_DEBUG( "[NET TEST] EvtSysEventSubscribe(): error [%#X] for event [%s]", error_code , cfgEvents[count]);
-               }
-       }
-
-       return 0;
-#endif
-}
-
-#if 0
-void tapi_cfg_thread()
-{
-       TEST_DEBUG("start tapi_cfg_thread");
-       cfg_select_loop();
-       fprintf (stderr, " cfg exited");
-       pthread_exit(NULL);
-}
-
-
-int cfg_main(int argc, char *argv[])
-{
-       int ret=0;
-       pthread_t cfg_thread_id;
-
-       TEST_DEBUG("\n\n\n ===== config module test  ver 1.01 =====");
-
-       ret = pthread_create(&cfg_thread_id, NULL, &tapi_cfg_thread, NULL);
-
-       if(ret != 0)
-       {
-               TEST_DEBUG( "Thread for TAPI Events Failed");
-       }
-
-       pthread_join(cfg_thread_id, NULL);
-}
-#endif
diff --git a/src/test_apps/tapi_gps_test.c b/src/test_apps/tapi_gps_test.c
deleted file mode 100644 (file)
index c242d6c..0000000
+++ /dev/null
@@ -1,387 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <assert.h>
-#include <glib.h>
-#include <unistd.h>
-#include <string.h>
-
-#include "TapiCommon.h"
-#include "ITapiGps.h"
-#include "TelErr.h"
-#include "TelUtility.h"
-#include "TapiEvent.h"
-
-static unsigned int GPS_subscription_id;
-
-#define TEST_DEBUG(frmt, args...) \
-{do { fprintf(stderr, "[GPS Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-
-void gps_async_event_callback(TelTapiEvent_t* pGpsEvent)
-{
-       if(pGpsEvent->pData == NULL)
-       {
-               TEST_DEBUG("No Event Data!!");
-               return;
-       }
-
-       TEST_DEBUG("*************** Callback data **********************");
-       TEST_DEBUG("EventClass [%d],EventType [0x%x], Reques Id[%d], Event status [%d], psEvent->pDataLen[%d]",
-               pGpsEvent->EventClass, pGpsEvent->EventType, pGpsEvent->RequestId, pGpsEvent->Status,pGpsEvent->pDataLen);
-
-       // TAPI_EVENT_NONE:
-       switch(pGpsEvent->EventType)
-       {
-               case TAPI_EVENT_GPS_INIT_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_INIT_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_DEINIT_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_DEINIT_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_FIX_REQUEST_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_FIX_REQUEST_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_STOP_SESSION_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_STOP_SESSION_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_PARAMETERS_SET_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_PARAMETERS_SET_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_INIT:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_INIT $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_DEINIT:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_DEINIT $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_ENABLE_SET_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_ENABLE_SET_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_SET_TIME_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_SET_TIME_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_SET_DATA_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_SET_DATA_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_POSITION_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_POSITION_NOTI $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_EXT_POSITION_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_EXT_POSITION_NOTI $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_PARAMETERS_GET_RESP:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_PARAMETERS_GET_RESP $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_PD_CMD_CB_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_PD_CMD_CB_NOTI $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_PDP_CONNECTION_IND:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_PDP_CONNECTION_IND $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_DNS_LOOKUP_IND:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_DNS_LOOKUP_IND $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_VERIFICATION_IND:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_VERIFICATION_IND $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_SUPL_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_SUPL_NOTI $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_TIME_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_TIME_NOTI $$$$$$ ");
-                       }
-                       break;
-               case TAPI_EVENT_GPS_XTRA_DATA_NOTI:
-                       {
-                               TEST_DEBUG("$$$$$$ TAPI_EVENT_GPS_XTRA_DATA_NOTI $$$$$$ ");
-                       }
-                       break;
-
-               default:
-                       TEST_DEBUG("Unhandled pGpsEvent->EventType[0x%x]",pGpsEvent->EventType);
-                       break;
-       }
-       return;
-}
-
-
-int gps_read_key_input()
-{
-       int ret;
-       char buf[512] = {0, };
-       char msg[512];
-       char  diallingNum[256];
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-       memset(buf,0, sizeof(buf));
-       memset(diallingNum,0,sizeof(diallingNum));
-       memset(msg,0,sizeof(msg));
-
-       fprintf(stderr,"*************** GPS TEST MENU     ***************\n");
-       fprintf(stderr,"\n  1. INIT GPS\n");
-       fprintf(stderr,"\n  2. DEINIT GPS\n");
-       fprintf(stderr,"\n  3. SEND PARAMETERS\n");
-       fprintf(stderr,"\n  4. SEND FIX REQUEST\n");
-       fprintf(stderr,"\n  5. STOP SESSION\n");
-       fprintf(stderr,"\n  6. GET PARAMETERS\n");
-       fprintf(stderr,"\n  7. XTRA INIT\n");
-       fprintf(stderr,"\n  8. XTRA DEINIT\n");
-       fprintf(stderr,"\n  9. XTRA ENABLE\n");
-       fprintf(stderr,"\n  a. XTRA DISABLE\n");
-       fprintf(stderr,"\n  b. XTRA TIME INFO REQUEST\n");
-       fprintf(stderr,"\n  c. XTRA DATA INFO REQUEST\n");
-       fprintf(stderr,"\n  q. QUIT\n");
-       fprintf(stderr,"*****************************************************\n");
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       if(memcmp(buf, "1", 1) == 0)
-       {
-               ret_val = tel_init_gps();
-               TEST_DEBUG("GPS INIT API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "2", 1) == 0)
-       {
-               ret_val = tel_deinit_gps();
-               TEST_DEBUG("GPS DEINIT API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "3", 1) == 0)
-       {
-               tapi_gps_param_t  param = {0, };
-               int i = 0;
-
-               param.ParamType[i++] = TAPI_GPS_PRM_MSG_SERVER_TYPE;
-               param.ServerType = TAPI_GPS_SERVER_UMTS;
-
-
-               param.ParamType[i++] = TAPI_GPS_PRM_MSG_POSITION_MODE;
-               param.PositionMode = TAPI_GPS_POS_MODE_3G_CP_UE_BASED;
-
-               param.ParamType[i++] = TAPI_GPS_PRM_MSG_MT_LR;
-               param.SslOnOff = TAPI_GPS_MT_LR_DISABLE;
-
-               param.ParamType[i++] = TAPI_GPS_PRM_MSG_MO_METHOD;
-               param.SslOnOff = TAPI_GPS_MO_UP;
-
-               param.ParamType[i++] = TAPI_GPS_PRM_MSG_SSL_ON_OFF;
-               param.SslOnOff = TAPI_GPS_SSL_DISABLE;
-
-
-               param.NumOfRecord = i;
-
-               ret_val = tel_set_gps_parameters(&param);
-               TEST_DEBUG("SET PARAMETERS API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "4", 1) == 0)    // fix request
-       {
-               tapi_gps_fix_request_msg_t fix_req = {0,};
-               int i = 0;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_SESSION_TYPE;
-               fix_req.SessionType = TAPI_GPS_TRACKING_MODE;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_SESSION_OPERATION;
-               fix_req.SessionOperation = TAPI_GPS_STANDALONE_ONLY;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_NUM_FIXES;
-               fix_req.TotalFixes = 99999999;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_TIME_BTW_FIXES;
-               fix_req.TimeBtwFixes = 1;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_ACCURACY;
-               fix_req.Accuracy = 50;
-
-               fix_req.ParamType[i++] = TAPI_GPS_FIX_REQ_SESSION_TIMEOUT;
-               fix_req.GpsSessionTimeout = 2;
-               fix_req.NumOfRecord = i;
-
-               ret_val = tel_set_gps_prefix_info(&fix_req);
-               TEST_DEBUG("GPS FIX REQUEST RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "5", 1) == 0)
-       {
-               ret_val = tel_stop_gps_session();
-               TEST_DEBUG("GPS STOP SESSION RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "6", 1) == 0)
-       {
-               ret_val = tel_get_gps_parameters();
-               TEST_DEBUG("GPS GET PARAMS API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "7", 1) == 0)
-       {
-               ret_val = tel_init_gps_xtra();
-               TEST_DEBUG("GPS XTRA INIT API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "8", 1) == 0)
-       {
-               ret_val = tel_deinit_gps_xtra();
-               TEST_DEBUG("GPS XTRA DEINIT API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "9", 1) == 0)
-       {
-               ret_val = tel_enable_gps_xtra();
-               TEST_DEBUG("GPS XTRA ENABLE API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "a", 1) == 0)
-       {
-               ret_val = tel_disable_gps_xtra();
-               TEST_DEBUG("GPS XTRA DISABLE API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "b", 1) == 0)
-       {
-               tapi_gps_xtra_time_info_t time_info = {0,};
-
-               ret_val = tel_set_gps_xtra_time(&time_info);
-               TEST_DEBUG("GPS XTRA SET TIME API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "c", 1) == 0)
-       {
-               tapi_gps_xtra_data_info_t data_info = {0,};
-
-               ret_val = tel_set_gps_xtra_data(&data_info);
-               TEST_DEBUG("GPS XTRA SET DATA API RETURN VALUE : [%d]\n" , ret_val);
-       }
-       if(memcmp(buf, "q", 1) == 0)
-       {
-               return -1;
-       }
-       return 0;
-}
-
-void gps_select_loop()
-{
-       int ret;
-       fd_set readfds;
-
-       while(1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if(ret)
-               {
-                       if(FD_ISSET(0, &readfds))
-                       {
-                               if(gps_read_key_input()<0)
-                                       break;
-                       }
-               }
-       }
-}
-
-int gps_test_subscribe_tapi_events()
-{
-       int ret_val = TRUE;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       int GpsEvt = TAPI_EVENT_GPS_INIT_RESP;
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               api_err = tel_register_event(GpsEvt, &GPS_subscription_id,(TelAppCallback)&gps_async_event_callback, NULL);
-               if(api_err != TAPI_API_SUCCESS)
-               {
-                       TEST_DEBUG("isn't subscribed. sub id is [%d], api_err is [%d]\n", GPS_subscription_id,api_err);
-                       ret_val = FALSE;
-               }
-       }
-       else
-       {
-               TEST_DEBUG("tel_init() failed");
-       }
-       return ret_val;
-}
-
-void gps_thread_loop()
-{
-       TEST_DEBUG("start gps_thread_loop\n");
-       gps_select_loop();
-       fprintf (stderr, "gps exited\n");
-       pthread_exit(NULL);
-}
-
-void gps_main(int argc, char *argv[])
-{
-       int ret=0;
-       pthread_t gps_thread_id;
-
-       ret = pthread_create(&gps_thread_id, NULL, (void*)&gps_thread_loop, NULL);
-
-       if(ret != 0)
-       {
-               TEST_DEBUG("Thread for TAPI Events Failed\n");
-       }
-
-       pthread_join(gps_thread_id, NULL);
-}
-
-
diff --git a/src/test_apps/tapi_misc_test.c b/src/test_apps/tapi_misc_test.c
deleted file mode 100644 (file)
index ed68000..0000000
+++ /dev/null
@@ -1,535 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <assert.h>
-#include <glib.h>
-#include <string.h>
-#include <unistd.h>
-
-#include "ITapiMisc.h"
-#include "TapiCommon.h"
-#include "TelErr.h"
-#include "vconf.h"
-#include "TelUtility.h"
-#include "TapiEvent.h"
-
-typedef struct {
-       int group;
-       int type;
-       int len;
-       void *dst;
-} edata_t;
-
-#define TEST_DEBUG(frmt, args...) \
-{do { fprintf(stderr, "[MISC Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-int error_code;
-extern int EvtDeliveryHandle;
-
-TelMiscAlarmInfo_t alarm_info;
-static unsigned int * MISC_subscription_id;
-
-void __PrintNAMInfoMASK(char* str, TS_UINT16 nam_info_mask) {
-       switch (nam_info_mask) {
-       case TAPI_MISC_NAM_INFO_MASK_TOTAL:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_TOTAL [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_CURRENT_INDEX:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_CURRENT_INDEX [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_REQUEST_INDEX:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_REQUEST_INDEX [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_AUTONAM:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_AUTONAM [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_MCC:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_MCC [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_MNC:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_MNC [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_MIN:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_MIN [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_MDN:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_MDN [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_NAM_NAME:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_NAM_NAME [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_NAM_CHANGE:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_NAM_CHANGE [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_NAM_NUM:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_NAM_NUM [%d]", str, nam_info_mask)
-               ;
-               break;
-       case TAPI_MISC_NAM_INFO_MASK_ALL:
-               TEST_DEBUG("%s TAPI_MISC_NAM_INFO_MASK_ALL [%d]", str, nam_info_mask)
-               ;
-               break;
-       default:
-               TEST_DEBUG("%s Undefined MASK [0x%x]", str, nam_info_mask)
-               ;
-               break;
-       }
-}
-
-//static int  misc_async_event_callback (TelTapiEventClass_t   eventClass,int  eventType, void * param2)
-static void misc_async_event_callback(TelTapiEvent_t *event) {
-       TEST_DEBUG("EVENT TYPE:[0x%x], STATUS:[0x%x]", event->EventType, event->Status);
-
-       switch (event->EventClass) {
-       case TAPI_EVENT_CLASS_MISC: {
-               switch (event->EventType) {
-               case TAPI_EVENT_MISC_NITZ_GETCNF: {
-                       tapi_misc_time_zone_info_type zone_info;
-                       memcpy(&zone_info, (tapi_misc_time_zone_info_type*) event->pData,
-                                       sizeof(tapi_misc_time_zone_info_type));
-
-                       TEST_DEBUG("$$$$$$ TAPI_EVENT_MISC_NITZ_GETCNF $$$$$$ ");
-
-                       TEST_DEBUG("time info valid : [%d](0:invalid, 1:nw, 2:RTC, 3:RTC BACKUP) ",zone_info.time_zone_valid);
-                       TEST_DEBUG("Daylight_valid : [%d] ",zone_info.bDaylight_valid);
-                       TEST_DEBUG("Year : [%d] ",zone_info.year);
-                       TEST_DEBUG("Month : [%d] ",zone_info.month);
-                       TEST_DEBUG("Day : [%d] ",zone_info.day);
-                       TEST_DEBUG("Hour : [%d] ",zone_info.hour);
-                       TEST_DEBUG("Minute : [%d] ",zone_info.minute);
-                       TEST_DEBUG("Second : [%d] ",zone_info.second);
-                       TEST_DEBUG("Time_zone :[%d] ",zone_info.time_zone);
-                       TEST_DEBUG("Daylight_adjust : [%d] ",zone_info.daylight_adjust);
-                       TEST_DEBUG("Day_of_week :[%d] ",zone_info.day_of_week);
-
-                       alarm_info.year = zone_info.year;
-                       alarm_info.month = zone_info.month;
-                       alarm_info.day = zone_info.day;
-                       alarm_info.hour = zone_info.hour;
-                       alarm_info.minute = zone_info.minute;
-                       alarm_info.second = zone_info.second;
-                       alarm_info.time_zone = zone_info.time_zone;
-                       alarm_info.day_of_week = zone_info.day_of_week;
-
-                       break;
-               }
-               case TAPI_EVENT_MISC_SERIAL_NUMBER_IND: {
-                       TelMiscSNInformation SN = { 0, };
-
-                       int index;
-
-                       memcpy(&SN, (char*) event->pData, sizeof(TelMiscSNInformation));
-                       TEST_DEBUG("$$$$$$ TAPI_EVENT_MISC_SERIAL_NUMBER_IND $$$$$$ ");
-                       TEST_DEBUG("Number Len :[%d] ", SN.sn_len);
-                       switch (SN.sn_index) {
-                       case TAPI_MISC_ME_ESN:
-                               TEST_DEBUG("SN Index: ME ESN");
-                               for (index = 0; index < 4; index++) {
-                                       TEST_DEBUG("Number :[0x%x]", SN.szNumber[index]);
-                               }
-                               break;
-                       case TAPI_MISC_ME_MEID:
-                               TEST_DEBUG("SN Index: ME MEID");
-                               for (index = 0; index < 8; index++) {
-                                       TEST_DEBUG("Number :[0x%x]", SN.szNumber[index]);
-                               }
-                               break;
-                       default:
-                               break;
-                       }
-                       break;
-               }
-
-               case TAPI_EVENT_MISC_NAM_INFO_NOTI:
-               case TAPI_EVENT_MISC_GET_NAM_INFO_CNF: {
-                       TelMiscNamInfo_t NAM = { 0, };
-
-                       memcpy(&NAM, (char*) event->pData, sizeof(TelMiscNamInfo_t));
-                       TEST_DEBUG("$$$$$$ TAPI_EVENT_MISC_GET_NAM_INFO_CNF or NAM_INFO_NOTI $$$$$$ ");
-                       __PrintNAMInfoMASK("Nam Info Mask: ", NAM.nam_info_mask);
-                       TEST_DEBUG("Num of Total Nam : %d ", NAM.nam_total);
-                       TEST_DEBUG("Index of Current Selected NAM : %d ", NAM.nam_current_index);
-                       TEST_DEBUG("Index of Request Nam : %d ", NAM.nam_req_index);
-                       TEST_DEBUG("NAM Auto(0:disable / 1:enable) : %d ", NAM.nam_auto);
-                       TEST_DEBUG("NAM MCC : [%s] ", NAM.nam_mcc);
-                       TEST_DEBUG("NAM MNC : [%s] ", NAM.nam_mnc);
-                       TEST_DEBUG("NAM MIN : [%s] ", NAM.nam_min);
-                       TEST_DEBUG("NAM MDN : [%s] ", NAM.nam_mdn);
-                       TEST_DEBUG("NAM NAME : [%s] ", NAM.nam_name);
-
-                       break;
-               }
-
-               default:
-                       TEST_DEBUG(" MISC TEST -----TAPI_MISC EVENT TYPE DEFAULT CASE : [%d] ", event->EventType)
-                       ;
-                       break;
-               }
-               break;
-       }
-
-       default:
-               break;
-
-       }
-
-       TEST_DEBUG(" ########## End of MISC EVENT  ##################");
-
-       return;
-}
-
-int misc_read_key_input(int option) {
-       int ret;
-       char buf[512] = { 0, };
-       char msg[512];
-       char diallingNum[256];
-       int diallingNum_len = 0;
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-       memset(buf, 0, sizeof(buf));
-       memset(diallingNum, 0, sizeof(diallingNum));
-       memset(msg, 0, sizeof(msg));
-       diallingNum_len = 0;
-
-       if (option == 10) {
-               TEST_DEBUG("*************** MISC TEST MENU     ***************");
-               TEST_DEBUG("1g.tel_get_misc_timezone_info       (UMTS/CDMA)");
-               TEST_DEBUG("1s.tapi_misc_timezone_setinfo       (UMTS/CDMA)");
-               TEST_DEBUG("4.tel_get_misc_alarm_info   (IPCv3.0)");
-               TEST_DEBUG("5.ME serial number          (UMTS/CDMA)");
-               TEST_DEBUG("6.ME version info   (UMTS/CDMA)");
-               TEST_DEBUG("7.ts_get_misc_nam_info      (CDMA)");
-               TEST_DEBUG("8.emergency mode control (UMTS/CDMA)");
-               TEST_DEBUG("0.exit");
-               TEST_DEBUG("*****************************************************\n");
-
-               ret = read(0, buf, sizeof(buf));
-               if (ret < 0) {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               } else if (ret == 0)
-                       return ret;
-
-               if (memcmp(buf, "0", sizeof("0") - 1) == 0) {
-                       TEST_DEBUG("Finished Testing this module, Going back to Main Menu");
-                       return -1;
-               } else if (memcmp(buf, "1g", sizeof("1g") - 1) == 0) {
-                       TEST_DEBUG("Get time info");
-                       ret_val = tel_get_misc_timezone_info();
-                       TEST_DEBUG("API RETURN VALUE : [%d]" , ret_val);
-               } else if (memcmp(buf, "1s", sizeof("1s") - 1) == 0) {
-                       TEST_DEBUG("Set time info");
-                       tapi_misc_time_zone_info_type timezone_info = { 0, };
-                       timezone_info.bDaylight_valid = 1;
-                       timezone_info.year = 10;
-                       timezone_info.month = 1;
-                       timezone_info.day = 1;
-                       timezone_info.hour = 1;
-                       timezone_info.minute = 1;
-                       timezone_info.second = 1;
-                       timezone_info.time_zone = 36;
-                       timezone_info.time_zone_valid = TAPI_MISC_NITZ_RTC_BKUP_PHONE;
-                       timezone_info.daylight_adjust = TAPI_MISC_NITZ_NOADJUST;
-                       timezone_info.day_of_week = TAPI_MISC_NITZ_DOW_FRI;
-
-                       ret_val = tel_set_misc_timezone_info(&timezone_info);
-
-                       TEST_DEBUG("API RETURN VALUE : [%d]" , ret_val);
-               } else if (memcmp(buf, "2", sizeof("2") - 1) == 0) {
-                       if (memcmp(buf + 1, "a", sizeof("a") - 1) == 0)
-                               alarm_info.minute += 1;
-                       else if (memcmp(buf + 1, "b", sizeof("b") - 1) == 0)
-                               alarm_info.minute += 2;
-                       else if (memcmp(buf + 1, "c", sizeof("c") - 1) == 0)
-                               alarm_info.minute += 3;
-                       else if (memcmp(buf + 1, "d", sizeof("d") - 1) == 0)
-                               alarm_info.minute += 10;
-                       else {
-                               TEST_DEBUG("Wrong Selection!!");
-                               return 0;
-                       }
-               } else if (memcmp(buf, "4", sizeof("4") - 1) == 0) {
-                       TEST_DEBUG("Get current alarm status");
-                       //ret_val = TelTapiMiscGetAlarmInfo();
-                       TEST_DEBUG("API RETURN VALUE : [%d]" , ret_val);
-               } else if (memcmp(buf, "5", sizeof("5") - 1) == 0) {
-                       TelMiscSNIndexType_t sn_index;
-                       TelMiscSNInformation sn_info = { 0, };
-
-                       int iSelect = 0;
-                       TEST_DEBUG("1. IMEI (UMTS)");
-                       TEST_DEBUG("2. ME_ESN (CDMA)");
-                       TEST_DEBUG("3. ME_MEID (CDMA)");
-                       TEST_DEBUG("Select: ");
-                       scanf("%d", &iSelect);
-
-                       switch (iSelect) {
-                       case 1:
-                               sn_index = TAPI_MISC_ME_IMEI;
-                               TEST_DEBUG("Get ME IMEI...!\n")
-                               ;
-                               break;
-                       case 2:
-                               sn_index = TAPI_MISC_ME_ESN;
-                               TEST_DEBUG("Get ME ESN...!\n")
-                               ;
-                               break;
-                       case 3:
-                               sn_index = TAPI_MISC_ME_MEID;
-                               TEST_DEBUG("Get ME MEID...!\n")
-                               ;
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!\n")
-                               ;
-                               return 0;
-                               break;
-                       }
-                       ret_val = tel_get_misc_me_sn(sn_index, &sn_info);
-
-                       if (ret_val == TAPI_API_SUCCESS) {
-                               TEST_DEBUG("sn_index[%d]",sn_info.sn_index);
-                               TEST_DEBUG("sn_len[%d]",sn_info.sn_len);
-                               TEST_DEBUG("szNumber[%s]",sn_info.szNumber);
-                       } else {
-                               TEST_DEBUG("FAIL API RETURN:[%d]",ret_val);
-                       }
-               } else if (memcmp(buf, "6", sizeof("6") - 1) == 0) {
-                       TelMiscVersionInformation ver_info = { 0, };
-                       TEST_DEBUG("ME version info..!");
-                       ret_val = tel_get_misc_me_version(&ver_info);
-                       if (ret_val == TAPI_API_SUCCESS) {
-                               TEST_DEBUG("ver_mask[0x%02x]",ver_info.ver_mask);
-                               TEST_DEBUG("szHwVersion[%s]",ver_info.szHwVersion);
-                               TEST_DEBUG("szSwVersion[%s]",ver_info.szSwVersion);
-                               TEST_DEBUG("szRfCalDate[%s]",ver_info.szRfCalDate);
-                               TEST_DEBUG("szProductCode[%s]",ver_info.szProductCode);
-                       } else {
-                               TEST_DEBUG("FAIL API RETURN:[%d]",ret_val);
-                       }
-               } else if (memcmp(buf, "7", sizeof("7") - 1) == 0) {
-                       TS_WORD nam_info_mask;
-                       TelMiscNamIndex_t nam_index;
-
-                       int iSelect = 0;
-                       TEST_DEBUG("1. The Number of Total NAM");
-                       TEST_DEBUG("2. The Index of current selected NAM");
-                       TEST_DEBUG("3. The Index of request NAM");
-                       TEST_DEBUG("4. Auto NAM");
-                       TEST_DEBUG("5. MCC");
-                       TEST_DEBUG("6. MNC");
-                       TEST_DEBUG("7. MIN");
-                       TEST_DEBUG("8. MDN");
-                       TEST_DEBUG("9. Nam Name");
-                       TEST_DEBUG("10. Nam Change");
-                       TEST_DEBUG("11. Current Nam num");
-                       TEST_DEBUG("12. All parameter");
-
-                       TEST_DEBUG("Select: ");
-                       scanf("%d", &iSelect);
-
-                       switch (iSelect) {
-                       case 1:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_TOTAL;
-                               break;
-                       case 2:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_CURRENT_INDEX;
-                               break;
-                       case 3:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_REQUEST_INDEX;
-                               break;
-                       case 4:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_AUTONAM;
-                               break;
-                       case 5:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_MCC;
-                               break;
-                       case 6:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_MNC;
-                               break;
-                       case 7:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_MIN;
-                               break;
-                       case 8:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_MDN;
-                               break;
-                       case 9:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_NAM_NAME;
-                               break;
-                       case 10:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_NAM_CHANGE;
-                               break;
-                       case 11:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_NAM_NUM;
-                               break;
-                       case 12:
-                               nam_info_mask = TAPI_MISC_NAM_INFO_MASK_ALL;
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!")
-                               ;
-                               return 0;
-                               break;
-                       }
-
-                       TEST_DEBUG("Select MISC Nam Index(1~5): ");
-                       scanf("%d", &iSelect);
-                       switch (iSelect) {
-                       case 1:
-                               nam_index = TAPI_MISC_NAM_1;
-                               break;
-                       case 2:
-                               nam_index = TAPI_MISC_NAM_2;
-                               break;
-                       case 3:
-                               nam_index = TAPI_MISC_NAM_3;
-                               break;
-                       case 4:
-                               nam_index = TAPI_MISC_NAM_4;
-                               break;
-                       case 5:
-                               nam_index = TAPI_MISC_NAM_5;
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!")
-                               ;
-                               return 0;
-                               break;
-                       }
-
-                       TEST_DEBUG("Current NAM index(1) or Request NAM index(2): ");
-                       scanf("%d", &iSelect);
-                       switch (iSelect) {
-                       case 1:
-                               nam_info_mask |= TAPI_MISC_NAM_INFO_MASK_CURRENT_INDEX;
-                               break;
-                       case 2:
-                               nam_info_mask |= TAPI_MISC_NAM_INFO_MASK_REQUEST_INDEX;
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!")
-                               ;
-                               return 0;
-                               break;
-                       }
-
-                       TEST_DEBUG("You selected nam infomask[0x%x] & index[0x%x]", nam_info_mask, nam_index);
-                       TEST_DEBUG("Get ME NAM Info...!");
-                       ret_val = tel_get_misc_nam_info(nam_info_mask, nam_index);
-                       TEST_DEBUG("API RETURN VALUE : [%d]" , ret_val);
-               }
-
-               else if (memcmp(buf, "8", sizeof("8") - 1) == 0) {
-                       int selection = 0;
-                       int mode = 0;
-                       char dummy;
-                       TEST_DEBUG("device emergency mode control");
-                       TEST_DEBUG("Please select operation: ");
-                       TEST_DEBUG("1:get status, 2:enable, 3:disable");
-                       scanf("%d%c",&selection,&dummy);
-
-                       switch (selection) {
-                       case 1:
-                               ret_val = tel_get_misc_emergency_mode(&mode);
-                               TEST_DEBUG("ret_val[%d], mode[%d]",ret_val,mode);
-                               break;
-                       case 2:
-                               ret_val = tel_set_misc_emergency_mode(1);
-                               TEST_DEBUG("enable ret_val[%d]",ret_val);
-                               break;
-                       case 3:
-                               ret_val = tel_set_misc_emergency_mode(0);
-                               TEST_DEBUG("disable ret_val[%d]",ret_val);
-                               break;
-                       }
-               } else {
-                       TEST_DEBUG("Invalid Selection!\n");
-               }
-
-       }
-
-       return 0;
-}
-
-void misc_select_loop(int option) {
-       int ret;
-       fd_set readfds;
-
-       while (1) {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret) {
-                       if (FD_ISSET(0, &readfds)) {
-                               if (misc_read_key_input(option) < 0)
-                                       break;
-                       }
-               }
-       }
-}
-
-int misc_test_subscribe_tapi_events(void) {
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfMISCEvt = 0;
-       TapiResult_t api_err = TAPI_API_SUCCESS;
-
-       int MISCEvtList[] = { TAPI_EVENT_MISC_NITZ_GETCNF, /**< 0x0A00, */
-                       TAPI_EVENT_MISC_NITZ_NOTIFY, /**<     */
-                       TAPI_EVENT_MISC_NITZ_IND, /**<     */
-                       TAPI_EVENT_MISC_AT_FUS, /**<     */
-                       //              TAPI_EVENT_MISC_ALARM_SETCNF,      /**< alarm set confirm message */
-                       //              TAPI_EVENT_MISC_ALARM_GETCNF,   /**< alarm message */
-                       TAPI_EVENT_MISC_SERIAL_NUMBER_IND,
-                       TAPI_EVENT_MISC_GET_NAM_INFO_CNF, TAPI_EVENT_MISC_SET_NAM_INFO_CNF,
-                       TAPI_EVENT_MISC_NAM_INFO_NOTI };
-
-       iNumOfMISCEvt = sizeof(MISCEvtList) / sizeof(int);
-       MISC_subscription_id = (unsigned int *) calloc(iNumOfMISCEvt,
-                       sizeof(unsigned int));
-
-       for (i = 0; i < iNumOfMISCEvt; i++) {
-               api_err = tel_register_event(MISCEvtList[i], &MISC_subscription_id[i],
-                               (TelAppCallback) &misc_async_event_callback, NULL);
-               if (api_err != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", MISCEvtList[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-}
diff --git a/src/test_apps/tapi_nw_test.c b/src/test_apps/tapi_nw_test.c
deleted file mode 100644 (file)
index b967973..0000000
+++ /dev/null
@@ -1,1286 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <assert.h>
-#include <glib.h>
-#include <unistd.h>
-#include <string.h>
-
-#include "ITapiNetwork.h"
-#include "TapiCommon.h"
-#include "ITapiPS.h"
-#include "TelUtility.h"
-#include "TelSim.h"
-#include "TelErr.h"
-#include "vconf.h"
-#include "TapiEvent.h"
-
-#if 0 //ED based
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}edata_t;
-#endif //ED based
-
-int error_code;
-int iNumOfNwEvt;
-static unsigned int * NW_subscription_id;
-//extern int EvtDeliveryHandle ;
-
-#define SZ_IMEI "user/telephony/szMobileEquipmentSerialNumber"
-
-#define TEST_DEBUG(frmt, args...) \
-{do { fprintf(stderr, "[NW Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-
-void __PrintNWBand(char* str, TelNetworkBand_t tNWBandType)
-{
-       switch(tNWBandType)
-       {
-               case TAPI_NETWORK_BAND_TYPE_ANY:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_ANY [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_GSM850:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM850 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_GSM_900_1800:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM_900_1800 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_GSM1900:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM1900 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_GSM:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_WCDMA:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_WCDMA [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_WCDMA850:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_WCDMA850 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_WCDMA1900:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_WCDMA1900 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-
-               case TAPI_NETWORK_BAND_TYPE_WCDMA2100:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_WCDMA2100 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-               case TAPI_NETWORK_BAND_TYPE_GSM900:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM900 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-               case TAPI_NETWORK_BAND_TYPE_GSM1800:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM1800 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-               case TAPI_NETWORK_BAND_TYPE_GSM_850_1900:
-                       {
-                               TEST_DEBUG("%s TAPI_NETWORK_BAND_TYPE_GSM_850_1900 [0x%x]", str, tNWBandType);
-                       }
-                       break;
-               default:
-                       {
-                               TEST_DEBUG("%s Undefined Storage Type returnted [0x%x]", str, tNWBandType);
-                       }
-                       break;
-       }
-       return;
-}
-
-
-void __PrintGetRoamingModeCnfCB(void *pData)
-{
-       TelNetworkRoamingMode_t* pRoamingMode = NULL;
-
-       pRoamingMode = (TelNetworkRoamingMode_t *)pData;
-
-       switch(pRoamingMode->pref_net_type)
-       {
-               case TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC:
-                       TEST_DEBUG("TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC\n");
-                       break;
-               case TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_A:
-                       TEST_DEBUG("TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_A\n");
-                       break;
-               case TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_B:
-                       TEST_DEBUG("TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_B\n");
-                       break;
-               case TAPI_NETWORK_PREF_NET_TYPE_HOME_ONLY:
-                       TEST_DEBUG("TAPI_NETWORK_PREF_NET_TYPE_HOME_ONLY\n");
-                       break;
-               case TAPI_NETWORK_PREF_NET_TYPE_ROAM_ONLY:
-                       TEST_DEBUG("TAPI_NETWORK_PREF_NET_TYPE_ROAM_ONLY\n");
-                       break;
-               default:
-                       break;
-       }
-
-       switch(pRoamingMode->prl_pref_only)
-       {
-               case TAPI_NETWORK_PRL_PREF_ONLY_OFF:
-                       TEST_DEBUG("TAPI_NETWORK_PRL_PREF_ONLY_OFF\n");
-                       break;
-               case TAPI_NETWORK_PRL_PREF_ONLY_ON:
-                       TEST_DEBUG("TAPI_NETWORK_PRL_PREF_ONLY_ON\n");
-                       break;
-               default:
-                       break;
-       }
-
-       return;
-}
-
-void __PrintGetHybridModeCnfCB(void *pData)
-{
-       TelNetworkCDMAHybridMode_t HybridMode = 0x00;
-
-       memcpy(&HybridMode, pData, sizeof(TelNetworkCDMAHybridMode_t));
-
-       switch(HybridMode){
-               case TAPI_NETWORK_CDMA_HYBRID:
-                       TEST_DEBUG("TAPI_NETWORK_CDMA_HYBRID \n");
-                       break;
-               case TAPI_NETWORK_CDMA_1X_ONLY:
-                       TEST_DEBUG("TAPI_NETWORK_CDMA_1X_ONLY\n");
-                       break;
-               case TAPI_NETWORK_CDMA_EVDO_ONLY:
-                       TEST_DEBUG("TAPI_NETWORK_CDMA_EVDO_ONLY\n");
-                       break;
-               default:
-                       TEST_DEBUG("Unknown Mode\n");
-                       break;
-       }
-       return;
-}
-
-void __PrintGetNetworkInfoCB(void* pData)
-{
-       TelNetworkInfo_t tNetworkInfo ={0,};
-       memcpy(&tNetworkInfo, pData, sizeof(TelNetworkInfo_t));
-
-       TEST_DEBUG("__PrintGetNetworkInfoCB() : PLMN is %lu\n",tNetworkInfo.SysId.SysId);
-
-       if(tNetworkInfo.SysId.bPlmnForbidden== TRUE)
-       {
-               TEST_DEBUG("__PrintGetNetworkInfoCB(): Network Forbidden\n");
-       }
-
-       TEST_DEBUG("Network Service Type : ");
-       switch(tNetworkInfo.SysId.SystemType)
-       {
-
-               case TAPI_NETWORK_SYSTEM_GSM: // GSM
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_GSM\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_GPRS: // GPRS
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_GPRS\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_UMTS: // UTRAN
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_UMTS\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_EGPRS: // EGPRS
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_EGPRS\n");
-                       break;
-
-               default:
-                       TEST_DEBUG(" DEFAULT IN SYSTEM TYPE\n");
-                       break;
-
-       }
-
-       TEST_DEBUG("Network Service Level : ");
-       switch(tNetworkInfo.ServiceLevel)
-       {
-               case TAPI_NETWORK_SERVICE_LEVEL_NO:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_NO\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_EMERGENCY:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_EMERGENCY\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_FULL:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_FULL\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_SEARCH:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_SEARCH\n");
-                       break;
-
-               default:
-                       TEST_DEBUG(" Not Defined\n");
-                       break;
-
-       }
-       return;
-}
-
-
-void __PrintSearchNetworkCB(void* pData)
-{
-       TelNetworkList_t tmpNetworkList ={0,};
-       int idx=0;
-
-       memcpy(&tmpNetworkList, pData, sizeof(TelNetworkList_t));
-       TEST_DEBUG("[PHONE CLIENT] ReceiveNetworkList() - entryCount:[%d]\n",tmpNetworkList.NumOfNwAvailable);
-
-       for(idx=0;idx<tmpNetworkList.NumOfNwAvailable;idx++)
-       {
-               TEST_DEBUG("[PHONE CLIENT] NetworkList.systemList[idx].sysid =>%lu\n", tmpNetworkList.SystemList[idx].SysId);
-               //                      TEST_DEBUG("[PHONE CLIENT] NetworkList.systemList[idx].systemType =>%x\n", NetworkList.systemList[idx].systemType  );
-       }
-
-       if(tmpNetworkList.SystemList[0].ServiceType== TAPI_NETWORK_SERVICE_TYPE_COMBINED)
-       {
-               TEST_DEBUG("TAPI_NETWORK_SERVICE_TYPE_COMBINED\n");
-
-       }
-       else if(tmpNetworkList.SystemList[0].ServiceType== TAPI_NETWORK_SERVICE_TYPE_CS)
-       {
-               TEST_DEBUG("TAPI_NETWORK_SERVICE_TYPE_CS\n");
-
-       }
-       else if(tmpNetworkList.SystemList[0].ServiceType== TAPI_NETWORK_SERVICE_TYPE_PS)
-       {
-               TEST_DEBUG("TAPI_NETWORK_SERVICE_TYPE_PS\n");
-       }
-
-}
-
-void __PrintSelectNetworkCB(void* pData)
-{
-       TelNetworkInfo_t tNetworkInfo = {0,};
-       memcpy(&tNetworkInfo, pData, sizeof(TelNetworkInfo_t));
-
-       switch(tNetworkInfo.SysId.SystemType)
-       {
-               case TAPI_NETWORK_SYSTEM_GSM: // GSM
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_GSM\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_GPRS: // GPRS
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_GPRS\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_UMTS: // UTRAN
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_UMTS\n");
-                       break;
-
-               case TAPI_NETWORK_SYSTEM_EGPRS: // EGPRS
-                       TEST_DEBUG(" TAPI_NETWORK_SYSTEM_EGPRS\n");
-                       break;
-
-               default:
-                       TEST_DEBUG(" DEFAULT IN SYSTEM TYPE\n");
-                       break;
-
-       }
-
-       switch(tNetworkInfo.SysId.SystemType)
-       {
-
-               case TAPI_NETWORK_SERVICE_TYPE_NO_SVE:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_TYPE_NO_SVE\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_TYPE_LIMITED:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_TYPE_LIMITED\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_TYPE_CS:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_TYPE_CS\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_TYPE_PS:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_TYPE_PS\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_TYPE_COMBINED:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_TYPE_COMBINED\n");
-                       break;
-
-               default:
-                       TEST_DEBUG(" DEFAULT IN SERVICE TYPE\n");
-                       break;
-
-       }
-
-       switch(tNetworkInfo.ServiceLevel)
-       {
-
-               case TAPI_NETWORK_SERVICE_LEVEL_NO:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_NO\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_EMERGENCY:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_EMERGENCY\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_FULL:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_FULL\n");
-                       break;
-
-               case TAPI_NETWORK_SERVICE_LEVEL_SEARCH:
-                       TEST_DEBUG(" TAPI_NETWORK_SERVICE_LEVEL_SEARCH\n");
-                       break;
-
-               default:
-                       TEST_DEBUG(" DEFAULT IN SERVICE LEVEL\n");
-                       break;
-
-       }
-
-
-}
-
-void __PrintGetSelectionModeCB(void* pData)
-{
-       TelNetworkSelectionMode_t tSelectionMode = 0x00;
-       memcpy(&tSelectionMode, pData, sizeof(TelNetworkSelectionMode_t));
-
-       if(tSelectionMode == TAPI_NETWORK_SELECTIONMODE_AUTOMATIC)
-       {
-               TEST_DEBUG("__PrintGetSelectionModeCB(): TAPI_MODE_AUTOMATIC\n");
-       }
-       else if(tSelectionMode == TAPI_NETWORK_SELECTIONMODE_MANUAL)
-       {
-               TEST_DEBUG("__PrintGetSelectionModeCB(): TAPI_MODE_MANUAL\n");
-       }
-       else TEST_DEBUG("__PrintGetSelectionModeCB()???");
-
-       return;
-}
-
-
-void nw_async_event_callback(TelTapiEvent_t* pNwEvent, void *data)
-{
-
-       TEST_DEBUG("Func Entrance");
-       TEST_DEBUG("Request ID : [0x%x]\n", pNwEvent->RequestId);
-
-       if(pNwEvent->pData==NULL)
-       {
-               TEST_DEBUG("No Event Data!!");
-//             return;
-       }
-
-       TEST_DEBUG("*************** Callback data **********************");
-       TEST_DEBUG("EventClass [%d],EventType [0x%x], Reques Id[%d], Event status [%d], psEvent->pDataLen[%d]",
-               pNwEvent->EventClass, pNwEvent->EventType, pNwEvent->RequestId, pNwEvent->Status,pNwEvent->pDataLen);
-
-       switch(pNwEvent->EventClass)
-       {
-               case TAPI_EVENT_CLASS_NETWORK:
-                       {
-                               switch(pNwEvent->EventType)
-                               {
-                                       case TAPI_EVENT_NETWORK_RADIO_INFO_IND :
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_RADIO_INFO_IND $$$$$$ \n");
-                                                       //system("cat bark-2.wav > /dev/dsp");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SELECT_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SELECT_CNF $$$$$$");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_GETSELECTIONMODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETSELECTIONMODE_CNF $$$$$$");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR)
-                                                               __PrintGetSelectionModeCB(pNwEvent->pData);
-                                               }
-                                               break;
-
-
-                                        case TAPI_EVENT_NETWORK_GETPREFFEREDPLMN_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETPREFFEREDPLMN_CNF $$$$$$");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkPrefferedPlmnList_t   preff_plmn_list;
-                                                               memcpy(&preff_plmn_list, pNwEvent->pData, sizeof(TelNetworkPrefferedPlmnList_t));
-                                                               unsigned int plmn_count;
-                                                               unsigned int counter ;
-                                                               plmn_count = preff_plmn_list.NumOfPreffPlmns;
-                                                               counter = 0;
-                                                               TEST_DEBUG(" PREFF PLMN COUNT :[%d]\n",preff_plmn_list.NumOfPreffPlmns);
-                                                               while(counter <plmn_count)
-                                                               {
-                                                                       TEST_DEBUG(" INDEX:[%d]\t\t",preff_plmn_list.PreffPlmnRecord[counter].Index);
-                                                                       TEST_DEBUG(" PLMN ID:[%s]\t\t",preff_plmn_list.PreffPlmnRecord[counter].Plmn);
-                                                                       TEST_DEBUG(" SYSTEM TYPE:[%d]\n",preff_plmn_list.PreffPlmnRecord[counter].SystemType);
-                                                                       TEST_DEBUG("");
-                                                                       counter++;
-                                                               }
-                                                       }
-
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_GETPOWERONATTACH_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETPOWERONATTACH_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkPowerOnAttach_t       poweron_attach;
-                                                               memcpy(&poweron_attach, pNwEvent->pData, sizeof(TelNetworkPowerOnAttach_t));
-                                                               if(poweron_attach == TAPI_NETWORK_POWERON_ATTACH_DISABLE)
-                                                               {
-                                                                       TEST_DEBUG(" Power On Attach diable");
-                                                               }
-                                                               else if(poweron_attach == TAPI_NETWORK_POWERON_ATTACH_ENABLE)
-                                                               {
-                                                                       TEST_DEBUG(" Power On Attach enable");
-                                                               }
-                                                               else
-                                                               {
-                                                                       TEST_DEBUG(" Power On Attach status Error");
-                                                               }
-                                                       }
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_SETPOWERONATTACH_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETPOWERONATTACH_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_GETNWBAND_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETNWBAND_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkBand_t band_type;
-                                                               memcpy(&band_type, pNwEvent->pData, sizeof(TelNetworkBand_t));
-                                                               __PrintNWBand(" BAND TYPE: ", band_type);
-                                                       }
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_GETSERVICEDOMAIN_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETSERVICEDOMAIN_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkServiceDomain_t service_type;
-                                                               memcpy(&service_type, pNwEvent->pData, sizeof(TelNetworkServiceDomain_t));
-                                                               TEST_DEBUG(" SERVICE DOMAIN:[%d] 0:combined,1:ps,2:cs,3:auto ", service_type);
-                                                       }
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_GETNWORDER_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETNWORDER_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkMode_t        network_order[TAPI_NETWORK_ORDER_MAX];
-                                                               memcpy(&network_order, pNwEvent->pData, (sizeof(TelNetworkMode_t)* TAPI_NETWORK_ORDER_MAX));
-                                                               TEST_DEBUG(" NETWORK ORDER:[%d] 0:none,1:em,2:auto,3:cdma,4:gsm,5:wcdma,6:wlan ", network_order[0]);
-                                                       }
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_SETPREFFEREDPLMN_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETPREFFEREDPLMN_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_GETNWMODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GETNWMODE_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR){
-                                                               TelNetworkMode_t        network_mode;
-                                                               memcpy(&network_mode, pNwEvent->pData, sizeof(TelNetworkMode_t));
-                                                               TEST_DEBUG(" NETWORK MODE:[%d] 0:none,1:em,2:auto,3:cdma,4:gsm,5:wcdma,6:wlan", network_mode);
-                                                       }
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_LOCATIONCELLINFO_IND:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_LOCATIONCELLINFO_IND $$$$$$ ");
-                                                       TelNetworkLocationCellInfo_t  network_loc_cell_info;
-                                                       memcpy(&network_loc_cell_info, pNwEvent->pData, sizeof(TelNetworkLocationCellInfo_t));
-                                                       TEST_DEBUG(" LAC:[%d] ", network_loc_cell_info.LocationAreaCode);
-                                                       TEST_DEBUG(" CID:[%ld]", network_loc_cell_info.CellId);
-                                               }
-                                               break;
-
-                                        case TAPI_EVENT_NETWORK_DISPLAYINFO_IND:
-                                               {
-                                                       TelNetworkDisplayInfo_t   dispInfo;
-                                                       memcpy(&dispInfo, pNwEvent->pData, sizeof(TelNetworkDisplayInfo_t));
-
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_DISPLAYINFO_IND $$$$$$ ");
-
-                                                       if(dispInfo.DisplayInfo[TAPI_NETWORK_CS_DISP_INDEX] != -1)
-                                                       {
-                                                               TEST_DEBUG("CSTYPE = %d ",dispInfo.DisplayInfo[TAPI_NETWORK_CS_DISP_INDEX]);
-                                                       }
-                                                       if(dispInfo.DisplayInfo[TAPI_NETWORK_PS_DISP_INDEX] != -1)
-                                                       {
-                                                               TEST_DEBUG("PSTYPE = %d ",dispInfo.DisplayInfo[TAPI_NETWORK_PS_DISP_INDEX]);
-                                                       }
-                                                       if(dispInfo.DisplayInfo[TAPI_NETWORK_SVC_DISP_INDEX] != -1)
-                                                       {
-                                                               TEST_DEBUG("SVCTYPE = %d ",dispInfo.DisplayInfo[TAPI_NETWORK_SVC_DISP_INDEX] );
-                                                       }
-                                                       if(dispInfo.DisplayInfo[TAPI_NETWORK_ROAM_DISP_INDEX] != -1)
-                                                       {
-                                                               TEST_DEBUG("ROAM TYPE = %d ", dispInfo.DisplayInfo[TAPI_NETWORK_ROAM_DISP_INDEX]);
-                                                       }
-
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SEARCH_CNF:
-                                               {
-
-                                                       TelNetworkPlmnList_t* ui_network_info;
-                                                       int ui_entry_count=0;
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SEARCH_CNF $$$$$$ ");
-
-                                                       ui_network_info = (TelNetworkPlmnList_t *)calloc(1, sizeof(TelNetworkPlmnList_t));
-
-                                                       memcpy(ui_network_info, pNwEvent->pData, sizeof(TelNetworkPlmnList_t));
-
-                                                       while(ui_entry_count<ui_network_info->networks_count)
-                                                       {
-
-                                                               TEST_DEBUG( "Type_of_plmn[%d] 0:unkwon,1:home,2:available,3:forbidden,  NetworkName[%s]",ui_network_info->network_list[ui_entry_count].type_of_plmn,ui_network_info->network_list[ui_entry_count].network_name);
-                                                               TEST_DEBUG( "ServiceProviderName[%s]",ui_network_info->network_list[ui_entry_count].service_provider_name);
-                                                               TEST_DEBUG( "PLMN ID[%u]",ui_network_info->network_list[ui_entry_count].plmn_id);
-                                                               ui_entry_count++;
-                                                       }
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SPN_INFO:
-                                               {
-                                                       TelNetworkSpnMccMncInfo_t       short_network_name;
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SPN_INFO $$$$$$ ");
-                                                       memcpy(&short_network_name, pNwEvent->pData, sizeof(TelNetworkSpnMccMncInfo_t));
-                                                       TEST_DEBUG(" Display Condition ####     [%d]     ####",short_network_name.bDispCondition);
-                                                       TEST_DEBUG(" RPLMN  NAME ####   [%s]     ####",short_network_name.short_network_name);
-                                                       TEST_DEBUG("SERVICE PROVIDER NAME ####   [%s]    ####",short_network_name.spn_name);
-                                                       TEST_DEBUG("MCC ####    [%d] ####       MNC #### [%d]",short_network_name.mcc , short_network_name.mnc);
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SETNWORDER_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETNWORDER_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SETNWMODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETNWMODE_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SETNWBAND_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETNWBAND_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SETSERVICEDOMAIN_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SETSERVICEDOMAIN_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SET_ROAMING_MODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SET_ROAMING_MODE_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_GET_ROAMING_MODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GET_ROAMING_MODE_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR)
-                                                               __PrintGetRoamingModeCnfCB(pNwEvent->pData);
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_SET_CDMA_HYBRID_MODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_SET_CDMA_HYBRID_MODE_CNF $$$$$$ ");
-                                               }
-                                               break;
-
-                                       case TAPI_EVENT_NETWORK_GET_CDMA_HYBRID_MODE_CNF:
-                                               {
-                                                       TEST_DEBUG("$$$$$$ TAPI_EVENT_NETWORK_GET_CDMA_HYBRID_MODE_CNF $$$$$$ ");
-                                                       if(pNwEvent->Status == TAPI_NETWORK_NO_ERR)
-                                                               __PrintGetHybridModeCnfCB(pNwEvent->pData);
-                                               }
-                                               break;
-
-                                       default:
-                                               TEST_DEBUG("Unhandled pNwEvent->EventType[0x%x]",pNwEvent->EventType);
-                                               break;
-                               }
-                       }
-                       break;
-
-               default:
-                       TEST_DEBUG("Unhandled pNwEvent->EventClass[0x%x]",pNwEvent->EventClass);
-                       break;
-       }
-
-       return;
-}
-
-
-int nw_read_key_input(int option)
-{
-       int ret;
-       char buf[512] = {0, };
-       char msg[512];
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-       int reqid;
-
-       memset(buf, 0x00, sizeof(buf));
-       memset(msg, 0x00, sizeof(msg));
-
-       fprintf(stderr,"*************** NETWORK TEST MENU     ***************\n");
-       fprintf(stderr,"c.Cancel to Search Network\n");
-       fprintf(stderr,"1.Search Network\n");
-       fprintf(stderr,"2.Select Network [mode(automatic/manual) systemid]\n");
-       fprintf(stderr,"3.Get Selection Mode\n");
-       fprintf(stderr,"4.Set NETWORK MODE --> [a] AUTO \t [b] GSM \t[c] WCDMA\n");
-       fprintf(stderr,"5.Get NETWORK MODE\n");
-       fprintf(stderr,"6 Set NETWORK Preferred Order -->[a] GSM [b] WCDMA [c] AUTO \n");
-       fprintf(stderr,"7 Get NETWORK Preferred Order\n");
-       fprintf(stderr,"8.Set SERVICE DOMAIN -->[a] PS [b] CS [c] AUTO [d] COMBINED\n");
-       fprintf(stderr,"9.Get SERVICE DOMAIN\n");
-       fprintf(stderr,"10.Get Network Information\n");
-       fprintf(stderr,"11.Set Preferred PLMN List \n");
-       fprintf(stderr,"12.Get Preferred PLMN List \n");
-       fprintf(stderr,"13.Set POWER ON ATTACH --> [a] DISABLE [b] ENABLE\n");
-       fprintf(stderr,"14.Get POWER ON ATTACH\n");
-       fprintf(stderr,"15.Set NETWORK BAND \n");
-       fprintf(stderr,"16.Get NETWORK BAND \n");
-       fprintf(stderr,"17.Get Phone Number (from gconf)-not used now(091130) \n");
-       fprintf(stderr,"*****************************************************\n");
-       fprintf(stderr,"1A.Set CDMA Roaming Mode [a]Auto [b]Auto_A [c]Auto_b [d]Home [e]Roam\n");
-       fprintf(stderr,"1B.Get CDMA Roaming Mode \n");
-       fprintf(stderr,"1C.Set CDMA Hybrid Mode [a]Hybrid [b]1x [c]EVDO\n");
-       fprintf(stderr,"1D.Get CDMA Hybrid Mode \n");
-       fprintf(stderr,"*************** VCONF / STATUS TEST MENU ********************\n");
-       fprintf(stderr,"STATUS GET CLASS  : class0(Net), class1(Sim), class2(CPHS), class3(SimDevCtx)\n");
-       fprintf(stderr,"VCONF /STATUS GET MEMBER : mem \n");
-       fprintf(stderr,"*****************************************************\n");
-       fprintf(stderr,"q Quit\n");
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0) return ret;
-
-       if(strncmp(buf, "menu", 4) == 0)
-       {
-               printf("Finished Testing this module, Going back to Main Menu\n");
-               return -1;
-       }
-
-       if( ret == 2 && memcmp(buf,"c",sizeof("c")-1) == 0 )
-       {
-               ret_val = tel_cancel_network_manual_search(&reqid);
-               TEST_DEBUG("TelTapiNwCancelManualSearch API RETURN VALUE : [%d]" , ret_val);
-       }
-
-       if( ret == 2 && memcmp(buf,"1",sizeof("1")-1) == 0 )
-       {
-               ret_val = tel_search_network(&reqid);
-               TEST_DEBUG("tel_search_network API RETURN VALUE : [%d]" , ret_val);
-       }
-
-       if( memcmp(buf,"2",sizeof("2")-1) == 0 )
-       {
-               unsigned int plmn = 45001;
-               TelNetworkSelectionMode_t mode;
-               char tmpPLMN[6]={0, };
-
-               if(memcmp(buf+2, "automatic", sizeof("automatic")-1) == 0){
-                       TEST_DEBUG("Automatic mode \n");
-                       ret_val = tel_select_network_automatic(&reqid);
-               }
-               else if(memcmp(buf+2, "manual", sizeof("manual")-1) == 0){
-                       TEST_DEBUG("Manual mode \t");
-                       mode = TAPI_NETWORK_SELECTIONMODE_MANUAL;
-                       memcpy(tmpPLMN,  buf+3 + sizeof("manual")-1, 6);
-                       plmn=(TS_UINT32)atoi(tmpPLMN);
-                       TEST_DEBUG("PLMN number is [%u]",plmn);
-                       ret_val = tel_select_network_manual(plmn, &reqid);
-               }
-               else{
-                       TEST_DEBUG("Unknown mode \n");
-                       return 0;
-               }
-
-               TEST_DEBUG("tel_select_network_manual API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       else if(memcmp(buf,"3",sizeof("3")-1) == 0)
-       {
-               ret_val = tel_get_network_selection_mode(&reqid);
-               TEST_DEBUG("tel_get_network_selection_mode API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if( memcmp(buf,"4",sizeof("4")-1) == 0 )
-       {
-
-               TelNetworkMode_t networkMode;
-               if(memcmp(buf+1,"a",sizeof("a")-1) == 0 )
-                       networkMode =TAPI_NETWORK_MODE_AUTOMATIC;
-               else if(memcmp(buf+1,"b",sizeof("b")-1) == 0 )
-                       networkMode =TAPI_NETWORK_MODE_GSM;
-               else if(memcmp(buf+1,"c",sizeof("c")-1) == 0 )
-                       networkMode =TAPI_NETWORK_MODE_WCDMA;
-               else{
-                       TEST_DEBUG("Unknown Network mode\n");
-                       return 0;
-               }
-
-               ret_val = tel_set_network_mode(networkMode, &reqid);
-               TEST_DEBUG("tel_set_network_mode API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"5",sizeof("5")-1) == 0 )
-       {
-               ret_val = tel_get_network_mode(&reqid);
-               TEST_DEBUG("tel_get_network_mode API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-
-       if( memcmp(buf,"6",sizeof("6")-1) == 0 )
-       {
-               TelNetworkMode_t networkOrder[5];
-
-               if(memcmp(buf+1,"a",sizeof("a")-1) == 0 )
-                       networkOrder[0] =TAPI_NETWORK_MODE_GSM;
-               else if(memcmp(buf+1,"b",sizeof("b")-1) == 0 )
-                       networkOrder[0] =TAPI_NETWORK_MODE_WCDMA;
-               else if(memcmp(buf+1,"c",sizeof("c")-1) == 0 )
-                       networkOrder[0] =TAPI_NETWORK_MODE_AUTOMATIC;
-
-               ret_val = tel_set_network_acquisition_order(networkOrder, &reqid);
-               TEST_DEBUG("tel_set_network_acquisition_order API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if( memcmp(buf,"7",sizeof("7")-1) == 0 )
-       {
-               ret_val = tel_get_network_acquisition_order(&reqid);
-               TEST_DEBUG("tel_get_network_acquisition_order API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"8",sizeof("8")-1) == 0)
-       {
-               TelNetworkServiceDomain_t serviceDomain;
-
-               if(memcmp(buf+1,"a",sizeof("a")-1) == 0 )
-                       serviceDomain =TAPI_NETWORK_SERVICE_DOMAIN_PS ;
-               else if(memcmp(buf+1,"b",sizeof("b")-1) == 0 )
-                       serviceDomain =TAPI_NETWORK_SERVICE_DOMAIN_CS ;
-               else if(memcmp(buf+1,"c",sizeof("c")-1) == 0 )
-                       serviceDomain =TAPI_NETWORK_SERVICE_DOMAIN_AUTOMATIC ;
-               else if(memcmp(buf+1,"d",sizeof("d")-1) == 0 )
-                       serviceDomain =TAPI_NETWORK_SERVICE_DOMAIN_COMBINED ;
-
-               ret_val = tel_set_network_service_domain(serviceDomain, &reqid);
-               TEST_DEBUG("tel_set_network_service_domain API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"9",sizeof("9")-1) == 0)
-       {
-               ret_val = tel_get_network_service_domain(&reqid);
-               TEST_DEBUG("tel_get_network_service_domain API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"11",sizeof("11")-1) == 0)
-       {
-               TelNetworkPrefferedPlmnInfo_t  PreffPlmnInfo;
-               int index = 0;
-               char dummy;
-               TEST_DEBUG("Plese input index : ");
-               scanf("%d%c",&index,&dummy);
-               PreffPlmnInfo.Index = index;
-               strcpy((char *)PreffPlmnInfo.Plmn, "45454");
-               TEST_DEBUG("Add 45454# to Preferred PLMN");
-               PreffPlmnInfo.SystemType = TAPI_NETWORK_SYSTEM_GSM;
-               ret_val = tel_set_network_preferred_plmn(TAPI_NETWORK_PREF_PLMN_ADD, &PreffPlmnInfo, &reqid);
-               TEST_DEBUG("tel_set_network_preferred_plmn API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"12",sizeof("12")-1) == 0)
-       {
-               ret_val = tel_get_network_preferred_plmn(&reqid);
-               TEST_DEBUG("tel_get_network_preferred_plmn API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"13",sizeof("13")-1) == 0)
-       {
-               if(memcmp(buf+2,"a",sizeof("a")-1) == 0)
-               {
-                       ret_val = tel_set_network_power_on_attach(TAPI_NETWORK_POWERON_ATTACH_DISABLE, &reqid );
-                       TEST_DEBUG("tel_set_network_power_on_attach API[Disable] RETURN VALUE : [%d]\n" , ret_val);
-               }
-               else if(memcmp(buf+2,"b",sizeof("b")-1) == 0)
-               {
-                       ret_val = tel_set_network_power_on_attach(TAPI_NETWORK_POWERON_ATTACH_ENABLE, &reqid);
-                       TEST_DEBUG("tel_set_network_power_on_attach API[Enable] RETURN VALUE : [%d]\n" , ret_val);
-               }
-       }
-
-       if(memcmp(buf,"14",sizeof("14")-1) == 0)
-       {
-               ret_val = tel_get_network_power_on_attach(&reqid);
-               TEST_DEBUG("tel_get_network_power_on_attach API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"15",sizeof("15")-1) == 0)
-       {
-               int iBandMode = 1;
-               int iBand = 1;
-               fprintf(stderr, "1=Preferred, 2=Only\n");
-               fprintf(stderr, "Input Band Mode: ");
-               scanf("%d", &iBandMode);
-               getchar();
-
-               fprintf(stderr, "0=All,1=GSM850 2=GSM900_1800 3=GSM1900 4=GSM_ALL 5=WCDMA 6=WCDMA850 7=WCDMA1900 8=WCDMA2100 9=gsm900 10=gsm1800 11=gsm850_1900\n");
-               fprintf(stderr, "Input Band: ");
-               scanf("%d", &iBand);
-               getchar();
-
-               ret_val = tel_set_network_band(iBandMode, iBand, &reqid);
-               //TelTapiNwSetNetworkBand(TAPI_NETWORK_BAND_MODE_ONLY , TAPI_NETWORK_BAND_TYPE_ANY,&reqid);
-               TEST_DEBUG("tel_set_network_band API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"16",sizeof("16")-1) == 0)
-       {
-               ret_val = tel_get_network_band(&reqid);
-               TEST_DEBUG("tel_get_network_band API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(memcmp(buf,"17",sizeof("17")-1) == 0)
-       {
-#if 0 //not use in slp2.0
-               GConfClient*    gconf_client;
-               char*       strval;
-
-               gconf_client = gconf_client_get_default();
-
-               // get Subscriber No from gconf
-               strval= gconf_client_get_string(gconf_client, "/Services/Telephony/szSubscriberNumber", NULL);
-
-               TEST_DEBUG("Subscriber Number [ %s ] from gconf", strval);
-
-               g_free(strval); //g_free checks for the NULL, so no need to check seperately
-               g_object_unref(gconf_client);
-#endif //not use in slp2.0
-       }
-
-       if( memcmp(buf,"1A",sizeof("1A")-1) == 0 )
-       {
-               TelNetworkRoamingMode_t RoamingMode = {0, };
-               if(memcmp(buf+3,"a",sizeof("a")-1) == 0 )
-               {
-                       RoamingMode.pref_net_type = TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC;
-               }
-               else if(memcmp(buf+3,"b",sizeof("b")-1) == 0 )
-               {
-                       RoamingMode.pref_net_type = TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_A;
-               }
-               else if(memcmp(buf+32,"c",sizeof("c")-1) == 0 )
-               {
-                       RoamingMode.pref_net_type = TAPI_NETWORK_PREF_NET_TYPE_AUTOMATIC_B;
-               }
-               else if(memcmp(buf+3,"d",sizeof("d")-1) == 0 )
-               {
-                       RoamingMode.pref_net_type = TAPI_NETWORK_PREF_NET_TYPE_HOME_ONLY;
-               }
-               else if(memcmp(buf+3,"e",sizeof("e")-1) == 0 )
-               {
-                       RoamingMode.pref_net_type = TAPI_NETWORK_PREF_NET_TYPE_ROAM_ONLY;
-               }
-               else
-                       TEST_DEBUG("unknown roam preferred network type \n");
-               RoamingMode.prl_pref_only = TAPI_NETWORK_PRL_PREF_ONLY_OFF;
-
-               TEST_DEBUG("tel_set_network_roaming ..... mode:[%d]\n" , ret_val);
-               ret_val = tel_set_network_roaming(&RoamingMode, &reqid);
-               TEST_DEBUG("tel_set_network_roaming API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if( memcmp(buf,"1B",sizeof("1B")-1) == 0 )
-       {
-               ret_val = tel_get_network_roaming(&reqid);
-               TEST_DEBUG("API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-
-       if( memcmp(buf,"1C",sizeof("1C")-1) == 0 )
-       {
-               TelNetworkCDMAHybridMode_t CDMAHybridMode = 0;
-               if(memcmp(buf+3,"a",sizeof("a")-1) == 0 )
-               {
-                       CDMAHybridMode = TAPI_NETWORK_CDMA_HYBRID;
-               }
-               else if(memcmp(buf+3,"b",sizeof("b")-1) == 0 )
-               {
-                       CDMAHybridMode = TAPI_NETWORK_CDMA_1X_ONLY;
-               }
-               else if(memcmp(buf+3,"c",sizeof("c")-1) == 0 )
-               {
-                       CDMAHybridMode = TAPI_NETWORK_CDMA_EVDO_ONLY;
-               }
-               else
-               {
-                       TEST_DEBUG("unknown roam preferred network type \n");
-               }
-               TEST_DEBUG("tel_set_network_hybrid_in_cdma .... mode:[%d]\n" , CDMAHybridMode);
-               ret_val = tel_set_network_hybrid_in_cdma(CDMAHybridMode, &reqid);
-               TEST_DEBUG("tel_set_network_hybrid_in_cdma API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if( memcmp(buf,"1D",sizeof("1D")-1) == 0 )
-       {
-               ret_val = tel_get_network_hybrid_in_cdma(&reqid);
-               TEST_DEBUG("tel_get_network_hybrid_in_cdma API RETURN VALUE : [%d]\n" , ret_val);
-       }
-
-       if(strncmp(buf, "mem", 3) == 0)
-       {
-               int retValue=0;
-               int apiRet =0;
-               char* spnName = NULL;
-               char* nwName = NULL;
-               char* imei = NULL;
-               char* szImei = NULL;
-               char* szSubNum = NULL;
-               char* szSubName = NULL;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_RSSI, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_RSSI api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_PLMN, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_PLMN api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_LAC, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_LAC api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_CELLID, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_CELLID api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_TAPI_STATE, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_TAPI_STATE api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SVC_ROAM, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SVC_ROAM api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SVC_CS, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SVC_CS api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SVC_PS, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SVC_PS api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_ZONE_TYPE, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_ZONE_TYPE api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SVCTYPE, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SVCTYPE api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_LOW_BATTERY, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_LOW_BATTERY api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SIM_INIT, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SIM_INIT api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SIM_CHV, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SIM_CHV api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SIM_SLOT, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SIM_SLOT api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SIM_PB_INIT, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SIM_PB_INIT api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_CALL_STATE, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_CALL_STATE api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_ZONE_ZUHAUSE, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_ZONE_ZUHAUSE api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SAT_IDLE_SCREEN_EVENT, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SAT_IDLE_SCREEN_EVENT api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               apiRet = vconf_get_int(VCONFKEY_TELEPHONY_SPN_DISP_CONDITION, &retValue);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SPN_DISP_CONDITION api ret[%d], return value[%d] ",ret_val,retValue);
-               apiRet = 0;
-               retValue = 0;
-
-               spnName = vconf_get_str(VCONFKEY_TELEPHONY_SPN_NAME);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SPN_NAME:[%s] ",spnName);
-
-               nwName = vconf_get_str(VCONFKEY_TELEPHONY_NWNAME);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_NWNAME:[%s] ",nwName);
-
-               imei = vconf_get_str(VCONFKEY_TELEPHONY_IMEI);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_IMEI:[%s] ",imei);
-
-               szImei = vconf_get_str(SZ_IMEI);
-               TEST_DEBUG("SZ_IMEI:[%s] ",szImei);
-
-               szSubNum= vconf_get_str(VCONFKEY_TELEPHONY_SUBSCRIBER_NUMBER);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SUBSCRIBER_NUMBER:[%s] ",szSubNum);
-
-               szSubName= vconf_get_str(VCONFKEY_TELEPHONY_SUBSCRIBER_NAME);
-               TEST_DEBUG("VCONFKEY_TELEPHONY_SUBSCRIBER_NAME:[%s] ",szSubName);
-       }
-
-       if( memcmp(buf,"q",sizeof("q")-1) == 0 )
-       {
-               return -1;
-       }
-
-       return 0;
-}
-
-
-
-void nw_select_loop(int option)
-{
-       int ret;
-       fd_set readfds;
-
-       while (1) {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret) {
-
-                       if (FD_ISSET(0, &readfds)) {
-                               if(nw_read_key_input(option)<0)
-                                       break;
-                       }
-               }
-       }
-}
-
-void nw_test_thread_loop()
-{
-       TEST_DEBUG("start nw_test_thread_loop\n");
-       nw_select_loop(7);
-       fprintf(stderr," network exited\n");
-       pthread_exit(NULL);
-}
-
-int nw_test_subscribe_tapi_events()
-{
-       int i = 0;
-       int ret_val = TRUE;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       int NwEvtList[] =
-       {
-               TAPI_EVENT_NETWORK_GETNWBAND_CNF,
-               TAPI_EVENT_NETWORK_SETNWBAND_CNF,
-               TAPI_EVENT_NETWORK_GETSERVICEDOMAIN_CNF,
-               TAPI_EVENT_NETWORK_SETSERVICEDOMAIN_CNF,
-               TAPI_EVENT_NETWORK_CANCELMANUALSELECTION_CNF,
-               TAPI_EVENT_NETWORK_CANCELMANUALSEARCH_CNF,
-               TAPI_EVENT_NETWORK_GETNWORDER_CNF,
-               TAPI_EVENT_NETWORK_SETNWORDER_CNF,
-               TAPI_EVENT_NETWORK_GETNWMODE_CNF,
-               TAPI_EVENT_NETWORK_SETNWMODE_CNF,
-               TAPI_EVENT_NETWORK_SELECT_CNF,
-               TAPI_EVENT_NETWORK_SEARCH_CNF,
-               TAPI_EVENT_NETWORK_GETSELECTIONMODE_CNF,
-               TAPI_EVENT_NETWORK_GETPREFFEREDPLMN_CNF,
-               TAPI_EVENT_NETWORK_SETPREFFEREDPLMN_CNF,
-               TAPI_EVENT_NETWORK_GETPOWERONATTACH_CNF,
-               TAPI_EVENT_NETWORK_SETPOWERONATTACH_CNF,
-               TAPI_EVENT_NETWORK_LOCATIONCELLINFO_IND,
-               TAPI_EVENT_NETWORK_CHANGE_IND,
-               TAPI_EVENT_NETWORK_RADIO_INFO_IND,
-               TAPI_EVENT_NETWORK_SPN_INFO,
-               TAPI_EVENT_NETWORK_DISPLAYINFO_IND,
-               TAPI_EVENT_NETWORK_SEARCH_POPUP_ENABLE,
-               TAPI_EVENT_NETWORK_SEARCH_POPUP_DISABLE,
-               TAPI_EVENT_NETWORK_SET_ROAMING_MODE_CNF,
-               TAPI_EVENT_NETWORK_GET_ROAMING_MODE_CNF,
-               TAPI_EVENT_NETWORK_SET_CDMA_HYBRID_MODE_CNF,
-               TAPI_EVENT_NETWORK_GET_CDMA_HYBRID_MODE_CNF,
-       };
-
-       iNumOfNwEvt = sizeof(NwEvtList)/sizeof(int);
-       TEST_DEBUG("Number of NW Event List to be registered: %d", iNumOfNwEvt);
-       NW_subscription_id = (unsigned int *)calloc(iNumOfNwEvt, sizeof(unsigned int));
-
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               for( i=0 ; i< iNumOfNwEvt; i++ )
-               {
-                       api_err = tel_register_event(NwEvtList[i], &NW_subscription_id[i],(TelAppCallback)&nw_async_event_callback, NULL);
-
-                       if(api_err != TAPI_API_SUCCESS)
-                       {
-                               TEST_DEBUG("isn't subscribed. sub id is [%d], api_err is [%d]\n", NW_subscription_id[i],api_err);
-                               ret_val = FALSE;
-                               break;
-                       }
-               }
-       }
-       else
-       {
-               TEST_DEBUG("tel_init() failed");
-       }
-       return ret_val;
-
-}
-
-
-int nw_test_unsubscribe_tapi_events(void)
-{
-       int i = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-       int ret_val = TRUE;
-
-       for(i=0;i<iNumOfNwEvt; i++){
-               api_err = tel_deregister_event(NW_subscription_id[i]);
-               if(api_err != TAPI_API_SUCCESS){
-                       TEST_DEBUG("tel_deregister_event isn't unsubscribed. sub id is [%d] api_err is [%d]\n",NW_subscription_id[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-
-       }
-       tel_deinit();
-       return ret_val;
-}
-
-void nw_main(int argc, char *argv[])
-{
-       int ret=0;
-       pthread_t network_thread_id;
-
-       TEST_DEBUG("===== Network_test  ver 1.01 =====\n");
-
-       ret = pthread_create(&network_thread_id, NULL, (void *)&nw_test_thread_loop, NULL);
-
-       if(ret != 0)
-       {
-               TEST_DEBUG( "Thread for TAPI Events Failed\n");
-       }
-
-       //nw_test_subscribe_tapi_events();
-
-       pthread_join(network_thread_id, NULL);
-}
-
-
diff --git a/src/test_apps/tapi_power_test.c b/src/test_apps/tapi_power_test.c
deleted file mode 100644 (file)
index d2decf8..0000000
+++ /dev/null
@@ -1,381 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <pthread.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <assert.h>
-#include <glib.h>
-#include <string.h>
-#include <unistd.h>
-
-#include "TapiCommon.h"
-#include "ITapiPower.h"
-#include "TelDisplay.h"
-#include "TapiEvent.h"
-
-#define TEST_DEBUG(frmt, args...)      \
-{do { fprintf(stderr, "[Pow Test][%s:%04d] "frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-
-#ifndef false
-#define false 0
-#endif
-#ifndef true
-#define true  !0
-#endif
-#ifndef bool
-#define bool  char
-#endif
-
-#define        NUM_OF_POWER_EVENT                      4
-
-static unsigned int power_subscription_id[NUM_OF_POWER_EVENT] = {0, };
-
-static unsigned int  display_subscription_id = 0;
-
-void __PrintBatteryStatus(void *pData)
-{
-       tapi_power_battery_status_level_t*  pBattLevel;
-
-       pBattLevel = (tapi_power_battery_status_level_t*)pData;
-       switch(*pBattLevel){
-               case TAPI_POWER_BATT_STAT_POWER_OFF_LEVEL:
-                       TEST_DEBUG("Battery Level  [Power Off]");
-                       break;
-               case TAPI_POWER_BATT_STAT_CRIT_LOW_LEVEL:
-                       TEST_DEBUG("Battery Level [Critical-Low]");
-                       break;
-               case TAPI_POWER_BATT_STAT_LOW_LEVEL:
-                       TEST_DEBUG("Battery Level [Low Battery]");
-                       break;
-               case TAPI_POWER_BATT_STAT_NORMAL_LEVEL:
-                       TEST_DEBUG("Battery Level [Normal Level]");
-                       break;
-               default:
-                       TEST_DEBUG("Unknown Battery Level");
-                       break;
-       }
-
-       return;
-}
-
-void __PrintFlightModeStatus(void *pData)
-{
-       tapi_power_flight_mode_resp_type_t*  pFlightStatus;
-
-       pFlightStatus = (tapi_power_flight_mode_resp_type_t *)pData;
-
-       switch(*pFlightStatus){
-               case TAPI_POWER_FLIGHT_MODE_RESP_ON:
-                       TEST_DEBUG("Flight Mode  [On]");
-                       break;
-               case TAPI_POWER_FLIGHT_MODE_RESP_OFF:
-                       TEST_DEBUG("Flight Mode  [Off]");
-                       break;
-               case TAPI_POWER_FLIGHT_MODE_RESP_FAIL:
-                       TEST_DEBUG("Flight Mode  [Mode Change Fail]");
-                       break;
-               default:
-                       TEST_DEBUG("Unknown Flight Mode");
-                       break;
-       }
-       return;
-}
-
-void __PrintDisplayIconInfo(void *pData)
-{
-       tapi_display_icon_info_t*  pDisplayIcon = NULL;
-
-       pDisplayIcon = (tapi_display_icon_info_t*)pData;
-
-       switch(pDisplayIcon->rssi){
-               case TAPI_DISPLAY_RSSI_0:
-                       TEST_DEBUG("RSSI [0]");
-                       break;
-               case TAPI_DISPLAY_RSSI_1:
-                       TEST_DEBUG("RSSI [1]");
-                       break;
-               case TAPI_DISPLAY_RSSI_2:
-                       TEST_DEBUG("RSSI [2]");
-                       break;
-               case TAPI_DISPLAY_RSSI_3:
-                       TEST_DEBUG("RSSI [3]");
-                       break;
-               case TAPI_DISPLAY_RSSI_4:
-                       TEST_DEBUG("RSSI [4]");
-                       break;
-               case TAPI_DISPLAY_RSSI_5:
-                       TEST_DEBUG("RSSI [5]");
-                       break;
-               case TAPI_DISPLAY_RSSI_6:
-                       TEST_DEBUG("RSSI [6]");
-                       break;
-               default:
-                       TEST_DEBUG("Unknow RSSI Value");
-                       break;
-
-       }
-
-       switch(pDisplayIcon->batt){
-               case TAPI_POWER_PHONE_BATT_LEVEL0:
-                       TEST_DEBUG("Battery Level [0]");;
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL1:
-                       TEST_DEBUG("Battery Level [1]");
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL2:
-                       TEST_DEBUG("Battery Level [2]");
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL3:
-                       TEST_DEBUG("Battery Level [3]");
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL4:
-                       TEST_DEBUG("Battery Level [4]");
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL5:
-                       TEST_DEBUG("Battery Level [5]");
-                       break;
-               case TAPI_POWER_PHONE_BATT_LEVEL_INIT:
-                       TEST_DEBUG("Battery Level [Init]");
-                       break;
-               default:
-                       TEST_DEBUG("Unknow Battery Level Value");
-                       break;
-
-       }
-
-}
-
-void  power_async_event_callback(TelTapiEvent_t* event,void *data )
-{
-
-       TEST_DEBUG("$$$$$$ POWER EVENT NOTIFICATION $$$$$$");
-       TEST_DEBUG("Request ID : [0x%x]", event->RequestId);
-
-       switch(event->EventType)
-       {
-               case TAPI_EVENT_POWER_PHONE_OFF:
-                       TEST_DEBUG("Event Type: [TAPI_EVENT_POWER_PHONE_OFF]");
-                       break;
-               case TAPI_EVENT_POWER_BATT_STAT_IND:
-                       TEST_DEBUG("Event Type: [TAPI_EVENT_POWER_BATT_STAT_IND]");
-                       __PrintBatteryStatus(event->pData);
-                       break;
-               case TAPI_EVENT_POWER_FLIGHT_MODE_RESP:
-                       TEST_DEBUG("Event Type: [TAPI_EVENT_POWER_FLIGHT_MODE_RESP]");
-                       __PrintFlightModeStatus(event->pData);
-                       break;
-               case TAPI_EVENT_DISPLAY_ICON_INFO_IND:
-                       TEST_DEBUG("Event Type: [TAPI_EVENT_DISPLAY_ICON_INFO_IND]");
-                       __PrintDisplayIconInfo(event->pData);
-                       break;
-               default:
-                       TEST_DEBUG("Event Type: unknown event:[%d]", event->EventType);
-                       break;
-       }
-       TEST_DEBUG("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$");
-
-}
-
-
-int power_read_key_input(void)
-{
-       int ret;
-       char buf[512] = {0, };
-       char msg[512];
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-       memset(buf,0, sizeof(buf));
-       memset(msg,0,sizeof(msg));
-
-       printf("******* Power & Display Test MENU ******************\n");
-       printf("*************** Asynchronous API *****************\n");
-       printf("Power Off[PwrOff]\n");
-       printf("Power On[PwrOn]\n");
-       printf("Reset [Reset]\n");
-       printf("Flight Mode On[FlightModeOn]  \n");
-       printf("Flight Mode Off[FlightModeOff] \n");
-       printf("Reboot Modem[RebootModem] \n");
-       printf("Ramdump [Ramdump] \n");
-       printf("**************** Synchronous API *****************\n");
-       printf("Get Power status[GetPwrStatus] \n");
-       printf("Quit Power Test[quit] \n");
-       printf("************************************************\n");
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       if(strncmp(buf, "PwrOff", sizeof("PwrOff")-1) == 0)
-       {
-               ret_val = tel_process_power_command(TAPI_PHONE_POWER_OFF);
-               TEST_DEBUG("tel_process_power_command return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "PwrOn", sizeof("PwrOn")-1) == 0)
-       {
-               ret_val = tel_process_power_command(TAPI_PHONE_POWER_ON);
-               TEST_DEBUG("tel_process_power_command return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "Reset", sizeof("Reset")-1) == 0)
-       {
-               ret_val = tel_process_power_command(TAPI_PHONE_POWER_RESET);
-               TEST_DEBUG("tel_process_power_command return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "FlightModeOn", sizeof("FlightModeOn")-1) == 0)
-       {
-               ret_val = tel_set_flight_mode(TAPI_POWER_FLIGHT_MODE_ENTER);
-               TEST_DEBUG("tel_set_flight_mode return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "FlightModeOff", sizeof("FlightModeOff")-1) == 0)
-       {
-               ret_val = tel_set_flight_mode(TAPI_POWER_FLIGHT_MODE_LEAVE);
-               TEST_DEBUG("tel_set_flight_mode return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "RebootModem", sizeof("RebootModem")-1) == 0)
-       {
-               ret_val = tel_reset_modem();
-               TEST_DEBUG("tel_reset_modem return value is %d \n",ret_val);
-       }
-
-       else if(strncmp(buf, "Ramdump", sizeof("Ramdump")-1) == 0)
-       {
-               ret_val = tel_enforce_ramdump_of_modem();
-               TEST_DEBUG("tel_enforce_ramdump_of_modem return value is %d",ret_val);
-       }
-       else if(strncmp(buf, "quit", sizeof("quit")-1) == 0)
-       {
-               return -1;
-       }
-
-       memset(buf, 0, 512);
-
-       return 0;
-}
-
-
-void power_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-               {
-                       if (FD_ISSET(0, &readfds))
-                       {
-                               if(power_read_key_input() < 0)
-                                       break;
-                       }
-               }
-       }
-       return;
-}
-
-int power_test_unsubscribe_tapi_event(void)
-{
-       int i = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-       int ret_val = TRUE;
-
-       for(i=0;i<NUM_OF_POWER_EVENT; i++){
-               api_err = tel_deregister_event(power_subscription_id[i]);
-               if(api_err != TAPI_API_SUCCESS){
-                       TEST_DEBUG("tel_deregister_event isn't unsubscribed. sub id is %d api_err is %d\n",power_subscription_id[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-
-       }
-
-       tel_deinit();
-
-       return ret_val;
-}
-
-int power_test_subscribe_tapi_events (void)
-{
-       TEST_DEBUG("1");
-
-       int i = 0;
-       int ret_val = TRUE;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       int PowerEvtList[NUM_OF_POWER_EVENT] = {
-               TAPI_EVENT_POWER_PHONE_OFF,
-               TAPI_EVENT_POWER_BATT_STAT_IND,
-               TAPI_EVENT_POWER_FLIGHT_MODE_RESP,
-               TAPI_EVENT_POWER_SERVICE_READY_IND,
-       };
-
-       //TEST_DEBUG("########### Power TEST #############");
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               TEST_DEBUG("2");
-               for(i=0;i<NUM_OF_POWER_EVENT; i++){
-                       TEST_DEBUG("3");
-                       api_err = tel_register_event(PowerEvtList[i], &power_subscription_id[i],(TelAppCallback)&power_async_event_callback,NULL);
-                       TEST_DEBUG("4");
-
-                       if(api_err != TAPI_API_SUCCESS){
-                               TEST_DEBUG("tel_register_event isn't subscribed. sub id is %d api_err is %d\n",power_subscription_id[i],api_err);
-                               ret_val = FALSE;
-                               break;
-                       }
-               }
-
-               TEST_DEBUG("5");
-
-               api_err = tel_register_event(TAPI_EVENT_DISPLAY_ICON_INFO_IND, &display_subscription_id,(TelAppCallback)&power_async_event_callback,NULL);
-               TEST_DEBUG("6");
-               if(api_err != TAPI_API_SUCCESS){
-                       TEST_DEBUG("tel_register_event isn't subscribed. sub id is %d api_err is %d\n",display_subscription_id,api_err);
-                       ret_val = FALSE;
-               }
-       }
-       else {
-
-               TEST_DEBUG("tel_init() failed");
-       }
-       return ret_val;
-}
-
-int power_test_main(int argc, char *argv[])
-{
-       return 0;
-}
diff --git a/src/test_apps/tapi_ps_test.c b/src/test_apps/tapi_ps_test.c
deleted file mode 100644 (file)
index 54875c0..0000000
+++ /dev/null
@@ -1,535 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <unistd.h>
-#include <string.h>
-#include <assert.h>
-#include <glib.h>
-
-#include "ITapiPS.h"
-#include "TapiCommon.h"
-#include "TapiEvent.h"
-
-#define TEST_DEBUG(frmt, args...)      \
-{do { fprintf(stderr, "[PS Test][%s:%04d] "frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-#ifndef false
-       #define false 0
-#endif
-#ifndef true
-       #define true  !0
-#endif
-#ifndef bool
-       #define bool  char
-#endif
-
-int tapi_thread_id;
-//extern int EvtDeliveryHandle ;
-int request_id;
-int iNumOfPSEvt = 0;
-int error_code;
-static unsigned int * PS_subscription_id;
-
-// same as tapievent
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}data_t;
-
-
-void data_async_event_callback(TelTapiEvent_t* psEvent)
-{
-       if(psEvent->pData==NULL)
-       {
-               TEST_DEBUG("No Event Data!!");
-               return;
-       }
-
-       TEST_DEBUG("*************** Callback data **********************");
-       TEST_DEBUG("EventClass [%d],EventType [0x%x], Reques Id[%d], Event status [%d], psEvent->pDataLen[%d]",
-               psEvent->EventClass, psEvent->EventType, psEvent->RequestId, psEvent->Status,psEvent->pDataLen);
-
-       switch(psEvent->EventClass)
-       {
-               case TAPI_EVENT_CLASS_DATA:
-                       switch(psEvent ->EventType)
-                       {
-                               case TAPI_EVENT_PS_PDP_ACT_IPCONFIG_INFO:
-                                       {
-                                               tapi_ps_net_start_rsp_t  pdp_ip_resp ={0,};
-                                               memcpy(&pdp_ip_resp, psEvent->pData, sizeof(tapi_ps_net_start_rsp_t));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_PDP_ACT_IPCONFIG_INFO     ***************");
-                                               TEST_DEBUG("ERR:[%d]",pdp_ip_resp.err);
-                                               TEST_DEBUG("CONTEXT ID:[%d]",pdp_ip_resp.cont_id);
-                                               TEST_DEBUG("PDP INFO FIELD FLAG:[%d]",pdp_ip_resp.pdp_info.field_flag);
-                                               TEST_DEBUG("PDP INFO GATEWAY:[%d.%d.%d.%d]",pdp_ip_resp.pdp_info.gateway[0],pdp_ip_resp.pdp_info.gateway[1],pdp_ip_resp.pdp_info.gateway[2],pdp_ip_resp.pdp_info.gateway[3]);
-                                               TEST_DEBUG("PDP INFO IP ADDRESS:[%d.%d.%d.%d]",pdp_ip_resp.pdp_info.ip_address[0],pdp_ip_resp.pdp_info.ip_address[1],pdp_ip_resp.pdp_info.ip_address[2],pdp_ip_resp.pdp_info.ip_address[3]);
-                                               TEST_DEBUG("PDP INFO PRIMARY DNS:[%d.%d.%d.%d]",pdp_ip_resp.pdp_info.primary_dns[0],pdp_ip_resp.pdp_info.primary_dns[1],pdp_ip_resp.pdp_info.primary_dns[2],pdp_ip_resp.pdp_info.primary_dns[3]);
-                                               TEST_DEBUG("PDP INFO SECONDARY DNS:[%d.%d.%d.%d]",pdp_ip_resp.pdp_info.secondary_dns[0],pdp_ip_resp.pdp_info.secondary_dns[1],pdp_ip_resp.pdp_info.secondary_dns[2],pdp_ip_resp.pdp_info.secondary_dns[3]);
-                                               TEST_DEBUG("PDP INFO SUBNET MASK:[%d.%d.%d.%d]",pdp_ip_resp.pdp_info.subnet_mask[0],pdp_ip_resp.pdp_info.subnet_mask[1],pdp_ip_resp.pdp_info.subnet_mask[2],pdp_ip_resp.pdp_info.subnet_mask[3]);
-                                               TEST_DEBUG("PDP INFO DEVICE NAME:****[%s]****",pdp_ip_resp.devname);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_PDP_ACT_RSP:
-                                       {
-                                               tapi_ps_pdp_info_t  pdp_ip_resp ={0,};
-                                               memcpy(&pdp_ip_resp, psEvent->pData, sizeof(tapi_ps_pdp_info_t));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_PDP_ACT_RSP       ***************");
-                                               TEST_DEBUG("CONTEXT ID:[%d]",pdp_ip_resp.cont_id);
-                                               TEST_DEBUG("ERR:[0x%x](0:normal)",pdp_ip_resp.err);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_PDP_DEACT_RSP:
-                                       {
-                                               tapi_ps_pdp_info_t              stop_resp ={0,};
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_PDP_DEACT_RSP     ***************");
-                                               memcpy(&stop_resp, psEvent->pData, sizeof(tapi_ps_pdp_info_t));
-                                               TEST_DEBUG("CONTEXT ID:[%d]",stop_resp.cont_id);
-                                               TEST_DEBUG("ERR:[0x%x](0:normal)",stop_resp.err);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_PDP_DEACT_IND:
-                                       {
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_PDP_DEACT_IND     ***************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_CALL_STATISTICS:
-                                       {
-                                               tapi_ps_call_statistics_t  call_stats ={0,};
-                                               memcpy(&call_stats, psEvent->pData, sizeof(tapi_ps_call_statistics_t));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_CALL_STATISTICS   ***************");
-                                               TEST_DEBUG("CALL STATS FOR CONTEXT ID:[%d]",call_stats.cid);
-                                               TEST_DEBUG("CALL STATS RX BYTES:[%lu]",call_stats.rx);
-                                               TEST_DEBUG("CALL STATS TX BYTES:[%lu]",call_stats.tx);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_ERROR_IND:
-                                       {
-                                               tapi_gprs_error_info_t error_rsp ={0,};
-                                               memcpy(&error_rsp, psEvent->pData, sizeof(tapi_gprs_error_info_t));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_ERROR_IND ***************");
-                                               TEST_DEBUG("ERROR CAUSE:[%d]",error_rsp.cause);
-                                               TEST_DEBUG("ERROR TYPE:[%d]",error_rsp.type);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_HSDPA_STATUS_NOTI:
-                                       {
-                                               tapi_hspda_status_type hsdpa_status =0x00;
-                                               memcpy(&hsdpa_status, psEvent->pData, sizeof(tapi_hspda_status_type));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_HSDPA_STATUS_NOTI ***************");
-                                               TEST_DEBUG("HSDPA STATUS - (0 -INACTIVE)  (1 -ACTIVE)  (2 -SUSPEND)");
-                                               TEST_DEBUG("CURRENT HSDPA STATUS:[%d]",hsdpa_status);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_PS_BTDUN_PINCONTROL_NOTI:
-                                       {
-                                               tapi_ps_btdun_pincontrol pincontrol ={0,};
-                                               memcpy(&pincontrol, psEvent->pData, sizeof(tapi_ps_btdun_pincontrol));
-                                               TEST_DEBUG("**************      TAPI_EVENT_PS_BTDUN_PINCONTROL_NOTI     ***************");
-                                               TEST_DEBUG("SIGNAL :[%d]",pincontrol.signal);
-                                               TEST_DEBUG("STATUS:[%d]",pincontrol.status);
-                                               TEST_DEBUG("*******************************************************");
-                                       }
-                    break;
-
-                               default:
-                                       TEST_DEBUG("***  Default Event  psEvent ->EventType[0x%x] ****", psEvent ->EventType);
-                                       break;
-
-                       }
-
-                       break;
-
-
-               default:
-                       TEST_DEBUG("*** Other TAPI EVENT received : psEvent->EventClass : [0x%x] ****", psEvent->EventClass);
-                       break;
-
-       }
-
-}
-
-int data_test_subscribe_tapi_events()
-{
-       int i = 0;
-       int ret_val = TRUE;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-       int PSEvtList[] =
-       {
-               TAPI_EVENT_PS_PDP_ACT_RSP,
-               TAPI_EVENT_PS_PDP_DEACT_RSP,
-               TAPI_EVENT_PS_PDP_DEACT_IND,
-               TAPI_EVENT_PS_STATUS,
-               TAPI_EVENT_PS_CALL_STATISTICS,
-               TAPI_EVENT_PS_HSDPA_STATUS_NOTI,
-               TAPI_EVENT_PS_BTDUN_PINCONTROL_NOTI,
-               TAPI_EVENT_PS_PDP_ACT_IPCONFIG_INFO,
-               TAPI_EVENT_PS_ERROR_IND,
-               TAPI_EVENT_PS_EXTERNAL_CALL_IND,
-       };
-
-       iNumOfPSEvt = sizeof(PSEvtList)/sizeof(int);
-       TEST_DEBUG("Number of PS Event List to be registered: %d", iNumOfPSEvt);
-       PS_subscription_id = (unsigned int *)calloc(iNumOfPSEvt, sizeof(unsigned int));
-
-               if(tel_init() == TAPI_API_SUCCESS)
-               {
-                       for( i=0 ; i< iNumOfPSEvt; i++ )
-                       {
-                               api_err = tel_register_event(PSEvtList[i], &PS_subscription_id[i],(TelAppCallback)&data_async_event_callback,NULL);
-
-                               if(api_err != TAPI_API_SUCCESS)
-                               {
-                                       TEST_DEBUG("isn't subscribed. sub id is [%d], api_err is [%d]\n", PS_subscription_id[i],api_err);
-                                       ret_val = FALSE;
-                                       break;
-                               }
-                       }
-               }
-               else
-               {
-                       TEST_DEBUG("tel_init() failed");
-               }
-       return ret_val;
-
-}
-
-
-int data_test_unsubscribe_tapi_events(void)
-{
-       int i = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-       int ret_val = TRUE;
-
-       for(i=0;i<iNumOfPSEvt; i++){
-               api_err = tel_deregister_event(PS_subscription_id[i]);
-               if(api_err != TAPI_API_SUCCESS){
-                       TEST_DEBUG("tel_deregister_event isn't unsubscribed. sub id is [%d] api_err is [%d]\n",PS_subscription_id[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-       tel_deinit();
-       return ret_val;
-}
-
-
-void HandleGeneralResponseError(int error)
-{
-       if(error == 0x8000 || error == 0x8100)
-       {
-               TEST_DEBUG("!!Success!!");
-       }
-       else
-       {
-               TEST_DEBUG("!!Fail!! error value : 0x%x", error);
-       }
-}
-
-
-/*
-int get_handle()
-{
-    _handle = TapiRegisterClient(TAPI_EVENT_CLASS_DATA, app_callback, TRUE);
-
-    if( _handle == NULL )
-    {
-
-       TEST_DEBUG("handle get error");
-       return -1;
-    }
-
-    if(!ProtoMgrRegisterLPC())
-    {
-       TEST_DEBUG("LPC  get error - Call");
-       return -1;
-    }
-
-}
-
-
-
-// ravi 10 20 #add server die handler
-int read_phoneserver_pkt(void)
-{
-  int ret;
-
-  ret = lxt_callback(_handle);
-
-  if (ret == -1 )
-  {
-       TEST_DEBUG("Tapi Client: Phone Server Died, Exiting Gracefully");
-       exit(0);
-  }
-
-    return 0;
-}
-
-
-int call_quit(void)
-{
-       int result = 0;
-
-       if (!noti_finish(&error_code))
-       {
-               TEST_DEBUG( "Error: noti_finish() %d", error_code);
-       }
-       else
-       {
-               TEST_DEBUG("### noti was closed");
-       }
-
-       if (!TapiUnregisterClient(_handle))
-       {
-               TEST_DEBUG( "Error: TapiUnregisterClient failed");
-       }
-       else
-       {
-               TEST_DEBUG("### TapiUnregisterClient success");
-       }
-
-       return result;
-
-}
-
-*/
-
-
-int data_read_key_input(void)
-{
-       int ret;
-       char buf[256];
-//     char cid;
-       int requestId;
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-    ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                        perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-
-       TEST_DEBUG("Enter string in square braces: %s", buf);
-
-       TEST_DEBUG("################### PS TEST MENU    ###################");
-       TEST_DEBUG("gprs start          :       [start]");
-       TEST_DEBUG("pdp deactivate      :       [deact]");
-       TEST_DEBUG("BT PIN CTRL         :       [pinon]");
-       TEST_DEBUG("BT PIN CTRL         :       [pinoff]");
-       TEST_DEBUG("quit                :       [quit]");
-
-       TEST_DEBUG("######################################################\n");
-
-
-        if(strncmp(buf, "start", 5) == 0)
-        {
-               tapi_ps_net_start_req_t start_req;
-               int  ctxt_id;
-               memset(&start_req, 0, sizeof(tapi_ps_net_start_req_t));
-
-               TEST_DEBUG("ENTER Context id....");
-               scanf("%d", &ctxt_id);
-               start_req.cont_id = ctxt_id;
-               start_req.pdp_info.pdp_type = GPRS_PDP_TYPE_IP;
-
-               TEST_DEBUG("ENTER APN choice  1. [nate.sktelecom.com],   2. [annam.dyn], 3. [web.vodafone.de], 4. [airtelwap.es]");
-               scanf("%d", &ctxt_id);
-               if(ctxt_id == 1)
-                       strcpy(start_req.pdp_info.apn , "nate.sktelecom.com");
-               if(ctxt_id == 2)
-               {
-                       //strcpy(start_req.pdp_info.apn , "annam.dyn");
-                       strcpy(start_req.pdp_info.apn , "annah.dyn");
-                       //strcpy(start_req.pdp_info.dns1 , "10.8.15.249");
-                       //strcpy(start_req.pdp_info.dns2 , "10.8.15.250");
-                       //strcpy(start_req.pdp_info.password, "mms");
-                       //strcpy(start_req.pdp_info.username, "mms");
-               }
-               if(ctxt_id == 3)
-               {
-                       //strcpy(start_req.pdp_info.apn , "annam.dyn");
-                       strcpy(start_req.pdp_info.apn , "web.vodafone.de");
-                       //strcpy(start_req.pdp_info.dns1 , "10.8.15.249");
-                       //strcpy(start_req.pdp_info.dns2 , "10.8.15.250");
-                       //strcpy(start_req.pdp_info.password, "mms");
-                       //strcpy(start_req.pdp_info.username, "mms");
-               }
-               if(ctxt_id == 4)
-               {
-                       strcpy(start_req.pdp_info.apn, "airtelwap.es");
-               }
-
-               start_req.pdp_info.pdp_type= GPRS_PDP_TYPE_IP;
-
-               ret_val= tel_activate_gprs_pdp(&start_req,&requestId);
-               TEST_DEBUG(" API RETURN VAL:[%d]",ret_val);
-       }
-
-
-       else if(strncmp(buf, "deact", 5) == 0)
-       {
-               tapi_ps_net_stop_req_t stop_req;
-               memset(&stop_req, 0, sizeof(tapi_ps_net_stop_req_t));
-
-               TEST_DEBUG("ENTER Context id....");
-               int  ctxt_id;
-               scanf("%d", &ctxt_id);
-               stop_req.cont_id = ctxt_id;
-
-               ret_val=tel_deactivate_gprs_pdp(&stop_req,&requestId);
-               TEST_DEBUG(" API RETURN VAL:[%d]",ret_val);
-       }
-       else if(strncmp(buf, "pinon", 5) == 0)
-       {
-               tapi_ps_btdun_pincontrol pincontrol;
-
-               memset(&pincontrol, 0, sizeof(tapi_ps_btdun_pincontrol));
-
-               pincontrol.signal=GPRS_DATA_SIGNAL_DTR;
-               pincontrol.status=GPRS_SIGNAL_STATUS_ON;
-
-               ret_val=  tel_control_gprs_btdun_pin(pincontrol,&requestId);
-               TEST_DEBUG(" API RETURN VAL:[%d]",ret_val);
-       }
-       else if(strncmp(buf, "pinoff", 6) == 0)
-       {
-               tapi_ps_btdun_pincontrol pincontrol;
-
-               memset(&pincontrol, 0, sizeof(tapi_ps_btdun_pincontrol));
-
-               pincontrol.signal=GPRS_DATA_SIGNAL_DTR;
-               pincontrol.status=GPRS_SIGNAL_STATUS_OFF;
-
-               ret_val=  tel_control_gprs_btdun_pin(pincontrol,&requestId);
-               TEST_DEBUG(" API RETURN VAL:[%d]",ret_val);
-       }
-
-       /*      Go back to main Menu.   */
-       else if(strncmp(buf, "quit", 4) == 0)
-       {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu");
-               return -1;
-       }
-
-       memset(buf, '\0', 256);
-
-       return 0;
-
-}
-
-
-void data_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-
-    while (1)
-               {
-        FD_ZERO(&readfds);
-        FD_SET(0, &readfds);
-
-
-        ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-        if (ret) {
-
-           if (FD_ISSET(0, &readfds)) {
-                 if(data_read_key_input()<0)
-                       break;
-            }
-        }
-    }
-}
-
-
-
-void* data_test_thread_loop(void* data)
-{
-       TEST_DEBUG( " data_test_thread_loop : called...");
-
-       data_select_loop();
-
-       TEST_DEBUG(" data_test_thread_loop : stdin Loop exited");
-
-       pthread_exit(NULL);
-}
-
-
-int data_main(int argc, char *argv[])
-{
-
-//     int ret = 0;
-//     int count;
-       pthread_t  p_thread;
-
-//     ret = get_handle();
-
-
-       tapi_thread_id = pthread_create(&p_thread, NULL, data_test_thread_loop, NULL);
-
-       if(tapi_thread_id != 0)
-       {
-               TEST_DEBUG( "Failed while creating a thread to read from stdin");
-               return -1;
-       }
-       else
-       {
-               TEST_DEBUG( "a thread was created to read from stdin ..");
-       }
-
-       data_test_subscribe_tapi_events();
-
-       pthread_join(p_thread, NULL);
-
-       TEST_DEBUG("Exiting PS test program bye bye !");
-
-       return 0;
-
-}
-
diff --git a/src/test_apps/tapi_sat_test.c b/src/test_apps/tapi_sat_test.c
deleted file mode 100644 (file)
index 3878542..0000000
+++ /dev/null
@@ -1,1640 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <assert.h>
-#include <glib.h>
-
-#include "TelDefines.h"
-#include "ITapiCall.h"
-#include "ITapiSs.h"
-#include "TapiCommon.h"
-#include "TelSim.h"
-#include "TelErr.h"
-#include "TelSatEnvelope.h"
-#include "TelSatObj.h"
-#include "TelSatProactvCmd.h"
-#include "ITapiSat.h"
-#include "TelUtility_ext.h"
-#include "TelUtility.h"
-
-
-TS_UINT g_hCall;
-TelTapiCallInfo_t g_info;
-
-extern int EvtDeliveryHandle ;
-
-
-/***************************/
-int tapi_thread_id;
-
-int error_code;
-unsigned int curr_cmd = 0;
-
-tapi_simatk_select_item_ind_data_t sel_item_data;
-tapi_simatk_resp_data_t tr_data;
-
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}data_t;
-
-unsigned char *ptrEvnts[] = {
-"Telephony.Sat.UI.DisplayText",
-"Telephony.Sat.UI.GetInKey",
-"Telephony.Sat.UI.GetInputKey",
-"Telephony.Sat.UI.PlayTone",
-"Telephony.Sat.UI.Refresh",
-"Telephony.Sat.UI.SetUpMenu",
-"Telephony.Sat.UI.SelectItem",
-"Telephony.Sat.UI.SendSms",
-"Telephony.Sat.UI.SendSs",
-"Telephony.Sat.UI.SendUssd",
-"Telephony.Sat.UI.SetupCall",
-"Telephony.Sat.ProvideLocalInfo",
-"Telephony.Sat.SetupEventList",
-"Telephony.Sat.SetupIdelMode",
-"Telephony.Sat.UI.SendDtmf",
-"Telephony.Sat.Idle.LanguageNotification",
-"Telephony.Sat.UI.LaunchBrowser",
-"Telephony.Sat.UI.EndProacativeSession",
-"Telephony.Sat.Call.CallControlCnf",
-"Telephony.Sat.SMS.MoSmsControlCnf",
-"Telephony.Sat.SMS.Refresh",
-"Telephony.Sat.Phonebook.Refresh",
-"Telephony.Sat.Idle.Refresh",
-"Telephony.Sat.SMS.SendSms",
-"Telephony.Sat.Call.SetupCall",
-"Telephony.Sat.SS.SendSs",
-"Telephony.Sat.USSD.SendUssd",
-"Telephony.Sat.Idle.SetupText",
-"Telephony.Sat.DTMF.SendDtmf",
-"User.WapBrowser.ESimAtkOpenURL",
-"Telephony.Sat.UI.CmdProcEnd",
-"Telephony.Sat.MenuSelectionCnf",
-"Telephony.Sat.EventDownloadCnf"
-};
-
-
-
-int
-sat_util_pack_7bit( TS_BYTE* pOut, const char* szData, int in_len )
-{
-       int i;
-       int pos;
-       int shift = 0;
-
-       for( pos = 0, i = 0; /*pos < out_len_max &&*/ i < in_len; pos++, i++ )
-       {
-               /* pack the low bits */
-               pOut[pos] = szData[i] >> shift;
-
-               if ( i + 1 < in_len )
-               {
-                       /* pack the high bits using the low bits of the next character */
-                       pOut[pos] |= szData[i+1] << ( 7 - shift );
-
-                       shift++;
-
-                       if( shift == 7 )
-                       {
-                               shift = 0;
-                               i++;
-                       }
-               }
-       }
-
-       /* done */
-       return pos;
-}
-
-
-
-void
-test_send_tr(unsigned char gen_resp)
-{
-//Send TR
-       int ret;
-       unsigned char input;
-
-       tr_data.tr_data.display_txt.result.general_result = gen_resp;
-       tr_data.tr_data.display_txt.result.me_problem = 0x00;
-
-       switch(gen_resp)
-               {
-                       case 0x20:
-                       case 0x21:
-                       case 0x26:
-                       case 0x34:
-                       case 0x35:
-                       case 0x37:
-                       case 0x38:
-                       case 0x39:
-                       case 0x3a:
-                       case 0x3c:
-                       case 0x3d:
-                       {
-                               char scabuf[5] = {0};
-                               printf("additional response 0x00 ~ 0x0a:  0x\n");
-                               ret = read(0, scabuf, sizeof(scabuf));
-                               if (ret < 0)
-                               {
-                                       if (errno == EINTR)
-                                               perror("read(1)");
-                                       return -1;
-                               }
-                               else if (ret == 0)
-                                       return ret;
-
-                               input = (scabuf[0] -'0' )<< 4;
-                               input |= (scabuf[1]-'0')&0x0F;
-                               if(input >= 0x00 && input <= 0x3F)
-                               {
-                                       printf("additional response gen_resp 0x%x - add_resp 0x%x\n", gen_resp, input);
-                                       if(gen_resp == 0x39)
-                                       {
-                                               if(curr_cmd == TAPI_EVENT_SAT_UI_SEND_SS_IND)
-                                                       tr_data.tr_data.send_ss.additional_cc_problem_info = input;
-                                               else if(curr_cmd == TAPI_EVENT_SAT_UI_SEND_USSD_IND)
-                                                       tr_data.tr_data.send_ussd.additional_cc_problem_info = input;
-                                               else
-                                                       tr_data.tr_data.display_txt.result.me_problem = input;
-                                       }
-                                       else if(gen_resp == 0x34)
-                                               tr_data.tr_data.send_ss.additional_ss_problem_info = input;
-                                       else if(gen_resp == 0x37)
-                                               tr_data.tr_data.send_ussd.additional_ussd_problem_info = input;
-                                       else
-                                               tr_data.tr_data.display_txt.result.me_problem = input;
-                               }
-
-                       }
-
-                       default:
-                               break;
-               }
-
-       printf(" [SAT] : test_send_tr ::: send TR. command_number=%d, type=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type);
-       TelTapiSatSendUiUserConfirm(tr_data.command_number ,tr_data.command_type,SAT_ENGINE_USER_CONFIRM_YES,NULL,0);
-}
-
-
-/*
-void
-test_call_control(void)
-{
-       tapi_call_setup_info_t call;
-       unsigned short error;
-       tapi_call_handle  call_handle;
-       unsigned char num_dial[] = "+01234567890123456789";
-
-       call.call_type = TAPI_CALL_TYPE_VOICE;
-       memcpy(call.number,num_dial, sizeof(num_dial));
-       call.identity_mode = 0x01;
-       tapi_call_setup(&call, call_handle, &error);
-}
-*/
-
-void
-test_simatk_proactive_send_dtmf(tapi_simatk_send_dtmf_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : alpha_id present?= %d,  alphaID: %s\n",tst_data->alpha_id.is_present, tst_data->alpha_id.string);
-
-       printf(" [SAT] : DTMF STRING: len = %d, USSD string = %s\n", tst_data->dtmf_string.string_length, tst_data->dtmf_string.dtmf_tone);
-
-       if(tst_data->icon_id.is_present)
-               printf(" \n[SAT] : icon identifier: icon_id=%d, icon_qulaifier = 0x%x\n", tst_data->icon_id.icon_identifier, tst_data->icon_id.icon_qualifier);
-       else
-               printf(" \n[SAT] : icon NOT present\n");
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-}
-
-void
-test_simatk_proactive_play_tone(tapi_simatk_play_tone_ind_data_t* tst_data)
-{
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-       printf(" [SAT] : command qulaifier: Vibrate_alert 0=optional, 1=required, %d\n", tst_data->command_detail.u.cmd_quali_play_tone.vibrate_alert);
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-       printf(" [SAT] : alpha identifier: is_alpha_present=%d, rawdcs=0x%x, str_len=%d, string=%s\n", tst_data->alpha_id.is_present,
-                               tst_data->alpha_id.dcs.raw_dcs, tst_data->alpha_id.string_len, tst_data->alpha_id.string);
-
-       printf(" [SAT] : TONE: requested tone - 0x%02x\n", tst_data->tone.type);
-       printf(" [SAT] : DURATION: interval=0x%x, time unit=0x%x\n",tst_data->duration.time_interval,tst_data->duration.time_unit);
-       printf(" [SAT] : icon: is_icon_present=%d, icon id: %d\n",tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-}
-
-void
-test_simatk_proactive_get_input(tapi_simatk_get_input_ind_data_t* tst_data)
-{
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: is_using_alphabet_set (1=ys, 0=using digits) [%d]\n",tst_data->command_detail.u.cmd_quali_get_input.is_using_alphabet_set);
-
-       printf(" [SAT] : command qualifier: alpha_type = 0x%x, help info available? = %d\n",tst_data->command_detail.u.cmd_quali_get_input.alphabet_type, tst_data->command_detail.u.cmd_quali_get_input.is_help_info_available);
-
-       printf(" [SAT] : command qualifier: is_me_echo_user_input? [%d], unpacked data? [%d]\n",tst_data->command_detail.u.cmd_quali_get_input.is_me_echo_user_input, tst_data->command_detail.u.cmd_quali_get_input.is_user_input_unpacked_format);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : text-dcs: compressed?=%d, alpha_format=0x%x\n",tst_data->text.dcs.is_compressed_format, tst_data->text.dcs.alphabet_format);
-
-       printf(" [SAT] : text: string_length=%d, string=%s\n",tst_data->text.string_length, tst_data->text.string);
-
-       printf(" [SAT] : text: response length: min =%d, max=%d\n",tst_data->response_length.min, tst_data->response_length.max);
-
-       printf(" [SAT] : icon: is_icon_present=%d, icon id: %d\n",tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       printf(" [SAT] : Default Text: string length=%d\n",tst_data->default_text.string_length);
-
-       printf(" [SAT] : Default Text: dcs=0x%02x, default string: %s\n",tst_data->default_text.dcs.alphabet_format, tst_data->default_text.string);
-
-       if(!tst_data->command_detail.u.cmd_quali_get_input.is_user_input_unpacked_format)
-               tr_data.tr_data.get_input.text.dcs.alphabet_format = TAPI_SAT_ALPHABET_FROMAT_SMS_DEFAULT;
-       else
-               tr_data.tr_data.get_input.text.dcs.alphabet_format = TAPI_SIMATK_ALPHABET_FROMAT_8BIT_DATA;
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-
-               if(tst_data->icon_id.is_present)
-               tr_data.tr_data.get_input.result.general_result = TAPI_SAT_R_SUCCESS_BUT_REQUESTED_ICON_NOT_DISPLAYED;
-       else
-               tr_data.tr_data.get_input.result.general_result = 0x00;
-
-}
-
-void
-test_simatk_proactive_get_inkey(tapi_simatk_get_inkey_ind_data_t* tst_data)
-{
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: inkey_type 0== using character set, 1== yes/no type [%d]\n",tst_data->command_detail.u.cmd_quali_get_inkey.inkey_type);
-
-       printf(" [SAT] : command qualifier: use_alpha_set? [%d], is_help info available? [%d]\n",tst_data->command_detail.u.cmd_quali_get_inkey.is_using_alphabet_set, tst_data->command_detail.u.cmd_quali_get_inkey.is_help_info_available);
-
-       printf(" [SAT] : command qualifier: immideate response required? [%d], alphabet_type [%d]\n",tst_data->command_detail.u.cmd_quali_get_inkey.is_immediate_response_required, tst_data->command_detail.u.cmd_quali_get_inkey.alphabet_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : text-dcs: compressed?=%d, alpha_format=0x%x, msg_class=0x%x, raw_dcs=%d\n",tst_data->text.dcs.is_compressed_format, tst_data->text.dcs.alphabet_format,tst_data->text.dcs.msg_class, tst_data->text.dcs.raw_dcs);
-
-       printf(" [SAT] : text: string_length=%d, string=%s\n",tst_data->text.string_length, tst_data->text.string);
-
-       printf(" [SAT] : icon: is_icon_present=%d\n",tst_data->icon_id.is_present);
-
-       printf(" [SAT] : DURATION: interval=0x%x, time unit=0x%x\n",tst_data->duration.time_interval,tst_data->duration.time_unit);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-
-       if(tst_data->icon_id.is_present)
-               tr_data.tr_data.get_inkey.result.general_result = TAPI_SAT_R_SUCCESS_BUT_REQUESTED_ICON_NOT_DISPLAYED;
-       else
-               tr_data.tr_data.get_inkey.result.general_result = 0x00;
-}
-
-
-
-void
-test_simatk_event_download(tapi_simatk_event_download_type_t event)
-{
-       TelSatkEventDownloadData_t evt_dl;
-       int requestId = -1;
-
-       memset(&evt_dl, 0x00, sizeof(TelSatkEventDownloadData_t));
-
-       printf(" [SAT] : EVENT DOWNLOAD\n");
-
-       switch(event)
-       {
-               case TAPI_EVENT_SAT_DW_TYPE_IDLE_SCREEN_AVAILABLE:
-                       evt_dl.event_download_type = TAPI_EVENT_SAT_DW_TYPE_IDLE_SCREEN_AVAILABLE;
-                       break;
-
-               case TAPI_EVENT_SAT_DW_TYPE_USER_ACTIVITY:
-                       evt_dl.event_download_type = TAPI_EVENT_SAT_DW_TYPE_USER_ACTIVITY;
-                       break;
-
-               case TAPI_EVENT_SAT_DW_TYPE_LANGUAGE_SELECTION:
-                       {
-                               char scabuf[5] = {0};
-                               int ret = 0;
-
-                               printf(" en: english\n");
-                               printf(" de: german\n");
-                               ret = read(0, scabuf, sizeof(scabuf));
-                               if (ret < 0)
-                               {
-                                       if (errno == EINTR)
-                                               perror("read(1)");
-                                       return -1;
-                               }
-                               else if (ret == 0)
-                                       return ret;
-
-                               if(strncmp(scabuf, "en", 2) == 0)
-                                       evt_dl.u.language_selection_event_req_Data.language = TAPI_SAT_LP_ENGLISH;
-                               else
-                                       evt_dl.u.language_selection_event_req_Data.language = TAPI_SAT_LP_GERMAN;
-
-                       evt_dl.event_download_type = TAPI_EVENT_SAT_DW_TYPE_LANGUAGE_SELECTION;
-                       }
-                       break;
-
-               case TAPI_EVENT_SAT_DW_TYPE_BROWSER_TERMINATION:
-                       evt_dl.event_download_type = TAPI_EVENT_SAT_DW_TYPE_BROWSER_TERMINATION;
-                       evt_dl.u.browser_termination_event_req_Data.browser_termination_cause = TAPI_SAT_BROWSER_TERMINATED_BY_USER;
-                       break;
-
-               default:
-                       break;
-       }
-       TelTapiSatEventDownloadEnvelope(&evt_dl, &requestId);
-}
-
-void
-test_simatk_proactive_lang_noti(tapi_simatk_language_notification_ind_data_t* tst_data)
-{
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : command qualifier: language specified? = %d\n",tst_data->command_detail.u.cmd_quali_language_notification.bSpecificLanguageNotification);
-
-       if(tst_data->command_detail.u.cmd_quali_language_notification.bSpecificLanguageNotification)
-               printf(" [SAT] : command qualifier: language  = %d\n",tst_data->language.language);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-
-}
-
-void
-test_simatk_proactive_provide_local_info(tapi_simatk_provide_local_info_ind_data_t* tst_data)
-{
-
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : command qualifier: requested info = 0x%02x\n",tst_data->command_detail.u.cmd_quali_provide_local_info);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       //tr_data.tr_data.provide_loc_info.other_info = TRUE;
-       tr_data.tr_data.provide_loc_info.info_type = tst_data->command_detail.u.cmd_quali_provide_local_info;
-
-       if(tst_data->command_detail.u.cmd_quali_provide_local_info == TAPI_SIMATK_CMD_QUALI_PROVIDE_LANGUAGE_SETTING)
-       {
-               tr_data.tr_data.provide_loc_info.u.language_info.language = TAPI_SIMATK_LP_ENGLISH;
-       }
-       else if(tst_data->command_detail.u.cmd_quali_provide_local_info == TAPI_SIMATK_CMD_QUALI_PROVIDE_DATE_TIME_AND_TIME_ZONE)
-       {
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.year = 0x80;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.month = 0x50;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.day = 0x70;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.hour = 0x41;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.minute = 0x80;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.second = 0x71;
-               tr_data.tr_data.provide_loc_info.u.time_zone_info.time_zone = 0xFF;
-       }
-}
-
-void
-test_simatk_proactive_setup_idle_mode_text(tapi_simatk_setup_idle_mode_text_ind_data_t* tst_data)
-{
-
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : text-dcs: compressed?=%d, alpha_format=0x%x, msg_class=0x%x, raw_dcs=%d\n",tst_data->text.dcs.is_compressed_format, tst_data->text.dcs.alphabet_format,tst_data->text.dcs.msg_class, tst_data->text.dcs.raw_dcs);
-
-       printf(" [SAT] : text: string_length=%d, string=%s\n",tst_data->text.string_length, tst_data->text.string);
-
-       printf(" [SAT] : icon: is_icon_present=%d\n",tst_data->icon_id.is_present);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-}
-
-void
-test_simatk_proactive_display_text(tapi_simatk_display_text_ind_data_t* tst_data)
-{
-
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: clear=%d, priority=%d\n",tst_data->command_detail.u.cmd_quali_display_text.msg_clear,tst_data->command_detail.u.cmd_quali_display_text.msg_priority);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : text-dcs: compressed?=%d, alpha_format=0x%x, msg_class=0x%x, raw_dcs=%d\n",tst_data->text.dcs.is_compressed_format, tst_data->text.dcs.alphabet_format,tst_data->text.dcs.msg_class, tst_data->text.dcs.raw_dcs);
-
-       printf(" [SAT] : text: string_length=%d, string=%s\n",tst_data->text.string_length, tst_data->text.string);
-
-       printf(" [SAT] : icon: is_icon_present=%d\n",tst_data->icon_id.is_present);
-
-       printf(" [SAT] : DURATION: interval=0x%x, time unit=0x%x\n",tst_data->duration.time_interval,tst_data->duration.time_unit);
-
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-/*     tr_data.tr_data.display_txt.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.display_txt.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.display_txt.result.general_result);
-       tapi_simatk_send_terminal_response(&tr_data);*/
-
-}
-
-void
-test_simatk_send_menu_select_env(TS_BOOL help)
-{
-       TelSatMenuSelectionReqInfo_t env_data;
-       char str[5] = {0,0};
-       int item;
-       char scabuf[5] = {0};
-       int ret;
-       int requestId = -1;
-
-       ret = read(0, scabuf, sizeof(scabuf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       memcpy(str, scabuf, (strlen(scabuf)-1));
-
-               item = atoi(str);
-
-       env_data.item_identifier = item;
-       env_data.is_help_requested = help;
-       printf(" [SAT] : test_simatk_send_menu_select_env ::: MENU SELECT item_id= 0x%x, HELP?=%s\n",
-                                                               env_data.item_identifier,(env_data.is_help_requested)?"Reqd":"NOT Reqd");
-       TelTapiSatMenuSelectionEnvelope(&env_data, &requestId);
-}
-
-void
-test_simatk_proactive_refresh(tapi_simatk_refresh_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: REFRESH MODE=%d\n",tst_data->command_detail.u.cmd_quali_refresh);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : File Count=%d\n", tst_data->file_list.file_count);
-
-       printf(" [SAT] : file ids:");
-       for(i=0; i<tst_data->file_list.file_count;i++)
-               printf("\tfile_#[%d] = 0x%04x",i,tst_data->file_list.file_id[i]);
-
-       printf(" \n");
-
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       /*tr_data.tr_data.refresh.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.refresh.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.refresh.result.general_result);
-       tapi_simatk_send_terminal_response(&tr_data);*/
-}
-
-
-test_simatk_proactive_setup_menu(tapi_simatk_setup_menu_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: selection_pref=%d, help_info=%d\n",tst_data->command_detail.u.cmd_quali_setup_menu.selection_preference,tst_data->command_detail.u.cmd_quali_setup_menu.is_help_info_available);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : alpha identifier: is_alpha_present=%d, rawdcs=0x%x, str_len=%d, string=%s\n", tst_data->alpha_id.is_present,
-                               tst_data->alpha_id.dcs.raw_dcs, tst_data->alpha_id.string_len, tst_data->alpha_id.string);
-
-       printf(" [SAT] : items NAI: list count=%d \n [SAT] : items NAI:",tst_data->item_next_action_ind_list.list_count);
-       for(i=0; i<tst_data->item_next_action_ind_list.list_count;i++)
-               printf("\tnai_ind[%d] = 0x%02x",i, tst_data->item_next_action_ind_list.list[i]);
-
-       printf(" \n[SAT] : icon identifier: is icon present = %d\n",tst_data->icon_id.is_present);
-
-       printf(" [SAT] : setup menu: menu_count = %d\n",tst_data->menu_item_count);
-       for(i=0;i<tst_data->menu_item_count;i++)
-               printf("\tmenu_item[%d]= %s, [menu_item_id = %d]\n",i, tst_data->menu_item[i].text, tst_data->menu_item[i].item_id);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       /*tr_data.tr_data.setup_menu.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.setup_menu.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.setup_menu.result.general_result);
-       tapi_simatk_send_terminal_response(&tr_data);*/
-}
-
-void
-test_simatk_proactive_send_sms(tapi_simatk_send_sms_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : send sms :is_packing_by ME rquired%d\n",tst_data->command_detail.u.cmd_quali_send_sms.is_packing_by_me_required);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : send sms: alpha_id present?= %d,  icon present? = %d, icon_id=%d\n",tst_data->alpha_id.is_present, tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       printf(" [SAT] : send sms: ALPHA Len = %d, Alpha ID: %s\n",tst_data->alpha_id.string_len, tst_data->alpha_id.string);
-       printf(" [SAT] : send sms ADDRESS: ton=0x%x, npi=0x%x\n",tst_data->address.ton,tst_data->address.npi);
-
-       printf(" [SAT] : send sms ADDRESS: len = %d, dialling Number = %s\n", tst_data->address.dialling_number_length, tst_data->address.dialling_number);
-
-       printf(" [SAT] : send sms TPDU: len = %d, tpdu_data:\n",tst_data->sms_tpdu.data_length);
-       for(i=0;i<tst_data->sms_tpdu.data_length;i++)
-               printf("\t0x%02x",tst_data->sms_tpdu.data[i]);
-       printf("\n");
-
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       /*tr_data.tr_data.setup_event_list.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.setup_event_list.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.setup_event_list.result.general_result);
-       tapi_simatk_send_terminal_response(&tr_data);*/
-}
-
-void
-test_simatk_proactive_setup_evt_list(tapi_simatk_setup_event_list_ind_data_t* tst_data)
-{
-
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : setup menu: setup event count = %d\n",tst_data->event_list.event_list_count);
-       for(i=0;i<tst_data->event_list.event_list_count;i++)
-               printf("\t#[%d], [event = 0x%02x]\n",i+1, tst_data->event_list.list[i]);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       /*tr_data.tr_data.setup_event_list.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.setup_event_list.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.setup_event_list.result.general_result);
-       tapi_simatk_send_terminal_response(&tr_data);*/
-}
-
-void
-test_simatk_proactive_send_ussd(tapi_simatk_send_ussd_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : alpha_id present?= %d,  alphaID: %s\n",tst_data->alpha_id.is_present, tst_data->alpha_id.string);
-
-//     printf(" [SAT] : USSD STRING - DCS: alpha format=0x%x, compressed format?=0x%x\n",tst_data->ussd_string.dcs.alphabet_format,tst_data->ussd_string.dcs.is_compressed_format);
-
-       printf(" [SAT] : USSD STRING - DCS: Raw DCS =0x%x\n",tst_data->ussd_string.raw_dcs);
-
-       printf(" [SAT] : USSD STRING: len = %d, USSD string = \n", tst_data->ussd_string.ussd_string_length);
-
-       for(i=0;i<tst_data->ussd_string.ussd_string_length;i++)
-               printf(" 0x%02x\t",tst_data->ussd_string.ussd_string[i]);
-
-       printf(" \n[SAT] : icon identifier: is icon present = %d, icon_id=%d\n",tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-}
-
-void
-test_simatk_proactive_send_ss(tapi_simatk_send_ss_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : alpha_id present?= %d,  alphaID: %s\n",tst_data->alpha_id.is_present, tst_data->alpha_id.string);
-
-       printf(" [SAT] : SS STRING: ton=0x%x, npi=0x%x\n",tst_data->ss_string.ton,tst_data->ss_string.npi);
-
-       printf(" [SAT] : SS STRING: len = %d, ss string = %s\n", tst_data->ss_string.string_length, tst_data->ss_string.string);
-
-       printf(" \n[SAT] : icon identifier: is icon present = %d, icon_id=%d\n",tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-}
-
-void
-test_simatk_proactive_setup_call(tapi_simatk_setup_call_ind_data_t* tst_data)
-{
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : setup call :Qualifier = %d\n",tst_data->command_detail.u.cmd_quali_setup_call);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : user confirmation phase: alpha_id present?= %d,  alphaID: %s\n",tst_data->user_confirm_phase_alpha_id.is_present, tst_data->user_confirm_phase_alpha_id.string);
-
-       printf(" [SAT] : ADDRESS: ton=0x%x, npi=0x%x\n",tst_data->address.ton,tst_data->address.npi);
-
-       printf(" [SAT] : ADDRESS: len = %d, dialling Number = %s\n", tst_data->address.dialling_number_length, tst_data->address.dialling_number);
-
-       printf(" [SAT] : SUB ADDRESS: len = %d, data:\n",tst_data->sub_address.sub_address_len);
-       for(i=0;i<tst_data->sub_address.sub_address_len;i++)
-               printf("\t0x%02x",tst_data->sub_address.sub_address[i]);
-       printf("\n");
-
-       printf(" [SAT] : CCP: len = %d, data:\n",tst_data->ccp.data_length);
-       for(i=0;i<tst_data->ccp.data_length;i++)
-               printf("\t0x%02x",tst_data->ccp.data[i]);
-       printf("\n");
-
-       printf(" [SAT] : DURATION: interval=0x%x, time unit=0x%x\n",tst_data->duration.time_interval,tst_data->duration.time_unit);
-
-       printf(" [SAT] : call setup phase: alpha_id present?= %d,  alphaID: %s\n",tst_data->call_setup_phase_alpha_id.is_present, tst_data->call_setup_phase_alpha_id.string);
-
-       printf(" \n[SAT] : user confirmation phase - icon identifier: is icon present = %d, icon_id=%d\n",tst_data->user_confirm_phase_icon_id.is_present, tst_data->user_confirm_phase_icon_id.icon_identifier);
-
-       printf(" \n[SAT] : call setup phase - icon identifier: is icon present = %d, icon_id=%d\n",tst_data->call_setup_phase_icon_id.is_present, tst_data->call_setup_phase_icon_id.icon_identifier);
-
-       //Send TR
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       /*tr_data.tr_data.setup_event_list.result.general_result = TAPI_SIMATK_R_SUCCESS;
-       tr_data.tr_data.setup_event_list.result.me_problem = 0x00;
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.setup_event_list.result.general_result);
-       //tapi_simatk_send_terminal_response(&tr_data);*/
-}
-
-void
-test_simatk_proactive_select_item_list(tapi_simatk_select_item_ind_data_t* tst_data)
-{
-
-       int i;
-       printf(" [SAT] : command detail: command_num=%d, command_type=0x%x\n",tst_data->command_detail.command_number,tst_data->command_detail.command_type);
-
-       printf(" [SAT] : command qualifier: prez_type = %d, selection_pref=%d, help_info=%d\n",tst_data->command_detail.u.cmd_quali_select_item.presentation_type,
-               tst_data->command_detail.u.cmd_quali_select_item.selection_preference,tst_data->command_detail.u.cmd_quali_select_item.is_help_info_available);
-
-       printf(" [SAT] : device identity: src=0x%x, dest=0x%x\n",tst_data->device_identities.source,tst_data->device_identities.destination);
-
-       printf(" [SAT] : alpha identifier: is_alpha_present=%d, rawdcs=0x%x, str_len=%d, string=%s\n", tst_data->alpha_id.is_present,
-                               tst_data->alpha_id.dcs.raw_dcs, tst_data->alpha_id.string_len, tst_data->alpha_id.string);
-
-       printf(" [SAT] : items NAI: list count=%d \n [SAT] : items NAI:",tst_data->item_next_action_ind_list.list_count);
-       for(i=0; i<tst_data->item_next_action_ind_list.list_count;i++)
-               printf("\tnai_ind[%d] = 0x%02x",i, tst_data->item_next_action_ind_list.list[i]);
-
-       printf(" \n[SAT] : DEFAULT ITEM = %d\n",tst_data->default_item_identifier);
-       printf(" \n[SAT] : icon identifier: is icon present = %d, icon_id=%d\n",tst_data->icon_id.is_present, tst_data->icon_id.icon_identifier);
-
-       printf(" [SAT] : setup menu: item_count = %d\n",tst_data->menu_item_count);
-       for(i=0;i<tst_data->menu_item_count;i++)
-               printf("\tITEM#[%d]= %s, [item_id = %d]\n",i, tst_data->menu_item[i].text, tst_data->menu_item[i].item_id);
-
-       tr_data.command_number = tst_data->command_detail.command_number;
-       tr_data.command_type = tst_data->command_detail.command_type;
-       if(tst_data->command_detail.u.cmd_quali_select_item.is_help_info_available == TRUE)
-               tr_data.tr_data.select_item.item_identifier = 0x01;
-}
-
-void
-test_select_item_send_tr(void)
-{
-       tapi_simatk_resp_data_t tr_data;
-       char str[5] = {0,0};
-       int item;
-       int ret;
-       //Send TR
-       //if(item_id > '0' && item_id <= '9')
-       {
-       char scabuf[5] = {0};
-               ret = read(0, scabuf, sizeof(scabuf));
-               if (ret < 0)
-               {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               }
-               else if (ret == 0)
-                       return ret;
-               memcpy(str, scabuf, (strlen(scabuf)));
-               item = atoi(str);
-
-               if(item == 0)
-               {
-                       tr_data.tr_data.select_item.result.general_result = TAPI_SIMATK_R_PROACTIVE_SESSION_TERMINATED_BY_USER;
-                       tr_data.tr_data.select_item.other_info = FALSE;
-               }
-       /*      else if(sel_item_data.menu_item_count <  item )
-               {
-                       printf(" [SAT] : ***input should be between 1 & %d\n",sel_item_data.menu_item_count);
-                       tr_data.tr_data.select_item.result.general_result = TAPI_SIMATK_R_BACKWARD_MOVE_BY_USER;
-                       tr_data.tr_data.select_item.other_info = FALSE;
-
-               }*/
-               else
-               {
-                       tr_data.tr_data.select_item.result.general_result = TAPI_SIMATK_R_SUCCESS;
-                       tr_data.tr_data.select_item.other_info = TRUE;
-                       tr_data.tr_data.select_item.item_identifier = (unsigned char)item;
-               }
-       }
-       //else
-       //{
-       //      printf(" [SAT] : ***INCORRECT INPUT\n");
-       //              tr_data.tr_data.select_item.result.general_result = TAPI_SIMATK_R_PROACTIVE_SESSION_TERMINATED_BY_USER;
-       //              tr_data.tr_data.select_item.other_info = FALSE;
-       //}
-
-
-       tr_data.command_number = sel_item_data.command_detail.command_number;
-       tr_data.command_type = sel_item_data.command_detail.command_type;
-
-       tr_data.tr_data.select_item.result.me_problem = 0x00;
-
-       printf(" [SAT] : send TR. command_number=%d, type=0x%x, gen_result=0x%x, item_id=%d\n",
-                                                               tr_data.command_number, tr_data.command_type,
-                                                               tr_data.tr_data.select_item.result.general_result, item);
-       TelTapiSatSendUiUserConfirm(tr_data.command_number,tr_data.command_type,SAT_ENGINE_USER_CONFIRM_YES,&tr_data.tr_data.select_item.item_identifier,sizeof(TS_UINT8));
-}
-
-int isServerDied = 0;
-/********************************************************************************/
-
-
-int sat_read_key_input(void)
-{
-       char ch;
-       int ret;
-       char callId=0;
-       unsigned short len;
-       char buf[256];
-       char dtmfStr[16] = "1000103001";
-       char normal[16] = "0103001";
-
-
-
-
-
-    ret = read(0, buf, sizeof(buf));
-    if (ret < 0) {
-      if (errno == EINTR)
-      perror("read(1)");
-      return -1;
-    } else if (ret == 0) return ret;
-
-
-       printf("\n q : quit \n");
-       if(curr_cmd == TAPI_EVENT_SAT_SELECT_ITEM_IND)
-               printf(" si : select item terminal response \n");
-       if(curr_cmd == TAPI_EVENT_SAT_GET_INKEY_IND || curr_cmd == TAPI_EVENT_SAT_GET_INPUT_IND)
-       {
-               printf(" \"inkey\" or \"input\" : get inkey/input response \n");
-               printf(" \"tr\" : to send response other than success \n");
-       }
-       else if(curr_cmd != 0x00)
-               printf(" tr :Send TR for the current command = 0x%x \n",curr_cmd);
-       printf(" smhelp :  envelope cmd help \n");
-       printf(" sm :  envelope cmd select menu \n");
-       printf(" ed: event download\n");
-       printf(" cc: MO call control\n");
-
-       printf("--SAT_key_in : %s\n", buf);
-
-       if(strncmp(buf, "q", 1) == 0){
-               printf("### test program is terminated.\n");
-
-            return -1;
-      }
-
-       if(strncmp(buf, "tr", 2) == 0)
-       {
-               char scabuf[5] = {0};
-               unsigned char input=0x00;
-
-               printf("general response 0x00 ~ 0x3d:  0x\n");
-
-               ret = read(0, scabuf, sizeof(scabuf));
-               if (ret < 0)
-               {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               }
-               else if (ret == 0)
-                       return ret;
-
-               input = (scabuf[0] -'0' )<< 4;
-               input |= (scabuf[1]-'0')&0x0F;
-               if(input >= 0x00 && input <= 0x3d)
-                       test_send_tr(input);
-               else
-                       test_send_tr(0x00);
-       }
-
-
-       else if(strncmp(buf, "smhelp", 6) == 0)
-       {
-               printf("\n select menu for help: \n");
-               test_simatk_send_menu_select_env(TRUE);
-       }
-       else if(strncmp(buf, "sm", 2) == 0)
-       {
-               printf("\n select menu: \n");
-               test_simatk_send_menu_select_env(FALSE);
-       }
-
-       else if(strncmp(buf, "si", 2) == 0)
-       {
-               printf("\n select item: \n");
-               test_select_item_send_tr();
-       }
-       else if(strncmp(buf, "ed", 2) == 0)
-       {
-               char scabuf[5] = {0};
-               printf(" id : idle screen \n");
-               printf(" ua :  user activity \n");
-               printf(" ls: language selection\n");
-               printf(" bt: browser termination\n");
-               ret = read(0, scabuf, sizeof(scabuf));
-               if (ret < 0)
-               {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               }
-               else if (ret == 0)
-                       return ret;
-
-               if(strncmp(scabuf, "id", 2) == 0)
-                       test_simatk_event_download(TAPI_SIMATK_EVENT_DW_TYPE_IDLE_SCREEN_AVAILABLE);
-               else if(strncmp(scabuf, "ua", 2) == 0)
-                       test_simatk_event_download(TAPI_SIMATK_EVENT_DW_TYPE_USER_ACTIVITY);
-               else if(strncmp(scabuf, "ls", 2) == 0)
-                       test_simatk_event_download(TAPI_SIMATK_EVENT_DW_TYPE_LANGUAGE_SELECTION);
-               else if(strncmp(scabuf, "bt", 2) == 0)
-                       test_simatk_event_download(TAPI_SIMATK_EVENT_DW_TYPE_BROWSER_TERMINATION);
-               else
-                       printf("no such event\n");
-
-       }
-       else if((strncmp(buf, "inkey", 5) == 0) ||(strncmp(buf, "input", 5) == 0))
-       {
-               char scabuf[255] = {0};
-               printf(" ONly one character for INKEY, between min and max for INPUT: \n");
-               printf(" plz read the command qualifier and provide the input accordingly... \n");
-               printf(" bk : backward move \n");
-               printf(" end :  end proactive session \n");
-               printf(" INKEY: y OR n: for yes or no input\n");
-               printf(" input char/string:\n");
-
-               ret = read(0, scabuf, sizeof(scabuf));
-               if (ret < 0)
-               {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               }
-               else if (ret == 0)
-                       return ret;
-
-               if((strncmp(scabuf, "y", 1) == 0) || (strncmp(scabuf, "n", 1) == 0))
-               {
-                       //tr_data.tr_data.get_inkey.result.general_result = 0x00;
-                       tr_data.tr_data.get_inkey.text.dcs.msg_class = TAPI_SIMATK_MSG_CLASS_RESERVED;
-                       tr_data.tr_data.get_inkey.text.dcs.alphabet_format = TAPI_SIMATK_ALPHABET_FROMAT_8BIT_DATA;
-                       tr_data.tr_data.get_inkey.text.string_length = 1;
-                       if(strncmp(scabuf, "y", 1) == 0)
-                               tr_data.tr_data.get_inkey.text.string[0] = 0x01; //buf[0];
-                       else
-                               tr_data.tr_data.get_inkey.text.string[0] = 0x00;
-                       tr_data.tr_data.get_inkey.text.string[1] = '\0';
-                       //test_send_tr(tr_data.tr_data.get_inkey.result.general_result);
-               }
-               else if(strncmp(scabuf, "bk", 2) == 0)
-               {
-                       tr_data.tr_data.get_inkey.result.general_result = 0x11;
-               }
-               else if(strncmp(scabuf, "end", 3) == 0)
-               {
-                       tr_data.tr_data.get_inkey.result.general_result = 0x10;
-               }
-               else
-               {
-                       if(strncmp(buf, "inkey", 5) == 0)
-                       {
-                               //tr_data.tr_data.get_inkey.result.general_result = 0x00;
-                               tr_data.tr_data.get_inkey.text.dcs.msg_class = TAPI_SIMATK_MSG_CLASS_RESERVED;
-                               tr_data.tr_data.get_inkey.text.dcs.alphabet_format = TAPI_SIMATK_ALPHABET_FROMAT_8BIT_DATA;
-                       tr_data.tr_data.get_inkey.text.string_length = 1;
-                               tr_data.tr_data.get_inkey.text.string[0] = scabuf[0]; //buf[0];
-                       tr_data.tr_data.get_inkey.text.string[1] = '\0';
-               }
-                       else
-                       {
-                               int i=0;
-
-                               //tr_data.tr_data.get_input.result.general_result = 0x00;
-                               tr_data.tr_data.get_input.text.dcs.msg_class = TAPI_SIMATK_MSG_CLASS_RESERVED;
-                               printf("inkey: input: %s\n",scabuf);
-                               while(scabuf[i] != 0xA)
-                               {
-                                       //printf("%c\n",scabuf[i]);
-                                       i++;
-                               }
-                               if(tr_data.tr_data.get_input.text.dcs.alphabet_format == TAPI_SIMATK_ALPHABET_FROMAT_SMS_DEFAULT)
-                               {
-                                       tr_data.tr_data.get_input.text.string_length = (TS_UINT8)sat_util_pack_7bit(tr_data.tr_data.get_input.text.string, &scabuf[0], i );
-                               }
-                               else
-                               {
-                                       tr_data.tr_data.get_input.text.string_length = i;
-                                       memcpy(tr_data.tr_data.get_input.text.string, &scabuf[0], tr_data.tr_data.get_input.text.string_length);
-                               }
-                       }
-               }
-
-               test_send_tr(tr_data.tr_data.get_inkey.result.general_result);
-       }
-       else if(strncmp(buf, "cc", 2) == 0)
-       {
-               char scabuf[25] = {0};
-               TelCallSetupParams_t si;
-
-               memset(&si, 0, sizeof(si));
-               si.CallType=TAPI_CALL_TYPE_VOICE;
-
-               printf("number to be dialled:\n");
-
-               ret = read(0, scabuf, sizeof(scabuf));
-               if (ret < 0)
-               {
-                       if (errno == EINTR)
-                               perror("read(1)");
-                       return -1;
-               }
-               else if (ret == 0)
-                       return ret;
-
-               memcpy(si.szNumber, &scabuf, strlen(scabuf));
-
-               si.IdentityMode = TAPI_CALL_IDENTITY_SHOW;              //default
-
-               printf("send the call make message to server....%s", si.szNumber);
-
-               //ret = tapi_call_setup(&si, &g_hCall);
-
-               printf(" after calling tapi_call_setup : g_hCall - %d", g_hCall);
-
-               printf(" Tapi return value is %d", ret);
-
-               if(ret)
-               {
-                       memcpy(&g_info.callNumber, si.szNumber, sizeof( si.szNumber));
-               }
-       }
-
-       /*
-       #if 0
-       if(strncmp(buf, "prof", 4) == 0){
-               test_simatk_profile_download();
-      } else if(strncmp(buf, "env", 3) == 0){
-               test_simatk_envelope_send();
-      } else if(strncmp(buf, "ed", 2) == 0){
-               test_simatk_event_send();
-      } else if(strncmp(buf, "sm", 2) == 0) {
-               scanf("%s", buf);
-
-               sendEnvelopeCmd_SetupMenu(FALSE, atoi(buf));
-       } else if(strncmp(buf, "si", 2) == 0) {
-               scanf("%s", buf);
-
-               sendTerminalResponse_SelectItem(0x00, TRUE, atoi(buf), 0, NULL);
-       }
-
-       #endif
-       */
-
-       if(strncmp(buf, "menu", 4) == 0)
-        {
-               printf("Finished Testing this module, Going back to Main Menu\n");
-               //call_test_exit();
-               return -1;
-               //exit(0);
-        }
-
-       memset(buf, '\0', 256);
-
-    return 0;
-}
-
-
-/********************************************************************************/
-static int  app_callback(TelTapiEventClass_t eventClass, TelTapiEventType_t    eventType, /*length*/int  param1,/*pDate*/void * param2)
-{
-       int i;
-       //unsigned char *buf= (unsigned char*) param2;
-
-       //unsigned char *count = buf;
-       int            loop_count;
-
-printf("\n [SAT] app_callback( eventType=0x%02x) \n", eventType);
-#if 0
-printf("   eventClass: %d, eventType: %d[%02x], paramLength = %d\n", eventClass, eventType, eventType, param1);
-
-       for( i=0; i<param1; i++ ) printf("[%02x] ", buf[i]);
-       printf("\n --------------- ------ \n");
-
-       #endif
-
-       switch(eventClass)
-       {
-               case TAPI_EVENT_CLASS_SAT:
-                       switch(eventType)
-                       {
-                               case TAPI_EVENT_SAT_END_PROACTIVE_SESSION_IND:
-                                       printf("[SAT]  TAPI_EVENT_SAT_END_PROACTIVE_SESSION_IND.\n");
-                                       break;
-
-                               case TAPI_EVENT_SAT_DISPLAY_TEXT_IND:
-                               {
-                                       tapi_simatk_display_text_ind_data_t  tst_data;
-                                       tapi_simatk_resp_data_t tr_data;
-                                       curr_cmd = eventType;
-
-                                       printf(" [SAT] TAPI_EVENT_SAT_DISPLAY_TEXT_IND: \n");
-                                       //test_display_text_data.data_len = param1;
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_display_text_ind_data_t));
-
-                                       test_simatk_proactive_display_text(&tst_data);
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SETUP_MENU_IND:
-                               {
-                                       tapi_simatk_setup_menu_ind_data_t  tst_data;
-                                       curr_cmd = eventType;
-
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SETUP_MENU_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_setup_menu_ind_data_t));
-
-                                       test_simatk_proactive_setup_menu(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_SIMATK_EVENT_SETUP_EVENT_LIST_IND:
-                               {
-                                       tapi_simatk_setup_event_list_ind_data_t tst_data;
-
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_SIMATK_EVENT_SETUP_EVENT_LIST_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_setup_event_list_ind_data_t));
-
-                                       test_simatk_proactive_setup_evt_list(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_REFRESH_IND:
-                               {
-                                       tapi_simatk_refresh_ind_data_t tst_data;
-
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_REFRESH_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_refresh_ind_data_t));
-
-                                       test_simatk_proactive_refresh(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_SELECT_ITEM_IND:
-                               {
-                                       printf(" [SAT] TAPI_EVENT_SAT_SELECT_ITEM_IND: \n");
-                                       memcpy(&sel_item_data, param2, sizeof(tapi_simatk_select_item_ind_data_t));
-                                       curr_cmd = eventType;
-                                       test_simatk_proactive_select_item_list(&sel_item_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SEND_SMS_IND:
-                               {
-                                       tapi_simatk_send_sms_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SEND_SMS_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_send_sms_ind_data_t));
-
-                                       test_simatk_proactive_send_sms(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SETUP_CALL_IND:
-                               {
-                                       tapi_simatk_setup_call_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SETUP_CALL_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_setup_call_ind_data_t));
-                                       test_simatk_proactive_setup_call(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SEND_SS_IND:
-                               {
-                                       tapi_simatk_send_ss_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SEND_SS_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_send_ss_ind_data_t));
-                                       test_simatk_proactive_send_ss(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SEND_USSD_IND:
-                               {
-                                       tapi_simatk_send_ussd_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SEND_USSD_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_send_ussd_ind_data_t));
-                                       test_simatk_proactive_send_ussd(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_GET_INKEY_IND:
-                                       {
-                                       tapi_simatk_get_inkey_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_GET_INKEY_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_get_inkey_ind_data_t));
-                                       test_simatk_proactive_get_inkey(&tst_data);
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_SAT_GET_INPUT_IND:
-                                       {
-                                       tapi_simatk_get_input_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_GET_INPUT_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_get_inkey_ind_data_t));
-                                       test_simatk_proactive_get_input(&tst_data);
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_SAT_PLAY_TONE_IND :
-                                       {
-                                       tapi_simatk_play_tone_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_PLAY_TONE_IND : \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_play_tone_ind_data_t));
-                                       test_simatk_proactive_play_tone(&tst_data);
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_SAT_UI_SEND_DTMF_IND:
-                                       {
-                                       tapi_simatk_send_dtmf_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_UI_SEND_DTMF_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_send_dtmf_ind_data_t));
-                                       test_simatk_proactive_send_dtmf(&tst_data);
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_SAT_SETUP_IDLE_MODE_TEXT_IND:
-                               {
-                                       tapi_simatk_setup_idle_mode_text_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_SETUP_IDLE_MODE_TEXT_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_setup_idle_mode_text_ind_data_t));
-                                       test_simatk_proactive_setup_idle_mode_text(&tst_data);
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SAT_PROVIDE_LOCAL_INFO_IND:
-                               {
-                                       tapi_simatk_provide_local_info_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_PROVIDE_LOCAL_INFO_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_provide_local_info_ind_data_t));
-                                       test_simatk_proactive_provide_local_info(&tst_data);
-                               }
-
-                                       break;
-
-                               case TAPI_EVENT_SAT_LANGUAGE_NOTIFICATION_IND:
-                               {
-                                       tapi_simatk_language_notification_ind_data_t tst_data;
-                                       curr_cmd = eventType;
-                                       printf(" [SAT] TAPI_EVENT_SAT_PROVIDE_LOCAL_INFO_IND: \n");
-                                       memcpy(&tst_data, param2, sizeof(tapi_simatk_language_notification_ind_data_t));
-                                       test_simatk_proactive_lang_noti(&tst_data);
-                               }
-
-                                       break;
-
-                               case TAPI_EVENT_SAT_CALL_CONTROL_IND:
-                               {
-                                       tapi_simatk_call_control_cnf_data_t cc_result;
-                                       int i;
-                                       memcpy(&cc_result, param2, sizeof(tapi_simatk_call_control_cnf_data_t));
-                                       printf(" [SAT] TAPI_EVENT_SAT_CALL_CONTROL_IND: \n");
-                                       curr_cmd = eventType;
-
-                                       printf(" [SAT] :  call type=0x%x, call control result: 0x%x\n",cc_result.call_type, cc_result.call_control_result);
-
-                                       printf(" [SAT] : alpha_present=%d, alpha_len=%d, alpha_text=%s\n",cc_result.alpha_identifier.is_present, cc_result.alpha_identifier.string_len, cc_result.alpha_identifier.string);
-
-                                       if(cc_result.call_control_result == SIMATK_CALL_CONTROL_R_ALLOWED_WITH_MOD)
-                                       {
-                                               if(cc_result.call_type == TAPI_SIMATK_CALL_TYPE_MO_VOICE)
-                                               {
-                                                       if(cc_result.u.voice_call_data.address.dialling_number_length > 0)
-                                                       {
-                                                               printf(" [SAT] : TON = 0x%x, NPI = 0x%x\n",cc_result.u.voice_call_data.address.ton, cc_result.u.voice_call_data.address.npi);
-                                                               printf(" [SAT] : ADDRESS: len=%d, value =", cc_result.u.voice_call_data.address.dialling_number_length);
-                                                               for(i=0; i<cc_result.u.voice_call_data.address.dialling_number_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.voice_call_data.address.dialling_number[i]);
-                                                       }
-
-                                                       if(cc_result.u.voice_call_data.sub_address.sub_address_len > 0)
-                                                       {
-                                                               printf(" [SAT] : SUBADDRESS: len=%d, value =", cc_result.u.voice_call_data.sub_address.sub_address_len);
-                                                               for(i=0; i<cc_result.u.voice_call_data.sub_address.sub_address_len;i++)
-                                                                       printf("\t0x%02x",cc_result.u.voice_call_data.sub_address.sub_address[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : SUBADDRESS NOT PRESENT ");
-
-                                                       printf(" [SAT] : BC REPEAT IND: %d", cc_result.u.voice_call_data.bc_repeat_indicator);
-
-                                                       if(cc_result.u.voice_call_data.ccp1.data_length > 0)
-                                                       {
-                                                               printf(" [SAT] : CCP1: len=%d, value =", cc_result.u.voice_call_data.ccp1.data_length);
-                                                               for(i=0; i<cc_result.u.voice_call_data.ccp1.data_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.voice_call_data.ccp1.data[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : CCP1 NOT PRESENT ");
-
-                                                       if(cc_result.u.voice_call_data.ccp2.data_length > 0)
-                                                       {
-                                                               printf(" [SAT] : CCP2: len=%d, value =", cc_result.u.voice_call_data.ccp2.data_length);
-                                                               for(i=0; i<cc_result.u.voice_call_data.ccp2.data_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.voice_call_data.ccp2.data[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : CCP2 NOT PRESENT ");
-                                               }
-                                               else
-                                               {
-                                                       if(cc_result.u.ss_data.ss_string.string_length > 0)
-                                                       {
-                                                               printf(" [SAT] : TON = 0x%x, NPI = 0x%x\n",cc_result.u.ss_data.ss_string.ton, cc_result.u.ss_data.ss_string.npi);
-                                                               printf(" [SAT] : ADDRESS: len=%d, value =", cc_result.u.ss_data.ss_string.string_length);
-                                                               for(i=0; i<cc_result.u.ss_data.ss_string.string_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.ss_data.ss_string.string[i]);
-                                                       }
-
-                                                       if(cc_result.u.ss_data.sub_address.sub_address_len > 0)
-                                                       {
-                                                               printf(" [SAT] : SUBADDRESS: len=%d, value =", cc_result.u.ss_data.sub_address.sub_address_len);
-                                                               for(i=0; i<cc_result.u.ss_data.sub_address.sub_address_len;i++)
-                                                                       printf("\t0x%02x",cc_result.u.ss_data.sub_address.sub_address[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : SUBADDRESS NOT PRESENT ");
-
-                                                       printf(" [SAT] : BC REPEAT IND: %d", cc_result.u.ss_data.bc_repeat_indicator);
-
-                                                       if(cc_result.u.ss_data.ccp1.data_length > 0)
-                                                       {
-                                                               printf(" [SAT] : CCP1: len=%d, value =", cc_result.u.ss_data.ccp1.data_length);
-                                                               for(i=0; i<cc_result.u.ss_data.ccp1.data_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.ss_data.ccp1.data[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : CCP1 NOT PRESENT ");
-
-                                                       if(cc_result.u.ss_data.ccp2.data_length > 0)
-                                                       {
-                                                               printf(" [SAT] : CCP2: len=%d, value =", cc_result.u.ss_data.ccp2.data_length);
-                                                               for(i=0; i<cc_result.u.ss_data.ccp2.data_length;i++)
-                                                                       printf("\t0x%02x",cc_result.u.ss_data.ccp2.data[i]);
-                                                       }
-                                                       else
-                                                               printf(" [SAT] : CCP2 NOT PRESENT ");
-                                               }
-                                       }
-                               }
-                                       break;
-                               case TAPI_EVENT_SAT_MO_SMS_CONTROL_IND:
-                               {
-                                       tapi_simatk_call_control_cnf_data_t sm_result;
-                                       int i;
-
-                                       memcpy(&sm_result, param2, sizeof(tapi_simatk_call_control_cnf_data_t));
-                                       printf(" [SAT] TAPI_EVENT_SAT_MO_SMS_CONTROL_IND: \n");
-                                       curr_cmd = eventType;
-
-                                       printf(" [SAT] :  call type=0x%x, MO SM control result: 0x%x\n",sm_result.call_type, sm_result.call_control_result);
-
-                                       printf(" [SAT] : alpha_present=%d, alpha_len=%d, alpha_text=%s\n",sm_result.alpha_identifier.is_present, sm_result.alpha_identifier.string_len, sm_result.alpha_identifier.string);
-
-                                       if(sm_result.u.sms_data.rp_dest_address.dialling_number_length > 0)
-                                       {
-                                               printf(" [SAT] : TON = 0x%x, NPI = 0x%x\n",sm_result.u.sms_data.rp_dest_address.ton, sm_result.u.sms_data.rp_dest_address.npi);
-
-                                               printf(" [SAT] :RPD ADDRESS: len=%d, value =", sm_result.u.sms_data.rp_dest_address.dialling_number_length);
-                                               for(i=0; i<sm_result.u.sms_data.rp_dest_address.dialling_number_length;i++)
-                                                       printf("\t0x%02x",sm_result.u.sms_data.rp_dest_address.dialling_number[i]);
-                                       }
-                                       else
-                                               printf("RP Dest Address Not Present");
-                                       printf(" \n");
-
-                                       if(sm_result.u.sms_data.tp_dest_address.dialling_number_length > 0)
-                                       {
-                                               printf(" [SAT] : TON = 0x%x, NPI = 0x%x\n",sm_result.u.sms_data.tp_dest_address.ton, sm_result.u.sms_data.tp_dest_address.npi);
-
-                                               printf(" [SAT] :TPD ADDRESS: len=%d, value =", sm_result.u.sms_data.tp_dest_address.dialling_number_length);
-                                               for(i=0; i<sm_result.u.sms_data.tp_dest_address.dialling_number_length;i++)
-                                                       printf("\t0x%02x",sm_result.u.sms_data.tp_dest_address.dialling_number[i]);
-                                       }
-                                       else
-                                               printf("TP Dest Address Not Present");
-                                       printf(" \n");
-                               }
-                                       break;
-
-                               default:
-                                       break;
-                               }
-
-
-                       break;
-               default:
-                       printf(" NOT a simatk event\n");
-                       break;
-
-       }
-printf("\n [SAT] end of app_callback(sat_test/main.c) \n");
-
-       return TRUE;
-
-}
-
-
-
-
-/*****************************************************************/
-
-void sat_select_loop(void)
-{
-    int ret;
-    fd_set readfds;
-//     fprintf(stderr,"sat Select Loop!\n");
-
-    while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-                ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-                {
-                    if (FD_ISSET(0, &readfds))
-                        {
-                             if(sat_read_key_input()<0)
-                                       break;
-                       }
-               }
-        }
-}
-
-void tapi_sat_thread()
-{
-    fprintf(stderr,"start tapi_sat_thread\n");
-       sat_select_loop();
-       fprintf (stderr, " sat exited\n");
-       pthread_exit(NULL);
-}
-
-bool on_simatk_event_received (EvtSysEventSourceId_t src_id, const char* noti_id, GArray* parameters, void* local_data)
-{
-       EvtSysEventProperty_t* e;
-       int len;
-       int reqid;
-       int status;
-       int group, type;
-
-       /*      Number of params must be 5      */
-       assert(parameters->len == 5);
-
-       /*      First param is  tapi event group   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 0);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       group = e->value.i;
-       printf("received group is :%d\n", group);
-
-       /*      First param is  tapi event type   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 1);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       type = e->value.i;
-       printf("received event type is :%d\n", type);
-
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 2);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       reqid = e->value.i;
-       printf("received Request ID is :%d\n", reqid);
-
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 3);
-       assert(e->type ==  DBUS_TYPE_INT32);
-       status = e->value.i;
-       printf("received STATUS is :%d\n", status);
-
-       /*      over allocate this after receiving the len  */
-       unsigned char *data;
-       unsigned char *result;
-       size_t  out_len;
-
-       /*      Get the tapi event data  here   */
-       e = &g_array_index (parameters, EvtSysEventProperty_t, 4);
-       assert(e->type == DBUS_TYPE_STRING);
-
-       data = e->value.i;
-
-       len = strlen(data);
-
-       printf("Decoding..\n");
-
-       result = TAPI_BASE64_DECODE(data, len, &out_len);
-
-       app_callback(group, type, len, result);
-       /*      clean the buffer        */
-//     memset(result2, NULL,  (sdata->len*2));
-
-       /* We've done with this notificaiton */
-       return true;
-
-}
-
-
-int sat_test_subscribe_tapi_events(void)
-{
-
-       //GMainLoop *mainloop;
-       data_t sdata;
-       noti_subscription_id_t subscription_id;
-       int count = 0;
-
-       /*
-       fprintf(stderr, " GMAIN LOOP\n");
-
-       if (! noti_init(&error_code))
-       {
-               fprintf(stderr, "Error x_noti_init():%#X \n", error_code);
-               return -1;
-       }
-       printf("receive_tapi_event: noti init success\n");
-
-       */
-       for(count =0;count<sizeof(ptrEvnts)/sizeof(*ptrEvnts);count++)
-       {
-               error_code = EvtSysEventSubscribe (
-                                                                                       EvtDeliveryHandle,
-                                                                                       ptrEvnts[count],                                /* notification ID */
-                                                                                       NULL,                                           /*      filter expression       */
-                                                                                       on_simatk_event_received,               /* notification handler */
-                                                                                       (void *)&sdata,                         /* local data */
-                                                                                       &subscription_id                        /* subscription ID */
-                                                                               );
-               if (error_code )
-               {
-                       fprintf(stderr, "Error x_noti_set_cb():%#X \n", error_code);
-               }
-               else
-                       fprintf(stderr, "SIMATK-not subscribe ok for [%d]\n", count);
-
-#if 0
-
-               if (! noti_subscribe (
-                               ptrEvnts[count],                                /* notification ID */
-                               NULL,                                           /*      filter expression       */
-                               on_simatk_event_received,               /* notification handler */
-                               (void *)&sdata,                         /* local data */
-                               &subscription_id,                               /* subscription ID */
-                               &error_code))
-               {
-                       fprintf(stderr, "Error x_noti_set_cb():%#X \n", error_code);
-               }
-               else
-                       fprintf(stderr, "SIMATK-not subscribe ok for [%d]\n", count);
-
-#endif
-       }
-
-/*
-       printf("receive_tapi_event: noti subscribe is success\n");
-
-       mainloop = g_main_loop_new (NULL, FALSE);
-
-       g_main_loop_run (mainloop);
-
-       printf("receive_tapi_event: finish\n");
-*/
-       return 0;
-
-
-}
-
-
-int sat_main(int argc, char *argv[])
-{
-       int ret=0;
-       pthread_t sat_thread_id;
-
-       printf("\n\n\n ===== SAT TEST main* =====\n");
-
-       //ret=get_handle();
-       //fprintf(stderr,"out of get handle\n");
-
-       ret = pthread_create(&sat_thread_id, NULL, &tapi_sat_thread, NULL);
-
-       if(ret != 0)
-       {
-               fprintf(stderr, "Thread for TAPI Events Failed\n");
-       }
-
-       sat_test_subscribe_tapi_events();
-
-       pthread_join(sat_thread_id, NULL);
-
-}
-
diff --git a/src/test_apps/tapi_sim_test.c b/src/test_apps/tapi_sim_test.c
deleted file mode 100644 (file)
index b84c57a..0000000
+++ /dev/null
@@ -1,3816 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-/* standard header files*/
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <fcntl.h>
-#include <string.h>
-#include <sys/stat.h>
-#include <unistd.h>
-#include <pthread.h>
-#include <linux/stat.h>
-#include <assert.h>
-
-/*Dbus header files*/
-#include <glib.h>
-
-#include "ITapiSim.h"
-#include "TelErr.h"
-#include "TapiCommon.h"
-#include "TelUtility.h"
-#include "TapiEvent.h"
-
-#define SIM_APPLICATION_ID  10
-#define _TAPI_DEBUG_ON_SCREEN_
-#define TEST_DEBUG(frmt, args...) \
-{do { fprintf(stderr, "[SIM Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-#ifndef false
-#define false 0
-#endif
-#ifndef true
-#define true  !0
-#endif
-#ifndef bool
-#define bool  char
-#endif
-
-//extern int EvtDeliveryHandle ;
-int request_id;
-int iNumOfSIMEvt = 0;
-int error_code;
-static unsigned int* SIM_subscription_id;
-
-void sim_async_event_callback(TelTapiEvent_t* sim_event);
-
-// same as tapievent
-typedef struct {
-       int group;
-       int type;
-       int ID;
-       int status;
-       void *dst;
-} data_t;
-
-int strlen2(register const char * s) {
-       int count = 0;
-       while (*s++)
-               count++;
-       return count;
-}
-
-int _fgets(register char * digit, int n) {
-
-       if (!fgets(digit, n, stdin)) {
-               return -1;
-       }
-       if (*(digit + (n = strlen2(digit) - 1)) ^ '\n') {
-               n = 0;
-               while (getchar() ^ '\n')
-                       n--;
-               if (n)
-                       return 1;
-
-               return 0;
-       } else
-               *(digit + n) = 0;
-       return 0;
-}
-
-TelSimPbFileType_t __InputStorageType() {
-       TelSimPbFileType_t storage_type = 0;
-
-       int iStorageType = 0;
-       char dummy = 0;
-
-       TEST_DEBUG(" storage types are below : ");
-       TEST_DEBUG(" 2 - Emergency numbers ");
-       TEST_DEBUG(" 3 - Fixed dialing numbers ");
-       TEST_DEBUG(" 4-  Last dialled numbers ");
-       TEST_DEBUG(" 8 - Own numbers ");
-       TEST_DEBUG(" 10 - 2G SIM numbers ");
-       TEST_DEBUG(" 11 - Service dialing numbers ");
-       TEST_DEBUG(" 12 - 3G SIM numbers ");
-       TEST_DEBUG(" 15 - Additional string numbers ");
-       TEST_DEBUG(" 16 - Grouping text string ");
-
-       TEST_DEBUG("Please input storage type: ");
-       scanf("%d%c", &iStorageType, &dummy);
-
-       switch (iStorageType) {
-       case 2: {
-               storage_type = TAPI_SIM_PB_EN;
-       }
-               break;
-
-       case 3: {
-               storage_type = TAPI_SIM_PB_FDN;
-       }
-               break;
-
-       case 4: {
-               storage_type = TAPI_SIM_PB_LDN;
-       }
-               break;
-
-       case 8: {
-               storage_type = TAPI_SIM_PB_MSISDN;
-       }
-               break;
-
-       case 10: {
-               storage_type = TAPI_SIM_PB_ADN;
-       }
-               break;
-
-       case 11: {
-               storage_type = TAPI_SIM_PB_SDN;
-       }
-               break;
-
-       case 12: {
-               storage_type = TAPI_SIM_PB_3GSIM;
-       }
-               break;
-
-       case 15: {
-               storage_type = TAPI_SIM_PB_AAS;
-       }
-               break;
-
-       case 16: {
-               storage_type = TAPI_SIM_PB_GAS;
-       }
-               break;
-
-       default: {
-               storage_type = TAPI_SIM_PB_UNKNOWNN;
-       }
-               break;
-       }
-       return storage_type;
-
-}
-
-void __PrintStorageType(TelSimPbFileType_t tSimPbFileType) {
-       switch (tSimPbFileType) {
-       case TAPI_SIM_PB_EN: {
-               TEST_DEBUG("TAPI_SIM_PB_EN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_FDN: {
-               TEST_DEBUG("TAPI_SIM_PB_FDN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_LDN: {
-               TEST_DEBUG("TAPI_SIM_PB_LDN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_MSISDN: {
-               TEST_DEBUG("TAPI_SIM_PB_MSISDN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_ADN: {
-               TEST_DEBUG("TAPI_SIM_PB_ADN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_SDN: {
-               TEST_DEBUG("TAPI_SIM_PB_SDN [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_3GSIM: {
-               TEST_DEBUG("TAPI_SIM_PB_3GSIM [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_AAS: {
-               TEST_DEBUG("TAPI_SIM_PB_AAS [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       case TAPI_SIM_PB_GAS: {
-               TEST_DEBUG("TAPI_SIM_PB_GAS [0x%x]", tSimPbFileType);
-       }
-               break;
-
-       default: {
-               TEST_DEBUG("Undefined Storage Type returnted [0x%x]", tSimPbFileType);
-       }
-               break;
-       }
-}
-
-void __PrintPbFiledType(TelSimPb3GFileType_t tSimPb3GFileType) {
-       switch (tSimPb3GFileType) {
-       case TAPI_PB_3G_NAME: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_NAME [0x%x]", tSimPb3GFileType);
-               break;
-       }
-
-       case TAPI_PB_3G_NUMBER: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_NUMBER [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_ANR: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_ANR [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_EMAIL: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_EMAIL [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_SNE: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_SNE [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_GRP: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_GRP [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_PBC: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_PBC [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_ANRA: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_ANRA [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       case TAPI_PB_3G_ANRB: {
-               TEST_DEBUG("PB Type: TAPI_PB_3G_ANRB [0x%x]", tSimPb3GFileType);
-               break;
-       }
-       default: {
-               TEST_DEBUG("PB Type: Undefined PB 3G File Type [0x%x]", tSimPb3GFileType);
-       }
-       }
-}
-
-#if 0
-void __PrintLockType(TelSimLockType_t tSimLockType)
-{
-       switch(tSimLockType)
-       {
-               case TAPI_SIM_LOCK_READY:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_READY [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PS:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PS (Phone-Sim Lock) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PF:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PF (Phone first SIM) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_SC:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_SC (PIN, PIN2, PUK, PUK2 Lock)  [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_FD:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_FD (FDN) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PN:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PN (Network Personalization) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PU:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PU (Network Subset Personalization) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PP:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PP (Service Provider Personalization) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_PC:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_PC (Corporate Personalization) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_SC2:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_SC2 (PIN2 Lock) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_SCPUK2:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_SCPUK2 (PIN2 Unblocking Key) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_LOCK_ACL:
-               TEST_DEBUG("Lock Type: TAPI_SIM_LOCK_ACL (ACL Lock) [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_NO_SIM:
-               TEST_DEBUG("Lock Type: TAPI_SIM_NO_SIM [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_UNAVAIL:
-               TEST_DEBUG("Lock Type: TAPI_SIM_UNAVAIL [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_INIT_COMPLETE:
-               TEST_DEBUG("Lock Type: TAPI_SIM_INIT_COMPLETE [0x%x]", tSimLockType);
-               break;
-               case TAPI_SIM_PB_INIT_COMPLETE:
-               TEST_DEBUG("Lock Type: TAPI_SIM_PB_INIT_COMPLETE [0x%x]", tSimLockType);
-               break;
-               default:
-               TEST_DEBUG("Lock Type: Undefined Lcok Type [0x%x]", tSimLockType);
-       }
-}
-
-void __PrintLockKey(TelSimLockKey_t tSimLockKey)
-{
-       switch(tSimLockKey)
-       {
-               case TAPI_SIM_LOCK_KEY_NOT_NEED:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_NOT_NEED [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_KEY_PIN:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_PIN [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_KEY_PUK:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_PUK [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_KEY_PIN2:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_PIN2 [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_KEY_PUK2:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_PUK2 [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_PERM_BLOCKED:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_PERM_BLOCKED [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_DISABLE:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_DISABLE [0x%x]", tSimLockKey);
-               break;
-               case TAPI_SIM_LOCK_KEY_SIMLOCK:
-               TEST_DEBUG(" Lock Key:  TAPI_SIM_LOCK_KEY_SIMLOCK [0x%x]", tSimLockKey);
-               break;
-               default:
-               TEST_DEBUG(" Lock Key:  Undefined Lock key [0x%x]", tSimLockKey);
-       }
-}
-#endif
-
-void __PrintCardStatus(char* str, TelSimCardStatus_t tSimCardStatus) {
-       switch (tSimCardStatus) {
-       case TAPI_SIM_STATUS_CARD_ERROR:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_CARD_ERROR [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_CARD_NOT_PRESENT:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_CARD_NOT_PRESENT [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_INITIALIZING:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_INITIALIZING [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_INIT_COMPLETED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_INIT_COMPLETED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_PIN_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_PIN_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_PUK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_PUK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_CARD_BLOCKED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_CARD_BLOCKED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_NCK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_NCK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_NSCK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_NSCK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_SPCK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_SPCK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_CCK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_CCK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_CARD_REMOVED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_CARD_REMOVED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       case TAPI_SIM_STATUS_SIM_LOCK_REQUIRED:
-               TEST_DEBUG("[%s]TAPI_SIM_STATUS_SIM_LOCK_REQUIRED [0x%x]", str, tSimCardStatus)
-               ;
-               break;
-       default:
-               TEST_DEBUG("[%s]Undefined Card Status [0x%x]", str, tSimCardStatus)
-               ;
-       }
-}
-
-void __PrintPinStatus(char* str, TelSimPinStatus_t tSimPinStatus) {
-       switch (tSimPinStatus) {
-       case TAPI_SIM_PIN_STATUS_DISABLED:
-               TEST_DEBUG("%sTAPI_SIM_PIN_STATUS_DISABLED [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-       case TAPI_SIM_PIN_STATUS_ENABLED:
-               TEST_DEBUG("%sTAPI_SIM_PIN_STATUS_ENABLED [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-       case TAPI_SIM_PIN_STATUS_BLOCKED:
-               TEST_DEBUG("%sTAPI_SIM_PIN_STATUS_BLOCKED [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-       case TAPI_SIM_PIN_STATUS_PUK_BLOCKED:
-               TEST_DEBUG("%sTAPI_SIM_PIN_STATUS_PUK_BLOCKED [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-       case TAPI_SIM_PIN_STATUS_UNKNOWN:
-               TEST_DEBUG("%sTAPI_SIM_PIN_STATUS_UNKNOWN [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-       default:
-               TEST_DEBUG("%sUndefined Pin Status [0x%x]", str, tSimPinStatus)
-               ;
-               break;
-
-       }
-}
-
-void __PrintCardType(char* str, TelSimCardType_t tSimCardType) {
-       switch (tSimCardType) {
-       case TAPI_SIM_CARD_TYPE_UNKNOWN:
-               TEST_DEBUG("%sTAPI_SIM_CARD_TYPE_UNKNOWN [0x%x]", str, tSimCardType)
-               ;
-               break;
-       case TAPI_SIM_CARD_TYPE_GSM:
-               TEST_DEBUG("%sTAPI_SIM_CARD_TYPE_GSM [0x%x]", str, tSimCardType)
-               ;
-               break;
-       case TAPI_SIM_CARD_TYPE_USIM:
-               TEST_DEBUG("%sTAPI_SIM_CARD_TYPE_USIM [0x%x]", str, tSimCardType)
-               ;
-               break;
-       default:
-               TEST_DEBUG("%sUndefined Card Type [0x%x]", str, tSimCardType)
-               ;
-       }
-}
-
-void __PrintECCSvcInfo(TelSimEccEmergencyServiceInfo_t tSimECCSvcInfo) {
-       switch (tSimECCSvcInfo) {
-       case TAPI_SIM_ECC_ESC_POLICE:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_POLICE [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       case TAPI_SIM_ECC_ESC_AMBULANCE:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_AMBULANCE [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       case TAPI_SIM_ECC_ESC_FIREBRIGADE:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_FIREBRIGADE [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       case TAPI_SIM_ECC_ESC_MARAINEGUARD:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_MARAINEGUARD [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       case TAPI_SIM_ECC_ESC_MOUTAINRESCUE:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_MOUTAINRESCUE [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       case TAPI_SIM_ECC_ESC_SPARE:
-               TEST_DEBUG("TAPI_SIM_ECC_ESC_SPARE [0x%x]", tSimECCSvcInfo)
-               ;
-               break;
-       default:
-               TEST_DEBUG("Undefined ECC Sercie Info [0x%x]", tSimECCSvcInfo)
-               ;
-       }
-}
-
-void __PrintUSTData(unsigned long UstLen, unsigned short UstData[]) {
-       int i = 0;
-       fprintf(stderr, "UST Data: ");
-       for (i = 0; i < UstLen; i++) {
-               fprintf(stderr, "0x%x ", UstData[i]);
-       }
-       fprintf(stderr, "\n");
-}
-
-#if 0
-void __PrintUSimSvcTable(TelUSimServiceTable_t tUSimSVCTable)
-{
-       TEST_DEBUG("-------- UST Table -------- (1: On, 0:Off)");
-       TEST_DEBUG("Local Phonebook [%d] ", tUSimSVCTable.bLocalPhoneBook);
-       TEST_DEBUG("FDN [%d] ", tUSimSVCTable.bFdn);
-       TEST_DEBUG("EXT2 [%d] ", tUSimSVCTable.bExtension2);
-       TEST_DEBUG("SDN [%d] ", tUSimSVCTable.bSdn);
-       TEST_DEBUG("EXT3 [%d] ", tUSimSVCTable.bExtension3);
-       TEST_DEBUG("BDN [%d] ", tUSimSVCTable.bBdn);
-       TEST_DEBUG("EXT4 [%d] ", tUSimSVCTable.bExtension4);
-       TEST_DEBUG("OUT Going Call Info. [%d] ", tUSimSVCTable.bOCIOCT);
-       TEST_DEBUG("Call control [%d] ", tUSimSVCTable.bUsimCallControl);
-       TEST_DEBUG("Added more Table as you need");
-       TEST_DEBUG("---------------------------");
-}
-
-void __PrintSimSvcTable(TelSimServiceTable_t tSimSVCTable)
-{
-       TEST_DEBUG("-------- UST Table --------");
-       TEST_DEBUG("FDN [%d] ", tSimSVCTable.bFdn);
-       TEST_DEBUG("EXT2 [%d] ", tSimSVCTable.bExtension2);
-       TEST_DEBUG("SDN [%d] ", tSimSVCTable.bSdn);
-       TEST_DEBUG("EXT3 [%d] ", tSimSVCTable.bExtension3);
-       TEST_DEBUG("BDN [%d] ", tSimSVCTable.bBdn);
-       TEST_DEBUG("EXT4 [%d] ", tSimSVCTable.bExtension4);
-       TEST_DEBUG("PIN1 Disable func. [%d] ", tSimSVCTable.bPIN1DisableFunction );
-       TEST_DEBUG("Adn [%d] ", tSimSVCTable.bAdn);
-       TEST_DEBUG("Added more Table as you need");
-       TEST_DEBUG("---------------------------");
-}
-#endif
-
-void __PrintSSTData(unsigned long SstLen, unsigned short SstData[]) {
-       int i = 0;
-       TEST_DEBUG("SST Data: ");
-       for (i = 0; i < SstLen; i++) {
-               fprintf(stderr, "0x%x ", SstData[i]);
-       }
-}
-
-void __PrintLangInfo(char *str, TelSimLanguagePreferenceCode_t tSimLP) {
-       switch (tSimLP) {
-       case TAPI_SIM_LP_GERMAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_GERMAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_ENGLISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_ENGLISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_ITALIAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_ITALIAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_FRENCH:
-               TEST_DEBUG("%s TAPI_SIM_LP_FRENCH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_SPANISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_SPANISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_DUTCH:
-               TEST_DEBUG("%s TAPI_SIM_LP_DUTCH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_SWEDISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_SWEDISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_DANISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_DANISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_PORTUGUESE:
-               TEST_DEBUG("%s TAPI_SIM_LP_PORTUGUESE", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_FINNISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_FINNISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_NORWEGIAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_NORWEGIAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_GREEK:
-               TEST_DEBUG("%s TAPI_SIM_LP_GREEK", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_TURKISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_TURKISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_HUNGARIAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_HUNGARIAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_POLISH:
-               TEST_DEBUG("%s TAPI_SIM_LP_POLISH", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_KOREAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_KOREAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_CHINESE:
-               TEST_DEBUG("%s TAPI_SIM_LP_CHINESE", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_RUSSIAN:
-               TEST_DEBUG("%s TAPI_SIM_LP_RUSSIAN", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_JAPANESE:
-               TEST_DEBUG("%s TAPI_SIM_LP_JAPANESE", str)
-               ;
-               break;
-
-       case TAPI_SIM_LP_LANG_UNSPECIFIED:
-       default:
-               TEST_DEBUG("%s Undefined Language Preference Code", str)
-               ;
-               break;
-       }
-}
-
-void __PrintPBResult(char *str, TelSimPbAccessResult_t tPBResult) {
-       switch (tPBResult) {
-       case TAPI_SIM_PB_SUCCESS:
-               TEST_DEBUG("%s TAPI_SIM_PB_SUCCESS", str)
-               ;
-               break;
-
-       case TAPI_SIM_PB_FAIL:
-               TEST_DEBUG("%s TAPI_SIM_PB_FAIL", str)
-               ;
-               break;
-
-       case TAPI_SIM_PB_INVALID_INDEX:
-               TEST_DEBUG("%s TAPI_SIM_PB_INVALID_INDEX", str)
-               ;
-               break;
-
-       case TAPI_SIM_PB_INVALID_NUMBER_LENGTH:
-               TEST_DEBUG("%s TAPI_SIM_PB_INVALID_NUMBER_LENGTH", str)
-               ;
-               break;
-
-       case TAPI_SIM_PB_INVALID_NAME_LENGTH:
-               TEST_DEBUG("%s TAPI_SIM_PB_INVALID_NAME_LENGTH", str)
-               ;
-               break;
-
-       case TAPI_SIM_PB_ACCESS_CONDITION_NOT_SATISFIED:
-               TEST_DEBUG("%s TAPI_SIM_PB_ACCESS_CONDITION_NOT_SATISFIED", str)
-               ;
-               break;
-
-       default:
-               TEST_DEBUG("%s Undefined PB Access Result", str)
-               ;
-               break;
-       }
-}
-
-void __PrintPBStorageList(char *str, TS_UINT16 StorageList) {
-       if (StorageList & (0x01 << TAPI_SIM_PB_FDN)) {
-               TEST_DEBUG("%s PB_FDN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_LDN)) {
-               TEST_DEBUG("%s PB_LDN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_MSISDN)) {
-               TEST_DEBUG("%s PB_MSISDN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_ADN)) {
-               TEST_DEBUG("%s PB_ADN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_SDN)) {
-               TEST_DEBUG("%s PB_SDN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_EN)) {
-               TEST_DEBUG("%s PB_EN is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_3GSIM)) {
-               TEST_DEBUG("%s PB_3GSIM is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_AAS)) {
-               TEST_DEBUG("%s PB_AAS is in the StorageList", str);
-       }
-
-       if (StorageList & (0x01 << TAPI_SIM_PB_GAS)) {
-               TEST_DEBUG("%s PB_GAS is in the StorageList", str);
-       }
-}
-
-#if 0
-TelSimReadFileRequestData_t __SelectBinary()
-{
-       int iSelect = 0;
-       TelSimReadFileRequestData_t ReadFileReqData = { {0,}};
-
-       ReadFileReqData.Offset = 0; /**< offset if read binary */
-
-       ReadFileReqData.FileType = TAPI_SIM_FTYPE_TRANSPARENT;
-       // if record
-       ReadFileReqData.RecordIndex =0; /**< record index if read record */
-       ReadFileReqData.RecordIndexFrom=0;
-       ReadFileReqData.RecordIndexTo=0;
-       ReadFileReqData.RecordMode=TAPI_SIM_RECORD_NONE; /**< record index if read record */
-
-       TEST_DEBUG("---- EF File List ----");
-       TEST_DEBUG("1: ICCID");
-       TEST_DEBUG("2: SPN");
-       TEST_DEBUG("----------------------");
-       TEST_DEBUG("Select EF File: ");
-
-       scanf("%d", &iSelect);
-       if(iSelect == 1)
-       {
-               ReadFileReqData.FileID.FileName = TAPI_SIM_EFILE_ICCID;
-               ReadFileReqData.DataLength = 0x0A; /* hard code 10 bytes */;
-       }
-       else if(iSelect == 2)
-       {
-               ReadFileReqData.FileID.FileName = TAPI_SIM_EFILE_SPN;
-               ReadFileReqData.DataLength = 17;
-       }
-       else if(iSelect == 2)
-       {
-               ReadFileReqData.FileID.FileName = TAPI_SIM_EFILE_LP;
-       }
-       else
-       {
-               TEST_DEBUG("Invalid Selection!");
-       }
-
-       return ReadFileReqData;
-
-}
-#endif
-
-/**
- * This function  is used for encoding a ASCII text into UNICODE text
- *
- * @return             This function returns a TRUE on Success and FALSE on failure
- * @param[in]          text_len -input text lenght
- * @param[in]          text_data - input text data
- * @param[in]  unicode_text_len - unicode converted tex lenght
- * @param[in]  unicode_text - unicode text
- * @Interface          Asynchronous.
- * @remark
- * @Refer
- */
-TS_BOOL __encode_text_unicode(char text_len, char *text_data,
-               char *unicode_text_len, char *unicode_text) {
-       int j, i;
-       i = j = 0;
-
-       if (text_len == 0) {
-               TEST_DEBUG("Unicode encoding failed - input text string length is 0!");
-               return FALSE;
-       }
-       /*UNicode conversion*/
-       /* a  = Ascii is 61 and in Unicode it is 0061 but modem expects 6100 */
-       for (j = 0, i = 0; i < text_len * 2; i++) {
-               unicode_text[i++] = text_data[j++];
-               unicode_text[i] = 0x00;
-       }
-       *unicode_text_len = text_len * 2;
-       return TRUE;
-
-}
-
-/**
- * This function  is used for encoding a ASCII text into GSM7 bit text
- *
- * @return             This function returns a TRUE on Success and FALSE on failure
- * @param[in]          text_len - input text lenght
- * @param[in]          text_data - input text data
- * @param[in]  out_len_max - gsm7bit converted text lenght
- * @param[in]  gsm7bit_text - gsm7bit converted tex data
- * @return             This function returns a TRUE on Success and FALSE on failure
- */
-TS_BOOL __encode_gsm_7_bit_chars(char text_len, const char* text_data,
-               char *out_len_max, char* gsm7bit_text) {
-       int i;
-       int pos;
-       TS_UINT16 shift = 0;
-
-       for (pos = 0, i = 0; i < text_len; pos++, i++) {
-               /* pack the low bits - for single char */
-               gsm7bit_text[pos] = text_data[i] >> shift;
-
-               if (i + 1 < text_len) {
-                       /* pack the high bits using the low bits of the next character */
-                       gsm7bit_text[pos] |= text_data[i + 1] << (7 - shift);
-
-                       shift++;
-
-                       if (shift == 7) {
-                               shift = 0;
-                               i++;
-                       }
-               }
-       }
-       *out_len_max = (text_len * 7) / 8;
-
-       /* done */
-       return pos;
-
-}
-
-/**
- * This function converts unicode to ascii text
- *
- * @return             This function returns a 1 on Success and -1 on failure
- * @param[in]          phone_pb_type
- * @Interface          Asynchronous.
- * @remark
- * @Refer
- */
-TS_BOOL __decode_unicode_to_asci_str(char text_len, char *text_data,
-               char *ascii_text_len, char *ascii_text) {
-       int i, j;
-       i = j = 0;
-       if (text_len == 0 || text_data == NULL || ascii_text == NULL) {
-               TEST_DEBUG("Unicode Decode Failed as text length is 0");
-               return FALSE;
-       }
-
-       if (0 != (text_len % 2)) {
-               TEST_DEBUG(" ##### Unicode decoding failed due to invalid text length [%d]", text_len );
-               return FALSE;
-       }
-
-       for (i = 0; i < text_len; i++) {
-               ascii_text[i] = text_data[j];
-               j = j + 2;
-       }
-       *ascii_text_len = (text_len / 2);
-       ascii_text[i] = '\0';
-       return TRUE;
-}
-
-int sim_test_subscribe_tapi_events() {
-       int i = 0;
-       int ret_val = TRUE;
-       TapiResult_t api_err = TAPI_API_SUCCESS;
-
-       int SIMEvtList[] = { TAPI_EVENT_SIM_PB_STORAGE_COUNT_CNF,
-                       TAPI_EVENT_SIM_PB_ENTRY_INFO_CNF,
-                       TAPI_EVENT_SIM_PB_ACCESS_READ_CNF,
-
-                       TAPI_EVENT_SIM_PB_UPDATE_CNF, TAPI_EVENT_SIM_PB_DELETE_CNF,
-                       TAPI_EVENT_SIM_STATUS_IND, TAPI_EVENT_SIM_FDN_STATUS_IND,
-
-                       TAPI_EVENT_SIM_PB_CAPABILITY_INFO_CNF,
-                       TAPI_EVENT_SIM_ISIM_AUTHENTICATION_CNF,
-                       TAPI_EVENT_SIM_SAP_CONNECT_NOTI, TAPI_EVENT_SIM_SAP_CONNECT_CNF,
-                       TAPI_EVENT_SIM_SAP_CONNECT_STATUS_CNF,
-                       TAPI_EVENT_SIM_SAP_TRANSFER_ATR_CNF,
-                       TAPI_EVENT_SIM_SAP_TRANSFER_APDU_CNF,
-                       TAPI_EVENT_SIM_SAP_SET_PROTOCOL_CNF,
-                       TAPI_EVENT_SIM_SAP_SET_SIM_POWER_CNF,
-                       TAPI_EVENT_SIM_SAP_CARD_READER_STATUS_CNF, TAPI_EVENT_SIM_APDU_CNF,
-                       TAPI_EVENT_SIM_ATR_CNF,
-
-                       TAPI_EVENT_SIM_GET_INDICATION_CNF,
-                       TAPI_EVENT_SIM_SET_INDICATION_CNF, TAPI_EVENT_SIM_GET_MAILBOX_CNF,
-                       TAPI_EVENT_SIM_SET_MAILBOX_CNF, TAPI_EVENT_SIM_SET_LANGUAGE_CNF,
-                       TAPI_EVENT_SIM_RSIM_ACCESS_CNF, TAPI_EVENT_SIM_VERIFY_SEC_CNF,
-                       TAPI_EVENT_SIM_VERIFY_PUK_CNF, TAPI_EVENT_SIM_CHANGE_PINS_CNF,
-                       TAPI_EVENT_SIM_DISABLE_SEC_CNF, TAPI_EVENT_SIM_ENABLE_SEC_CNF,
-                       TAPI_EVENT_SIM_DISABLE_FDNMODE_CNF,
-                       TAPI_EVENT_SIM_ENABLE_FDNMODE_CNF, TAPI_EVENT_SIM_PERS_STATUS_CNF,
-                       TAPI_EVENT_SIM_DISABLE_PERS_CNF, TAPI_EVENT_SIM_ENABLE_PERS_CNF };
-
-       iNumOfSIMEvt = sizeof(SIMEvtList) / sizeof(int);
-       TEST_DEBUG("Number of SIM Event List to be registered: %d", iNumOfSIMEvt);
-       //TAPI_CALLOC(SIM_subscription_id, iNumOfSIMEvt, unsigned int)
-       //#define TAPI_CALLOC(ptr, no_elements, type)   s
-       SIM_subscription_id = (unsigned int *) calloc(iNumOfSIMEvt,
-                       sizeof(unsigned int));
-       if (SIM_subscription_id == NULL) {
-               TEST_DEBUG("calloc error -NULL, errno is [%d]", errno);
-       }
-
-       for (i = 0; i < iNumOfSIMEvt; i++) {
-               api_err = tel_register_event(SIMEvtList[i], &SIM_subscription_id[i],
-                               (TelAppCallback) &sim_async_event_callback, NULL);
-
-               if (api_err != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("isn't subscribed. sub id is [%d], api_err is [%d]\n", SIM_subscription_id[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-
-}
-
-int sim_test_unsubscribe_tapi_events(void) {
-       int i = 0;
-       TapiResult_t api_err = TAPI_API_SUCCESS;
-       int ret_val = TRUE;
-
-       for (i = 0; i < iNumOfSIMEvt; i++) {
-               api_err = tel_deregister_event(SIM_subscription_id[i]);
-               if (api_err != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TelTapiDeRegister isn't unsubscribed. sub id is [%d] api_err is [%d]\n",SIM_subscription_id[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-
-       }
-
-       return ret_val;
-}
-
-void sim_async_event_callback(TelTapiEvent_t* sim_event)
-{
-       //int i;
-       //static unsigned int fileSize = 0;
-
-       TEST_DEBUG("Func Entrance");
-       TEST_DEBUG("Request ID : [0x%x]\n", sim_event->RequestId);
-
-       if (sim_event->pData == NULL) {
-               TEST_DEBUG("No Event Data!!");
-               //              return;
-       }
-
-       TEST_DEBUG("*************** Callback data **********************");
-       TEST_DEBUG("EventClass [%d],EventType [0x%x], Reques Id[%d], Event status [%d], sim_event->pDataLen[%d]",
-                       sim_event->EventClass, sim_event->EventType, sim_event->RequestId, sim_event->Status,sim_event->pDataLen);
-#if 0
-       if(sim_event->Status != TAPI_SIM_PB_SUCCESS)
-       {
-               __PrintPBResult("SIM Result", sim_event->Status);
-               TEST_DEBUG("TAPI Fail: EventStatus [%d]", sim_event->Status);
-               return;
-       }
-#endif
-
-       if (sim_event->EventClass == TAPI_EVENT_CLASS_SIM) {
-               switch (sim_event->EventType) {
-               case TAPI_EVENT_SIM_STATUS_IND: {
-                       TEST_DEBUG("***********TAPI_EVENT_SIM_STATUS_IND**************");
-
-                       //      TEST_DEBUG("Event status [%d]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_STATUS_CARD_ERROR) {
-                               TEST_DEBUG("SIM CARD ERROR");
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_CARD_NOT_PRESENT) {
-                               TEST_DEBUG("SIM CARD NOT INSERTED");
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_SIM_INITIALIZING) {
-                               TelSimCardType_t CardType =
-                                               *((TelSimCardType_t*) (sim_event->pData));
-
-                               TEST_DEBUG("SIM INITITIALIZING");
-                               __PrintCardType("CardType: ", CardType);
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_SIM_INIT_COMPLETED) {
-                               TEST_DEBUG("SIM INIT COMPLETED");
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_SIM_PIN_REQUIRED) {
-                               TEST_DEBUG("SIM PIN REQUIRED");
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_SIM_PUK_REQUIRED) {
-                               TEST_DEBUG("SIM PUK REQUIRED");
-                       } else if (sim_event->Status == TAPI_SIM_STATUS_CARD_BLOCKED) {
-                               TEST_DEBUG("SIM CARD BLOCKED");
-                       }
-                       TEST_DEBUG("********************************************");
-
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_CAPABILITY_INFO_CNF: {
-                       TEST_DEBUG("*****************TAPI_EVENT_SIM_PB_CAPABILITY_INFO_CNF***************************");
-
-                       //TEST_DEBUG("SIM PB Capability Info event status = [0x%x]", sim_event->Status);
-
-                       TelSimPbCapabilityInfo_t *sim_capability_info =
-                                       (TelSimPbCapabilityInfo_t*) sim_event->pData;
-
-                       int i;
-                       for (i = 0; i < sim_capability_info->FileTypeCount; i++) {
-                               __PrintPbFiledType(
-                                               sim_capability_info->FileTypeInfo[i].FileType3G);
-                               // TEST_DEBUG(" Filed tag type [%d]", sim_capability_info->FileTypeInfo[i].FileType3G);
-                               TEST_DEBUG(" max index [%d]", sim_capability_info->FileTypeInfo[i].PbIndexMax);
-                               TEST_DEBUG(" max entry [%d]", sim_capability_info->FileTypeInfo[i].PbTextMax);
-                               TEST_DEBUG(" used count [%d]", sim_capability_info->FileTypeInfo[i].TotalRecordCount);
-                       }
-
-                       TEST_DEBUG("****************************************************");
-
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_STORAGE_COUNT_CNF: {
-                       TEST_DEBUG("*****TAPI_EVENT_SIM_PB_STORAGE_COUNT_CNF*****");
-
-                       TelSimPbStorageInfo_t *storageInfo =
-                                       (TelSimPbStorageInfo_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM PB storage count event status = [0x%x]", sim_event->Status);
-
-
-                       __PrintStorageType(storageInfo->StorageFileType);
-                       //TEST_DEBUG("PB_STORAGE_TYPE 0x%x", storageInfo->StorageFileType);
-                       TEST_DEBUG("TOTAL_COUNT = %d", storageInfo->TotalRecordCount);
-                       TEST_DEBUG("USED_COUNT =  %d", storageInfo->UsedRecordCount);
-
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_ENTRY_INFO_CNF: {
-                       TEST_DEBUG("**********TAPI_EVENT_SIM_PB_ENTRY_INFO_CNF********");
-
-                       TelSimPbEntryInfo_t *entryInfo =
-                                       (TelSimPbEntryInfo_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM PB entry info event status = [0x%x]", sim_event->Status);
-
-                       //TEST_DEBUG("STORAGE TYPE [%d]", entryInfo->StorageFileType);
-                       __PrintStorageType(entryInfo->StorageFileType);
-                       TEST_DEBUG("PB_INDEX_MIN %d", entryInfo->PbIndexMin);
-                       TEST_DEBUG("PB_INDEX_MAX = %d", entryInfo->PbIndexMax);
-                       TEST_DEBUG("PB_NUM_LEN_MAX =  %d", entryInfo->PbNumLenMax);
-                       TEST_DEBUG("PB_TEXT_LEN_MAX =  %d", entryInfo->PbTextLenMax);
-
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_ACCESS_READ_CNF: {
-                       TEST_DEBUG("*********TAPI_EVENT_SIM_PB_ACCESS_READ_CNF*********");
-
-                       //TEST_DEBUG("SIM PB access read event status = [0x%x]", sim_event->Status);
-
-                       TelSimPbRecordData_t *sim_acces_info =
-                                       (TelSimPbRecordData_t*) sim_event->pData;
-
-                       __PrintStorageType(sim_acces_info->StorageFileType);
-                       //TEST_DEBUG("storaget type is [0x%x]",sim_acces_info->StorageFileType);
-
-                       if (sim_event->Status != TAPI_SIM_PB_SUCCESS) {
-                               TEST_DEBUG(" SIM phone book access error [%d]", sim_event->Status);
-                               break;
-                       }
-
-                       int ascii_text_len = 0;
-                       char ascii_text[256] = { 0, };
-
-                       if (sim_acces_info->StorageFileType == TAPI_SIM_PB_EN
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_FDN
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_LDN
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_MSISDN
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_ADN
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_SDN) {
-                               TEST_DEBUG(" 2G Type SIM phone book access");
-                               TEST_DEBUG(" sim_acces_info->StorageFileType[%d](0-fdn,1-ldn,2-msisdn,3-adn,4-sdn,5-en), number[%s]",sim_acces_info->StorageFileType, (char *)sim_acces_info->ContactInfo.Pb2GData.Number);
-
-                               /* unicode decoding */
-                               if (sim_acces_info->ContactInfo.Pb2GData.NameEncryptType
-                                               == TAPI_SIM_TEXT_ENC_UCS2) {
-                                       TEST_DEBUG("Decoding UCS2 to ASCII");
-                                       if (FALSE
-                                                       == __decode_unicode_to_asci_str(
-                                                                       sim_acces_info->ContactInfo.Pb2GData.NameLen,
-                                                                       (char *) &sim_acces_info->ContactInfo.Pb2GData.Name,
-                                                                       (char *) &ascii_text_len, ascii_text)) {
-                                               TEST_DEBUG(" Deocing to ascii failed ");
-                                               break;
-                                       }
-                               } else if (sim_acces_info->ContactInfo.Pb2GData.NameEncryptType
-                                               == TAPI_SIM_TEXT_ENC_ASCII
-                                               || sim_acces_info->ContactInfo.Pb2GData.NameEncryptType
-                                                               == TAPI_SIM_TEXT_ENC_GSM7BIT) {
-                                       //TAPI_MEMCPY(ascii_text, sim_acces_info->ContactInfo.Pb2GData.Name, 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                       //#define TAPI_MEMCPY(dest , src , dest_len , src_len)
-                                       if (256 >= TAPI_SIM_NUM_TEXT_LEN_MAX) {
-                                               memcpy(ascii_text,
-                                                               sim_acces_info->ContactInfo.Pb2GData.Name,
-                                                               TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                       } else {
-                                               TEST_DEBUG("memcpy FAILURE - dest_len(%d) < src_len(%d)", 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                       }
-                               } else {
-                                       TEST_DEBUG("Name Encryption is not UCS2 / ASCII / unpacked GSM7bit");
-                                       break;
-                               }
-                               TEST_DEBUG("text[%s]", ascii_text);
-                       } else if (sim_acces_info->StorageFileType == TAPI_SIM_PB_3GSIM) {
-                               int i, k;
-                               int tmp_size;
-                               int num_of_pb_rec = 0;
-
-                               TEST_DEBUG(" sim_event->pDataLen [%d]",sim_event->pDataLen);
-                               TEST_DEBUG(" sizeof(TelSimPbRecordData_t)[%d]",sizeof(TelSimPbRecordData_t));
-                               TEST_DEBUG(" strlen(sim_event->pData)[%d]", strlen(sim_event->pData));
-
-                               num_of_pb_rec = (sim_event->pDataLen
-                                               / sizeof(TelSimPbRecordData_t));
-
-                               TEST_DEBUG("Number of Saved Records [%d]",num_of_pb_rec);
-
-                               char * temp = (char*) malloc(sim_event->pDataLen);
-                               memcpy(temp, (char*) sim_event->pData, sim_event->pDataLen);
-
-                               TelSimPbRecordData_t *sim_3g_access_info;
-
-                               for (k = 0; k < num_of_pb_rec; k++) {
-                                       tmp_size = k * sizeof(TelSimPbRecordData_t);
-                                       sim_3g_access_info = (TelSimPbRecordData_t*) (temp
-                                                       + tmp_size);
-
-                                       TEST_DEBUG("****************************************************");
-                                       TEST_DEBUG(" Record Num = [%d], index = [%d], next index = [%d] ",k , sim_3g_access_info->Index,sim_3g_access_info->NextIndex);
-
-                                       TEST_DEBUG(" Num of Fields = [%d]",sim_3g_access_info->ContactInfo.Pb3GData.FileTypeCount);
-                                       for (i = 0; i
-                                                       < sim_3g_access_info->ContactInfo.Pb3GData.FileTypeCount; i++) {
-                                               TEST_DEBUG("-------------------------------------");
-                                               TEST_DEBUG("Field_type = [%d], FiledLen = [%d]",
-                                                               sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType,
-                                                               sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength);
-
-                                               if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                               == TAPI_PB_3G_GRP) {
-                                                       int grp_index;
-                                                       TEST_DEBUG("Number of groups [%d]",sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength );
-
-                                                       for (grp_index = 0; grp_index
-                                                                       < (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength); grp_index++) {
-                                                               TEST_DEBUG(" Groupd Index [%d]",sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData[grp_index]); //ignore data_type byte
-
-                                                       }
-
-                                               } else if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                               == TAPI_PB_3G_NAME
-                                                               || sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                                               == TAPI_PB_3G_EMAIL
-                                                               || sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                                               == TAPI_PB_3G_SNE) {
-                                                       TEST_DEBUG("3G Name or Email or SNE");
-                                                       if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.EncryptionType
-                                                                       == TAPI_SIM_TEXT_ENC_UCS2) {
-                                                               TEST_DEBUG("EncryptionType: UCS2");
-                                                               if (FALSE
-                                                                               == __decode_unicode_to_asci_str(
-                                                                                               sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength,
-                                                                                               (char *) &sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                                                               (char *) &ascii_text_len,
-                                                                                               ascii_text)) {
-                                                                       TEST_DEBUG("Deocing ucs2 to ascii failed ");
-                                                                       break;
-                                                               }
-                                                       } else if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.EncryptionType
-                                                                       == TAPI_SIM_TEXT_ENC_ASCII) {
-                                                               TEST_DEBUG("EncryptionType: ASCII");
-                                                               //TAPI_MEMCPY(ascii_text, sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData, 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               //#define TAPI_MEMCPY(dest , src , dest_len , src_len)
-                                                               if (256 >= TAPI_SIM_NUM_TEXT_LEN_MAX) {
-                                                                       memcpy(
-                                                                                       ascii_text,
-                                                                                       sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                                                       TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               } else {
-                                                                       TEST_DEBUG("memcpy FAILURE - dest_len(%d) < src_len(%d)", 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               }
-
-                                                       } else if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.EncryptionType
-                                                                       == TAPI_SIM_TEXT_ENC_GSM7BIT) {
-                                                               TEST_DEBUG("EncryptionType: GSM7 bit");
-                                                               //TAPI_MEMCPY(ascii_text, sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData, 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               //#define TAPI_MEMCPY(dest , src , dest_len , src_len)
-                                                               if (256 >= TAPI_SIM_NUM_TEXT_LEN_MAX) {
-                                                                       memcpy(
-                                                                                       ascii_text,
-                                                                                       sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                                                       TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               } else {
-                                                                       TEST_DEBUG("memcpy FAILURE - dest_len(%d) < src_len(%d)", 256, TAPI_SIM_NUM_TEXT_LEN_MAX);
-                                                               }
-
-                                                       } else {
-                                                               TEST_DEBUG("Name Encryption is not UCS2 / ASCII / unpacked GSM7bit");
-                                                               break;
-                                                       }
-
-                                                       TEST_DEBUG("Field_data[%s]", ascii_text);
-
-                                               } else {
-                                                       TEST_DEBUG("Number Type[%d]", sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.NumType);
-                                                       TEST_DEBUG("AAS RecID [0x%x]", sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].AasRecordIdentifier);
-
-                                                       if (sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                                       == TAPI_PB_3G_ANR) {
-                                                               TEST_DEBUG("3G ANR Type");
-                                                       } else {
-                                                               TEST_DEBUG("3G Number Type");
-                                                       }
-                                                       TEST_DEBUG("Number_data[%s]",sim_3g_access_info->ContactInfo.Pb3GData.PbFileDataInfo[i].FileData);
-                                               }
-                                       }
-                               }
-
-                       } else if (sim_acces_info->StorageFileType == TAPI_SIM_PB_AAS
-                                       || sim_acces_info->StorageFileType == TAPI_SIM_PB_GAS) {
-                               TEST_DEBUG(" AAS and GAS");
-                               TEST_DEBUG(" index = [%d]",sim_acces_info->Index);
-                               __PrintStorageType(sim_acces_info->StorageFileType);
-                               TEST_DEBUG(" str len = [%d]",sim_acces_info->ContactInfo.PbAdditionalNumStringData.TextLength);
-                               TEST_DEBUG(" encrypt type = [%d]",sim_acces_info->ContactInfo.PbAdditionalNumStringData.EncryptionType);
-                               TEST_DEBUG(" string = [%s]",sim_acces_info->ContactInfo.PbAdditionalNumStringData.TextData);
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_UPDATE_CNF: {
-                       TEST_DEBUG("*****************TAPI_EVENT_SIM_PB_UPDATE_CNF***************************");
-
-                       TelSimPbUpdateResp_t *pUpdateResp =
-                                       (TelSimPbUpdateResp_t*) sim_event->pData;
-
-                       __PrintStorageType(pUpdateResp->PbStorageInfo.StorageFileType);
-                       TEST_DEBUG("Storage Info Total Record cnt [%d]", pUpdateResp->PbStorageInfo.TotalRecordCount);
-                       TEST_DEBUG("Storage File Used Record Cnt [%d]", pUpdateResp->PbStorageInfo.UsedRecordCount);
-                       //TEST_DEBUG(" Storage File Type [%d] ", pUpdateResp->PbStorageInfo.StorageFileType);
-                       TEST_DEBUG("Storage File Index [%d]", pUpdateResp->PbIndex);
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PB_DELETE_CNF: {
-                       TEST_DEBUG("*****************TAPI_EVENT_SIM_PB_DELETE_CNF***************************");
-
-                       TEST_DEBUG("SIM Delete PB event status = [0x%x]", sim_event->Status);
-
-                       TelSimPbUpdateResp_t *pDeleteResp =
-                                       (TelSimPbUpdateResp_t*) sim_event->pData;
-                       TEST_DEBUG(" Storage File Type [%d] ", pDeleteResp->PbStorageInfo.StorageFileType);
-                       TEST_DEBUG(" Storage File Index [%d]", pDeleteResp->PbIndex);
-
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_FDN_STATUS_IND: {
-                       TEST_DEBUG("*****************TAPI_EVENT_SIM_FDN_STATUS_IND***************************");
-
-                       TEST_DEBUG("SIM FDN status event status = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG("********************************************");
-
-               }
-                       break;
-
-                       /** will be tested later **/
-#if 1
-               case TAPI_EVENT_SIM_AUTHENTICATION_CNF: {
-                       TEST_DEBUG("*****************IMS Authentication **********************");
-#if 0
-                       TelSimAuthenticationResponse_t *auth_resp =
-                                       (TelSimAuthenticationResponse_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM ISIM authentication event status = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG(" auth resp data [%s]",auth_resp->ResponeData);
-                       TEST_DEBUG("  auth string [%s]",auth_resp->AuthenticationString);
-                       TEST_DEBUG(" auth cipher key [%s]",auth_resp->CipherKey);
-                       TEST_DEBUG(" auth integrity key [%s]",auth_resp->IntegrityKey);
-#endif
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_CONNECT_CNF: {
-                       TEST_DEBUG("*********** SAP CONNECT RESP *************");
-
-                       TelSimSapConnect_t *sap_conn_resp =
-                                       (TelSimSapConnect_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP connect request event status  = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG(" message id [0x%x]", sap_conn_resp->MsgId);
-                       TEST_DEBUG("connection status [0x%x] ", sap_conn_resp->ConnectionStatus);
-                       TEST_DEBUG("max message size [%d]", sap_conn_resp->MaxMsgSize);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_CONNECT_STATUS_CNF: {
-                       TEST_DEBUG("*********** SAP CONNECT STATUS *************");
-
-                       TEST_DEBUG("SIM SAP connect event status = [0x%x]", sim_event->Status);
-
-                       TelSimSapStatusInfo_t *sap_conn_status =
-                                       (TelSimSapStatusInfo_t*) sim_event->pData;
-                       TEST_DEBUG(" connection status info [0x%x]", *sap_conn_status);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_TRANSFER_ATR_CNF: {
-                       TEST_DEBUG("*********** SAP TRANSFER ATR *************");
-
-                       int i = 0;
-                       TelSimSapAtrInfo_t *sap_transfer_atr =
-                                       (TelSimSapAtrInfo_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP trasfer ATR event status  = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG(" ATR result [0x%x]", sap_transfer_atr->AtrResult);
-                       TEST_DEBUG(" ATR length [%lu]", sap_transfer_atr->AtrLength);
-                       TEST_DEBUG(" ATR data ---> " );
-                       for (i = 0; i < sap_transfer_atr->AtrLength; i++)
-                               TEST_DEBUG(" [0x%x]", sap_transfer_atr->AtrData[i]);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_TRANSFER_APDU_CNF: {
-                       TEST_DEBUG("*********** SAP TRANSFER APDU *************");
-
-                       int i = 0;
-                       TelSimSapApduData_t *sap_transfer_apdu =
-                                       (TelSimSapApduData_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP trasfer APDU event status  = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG(" APDU  length [0x%x]", sap_transfer_apdu->ApduLength);
-                       TEST_DEBUG(" APDU  data ---> " );
-                       for (i = 0; i < sap_transfer_apdu->ApduLength; i++)
-                               TEST_DEBUG(" [0x%x]", sap_transfer_apdu->Apdu[i]);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_SET_PROTOCOL_CNF: {
-                       TEST_DEBUG("*********** SAP SET PROTOCOL  *************");
-
-                       TelSimSapProtocol_t *sap_result_code =
-                                       (TelSimSapProtocol_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP set protocol event status  = [0x%x]", sim_event->Status);
-                       TEST_DEBUG("SAP SET protocol  result [0x%x]", *sap_result_code );
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_SET_SIM_POWER_CNF: {
-                       TEST_DEBUG("*********** SAP SET SIM POWER ON/OFF  *************");
-
-                       TelSimSapPower_t *sap_sim_power =
-                                       (TelSimSapPower_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP set SIM power  event status  = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG("message id [0x%x]", sap_sim_power->MsgId);
-                       TEST_DEBUG(" sim power on/off result [0x%x]", sap_sim_power->SimPowerResult);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SAP_CARD_READER_STATUS_CNF: {
-                       TEST_DEBUG("*********** SAP CARD READER STATUS *************");
-
-                       TelSimCardReaderStatus_t *sap_card_reader_status =
-                                       (TelSimCardReaderStatus_t*) sim_event->pData;
-
-                       TEST_DEBUG("SIM SAP card reader event status  = [0x%x]", sim_event->Status);
-
-                       TEST_DEBUG(" card reader result [0x%x] ", sap_card_reader_status->CardReaderResult);
-                       TEST_DEBUG(" card reader status bitwise encoded data [%d]", sap_card_reader_status->CardReaderStatus);
-
-                       TEST_DEBUG("*****************************************");
-               }
-                       break;
-#endif
-
-                       /******************************************************************************************************************************/
-                       /*                                                                              NEW EVENT                                                                               */
-                       /******************************************************************************************************************************/
-               case TAPI_EVENT_SIM_RSIM_ACCESS_CNF: {
-                       TEST_DEBUG("********NEW*TAPI_EVENT_SIM_RSIM_ACCESS_CNF**********");
-
-                       TelSimReadFileRaw_t * rsim_resp =
-                                       (TelSimReadFileRaw_t*) sim_event->pData;
-
-                       if (sim_event->Status == TAPI_SIM_ACCESS_SUCCESS) {
-                               TEST_DEBUG("rsim_resp->sw1[0x%x]", rsim_resp->sw1);
-                               TEST_DEBUG("rsim_resp->sw2[0x%x]", rsim_resp->sw2);
-                               TEST_DEBUG("rsim_resp->DataLen[%d]", rsim_resp->DataLen);
-                               TEST_DEBUG("rsim_resp->Data[%s]", rsim_resp->Data);
-                       } else {
-                               TEST_DEBUG("OPERATION FAILED");
-                       }
-
-                       TEST_DEBUG("********NEW*TAPI_EVENT_SIM_RSIM_ACCESS_CNF**********");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_VERIFY_SEC_CNF: {
-                       TEST_DEBUG("********NEW*TAPI_EVENT_SIM_VERIFY_SEC_CNF**********");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Verify PIN event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_OPERATION_TIMEOUT) {
-                               TEST_DEBUG("TAPI SIM Operation Timeout!!");
-                       } else if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("PIN1 Verification Success!");
-                               } else {
-                                       TEST_DEBUG("PIN2 Vefication Success!");
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PIN Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PUK Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("SIM Lock Verification Failed! - SIM Lock code Required");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_VERIFY_PUK_CNF: {
-                       TEST_DEBUG("**********NEW*TAPI_EVENT_SIM_VERIFY_PUK_CNF********");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Unblock PIN event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("Unblock PIN1 Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("Unblock PIN2 Success!");
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PIN Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PUK Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_CHANGE_PINS_CNF: {
-                       TEST_DEBUG("********NEW*TAPI_EVENT_SIM_CHANGE_PINS_CNF***************************");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Change PIN event status = [0x%x], pinType[%d]", sim_event->Status, pPinInfo->PinType);
-                       TEST_DEBUG("PinType[%d]", pPinInfo->type);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("Change PIN1 Success!");
-                               } else {
-                                       TEST_DEBUG("Change PIN2 Success!");
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PIN Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PUK Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_DISABLE_SEC_CNF: {
-                       TEST_DEBUG("****************NEW*TAPI_EVENT_SIM_DISABLE_SEC_CNF****************");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Disable SEC event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("Disable PIN1 Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("Disable PIN2 Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("Disable SIM LOCK Success!");
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PIN1Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PUK1 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("SIM LOCK Verification Failed! - SIM LOCK CODE Required ");
-                                       TEST_DEBUG("Remainint attempts [%d] - Useless value", pPinInfo->retry_count);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_ENABLE_SEC_CNF: {
-                       TEST_DEBUG("****************NEW*TAPI_EVENT_SIM_ENABLE_SEC_CNF****************");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM ENABLE SEC event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("Enable PIN1 Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("Enable PIN2 Success!");
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("Enable SIM LOCK Success!");
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PIN1Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK1) {
-                                       TEST_DEBUG("PIN1 Verification Failed! - PUK1 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_SIM) {
-                                       TEST_DEBUG("SIM LOCK Verification Failed! - SIM LOCK CODE Required ");
-                                       TEST_DEBUG("Remainint attempts [%d] - Useless value", pPinInfo->retry_count);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_DISABLE_FDNMODE_CNF: {
-                       TEST_DEBUG("****************NEW*TAPI_EVENT_SIM_DISABLE_FDNMODE_CNF****************");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Disable FDN event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("Disable FDN Success!");
-                               } else {
-                                       TEST_DEBUG("Unhandled type[%d]", pPinInfo->type);
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else {
-                                       TEST_DEBUG("Unhandled type[%d]", pPinInfo->type);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_ENABLE_FDNMODE_CNF: {
-                       TEST_DEBUG("****************NEW*TAPI_EVENT_SIM_ENABLE_FDNMODE_CNF****************");
-
-                       TelSimSecResult_t *pPinInfo = (TelSimSecResult_t*) sim_event->pData;
-
-                       //TEST_DEBUG("SIM Enable FDN event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("Enable FDN Success!");
-                               } else {
-                                       TEST_DEBUG("Unhandled type[%d]", pPinInfo->type);
-                               }
-                       } else {
-                               if (pPinInfo->type == TAPI_SIM_PTYPE_PIN2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PIN2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else if (pPinInfo->type == TAPI_SIM_PTYPE_PUK2) {
-                                       TEST_DEBUG("PIN2 Verification Failed! - PUK2 Required ");
-                                       TEST_DEBUG("Remainint attempts [%d]", pPinInfo->retry_count);
-                               } else {
-                                       TEST_DEBUG("Unhandled type[%d]", pPinInfo->type);
-                               }
-                       }
-                       TEST_DEBUG("********************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_PERS_STATUS_CNF: {
-                       TelSimPersStatus_t* pers_status =
-                                       (TelSimPersStatus_t*) sim_event->pData;
-
-                       printf(
-                                       "[SIM APP]**********NEW* TAPI_EVENT_SIM_PERS_STATUS_CNF************\n");
-                       printf("[SIM APP]SIM lock personalisation event status = [%x]\n",
-                                       sim_event->Status);
-                       printf(
-                                       "[SIM APP]SIM lock personalisation status - net0-ns1-sp2-cp3  = [%d]\n",
-                                       pers_status->type);
-                       printf(
-                                       "[SIM APP]SIM lock personalisation status - unlock0-lock1  = [%d]\n",
-                                       pers_status->mode);
-                       printf(
-                                       "[SIM APP]***************************************************\n");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_DISABLE_PERS_CNF: {
-                       TelSimPinOperationResult_t opResult =
-                                       (TelSimPinOperationResult_t) sim_event->Status;
-
-                       printf(
-                                       "[SIM APP]*********NEW*TAPI_EVENT_SIM_DISABLE_PERS_CNF************\n");
-                       printf("[SIM APP]Eable Personalization event status = [%x]\n",
-                                       opResult);
-
-                       if (opResult == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               printf("[SIM APP]Disable Personalization Success!\n");
-                       } else {
-                               printf(
-                                               "[SIM APP]Verification Failed! - Correct Password Required\n");
-                       }
-                       printf(
-                                       "\n***************************************************************\n");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_ENABLE_PERS_CNF: {
-                       TelSimPinOperationResult_t opResult =
-                                       (TelSimPinOperationResult_t) sim_event->Status;
-
-                       printf(
-                                       "[SIM APP]*********NEW*TAPI_EVENT_SIM_ENABLE_PERS_CNF************\n");
-                       printf("[SIM APP]Eable Personalization event status = [%x]\n",
-                                       opResult);
-
-                       if (opResult == TAPI_SIM_PIN_OPERATION_SUCCESS) {
-                               printf("[SIM APP]Enable Personalization Success!\n");
-                       } else {
-                               printf(
-                                               "[SIM APP]Verification Failed! - Correct Password Required\n");
-                       }
-                       printf(
-                                       "\n***************************************************************\n");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_SET_LANGUAGE_CNF: {
-                       TEST_DEBUG("*********NEW*TAPI_EVENT_SIM_SET_LANGUAGE_CNF************");
-                       TEST_DEBUG("update event status = [0x%x]", sim_event->Status);
-                       TEST_DEBUG("**********************************************************");
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_APDU_CNF: {
-                       TelSimApduResp_t* apdu_resp = (TelSimApduResp_t*) sim_event->pData;
-                       int i = 0;
-                       TEST_DEBUG("*********NEW*TAPI_EVENT_SIM_APDU_CNF************");
-                       TEST_DEBUG("update event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == 1234) {
-                               TEST_DEBUG("timeout happended. this means, modem didn`t reply");
-                               return;
-                       }
-
-                       if (apdu_resp != NULL) {
-                               TEST_DEBUG("apdu_resp->apdu_resp_len[%d]",apdu_resp->apdu_resp_len);
-
-                               for (i = 0; i < apdu_resp->apdu_resp_len; i++)
-                                       TEST_DEBUG("apdu_resp->apdu_resp[%d]=[0x%x]",i,apdu_resp->apdu_resp[i]);
-
-                       } else {
-                               TEST_DEBUG("atr_resp == NULL");
-                       }
-                       TEST_DEBUG("**********************************************************");;
-               }
-                       break;
-
-               case TAPI_EVENT_SIM_ATR_CNF: {
-                       TelSimAtrResp_t* atr_resp = (TelSimAtrResp_t*) sim_event->pData;
-                       int i = 0;
-
-                       TEST_DEBUG("*********NEW*TAPI_EVENT_SIM_ATR_CNF************");
-                       TEST_DEBUG("update event status = [0x%x]", sim_event->Status);
-
-                       if (sim_event->Status == 1234) {
-                               TEST_DEBUG("timeout happended. this means, modem didn`t reply");
-                               return;
-                       }
-
-                       if (atr_resp != NULL) {
-                               TEST_DEBUG("atr_resp->atr_resp_len[%d]",atr_resp->atr_resp_len);
-
-                               for (i = 0; i < atr_resp->atr_resp_len; i++)
-                                       TEST_DEBUG("atr_resp->atr_resp[%d]=[0x%x]",i,atr_resp->atr_resp[i]);
-                       } else {
-                               TEST_DEBUG("atr_resp == NULL");
-                       }
-                       TEST_DEBUG("**********************************************************");
-               }
-                       break;
-
-#if 0
-
-                       case TAPI_SIM_EVENT_PB_GET_STORAGE_LIST:
-                       {
-                               TEST_DEBUG("****************TAPI_SIM_EVENT_PB_GET_STORAGE_LIST****************************");
-                               char *p = (char*)&sim_event->pData;
-
-                               TEST_DEBUG("SIM phone book storage list Information ");
-                               if(*p & 0x01)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_DC - ME Dailled Call list");
-                               if(*p & 0x02)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_EN - Emergency Number");
-                               if(*p & 0x03)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_FD - Fixed dialing phonebook");
-                               if(*p & 0x04)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_LD - Last dialled phonebook");
-                               if(*p & 0x05)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_MC -Missed call list");
-                               if(*p & 0x06)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_ME - ME phone book");
-                               if(*p & 0x07)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_MT - ME and sim combined phone book");
-                               if(*p & 0x08)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_ON - My own number - MSISDN");
-                               if(*p & 0x09)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_RC - ME Received calls");
-                               if(*p & 0x0A)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_SIM - SIM phone book");
-                               if(*p & 0x0B)
-                               TEST_DEBUG("IPC_PB_STORAGE_TYPE_SDN - Service dailing number");
-
-                               TEST_DEBUG("********************************************");
-                       }
-                       break;
-#endif
-
-               default:
-                       TEST_DEBUG("Undhandled event type [0x%x]",sim_event->EventType)
-                       ;
-               }
-               printf("\n");
-       }//end switch (Type)
-       else {
-               TEST_DEBUG("Undhandled EventClass [0x%x]",sim_event->EventClass);
-       }
-       return;
-
-}// end func
-
-
-int sim_read_key_input(void) {
-       char buf[256] = { 0, };
-       int ret = 0;
-       TapiResult_t err_code = TAPI_API_SUCCESS;
-       char ch;
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0) {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-
-       } else if (ret == 0)
-               return ret;
-
-       printf("************************************\n");
-       printf("op : show all OP | q : quit sim test app \n");
-       printf("************************************\n");
-       printf("SIM OP in : %s\n", buf);
-
-       if (memcmp(buf, "op", sizeof("op") - 1) == 0) {
-               printf("***************************** NEW Asynchronous APIs *******************************\n");
-               printf("rsim : rsim \n");
-               printf("pin1 : verify pin1 number \n");
-               printf("pin2 : verify pin2 number\n");
-               printf("sim : verify sim lock number\n");
-               printf("puk1 : Unblocking CHV1 \n");
-               printf("puk2 : Unblocking CHV2 \n");
-               printf("chpin1 : change pin1 number \n");
-               printf("chpin2 : change pin2 number \n");
-               printf("enpin : CHV enable\n");
-               printf("dispin : CHV disable\n");
-               printf("enfdn : FDN enable\n");
-               printf("disfdn : FDN disable\n");
-               printf("ensim : enable sim lock\n");
-               printf("dissim : disable sim lock\n");
-               printf("getpers : Get lock personalisation information \n");
-               printf("medepers : de-personalization test\n");
-               printf("mepers : personalization test\n");
-               printf("setlang : update sim language info\n");
-               printf("apdu : send apdu\n");
-               printf("atr : request atr\n");
-               printf("***************************** Synchronous APIs *******************************\n");
-               printf("siminit : Get SIM init Information\n");
-               printf("getpin1 : Get CHV1 status info\n");
-               printf("getfdn : Get FDN status info\n");
-               printf("getpin2 : Get CHV2 status Info \n");
-               printf("getsim : Get CHV2 status Info \n");
-               printf("gettype : show Sim Card Type\n");
-               printf("getimsi : show Sim IMSI\n");
-               printf("geticcid : show Sim ICCID\n");
-               printf("getlang:Language Indication Info\n");
-               printf("getecc : get SIM ECC\n");
-               printf("getuecc : get USIM ECC\n");
-               printf("getmb : get mailbox number\n");
-               printf("getmw : get message waiting information\n");
-               printf("getcf : get callforwarding information\n");
-               printf("getcphs : get cphs information\n");
-               printf("getmsisdn : get msisdn information\n");
-               printf("******************************* PHONE BOOK ***********************************\n");
-               printf("pbinit : Get pb init info\n");
-               printf("pbcapa : pb capability info \n");
-               printf("pbcnt : phonebook used and total count\n");
-               printf("pbentry : phonebook entry info\n");
-               printf("pbadd : phonebook add\n");
-               printf("pbdel : phonebook delete\n");
-               printf("pbread:phonebook read\n");
-               //              printf("****************************** SAP commands **********************************\n");
-               //              printf("sapconnect: SAP Connect request\n");
-               //              printf("sapstatus : SAP current connection status request \n");
-               //              printf("sapatr: SAP transfer atr request\n");
-               //              printf("sapapdu: SAP transfer apdu request\n");
-               //              printf("sapsetproto: SAP set protocol request\n");
-               //              printf("sapsimpwr: SAP SIM power on/off request\n");
-               //              printf("sapreaderstat: SAP card reader status request\n");
-               //              printf("*****************************************************************************\n");
-       }
-
-       /*NEW API -START*/
-       if (memcmp(buf, "siminit", sizeof("siminit") - 1) == 0) {
-               TelSimCardStatus_t status = 0x00;
-               int b_card_changed = 0;
-
-               err_code = tel_get_sim_init_info(&status, &b_card_changed);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("*************************************************************");
-                       __PrintCardStatus("CardStatus: ", status);
-                       TEST_DEBUG("b_card_changed[%d]\n",b_card_changed);
-                       TEST_DEBUG("*************************************************************");
-               } else {
-                       TEST_DEBUG("TAPI Fail: Error Code [%d]\n",err_code);
-               }
-       } else if (memcmp(buf, "rsim", sizeof("rsim") - 1) == 0) {
-               TEST_DEBUG("rsim....");
-
-               TelSimRSimReq_t rsim = { 0, };
-
-               rsim.file_id = 0x6F60;
-               rsim.rsim_cmd = TAPI_SIM_GET_RESPONSE;
-
-               err_code = tel_req_sim_access((const TelSimRSimReq_t*) &rsim,
-                               &request_id);
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       } else if (memcmp(buf, "pin1", sizeof("pin1") - 1) == 0) {
-               TEST_DEBUG("Pin1 Verification");
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[TAPI_SIM_PIN_LENGTH + 1];
-
-               getchar();
-
-               TEST_DEBUG(" PUT PIN1 CODE: ");
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t pin_data = { 0, };
-
-               pin_data.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               pin_data.pw_len = strlen(init_pin_val);
-
-               TEST_DEBUG("pw_len[%d]", pin_data.pw_len);
-
-               pin_data.pw = (unsigned char*) malloc(length);
-               memcpy(pin_data.pw, init_pin_val, length);
-
-               err_code = tel_verifiy_sim_pins(&pin_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "pin2", sizeof("pin2") - 1) == 0) {
-               TEST_DEBUG("Pin2 Verification");
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[TAPI_SIM_PIN_LENGTH + 1];
-
-               getchar();
-
-               TEST_DEBUG(" PUT PIN2 CODE: ");
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t pin_data = { 0, };
-
-               pin_data.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               pin_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", pin_data.pw_len);
-
-               pin_data.pw = (unsigned char*) malloc(length);
-               memcpy(pin_data.pw, init_pin_val, length);
-
-               err_code = tel_verifiy_sim_pins(&pin_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "sim", sizeof("sim") - 1) == 0) {
-               TEST_DEBUG("sim lock verification");
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[TAPI_SIM_PIN_LENGTH + 1];
-
-               //puts("Flushing input - Enter \ to exit! ");
-               //while ((ch = getchar()) != '\n' && ch != EOF);
-               getchar();
-
-               TEST_DEBUG(" PUT SIM LOCK CODE: 4 DIGIT ");
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t pin_data = { 0, };
-
-               pin_data.type = TAPI_SIM_PTYPE_SIM; // 0x06
-               pin_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", pin_data.pw_len);
-
-               pin_data.pw = (unsigned char*) malloc(length);
-               memcpy(pin_data.pw, init_pin_val, length);
-
-               err_code = tel_verifiy_sim_pins(&pin_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-       // Disable pin1
-       else if (memcmp(buf, "dispin", sizeof("dispin") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("Disable npin1");
-               TEST_DEBUG("Plese input PIN1 CODE: ");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_disable_sim_security(&sec_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // Enable pin1
-       else if (memcmp(buf, "enpin", sizeof("enpin") - 1) == 0) {
-               //TEST_DEBUG("Flushing input - Enter \ to exit!");
-               //while ((ch = getchar()) != '\n' && ch != EOF);
-               getchar();
-
-               TEST_DEBUG("Enable npin1");
-               TEST_DEBUG("Plese input PIN1 CODE: ");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_enable_sim_security(&sec_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // Disable sim lock
-       else if (memcmp(buf, "dissim", sizeof("dissim") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("Disable ndissim");
-               TEST_DEBUG("Plese input SIM LOCK CODE: ");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_SIM; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_disable_sim_security(&sec_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // Enable pin1
-       else if (memcmp(buf, "ensim", sizeof("ensim") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("Enable nensim");
-               TEST_DEBUG("Plese input SIM LOCK CODE: ");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_SIM; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_enable_sim_security(&sec_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // get pin1 status
-       else if (memcmp(buf, "getpin1", sizeof("getpin1") - 1) == 0) {
-               TelSimPinType_t type = TAPI_SIM_PTYPE_PIN1;
-               TelSimPinStatus_t status = -1;
-               TEST_DEBUG("Get pin1 status");
-
-               err_code = tel_get_sim_security_status(type, &status);
-
-               if (err_code == TAPI_API_SUCCESS) {
-
-                       TEST_DEBUG(" *****************************************************");
-                       switch (status) {
-                       case TAPI_SIM_PIN_STATUS_DISABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_DISABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_ENABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_ENABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_PUK_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_PUK_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_UNKNOWN: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_UNKNOWN ");
-                       }
-                               break;
-
-                       default:
-                               TEST_DEBUG(" Default case statment: pin1_status(%d)", status)
-                               ;
-                       }
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-               TEST_DEBUG("*****************************************************");
-       }
-       // get pin2 status
-       else if (memcmp(buf, "getpin2", sizeof("getpin2") - 1) == 0) {
-               TelSimPinType_t type = TAPI_SIM_PTYPE_PIN2;
-               TelSimPinStatus_t status = -1;
-               TEST_DEBUG("Get pin2 status");
-
-               err_code = tel_get_sim_security_status(type, &status);
-
-               if (err_code == TAPI_API_SUCCESS) {
-
-                       TEST_DEBUG(" *****************************************************");
-                       switch (status) {
-                       case TAPI_SIM_PIN_STATUS_DISABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_DISABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_ENABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_ENABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_PUK_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_PUK_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_UNKNOWN: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_UNKNOWN ");
-                       }
-                               break;
-
-                       default:
-                               TEST_DEBUG(" Default case statment: pin2_status(%d)", status)
-                               ;
-                       }
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-               TEST_DEBUG("*****************************************************");
-       } else if (memcmp(buf, "getsim", sizeof("getsim") - 1) == 0) {
-               TelSimPinType_t type = TAPI_SIM_PTYPE_SIM;
-               TelSimPinStatus_t status = -1;
-               TEST_DEBUG("Get SIM LOCK status");
-
-               err_code = tel_get_sim_security_status(type, &status);
-
-               if (err_code == TAPI_API_SUCCESS) {
-
-                       TEST_DEBUG(" *****************************************************");
-                       switch (status) {
-                       case TAPI_SIM_PIN_STATUS_DISABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_DISABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_ENABLED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_ENABLED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_PUK_BLOCKED: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_PUK_BLOCKED ");
-                       }
-                               break;
-
-                       case TAPI_SIM_PIN_STATUS_UNKNOWN: {
-                               TEST_DEBUG("TAPI_SIM_PIN_STATUS_UNKNOWN ");
-                       }
-                               break;
-
-                       default:
-                               TEST_DEBUG(" Default case statment: sim_status(%d)", status)
-                               ;
-                       }
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-               TEST_DEBUG("*****************************************************");
-       }
-       // Enable FDN
-       else if (memcmp(buf, "enfdn", sizeof("enfdn") - 1) == 0) {
-               //puts("Flushing input - Enter \ to exit! ");
-               //while ((ch = getchar()) != '\n' && ch != EOF);
-               getchar();
-
-               TEST_DEBUG("Enable FDN");
-               TEST_DEBUG("Plese input PIN2 CODE: ");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_enable_sim_fdn(sec_data.pw, (int *)&sec_data.pw_len,
-                               &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-       // Disable FDN
-       else if (memcmp(buf, "disfdn", sizeof("disfdn") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("Disable FDN");
-               TEST_DEBUG("Plese input PIN2 CODE");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t sec_data = { 0, };
-               sec_data.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               sec_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", sec_data.pw_len);
-
-               sec_data.pw = (unsigned char*) malloc(length);
-               memcpy(sec_data.pw, init_pin_val, length);
-
-               err_code = tel_disable_sim_fdn(sec_data.pw, (int *)&sec_data.pw_len,
-                               &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-       // get FDN status
-       else if (memcmp(buf, "getfdn", sizeof("getfdn") - 1) == 0) {
-               TEST_DEBUG("Get FDN status");
-               int fdn_status = 0;
-
-               err_code = tel_get_sim_fdn_status(&fdn_status);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       if (fdn_status == 0) {
-                               TEST_DEBUG("*************************");
-                               TEST_DEBUG("FDN disabled ");
-                               TEST_DEBUG("*************************");
-                       } else {
-                               TEST_DEBUG("*************************");
-                               TEST_DEBUG("FDN enabled");
-                               TEST_DEBUG("*************************");
-                       }
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       } else if (memcmp(buf, "gettype", sizeof("gettype") - 1) == 0) {
-               TelSimCardType_t cardInfo;
-               TEST_DEBUG("Get card type !!!");
-               err_code = tel_get_sim_type(&cardInfo);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("*************************************************************");
-                       __PrintCardType("", cardInfo);
-                       TEST_DEBUG("*************************************************************");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       } else if (memcmp(buf, "getimsi", sizeof("getimsi") - 1) == 0) {
-               TelSimImsiInfo_t imsi;
-               TEST_DEBUG("Get IMSI type !!!");
-               err_code = tel_get_sim_imsi(&imsi);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("*************************************************************");
-                       TEST_DEBUG("* imsi.bValid[%d]",imsi.bValid);
-                       TEST_DEBUG("* imsi.szMcc[%s]",imsi.szMcc);
-                       TEST_DEBUG("* imsi.szMnc[%s]",imsi.szMnc);
-                       TEST_DEBUG("* imsi.szMsin[%s]",imsi.szMsin);
-                       TEST_DEBUG("*************************************************************");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       } else if (memcmp(buf, "geticcid", sizeof("geticcid") - 1) == 0) {
-               TelSimIccIdInfo_t iccid;
-               TEST_DEBUG("Get ICCID  !!!");
-               err_code = tel_get_sim_iccid(&iccid);
-               int i = 0;
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("*************************************************************");
-                       TEST_DEBUG("* iccid.icc_length[%d]",iccid.icc_length);
-                       for (i = 0; i < iccid.icc_length; i++) {
-                               TEST_DEBUG("* iccid.icc_num[%c]",iccid.icc_num[i]);
-                       }
-                       TEST_DEBUG("*************************************************************");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getlang", sizeof("getlang") - 1) == 0) {
-               TEST_DEBUG("Language Preference INFO ");
-               int i;
-               TelSimLanguageInfo_t li_info = { 0, };
-
-               err_code = tel_get_sim_language(&li_info);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG("************ LI  INFO ***********************");
-                       TEST_DEBUG("LpCount: [%lu]", li_info.LpCount);
-                       for (i = 0; i < li_info.LpCount; i++) {
-                               fprintf(stderr, "Loop(%d), ", i);
-                               __PrintLangInfo("LpCode: ", li_info.Lp[i]);
-                       }
-                       TEST_DEBUG("============================================");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getecc", sizeof("getecc") - 1) == 0) {
-               TEST_DEBUG(" Get SIM ECC  ");
-               int ecc_rec_count = 0;
-               TelSimEccData_t ecc_info = { { { 0, } } };
-               TelSimEccInfo_t SimEccInfo = { { 0, } };
-
-               err_code = tel_get_sim_ecc(&ecc_info, &ecc_rec_count);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       SimEccInfo = ecc_info.EccInfo;
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" EEC count [%d]", ecc_rec_count);
-                       TEST_DEBUG(" ============================================");
-
-                       if (ecc_rec_count != 0) {
-                               TEST_DEBUG("ECC1 [%s]", SimEccInfo.szEcc1);
-                               TEST_DEBUG("ECC2 [%s]", SimEccInfo.szEcc2);
-                               TEST_DEBUG("ECC3 [%s]", SimEccInfo.szEcc3);
-                               TEST_DEBUG("ECC4 [%s]", SimEccInfo.szEcc4);
-                               TEST_DEBUG("ECC5 [%s]", SimEccInfo.szEcc5);
-                       }
-                       TEST_DEBUG(" ============================================");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getuecc", sizeof("getuecc") - 1) == 0) {
-               int i = 0;
-               int uecc_rec_count = 0;
-
-               TEST_DEBUG(" Get USIM ECC  ");
-
-               TelSimEccData_t uecc_info = { { { 0, } } };
-
-               err_code = tel_get_sim_ecc(&uecc_info, &uecc_rec_count);
-
-               if (err_code == TAPI_API_SUCCESS) {
-
-                       TEST_DEBUG("ECC count [%d]",uecc_rec_count );
-
-                       for (i = 0; i < uecc_rec_count; i++) {
-                               TEST_DEBUG("Loop(%d): ", i);
-                               TEST_DEBUG(" ECC Used [%d]", uecc_info.UeccInfo[i].bUsed);
-                               TEST_DEBUG(" ECC Len [%d]", uecc_info.UeccInfo[i].EccLen);
-
-                               if (NULL != uecc_info.UeccInfo[i].szEcc) {
-                                       TEST_DEBUG("ECC string [%s]", uecc_info.UeccInfo[i].szEcc);
-                               } else {
-                                       TEST_DEBUG("ECC string [null]");
-                               }
-
-                               TEST_DEBUG("ECC alphaID [%s]",uecc_info.UeccInfo[i].szEccAlphaIdentifier);
-                               __PrintECCSvcInfo(uecc_info.UeccInfo[i].EccEmergencyServiceInfo);
-                       }
-
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getimsi", sizeof("getimsi") - 1) == 0) {
-               TEST_DEBUG("Get IMSI INFO ");
-
-               TelSimImsiInfo_t sim_imsi_info;
-
-               err_code = tel_get_sim_imsi(&sim_imsi_info);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" IMSI [mcc,mnc,msin]= ");
-                       TEST_DEBUG(" [%s]",sim_imsi_info.szMcc);
-                       TEST_DEBUG(" [%s]",sim_imsi_info.szMnc);
-                       TEST_DEBUG(" [%s]",sim_imsi_info.szMsin);
-                       TEST_DEBUG(" ============================================");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getmb", sizeof("getmb") - 1) == 0) {
-               TEST_DEBUG("Get MAILBOX INFO ");
-
-               TelSimMailboxNumbers_s mbox;
-
-               err_code = tel_get_sim_mailbox_info(&mbox);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-
-                       if (mbox.b_cphs) {
-                               TEST_DEBUG("Current SIM is CPHS");
-                       } else {
-                               TEST_DEBUG("Current SIM is not CPHS but 3GPP");
-                       }
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" voice_line1.bUsed[%d]",mbox.voice_line1.bUsed);
-                       TEST_DEBUG(" voice_line1.AlphaIdLength[%lu]",mbox.voice_line1.AlphaIdLength);
-                       TEST_DEBUG(" voice_line1.AlphaId[%s]",mbox.voice_line1.AlphaId);
-                       TEST_DEBUG(" voice_line1.DiallingnumLength[%lu]",mbox.voice_line1.DiallingnumLength);
-                       TEST_DEBUG(" voice_line1.DiallingNum[%s]",mbox.voice_line1.DiallingNum);
-                       TEST_DEBUG(" voice_line1.NumberingPlanIdent[%d]",mbox.voice_line1.NumberingPlanIdent);
-                       TEST_DEBUG(" voice_line1.TypeOfNumber[%u]",mbox.voice_line1.TypeOfNumber);
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" voice_line2.bUsed[%d]",mbox.voice_line2.bUsed);
-                       TEST_DEBUG(" voice_line2.AlphaIdLength[%lu]",mbox.voice_line2.AlphaIdLength);
-                       TEST_DEBUG(" voice_line2.AlphaId[%s]",mbox.voice_line2.AlphaId);
-                       TEST_DEBUG(" voice_line2.DiallingnumLength[%lu]",mbox.voice_line2.DiallingnumLength);
-                       TEST_DEBUG(" voice_line2.DiallingNum[%s]",mbox.voice_line2.DiallingNum);
-                       TEST_DEBUG(" voice_line2.NumberingPlanIdent[%d]",mbox.voice_line2.NumberingPlanIdent);
-                       TEST_DEBUG(" voice_line2.TypeOfNumber[%d]",mbox.voice_line2.TypeOfNumber);
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" video.bUsed[%d]",mbox.video.bUsed);
-                       TEST_DEBUG(" video.AlphaIdLength[%lu]",mbox.video.AlphaIdLength);
-                       TEST_DEBUG(" video.AlphaId[%s]",mbox.video.AlphaId);
-                       TEST_DEBUG(" video.DiallingnumLength[%lu]",mbox.video.DiallingnumLength);
-                       TEST_DEBUG(" video.DiallingNum[%s]",mbox.video.DiallingNum);
-                       TEST_DEBUG(" video.NumberingPlanIdent[%d]",mbox.video.NumberingPlanIdent);
-                       TEST_DEBUG(" video.TypeOfNumber[%d]",mbox.video.TypeOfNumber);
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" fax.bUsed[%d]",mbox.fax.bUsed);
-                       TEST_DEBUG(" fax.AlphaIdLength[%lu]",mbox.fax.AlphaIdLength);
-                       TEST_DEBUG(" fax.AlphaId[%s]",mbox.fax.AlphaId);
-                       TEST_DEBUG(" fax.DiallingnumLength[%lu]",mbox.fax.DiallingnumLength);
-                       TEST_DEBUG(" fax.DiallingNum[%s]",mbox.fax.DiallingNum);
-                       TEST_DEBUG(" fax.NumberingPlanIdent[%d]",mbox.fax.NumberingPlanIdent);
-                       TEST_DEBUG(" fax.TypeOfNumber[%d]",mbox.fax.TypeOfNumber);
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG(" email.bUsed[%d]",mbox.email.bUsed);
-                       TEST_DEBUG(" email.AlphaIdLength[%lu]",mbox.email.AlphaIdLength);
-                       TEST_DEBUG(" email.AlphaId[%s]",mbox.email.AlphaId);
-                       TEST_DEBUG(" email.DiallingnumLength[%lu]",mbox.email.DiallingnumLength);
-                       TEST_DEBUG(" email.DiallingNum[%s]",mbox.email.DiallingNum);
-                       TEST_DEBUG(" email.NumberingPlanIdent[%d]",mbox.email.NumberingPlanIdent);
-                       TEST_DEBUG(" email.TypeOfNumber[%d]",mbox.email.TypeOfNumber);
-                       TEST_DEBUG(" ============================================");
-
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getmw", sizeof("getmw") - 1) == 0) {
-               TEST_DEBUG("Get MESSAGE WAITING INFO ");
-
-               TelSimMessageWaiting_s mw;
-
-               err_code = tel_get_sim_messagewaiting_info(&mw);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-
-                       if (mw.b_cphs) {
-                               TEST_DEBUG("Current SIM is CPHS");
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG(" cphs_mw.bWaitVoiceMsgLine1[%d]",mw.mw_data_u.cphs_mw.bWaitVoiceMsgLine1);
-                               TEST_DEBUG(" cphs_mw.bWaitVoiceMsgLine2[%d]",mw.mw_data_u.cphs_mw.bWaitVoiceMsgLine2);
-                               TEST_DEBUG(" cphs_mw.bWaitFaxMsg[%d]",mw.mw_data_u.cphs_mw.bWaitFaxMsg);
-                               TEST_DEBUG(" cphs_mw.bWaitDataMsg[%d]",mw.mw_data_u.cphs_mw.bWaitDataMsg);
-
-                       } else {
-                               TEST_DEBUG("Current SIM is not CPHS but 3GPP");
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG(" mw_data_u.mw.IndicatorType[0x%x]",mw.mw_data_u.mw.IndicatorType);
-                               TEST_DEBUG(" mw_data_u.mw.VoiceMailCount[%d]",mw.mw_data_u.mw.VoiceMailCount);
-                               TEST_DEBUG(" mw_data_u.mw.FaxCount[%d]",mw.mw_data_u.mw.FaxCount);
-                               TEST_DEBUG(" mw_data_u.mw.EmailCount[%d]",mw.mw_data_u.mw.EmailCount);
-                               TEST_DEBUG(" mw_data_u.mw.OtherCount[%d]",mw.mw_data_u.mw.OtherCount);
-                               TEST_DEBUG(" mw_data_u.mw.VideoMailCount[%d]",mw.mw_data_u.mw.VideoMailCount);
-                       }
-                       TEST_DEBUG(" ============================================");
-
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getcf", sizeof("getcf") - 1) == 0) {
-               TEST_DEBUG("Get CALLFORWARDING INFO ");
-
-               TelSimCallForwarding_s cf;
-
-               err_code = tel_get_sim_callforwarding_info(&cf);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-
-                       if (cf.b_cphs) {
-                               TEST_DEBUG("Current SIM is CPHS");
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalLine1[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalLine1);
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalLine2[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalLine2);
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalFax[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalFax);
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalData[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalData);
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalSms[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalSms);
-                               TEST_DEBUG(" cphs_cf.bCallForwardUnconditionalBearer[%d]",cf.cf_data_u.cphs_cf.bCallForwardUnconditionalBearer);
-                       } else {
-                               TEST_DEBUG("Current SIM is not CPHS but 3GPP");
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG(" cf.bUsed[%d]",cf.cf_data_u.cf.bUsed);
-                               TEST_DEBUG(" cf.MspNumber[%d]",cf.cf_data_u.cf.MspNumber);
-                               TEST_DEBUG(" cf.Status[0x%x]",cf.cf_data_u.cf.Status);
-                               TEST_DEBUG(" cf.DiallingnumLen[%lu]",cf.cf_data_u.cf.DiallingnumLen);
-                               TEST_DEBUG(" cf.TypeOfNumber[%d]",cf.cf_data_u.cf.TypeOfNumber);
-                               TEST_DEBUG(" cf.NumberingPlanIdent[%d]",cf.cf_data_u.cf.NumberingPlanIdent);
-                               TEST_DEBUG(" cf.DiallingNum[%s]",cf.cf_data_u.cf.DiallingNum);
-                       }
-                       TEST_DEBUG(" ============================================");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "getcphs", sizeof("getcphs") - 1) == 0) {
-               TEST_DEBUG("Get CPHS INFO ");
-
-               TelSimCphsLocalInfo_t cphs;
-
-               err_code = tel_get_sim_cphs_info(&cphs);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-
-                       if (cphs.b_used) {
-                               TEST_DEBUG("Current SIM is CPHS");
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.cphsinfo.CphsPhase[%d]",cphs.cphsinfo.CphsPhase);
-                               TEST_DEBUG("cphs.cphsinfo.CphsServiceTable.bCustomerServiceProfile[%d]",cphs.cphsinfo.CphsServiceTable.bCustomerServiceProfile);
-                               TEST_DEBUG("cphs.cphsinfo.CphsServiceTable.bServiceStringTable[%d]",cphs.cphsinfo.CphsServiceTable.bServiceStringTable);
-                               TEST_DEBUG("cphs.cphsinfo.CphsServiceTable.bMailBoxNumbers[%d]",cphs.cphsinfo.CphsServiceTable.bMailBoxNumbers);
-                               TEST_DEBUG("cphs.cphsinfo.CphsServiceTable.bOperatorNameShortForm[%d]",cphs.cphsinfo.CphsServiceTable.bOperatorNameShortForm);
-                               TEST_DEBUG("cphs.cphsinfo.CphsServiceTable.bInformationNumbers[%d]",cphs.cphsinfo.CphsServiceTable.bInformationNumbers);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.csp.ServiceProfileEntry[0].CustomerServiceGroup[%d]",cphs.csp.ServiceProfileEntry[0].CustomerServiceGroup);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.infn.bUsed[%d]",cphs.infn.bUsed);
-                               TEST_DEBUG("cphs.infn.AlphaIdLength[%d]",cphs.infn.AlphaIdLength);
-                               TEST_DEBUG("cphs.infn.IndexLevelIndicator[%d]",cphs.infn.IndexLevelIndicator);
-                               TEST_DEBUG("cphs.infn.PremiumServiceIndicator[%d]",cphs.infn.PremiumServiceIndicator);
-                               TEST_DEBUG("cphs.infn.NetworkSpecificIndicator[%d]",cphs.infn.NetworkSpecificIndicator);
-                               TEST_DEBUG("cphs.infn.Alpha_id[%s]",cphs.infn.Alpha_id);
-                               TEST_DEBUG("cphs.infn.DiallingnumLength[%lu]",cphs.infn.DiallingnumLength);
-                               TEST_DEBUG("cphs.infn.TypeOfNumber[%d]",cphs.infn.TypeOfNumber);
-                               TEST_DEBUG("cphs.infn.NumberingPlanIdentity[%d]",cphs.infn.NumberingPlanIdentity);
-                               TEST_DEBUG("cphs.infn.DiallingNum[%s]",cphs.infn.DiallingNum);
-                               TEST_DEBUG("cphs.infn.Ext1RecordId[%d]",cphs.infn.Ext1RecordId);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.opname.NameLength[%d]",cphs.opname.NameLength);
-                               TEST_DEBUG("cphs.opname.OperatorName[%s]",cphs.opname.OperatorName);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.opshortform.ShortNameLength[%d]",cphs.opshortform.ShortNameLength);
-                               TEST_DEBUG("cphs.opshortform.OperatorShortName[%s]",cphs.opshortform.OperatorShortName);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.dflagsinfo.DynamicFlags[%d]",cphs.dflagsinfo.DynamicFlags);
-                               TEST_DEBUG(" ============================================");
-                               TEST_DEBUG("cphs.d2flagsinfo.Dynamic2Flag[%d]",cphs.d2flagsinfo.Dynamic2Flag);
-                       } else {
-                               TEST_DEBUG("Current SIM is not CPHS but 3GPP");
-                               TEST_DEBUG(" ============================================");
-
-                       }
-                       TEST_DEBUG(" ============================================");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "getmsisdn", sizeof("getmsisdn") - 1) == 0) {
-               TEST_DEBUG("Get MSISDN INFO ");
-
-               TelSimSubscriberInfo_t msisdn;
-
-               err_code = tel_get_sim_msisdn(&msisdn);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" ============================================");
-                       TEST_DEBUG("name[%s]",msisdn.name);
-                       TEST_DEBUG("num[%s]",msisdn.num);
-                       if (msisdn.name == '\0')
-                               TEST_DEBUG("name is null string");
-
-                       if (msisdn.num == '\0')
-                               TEST_DEBUG("number is null string");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       } else if (memcmp(buf, "pbinit", sizeof("pbinit") - 1) == 0) {
-               TEST_DEBUG("npbinit status");
-
-               int valid_index = 0;
-               TelSimPbList_t pb_list = { 0, };
-               int pPbInitCompleted = 0;
-
-               err_code = tel_get_sim_pb_init_info(&pPbInitCompleted, &pb_list,
-                               &valid_index);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       if (pPbInitCompleted == 0) {
-                               TEST_DEBUG(" SIM PB INIT NOT completed ");
-                       } else {
-                               TEST_DEBUG("SIM PB INIT completed");
-                               /* if no sim records at all then valid_index = 0xFF */TEST_DEBUG("ADN First index is [%d]",valid_index);
-                               TEST_DEBUG("SIM phone book storage list Information ");
-                               TEST_DEBUG("********************************************");
-                               TEST_DEBUG("pb_list.b_fdn[%d]",pb_list.b_fdn);
-                               TEST_DEBUG("pb_list.b_msisdn[%d]",pb_list.b_msisdn);
-                               TEST_DEBUG("pb_list.b_adn[%d]",pb_list.b_adn);
-                               TEST_DEBUG("pb_list.b_sdn[%d]",pb_list.b_sdn);
-                               TEST_DEBUG("pb_list.b_3g[%d]",pb_list.b_3g);
-                               TEST_DEBUG("pb_list.b_aas[%d]",pb_list.b_aas);
-                               TEST_DEBUG("pb_list.b_gas[%d]",pb_list.b_gas);
-
-                               /*
-                                if(pb_list & 0x01)
-                                TEST_DEBUG("ME dialed calls list stored in NV");
-                                if(pb_list & 0x02)
-                                TEST_DEBUG("SIM(or ME) emergency number");
-                                if(pb_list & 0x03)
-                                TEST_DEBUG("SIM fixed-dialing phonebook");
-                                if(pb_list & 0x04)
-                                TEST_DEBUG("SIM last-dialing phonebook");
-                                if(pb_list & 0x05)
-                                TEST_DEBUG("ME missed calls list");
-                                if(pb_list & 0x06)
-                                TEST_DEBUG("ME phonebook");
-                                if(pb_list & 0x07)
-                                TEST_DEBUG("Combined ME and SIM phonebook");
-                                if(pb_list & 0x08)
-                                TEST_DEBUG("SIM(or ME) own numbers ( MSISDNs) list");
-                                if(pb_list & 0x09)
-                                TEST_DEBUG("ME received calls list stored in NV");
-                                if(pb_list & 0x0A)
-                                TEST_DEBUG("2G SIM phonebook");
-                                if(pb_list & 0x0B)
-                                TEST_DEBUG("Service Dialing Number");
-                                if(pb_list & 0x0C)
-                                TEST_DEBUG("3G SIM phonebook");
-                                if(pb_list & 0x0D)
-                                TEST_DEBUG("Incoming Call Information");
-                                if(pb_list & 0x0E)
-                                TEST_DEBUG("Outgoing Call Information");
-                                if(pb_list & 0x0F)
-                                TEST_DEBUG("Additional Number Alpha String");
-                                if(pb_list & 0x10)
-                                TEST_DEBUG("Grouping Information Alpha String");
-                                */
-                               /*
-                                PB_DC  0x01    ME dialed calls list stored in NV
-                                PB_EN  0x02    SIM(or ME) emergency number
-                                PB_FD  0x03    SIM fixed-dialing phonebook
-                                PB_LD  0x04    SIM last-dialing phonebook
-                                PB_MC  0x05    ME missed calls list
-                                PB_ME  0x06    ME phonebook
-                                PB_MT  0x07    Combined ME and SIM phonebook
-                                PB_ON  0x08    SIM(or ME) own numbers ( MSISDNs) list
-                                PB_RC  0x09    ME received calls list stored in NV
-                                PB_SIM 0x0A    2G SIM phonebook
-                                PB_SDN 0x0B    Service Dialing Number
-                                PB_3GSIM       0x0C    3G SIM phonebook
-                                PB_ICI 0x0D    Incoming Call Information
-                                PB_OCI 0x0E    Outgoing Call Information
-                                PB_AAS 0x0F    Additional Number Alpha String
-                                PB_GAS 0x10    Grouping Information Alpha String
-                                */
-
-                               TEST_DEBUG("********************************************");
-                       }
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       }
-
-       //change pin1 number
-       else if (memcmp(buf, "chpin1", sizeof("chpin1") - 1) == 0) {
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_old_pin_val[length];
-               char init_new_pin_val[length];
-
-               memset(&init_old_pin_val, 0, length);
-               memset(&init_new_pin_val, 0, length);
-
-               TelSimSecPw_t old_pin = { 0, };
-               TelSimSecPw_t new_pin = { 0, };
-
-               getchar();
-
-               TEST_DEBUG("Change PIN1 CODE");
-               TEST_DEBUG("Input Current PIN1 Code: ");
-
-               _fgets(init_old_pin_val, 9);
-
-               old_pin.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               old_pin.pw_len = strlen(init_old_pin_val);
-               TEST_DEBUG("pw_len[%d]", old_pin.pw_len);
-               old_pin.pw = (unsigned char*) malloc(length);
-               memcpy(old_pin.pw, init_old_pin_val, length);
-
-               TEST_DEBUG("Input New PIN1 Code: ");
-
-               _fgets(init_new_pin_val, 9);
-
-               new_pin.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               new_pin.pw_len = strlen(init_new_pin_val);
-               TEST_DEBUG("pw_len[%d]", new_pin.pw_len);
-               new_pin.pw = (unsigned char*) malloc(length);
-               memcpy(new_pin.pw, init_new_pin_val, length);
-
-               err_code = tel_change_sim_pins(&old_pin, &new_pin, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       //change pin2 number
-       else if (memcmp(buf, "chpin2", sizeof("chpin2") - 1) == 0) {
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_old_pin_val[length];
-               char init_new_pin_val[length];
-
-               memset(&init_old_pin_val, 0, length);
-               memset(&init_new_pin_val, 0, length);
-
-               TelSimSecPw_t old_pin = { 0, };
-               TelSimSecPw_t new_pin = { 0, };
-
-               getchar();
-
-               TEST_DEBUG("Change PIN2 CODE");
-               TEST_DEBUG("Input Current PIN2 Code: ");
-
-               _fgets(init_old_pin_val, 9);
-
-               old_pin.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               old_pin.pw_len = strlen(init_old_pin_val);
-               TEST_DEBUG("pw_len[%d]", old_pin.pw_len);
-               old_pin.pw = (unsigned char*) malloc(length);
-               memcpy(old_pin.pw, init_old_pin_val, length);
-
-               TEST_DEBUG("Input New PIN2 Code: ");
-
-               _fgets(init_new_pin_val, 9);
-
-               new_pin.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               new_pin.pw_len = strlen(init_new_pin_val);
-               TEST_DEBUG("pw_len[%d]", new_pin.pw_len);
-               new_pin.pw = (unsigned char*) malloc(length);
-               memcpy(new_pin.pw, init_new_pin_val, length);
-
-               err_code = tel_change_sim_pins(&old_pin, &new_pin, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // unblock CHV and enter new pin code
-       else if (memcmp(buf, "puk1", sizeof("puk1") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("PUK1 verification");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-               char init_puk_val[length];
-
-               TEST_DEBUG("Plese input PUK CODE: ");
-
-               _fgets(init_puk_val, 9);
-
-               TEST_DEBUG("NEW PIN1 CODE: ");
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t puk_data = { 0, };
-               TelSimSecPw_t new_pin_data = { 0, };
-
-               puk_data.type = TAPI_SIM_PTYPE_PUK1; // 0x00
-               puk_data.pw_len = strlen(init_puk_val);
-               TEST_DEBUG("pw_len[%d]", puk_data.pw_len);
-               puk_data.pw = (unsigned char*) malloc(length);
-               memcpy(puk_data.pw, init_puk_val, length);
-
-               new_pin_data.type = TAPI_SIM_PTYPE_PIN1; // 0x00
-               new_pin_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", new_pin_data.pw_len);
-               new_pin_data.pw = (unsigned char*) malloc(length);
-               memcpy(new_pin_data.pw, init_pin_val, length);
-
-               //  sim pin init
-               TEST_DEBUG("PUKtype Value %d",puk_data.type);
-               TEST_DEBUG("PUK Value %s",puk_data.pw);
-               TEST_DEBUG("New Pin Value %s",new_pin_data.pw);
-
-               err_code = tel_verify_sim_puks(&puk_data, &new_pin_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       // unblock CHV2 and enter new pin2 code
-       else if (memcmp(buf, "puk2", sizeof("puk2") - 1) == 0) {
-               getchar();
-
-               TEST_DEBUG("PUK2 verification");
-
-               int length = TAPI_SIM_PIN_LENGTH + 1;
-               char init_pin_val[length];
-               char init_puk_val[length];
-
-               TEST_DEBUG("Plese input PUK2 CODE: ");
-
-               _fgets(init_puk_val, 9);
-
-               TEST_DEBUG("NEW PIN2 CODE: ");
-               _fgets(init_pin_val, 9);
-
-               TelSimSecPw_t puk_data = { 0, };
-               TelSimSecPw_t new_pin_data = { 0, };
-
-               puk_data.type = TAPI_SIM_PTYPE_PUK2; // 0x00
-               puk_data.pw_len = strlen(init_puk_val);
-               TEST_DEBUG("pw_len[%d]", puk_data.pw_len);
-               puk_data.pw = (unsigned char*) malloc(length);
-               memcpy(puk_data.pw, init_puk_val, length);
-
-               new_pin_data.type = TAPI_SIM_PTYPE_PIN2; // 0x00
-               new_pin_data.pw_len = strlen(init_pin_val);
-               TEST_DEBUG("pw_len[%d]", new_pin_data.pw_len);
-               new_pin_data.pw = (unsigned char*) malloc(length);
-               memcpy(new_pin_data.pw, init_pin_val, length);
-
-               //  sim pin init
-               TEST_DEBUG("PUKtype Value %d",puk_data.type);
-               TEST_DEBUG("PUK Value %s",puk_data.pw);
-               TEST_DEBUG("New Pin Value %s",new_pin_data.pw);
-
-               err_code = tel_verify_sim_puks(&puk_data, &new_pin_data, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "mepers", sizeof("mepers") - 1) == 0) {
-               int tempi;
-               char dummy;
-
-               TelSimPersPw_t lock_pers = { 0, };
-
-               printf("------------------------------ \n");
-               printf("Personalization Type : \n");
-               printf("------------------------------ \n");
-               printf("1 - Network  \n");
-               printf("2 - Network Subset \n");
-               printf("3 - Service Provider \n");
-               printf("4 - Corporate \n");
-               printf("------------------------------ \n");
-
-               printf("\nPlease input type: \n");
-               scanf("%d%c", &tempi, &dummy);
-
-               switch (tempi) {
-               case 1: {
-                       lock_pers.type = TAPI_SIM_PERS_NET;
-               }
-                       break;
-
-               case 2: {
-                       lock_pers.type = TAPI_SIM_PERS_NS;
-               }
-                       break;
-
-               case 3: {
-                       lock_pers.type = TAPI_SIM_PERS_SP;
-               }
-                       break;
-
-               case 4: {
-                       lock_pers.type = TAPI_SIM_PERS_CP;
-               }
-                       break;
-
-               default: {
-                       printf("wrong pers type! exit!\n");
-                       exit(1);
-               }
-                       break;
-               }
-
-               switch (lock_pers.type) {
-               case TAPI_SIM_PERS_NET: {
-                       puts("Flushing input - Enter \\n to exit! ");
-
-                       while ((ch = getchar()) != '\n' && ch != EOF)
-                               ;
-
-                       printf("Lock Personalisation MCC+MNC 5\n");
-                       printf(
-                                       "Plese input Network Lock CODE : length of MCC+MNC, MCC, MNC, NCK\n");
-                       printf(
-                                       "We need to use this for testing : length of MCC+MNC(5), MCC(450), MNC(01), NCK(12345678) => 54500112345678\n");
-
-                       int length = 14 + 1;
-                       char init_password_val[length];
-                       _fgets(init_password_val, 15);
-
-                       lock_pers.pw_len = 14;
-                       lock_pers.pw = (unsigned char*) malloc(length);
-                       memcpy(lock_pers.pw, init_password_val, length);
-
-               }
-                       break;
-
-               case TAPI_SIM_PERS_NS: {
-                       puts("Flushing input - Enter \\n to exit! ");
-
-                       while ((ch = getchar()) != '\n' && ch != EOF)
-                               ;
-
-                       printf(
-                                       "Network Subset Personalisation MCC+MNC 5 byte, subset 2byte \n");
-                       printf(
-                                       "We need to use this for testing : length of MCC+MNC(5), MCC(450), MNC(01), lengthof NSP(2), NSP(11) NSPCK(12345678) => 54500121112345678\n");
-
-                       int length = 17 + 1;
-                       char init_password_val[length];
-                       _fgets(init_password_val, 18);
-
-                       lock_pers.pw_len = 17;
-                       lock_pers.pw = (unsigned char*) malloc(length);
-                       memcpy(lock_pers.pw, init_password_val, length);
-               }
-                       break;
-
-               case TAPI_SIM_PERS_SP: {
-                       puts("Flushing input - Enter \\n to exit! ");
-
-                       while ((ch = getchar()) != '\n' && ch != EOF)
-                               ;
-
-                       printf(
-                                       "Service Provider Personalisation MCC+MNC 5 byte, SP 2byte \n");
-                       printf(
-                                       "We need to use this for testing : length of MCC+MNC(5), MCC(450), MNC(01), SP(11) SPCK(12345678) => 5450011112345678\n");
-
-                       int length = 16 + 1;
-                       char init_password_val[length];
-                       _fgets(init_password_val, 17);
-
-                       lock_pers.pw_len = 16;
-                       lock_pers.pw = (unsigned char*) malloc(length);
-                       memcpy(lock_pers.pw, init_password_val, length);
-               }
-                       break;
-
-               case TAPI_SIM_PERS_CP: {
-                       puts("Flushing input - Enter \\n to exit! ");
-
-                       while ((ch = getchar()) != '\n' && ch != EOF)
-                               ;
-
-                       printf(
-                                       "Corporate Personalisation MCC+MNC 5 byte, SP 2byte CP 2byte \n");
-                       printf(
-                                       "We need to use this for testing : length of MCC+MNC(5), MCC(450), MNC(01), SP(11) CP(11) CPCK(12345678) => 545001111112345678\n");
-
-                       int length = 18 + 1;
-                       char init_password_val[length];
-                       _fgets(init_password_val, 19);
-
-                       lock_pers.pw_len = 18;
-                       lock_pers.pw = (unsigned char*) malloc(length);
-                       memcpy(lock_pers.pw, init_password_val, length);
-               }
-                       break;
-
-               default: {
-                       printf("wrong condition exit\n");
-                       exit(1);
-               }
-                       break;
-               }
-
-               err_code = tel_enable_sim_personalization(&lock_pers, &request_id);
-               printf("Error Code [%x]\n", err_code);
-
-       }
-
-       if (memcmp(buf, "medepers", sizeof("medepers") - 1) == 0) {
-               int tempi;
-               char dummy;
-
-               TelSimPersPw_t lock_pers = { 0, };
-
-               printf("------------------------------ \n");
-               printf("de-Personalization Type : \n");
-               printf("------------------------------ \n");
-               printf("1 - Network  \n");
-               printf("2 - Network Subset \n");
-               printf("3 - Service Provider \n");
-               printf("4 - Corporate \n");
-               printf("------------------------------ \n");
-
-               printf("\nPlease input type: \n");
-               scanf("%d%c", &tempi, &dummy);
-
-               switch (tempi) {
-               case 1: {
-                       lock_pers.type = TAPI_SIM_PERS_NET;
-               }
-                       break;
-
-               case 2: {
-                       lock_pers.type = TAPI_SIM_PERS_NS;
-               }
-                       break;
-
-               case 3: {
-                       lock_pers.type = TAPI_SIM_PERS_SP;
-               }
-                       break;
-
-               case 4: {
-                       lock_pers.type = TAPI_SIM_PERS_CP;
-               }
-                       break;
-
-               default: {
-                       printf("wrong pers type! exit!\n");
-                       exit(1);
-               }
-                       break;
-               }
-
-               puts("Flushing input - Enter \\n to exit! ");
-
-               while ((ch = getchar()) != '\n' && ch != EOF)
-                       ;
-
-               printf("de Personalisation key is 8 byte \n");
-               printf("We need to use this for testing : 12345678\n");
-
-               int length = 8 + 1;
-               char init_password_val[length];
-               _fgets(init_password_val, 9);
-
-               lock_pers.pw_len = 8 /*control key*/;
-               lock_pers.pw = (unsigned char*) malloc(length);
-               memcpy(lock_pers.pw, init_password_val, length);
-
-               err_code = tel_disable_sim_personalization(&lock_pers, &request_id);
-
-               printf("Error Code [%x]\n", err_code);
-
-       }
-
-       if (memcmp(buf, "getpers", sizeof("getpers") - 1) == 0) {
-               int tempi = 0;
-               char dummy = 0;
-
-               TelSimPersType_t type = 0;
-
-               puts("Flushing input - Enter \\n to exit! ");
-
-               while ((ch = getchar()) != '\n' && ch != EOF)
-                       ;
-
-               printf("getpers status\n");
-               printf("Here - 1\n");
-               printf(
-                               "================================================================ \n");
-               printf("TAPI_SIM_PERS_NET               = 0x00, /**< Network Lock */ \n");
-               printf("TAPI_SIM_PERS_NS                = 0x01, /**< Nettwork Subset Lock */\n");
-               printf("TAPI_SIM_PERS_SP                = 0x02, /**< Service Provider Lock */\n");
-               printf("TAPI_SIM_PERS_CP                = 0x03, /**< Coporate Lock */\n");
-               printf(
-                               "================================================================ \n");
-               printf("Plese input Lock type \n");
-
-               scanf("%d%c", &tempi, &dummy);
-               type = tempi;
-
-               err_code = tel_get_sim_personalization_status(type, &request_id);
-               printf("Error Code [%x]\n", err_code);
-
-       } else if (memcmp(buf, "setlang", sizeof("setlang") - 1) == 0) {
-               int tempi;
-               char dummy;
-
-               TelSimLanguagePreferenceCode_t language = 0x00;
-
-               printf("------------------------------ \n");
-               printf("select language which will be updated: \n");
-               printf("------------------------------ \n");
-               printf("should select inside here ( 0.DE / 1.EN / 2.IT / 3.FR ) \n");
-               printf(
-                               "should select inside here ( 4.SPANISH / 5.DUTCH / 6.SWEDISH / 7.DANISH ) \n");
-               printf(
-                               "should select inside here ( 8.PORTUGUESE / 9.FINNISH / 10.NORWEGIAN / 11.GREEK ) \n");
-               printf(
-                               "should select inside here ( 12.TURKISH / 13.HUNGARIAN / 14.POLISH / 15.KOREAN ) \n");
-               printf(
-                               "should select inside here ( 16.CHINESE / 17.RUSSIAN / 18.JAPANESE ) \n");
-               printf("------------------------------ \n");
-
-               printf("\nPlease input type: \n");
-               scanf("%d%c", &tempi, &dummy);
-
-               language = (TelSimLanguagePreferenceCode_t) tempi;
-
-               err_code = tel_set_sim_language(language, &request_id);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API SUCCESS");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "apdu", sizeof("apdu") - 1) == 0) {
-               printf("------------------------------ \n");
-               printf("APDU\n");
-               printf("------------------------------ \n");
-
-               TelSimApdu_t apdu_data = { 0, };
-
-               char tmp_apdu[4] = { 0x41, 0xC0, 0x05, 0x6f };
-
-               apdu_data.apdu_len = 4;
-               apdu_data.apdu = (unsigned char*) &tmp_apdu;
-
-               err_code = tel_req_sim_apdu(&apdu_data, &request_id);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API SUCCESS");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "atr", sizeof("atr") - 1) == 0) {
-               printf("------------------------------ \n");
-               printf("ATR request: \n");
-               printf("------------------------------ \n");
-
-               err_code = tel_req_sim_atr(&request_id);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API SUCCESS");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       }
-
-       ////////////////////////////////////////////////////////////////////////
-       ///////////////////////  Phone Book ///////////////////////////////////
-       ///////////////////////////////////////////////////////////////////////
-       else if (memcmp(buf, "pbcapa", sizeof("pbcapa") - 1) == 0) {
-               TEST_DEBUG("PB capability info");
-
-               err_code = tel_get_sim_pb_3g_meta_info(&request_id);
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "pbcnt", sizeof("pbcnt") - 1) == 0) {
-               TEST_DEBUG("PB storage count info");
-
-               TelSimPbFileType_t storage_type = __InputStorageType();
-
-               __PrintStorageType(storage_type);
-
-               err_code = tel_get_sim_pb_count(storage_type, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "pbentry", sizeof("pbentry") - 1) == 0) {
-               TEST_DEBUG("PB Entry info");
-
-               TelSimPbFileType_t storage_type = __InputStorageType();
-
-               err_code = tel_get_sim_pb_meta_info(storage_type, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       ///////////////////////////////////
-       /*
-        0x01 : ADD
-        0x02 : DELETE
-        0x03 : EDIT
-        0x04 : WRITE (�ش� index�� data ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ unconditional write)
-        0x05 : DELETE ALL (�ش� phone book id�� ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½Ï´ï¿½ ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½Í¸ï¿½ delete)
-        */
-       else if (memcmp(buf, "pbadd", sizeof("pbadd") - 1) == 0) {
-               TelSimPbRecordData_t pb_add = { 0, };
-               char dummy;
-               char unicode_text[256];
-               int unicode_text_len = 0;
-               int index = 0;
-
-               TelSimPbFileType_t storage_type = __InputStorageType();
-               pb_add.StorageFileType = storage_type;
-
-               TEST_DEBUG("Plese input index : ");
-               scanf("%d%c", &index, &dummy);
-               pb_add.Index = index;
-
-               if (pb_add.StorageFileType == TAPI_SIM_PB_EN || pb_add.StorageFileType
-                               == TAPI_SIM_PB_FDN || pb_add.StorageFileType
-                               == TAPI_SIM_PB_MSISDN || pb_add.StorageFileType
-                               == TAPI_SIM_PB_LDN || pb_add.StorageFileType == TAPI_SIM_PB_ADN
-                               || pb_add.StorageFileType == TAPI_SIM_PB_SDN) {
-                       int tmpInput;
-                       TEST_DEBUG("2g phone book entry");
-
-                       TEST_DEBUG(" Number Types are below ");
-                       TEST_DEBUG(" 1 - INTERNATIONAL");
-                       TEST_DEBUG(" 2 - NATIONAL");
-                       TEST_DEBUG(" 3 - NETWORK");
-                       TEST_DEBUG(" 4 - DEDICATE");
-                       TEST_DEBUG("Select Numer Type: ");
-
-                       scanf("%d%c", &tmpInput, &dummy);
-                       pb_add.ContactInfo.Pb2GData.NumType = tmpInput;
-
-                       TEST_DEBUG("Plese input contact number : ");
-                       _fgets((char *) pb_add.ContactInfo.Pb2GData.Number, 15);
-                       pb_add.ContactInfo.Pb2GData.NumLen = strlen(
-                                       (char*) pb_add.ContactInfo.Pb2GData.Number);
-
-                       TEST_DEBUG(" Encryption Types are below ");
-                       TEST_DEBUG(" 1 - ASCII - DO NOT SUPPORT");
-                       TEST_DEBUG(" 2 - GSM7 Bit");
-                       TEST_DEBUG(" 3 - UCS2");
-                       TEST_DEBUG(" 4 - HEX - DO NOT SUPPORT");
-                       TEST_DEBUG("Select Text Encryption Type: ");
-
-                       scanf("%d%c", &tmpInput, &dummy);
-                       pb_add.ContactInfo.Pb2GData.NameEncryptType = tmpInput - 1;
-
-                       TEST_DEBUG("Plese input contact name : ");
-                       _fgets((char *) pb_add.ContactInfo.Pb2GData.Name, 20);
-
-                       if (pb_add.ContactInfo.Pb2GData.NameEncryptType
-                                       == TAPI_SIM_TEXT_ENC_UCS2) {
-                               TEST_DEBUG("TAPI_SIM_TEXT_ENC_UCS2 Encoding");
-                               /* unicode encoding */
-                               if (FALSE == __encode_text_unicode(
-                                               strlen((char *) pb_add.ContactInfo.Pb2GData.Name),
-                                               (char*) pb_add.ContactInfo.Pb2GData.Name,
-                                               (char *) &unicode_text_len, unicode_text)) {
-                                       TEST_DEBUG("Encoding failed ! ");
-
-                               } else {
-                                       pb_add.ContactInfo.Pb2GData.NameLen = unicode_text_len;
-                                       memcpy(pb_add.ContactInfo.Pb2GData.Name, unicode_text,
-                                                       unicode_text_len);
-                               }
-                       } else {
-                               pb_add.ContactInfo.Pb2GData.NameLen = strlen(
-                                               (char *) pb_add.ContactInfo.Pb2GData.Name);
-                       }
-               } else if (pb_add.StorageFileType == TAPI_SIM_PB_3GSIM) {
-                       int tempi;
-                       char num_field_type;
-                       int i = 0;
-
-                       TEST_DEBUG("3g phone book entry");
-
-                       TEST_DEBUG("Input Nuumber of fields to be entered: ");
-
-                       scanf("%d%c", &tempi, &dummy);
-
-                       num_field_type = tempi;
-
-                       pb_add.ContactInfo.Pb3GData.FileTypeCount = num_field_type;
-
-                       for (i = 0; i < num_field_type; i++) {
-                               TEST_DEBUG(" Field Types are below ");
-                               TEST_DEBUG(" 1 - Contact Name : (EF_ADN)");
-                               TEST_DEBUG(" 2 - Contact Mobile Number (EF_ADN)");
-                               TEST_DEBUG(" 3 - Contact Another Number (EF_ANR)");
-                               TEST_DEBUG(" 4 - Contact Email (EF_EMAIL)");
-                               TEST_DEBUG(" 5 - Contact Nick Name (EF_SNE)");
-                               TEST_DEBUG(" 6 - Contact Group (EF_GRP)");
-                               TEST_DEBUG(" 7 - Contact Hidden entry (EF_PBC) - NOT SUPPORT YET");
-                               TEST_DEBUG(" 8 - Contact Another Number A (EF_ANRA)");
-                               TEST_DEBUG(" 9 - Contact Another Number B (EF_ANRB)");
-
-                               TEST_DEBUG("Select Field type: ");
-
-                               scanf("%d%c", &tempi, &dummy);
-
-                               pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileType = tempi;
-
-                               if (tempi == 1 || tempi == 4 || tempi == 5 || tempi == 6) {
-                                       TEST_DEBUG(" Encryption Types are below ");
-                                       TEST_DEBUG(" 1 - ASCII");
-                                       TEST_DEBUG(" 2 - GSM7 Bit");
-                                       TEST_DEBUG(" 3 - UCS2");
-                                       TEST_DEBUG(" 4 - HEX");
-                                       TEST_DEBUG("Select Text Encryption Type: ");
-
-                                       scanf("%d%c", &tempi, &dummy);
-                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.EncryptionType
-                                                       = tempi - 1;
-
-                               } else {
-                                       TEST_DEBUG(" Number Types are below ");
-                                       TEST_DEBUG(" 1 - INTERNATIONAL");
-                                       TEST_DEBUG(" 2 - NATIONAL");
-                                       TEST_DEBUG(" 3 - NETWORK");
-                                       TEST_DEBUG(" 4 - DEDICATE");
-                                       TEST_DEBUG("Select Numer Type: ");
-
-                                       scanf("%d%c", &tempi, &dummy);
-                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.NumType
-                                                       = tempi;
-                               }
-
-                               if (pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                               == TAPI_PB_3G_GRP) {
-                                       int c, count, k = 0;
-
-                                       TEST_DEBUG("Please input number of index to add in GRP");
-                                       scanf("%d%c", &tempi, &dummy);
-
-                                       count = tempi;
-                                       for (c = 0; c < count; c++) {
-                                               TEST_DEBUG("Please input index of GRP: ");
-                                               scanf("%d%c", &tempi, &dummy);
-
-                                               pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData[k]
-                                                               = tempi;
-                                               k++;
-                                               //pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData[k] = 0;
-                                               //k++;
-                                       }
-                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength
-                                                       = count;
-                               } else if (pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                               == TAPI_PB_3G_NAME
-                                               || pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                               == TAPI_PB_3G_EMAIL
-                                               || pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileType
-                                                               == TAPI_PB_3G_SNE) {
-                                       TEST_DEBUG("Plese input  field string data: ");
-                                       _fgets(
-                                                       (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                       30);
-
-                                       TEST_DEBUG("strlen about input data[%d]",strlen((char *)pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData) );
-
-                                       if (pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataType.EncryptionType
-                                                       == TAPI_SIM_TEXT_ENC_UCS2) {
-                                               /* unicode encoding */
-                                               if (FALSE
-                                                               == __encode_text_unicode(
-                                                                               strlen(
-                                                                                               (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData),
-                                                                               (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                                               (char *) &unicode_text_len,
-                                                                               unicode_text)) {
-                                                       TEST_DEBUG("Encoding failed ! ");
-                                               } else {
-                                                       memcpy(
-                                                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                                       unicode_text, unicode_text_len);
-                                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength
-                                                                       = unicode_text_len;
-                                               }
-                                       } else {
-                                               pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength
-                                                               = strlen(
-                                                                               (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData);
-                                       }
-                               } else {
-                                       TEST_DEBUG("Plese input  field data: ");
-                                       _fgets(
-                                                       (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData,
-                                                       20);
-                                       pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileDataLength
-                                                       = strlen(
-                                                                       (char *) pb_add.ContactInfo.Pb3GData.PbFileDataInfo[i].FileData);
-                               }
-
-                       }
-
-               } else if (pb_add.StorageFileType == TAPI_SIM_PB_AAS
-                               || pb_add.StorageFileType == TAPI_SIM_PB_GAS) {
-                       TEST_DEBUG("additional num Alpha string or Group Alpha string ");
-
-                       TEST_DEBUG("Plese input Alpha name : ");
-                       _fgets(
-                                       (char *) pb_add.ContactInfo.PbAdditionalNumStringData.TextData,
-                                       20);
-#if 0
-                       /* GSM 7bit conversion */
-                       __encode_gsm_7_bit_chars(strlen((char *)pb_add.ContactInfo.PbAdditionalNumStringData.TextData) ,
-                                       (char *)pb_add.ContactInfo.PbAdditionalNumStringData.TextData, (char *)&unicode_text_len, unicode_text);
-
-                       memcpy(pb_add.ContactInfo.PbAdditionalNumStringData.TextData, unicode_text, unicode_text_len );
-
-                       pb_add.ContactInfo.PbAdditionalNumStringData.TextLength = unicode_text_len;
-
-                       pb_add.ContactInfo.PbAdditionalNumStringData.EncryptionType = TAPI_SIM_TEXT_ENC_GSM7BIT; // always 2 for GAS and AAS
-#endif
-                       pb_add.ContactInfo.PbAdditionalNumStringData.TextLength
-                                       = strlen(
-                                                       (char *) pb_add.ContactInfo.PbAdditionalNumStringData.TextData);
-                       pb_add.ContactInfo.PbAdditionalNumStringData.EncryptionType
-                                       = TAPI_SIM_TEXT_ENC_GSM7BIT; // But real type is ASCII (because current GSM7 is GSM7 with bit 8 set to '0')
-
-               } else {
-                       TEST_DEBUG("Undefined Storage File Type [0x%x]", pb_add.StorageFileType);
-
-               }
-
-               err_code = tel_update_sim_pb_record(&pb_add, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "pbdel", sizeof("pbdel") - 1) == 0) {
-               TelSimPbFileType_t storage_type = __InputStorageType();
-
-               TEST_DEBUG(" PB delete ");
-
-               unsigned short index = 0;
-               char dummy = 0;
-               TEST_DEBUG("Plese input index : ");
-               scanf("%d%c", (int *)&index, &dummy);
-
-               err_code = tel_delete_sim_pb_record(storage_type, index, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-
-       } else if (memcmp(buf, "pbread", sizeof("pbread") - 1) == 0) {
-               TEST_DEBUG("PB read");
-
-               unsigned short index = 0;
-               char dummy = 0;
-
-               TelSimPbFileType_t storage_type = __InputStorageType();
-
-               TEST_DEBUG("Plese input index : ");
-               scanf("%d%c", (int *)&index, &dummy);
-
-               err_code = tel_read_sim_pb_record(storage_type, index, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "isimauth", sizeof("isimauth") - 1) == 0) {
-               TEST_DEBUG("ISIM Authentication ");
-#if 0
-               getchar();
-
-               TelSimAuthenticationData_t auth_req = { 0, };
-
-               memset(&auth_req, 0, sizeof(TelSimAuthenticationData_t));
-
-               TEST_DEBUG(" Enter  RAND data ");
-               _fgets((char *) &auth_req.rand_data, 20);
-
-               auth_req.rand_length
-                               = strlen((char *) auth_req.rand_data);
-
-               TEST_DEBUG(" Enter Authentication  data ");
-               _fgets((char *) &auth_req.autn_data, 20);
-
-               auth_req.autn_length = strlen((char *) auth_req.autn_data);
-
-               TEST_DEBUG("TelTapiSimIsimAuthenticationRequest is not tested yet!");
-               /*
-                err_code = TelTapiSimIsimAuthenticationRequest( &auth_req, &request_id);
-
-                if(err_code == TAPI_API_SUCCESS)
-                {
-                TEST_DEBUG("TAPI API SUCCESS");
-                }
-                else
-                {
-                TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-                }
-                */
-#endif
-       }
-
-       else if (memcmp(buf, "sapcon", sizeof("sapcon") - 1) == 0) {
-               TEST_DEBUG("SAP Connect request  ");
-               TelSimSapConnect_t con_req = { 0, };
-               con_req.MsgId = TAPI_SIM_SAP_CONNECT_REQ;
-               con_req.MaxMsgSize = 10; //temp for testing only - not clear
-
-               err_code = tel_req_sap_connection(&con_req, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapdiscon", sizeof("sapdiscon") - 1) == 0) {
-               TEST_DEBUG("SAP Disconnect request  ");
-               TelSimSapConnect_t con_req = { 0, };
-               con_req.MsgId = TAPI_SIM_SAP_DISCONNECT_REQ;
-               con_req.MaxMsgSize = 10; //temp for testing only - not clear
-
-               err_code = tel_req_sap_connection(&con_req, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapstatus", sizeof("sapstatus") - 1) == 0) {
-               TEST_DEBUG("SAP Status request  ");
-
-               err_code = tel_req_sap_connection_status(&request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapatr", sizeof("sapatr") - 1) == 0) {
-               TEST_DEBUG("SAP ATR request  ");
-
-               err_code = tel_req_sap_transfer_atr(&request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapapdu", sizeof("sapapdu") - 1) == 0) {
-               TEST_DEBUG("SAP APDU transfer  ");
-
-               int file_id = TAPI_SIM_EFILE_ICCID;
-
-               /* for selecting EF ICCID */
-               TelSimSapApduData_t apdu_data;
-
-               apdu_data.ApduLength = 7;
-               apdu_data.Apdu[0] = 0xA0; // class
-               apdu_data.Apdu[1] = 0xA4; // instruction
-               apdu_data.Apdu[2] = 0; // p1 = parameter 1
-               apdu_data.Apdu[3] = 0; // p2 = parameter 2
-               apdu_data.Apdu[4] = 2; // p3 - parameter 3
-
-               memcpy(&apdu_data.Apdu[5], &file_id, sizeof(unsigned short));
-
-               err_code = tel_req_sap_transfer_apdu(&apdu_data, &request_id);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API SUCCESS");
-               } else {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapsetproto", sizeof("sapsetproto") - 1) == 0) {
-               TEST_DEBUG("SAP set protocol ");
-               TelSimSapProtocol_t protocol = TAPI_SIM_SAP_PROTOCOL_T0;
-
-               err_code = tel_req_sap_transport_protocol(protocol, &request_id);
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       else if (memcmp(buf, "sapsimpwr", sizeof("sapsimpwr") - 1) == 0) {
-               int tempi = 0;
-               TelSimSapMsgId_t msdId = 0;
-
-               char dummy = 0;
-
-               TEST_DEBUG("SAP SIM power  ");
-
-               TEST_DEBUG("Please input SAP SIM power on(1) / off(!1): ");
-
-               scanf("%d%c", &tempi, &dummy);
-               if (tempi == 1)
-                       msdId = TAPI_SIM_SAP_POWER_SIM_ON_REQ;
-               else
-                       msdId = TAPI_SIM_SAP_POWER_SIM_OFF_REQ;
-
-               err_code = tel_req_sap_power_operation(msdId, &request_id);// only for testing
-
-               if (err_code != TAPI_API_SUCCESS) {
-                       TEST_DEBUG("TAPI API FAIL: Error Code [0x%x]",err_code);
-               }
-       }
-
-       if (memcmp(buf, "close", sizeof("close") - 1) == 0) {
-               TEST_DEBUG(" close reuqest ");
-
-               //      err_code = tapi_sim_close(92);
-
-               //err_code = tapi_sim_close(g_test_hsim);
-               TEST_DEBUG(" ret value from close [0x%x]", err_code);
-
-               if (err_code == TAPI_API_SUCCESS) {
-                       TEST_DEBUG(" sim close OK!");
-               } else {
-                       TEST_DEBUG(" SIM close request returned error [0x%x] !",err_code );
-               }
-               TEST_DEBUG("Request ID [0x%x]", request_id);
-       }
-
-       if (memcmp(buf, "q", sizeof("q") - 1) == 0) {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu");
-               return -1;
-               //exit(0);
-       }
-
-       return 0;
-}
-
-void sim_select_loop(void) {
-       int ret;
-       fd_set readfds;
-
-       while (1) {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret) {
-
-                       if (FD_ISSET(0, &readfds)) {
-                               if (sim_read_key_input() < 0)
-                                       break;
-                       }
-               }
-       }
-}
-
-void* sim_test_thread_loop(void* data) {
-       TEST_DEBUG(" sim_test_thread_loop : called...");
-
-       sim_select_loop();
-
-       TEST_DEBUG(" sim_test_thread_loop : stdin Loop exited");
-
-       pthread_exit(NULL);
-}
-
-int sim_main(int argc, char *argv[]) {
-       pthread_t p_thread;
-
-       p_thread = pthread_create(&p_thread, NULL, sim_test_thread_loop, NULL);
-
-       if (p_thread != 0) {
-               TEST_DEBUG("Failed while creating a thread to read from stdin");
-               return -1;
-       } else {
-               TEST_DEBUG("A thread was created to read from stdin ..");
-       }
-
-       sim_test_subscribe_tapi_events();
-
-       pthread_join(p_thread, NULL);
-
-       TEST_DEBUG("Exiting sim test program bye bye !");
-
-       return 0;
-}
-
diff --git a/src/test_apps/tapi_sms_test.c b/src/test_apps/tapi_sms_test.c
deleted file mode 100644 (file)
index ac25704..0000000
+++ /dev/null
@@ -1,2713 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <glib.h>
-#include <string.h>
-#include <unistd.h>
-#include <assert.h>
-#include <glib.h>
-
-#include "TelUtility.h"
-#include <TapiCommon.h>
-#include <TelNetText.h>
-#include <ITapiNetText.h>
-
-#include "tapi_test_utility.h"
-#include "tapi_sms_test.h"
-
-/******* prototype ******* */
-#include "tapi_sms_util.h"
-
-#define        TAPI_NETTEXT_MSG_SIZE_MAX                               918
-#define        TAPI_NETTEXT_CB_SIZE_MAX                                93
-#define        TAPI_NETTEXT_ADDRESS_LEN_MAX                    20
-#define        TAPI_NETTEXT_SCADDRESS_LEN_MAX                  18
-
-#define TEST_DEBUG(frmt, args...)      \
-{do { fprintf(stderr, "[SMS Test][%s:%04d] "frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-// Global Variable
-static unsigned int *  SMS_subscription_id;
-int                                    dcs_pos =0;
-unsigned int                   SmsMsgId = 0;
-
-// same as tapievent
-typedef struct
-{
-       int group;
-       int type;
-       int requestid;
-       int status;
-       void *dst;
-}data_t;
-
-//extern int EvtDeliveryHandle ;
-//int error_code;
-
-TS_UINT8 tp_mr = 0x00;
-
-
-BOOL EncodeCdmaSmsParamTeleservice(int teleservice_id ,ParamTeleserv_t *ParamTeleserv)
-{
-       BOOL ret = FALSE;
-
-       if(ParamTeleserv == NULL){
-               printf("[EncodeCdmaSmsParamTeleservice] NULL pointer  \n");
-               return ret;
-       }
-
-       switch(teleservice_id){
-               case TELESERVICEID_CPT95:
-               case TELESERVICEID_CMT95:
-               case TELESERVICEID_VMN95:
-               case TELESERVICEID_WAP:
-                       ret = TRUE;
-                       break;
-               default:
-                       ret = FALSE;
-       }
-
-       if(ret == TRUE){
-               ParamTeleserv->param_id = PARAMID_TELESERVICE_ID;
-               ParamTeleserv->param_len = 2;
-               ParamTeleserv->teleserv_id = teleservice_id;
-       }
-
-       return ret;
-}
-
-BOOL EncodeCdmaSmsParamDestAddress(int NumberPlan, char* diallingNum ,ParamAddress_t *ParamAddr)
-{
-       BOOL ret = FALSE;
-       int length = 0;
-
-       if(ParamAddr == NULL || diallingNum == NULL){
-               printf("[EncodeCdmaSmsParamAddress] NULL pointer  \n");
-               return ret;
-       }
-
-       length = strlen(diallingNum); //remove CR
-
-       ParamAddr->param_id = PARAMID_ADDRESS;
-       ParamAddr->len = length;
-       ParamAddr->digit = DIGITMODE_4BITDTMF;
-       ParamAddr->num = NUMMODE_NONE_DATANETWORK;
-       ParamAddr->numtype = NUMBER_TYPE_UNKNOWN;
-       ParamAddr->numplan = NumberPlan;
-
-       strncpy((char *)ParamAddr->CHARi, diallingNum, length);
-
-       length +=5;
-       ParamAddr->param_len = length;
-
-       ret = TRUE;
-
-       return ret;
-}
-
-BOOL EncodeCdmaSmsParamCallbackAddress(int NumberPlan, char* diallingNum ,ParamCallback_t *ParamCallback)
-{
-       BOOL ret = FALSE;
-       int length = 0;
-
-       if(ParamCallback == NULL || diallingNum == NULL){
-               printf("[EncodeCdmaSmsParamAddress] NULL pointer  \n");
-               return ret;
-       }
-
-       length = strlen(diallingNum); //remove CR
-
-
-       ParamCallback->param_id = PARAMID_CALLBACK;
-       ParamCallback->digit = DIGITMODE_4BITDTMF;
-       ParamCallback->numtype = NUMBER_TYPE_UNKNOWN;
-       ParamCallback->numplan = NumberPlan;
-       ParamCallback->len = length;
-       strncpy((char *)ParamCallback->CHARi, diallingNum, length);
-
-       length +=4;
-       ParamCallback->param_len = length;
-
-       ret = TRUE;
-
-       return ret;
-}
-
-BOOL EncodeCdmaSmsParamMsgId(int type, ParamMsgId_t *ParamMsg)
-{
-       BOOL ret = FALSE;
-
-       if(ParamMsg == NULL){
-               printf("[EncodeCdmaSmsParamMsgId] NULL pointer  \n");
-               return ret;
-       }
-
-       ParamMsg->param_id = PARAMID_MESSAGE_ID;
-       ParamMsg->param_len =3;
-       ParamMsg->type = type;
-       ParamMsg->msg_id = SmsMsgId++;
-
-
-       ret = TRUE;
-
-       return ret;
-}
-
-BOOL EncodeCdmaSmsParamUserData(char* SendTxt, ParamUserData_t *ParamUser)
-{
-       BOOL ret = FALSE;
-       int length = 0;
-
-       if(ParamUser == NULL || SendTxt == NULL){
-               printf("[EncodeCdmaSmsParamUserData] NULL pointer  \n");
-               return ret;
-       }
-
-       length = strlen(SendTxt);
-
-       ParamUser->param_id = PARAMID_USER_DATA;
-       ParamUser->encoding = MSGENCODING_7BIT_ASCII;
-       strncpy((char *)ParamUser->CHARi, SendTxt, length);
-
-       ParamUser->len =  length;
-       length += 2;;
-       ParamUser->param_len = length;
-
-       ret = TRUE;
-
-       return ret;
-}
-
-BOOL EncodeCdmaSmsSubmitTpdu(char* diallingNum, int dialNumLen, char* msgTxt, int msg_len)
-{
-       ParamTeleserv_t ParamTeleserv = {0, };
-       ParamAddress_t ParamAddr = {0, };
-       //ParamCallback_t Paramcallback = {0, };
-       ParamMsgId_t ParamMsg = {0, };
-       ParamUserData_t ParamUser = {0, };
-
-       int i;
-       int requestId = 0;
-       //char CallbackNum[] = "1117908499";
-       TapiResult_t returnStatus;
-
-       TEST_DEBUG("EncodeCdmaSmsSubmitTpdu Func Enter");
-
-       TelSmsMsgInfo_t *pDataPackage = malloc(sizeof(TelSmsMsgInfo_t));
-       memset(pDataPackage, 0, sizeof(TelSmsMsgInfo_t));
-
-       pDataPackage->MsgType = TAPI_NETTEXT_MESSAGETYPE_SUBMIT;
-
-       //1 TeleService Identifier
-       EncodeCdmaSmsParamTeleservice(TELESERVICEID_CMT95, &ParamTeleserv);
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_TELESERVICE_MASK;
-       memcpy(&pDataPackage->MsgData.OutSubmit.TeleService, &ParamTeleserv.teleserv_id, sizeof(unsigned short));
-       TEST_DEBUG("teleservice at TEST APP: 0x%x", pDataPackage->MsgData.OutSubmit.TeleService);
-
-       //1 Destination Address
-       diallingNum[dialNumLen] = '\0';
-       EncodeCdmaSmsParamDestAddress(NUMBER_PLAN_UNKNOWN, diallingNum, &ParamAddr);
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_ADDRESS_MASK;
-       pDataPackage->MsgData.OutSubmit.DstAddr.Digit = ParamAddr.digit;
-       pDataPackage->MsgData.OutSubmit.DstAddr.NumberMode = ParamAddr.num;
-       pDataPackage->MsgData.OutSubmit.DstAddr.NumberType = ParamAddr.numtype;
-       pDataPackage->MsgData.OutSubmit.DstAddr.NumberPlan = ParamAddr.numplan;
-       pDataPackage->MsgData.OutSubmit.DstAddr.szAddrLength = ParamAddr.len;
-       memcpy(pDataPackage->MsgData.OutSubmit.DstAddr.szAddress, ParamAddr.CHARi, ParamAddr.len);
-
-       //1  Message Identifier
-       EncodeCdmaSmsParamMsgId(MESSAGETYPE_SUBMIT, &ParamMsg);
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_MESSAGE_ID_MASK;
-       pDataPackage->MsgData.OutSubmit.MsgId = ParamMsg.type;
-       pDataPackage->MsgType = ParamMsg.type;
-
-       //1  bearer
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_BEARER_REPLY_MASK;
-       pDataPackage->MsgData.OutSubmit.ReplySeqNumber = 1;
-
-#if 0
-       //1 Callback Address
-       EncodeCdmaSmsParamCallbackAddress(NUMBER_PLAN_UNKNOWN, CallbackNum, &Paramcallback);
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_CALLBACK_MASK;
-       pDataPackage->MsgData.OutSubmit.CallBackNumber.Digit = Paramcallback.digit;
-       pDataPackage->MsgData.OutSubmit.CallBackNumber.NumberType = Paramcallback.numtype;
-       pDataPackage->MsgData.OutSubmit.CallBackNumber.NumberPlan = Paramcallback.numplan;
-       pDataPackage->MsgData.OutSubmit.CallBackNumber.szAddrLength = Paramcallback.len;
-       memcpy(pDataPackage->MsgData.OutSubmit.CallBackNumber.szAddress, Paramcallback.CHARi, Paramcallback.len);
-#endif
-       //1 User Date
-       msgTxt[msg_len - 1] = '\0';
-       EncodeCdmaSmsParamUserData(msgTxt, &ParamUser);
-       pDataPackage->ParamMask |= TAPI_NETTEXT_PARAM_USER_DATA_MASK;
-       pDataPackage->MsgData.OutSubmit.MsgEncoding = ParamUser.encoding;
-       pDataPackage->MsgData.OutSubmit.MsgLength = ParamUser.len;
-       memcpy(pDataPackage->MsgData.OutSubmit.szData, ParamUser.CHARi, ParamUser.len);
-
-       TEST_DEBUG("");
-       TEST_DEBUG("=============== Test App Message =================");
-       TEST_DEBUG(" - MsgType: %d", pDataPackage->MsgType);
-       TEST_DEBUG(" - ParamMask: 0x%08x", pDataPackage->ParamMask);
-       printf("0000: ");
-       for (i = 0; i < sizeof(TelSmsMsgInfo_t); i++) {
-               printf("%02x ", *(((unsigned char *) pDataPackage) + i));
-               if ((i + 1) % 8 == 0)
-                       printf("  ");
-
-               if ((i + 1) % 16 == 0)
-                       printf("\n%04x: ", i+1);
-       }
-       printf("\n");
-       fflush(stdout);
-
-       TEST_DEBUG("==============================================");
-
-       returnStatus = tel_send_sms_msg(pDataPackage, 0x26, &requestId); //more to send is false since it is not concatenated.for concatenated send 1
-
-       TEST_DEBUG("tel_send_sms_msg() returnStatus: %d, requestId: %d", returnStatus, requestId);
-
-       free(pDataPackage);
-
-       return TRUE;
-}
-
-
-BOOL DecodeCellBroadcastMsg(int length,char * pPDU)
-{
-       int                     msgLength;
-       int                     sn = 0; //serial number
-       int                     msgID; //message identifier
-       tapi_nettext_coding_scheme  dcs;
-
-       TS_UINT8        page[2];
-       int                     contents_length;
-       char     contents[TAPI_NETTEXT_CB_SIZE_MAX];
-
-       TS_UINT8        gs;
-       TS_UINT8        msgCode;
-       TS_UINT8        updateNumber;
-
-       if(pPDU == NULL){
-               TEST_DEBUG("pData is Null")
-               return FALSE;
-       }
-
-       TEST_DEBUG("cb msg type is %x",pPDU[0]);
-       TEST_DEBUG("cb msg len is %x",pPDU[1]);
-
-
-       TEST_DEBUG("$$$$$$$$$$$$$$$length of cb msg is %d",length);
-       sn = (pPDU[2] <<8 ) |pPDU[1] ;
-
-       gs = (pPDU[2] & 0xC0) >> 6;  //bit 7, bit 6
-
-       msgCode = (( (pPDU[2] & 0x3F) <<4 ) | pPDU[3] ) & 0xF0 ;
-
-       updateNumber = pPDU[3] & 0x0F;  //bit3, bit2, bit1, bit0
-
-       msgID = pPDU[4] << 4 |pPDU[3];
-
-       SmsUtilDecodeDCS( &dcs, pPDU[6] );
-
-       page[0] = pPDU[7] & 0x0F; //total page
-       page[1] = (pPDU[7] & 0xF0)>>4 ; //current page
-
-
-       msgLength = length -2;
-
-       contents_length = msgLength -6;
-
-       if (dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-       {
-               TS_BYTE inData[TAPI_NETTEXT_CB_SIZE_MAX+1];
-
-               memset( inData, 0x00, TAPI_NETTEXT_CB_SIZE_MAX + 1 );
-
-               memcpy( (void*) inData, (void*) &pPDU[8], contents_length);
-               SmsUtilUnpackGSMCode(contents,  &pPDU[8], msgLength );
-       }
-       else
-       {
-               memcpy( contents, &pPDU[8], msgLength);
-               contents[msgLength] = 0;
-       }
-
-       printf("*************************************\n");
-       printf("serical number : 0x%04x \n" , sn);
-       printf("Geographical Scope: 0x%x\n" , gs);
-       printf("message code : 0x%x\n", msgCode);
-       printf("update Number : 0x%x\n",updateNumber);
-       printf("message identifier :  0x%x\n" , msgID);
-       printf("DCS-Commpressed?: %d (1: true)\n" , dcs.bCompressed);
-       printf("DCS-coding_group_type:  %x\n" , dcs.coding_group_type);
-       printf("contents bytes size : %d\n", contents_length);
-       printf("page : (%d /%d) (page /total ) \n", page[1], page[0] );
-       printf("contents: %s\n", contents);
-       printf("*************************************\n");
-       /*
-          if(dcs.class_type = TAPI_NETTEXT_CLASS_2)
-          {
-          TelSmsDatapackageInfo_t * pDataPackage;
-
-          pDataPackage = malloc(sizeof(TelSmsDatapackageInfo_t));
-
-          pDataPackage->MsgLength =length ;
-          memcpy(pDataPackage->szData, pPDU, pDataPackage->MsgLength);
-
-          returnStatus = TelTapiSmsWrite(0x01, pDataPackage,&requestId);
-          TEST_DEBUG("Write : returnstatus %d requestId :%d",returnStatus,requestId);
-          }
-          */
-       return TRUE;
-}
-
-BOOL EncodeSmsSubmitTpdu(char* diallingNum, int dialNumLen, char* msg, int msg_len)
-{
-
-       TPDU_SMS_SUBMIT tpdu_submit;
-
-       TS_BYTE  packet[TAPI_NETTEXT_MSG_SIZE_MAX];
-
-       TS_BYTE  SCA[TAPI_NETTEXT_SCADDRESS_LEN_MAX]; //send SMS ï¿½Ò¶ï¿½ ï¿½ï¿½ï¿½ï¿½Ï´ï¿½ ï¿½ï¿½ï¿½ï¿½ SCA��
-       int ret = 0;
-
-       //      TS_UINT8 tp_mr = 0x03;
-       tp_mr++;
-       TS_UINT8 tp_pid = 0; //reaplace type (65)
-       TS_UINT8 tp_dcs; //=17; //class_1(17),class_2(18)
-       TS_UINT8 tp_vp;
-
-
-       int index = 0, ScIndex = 0;
-       int i;
-       int requestId=0;
-       unsigned char             sca_len =0;
-       TapiResult_t returnStatus ;
-
-       TelSmsDatapackageInfo_t *pDataPackage= malloc(sizeof(TelSmsDatapackageInfo_t));
-
-       memset(pDataPackage, 0, sizeof(TelSmsDatapackageInfo_t));
-
-       memset(packet, 0, TAPI_NETTEXT_MSG_SIZE_MAX);
-
-       /************SCA ADDRESS GET START**************/
-       /*
-          returnStatus = TelTapiSmsGetSCA(&sc_addr,0);
-          printf("Service center addr returned from TAPI SCA address %s returnStatus %d\n",sc_addr.szDiallingNum,returnStatus);
-          SmsUtilDecodeAddrField(decodeScaAddr, &sc_addr.szDiallingNum[0],&sc_addr.Ton, &sc_addr.Npi);
-          sca_len = strlen( decodeScaAddr );
-
-          memcpy( SCA, decodeScaAddr, sca_len);
-          SCA[sca_len] = '\0';
-          */
-       TEST_DEBUG("Enter SCA: ");
-       memset(SCA,0,sizeof(SCA));
-
-       ret = read(0, SCA, sizeof(SCA));
-
-       if (ret <= 0) {
-               TEST_DEBUG(" NULL msg can NOT be sent ");
-               return -1;
-       }
-
-       sca_len=strlen((char *)SCA)-1;
-
-       TEST_DEBUG("Decode SCA Address =========");
-       TEST_DEBUG("SCA Number :%s, SCA Length :%d ",SCA , sca_len);
-       TEST_DEBUG("========================");
-
-       //SCA ADDRESS GET END
-
-       //SCA
-
-       //TODO : SCA
-
-       //      index +=SmsUtilEncodeAddrField(packet,SCA, strlen(SCA)  ,0x01,0x01);
-       ScIndex  =SmsUtilEncodeAddrField((unsigned char*)pDataPackage->Sca ,(char *)SCA, sca_len  ,0x01,0x01);
-
-
-       TEST_DEBUG("ScIndex is %d", ScIndex);
-
-       // TP-MTI, TP-RD, TP-VPF, TP-SRR, TP_UDHI, TP-RP
-       tpdu_submit.msg_type = SMS_TPDU_SUBMIT;
-       tpdu_submit.rd   =FALSE; //false :accept duplicate msg , true: reject duplicate msg
-       tpdu_submit.vpf = TAPI_NETTEXT_VP_RELATIVE;
-       tpdu_submit.srr  = FALSE;   //false :A status report is not requested , true: A status report is requested
-       tpdu_submit.udhi = FALSE ; //false: contains only the short message , true :a Header in addition to the short message
-       tpdu_submit.rp = FALSE  ; //false :TP Reply Path parameter is not set in this SMS SUBMIT, true : TP Reply Path parameter is set in this SMS SUBMIT
-
-       packet[index] =  tpdu_submit.msg_type;                                                  // SUBMIT: bits 0, 1
-       packet[index] |= tpdu_submit.rd? 0x04 : 0;                                              // bit 2
-       packet[index] |= tpdu_submit.vpf  << 3; // bits 3, 4
-       packet[index] |= tpdu_submit.srr ? 0x20 : 0;                                            // bit 5
-       packet[index] |= tpdu_submit.udhi? 0x40 : 0;                                            // bit 6
-       packet[index] |= tpdu_submit.rp ? 0x80 : 0;                                             // bit 7
-
-       index++;
-       TEST_DEBUG("index of message ref is %d, msgref is %d",index,tp_mr);
-       /* TP-MR */
-       packet[index++] = tp_mr;
-
-       // TP-DA
-       index +=  SmsUtilEncodeAddrField( packet+index, diallingNum, dialNumLen, 0x02, 0x01);
-
-       //TEST_DEBUG("DESTINATTION  ADDR Encoded =========");
-
-       //TP-PID
-       packet[index++] = tp_pid;
-
-       // TP_DCS (Data Coding Scheme)
-
-       tpdu_submit.dcs.bCompressed = FALSE;
-       tpdu_submit.dcs.bmsg_class_set = TRUE;
-       tpdu_submit.dcs.coding_group_type =TAPI_NETTEXT_CODGRP_SM_GENERAL_DCS;
-       tpdu_submit.dcs.alphabet_type = TAPI_NETTEXT_ALPHABET_DEFAULT;
-       tpdu_submit.dcs.class_type = TAPI_NETTEXT_CLASS_2;
-
-       SmsUtilEncodeDCS(&tp_dcs, &tpdu_submit.dcs);
-
-       packet[index++] = tp_dcs;
-
-       //TEST_DEBUG("DCS Encoded:tp_dcs =%d =========",tp_dcs);
-
-       //TP-VP
-
-       tpdu_submit.vp.vp_rel_type = TAPI_NETTEXT_VP_REL_6H ;
-       tpdu_submit.vp.vp_type = TAPI_NETTEXT_VP_RELATIVE;
-       tpdu_submit.vp.vpValue =0xff ;
-
-       SmsUtilEncodeValidity(&tp_vp,&tpdu_submit.vp);
-
-       //tp_vp =65;
-       packet[index++] = tp_vp;
-       //TEST_DEBUG("Validity Encoded :tp_vp =%d =========",tp_vp);
-
-       // UDL
-       packet[index++] = msg_len;
-
-       // TP-UD
-
-       if (tpdu_submit.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-       {
-               int pos;
-               pos =SmsUtilPackGSMCode( packet + index, msg, msg_len);
-               index += pos;
-       }
-
-       TEST_DEBUG("Send packet to phonseSever[%d] -----", index);
-
-       for(i=0; i< index ; i++ )
-       {
-               TEST_DEBUG("[%02x]", packet[i]);
-               if( i%10 == 9)
-                       TEST_DEBUG("\n");
-       }
-       TEST_DEBUG("\n");
-
-       memcpy( pDataPackage->szData, packet, index);
-       pDataPackage->MsgLength = index;
-
-       TEST_DEBUG("***Sending the Message (Api:SendMsg)***");
-
-       TEST_DEBUG("Length : %d",pDataPackage->MsgLength);
-
-       returnStatus = tel_send_sms( pDataPackage, 0 ,&requestId); //more to send is false since it is not concatenated.for concatenated send 1
-
-       TEST_DEBUG("SendMsg : returnStatus=%d requestId=%d", returnStatus, requestId);
-
-       free(pDataPackage);
-
-       return TRUE;
-
-}
-TS_BOOL DecodeSmsSubmitTpdu(int pdu_len, char * pPDU)
-{
-       TPDU_SMS_SUBMIT         tpdu_submit;
-       TS_BYTE              scaAddr_len =0;
-       int                         destAddr_len = 0;
-       char            diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-       char     scaAddr[TAPI_NETTEXT_SCADDRESS_LEN_MAX]; //service center address
-       char        destAddr[TAPI_NETTEXT_ADDRESS_LEN_MAX]; //destination number
-       int         sca_ton, sca_npi, dest_ton,dest_npi;
-       int         position;
-
-       position=0;
-
-       /* SCA_ADDR */
-       memset(diallingNum, 0, sizeof(diallingNum));
-
-       SmsUtilDecodeAddrField(diallingNum, &pPDU[position],&sca_ton, &sca_npi);
-
-       position+=2;  //include Address-Length, Type of Address
-
-       scaAddr_len = strlen( (char *)diallingNum );
-
-       if ( scaAddr_len % 2 )
-               position += scaAddr_len / 2 + 1;
-       else
-               position += scaAddr_len / 2;
-
-
-       if ( sca_ton == SIM_TON_INTERNATIONAL )
-       {
-               scaAddr[0] = '+';
-               memcpy( &scaAddr[1], diallingNum, scaAddr_len );
-               scaAddr[scaAddr_len+1] = '\0';
-       }
-       else
-       {
-               memcpy( scaAddr, diallingNum, scaAddr_len );
-               scaAddr[scaAddr_len] = '\0';
-       }
-
-       //TEST_DEBUG(" sca length: %d , sca # : %s", scaAddr_len, scaAddr);
-
-       /* TP-MTI, TP-RD, TP-VPF,  TP-RP, TP_UDHI, TP-SRR */
-
-       tpdu_submit.msg_type = SMS_TPDU_SUBMIT; // bit 0,1(Message Type Indicator )
-       tpdu_submit.rd = ( pPDU[position] & 0x04 ) ? TRUE : FALSE;// bit 2 (Message Type Indicator)
-       tpdu_submit.vpf =( pPDU[position] & 0x18) >> 3; //  bits 3, 4 ( validity period format)
-       tpdu_submit.srr=( pPDU[position] & 0x20 ) ? TRUE : FALSE;       // bit 5 (Status Report Request)
-       tpdu_submit.udhi=( pPDU[position] & 0x40 ) ? TRUE : FALSE;      // bit 6 (User Data Header Indicator)
-       tpdu_submit.rp = ( pPDU[position] & 0x80 ) ? TRUE : FALSE;      // bit 7 (Reply Path)
-
-       position++ ;
-
-       /* TP-MR */
-       tpdu_submit.mr = pPDU[position];
-
-       position++ ;
-
-       /* TP-DA */
-
-       memset(diallingNum, 0, sizeof(diallingNum));
-
-       SmsUtilDecodeAddrField(diallingNum, &pPDU[position],&dest_ton, &dest_npi);
-
-       position+=2;
-
-       destAddr_len = strlen( (char*) diallingNum );
-       if ( destAddr_len % 2 )
-               position += destAddr_len / 2 + 1;
-       else
-               position += destAddr_len / 2;
-
-
-       if ( dest_ton == SIM_TON_INTERNATIONAL )
-       {
-               destAddr[0] = '+';
-               memcpy( &destAddr[1], diallingNum, destAddr_len );
-               destAddr[destAddr_len+1] = '\0';
-       }
-       else
-       {
-               memcpy( destAddr, diallingNum, destAddr_len );
-               destAddr[destAddr_len] = '\0';
-       }
-       //TEST_DEBUG(" dest length: %d , dest # : %s", destAddr_len, destAddr);
-
-       tpdu_submit.desAddr.DialNumLen= destAddr_len;
-       memcpy(tpdu_submit.desAddr.szDiallingNum, destAddr , destAddr_len);
-       tpdu_submit.desAddr.Npi = dest_npi;
-       tpdu_submit.desAddr.Ton = dest_ton;
-
-       /* TP-PID */
-
-       tpdu_submit.pId = pPDU[position];
-       position++ ;
-
-       /* TP DCS */
-       SmsUtilDecodeDCS( &tpdu_submit.dcs, pPDU[position] );
-       position ++;
-
-       /* TP VP */
-       tpdu_submit.vp.vp_type = TAPI_NETTEXT_VP_RELATIVE;  //temp
-
-       if(tpdu_submit.vp.vp_type ==  TAPI_NETTEXT_VP_RELATIVE)
-       {
-               tpdu_submit.vp.vpValue = pPDU[position];
-               tpdu_submit.vp.vp_rel_type = TAPI_NETTEXT_VP_REL_1D;
-               position++;
-       }
-       else if (tpdu_submit.vp.vp_type ==  TAPI_NETTEXT_VP_ABSOLUTE || tpdu_submit.vp.vp_type ==  TAPI_NETTEXT_VP_ENHANCED)
-       {
-               position += 7;
-       }
-
-       /* TP UDL */
-       tpdu_submit.udl = pPDU[position] ;
-
-       if ( tpdu_submit.udl> TAPI_NETTEXT_SMDATA_SIZE_MAX )
-               tpdu_submit.udl = TAPI_NETTEXT_SMDATA_SIZE_MAX;
-
-       position++;
-
-       /* TP UD */
-       tpdu_submit.userData = malloc( sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-       memset(tpdu_submit.userData, 0, sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-       if (tpdu_submit.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-       {
-               char    inData[TAPI_NETTEXT_SMDATA_SIZE_MAX+1];
-
-               memset( inData, 0x00, TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 );
-
-               memcpy( (void*) inData, (void*) &pPDU[position], tpdu_submit.udl );
-
-               SmsUtilUnpackGSMCode((char *)tpdu_submit.userData, inData, (TS_UINT8) tpdu_submit.udl);
-       }
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Msg Type: TPDU_SUBMIT");
-
-       if(tpdu_submit.rd)
-       {
-               TEST_DEBUG("RD: Reject Duplicate")
-       }
-
-       else if(!tpdu_submit.rd)
-       {
-               TEST_DEBUG("RD: Accept Duplicate")
-       }
-
-       if(tpdu_submit.srr)
-       {
-               TEST_DEBUG("SRR: A status report is requested")
-       }
-
-       else if(!tpdu_submit.srr)
-       {
-               TEST_DEBUG("SRR: A status report is not  requested")
-       }
-
-       if(tpdu_submit.udhi)
-       {
-               TEST_DEBUG("UDHI: Contains a Header in addition to the short message.")
-       }
-       else if(!tpdu_submit.udhi)
-       {
-               TEST_DEBUG("UDHI: Only Short Message")
-       }
-
-       if(tpdu_submit.rp)
-       {
-               TEST_DEBUG("RP: Set Reply Path")
-       }
-
-       else if(!tpdu_submit.rp)
-       {
-               TEST_DEBUG("RP: Not set Reply Path")
-       }
-
-       TEST_DEBUG("SCA Addr : %s",scaAddr);
-       TEST_DEBUG("To : %s" ,destAddr);
-       TEST_DEBUG("Message : %s " , tpdu_submit.userData);
-       TEST_DEBUG("*************************************");
-
-       return TRUE;
-}
-
-int   DecodeSmsDeliverTpdu(int tpdu_len , char* pTPDU)
-{
-       TPDU_SMS_DELIVER   tpdu_deliver;
-       TmDateTime                 SCTimeStamp;;
-       int                 orgAddr_len = 0;
-       char        diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-       char                orgAddr[TAPI_NETTEXT_ADDRESS_LEN_MAX]; //originating number
-       int                 org_ton,org_npi;
-       int                 position=0;
-
-       /* TP-MTI, TP-MMS, TP-SRI, TP_UDHI, TP-RP */
-       tpdu_deliver.msg_type = SMS_TPDU_DELIVER;
-       tpdu_deliver.mms = ( pTPDU[position] & 0x04 ) ? TRUE : FALSE;// bit 2 (Message Type Indicator)
-       tpdu_deliver.sri =( pTPDU[position] & 0x20 ) ? TRUE : FALSE;    // bit 5 (Status Report Indication)
-       tpdu_deliver.udhi=( pTPDU[position] & 0x40 ) ? TRUE : FALSE;    // bit 6 (User Data Header Indicator)
-       tpdu_deliver.rp = ( pTPDU[position] & 0x80 ) ? TRUE : FALSE;    // bit 7 (Reply Path)
-
-       position++ ;
-
-       /* TP-OA */
-
-       memset(diallingNum, 0, sizeof(diallingNum));
-
-       orgAddr_len = SmsUtilDecodeAddrField(diallingNum, &pTPDU[position],&org_ton, &org_npi);
-
-       position+=2;
-
-       if ( orgAddr_len % 2 )
-               position += orgAddr_len / 2 + 1;
-       else
-               position += orgAddr_len / 2;
-
-       TEST_DEBUG("pos = %d, length = %d",position, orgAddr_len);
-
-       if ( org_ton == SIM_TON_INTERNATIONAL )
-       {
-               orgAddr[0] = '+';
-               memcpy( &orgAddr[1], diallingNum, orgAddr_len );
-               orgAddr[orgAddr_len+1] = '\0';
-       }
-       else
-       {
-               memcpy( orgAddr, diallingNum, orgAddr_len );
-               orgAddr[orgAddr_len] = '\0';
-       }
-
-       /* TP-PID */
-       tpdu_deliver.pId= pTPDU[position];
-
-       position ++;
-
-       /* TP-DCS */
-       SmsUtilDecodeDCS( &tpdu_deliver.dcs, pTPDU[position] );
-       dcs_pos = position;
-       position++;
-
-       /* TP-SCTS */
-       SmsUtilDecodeTimeStamp( &pTPDU[position], & SCTimeStamp );
-
-       position+=7;
-
-       /* TP-UDL */
-       tpdu_deliver.udl = pTPDU[position];
-
-       if ( tpdu_deliver.udl> TAPI_NETTEXT_SMDATA_SIZE_MAX )
-               tpdu_deliver.udl = TAPI_NETTEXT_SMDATA_SIZE_MAX;
-
-       position++;
-
-       /* TP-UD */
-       tpdu_deliver.userData = malloc( sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-       memset(tpdu_deliver.userData, 0, sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-       if (tpdu_deliver.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-       {
-               char    inData[TAPI_NETTEXT_SMDATA_SIZE_MAX+1];
-
-               memset( inData, 0x00, TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 );
-
-               memcpy( (void*) inData, (void*) &pTPDU[position], tpdu_deliver.udl );
-
-               SmsUtilUnpackGSMCode(tpdu_deliver.userData, inData, (TS_UINT8) tpdu_deliver.udl);
-       }
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Msg Type: TPDU_DELIVER");
-
-       if(tpdu_deliver.rp )
-       {TEST_DEBUG("RP: Set Reply Path")}
-       else if(!tpdu_deliver.rp )
-       {TEST_DEBUG("RP: Not set Reply Path")}
-
-       if(tpdu_deliver.sri)
-       {TEST_DEBUG("SRI: A status report shall be returned to the SME")}
-       else if(!tpdu_deliver.sri)
-       {TEST_DEBUG("SRI: A status report shall be not returned to the SME")}
-
-       if(tpdu_deliver.mms)
-       {TEST_DEBUG("MMS: No more messages are waiting for the MS in this SC")}
-       else if(!tpdu_deliver.mms)
-       {TEST_DEBUG("MMS: More messages are waiting for the MS in this SC")}
-
-       if(tpdu_deliver.udhi)
-       {TEST_DEBUG("UDHI: Contains a Header in addition to the short message.")}
-       else    if(!tpdu_deliver.udhi)
-       {TEST_DEBUG("UDHI: Only short message.")}
-
-                                                                       TEST_DEBUG("DcsClass : %x (4 means Class None) ",tpdu_deliver.dcs.class_type);
-
-
-       TEST_DEBUG("From : %10s" ,orgAddr );
-       TEST_DEBUG("Time : %d-%d-%d  , %d:%d:%d",
-                       SCTimeStamp.year, SCTimeStamp.month, SCTimeStamp.day, SCTimeStamp.hour, SCTimeStamp.minute ,SCTimeStamp.second);
-       TEST_DEBUG("Message : %s " , tpdu_deliver.userData);
-       TEST_DEBUG("*************************************");
-
-
-       return dcs_pos;
-}
-BOOL EncodeSmsDeliverReportTpdu()
-{
-       TPDU_SMS_DELIVER_REPORT deliver_report;
-       unsigned char packet[500];
-       TelSmsDatapackageInfo_t * pDataPackage;
-       TS_BYTE tp_dcs;
-       TS_BYTE mask=0x69;
-       int index=0;
-       int i ;
-
-       TelSmsDatapackageInfo_t  del_report;
-
-
-       memset(&(del_report), 0 , sizeof(TelSmsDatapackageInfo_t));
-
-       pDataPackage = malloc(sizeof(TelSmsDatapackageInfo_t));
-       memset(pDataPackage, 0, sizeof(TelSmsDatapackageInfo_t));
-
-       memset(packet, 0, 500);
-
-
-       /* TP-MTI , TP-UDHI */
-       deliver_report.msg_type = SMS_TPDU_DELIVER_REPORT;
-       deliver_report.udhi = FALSE;
-
-       packet[index] = deliver_report.msg_type;                                                //DELIVER REPORT
-       packet[index] |= deliver_report.udhi? 0x40 : 0; //bit 6
-
-       index ++;
-
-       /* TP-FCS */
-       //if(result==FAIL)
-       //{
-
-
-       //}
-
-
-       /* TP -PI */
-       deliver_report.paraInd = mask;
-       packet[index] = deliver_report.paraInd ;
-
-       if ( ( mask != 0xFF ) && ( mask != 0 ) )
-       {
-               index++;
-               /* TP-PID */
-               if ( mask & 0x01)
-               {
-                       deliver_report.pId = 0x65 ;
-                       packet[index++] = deliver_report.pId;
-               }
-
-               /* TP-DCS */
-               if ( mask & 0x02)
-               {
-                       deliver_report.dcs.bCompressed = FALSE;
-                       deliver_report.dcs.bmsg_class_set = TRUE;
-                       deliver_report.dcs.coding_group_type =TAPI_NETTEXT_CODGRP_SM_GENERAL_DCS;
-                       deliver_report.dcs.alphabet_type = TAPI_NETTEXT_ALPHABET_DEFAULT;
-                       deliver_report.dcs.class_type = TAPI_NETTEXT_CLASS_2;
-
-                       SmsUtilEncodeDCS(&tp_dcs, &deliver_report.dcs);
-                       packet[index++] = tp_dcs;
-               }
-               /* TP-UDL */
-               if ( mask & 0x04)
-               {
-                       deliver_report.udl =0x00;
-                       packet[index++] = deliver_report.udl;
-
-                       /* TP-UD */
-
-                       if (deliver_report.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-                       {
-                               //SmsUtilPackGSMCode( packet + index, msg, msg_len);
-                       }
-               }
-       }
-       TEST_DEBUG("EncodeSmsDeliverReportTpdu");
-       TEST_DEBUG("Send packet to phonseSever[%d] -----", index);
-
-       for(i=0; i< index ; i++ )
-       {
-               TEST_DEBUG("[%02x]", packet[i]);
-               if( i%10 == 9)
-                       TEST_DEBUG("\n");
-       }
-       TEST_DEBUG("\n");
-       memcpy( del_report.szData, packet, index);
-       del_report.MsgLength = index;
-       TEST_DEBUG("msgLength :%d",del_report.MsgLength);
-       int requestId =0;
-       tel_send_sms_deliver_report(&del_report,0, &requestId);//madhavi
-       TEST_DEBUG("after send deliver report request id is %d",requestId);
-       return TRUE;
-}
-
-
-BOOL DecodeSmsSubmitReportTpdu(int length , char *data)
-{
-
-       TPDU_SMS_SUBMIT_REPORT  submit_report;
-       TmDateTime                              SCTimeStamp;;
-       int                                             position=1;
-       int                                             i=0;
-       TS_BYTE                                         msgRef, tpdu_len;
-       int result=0;
-       TS_BYTE                                 mask;
-
-       /* Result */
-
-       if(data == NULL){
-               TEST_DEBUG("pData is Null")
-               return FALSE;
-       }
-
-       TEST_DEBUG("length :%d",length);
-
-
-       for(i=0;i<length;i++)
-               TEST_DEBUG("[%02x]",data[i]);
-
-
-       result = data[position];
-
-       TEST_DEBUG("In ackrecv (return status) result is %x",result);
-       position ++;
-
-       /* Msg Reference */
-
-       msgRef =  data[position++];
-       TEST_DEBUG("In ackrecv  position :%d msgref is %x",position,msgRef);
-       position ++;
-
-       /* TPDU Length */
-
-       tpdu_len = data[position];
-       TEST_DEBUG("In ackrecv position :%d len is %d",position,tpdu_len);
-
-
-
-       /**** SUBMIT REPORT TPDU PARSING
-        ***/
-
-       /* TP-MTI , TP-UDHI */
-       TEST_DEBUG("before TPDU position value:%d",position);
-
-       submit_report.msg_type = data[position] & 0x03; //bit 0,1
-       submit_report.udhi = data[position] & 0x40 ? TRUE : FALSE;       //bit 6;
-
-       position ++;
-
-       if(result == FAIL)
-       {
-               /* TP-FCS */
-               submit_report.fcs =  data[position] ;
-               position ++;
-       }
-
-       /* TP-PI  - set to a 1 indicates that a particular optional parameter is present in the fields which follow. */
-       /* Masking Bit  - TP -PID (bit 0), TP-DCS(bit 1), TP-UDL(bit 2) */
-
-       submit_report.paraInd = data[position] ;
-       mask =  submit_report.paraInd;
-       position ++;
-
-       //TEST_DEBUG("Parmeter Indication mask =%x", mask);
-
-       /* TP-SCTS */
-
-       SmsUtilDecodeTimeStamp( &data[position], & SCTimeStamp );
-
-       position+=7;
-
-       if( ( mask != 0xFF ) && ( mask != 0 ) )
-       {
-               /* TP-PID */
-               if ( mask & 0x01)
-               {
-                       submit_report.pId= data[position];
-                       position ++;
-                       TEST_DEBUG("TP-PID :%x", submit_report.pId);
-               }
-
-               /* TP-DCS */
-               if ( mask & 0x02)
-               {
-                       SmsUtilDecodeDCS( &submit_report.dcs, data[position] );
-                       position ++;
-                       TEST_DEBUG("TP-DCS :%x",data[position] );
-               }
-
-               if ( mask & 0x04)
-               {
-                       /* TP-UDL */
-                       submit_report.udl = data[position];
-                       position++;
-
-                       TEST_DEBUG("TP-UDL :%x",data[position] );
-
-                       /* TP-UD */
-
-                       submit_report.userData = malloc( sizeof ( TS_BYTE ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-                       memset(submit_report.userData, 0, sizeof ( TS_BYTE ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-                       if (submit_report.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-                       {
-                               char    inData[TAPI_NETTEXT_SMDATA_SIZE_MAX+1];
-
-                               memset( inData, 0x00, TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 );
-
-                               memcpy( (void*) inData, (void*) &data[position], submit_report.udl );
-
-                               SmsUtilUnpackGSMCode(submit_report.userData, inData, (TS_UINT8) submit_report.udl);
-                       }
-
-               }
-       }
-
-       TEST_DEBUG("*************************************");
-
-       if(result != 0x00)
-               TEST_DEBUG("SMS SEND FAIL!!")
-       else
-               TEST_DEBUG("SMS SEND SUCCESS!!")
-
-       if(result != 0x00)
-                               TEST_DEBUG("Failure Code : %x",submit_report.fcs)
-
-
-                                       TEST_DEBUG("*************************************");
-
-       return TRUE;
-}
-
-TS_BOOL DecodeSmsStatusReportTpdu(int tpdu_len, char* pTPDU)
-{
-       TPDU_SMS_STATUS_REPORT status_report;
-
-
-       TmDateTime   SCTimeStamp;
-       TmDateTime   DischargeTime;
-
-       int                     rcpAddr_len = 0;
-       char            diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-
-       char                  rcpAddr[TAPI_NETTEXT_ADDRESS_LEN_MAX]; //recipient number
-       int                   rcp_ton,rcp_npi;
-       int                   position=0;
-       TS_UINT               mask;
-
-       /* TP-MTI, TP MMS, TP SRQ, TP_UDHI */
-
-       status_report.msg_type = pTPDU[position] & 0x03; // bit 0,1
-       status_report.mms = pTPDU[position] & 0x04 ? TRUE : FALSE ; // bit 2
-       status_report.srq = pTPDU[position] &  0x20 ? TRUE : FALSE ; //bit 5
-       status_report.udhi = pTPDU[position] & 0x40 ? TRUE : FALSE;      //bit 6
-
-       position ++;
-
-       /* TP-MR */
-       status_report.mr = pTPDU[position];
-       position ++;
-
-       /* TP-RA */
-
-       memset(diallingNum, 0, sizeof(diallingNum));
-
-       SmsUtilDecodeAddrField(diallingNum, &pTPDU[position],&rcp_ton, &rcp_npi);
-
-       position+=2;
-
-       rcpAddr_len = strlen( (char*) diallingNum );
-       if ( rcpAddr_len % 2 )
-               position += rcpAddr_len / 2 + 1;
-       else
-               position += rcpAddr_len / 2;
-
-
-       if ( rcp_ton == SIM_TON_INTERNATIONAL )
-       {
-               rcpAddr[0] = '+';
-               memcpy( &rcpAddr[1], diallingNum, rcpAddr_len );
-               rcpAddr[rcpAddr_len+1] = '\0';
-       }
-       else
-       {
-               memcpy( rcpAddr, diallingNum, rcpAddr_len );
-               rcpAddr[rcpAddr_len] = '\0';
-       }
-
-       status_report.rcpAddr.DialNumLen= rcpAddr_len;
-       memcpy(status_report.rcpAddr.szDiallingNum, rcpAddr , rcpAddr_len);
-       status_report.rcpAddr.Npi = rcp_npi;
-       status_report.rcpAddr.Ton = rcp_ton;
-
-       /* TP-SCTS */
-       SmsUtilDecodeTimeStamp( &pTPDU[position], & SCTimeStamp );
-       position+=7;
-
-       /* TP-DT */
-       SmsUtilDecodeTimeStamp( &pTPDU[position], & DischargeTime );
-       position+=7;
-
-       /* TP-ST */
-       status_report.status = pTPDU[position];
-       position ++;
-
-       /* TP-PI */
-       status_report.paraInd = pTPDU[position];
-
-       mask = status_report.paraInd  ;
-
-       if ( ( mask != 0xFF ) && ( mask != 0 ) )
-       {
-               /* Increment only if mask is valid */
-               position ++;
-
-               /* TP-PID */
-               if ( mask & 0x01)
-               {
-                       status_report.pId= pTPDU[position];
-                       position ++;
-               }
-               /* TP-DCS */
-               if ( mask & 0x02)
-               {
-                       SmsUtilDecodeDCS( &status_report.dcs, pTPDU[position] );
-                       position ++;
-               }
-               if ( mask & 0x04)
-               {
-                       /* TP-UDL */
-                       status_report.udl = pTPDU[position];
-                       position++;
-
-                       /* TP-UD */
-
-                       status_report.userData = malloc( sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-                       memset(status_report.userData, 0, sizeof ( unsigned char ) * ( TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 ) );
-
-                       if (status_report.dcs.alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )
-                       {
-                               char    inData[TAPI_NETTEXT_SMDATA_SIZE_MAX+1];
-
-                               memset( inData, 0x00, TAPI_NETTEXT_SMDATA_SIZE_MAX + 1 );
-
-                               memcpy( (void*) inData, (void*) &pTPDU[position], status_report.udl );
-
-                               SmsUtilUnpackGSMCode(status_report.userData, inData, (TS_UINT8) status_report.udl);
-                       }
-
-               }
-       }
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Msg Type: STATUS_REPORT");
-       if(status_report.mms)
-       {TEST_DEBUG("MMS: No more messages are waiting for the MS in this SC")}
-       else if(!status_report.mms)
-       {TEST_DEBUG("MMS: More messages are waiting for the MS in this SC")}
-
-       if(status_report.srq)
-       {TEST_DEBUG("SRQ: the result of an SMS COMMAND ")}
-       else if(!status_report.srq)
-       {TEST_DEBUG("SRQ: the result of a SMS SUBMIT.")}
-
-       if(status_report.udhi)
-       {TEST_DEBUG("UDHI: Contains a Header in addition to the short message.")}
-       else if(!status_report.udhi)
-       {TEST_DEBUG("UDHI: Only Short Message")}
-
-       TEST_DEBUG("STATUS:%x",status_report.status);
-       if(status_report.status==0x00)
-               {TEST_DEBUG("STATUS : Short message received by the SME")}
-       else if(status_report.status==0x01)
-       {TEST_DEBUG("STATUS : Short message forwarded by the SC to the SMEbut the SC is unable to confirm delivery")}
-       else if(status_report.status==0x02)
-       {TEST_DEBUG("STATUS : Short message replaced by the SC")}
-
-       TEST_DEBUG("Recipient Number : %s" ,rcpAddr );
-       TEST_DEBUG("SC Time Stamp : %d-%d-%d  , %d:%d:%d",
-                       SCTimeStamp.year, SCTimeStamp.month, SCTimeStamp.day, SCTimeStamp.hour, SCTimeStamp.minute ,SCTimeStamp.second);
-       TEST_DEBUG("Discharge Time : %d-%d-%d  , %d:%d:%d",
-                       DischargeTime.year, DischargeTime.month, DischargeTime.day, DischargeTime.hour, DischargeTime.minute ,DischargeTime.second);
-
-       if(mask & 0x04)
-               TEST_DEBUG("Message : %s " , status_report.userData);
-
-       TEST_DEBUG("*************************************");
-
-       return TRUE;
-}
-
-void MsgCountNotification(int length, char *pData)
-{
-
-       static TelSmsStoredMsgCountInfo_t       *countInfo;
-       int loop_counter = 0;
-       TapiResult_t returnStatus ;
-       int requestId = 0;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-
-       countInfo = (TelSmsStoredMsgCountInfo_t*) pData;
-
-       if( countInfo->UsedCount != 0x00 )      //if used count is not zero
-       {
-               TEST_DEBUG("Index LIST..........");
-               for(loop_counter  = 0; loop_counter < countInfo->UsedCount ; loop_counter++)
-               {
-                       TEST_DEBUG("[%02x]", countInfo->IndexList[loop_counter]);
-                       returnStatus = tel_read_sms_in_sim(countInfo->IndexList[loop_counter],&requestId);
-                       TEST_DEBUG("After read msg: returnstatus %d request id is %d",returnStatus,requestId);
-               }
-               TEST_DEBUG("In MsgCountNotification total cnt is %d, usedcnt is %dapi_err %d",countInfo->TotalCount, countInfo->UsedCount,returnStatus);
-       }
-
-       TEST_DEBUG("In MsgCountNotification total cnt is %d, usedcnt is %d",countInfo->TotalCount, countInfo->UsedCount);
-}//Madhavi
-
-
-void ReadMsgNotification(int length, char *pData)
-{
-       TelSmsData_t  * sim_data;
-       int                scaAddr_len =0;
-       char                * pTPDU;
-       int                 tpdu_len =0;
-       char                diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-       char             scaAddr[TAPI_NETTEXT_SCADDRESS_LEN_MAX]; //service center address
-       int                 sca_ton, sca_npi;
-       int                 position;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null");
-               return;
-       }
-
-       scaAddr_len = pData[7];
-
-       int i = 0;
-       for( i=0;i<length ; i++)
-               TEST_DEBUG("[%02x]", pData[i]);
-
-       sim_data = (TelSmsData_t *)pData;
-
-       if(sim_data->MsgStatus== TAPI_NETTEXT_STATUS_UNREAD)
-               TEST_DEBUG("Msg Staus : received unread msg")
-       else if(sim_data->MsgStatus==TAPI_NETTEXT_STATUS_READ)
-               TEST_DEBUG("Msg Staus : received read msg")
-       else if(sim_data->MsgStatus==TAPI_NETTEXT_STATUS_UNSENT)
-               TEST_DEBUG("Msg Staus : unsent msg")
-       else
-               TEST_DEBUG("Msg Staus : [%d]", sim_data->MsgStatus)
-
-       TEST_DEBUG("First Data [%x]", sim_data->SmsData.szData[0]);
-       TEST_DEBUG("Second Data [%x]", sim_data->SmsData.szData[1]);
-       TEST_DEBUG("Third Data [%x]", sim_data->SmsData.szData[2]);
-       TEST_DEBUG("Fourth Data [%x]", sim_data->SmsData.szData[3]);
-
-       //if(sim_data->MsgStatus ==0x01 || sim_data->MsgStatus==0x02)
-       {
-               position=0;
-               // SCA_ADDR
-               memset(diallingNum, 0, sizeof(diallingNum));
-
-               SmsUtilDecodeAddrField(diallingNum, (char *)sim_data->SmsData.Sca, &sca_ton, &sca_npi);
-
-               position+=2;  //include Address-Length, Type of Address
-
-               scaAddr_len = strlen( (char *)diallingNum );
-
-               if ( scaAddr_len % 2 )
-                       position += scaAddr_len / 2 + 1;
-               else
-                       position += scaAddr_len / 2;
-
-
-               if ( sca_ton == SIM_TON_INTERNATIONAL )
-               {
-                       scaAddr[0] = '+';
-                       memcpy( &scaAddr[1], diallingNum, scaAddr_len );
-                       scaAddr[scaAddr_len+1] = '\0';
-               }
-               else
-               {
-                       memcpy( scaAddr, diallingNum, scaAddr_len );
-                       scaAddr[scaAddr_len] = '\0';
-               }
-
-               memcpy(&sim_data->SmsData.MsgLength, &pData[4+7 + position], sizeof(char) );    //position is 7(sca)
-
-               tpdu_len = sim_data->SmsData.MsgLength ;
-
-               memcpy(&sim_data->SmsData.szData, &pData[4+position+4 + 7], tpdu_len );
-
-               TEST_DEBUG("SCA Number : %s tpdu_len is %d",scaAddr,tpdu_len);
-
-               pTPDU = malloc(sizeof(TS_BYTE) * tpdu_len);
-               TEST_DEBUG("bfor memcopy position is %d",position);
-               memcpy(pTPDU, &(sim_data->SmsData.szData[0]), tpdu_len);
-               TEST_DEBUG("after memcpy");
-
-               DecodeSmsDeliverTpdu(tpdu_len, pTPDU);
-
-               free(pTPDU);
-       }
-
-}//Madhavi
-
-void MemoryFullNotification(int length, char *pData)
-{
-       int * memory_ind;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-       memory_ind = (int *)pData;
-       TEST_DEBUG("In memory full notification status %d",*memory_ind);
-
-}//Madhavi
-
-
-void DeleteMsgNotification(int length, char *pData)
-{
-       int *index;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-       index = (int *) pData;
-       TEST_DEBUG("In deletenotifcation the result and index are [%d]", *index);
-
-
-}//madhavi
-
-void SaveMsgNotification(int length, char *pData)
-{
-       int *index;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-       index = (int *)pData;
-       TEST_DEBUG("In savestatus noti, index [%d]", *index);
-
-}
-
-void GetCBNotification(int length, char *pData)
-{
-       TelSmsCbConfig_t * CBConfig;
-       int i =0;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-
-       CBConfig =(TelSmsCbConfig_t *) pData;
-
-
-       TEST_DEBUG("=========CB Configuration=========");
-
-       /*** CB Enable/Diable ***/
-       if(CBConfig->bCBEnabled==TRUE)
-               TEST_DEBUG("Cell Broadcast Msg Enabled...")
-       else
-               TEST_DEBUG("Cell Broadcast Msg Disabled...")
-
-
-                       /*** Selected ID ***/
-                       if(CBConfig->SelectedId == 0x01)
-                               TEST_DEBUG("All CBMI is selected... ")
-                       else if(CBConfig->SelectedId == 0x02)
-                               TEST_DEBUG("There are some selected CBMI...");
-
-       /*** CBMI  Count ***/
-       TEST_DEBUG("CBMI Count: %d \n",CBConfig->MsgIdCount);
-
-       /*** CBMI  List ***/
-
-       if(CBConfig->MsgIdCount !=0)
-       {
-
-               TEST_DEBUG("----- CBMI List -----");
-
-               for(i =0 ; i < CBConfig->MsgIdCount; i++)
-               {
-
-                       TEST_DEBUG("No.%d - [0x%04x]", i,CBConfig->MsgIDs[i]);
-
-               }
-
-       }
-       TEST_DEBUG("==================================");
-
-}
-
-void param_get_noti(int length, char *pData)
-{
-       TelSmsParams_t *smsp_param;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-       smsp_param = (TelSmsParams_t  *)pData;
-
-       TEST_DEBUG("record index is %x",smsp_param->RecordIndex);
-       TEST_DEBUG("record len  is %x",smsp_param->RecordLen);
-       TEST_DEBUG("alpha_id len  is %lu ",smsp_param->AlphaIdLen);
-       TEST_DEBUG("alpha_id is %s ",smsp_param->szAlphaId);
-       TEST_DEBUG("param indicator is  %xn",smsp_param->ParamIndicator);
-       TEST_DEBUG("dest dialling num is %s",smsp_param->TpDestAddr.szDiallingNum);
-       TEST_DEBUG("svcaddr dialling num is %s",smsp_param->TpSvcCntrAddr.szDiallingNum);
-       TEST_DEBUG("pid %x",smsp_param->TpProtocolId);
-       TEST_DEBUG("dcs is %x",smsp_param->TpDataCodingScheme);
-       TEST_DEBUG("validity is %x",smsp_param->TpValidityPeriod);
-}
-
-
-void Device_ReadyNoti(int length, char *pData)
-{
-       int *device_status;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-
-       device_status = (int *)pData;
-
-       if(*device_status == TRUE){
-               TEST_DEBUG("Device Ready");
-       }
-       else if(*device_status  == FALSE){
-               TEST_DEBUG("Device Not Ready");
-       }
-       else{
-               TEST_DEBUG("In device ready noti the result is %d",*device_status );
-       }
-       return;
-}
-
-void Deliver_ReportNoti(int status)
-{
-       if(status == TAPI_NETTEXT_SENDSMS_SUCCESS){
-               TEST_DEBUG("DELIVERY REPORT SUCCESS");
-       }
-       else{
-               TEST_DEBUG("DELIVERY REPORT Fail : Reason[0x%0x]", status);
-       }
-
-       return;
-}
-
-
-void get_preferred_bearer_noti(int length,char *pData)
-
-{
-       TEST_DEBUG("get preferred bearer");
-       int svc=0;
-       TelSmsBearerType_t *bearer;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-
-       bearer=(TelSmsBearerType_t *)pData;
-       TEST_DEBUG("In GetPreferredBearer noti bearer:%d",*bearer);
-       svc=*bearer;
-       TEST_DEBUG("svc:%d",svc);
-
-       if(svc== TAPI_NETTEXT_BEARER_PS_ONLY)
-               TEST_DEBUG("Packet Domain")
-       else if(svc== TAPI_NETTEXT_BEARER_CS_ONLY)
-               TEST_DEBUG("Circuit Switched")
-       else if(svc== TAPI_NETTEXT_BEARER_PS_PREFERRED)
-               TEST_DEBUG("Packet Domain preferred ")
-       else if(svc== TAPI_NETTEXT_BEARER_CS_PREFERRED)
-               TEST_DEBUG("Circuit Switched preferred")
-
-}
-
-void set_request_confirm_noti(int length, char *pData)
-{
-       TEST_DEBUG("***Set Request  confirm Notification*******");
-
-       TelSmsSetResponse *pSetReqConfType;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-       pSetReqConfType = (TelSmsSetResponse *)pData;
-
-       switch(*pSetReqConfType)
-       {
-               case TAPI_NETTEXT_CBSETCONFIG_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_CBSETCONFIG_RSP");
-                       break;
-#if 0
-               case TAPI_NETTEXT_SETPREFERREDBEARER_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETPREFERREDBEARER_RSP");
-                       break;
-#endif
-               case TAPI_NETTEXT_SETPARAMETERS_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETPARAMETERS_RSP");
-                       break;
-
-               case TAPI_NETTEXT_SETMEMORYSTATUS_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETMEMORYSTATUS_RSP");
-                       break;
-
-               case TAPI_NETTEXT_SETMESSAGESTATUS_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETMESSAGESTATUS_RSP");
-                       break;
-
-               case TAPI_NETTEXT_SETDEVICESTATUS_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETDEVICESTATUS_RSP");
-                       break;
-
-               case TAPI_NETTEXT_SETSCADDR_RSP:
-                       TEST_DEBUG("TAPI_NETTEXT_SETSCADDR_RSP");
-                       break;
-
-               default:
-                       TEST_DEBUG("Unknown set request confirm noti");
-                       break;
-
-       }
-
-       TEST_DEBUG("Notification Received Successfully");
-}
-
-void param_count_noti(int length, char *pData)
-{
-       int  * RecordCount;
-
-       if(pData == NULL){
-               TEST_DEBUG("pData is Null")
-               return;
-       }
-
-       RecordCount = (int *)pData;
-
-       TEST_DEBUG("ParamCnt Length[%d]", length);
-       TEST_DEBUG("In param_count_noti the record count is %d", *RecordCount);
-}
-
-int  SendMessage()
-{
-       int     ret;
-       int     msg_len=0;
-       char buf[512];
-       char message[512];
-       //char bearerType[2];
-       char diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-       int     diallingNum_len=0;
-
-       memset(buf,0, sizeof(buf));
-       memset(diallingNum,0,sizeof(diallingNum));
-       diallingNum_len=0;
-
-       TEST_DEBUG("Enter destination Number: ");
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       diallingNum_len=strlen(diallingNum);
-       memcpy(&diallingNum[diallingNum_len], buf,sizeof(buf));
-
-       diallingNum_len = strlen(diallingNum); //recalculate
-       TEST_DEBUG("dialling num %s and dialling num len is %d",diallingNum,diallingNum_len);
-       diallingNum[diallingNum_len]=0;
-       diallingNum_len =diallingNum_len-1;
-
-       TEST_DEBUG("Enter Message: ");
-       memset(message,0,sizeof(message));
-
-       ret = read(0, message, sizeof(message));
-
-       if (ret <= 0) {
-               TEST_DEBUG(" NULL msg can NOT be sent ");
-               return -1;
-       }
-
-       msg_len=strlen(message);
-
-       TEST_DEBUG("==========================");
-       TEST_DEBUG("To :%s", diallingNum);
-       TEST_DEBUG("Message: %sMsg Length:%d",message, msg_len);
-       TEST_DEBUG("Dialling number Length : %d" ,diallingNum_len);
-       TEST_DEBUG("==========================\n");
-
-       EncodeSmsSubmitTpdu(diallingNum, diallingNum_len,message, msg_len) ;
-       return 1;
-
-}
-
-int SendMessageCDMA()
-{
-       int ret;
-       int msg_len = 0;
-       char buf[512] = {0,};
-       char message[512] = {0,};
-       char diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX] = {0,};
-       int diallingNum_len = 0;
-
-       printf("\n");
-       printf("Enter destination Number:\n>> ");
-       fflush(stdout);
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0) {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       diallingNum_len = strlen(diallingNum);
-       memcpy(&diallingNum[diallingNum_len], buf, sizeof(buf));
-
-       diallingNum_len = strlen(diallingNum); //recalculate
-       diallingNum[diallingNum_len] = 0;
-       diallingNum_len = diallingNum_len - 1;
-       printf("dialling num [%s], dialling num len [%d]\n", diallingNum, diallingNum_len);
-
-       printf("Enter Message\n>> ");
-       fflush(stdout);
-
-       ret = read(0, message, sizeof(message));
-       if (ret <= 0) {
-               printf(" NULL msg can NOT be sent \n");
-               return -1;
-       }
-
-       msg_len = strlen(message);
-
-       printf("===========================\n");
-       printf("To: [%s] (len: %d)\n", diallingNum, diallingNum_len);
-       printf("Message: [%s]\nMsg Length: [%d]\n", message, msg_len);
-       printf("===========================\n\n");
-
-       EncodeCdmaSmsSubmitTpdu(diallingNum, diallingNum_len, message, msg_len);
-       //EncodeSmsSubmitTpdu(diallingNum, diallingNum_len,message, msg_len) ;
-
-       return 1;
-}
-
-
-
-
-int ReadMessage()
-{
-       int             menu;
-       int             ret;
-       char    buf[100];
-
-       TapiResult_t returnStatus;
-       int requestId = 0;
-       memset(buf,0, sizeof(buf));
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("1. SIM Message");
-
-       TEST_DEBUG("Select Number:");
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       menu = atoi(buf);
-       TEST_DEBUG("menu in read message(value is 1) is %d ",menu);
-       switch(menu)
-       {
-               case 1:
-
-                       TEST_DEBUG("***Reading the message(Api:GetMsgCount)***");
-                       returnStatus = tel_get_sms_count(&requestId);
-                       TEST_DEBUG("status for read message is %d request Id %d",returnStatus,requestId);
-
-       }
-       return 1;
-}
-
-int DeleteMessage(
-               )
-{
-       int     ret;
-       int     index;
-       char buf[100];
-
-       TapiResult_t returnStatus;
-
-       int requestId = 0;
-
-       memset(buf, 0, sizeof(buf));
-
-       TEST_DEBUG("Enter delete index >>");
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       index=atoi(buf);
-       TEST_DEBUG("index value :%d",index);
-
-
-       TEST_DEBUG("***Deleting the message(Api:DeleteMsg,GetMsgCount)***");
-
-       returnStatus = tel_delete_sms_in_sim(index,&requestId);
-       TEST_DEBUG("returnstatus  delete message  is for delete%d request id %d",returnStatus,requestId);
-       returnStatus = tel_get_sms_count(&requestId);
-       TEST_DEBUG("returnStatus for  delete msg msgcnt  %d requestid %d",returnStatus,requestId);
-
-
-       return 1;
-
-}
-
-int ReceiveMessage(int pdu_len, char * pPDU)
-{
-
-       int                scaAddr_len =0;
-       char                * pTPDU;
-       int                 tpdu_len =0;
-       char                diallingNum[TAPI_NETTEXT_ADDRESS_LEN_MAX];
-       char             scaAddr[TAPI_NETTEXT_SCADDRESS_LEN_MAX]; //service center address
-       int                 sca_ton, sca_npi;
-       int                 position;
-
-       TS_BYTE MTI = 0;
-       TS_BYTE MMS = 0;
-       TS_BYTE SRI = 0;
-       TS_BYTE UDHI = 0;
-       TS_BYTE RP = 0;
-
-       tapi_nettext_coding_scheme dcs;
-       TelSmsDatapackageInfo_t * datapackage;
-       TapiResult_t returnStatus;
-       position=0;
-       int requestId = 0;
-
-       if(pPDU == NULL){
-               TEST_DEBUG("pData is Null")
-               return FALSE;
-       }
-       /*      for debug
-               for( i=0;i<pdu_len ; i++)
-               TEST_DEBUG("[%02x]", pPDU[i]);
-               */
-
-       datapackage = (TelSmsDatapackageInfo_t *)pPDU;
-
-       memset(diallingNum, 0, sizeof(diallingNum));
-
-       SmsUtilDecodeAddrField(diallingNum, (char *)datapackage->Sca, &sca_ton, &sca_npi);
-
-       scaAddr_len = strlen( diallingNum );
-
-       if ( sca_ton == SIM_TON_INTERNATIONAL )
-       {
-               scaAddr[0] = '+';
-               memcpy( &scaAddr[1], diallingNum, scaAddr_len );
-               scaAddr[scaAddr_len+1] = '\0';
-       }
-       else
-       {
-               memcpy( scaAddr, diallingNum, scaAddr_len );
-               scaAddr[scaAddr_len] = '\0';
-       }
-
-       TEST_DEBUG("Sc address in test app is %s",scaAddr);
-
-       RP = datapackage->szData[position] & 0x80;
-       UDHI = datapackage->szData[position] & 0x40;
-       SRI = datapackage->szData[position] & 0x20;
-       MMS = datapackage->szData[position] & 0x04;
-       MTI = datapackage->szData[position] & 0x03;
-
-       TEST_DEBUG("RP [%x]", RP);
-       TEST_DEBUG("UDHI [%x]", UDHI);
-       TEST_DEBUG("SRI [%x]", SRI);
-       TEST_DEBUG("MMS [%x]", MMS);
-       TEST_DEBUG("MTI [%02x]", MTI);
-
-       tpdu_len = datapackage->MsgLength;
-
-       pTPDU = malloc(sizeof(TS_BYTE) * tpdu_len);
-
-       memcpy(pTPDU, &datapackage->szData[position], tpdu_len);
-
-       if(MTI ==SMS_TPDU_DELIVER)
-       {
-               DecodeSmsDeliverTpdu(tpdu_len, pTPDU);
-
-               TEST_DEBUG("dcs_pos : %d", dcs_pos);
-
-               SmsUtilDecodeDCS(&dcs, datapackage->szData[position+dcs_pos]);
-
-               //if(dcs.class_type == TAPI_NETTEXT_CLASS_2)
-               {
-                       TEST_DEBUG("dcs type is of class2");
-                       TelSmsData_t WriteData;
-
-                       memset(&WriteData, 0, sizeof(TelSmsData_t));
-
-                       memcpy(WriteData.SmsData.Sca , datapackage->Sca, TAPI_SIM_SMSP_ADDRESS_LEN);
-
-                       WriteData.SmsData.MsgLength = datapackage->MsgLength;
-
-                       memcpy(WriteData.SmsData.szData, datapackage->szData, datapackage->MsgLength);
-
-                       WriteData.MsgStatus = TAPI_NETTEXT_STATUS_READ;
-
-                       returnStatus = tel_write_sms_in_sim(&WriteData, &requestId);
-
-                       TEST_DEBUG("returnStatus for write  %d requestId :%d",returnStatus,requestId);
-               }
-
-
-       }
-       else if(MTI==SMS_TPDU_STATUS_REPORT)
-       {
-               DecodeSmsStatusReportTpdu(tpdu_len, pTPDU);
-       }
-
-       TelSmsDatapackageInfo_t * del_report= NULL;
-
-       del_report= malloc(sizeof(TelSmsDatapackageInfo_t));
-
-       memset(del_report, 0, sizeof(TelSmsDatapackageInfo_t));
-
-       memcpy(del_report->Sca, datapackage->Sca, TAPI_SIM_SMSP_ADDRESS_LEN);
-
-       del_report->szData[0] = SMS_TPDU_DELIVER_REPORT;        //TP-UDHI[bit6] : 0
-       del_report->szData[1] = 0;      // TP-PI = 0; bit2: TP-UDL bit1: TP-DCS bit0: TP-PID (No option field)
-       del_report->MsgLength = 2;
-
-       TEST_DEBUG("***receive message (Api:SendDeliverreport)****");
-
-
-       returnStatus =tel_send_sms_deliver_report(del_report,TAPI_NETTEXT_SENDSMS_SUCCESS, &requestId);
-
-       TEST_DEBUG("AFter send deliver report request id[%d] & result [0x%x]",requestId,returnStatus);
-
-       free(del_report);
-
-       free(pTPDU);
-
-       return 1;
-}
-
-int GetInformation()
-{
-       int             menu;
-       int             ret;
-       char    buf[100];
-
-       TapiResult_t returnStatus;
-
-       /* Get CB Setting Information */
-       //TS_UINT16 CBChannel[MAX_GSM_SMS_CBMI_LIST_SIZE];
-       int requestId=0;
-
-       memset(buf,0, sizeof(buf));
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("1.Get Service Center Number");
-       TEST_DEBUG("2.Get CB Setting Information");
-       TEST_DEBUG("3.Get SMS Parameters");
-       TEST_DEBUG("4.Get SMS PreferredBearer Information (Not supported)");
-       TEST_DEBUG("5.Get SMS Parameter Count");
-       TEST_DEBUG("6.Get Message Count");
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Select Number:");
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       menu = atoi(buf);
-
-       switch(menu)
-       {
-               case 1:
-                       {
-                               TEST_DEBUG("***Getting the SCA(Api: GetSCA)****");
-                               returnStatus = tel_get_sms_sca(0, &requestId);
-                               TEST_DEBUG("returnstatus for scaddr get %d",returnStatus);
-#if 0
-                               SmsUtilDecodeAddrField(decodeScaAddr, (char*)sc_addr.szDiallingNum, (int *)&sc_addr.Ton, (int *)&sc_addr.Npi);
-
-                               sca_len = strlen( decodeScaAddr );
-
-                               if ( sc_addr.Ton== SIM_TON_INTERNATIONAL )
-                               {
-                                       realScaAddr[0] = '+';
-                                       memcpy( &realScaAddr[1], decodeScaAddr, sca_len );
-                                       realScaAddr[sca_len+1] = '\0';
-                               }
-                               else
-                               {
-                                       memcpy( realScaAddr, decodeScaAddr, sca_len );
-                                       realScaAddr[sca_len] = '\0';
-                               }
-
-                               TEST_DEBUG("===== Decode SCA Address =====");
-                               TEST_DEBUG("SCA Number :%s ",realScaAddr);
-                               TEST_DEBUG("==============================");
-#endif
-                               break;
-                       }
-
-
-               case 2:
-                       {
-
-                               TEST_DEBUG("***Getting the CB Configuration(Api: GetCBConfig)***");
-                               returnStatus =  tel_get_sms_cb_config(&requestId);
-                               TEST_DEBUG("ReturnStatus[%d] Requestid0x%x]",returnStatus,requestId);
-                               break;
-                       }
-
-               case 3:
-                       {
-
-                               TEST_DEBUG("****Getting the parameter(Api:GetParameter)****");
-                               returnStatus = tel_get_sms_parameters(0,&requestId);
-                               TEST_DEBUG("ReturnStatus[%d] Requestid0x%x]",returnStatus,requestId);
-                               break;
-                       }
-               case 4:
-                       {
-
-                               //TEST_DEBUG("***Getting preferrredBearer(Api:GetPreferredBearer)***");
-                               //returnStatus=tel_get_sms_preferred_bearer(&requestId);
-                               //TEST_DEBUG("ReturnStatus[%d] Requestid0x%x]",returnStatus,requestId);
-                               break;
-                       }
-
-               case 5:
-                       {
-                               returnStatus = tel_get_sms_parameter_count(&requestId);
-                               TEST_DEBUG("ReturnStatus[%d] Requestid0x%x]",returnStatus,requestId);
-                               break;
-                       }
-               case 6:
-                       {
-                               returnStatus = tel_get_sms_count(&requestId);
-                               TEST_DEBUG("ReturnStatus[%d] Requestid0x%x]",returnStatus,requestId);
-                               break;
-                       }
-               default:
-                       return -1;
-
-       }
-
-       return 1;
-}
-
-int Setting()
-{
-       int                             settingMenu;
-       int                             ret;
-       char                    buf[512];
-
-       char            MemoryStatus[2]; //2006/8/8
-       char                    bearerType[2];  //2006/8/8
-       char            cbEnable[2];//2006/8/8
-
-       TelSmsCbConfig_t   *pCBConfig;
-
-       int                             memType;
-       int                             index;
-       int                             msgStauts;
-
-       TelSmsParams_t  smsParameters = {0,};
-       TapiResult_t returnStatus;
-       int requestId=0;
-
-       memset(buf,0, sizeof(buf));
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("1.Set Service Center Number");
-       TEST_DEBUG("2.Set PreferredBearer Type");
-       TEST_DEBUG("3.Set Deliver Report");
-       TEST_DEBUG("4.Set CB Enable/Disable");
-       TEST_DEBUG("5.Set SMS Parameters");
-       TEST_DEBUG("6.Set Memory Status");
-       TEST_DEBUG("7.Set Stored MsgStaus");
-       TEST_DEBUG("8.Set Device Ready");
-       TEST_DEBUG("9.Check Device Status");
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Select Number:");
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       settingMenu = atoi(buf);
-
-
-       switch(settingMenu)
-       {
-               case 1:  //Set Service Center Number
-                       {
-                               TEST_DEBUG("***Setting the SCA(Api:SetSCA)****");
-                               TelSmsAddressInfo_t sca;
-
-                               memset(&sca, 0, sizeof(TelSmsAddressInfo_t));
-
-                               sca.DialNumLen = 0x5;
-                               sca.Npi = TAPI_SIM_NPI_ISDN_TEL;
-                               sca.Ton = TAPI_SIM_TON_INTERNATIONAL;
-                               sca.szDiallingNum[0] = 0x28;
-                               sca.szDiallingNum[1] = 0x01;
-                               sca.szDiallingNum[2] = 0x19;
-                               sca.szDiallingNum[3] = 0x11;
-                               sca.szDiallingNum[4] = 0x11;
-
-                               returnStatus =  tel_set_sms_sca(&sca,0,&requestId);
-
-                               TEST_DEBUG("returnstatus after scaddr get is is %d requestId:%d ",returnStatus,requestId);
-
-                               break;
-                       }
-
-               case 2:
-                       {
-                               TEST_DEBUG("****Setting the BearerType(Api:SetPreferredBearer)****");
-
-                               TEST_DEBUG("Enter Bearer Type(1:PD, 2:CS, 3:PDP 4:CSP):");
-
-                               memset(bearerType,0 ,sizeof(bearerType));
-
-                               ret = read(0, bearerType, sizeof(bearerType));
-                               if (ret <= 0) {
-                                       TEST_DEBUG(" NULL msg can NOT be sent ");
-                                       return -1;
-                               }
-                               TEST_DEBUG("Set Preferred Bearer : bearerType =%d ", atoi(bearerType));
-
-                               returnStatus = tel_set_sms_preferred_bearer(atoi(bearerType),&requestId);
-                               TEST_DEBUG("returnStatus  after prefbearer set  is %d, reqid=[%d]",returnStatus,requestId);
-
-                               break;
-                       }
-
-               case 3: //Set Deliver Report
-                       {
-                               TEST_DEBUG("****Setting  Deliver Report(Api:SetDeliverReport)****");
-                               //EncodeSmsDeliverReportTpdu();
-                               break;
-                       }
-               case 4: //Set CB Enable/Disable
-                       {
-                               TEST_DEBUG("****Setting the CB configuration(Api:SetCbConfig)****");
-
-                               TEST_DEBUG("Enter CB ON/OFF (1: Enable, 2:Disable):");
-
-                               memset(cbEnable,0 ,sizeof(cbEnable));
-                               pCBConfig = malloc(sizeof(TelSmsCbConfig_t));
-
-                               ret = read(0, cbEnable, sizeof(cbEnable));
-
-                               if (ret <= 0) {
-                                       TEST_DEBUG(" NULL msg can NOT be sent ");
-                                       return -1;
-                               }
-
-                               pCBConfig->bCBEnabled = atoi(cbEnable);
-                               pCBConfig->SelectedId = 0x01;
-                               pCBConfig->MsgIdCount = 0x02;
-
-                               pCBConfig->MsgIDs[0] = 0x0c;
-                               pCBConfig->MsgIDs[1] = 0x0c;
-                               pCBConfig->MsgIDs[2] = 0xdf;
-                               pCBConfig->MsgIDs[3] = 0x00;
-
-                               TEST_DEBUG("from sms test setting the cb configuration:CBEnabled:%d,selectedId:%d,msgCount:%d,msgId: %d\t %d\t %d\t %d",pCBConfig->bCBEnabled,pCBConfig->SelectedId,pCBConfig->MsgIdCount,pCBConfig->MsgIDs[0],pCBConfig->MsgIDs[1],pCBConfig->MsgIDs[2],pCBConfig->MsgIDs[3]);
-
-                               returnStatus = tel_set_sms_cb_config(pCBConfig,&requestId);
-                               TEST_DEBUG("returnStatus after cbconfig set is is [%d], reqid [%d]",returnStatus,requestId);
-
-                               free(pCBConfig);
-                               break;
-                       }
-
-               case 5:
-                       {
-                               char* name = "Lpg";
-                               char* num = "0103001408";
-                               char* sca = "8210911111";
-
-
-                               TEST_DEBUG("****Setting Parameters(Api:SetParameters)****");
-
-                               smsParameters.RecordIndex = 0x00;
-                               smsParameters.RecordLen = 31;
-                               smsParameters.AlphaIdLen = 3;
-                               memcpy(&smsParameters.szAlphaId,name,strlen(name));
-
-
-                               smsParameters.ParamIndicator = 0xe0;
-                               smsParameters.TpDestAddr.DialNumLen = 10;
-                               smsParameters.TpDestAddr.Ton = 1;
-                               smsParameters.TpDestAddr.Npi = 1;
-
-                               smsParameters.TpSvcCntrAddr.DialNumLen = 10;
-                               smsParameters.TpSvcCntrAddr.Ton = 1;
-                               smsParameters.TpSvcCntrAddr.Npi = 1;
-
-                               memcpy(smsParameters.TpDestAddr.szDiallingNum , num, strlen(num));
-                               memcpy(smsParameters.TpSvcCntrAddr.szDiallingNum, sca, strlen(sca));
-                               smsParameters.TpProtocolId = 3;
-                               smsParameters.TpDataCodingScheme = 2;
-                               smsParameters.TpValidityPeriod = 1;
-
-                               returnStatus = tel_set_sms_parameters(&smsParameters,&requestId);
-                               TEST_DEBUG("returnstatus after sparam set  is %d reqid %d",returnStatus,requestId);
-                               break;
-                       }
-               case 6: //Set Memory Full Notification
-                       {
-                               TEST_DEBUG("Enter Memory Status to be set(1:Memory Available, 2:Memory Full)");
-                               memset(MemoryStatus,0 ,sizeof(MemoryStatus));
-                               ret = read(0, MemoryStatus, sizeof(MemoryStatus));
-                               if (ret <= 0) {
-                                       TEST_DEBUG(" NULL msg can NOT be sent ");
-                                       return -1;
-                               }
-                               TEST_DEBUG("Memory Status type is %d ", atoi(MemoryStatus));
-                               returnStatus =tel_set_sms_memory_status(atoi(MemoryStatus), &requestId);//Set to full 0x02-Full, 0x01-available
-                               TEST_DEBUG("api err after memstatus set is is %d",returnStatus);
-                               break;
-                       }
-               case 7: //Set Stored MsgStaus
-                       {
-                               memType=2;
-                               index=2;
-                               msgStauts =2;
-
-                               //TapiReadNetText(index, &CurMsgStauts, &DataPackage);
-                               returnStatus = tel_read_sms_in_sim(index,&requestId);//To avoid  mismatch of prototypes
-                               TEST_DEBUG("returnStatus after read is is %d",returnStatus);
-
-                               TEST_DEBUG("Before set status : index = %d, CurMsgStauts=%d",index,msgStauts);
-
-                               returnStatus = tel_set_sms_message_status(index,  msgStauts,&requestId);
-                               TEST_DEBUG("returnStatus after msgstatus set is %d",returnStatus);
-
-                               //tapi_nettext_read(index, &CurMsgStauts, &DataPackage);
-                               returnStatus = tel_read_sms_in_sim(index,&requestId);//To avoid  mismatch of prototypes
-                               TEST_DEBUG("returnStatus after read is %d",returnStatus);
-
-                               break;
-                       }
-               case 8:
-                       {
-                               returnStatus =tel_set_sms_device_status();
-                               TEST_DEBUG("returnStatus after read is %d",returnStatus);
-                               break;
-                       }
-               case 9:
-                       {
-                               int status = 0;
-                               returnStatus =tel_check_sms_device_status(&status);
-                               if (status == 1)
-                               {
-                                       TEST_DEBUG("Device Ready");
-                               }
-                               else
-                               {
-                                       TEST_DEBUG("Device Not Ready");
-                               }
-                               TEST_DEBUG("returnStatus after read is %d",returnStatus);
-                               break;
-                       }
-               default:
-                       return -1;
-       }
-       return 1;
-}
-
-
-int sms_read_key_input_cdma(void)
-{
-
-       int     ret;
-       char    buf[512];
-
-       //initialize value
-       memset(buf, 0, sizeof(buf));
-
-       printf("\n");
-       printf("*************************************\n");
-       printf("1.Send New Message\n");
-       printf("2.SMS Exit\n");
-       printf("*************************************\n");
-       printf("Select Number >> ");
-       fflush(stdout);
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0) {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       if (memcmp(buf, "1", sizeof("1") - 1) == 0) {
-               SendMessageCDMA();
-       }
-       if (memcmp(buf, "2", sizeof("2") - 1) == 0) {
-               return -1;
-       }
-
-       return 0;
-}
-
-int sms_read_key_input(void)
-{
-
-       int     ret;
-       char    buf[512];
-       int returnStatus=0;
-
-       //initialize value
-       memset(buf,0, sizeof(buf));
-
-       ret = read(0, buf, sizeof(buf));
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                       perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0)
-               return ret;
-
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("1.Send New Message");
-       TEST_DEBUG("2.Read Message");
-       TEST_DEBUG("3.Delete Message");
-       TEST_DEBUG("4.Delete All Message");
-       TEST_DEBUG("5.Setting");
-       TEST_DEBUG("6.Getting SMS Information");
-       TEST_DEBUG("7.SMS Exit");
-       TEST_DEBUG("*************************************");
-       TEST_DEBUG("Select Number : %s", buf);
-
-       int requestId = 0;
-
-       if( memcmp(buf,"1",sizeof("1")-1) == 0 ){ SendMessage();}
-       if( memcmp(buf,"2",sizeof("2")-1) == 0 ){ ReadMessage();}
-       if( memcmp(buf,"3",sizeof("3")-1) == 0 ){ DeleteMessage();}
-       if( memcmp(buf,"4",sizeof("4")-1) == 0 ){ returnStatus=tel_delete_sms_in_sim(-1,&requestId);TEST_DEBUG("returnStatus:%d,requestId:%d ",returnStatus,requestId);}
-       if( memcmp(buf,"5",sizeof("5")-1) == 0 ){ Setting();}
-       if( memcmp(buf,"6",sizeof("6")-1) == 0 ){ GetInformation();}
-       if( memcmp(buf,"7",sizeof("7")-1) == 0 ){ return -1; }
-
-       return 0;
-}
-
-void SMS_async_event_callback(TelTapiEvent_t* event)
-{
-       //char event_string[IF_NAME_MAX];
-       //char event_string[100];
-       int iSize = 0;
-
-       TEST_DEBUG("Func Entrance");
-       TEST_DEBUG("Request ID : [0x%x]\n", event->RequestId);
-
-//     TAPI_GET_EVENT_NAME(  event->EventType, event_string);
-//     TEST_DEBUG("Event Type [%s]\n", event_string);
-
-       TEST_DEBUG("TAPI Event Status = [0x%0x]", event->Status);
-       if(event->pData==NULL)
-       {
-               TEST_DEBUG("No Event Data!!");
-       }
-       else{
-               iSize = sizeof(event->pData);
-               TEST_DEBUG("Data length:%d", iSize);
-       }
-
-
-       switch(event->EventType)
-       {
-
-               case TAPI_EVENT_NETTEXT_READ_SMS_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$Read Msg Notification $$$");
-                       ReadMsgNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-               case TAPI_EVENT_NETTEXT_GET_COUNT_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$GetMsgCountNotification$$$$");
-                       MsgCountNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_SENTSTATUS_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ RECEIVE  ACK NOTIFICATION $$$$$$ ");
-                       DecodeSmsSubmitReportTpdu(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_GET_PARAM_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$ GET PARAM NOTI$$$");
-                       param_get_noti(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_DELETE_STATUS_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$Delete Notification$$$");
-                       DeleteMsgNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_SAVE_STATUS_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$Save Status Notification$$");
-                       SaveMsgNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_SET_REQUEST_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$ SET REQUESTCONFIRM NOTI$$$");
-                       set_request_confirm_noti(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_GET_CB_CONFIG_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$GET CB Config$$$");
-                       GetCBNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_GET_SMSBEARER_CNF:
-                       TEST_DEBUG("****************************************");
-                       TEST_DEBUG("$$$ GET PREFERRED BEARER$$$");
-                       get_preferred_bearer_noti(iSize, event->pData);
-                       TEST_DEBUG("****************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_DELIVERY_REPORT_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ DELIVER REPORT NOTI $$$$$$");
-                       Deliver_ReportNoti(event->Status);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_INCOM_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ INCOMING MESSAGE NOTIFICATION $$$$$$ ");
-                       ReceiveMessage(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_CB_INCOM_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ INCOMING CB NOTIFICATION $$$$$$ ");
-                       DecodeCellBroadcastMsg(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_MEMORY_STATUS_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ MEMORYF STATUS NOTIFICATION $$$$$$ ");
-                       MemoryFullNotification(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_DEVICE_READY_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$ DEVICE READY NOTI$$$");
-                       Device_ReadyNoti(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_PARAM_COUNT_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$ PARAM COUNT NOTI$$$");
-                       param_count_noti(iSize, event->pData);
-                       TEST_DEBUG("***************************************");
-                       break;
-               case TAPI_EVENT_NETTEXT_SENTSTATUS_EX_CNF :
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ SENT STATUS EX NOTIFICATION $$$$$$");
-                       TEST_DEBUG("Test appl. is Not implemented yet");
-                       TEST_DEBUG("***************************************");
-                       break;
-               case TAPI_EVENT_NETTEXT_INCOM_EX_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ INCOM EX NOTIFICATION $$$$$$");
-                       TEST_DEBUG("Test appl. is Not implemented yet");
-                       TEST_DEBUG("***************************************");
-                       break;
-               case TAPI_EVENT_NETTEXT_CB_INCOM_EX_IND:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ CB INCOM EX NOTIFICATION $$$$$$");
-                       TEST_DEBUG("Test appl. is Not implemented yet");
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               case TAPI_EVENT_NETTEXT_GET_SCA_CNF:
-                       TEST_DEBUG("***************************************");
-                       TEST_DEBUG("$$$$$$ GET SCA NOTIFICATION $$$$$$");
-                       TEST_DEBUG("Test appl. is Not implemented yet");
-                       TEST_DEBUG("***************************************");
-                       break;
-
-               default:
-                       TEST_DEBUG("Event Type: unknown event:[%d]\n", event->EventType);
-                       break;
-       }
-}
-
-
-int sms_subscribe_tapi_events()
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfSMSEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int SMSEvtList[] =
-       {
-               TAPI_EVENT_NETTEXT_READ_SMS_CNF,
-               TAPI_EVENT_NETTEXT_GET_COUNT_CNF,
-               TAPI_EVENT_NETTEXT_SENTSTATUS_CNF,
-               TAPI_EVENT_NETTEXT_GET_PARAM_CNF,
-               TAPI_EVENT_NETTEXT_DELETE_STATUS_CNF,
-               TAPI_EVENT_NETTEXT_SAVE_STATUS_CNF,
-               TAPI_EVENT_NETTEXT_SET_REQUEST_CNF,
-               TAPI_EVENT_NETTEXT_GET_CB_CONFIG_CNF,
-               TAPI_EVENT_NETTEXT_GET_SMSBEARER_CNF,
-               TAPI_EVENT_NETTEXT_DELIVERY_REPORT_CNF,
-               TAPI_EVENT_NETTEXT_INCOM_IND,
-               TAPI_EVENT_NETTEXT_CB_INCOM_IND,
-               TAPI_EVENT_NETTEXT_MEMORY_STATUS_IND,
-               TAPI_EVENT_NETTEXT_DEVICE_READY_IND,
-               TAPI_EVENT_NETTEXT_PARAM_COUNT_IND,
-               TAPI_EVENT_NETTEXT_SENTSTATUS_EX_CNF,
-               TAPI_EVENT_NETTEXT_INCOM_EX_IND,
-               TAPI_EVENT_NETTEXT_CB_INCOM_EX_IND,
-               TAPI_EVENT_NETTEXT_GET_SCA_CNF,
-       };
-
-       iNumOfSMSEvt = sizeof(SMSEvtList)/sizeof(int);
-       //TAPI_CALLOC(SMS_subscription_id, iNumOfSMSEvt, unsigned int)
-       //#define TAPI_CALLOC(ptr, no_elements, type)   s
-       SMS_subscription_id = (unsigned int *) calloc (iNumOfSMSEvt , sizeof (unsigned int));
-       if(SMS_subscription_id == NULL)
-       {
-               TEST_DEBUG("calloc error -NULL, errno is [%d]", errno);
-       }
-
-
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               for( i=0 ; i< iNumOfSMSEvt; i++ )
-               {
-                       api_err = tel_register_event(SMSEvtList[i], &SMS_subscription_id[i],(TelAppCallback)&SMS_async_event_callback,NULL);
-
-                       if(api_err != TAPI_API_SUCCESS)
-                       {
-                               TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", SMSEvtList[i],api_err);
-                               ret_val = FALSE;
-                               break;
-                       }
-               }
-       }
-       else
-       {
-               TEST_DEBUG("TelTapiInit() failed");
-       }
-       return ret_val;
-}
-
-void sms_select_loop_cdma(void)
-{
-       int ret;
-       fd_set readfds;
-       printf("Select Loop!\nPress enter key\n");
-       fflush(stdout);
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-               {
-                       if (FD_ISSET(0, &readfds))
-                       {
-                               if( sms_read_key_input_cdma() < 0)
-                               {
-                                       return;
-                               }
-                       }
-               }
-       }
-}
-
-void sms_select_loop_wcdma(void)
-{
-       int ret;
-       fd_set readfds;
-       printf("Select Loop!\n");
-
-       while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-               ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-               {
-                       if (FD_ISSET(0, &readfds))
-                       {
-                               if( sms_read_key_input() <0 )
-                               {
-                                       return;
-                               }
-                       }
-               }
-       }
-}
-
-
-
-void sms_select_loop()
-{
-       int iNum;
-       char buf[255];
-
-       while (1) {
-               printf("*************************************\n");
-               printf("1. WCDMA\n");
-               printf("2. CDMA\n");
-               printf("0. Exit\n");
-               printf("*************************************\n");
-               printf("Select Number by Network Type\n>> ");
-
-               fflush(stdout);
-               fflush(stdin);
-
-               memset(buf, 0, 255);
-               fgets(buf, 255, stdin);
-               iNum = atoi(buf);
-
-               if (iNum == 1) {
-                       sms_select_loop_wcdma();
-               }
-               else if (iNum == 2) {
-                       sms_select_loop_cdma();
-               }
-               else if (iNum == 0) {
-                       printf("SMS Program is terminated.\n");
-                       return;
-               }
-               else {
-                       printf("Input wrong number\n");
-               }
-       }
-
-       return;
-}
-
-void tapi_sms_thread()
-{
-       TEST_DEBUG("start tapi_nettext_thread");
-       //select_loop();
-       TEST_DEBUG ("thread exited");
-       pthread_exit(NULL);
-}
-
-void sms_test_main(int argc, char *argv[])
-{
-
-       int ret = 0, subscription_id = 0;
-       pthread_t nettext_thread_id;
-       TapiResult_t api_err = TAPI_API_SUCCESS;
-
-       TEST_DEBUG("\n ===== NETTEXT  ver RAMU =====");
-
-       ret = pthread_create(&nettext_thread_id, NULL, (void *)&tapi_sms_thread, NULL);
-
-       if(ret != 0)
-       {
-               TEST_DEBUG("Thread for TAPI Events Failed");
-       }
-
-       TEST_DEBUG("Before pthread join");
-
-       TEST_DEBUG("after TelTapiRegisterClass sub id is %d api_err is %d",subscription_id,api_err);
-
-       pthread_join(nettext_thread_id, NULL);
-
-       return;
-}
-//eof
-
diff --git a/src/test_apps/tapi_sms_test.h b/src/test_apps/tapi_sms_test.h
deleted file mode 100644 (file)
index 03e78b6..0000000
+++ /dev/null
@@ -1,648 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef TAPI_SMS_CDMA_H
-#define TAPI_SMS_CDMA_H
-
-/*
-   typedef unsigned char       INT8;
-   typedef unsigned short      INT16;
-   typedef unsigned int        INT;
-   typedef unsigned long       INT32;
-
-   typedef unsigned char       BYTE;
-   */
-
-typedef int BOOL;
-
-#ifndef packed__
-#define packed__ __attribute__ ((packed))
-#endif
-
-//=============================================================
-//
-//             PARAMETER_ID
-//
-//=============================================================
-#define PARAMID_TELESERVICE_ID                         0x01    /* Teleservice Identifier */
-#define PARAMID_SERVICE_CATEGORY                       0x02    /* Broadcast Service Category */
-#define PARAMID_ADDRESS                                        0x03    /* Address */
-#define PARAMID_SUBADDRESS                             0x04    /* Subaddress */
-#define PARAMID_BEARER_REPLY                           0x05    /* Bearer Reply Option */
-#define PARAMID_CAUSE_CODES                            0x06    /* Cause Codes */
-#define PARAMID_MESSAGE_ID                             0x07    /* Message Identifier */
-#define PARAMID_USER_DATA                                      0x08    /* User Data */
-#define PARAMID_USER_RESPONSE_CODE             0x09    /* User Response Code */
-#define PARAMID_MC_TIME_STAMP                  0x0A    /* Message Center Time Stamp */
-#define PARAMID_VALIDITY_PERIOD_ABS            0x0B    /* Validity Period - Absolute */
-#define PARAMID_VALIDITY_PERIOD_REL            0x0C    /* Validiry Period - Relative */
-#define PARAMID_DEFERRED_DELIVERY_ABS  0x0D    /* Deferred Delivery Time - Absolute */
-#define PARAMID_DEFERRED_DELIVERY_REL  0x0E    /* Deferred Delivery Time - Relative */
-#define PARAMID_PRIORITY                                       0x0F    /* Priority Indicator */
-#define PARAMID_PRIVACY                                        0x10    /* Privacy Indicator */
-#define PARAMID_REPLY_OPTION                           0x11    /* Reply Option */
-#define PARAMID_NUMBER_OF_MESSAGE              0x12    /* Number of Messages : Voice Mail Count */
-#define PARAMID_ALERT_ON_DELIVERY                      0x13    /* Alert on Message Delivery */
-#define PARAMID_LANGUAGE                                       0x14    /* Langauge Indicator */
-#define PARAMID_CALLBACK                                       0x15    /* Call Back Number */
-#define PARAMID_DISPLAY_MODE                           0x16    /* Display Mode */
-#define PARAMID_MULTI_ENCODING_USER_DATA       0x17    /* Multiply Encoding User Data */
-#define PARAMID_MEMORY_INDEX                           0x18    /* Memory address stored in Phone Memory */
-#define PARAMID_BEARER_DATA                            0x19    /* Bearer data - raw data  */
-
-//=============================================================
-//
-//             PARAMETER_DATA
-//
-//=============================================================
-
-//------------------------------------------------------------------------------
-// PARAMID_TELESERVICE_ID                      0x01    /* Teleservice Identifier */
-//------------------------------------------------------------------------------
-/* Common TELESERVICE ID's */
-#define TELESERVICEID_CPT95                            0x1001  /* 4097 : Paging */
-#define TELESERVICEID_CMT95                            0x1002  /* 4098 : Text Message */
-#define TELESERVICEID_VMN95                            0x1003  /* 4099 : Voice Mail Notification */
-#define TELESERVICEID_WAP                                      0x1004  /* WAP Message */
-
-//------------------------------------------------------------------------------
-// PARAMID_BCSERVICECATEGORY           0x02    /* Broadcast Service Category */
-//------------------------------------------------------------------------------
-// The Korean Wireless Service Carrier's do not use below Service Category's
-// Below Service Category's depend on the Carriers.
-#define CATEGORY_UNKNOWN                               0x00
-#define CATEGORY_EMERGENCY                             0x01
-#define CATEGORY_ADMIN                                 0x02
-#define CATEGORY_MAINTENANCE                   0x03
-#define CATEGORY_GEN_NEWS_LOC                  0x04
-#define CATEGORY_GEN_NEWS_REG                  0x05
-#define CATEGORY_GEN_NEWS_NAT                  0x06
-#define CATEGORY_GEN_NEWS_INT                  0x07
-#define CATEGORY_FIN_NEWS_LOC                  0x08
-#define CATEGORY_FIN_NEWS_REG                  0x09
-#define CATEGORY_FIN_NEWS_NAT                  0x0A
-#define CATEGORY_FIN_NEWS_INT                  0x0B
-#define CATEGORY_SPT_NEWS_LOC                  0x0C
-#define CATEGORY_SPT_NEWS_REG                  0x0D
-#define CATEGORY_SPT_NEWS_NAT                  0x0E
-#define CATEGORY_SPT_NEWS_INT                  0x0F
-#define CATEGORY_ENT_NEWS_LOC                  0x10
-#define CATEGORY_ENT_NEWS_REG                  0x11
-#define CATEGORY_ENT_NEWS_NAT                  0x12
-#define CATEGORY_ENT_NEWS_INT                  0x13
-#define CATEGORY_LOC_WEATHER                   0x14
-#define CATEGORY_AREA_TRAFFIC                  0x15
-#define CATEGORY_AIRPORT_SCHED                 0x16
-#define CATEGORY_RESTAURANTS                   0x17
-#define CATEGORY_LODGINGS                              0x18
-#define CATEGORY_RETAILS                               0x19
-#define CATEGORY_ADS                                   0x1A
-#define CATEGORY_STOCK_QUOTES                  0x1B
-#define CATEGORY_JOBS                                  0x1C
-#define CATEGORY_MEDICAL                               0x1D
-#define CATEGORY_TECH_NEWS                             0x1E
-#define CATEGORY_MULTI                                 0x1F
-
-//------------------------------------------------------------------------------
-// PARAMID_ADDRESS                                     0x03    /* Address */
-//------------------------------------------------------------------------------
-
-/* DIGIT MODE : CHARi[] filed�� 4bit dtmf code���� 8bit code������ ï¿½Ç¹ï¿½ï¿½Ñ´ï¿½.
-*/
-#define DIGITMODE_4BITDTMF                     0x00
-#define DIGITMODE_8BITCODE                     0x01
-
-/* NUMBER MODE
-*/
-#define NUMMODE_NONE_DATANETWORK       0x00    /* in ANSI TI.607 */
-#define NUMMODE_DATANETWORK                    0x01
-
-/* NUMBER TYPE
-*/
-/* The following are used when number mode is not data network address.
-*/
-#define NUMBER_TYPE_UNKNOWN                    0x00
-#define NUMBER_TYPE_INTERNATIONAL      0x01
-#define NUMBER_TYPE_NATIONAL           0x02
-#define NUMBER_TYPE_NETWORK                    0x03
-#define NUMBER_TYPE_SUBSCRIBER         0x04
-#define NUMBER_TYPE_RESERVED_5         0x05
-#define NUMBER_TYPE_ABREVIATED         0x06
-#define NUMBER_TYPE_RESERVED_7         0x07
-/* The following are used only when number mode is data network address
-   mode.
-   */
-#define NUMBER_TYPE_IP                         0x01
-#define NUMBER_TYPE_EMAILADDR          0x02
-
-/* NUMBER PLAN
-*/
-#define NUMBER_PLAN_UNKNOWN                    0x00
-#define NUMBER_PLAN_TELEPHONY          0x01    /* CCITT E.164 and E.163,  including ISDN plan */
-#define NUMBER_PLAN_RESERVED_2         0x02
-#define NUMBER_PLAN_DATA                       0x03    /* CCITT X.121 */
-#define NUMBER_PLAN_TELEX                      0x04    /* CCITT F.69 */
-#define NUMBER_PLAN_RESERVED_5         0x05
-#define NUMBER_PLAN_RESERVED_6         0x06
-#define NUMBER_PLAN_RESERVED_7         0x07
-#define NUMBER_PLAN_RESERVED_8         0x08
-#define NUMBER_PLAN_PRIVATE                    0x09
-#define NUMBER_PLAN_RESERVED_10                0x0A
-#define NUMBER_PLAN_RESERVED_11                0x0B
-#define NUMBER_PLAN_RESERVED_12                0x0C
-#define NUMBER_PLAN_RESERVED_13                0x0D
-#define NUMBER_PLAN_RESERVED_14                0x0E
-#define NUMBER_PLAN_RESERVED_15                0x0F
-
-/* NUM_FIELDS
-*/
-/*             MAXLENGTH_SMS_ADDRESS                   Maximum sms destination(or origination ) address /call back number */
-#define        MAXLENGTH_SMS_ADDRESS           20
-/* CHARi
-*/
-
-//------------------------------------------------------------------------------
-// PARAMID_SUBADDRESS                          0x04    /* Subaddress */
-//------------------------------------------------------------------------------
-/* SUB ADDRESS TYPE
-*/
-#define SUBADDR_NSAP                           0x00    /* CCITT X.213 or ISO 8348 AD2 */
-#define SUBADDR_USER_SPECIFIED         0x01    /* e.g. X.25 */
-
-/* ODD  : ï¿½Ì°ï¿½ï¿½ï¿½ ï¿½ï¿½ ï¿½Ê¿ï¿½ï¿½Ñ°ï¿½ ? phone���� ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ 4bit�� ï¿½ï¿½ï¿½ï¿½ï¿½Ï¸ï¿½ ï¿½Ç´Â°ï¿½ ï¿½Æ´Ñ°ï¿½ ?
-*/
-/* If the last CHARi field contains information only in the 4 most significant bits,
-   the ODD field shall be set to '1'.  Otherwise, the ODD field shall be set to '0'.
-   */
-#define SUBADDR_EVEN                           0x00
-#define SUBADDR_ODD                                    0x01
-
-/* NUM_FIELDS
-*/
-
-/* CHARi
-*/
-
-//------------------------------------------------------------------------------
-// PARAMID_BEARER_REPLY                                0x05    /* Bearer Reply Option */
-//------------------------------------------------------------------------------
-/* REPLY_SEQ
-*/
-// Range : 0 - 63
-//      refer to MAXLENGTH_SMS_REPLY_SEQUENCE_NUMBER
-
-//------------------------------------------------------------------------------
-// PARAMID_CAUSE_CODES                         0x06    /* Cause Codes */
-//------------------------------------------------------------------------------
-/* REPLY_SEQ
-*/
-// Range : 0 - 63
-// Refer to MAXLENGTH_SMS_REPLY_SEQUENCE_NUMBER
-
-/* ERROR_CLASS
-*/
-#define ERRORCLASS_NONE                                        0x00    /* No Error */
-#define ERRORCLASS_TEMP                                        0x02    /* Tempory Error */
-#define ERRORCLASS_PERMANENT                   0x03    /* Permanent Error */
-#define ERRORCLASS_INTERNAL                            0x04    /* Phone Internal Error */
-
-/* CAUSE_CODE : defined in IS-41D
-*/
-
-/* A. Network Problems:
-*/
-#define CAUSECODE_ADDRESS_VACANT                                                       0
-#define CAUSECODE_ADDRESS_TRANSLATION_FAILURE                          1
-#define CAUSECODE_NETWORK_RESOURCE_SHORTAGE                                    2
-#define CAUSECODE_NETWORK_FAILURE                                                      3
-#define CAUSECODE_INVALID_TELESERVICE_ID                                       4
-#define CAUSECODE_OTHER_NETWORK_PROBLEM                                                5
-#define CAUSECODE_OTHER_NETWORK_PROBLEM_MORE_FIRST                     6
-/* all values within this range are treated as IPC_CAUSECODE_OTHER_NETWORK_PROBLEM_S   */
-#define IPC_CAUSECODE_OTHER_NETWORK_PROBLEM_MORE_LAST                  31
-
-/* B. Terminal Problems:
-*/
-#define CAUSECODE_NO_PAGE_RESPONSE                                                     32
-#define CAUSECODE_DESTINATION_BUSY                                                     33
-#define CAUSECODE_NO_ACK                                                                       34
-#define CAUSECODE_DESTINATION_RESOURCE_SHORTAGE                                35
-#define CAUSECODE_SMS_DELIVERY_POSTPONED                                       36
-#define CAUSECODE_DESTINATION_OUT_OF_SERVICE                           37
-#define CAUSECODE_DESTINATION_NO_LONGER_AT_THIS_ADDRESS                38
-#define CAUSECODE_OTHER_TERMINAL_PROBLEM                                       39
-#define CAUSECODE_OTHER_TERMINAL_PROBLEM_MORE_FIRST                    40
-/* all values within this range are treated as IPC_CAUSECODE_OTHER_TERMINAL_PROBLEM_S */
-#define CAUSECODE_OTHER_TERMINAL_PROBLEM_MORE_LAST                     47
-#define CAUSECODE_SMS_DELIVERY_POSTPONED_MORE_FIRST                    48
-#define CAUSECODE_SMS_DELIVERY_POSTPONED_MORE_LAST                     63
-
-/* C. Radio Interface Problems:
-*/
-#define CAUSECODE_RADIO_IF_RESOURCE_SHORTAGE                           64
-#define CAUSECODE_RADIO_IF_INCOMPATIBLE                                                65
-#define CAUSECODE_OTHER_RADIO_IF_PROBLEM                                       66
-#define CAUSECODE_OTHER_RADIO_IF_PROBLEM_MORE_FIRST                    67
-/* all values within this range are treated as IPC_CAUSECODE_OTHER_RADIO_IF_PROBLEM */
-#define CAUSECODE_OTHER_RADIO_IF_PROBLEM_MORE_LAST                     95
-
-/* D. General Problems:
-*/
-#define CAUSECODE_UNEXPECTED_PARM_SIZE                                         96
-#define CAUSECODE_SMS_ORIGINATION_DENIED                                       97
-#define CAUSECODE_SMS_TERMINATION_DENIED                                       98
-#define CAUSECODE_SUPPL_SERVICE_NOT_SUPPORTED                          99
-#define CAUSECODE_SMS_NOT_SUPPORTED                                                    100
-#define CAUSECODE_RESERVED_101                                                         101
-#define CAUSECODE_MISSING_EXPECTED_PARM                                                102
-#define CAUSECODE_MISSING_MANDATORY_PARM                                       103
-#define CAUSECODE_UNRECOGNIZED_PARM_VALUE                                      104
-#define CAUSECODE_UNEXPECTED_PARM_VALUE                                                105
-#define CAUSECODE_USER_DATA_SIZE_ERROR                                         106
-#define CAUSECODE_OTHER_GENERAL_PROBLEMS                                       107
-#define CAUSECODE_OTHER_GENERAL_PROBLEMS_MORE_FIRST                    108
-/* all values within this range are treated as IPC_CAUSECODE_OTHER_GENERAL_PROBLEMS */
-#define CAUSECODE_OTHER_GENERAL_PROBLEMS_MORE_LAST                     255
-
-//------------------------------------------------------------------------------
-// PARAMID_MESSAGE_ID                          0x07    /* Message Identifier */
-//------------------------------------------------------------------------------
-/* MESSAGE_TYPE
-*/
-#define MESSAGETYPE_DELIVER                            0x01
-#define MESSAGETYPE_SUBMIT                             0x02
-#define MESSAGETYPE_CANCEL                             0x03
-#define MESSAGETYPE_DELIVERY_ACK               0x04
-#define MESSAGETYPE_USER_ACK                   0x05
-
-/* MESSAGE_ID
-*/
-// 2 bytes :    Range : 0 - 65535
-
-//------------------------------------------------------------------------------
-// PARAMID_USER_DATA                                   0x08    /* User Data */
-//------------------------------------------------------------------------------
-/* MESSAGE_ENCODING
-*/
-#define MSGENCODING_UNSPECIFIED                                                0x00    /* OCTET */
-#define MSGENCODING_IS91_EXTENDED_PROTOCOL                     0x01    /* */
-#define MSGENCODING_7BIT_ASCII                                         0x02    /* */
-#define MSGENCODING_IA5                                                                0x03    /* */
-#define MSGENCODING_UNICODE                                                    0x04    /* */
-#define MSGENCODING_SHIFT_JIS                                          0x05    /* */
-#define MSGENCODING_KSC5601                                                    0x06    /* Korean */
-#define MSGENCODING_HEBREW                                                     0x07    /* ISO_8859_8 */
-#define MSGENCODING_LATIN                                                      0x08    /* ISO_8859_1 */
-#define MSGENCODING_KSC5601_3PCS                                               0x10    /* Korean Standard */
-
-#define        MAXLENGTH_SMS_USER_DATA                                         160
-//------------------------------------------------------------------------------
-// PARAMID_USER_RESPONSE_CODE          0x09    /* User Response Code */
-//------------------------------------------------------------------------------
-/* USER_RESPONSE_CODE
-*/
-// This field value depends on the Teleservices or the carrier
-// This field had used in the Interactive Teleservices in Korea
-// currently the wireless service carriers adopt the browser( WAP,etc )
-// instead of SMS protocol in order to serve the interactive teleservice.
-
-//------------------------------------------------------------------------------
-// PARAMID_MC_TIME_STAMP                               0x0A    /* Message Center Time Stamp */
-//------------------------------------------------------------------------------
-
-/* YEAR
-*/
-// 4bit BCD Code,  example : if the year is 2002, the YEAR field contains 0x02.
-
-/* MONTH
-*/
-// 1 ~ 12 ( in decimal )
-
-/* DAY
-*/
-// 1 ~ 31( in decimal )
-
-/* HOUR
-*/
-// 0 ~ 23 ( in decimal )
-
-/* MINUTE
-*/
-// 0 ~ 59 ( in decimal )
-
-/* SECOND
-*/
-// 0 ~ 59 ( in decimal )
-
-//------------------------------------------------------------------------------
-// PARAMID_VALIDITY_PERIOD_ABS         0x0B    /* Validity Period - Absolute */
-//------------------------------------------------------------------------------
-
-//------------------------------------------------------------------------------
-// PARAMID_VALIDITY_PERIOD_REL         0x0C    /* Validiry Period - Relative */
-//------------------------------------------------------------------------------
-/* VALIDITY
-*/
-
-//------------------------------------------------------------------------------
-// PARAMID_DEFERRED_DELIVERY_ABS               0x0D    /* Deferred Delivery Time - Absolute */
-//------------------------------------------------------------------------------
-
-//------------------------------------------------------------------------------
-// PARAMID_DEFERRED_DELIVERY_REL               0x0E    /* Deferred Delivery Time - Relative */
-//------------------------------------------------------------------------------
-/* DELIVERY_TIME
-*/
-
-//------------------------------------------------------------------------------
-// PARAMID_PRIORITY                                    0x0F    /* Priority Indicator */
-//------------------------------------------------------------------------------
-#define PRIORITY_NORMAL                                        0x00
-#define PRIORITY_INTERACTIVE                   0x01
-#define PRIORITY_URGENT                                        0x02
-#define PRIORITY_EMERGENCY                             0x03
-
-//------------------------------------------------------------------------------
-// PARAMID_PRIVACY                                     0x10    /* Privacy Indicator */
-//------------------------------------------------------------------------------
-#define PRIVACY_NOT_RESTRICTED                 0x00
-#define PRIVACY_RESTRICTED                             0x01
-#define PRIVACY_CONFIDENTIAL                   0x02
-#define PRIVACY_SECRET                                 0x03
-
-//------------------------------------------------------------------------------
-// PARAMID_REPLY_OPTION                                0x11    /* Reply Option */
-//------------------------------------------------------------------------------
-
-// USER_ACK_REQ : user ack requested
-#define SMS_USER_ACK_NOT_REQUESTED             0x00
-#define SMS_USER_ACK_REQUESTED                 0x01
-
-// DAK_REQ : delivery ack requested
-#define SMS_DELIVERY_ACK_NOT_REQUESTED 0x00
-#define SMS_DELIVERY_ACK_REQUESTED             0x01
-
-//------------------------------------------------------------------------------
-// PARAMID_NUMBER_OF_MESSAGE                   0x12    /* Number of Messages : Voice Mail Count */
-//------------------------------------------------------------------------------
-/* MESSAGE_COUNT : voice mail count ( 0 - 99 )
-*/
-// refer to            MAXLENGTH_SMS_VOICE_MAIL_COUNT          99
-
-//------------------------------------------------------------------------------
-// PARAMID_ALERT_ON_DELIVERY                   0x13    /* Alert on Message Delivery */
-//------------------------------------------------------------------------------
-// IS-637B Feature : not yet adopted
-//             IPC_ALERT_PRIORITY_DEFAULT                      0x00    /* mobile default */
-//             IPC_ALERT_PRIORITY_LOW                          0x01    /* low priority alert: This alert is defined by the mobile station */
-//             IPC_ALERT_PRIORITY_MED                          0x02    /* medium priority alert : This alert is defined by the mobile station */
-//             IPC_ALERT_PRIORITY_HIGH                         0x03    /* high priority alert : This alert is defined by the mobile station */
-
-//------------------------------------------------------------------------------
-// PARAMID_LANGUAGE                                    0x14    /* Langauge Indicator */
-//------------------------------------------------------------------------------
-#define IPC_LANGUAGE_UNKNOWN                           0x00
-#define IPC_LANGUAGE_ENGLISH                           0x01
-#define IPC_LANGUAGE_FRENCH                                    0x02
-#define IPC_LANGUAGE_SPANISH                           0x03
-#define IPC_LANGUAGE_JAPANESE                          0x04
-#define IPC_LANGUAGE_KOREAN                                    0x05
-#define IPC_LANGUAGE_CHINESE                           0x06
-#define IPC_LANGUAGE_HEBREW                                    0x07
-#define IPC_LANGUAGE_KOREAN1                           0x40    /* Used in korean 3 PCS's and STI */
-#define IPC_LANGUAGE_KOREAN_SKT                                0xFE    /* Used in only SKT  */
-
-//------------------------------------------------------------------------------
-// PARAMID_CALLBACK                                    0x15    /* Call Back Number */
-//------------------------------------------------------------------------------
-/* DIGIT_MODE : CHARi[] filed�� 4bit dtmf code���� 8bit code������ ï¿½Ç¹ï¿½ï¿½Ñ´ï¿½.
-*/
-// refer to :
-//             DIGITMODE_4BITDTMF                      0x00
-//             DIGITMODE_8BITCODE                      0x01
-
-/* NUMBER_TYPE
-*/
-// refer to :
-//             NUMBER_TYPE_UNKNOWN                     0x00
-//             NUMBER_TYPE_INTERNATIONAL               0x01
-//             NUMBER_TYPE_NATIONAL                    0x02
-//             NUMBER_TYPE_NETWORK                     0x03
-//             NUMBER_TYPE_SUBSCRIBER          0x04
-//             NUMBER_TYPE_RESERVED_5          0x05
-//             NUMBER_TYPE_ABREVIATED          0x06
-//             NUMBER_TYPE_RESERVED_7          0x07
-
-/* NUMBER_PLAN
-*/
-// refer to :
-//             NUMBER_PLAN_UNKNOWN                     0x00
-//             NUMBER_PLAN_TELEPHONY                   0x01    /* CCITT E.164 and E.163,  including ISDN plan */
-//             NUMBER_PLAN_RESERVED_2          0x02
-//             NUMBER_PLAN_DATA                                0x03    /* CCITT X.121 */
-//             NUMBER_PLAN_TELEX                               0x04    /* CCITT F.69 */
-//             NUMBER_PLAN_RESERVED_5          0x05
-//             NUMBER_PLAN_RESERVED_6          0x06
-//             NUMBER_PLAN_RESERVED_7          0x07
-//             NUMBER_PLAN_RESERVED_8          0x08
-//             NUMBER_PLAN_PRIVATE                     0x09
-//             NUMBER_PLAN_RESERVED_10         0x0A
-//             NUMBER_PLAN_RESERVED_11         0x0B
-//             NUMBER_PLAN_RESERVED_12         0x0C
-//             NUMBER_PLAN_RESERVED_13         0x0D
-//             NUMBER_PLAN_RESERVED_14         0x0E
-//             NUMBER_PLAN_RESERVED_15         0x0F
-
-/* NUM_FIELDS
-*/
-// refer to :
-//             MAXLENGTH_SMS_ADDRESS                   32
-
-/* CHARi
-*/
-
-//------------------------------------------------------------------------------
-// IPC_SMSPARAMID_DISPLAY_MODE                         0x16    /* Display Mode */
-//------------------------------------------------------------------------------
-// IS-637B Feature : not yet adopted
-
-
-//------------------------------------------------------------------------------
-// IPC_SMSPARAMID_MULTI_ENCODING_USER_DATA     0x17    /* Multiply Encoding User Data */
-//------------------------------------------------------------------------------
-// refer to :
-
-// Teleservice Identifier
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT16                       teleserv_id;
-} packed__ ParamTeleserv_t;
-
-// Broadcast Service Category
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT16                       category;
-} packed__ ParamBcServCat_t;
-
-// Address
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        digit;
-       TS_UINT8                        num;
-       TS_UINT8                        numtype;
-       TS_UINT8                        numplan;
-       TS_UINT8                        len;
-       TS_UINT8                        CHARi[MAXLENGTH_SMS_ADDRESS];
-} packed__ ParamAddress_t;
-
-// Sub-Address
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        type;
-       TS_UINT8                        odd;
-       TS_UINT8                        len;
-       TS_UINT8                        CHARi[MAXLENGTH_SMS_ADDRESS];
-} packed__ ParamSubAddress_t;
-
-// Bearer Reply Option
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT16                       repyseq;
-} packed__ ParamBearerReplyOption_t;
-
-// Cause Codes
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        repyseq;
-       TS_UINT8                        class;
-       TS_UINT8                        code;
-} packed__ ParamErrorCause_t;
-
-// Message Identifier
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        type;
-       TS_UINT16                       msg_id;
-} packed__ ParamMsgId_t;
-
-// User Data
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        encoding;
-       TS_UINT8                        len;
-       TS_UINT8                        CHARi[MAXLENGTH_SMS_USER_DATA];
-} packed__ ParamUserData_t;
-
-// User Response code
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        code;
-} packed__ ParamUserResp_t;
-
-// Message Center Time Stamp, Validity Period, Deferred Delivery Time
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        year;
-       TS_UINT8                        month;
-       TS_UINT8                        day;
-       TS_UINT8                        hours;
-       TS_UINT8                        minutes;
-       TS_UINT8                        seconds;
-} packed__ ParamValidPeriodA_t, ParamDefDeliverTimeA_t;
-
-// Validity Period - Relative
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        valid;
-} packed__ ParamValidPeriodR_t, ParamDefDeliverTimeR_t;
-
-// Priority Indicator, Alert on Message Delivery
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        priority;
-} packed__ ParamPriority_t, ParamAlertPriority_t;
-
-// Privacy Indicator
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        privacy;
-} packed__ ParamPrivacy_t;
-
-// Reply Option
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        user_ack;
-       TS_UINT8                        delivery_ack;
-} packed__ ParamReplyOption_t;
-
-// Number of Messages
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        count;
-} packed__ ParamNumOfMsg_t;
-
-// Language indicator
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        language;
-} packed__ ParamLangInd_t;
-
-// Message display Mode
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        disply_mode;
-} packed__ ParamMsgDisplayMode_t;
-
-// Address
-typedef struct{
-       TS_UINT8                        param_id;
-       TS_UINT8                        param_len;
-       TS_UINT8                        digit;
-       TS_UINT8                        numtype;
-       TS_UINT8                        numplan;
-       TS_UINT8                        len;
-       TS_UINT8                        CHARi[MAXLENGTH_SMS_ADDRESS];
-} packed__ ParamCallback_t;
-
-typedef struct{
-       TS_UINT32                       index;
-       TS_UINT8                        data[255];
-} packed__ Message_t;
-
-#endif //TAPI_SMS_CDMA_H
-// EOF
-
diff --git a/src/test_apps/tapi_sms_util.c b/src/test_apps/tapi_sms_util.c
deleted file mode 100644 (file)
index 5b2ef38..0000000
+++ /dev/null
@@ -1,863 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include "tapi_sms_util.h"
-
-
-void  reverse(char* x, int len)
-{
-       int i, j = len - 1;
-
-       for (i = 0; i < j; i++)
-       {
-               int t = x[i];
-               x[i] = x[j];
-               x[j--] = t;
-       }
-}
-
-char*  AcItoa(int n, char* str, int b)
-{
-       int i = 0;
-
-       do
-               str[i++] = "0123456789ABCDEF"[n%b];
-
-       while ((n /= b) > 0);
-       reverse(str, i);
-       str[i] = '\0';
-
-       return str;
-}
-
-int  AcToupper(int ch)
-{
-       return (('a' <= (ch) && (ch) <= 'z')? ((ch) - ('a'-'A')) : (ch));
-}
-
-char* SmsUtilUnpackGSMCode(char* szData, const char* pIn, int in_len )
-{
-       int i;
-       int pos = 0;
-       int shift = 0;
-
-       /* If the number of fill bits != 0, then it would cause an additional shift */
-       /*
-       if ( shift != 0 )
-               pos = pos + 1;
-
-       if ( shift ==7 )
-               shift = 0;
-       */
-
-       for ( i = 0; i < in_len; i++, pos++ )
-       {
-               szData[i] = ( pIn[pos] << shift ) & 0x7F;
-
-               if ( pos != 0 )
-               {
-                       /* except the first byte, a character contains some bits
-                       ** from the previous byte.
-                       */
-                       szData[i] |= pIn[pos-1] >> (8-shift);
-               }
-
-               shift ++;
-
-               if ( shift == 7 )
-               {
-                       shift = 0;
-
-                       /* a possible extra complete character is available */
-                       i++;
-                       szData[i] = pIn[pos] >> 1;
-
-                       if( szData[i] == 0 )
-                       {
-                               /* this is the end of the input, quit */
-                               break;
-                       }
-               }
-       }
-
-       return szData;
-}
-
-int SmsUtilPackGSMCode( TS_BYTE* pOut, const char* szData, int in_len )
-{
-       int i;
-       int pos;
-       int shift = 0;
-       //shift = fill_bits;
-
-       //  memset( out, 0, out_len_max );
-
-       /* pack the ASCII characters
-       */
-       /*
-       if ( shift == 7 )
-               shift = 0;
-       */
-
-       for( pos = 0, i = 0; /*pos < out_len_max &&*/ i < in_len; pos++, i++ )
-       {
-               /* pack the low bits */
-               pOut[pos] = szData[i] >> shift;
-
-               if ( i + 1 < in_len )
-               {
-                       /* pack the high bits using the low bits of the next character */
-                       pOut[pos] |= szData[i+1] << ( 7 - shift );
-
-                       shift++;
-
-                       if( shift == 7 )
-                       {
-                               shift = 0;
-                               i++;
-                       }
-               }
-       }
-
-       /* done */
-       return pos;
-}
-
-
-void SmsUtilConvertBCD2Digit( char* pDigits, char* pBCD, int digitLen )
-{
-       int             i, bcdLen;
-       char    c[2];
-       unsigned char   higher, lower;
-
-       if ( pBCD == NULL || pDigits == NULL )
-       {
-               printf("__SmsConvertBCD2Digit: pBCD == NULL || pDigits == NULL. return.\n"  );
-               return;
-       }
-
-       if ( digitLen == 0 )
-       {
-               //printf("__SmsConvertBCD2Digit: digitLen == 0. return.\n" );
-
-               pDigits[0] = 0x00;
-
-               return;
-       }
-
-       if ( digitLen % 2 )
-               bcdLen = digitLen / 2 + 1;
-       else
-               bcdLen = digitLen / 2;
-
-       memset( pDigits, 0, bcdLen * 2 );
-
-       for ( i = 0; i < bcdLen; i++ )
-       {
-               lower = pBCD[i] & 0x0F;                                 // get low nibble
-
-               if ( lower == 0x0A )
-                       lower = '*';
-               else if ( lower == 0x0B )
-                       lower = '#';
-               else if ( lower == 0x0C )
-                       lower = 'p';                    //DTMF Control pDigits seperator
-               else if ( lower == 0x0F )
-                       lower = 0;
-               else
-               {
-                       AcItoa( lower, c, 16 );
-                       lower = (char) AcToupper(c[0]);
-               }
-
-               higher = ( pBCD[i] >> 4 ) & 0x0F;                       // get high nibble
-
-               if ( higher == 0x0A )
-                       higher = '*';           // =0x2A
-               else if ( higher == 0x0B )
-                       higher = '#';           // =0x23
-               else if ( higher == 0x0C )
-                       higher = 'p';           // =0x70, DTMF Control pDigits seperator
-               else if ( higher == 0x0F ) // if higher semi-octet is 0x0F, filled bits.
-               {
-                       //higher = 0;
-                       sprintf(pDigits + strlen(pDigits), "%c", lower);
-                       pDigits[/*digitLen-1*/bcdLen*2-1] = '\0';
-
-                       //printf("__SmsConvertBCD2Digit: pDigits [%s].\n", pDigits  );
-
-                       return;
-               }
-               else
-               {
-                       AcItoa(higher, c, 16);
-                       higher = (char) AcToupper(c[0]);
-               }
-
-               //sprintf(pDigits, "%s%c%c", pDigits, lower, higher);
-               sprintf(pDigits + strlen(pDigits), "%c%c", lower, higher);
-       }
-
-       pDigits[digitLen] = '\0';
-
-       //printf("__SmsConvertBCD2Digit: pDigits [%s].\n", pDigits  );
-}
-
-
-void SmsUtilConvertDigit2BCD( char* pBCD, char* pDigits, int digitLen )
-{
-       int     i, j, digit;
-
-       unsigned char   higher, lower;
-
-       if ( pBCD == NULL || pDigits == NULL )
-               return;
-
-       // 0123456789 -> 1032547698
-       for ( i = 0, j = 0; i < digitLen; i = i + 2, j++ )
-       {
-               if ( pDigits[i] == '*' )
-                       digit = 0x0A;
-               else if ( pDigits[i] == '#' )
-                       digit = 0x0B;
-               else if ( AcToupper( pDigits[i] ) == 'P' )
-                       digit = 0x0C;
-               else
-                       digit = (int) ( pDigits[i] - '0' );
-
-               lower = digit & 0x0F;
-
-               if ( digitLen != i + 1 )
-               {
-                       if ( pDigits[i+1] == '*' )
-                               digit = 0x0A;
-                       else if ( pDigits[i+1] == '#' )
-                               digit = 0x0B;
-                       else if ( AcToupper( pDigits[i+1] ) == 'P' )
-                               digit = 0x0C;
-                       else
-                               digit = (int) ( pDigits[i+1] - '0' );
-
-                       higher = digit & 0x0F;
-               }
-               else
-               {
-                       higher = 0xFF;
-               }
-
-               pBCD[j] = ( higher << 4 ) | lower;
-       }
-}
-
-
-TmDateTime* SmsUtilDecodeTimeStamp(char * pTimeStamp, TmDateTime *tmDateTime )
-{
-       //TmDateTime tmDateTime;
-       char szBuf[3];
-       //TS_UINT32     time;
-
-       if ( pTimeStamp == NULL )
-               return NULL;
-
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[0], 2 );
-       tmDateTime->year = atoi( szBuf ) + 2000;
-       if ( ( tmDateTime->year >= 1900 + MAX_YEAR )/* && ( tmDateTime->year < 2000 + BASE_YEAR )*/ )
-               tmDateTime->year -= 100;
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[1], 2 );
-       tmDateTime->month = atoi( szBuf );
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[2], 2 );
-       tmDateTime->day = atoi( szBuf );
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[3], 2 );
-       tmDateTime->hour = atoi( szBuf );
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[4], 2 );
-       tmDateTime->minute = atoi( szBuf );
-       SmsUtilConvertBCD2Digit( szBuf, (char*) &pTimeStamp[5], 2 );
-       tmDateTime->second = atoi( szBuf );
-
-       if ( ( tmDateTime->year < 1900 + BASE_YEAR ) || ( tmDateTime->year > 1900 + MAX_YEAR ) )
-               tmDateTime->year = 1900 + BASE_YEAR;
-
-       /*
-       time = TmDateTimeToSeconds( &tmDateTime );
-       if ( time > MAX_SECONDS )
-               time = MAX_SECONDS;
-
-       */
-
-       return tmDateTime;
-}
-
-unsigned char* SmsUtilEncodeTimeStamp( TmDateTime* tmDateTime, unsigned char* pTimeStamp )
-{
-       //TmDateTime tmDateTime;
-       char szBuf[3];
-       int     year;
-
-       if ( pTimeStamp == NULL )
-               return NULL;
-
-       memset( (void*) pTimeStamp, 0x00, sizeof ( unsigned char ) * 7 );
-
-       //TmSecondsToDateTime( timeStamp, &tmDateTime );
-
-       year = tmDateTime->year - 2000;
-       if ( year < 0 )
-               year += 100;
-       sprintf( szBuf, "%02d", year );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[0], szBuf, 2 );
-       sprintf( szBuf, "%02d", tmDateTime->month );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[1], szBuf, 2 );
-       sprintf( szBuf, "%02d", tmDateTime->day );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[2], szBuf, 2 );
-       sprintf( szBuf, "%02d", tmDateTime->hour );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[3], szBuf, 2 );
-       sprintf( szBuf, "%02d", tmDateTime->minute );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[4], szBuf, 2 );
-       sprintf( szBuf, "%02d", tmDateTime->second );
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[5], szBuf, 2 );
-
-
-       /*      ignore Time zone (assume it is using 0x00 as default)
-       timeZone = TmGetTimeZoneOffset() /15;
-       if ( timeZone < 0 )
-               absTimeZone = -timeZone;
-       else
-               absTimeZone = timeZone;
-       */
-
-       sprintf( szBuf, "%02d", 0);
-       SmsUtilConvertDigit2BCD( (char*) &pTimeStamp[6], szBuf, 2 );
-
-       //if ( timeZone < 0 )
-       //      pTimeStamp[6] |= 0x80;
-
-       return pTimeStamp;
-}
-
-
-
-int  SmsUtilDecodeAddrField(char *diallingNum, char* pAddrField, int *result_ton, int *result_npi )
-{
-       int index = 0;
-       int  ton,npi;
-       int DialNumLen=0;
-
-       ton = ( pAddrField[index+1] & 0x70 ) >> 4;
-       npi = pAddrField[index+1] & 0x0F;
-
-       if ( ton != SIM_TON_ALPHA_NUMERIC )
-       {
-               // Origination/Destination address ï¿½Êµå¿¡ï¿½ï¿½ï¿½ï¿½ length�� ï¿½ï¿½ï¿½ï¿½ address length
-               // origination/destination address ï¿½Êµï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ length�� 0 ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ number type/plan ï¿½Êµï¿½ï¿½ 0xFF ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½Â´ï¿½.
-               DialNumLen = pAddrField[index++];
-       }
-       else
-       {
-               DialNumLen = ( ( ( pAddrField[index++] + 1 ) / 2 ) * 8 ) / 7;
-       }
-
-
-
-
-       // SIM_SMSP_ADDRESS_LEN ï¿½ï¿½ï¿½ï¿½ address length ï¿½ï¿½ Å©ï¿½ï¿½ SIM_SMSP_ADDRESS_LEN ï¿½ï¿½Å­ï¿½ï¿½ ï¿½ï¿½È¯ï¿½ï¿½ ï¿½Ñ´ï¿½.
-
-       if ( DialNumLen > SIM_SMSP_ADDRESS_LEN )
-       {
-               DialNumLen = SIM_SMSP_ADDRESS_LEN;
-       }
-
-       printf(" DialNumLen = %d\n", DialNumLen  );
-
-       index++; /* ignore Type of Address field */
-
-       if (ton != SIM_TON_ALPHA_NUMERIC )
-       {
-               SmsUtilConvertBCD2Digit( diallingNum, (char*) &pAddrField[index],DialNumLen );
-       }
-       else
-       {
-               SmsUtilUnpackGSMCode( diallingNum, &pAddrField[index],DialNumLen );
-       }
-
-       printf(  "__SmsDecodeAddrField: diallingNum [%s].\n", (char*) diallingNum  );
-
-       *result_ton=ton;
-       *result_npi=npi;
-
-       printf("ton %d npi %d\n",ton,npi);
-
-       return DialNumLen;
-
-
-}
-
-int  SmsUtilEncodeAddrField(unsigned char* pAddrField, char* diallingNum, int DialNumLen, int ton, int npi )
-{
-       int index = 0;
-
-       if ( diallingNum == NULL || pAddrField == NULL )
-               return -1;
-
-       if ( ton != SIM_TON_ALPHA_NUMERIC )
-       {
-               // Origination/Destination address ï¿½Êµå¿¡ï¿½ï¿½ï¿½ï¿½ length�� ï¿½ï¿½ï¿½ï¿½ address length
-               pAddrField[index++] = (unsigned char)DialNumLen;
-               //printf(" addr len packet: %d\n", pAddrField[index]);
-       }
-       else
-       {
-               pAddrField[index] = (unsigned char) ( ( ( DialNumLen * 7 + 7 ) / 8 ) * 2 );
-
-               // ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½Æ®ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ 4��Ʈ�� ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ length ï¿½Êµå°ªï¿½ï¿½ -1�� ï¿½Ñ´ï¿½.
-               if ( ( ( DialNumLen * 7 ) % 8 ) <= 4 )
-                       pAddrField[index]--;
-
-               printf(" addr len packet: %d out of SIM_TON_ALPAHA\n", pAddrField[index]);
-
-               index++;
-
-
-
-       }
-
-       SET_TON_NPI( pAddrField[index], ton, npi );
-
-       index++; // SET_TON_NPI ï¿½ï¿½ MACRO ï¿½Ì¹Ç·ï¿½ ï¿½ï¿½ï¿½Î¿ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Å°ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½
-
-       if ( ton != SIM_TON_ALPHA_NUMERIC )
-       {
-               SmsUtilConvertDigit2BCD( (char*) &pAddrField[index], (char*) diallingNum, DialNumLen );
-
-               if ( DialNumLen % 2 )
-                       index += DialNumLen / 2 + 1;
-               else
-                       index += DialNumLen / 2;
-       }
-       else
-       {
-               index += SmsUtilPackGSMCode( &pAddrField[index], diallingNum, (int) DialNumLen );
-       }
-
-       return index;
-}
-int SmsUtilDecodeScAddrField( TelSmsAddressInfo_t* pSmsAddrField, TS_BYTE* pAddrField )
-{
-       printf("SmsUtilDecodeScAddrField\n");
-       int index = 0;
-       int length = 0;
-
-       if ( pSmsAddrField == NULL || pAddrField == NULL )
-       {
-               printf( "SmsUtilDecodeScAddrField: pSimAddrField or pAddrField is NULL.\n"  );
-
-               return 0;
-       }
-
-       // Service Center address ï¿½Êµå¿¡ï¿½ï¿½ï¿½ï¿½ length�� ï¿½Ú¿ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ byte�� ï¿½ï¿½
-       // -> ï¿½ï¿½ï¿½ï¿½ address ï¿½ï¿½ï¿½Ì´ï¿½ TON/API ï¿½ï¿½ï¿½ï¿½Æ®ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½Ï°ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½Æ®ï¿½ï¿½ 2�� or 2�� - 1(���� ï¿½ï¿½ï¿½Ì°ï¿½ È¦ï¿½ï¿½ï¿½Î°ï¿½ï¿½)
-       length = pAddrField[index];
-       // ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ ï¿½Þ½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ì¿¡ï¿½ï¿½ service center address�� ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ ï¿½Ö´ï¿½.
-       // ï¿½ï¿½ ï¿½ï¿½ì¿¡ length ï¿½ï¿½ 0 ï¿½Ì¸ï¿½ number type, plan ï¿½ï¿½ ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½
-       // length ï¿½ï¿½ 1 ï¿½Ì¸ï¿½ type, plan ï¿½ï¿½ ï¿½Ö´ï¿½ ï¿½ï¿½ï¿½
-       if ( length > 1 )
-       {
-               pSmsAddrField->DialNumLen = ( pAddrField[index++] - 1 ) * 2; // -1�� TON/API ï¿½Êµï¿½
-
-               // SIM_SMSP_ADDRESS_LEN ï¿½ï¿½ï¿½ï¿½ address length ï¿½ï¿½ Å©ï¿½ï¿½ SIM_SMSP_ADDRESS_LEN ï¿½ï¿½Å­ï¿½ï¿½ ï¿½ï¿½È¯ï¿½ï¿½ ï¿½Ñ´ï¿½.
-               if ( pSmsAddrField->DialNumLen > SIM_SMSP_ADDRESS_LEN )
-               {
-                       pSmsAddrField->DialNumLen = SIM_SMSP_ADDRESS_LEN;
-               }
-
-               pSmsAddrField->Ton = ( pAddrField[index] & 0x70 ) >> 4;
-               pSmsAddrField->Npi = pAddrField[index] & 0x0F;
-
-               index++; /* ignore Type of Address field */
-
-               SmsUtilConvertBCD2Digit( (char*) pSmsAddrField->DialNumLen, (char*) &pAddrField[index], pSmsAddrField->DialNumLen );
-
-               printf( "SmsUtilDecodeScAddrField: diallingNum [%s].\n", (char*) pSmsAddrField->DialNumLen  );
-
-               printf( "length=%d , ton %d, npi =%d\n",pSmsAddrField->DialNumLen, pSmsAddrField->Ton,pSmsAddrField->Npi );
-       }
-
-       return ++length;
-}
-
- int  SmsUtilEncodeScAddrField( TS_BYTE* pAddrField, TelSmsAddressInfo_t * pSmsAddrField )
-{
-       int index = 0;
-
-       if ( pSmsAddrField == NULL || pAddrField == NULL )
-               return -1;
-
-       // Service Center address ï¿½Êµå¿¡ï¿½ï¿½ï¿½ï¿½ length�� ï¿½Ú¿ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ byte�� ï¿½ï¿½
-       // -> ï¿½ï¿½ï¿½ï¿½ address ï¿½ï¿½ï¿½Ì´ï¿½ TON/API ï¿½ï¿½ï¿½ï¿½Æ®ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½Ï°ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½Æ®ï¿½ï¿½ 2�� or 2�� - 1(���� ï¿½ï¿½ï¿½Ì°ï¿½ È¦ï¿½ï¿½ï¿½Î°ï¿½ï¿½)
-       if ( pSmsAddrField->DialNumLen % 2 )
-       {
-               pAddrField[index++] = pSmsAddrField->DialNumLen / 2 + 1 + 1; // +1 ï¿½ï¿½ TON/NPI ï¿½Êµï¿½, È¦ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ß±ï¿½ ï¿½ï¿½ï¿½ï¿½ ï¿½Ñ¹ï¿½ ï¿½ï¿½ +1
-       }
-       else
-       {
-               pAddrField[index++] = pSmsAddrField->DialNumLen / 2 + 1; // +1 ï¿½ï¿½ TON/NPI ï¿½Êµï¿½
-       }
-
-       SET_TON_NPI( pAddrField[index], pSmsAddrField->Ton, pSmsAddrField->Npi );
-
-       index++; // SET_TON_NPI ï¿½ï¿½ MACRO ï¿½Ì¹Ç·ï¿½ ï¿½ï¿½ï¿½Î¿ï¿½ï¿½ï¿½ ï¿½ï¿½ï¿½ï¿½ï¿½ï¿½Å°ï¿½ï¿½ ï¿½ï¿½ï¿½×¹ß»ï¿½
-
-       SmsUtilConvertDigit2BCD( (char*) &pAddrField[index], (char*) pSmsAddrField->DialNumLen, pSmsAddrField->DialNumLen );
-
-       if ( pSmsAddrField->DialNumLen % 2 )
-               index += pSmsAddrField->DialNumLen / 2 + 1;
-       else
-               index += pSmsAddrField->DialNumLen / 2;
-
-       return index;
-}
-
-void SmsUtilDecodeDCS( tapi_nettext_coding_scheme* pCodingScheme,   unsigned char dcs )
-{
-       assert( pCodingScheme != NULL );
-
-       memset( pCodingScheme, 0, sizeof ( tapi_nettext_coding_scheme ) );
-
-       if ( dcs < 0x40 ) // bits 7..4 = 00xx : general data coding indication
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_GENERAL_DCS;
-
-               if ( dcs & 0x20 ) // bit 5 = 1 : indicates the text is compressed
-                       pCodingScheme->bCompressed = TRUE;
-
-               if ( dcs & 0x10 ) // bit 4 = 1 : indicates that bits  1 to 0 have a message class meaning
-               {
-                       pCodingScheme->bmsg_class_set = TRUE;
-
-                       switch ( dcs & 0x03 ) // bits 1 to 0 : message class
-                       {
-                               case 0x00:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_0;
-                                       break;
-                               case 0x01:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_1;
-                                       break;
-                               case 0x02:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_2;
-                                       break;
-                               case 0x03:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_3;
-                                       break;
-                       }
-               }
-               else // bit 4 = 0 : indicates that bits 1 to 0 are reserved and have no message class meaning
-                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_NONE;
-
-               switch ( dcs & 0x0C ) // bits 4 to 3 : character set
-               {
-                       case 0x00:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_DEFAULT;
-                               break;
-                       case 0x04:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_8BIT;
-                               break;
-                       case 0x08:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_UCS2;
-                               break;
-                       case 0x0C:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_MAX;
-                               break;
-               }
-       }
-       else if ( dcs >= 0x40 && dcs < 0x80 ) // bits 7..4 = 01xx : message marked for automatic deletion group. bits 5..0 are coded exactly the same as group 00xx
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_AUTO_DELETION;
-
-               if ( dcs & 0x20 ) // bit 5 = 1 : indicates the text is compressed
-                       pCodingScheme->bCompressed = TRUE;
-
-               if ( dcs & 0x10 ) // bit 4 = 1 : indicates that bits  1 to 0 have a message class meaning
-               {
-                       pCodingScheme->bmsg_class_set = TRUE;
-
-                       switch ( dcs & 0x03 ) // bits 1 to 0 : message class
-                       {
-                               case 0x00:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_0;
-                                       break;
-                               case 0x01:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_1;
-                                       break;
-                               case 0x02:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_2;
-                                       break;
-                               case 0x03:
-                                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_3;
-                                       break;
-                       }
-               }
-               else // bit 4 = 0 : indicates that bits 1 to 0 are reserved and have no message class meaning
-                       pCodingScheme->class_type = TAPI_NETTEXT_CLASS_NONE;
-
-               switch ( dcs & 0x0C ) // bits 4 to 3 : character set
-               {
-                       case 0x00:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_DEFAULT;
-                               break;
-                       case 0x04:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_8BIT;
-                               break;
-                       case 0x08:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_UCS2;
-                               break;
-                       case 0x0C:
-                               pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_MAX;
-                               break;
-               }
-       }
-       // bits 7..4 = 1000 ~ 1011 : reserved
-       else if ( dcs == 0xC0 ) // bits 7..4 = 1100 : message waiting indication group, discard message
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_WAITING_DISCARD;
-       }
-       else if ( dcs < 0xE0 )
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_WAITING_STORE;
-
-               if ( dcs & 0x08 )
-                       pCodingScheme->bmsg_ind_active = TRUE;
-
-               switch ( dcs & 0x03 )
-               {
-                       case 0x00:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_VOICE_MSG;
-                               break;
-                       case 0x01:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_FAX_MSG;
-                               break;
-                       case 0x02:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_EMAIL_MSG;
-                               break;
-                       case 0x03:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_OTHER_MSG;
-                               break;
-               }
-       }
-       else if ( dcs < 0xF0 )
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_WAITING_STORE_UCS2;
-
-               if ( dcs & 0x08 )
-                       pCodingScheme->bmsg_ind_active = TRUE;
-
-               switch ( dcs & 0x03 )
-               {
-                       case 0x00:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_VOICE_MSG;
-                               break;
-                       case 0x01:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_FAX_MSG;
-                               break;
-                       case 0x02:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_EMAIL_MSG;
-                               break;
-                       case 0x03:
-                               pCodingScheme->waiting_type = TAPI_NETTEXT_WAITING_OTHER_MSG;
-                               break;
-               }
-       }
-       else
-       {
-               pCodingScheme->coding_group_type = TAPI_NETTEXT_CODGRP_SM_CLASS_CODING;
-
-               if ( dcs & 0x04 )
-                       pCodingScheme->alphabet_type = TAPI_NETTEXT_ALPHABET_8BIT;
-
-               switch ( dcs & 0x03 )
-               {
-                       case 0x00:
-                               pCodingScheme->class_type = TAPI_NETTEXT_CLASS_0;
-                               break;
-                       case 0x01:
-                               pCodingScheme->class_type = TAPI_NETTEXT_CLASS_1;
-                               break;
-                       case 0x02:
-                               pCodingScheme->class_type = TAPI_NETTEXT_CLASS_2;
-                               break;
-                       case 0x03:
-                               pCodingScheme->class_type = TAPI_NETTEXT_CLASS_3;
-                               break;
-               }
-       }
-}
-
-void SmsUtilEncodeDCS( TS_BYTE* pDCS, tapi_nettext_coding_scheme* pCodingScheme )
-{
-       printf("SmsUtilEncodeDCS Start\n");
-       TS_BYTE dcs = 0x00;
-
-       assert( pCodingScheme != NULL );
-
-       if( pCodingScheme->coding_group_type == TAPI_NETTEXT_CODGRP_SM_GENERAL_DCS ) // bit 7..4 is 00xx
-       {
-               if ( pCodingScheme->bCompressed )
-                               dcs |= 0x20; // bit 5 is 1
-
-                       if ( pCodingScheme->bmsg_class_set )
-                       {
-                               dcs |= 0x10; // bit 4 is 1
-
-                               if( pCodingScheme->class_type== TAPI_NETTEXT_CLASS_0 )
-                                       dcs |= 0x00;
-
-                               else if ( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_1 )
-                                       dcs |= 0x01;
-
-                               else if ( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_2 )
-                                       dcs |= 0x02;
-
-                               else if ( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_3 )
-                                       dcs |= 0x03;
-                       }
-
-                       switch ( pCodingScheme->alphabet_type )
-                       {
-                               case TAPI_NETTEXT_ALPHABET_DEFAULT: // bit 3..2 is 00
-                               {
-                                       dcs |= 0x00;
-                                       break;
-                               }
-                               case TAPI_NETTEXT_ALPHABET_8BIT: // bit 3..2 is 01
-                               {
-                                       dcs |= 0x04;
-                                       break;
-                               }
-                               case TAPI_NETTEXT_ALPHABET_UCS2: // bit 3..2 is 10
-                               {
-                                       dcs |= 0x08;
-                                       break;
-                               }
-                               default: // bit 3..2 is 11
-                               {
-                                       dcs |= 0x0C;
-                                       break;
-                               }
-                       }
-       }
-       else if ( pCodingScheme->coding_group_type == TAPI_NETTEXT_CODGRP_SM_WAITING_DISCARD ) // bit 7..4 is 1100
-       {
-               dcs |= 0xC0;
-       }
-       else if ( pCodingScheme->coding_group_type == TAPI_NETTEXT_CODGRP_SM_WAITING_STORE ) // bit 7..4 is 1101
-       {
-               dcs |= 0xD0;
-
-               if ( pCodingScheme->bmsg_ind_active ) // bit 3..2 is 10
-                       dcs |= 0x08;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_VOICE_MSG)
-                       dcs |= 0x00;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_FAX_MSG)
-                       dcs |= 0x01;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_EMAIL_MSG) // bit 1..0 is 10
-                       dcs |= 0x02;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_OTHER_MSG) // bit 1..0 is 11
-                       dcs |= 0x03;
-
-       }
-       else if ( pCodingScheme->coding_group_type == TAPI_NETTEXT_CODGRP_SM_WAITING_STORE_UCS2 ) // bit 7..4 is 1110
-       {
-               dcs |= 0xE0;
-
-               if ( pCodingScheme->bmsg_ind_active ) // bit 3..2 is 10
-                       dcs |= 0x08;
-
-               if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_VOICE_MSG ) // bit 1..0 is 00
-                       dcs |= 0x00;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_FAX_MSG )
-                       dcs |= 0x01;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_EMAIL_MSG )
-                       dcs |= 0x02;
-
-               else if( pCodingScheme->waiting_type == TAPI_NETTEXT_WAITING_OTHER_MSG )
-                       dcs |= 0x03;
-       }
-       else if ( pCodingScheme->coding_group_type == TAPI_NETTEXT_CODGRP_SM_CLASS_CODING )     // bit 7..4 is 1111
-       {
-               dcs |= 0xF0;
-
-               if( pCodingScheme->alphabet_type == TAPI_NETTEXT_ALPHABET_DEFAULT )     // bit 2 is 0
-                       dcs |= 0x00;
-               else if( pCodingScheme->alphabet_type == TAPI_NETTEXT_ALPHABET_8BIT ) // bit 2 is 1
-                       dcs |= 0x04;
-
-               if( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_0) // bit 1..0 is 00
-                       ;
-
-               else if( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_1) // bit 1..0 is 01
-                       dcs |= 0x01;
-
-               else if( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_2) // bit 1..0 is 10
-                       dcs |= 0x02;
-
-               else if( pCodingScheme->class_type == TAPI_NETTEXT_CLASS_3) // bit 1..0 is 11
-                       dcs |= 0x03;
-       }
-
-       memcpy( pDCS, &dcs, sizeof ( TS_BYTE ) );
-
-       printf("SmsUtilEncodeDCS End\n");
-}
-
- TS_UINT8 SmsUtilEncodeValidity( TS_BYTE* pValidity, tapi_nettext_vp* pVP )
-{
-       TS_UINT8        pos = 0;
-
-       switch( pVP->vp_type )
-       {
-               case TAPI_NETTEXT_VP_NOT_USED:
-                       break;
-
-               case TAPI_NETTEXT_VP_RELATIVE:
-                       pValidity[pos] = (TS_UINT8) pVP->vpValue;
-                       pos ++;
-                       break;
-
-               case TAPI_NETTEXT_VP_ABSOLUTE:
-                       //TO DO
-                       //SmsUtilEncodeTimeStamp( pValidity, pVP->vpValue );
-                       pos += 7;
-                       break;
-
-               case TAPI_NETTEXT_VP_ENHANCED:
-                       break;
-       }
-
-       return pos;
-}
-
diff --git a/src/test_apps/tapi_sms_util.h b/src/test_apps/tapi_sms_util.h
deleted file mode 100644 (file)
index 2f4cdd1..0000000
+++ /dev/null
@@ -1,494 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdlib.h>
-#include <string.h>
-#include <sys/time.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include "assert.h"
-#include "glib.h"
-
-#include "TelDefines.h"
-#include "TelErr.h"
-#include "ITapiNetText.h"
-
-
-
-
-#define        SIM_TON_UNKNOWN                                 0 //unknown
-#define        SIM_TON_INTERNATIONAL                           1 //international number
-#define        SIM_TON_NATIONAL                                        2 //national number
-#define        SIM_TON_NETWORK_SPECIFIC                        3 //natwork specific number
-#define        SIM_TON_DEDICATED_ACCESS                        4 //subscriber number
-#define        SIM_TON_ALPHA_NUMERIC                           5//alphanumeric, GSM 7-bit default alphabet)
-#define        SIM_TON_ABBREVIATED_NUMBER              6 //abbreviated number
-#define        SIM_TON_RESERVED_FOR_EXT                        7 //reserved for extension
-
-
-#define MAX_UDH_LEN            137
-#define UDH_MAX                                7
-#define SMDATA_SIZE_MAX        160
-
-
-#define FAIL                   0x00
-#define SUCCESS                0x01
-//////////////////////////////////TPDU type////////////////////////////////
-typedef enum
-{
-       SMS_TPDU_DELIVER                                = 0x00, // sc -> ms
-       SMS_TPDU_DELIVER_REPORT         = 0x00, // ms -> sc
-       SMS_TPDU_SUBMIT                         = 0x01, // ms -> sc
-       SMS_TPDU_SUBMIT_REPORT          = 0x01, // sc -> ms
-       SMS_TPDU_STATUS_REPORT          = 0x02, // sc -> ms
-       SMS_TPDU_COMMAND                                = 0x02, // ms -> sc
-       SMS_PDU_INVALID_TYPE
-
-} SmsTPDUType;
-
-typedef enum
-{
-       SMS_DAEMON_UNKNOWN_MESSAGE,
-       SMS_DAEMON_RECEIVED_UNREAD_MESSAGE,
-       SMS_DAEMON_RECEIVED_READ_MESSAGE,
-       SMS_DAEMON_UNSENT_MESSAGE,
-       SMS_DAEMON_STORED_SENT_MESSAGE,
-
-}sd_message_status;
-
-
-/*
- * tapi_nettext_vp_type
- * This enumeration defines the validity period type.
- */
-typedef enum
-{
-       TAPI_NETTEXT_VP_NOT_USED = 0,           /**< validity period not used */
-       TAPI_NETTEXT_VP_RELATIVE = 2,           /**< after a predetermined time period after the service center has received the message */
-       TAPI_NETTEXT_VP_ABSOLUTE = 3,
-       TAPI_NETTEXT_VP_ENHANCED = 1,
-
-       TAPI_NETTEXT_VP_MAX
-} tapi_nettext_vp_type;
-/*
- * tapi_nettext_coding_group_type
- This enum defined the different sms coding group types
- */
-typedef enum
-{
-       TAPI_NETTEXT_CODGRP_SM_GENERAL_DCS,                     /**< Bits 7..4 00xx */
-       TAPI_NETTEXT_CODGRP_CB_GENERAL_LANG,            /**< 0000 */
-       TAPI_NETTEXT_CODGRP_CB_ALPHA,                           /**< 0001 */
-       TAPI_NETTEXT_CODGRP_CB_RES1,                            /**< 0010 */
-       TAPI_NETTEXT_CODGRP_CB_RES2,                            /**< 0011 */
-       TAPI_NETTEXT_CODGRP_SM_AUTO_DELETION,           /**< 01xx Bits 5..0 are coded the same as SM_GENERAL_DCS */
-       TAPI_NETTEXT_CODGRP_CB_GENERAL_DCS,                     /**< 01xx behavior is as SM_GENERAL_DCS */
-       TAPI_NETTEXT_CODGRP_SM_WAITING_DISCARD,         /**< 1100 */
-       TAPI_NETTEXT_CODGRP_SM_WAITING_STORE,           /**< 1101 */
-       TAPI_NETTEXT_CODGRP_SM_WAITING_STORE_UCS2,      /**< 1110 */
-       TAPI_NETTEXT_CODGRP_CB_WAP,                                     /**< 1110 Cell Broadcast */
-       TAPI_NETTEXT_CODGRP_SM_CLASS_CODING,            /**< 1111 */
-       TAPI_NETTEXT_CODGRP_CB_CLASS_CODING,            /**< 1111 Cell Broadcast */
-
-       TAPI_NETTEXT_CODGRP_MAX
-} tapi_nettext_coding_group_type;
-/*
- *  tapi_nettext_waiting_type
- Defines different types of waiting indicators
- */
-typedef enum
-{
-       TAPI_NETTEXT_WAITING_VOICE_MSG,         /**< voice message waiting */
-       TAPI_NETTEXT_WAITING_FAX_MSG,           /**< FAX message waiting */
-       TAPI_NETTEXT_WAITING_EMAIL_MSG,         /**< E-mail waiting */
-       TAPI_NETTEXT_WAITING_OTHER_MSG,         /**< Other message waiting */
-
-       TAPI_NETTEXT_WAITING_MAX
-} tapi_nettext_waiting_type;
-/*
- * tapi_nettext_alphabet_type
- Defines different alphabet types of an sms
- */
-typedef enum
-{
-       TAPI_NETTEXT_ALPHABET_DEFAULT,  /**< GSM alphabet default 7bit */
-       TAPI_NETTEXT_ALPHABET_8BIT,             /**< 8bit */
-       TAPI_NETTEXT_ALPHABET_UCS2,             /**< 16bit ucs2 */
-
-       TAPI_NETTEXT_ALPHABET_KSC5601,  /**< for Korean */
-
-       TAPI_NETTEXT_ALPHABET_MAX
-} tapi_nettext_alphabet_type;
-/*
- * tapi_nettext_class_type
- This enum defines the different classes of SMS which indicates the
- type of storage of the sms.
- */
-typedef enum
-{
-       TAPI_NETTEXT_CLASS_0,   /**< display immediately */
-       TAPI_NETTEXT_CLASS_1,   /**< may be stored */
-       TAPI_NETTEXT_CLASS_2,   /**< store in SIM */
-       TAPI_NETTEXT_CLASS_3,   /**< transfer to TE */
-       TAPI_NETTEXT_CLASS_NONE,
-
-       TAPI_NETTEXT_CLASS_MAX
-} tapi_nettext_class_type;
-
-/*
-This structure contains the information related to sms coding schemes
-
-*/
-typedef struct
-{
-       TS_BOOL                                                 bCompressed;            /**< if text is compressed this is TRUE */
-       TS_BOOL                                                 bmsg_class_set;         /**< message class indication. if TRUE = bits 1..0, if FALSE = reserved */
-       TS_BOOL                                                 bmsg_ind_active;                /**< message indication group. if TRUE = on, FALSE = off */
-       tapi_nettext_coding_group_type          coding_group_type;      /**< Coding group, GSM 03.38 */
-       tapi_nettext_waiting_type                       waiting_type;           /**< Type of message waiting */
-       tapi_nettext_alphabet_type                      alphabet_type;          /**< How to encode a message. */
-       tapi_nettext_class_type                 class_type;                     /**< The message class */
-} tapi_nettext_coding_scheme;
-
-/*
- *  tapi_nettext_vp_rel_Value
- * This structure defines the validity period types.
- */
-typedef enum
-{
-       TAPI_NETTEXT_VP_REL_1H,         /**< One hour */
-       TAPI_NETTEXT_VP_REL_6H,         /**< Six hours */
-       TAPI_NETTEXT_VP_REL_12H,        /**< Twelve hours */
-       TAPI_NETTEXT_VP_REL_1D,         /**< One day */
-       TAPI_NETTEXT_VP_REL_3D,         /**< Three days */
-       TAPI_NETTEXT_VP_REL_1W,         /**< One week */
-       TAPI_NETTEXT_VP_REL_1M,         /**< One Month */
-       TAPI_NETTEXT_VP_REL_MAX         /**< Max = 63 weeks */
-} tapi_nettext_vp_rel_Value;
-/*
-This structure contains all the information
-related to validity period of a message.
-
-*/
-typedef struct
-{
-       tapi_nettext_vp_type vp_type;                     /**< Validity period format */
-       tapi_nettext_vp_rel_Value vp_rel_type; /**< Validity period value duration the message must retain in the service center while application attempts delivery */
-       TS_UINT32 vpValue;                                                /** Validity period value */
-} tapi_nettext_vp;
-
-
-/* This structure contains the details of delete status notification, which comes after calling
-TelTapiSmsDeleteMsg*/
-typedef struct
-{
-       TS_UINT16 result;
-       TS_UINT8 index;
-}TelTapiSmsDeleteMsg_status_ind;
-
-
-/* This structure contains the details of save status notification, which comes after calling
-TelTapiSmsWriteMsg*/
-
-typedef struct
-{
-       TS_UINT16 result;
-       TS_UINT8 index;
-}tapi_nettext_save_status_ind;
-
-
-typedef struct
-{
-       int             year;
-       int             month;
-       int             day;
-       int             hour;
-       int             minute;
-       int             second;
-
-} TmDateTime;
-
-
-#define BASE_YEAR              70L                                     /* 1970 is the base year */
-#define MAX_YEAR                       130L                                    /* 2030 is the max year */
-
-
-#define        SIM_SMSP_ADDRESS_LEN                                    20      // digit length
-
-#define SET_TON_NPI(dest, ton, npi) {  \
-       dest = 0x80;                                            \
-       dest |= (ton & 0x07) << 4;                      \
-       dest |= npi & 0x0F;                                     \
-}
-
-
-
-
-typedef struct
-{
-       /************HEADER************/
-
-       // message type [M]
-       SmsTPDUType  msg_type ;   //bit 0 ,1
-
-       // reject duplicates [M]
-       TS_BOOL rd ;  // bit 2
-
-       // validity period format [M]
-       tapi_nettext_vp_type vpf ; //  bits 3, 4
-
-       // reply path [M]
-       TS_BOOL rp ; //bit 7
-
-       // user data header indication
-       TS_BOOL udhi ;   //bit 6
-
-       // status report request
-       TS_BOOL  srr ;  // bit 5
-
-       /************BODY************/
-
-       //message reference [M]
-       TS_UINT mr;
-
-       // destination address [M]
-       TelSmsAddressInfo_t desAddr;
-
-       // protocol identifier [M]
-       TS_BYTE pId;
-
-       // data coding scheme [M]
-       tapi_nettext_coding_scheme dcs;
-
-       // validity period
-       tapi_nettext_vp vp;
-
-       // user data length [M]
-       TS_UINT udl;
-
-       // user data
-       TS_BYTE *  userData;
-
-
-}TPDU_SMS_SUBMIT;
-
-typedef struct
-{
-       /************HEADER************/
-
-       // message type [M]
-       SmsTPDUType  msg_type;  //bit 0 ,1
-
-       // user data header indication
-       TS_BOOL udhi ;   //bit 6
-
-       /************BODY************/
-
-       // failure Cause [M]
-        TS_UINT        fcs;
-
-       // parameter indicator [M]
-       TS_BYTE paraInd;
-
-       // service centre time stamp [M]
-       TmDateTime scts;
-
-       // protocol identifier [M]
-       TS_BYTE pId;
-
-       // data coding scheme
-       tapi_nettext_coding_scheme dcs;
-
-       // user data length [M]
-       TS_UINT udl;
-
-       // user data
-       char*  userData;
-
-}TPDU_SMS_SUBMIT_REPORT;
-
-
-typedef struct
-{
-       /************HEADER************/
-       SmsTPDUType msg_type;   //bit 0 ,1
-
-       TS_BOOL mms; // bit 2
-
-       TS_BOOL rp; // bit 7
-
-       TS_BOOL udhi;  //bit 6
-
-       TS_BOOL sri; // bit , 5status_report_indication
-
-       /************BODY************/
-
-       TelSmsAddressInfo_t orgAddr;
-
-       TS_BYTE  pId;
-
-       TmDateTime scts;
-
-       tapi_nettext_coding_scheme dcs;
-
-       TS_UINT udl;
-
-       char  * userData;
-
-}TPDU_SMS_DELIVER;
-
-typedef struct
-{
-       /************HEADER************/
-       SmsTPDUType msg_type ;   //bit 0 ,1
-
-       TS_BOOL udhi ;  //bit 6
-
-       /************BODY************/
-
-       TS_UINT fcs;
-
-       TS_BYTE paraInd;
-
-       TS_BYTE pId;
-
-       tapi_nettext_coding_scheme dcs;
-
-       TS_UINT udl;
-
-       TS_BYTE * userData;
-
-}TPDU_SMS_DELIVER_REPORT;
-
-
-typedef struct
-{
-       /************HEADER************/
-       SmsTPDUType msg_type ;   //bit 0 ,1
-
-       TS_BOOL udhi ; //bit 6
-
-       TS_BOOL srr; //bit 5, status_report_request
-
-       /************BODY************/
-
-       TS_UINT  mr; //message_ref
-
-       TS_BYTE pId;
-
-       TS_BYTE cmdType;
-
-       TS_BYTE msgNum;
-
-       TelSmsAddressInfo_t destAddr;
-
-       TS_UINT udl;
-
-       TS_BYTE * userData;
-
-}TPDU_SMS_COMMAND;
-
-
-typedef struct
-{
-       /************HEADER************/
-
-       SmsTPDUType msg_type ;   //bit 0 ,1
-
-       TS_BOOL  udhi ; //bit 6
-
-       TS_BOOL mms ; //bit 2
-
-       TS_BOOL srq; //bit 5, status_report_qualifier
-
-       /************BODY************/
-
-       TS_UINT  mr;
-
-       TelSmsAddressInfo_t rcpAddr; //recipient_addr
-
-       TmDateTime scts;
-
-       TmDateTime dt; //discharge_time
-
-        TS_BYTE  status;
-
-        TS_BYTE paraInd;
-
-       TS_BYTE pId;
-
-       tapi_nettext_coding_scheme dcs;
-
-       TS_UINT udl;
-
-       char * userData;
-
-}TPDU_SMS_STATUS_REPORT;
-
-/**************************************************************************************
-*** (main.c) function header****************************************************************
-***************************************************************************************
-***************************************************************************************/
-int SendMessage();
-int ReadMessage();
-int DeleteMessage();
-int ReceiveMessage(int pdu_len, char * pPDU);
-int GetInformation();
-int Setting();
-
-TS_BOOL DecodeCellBroadcastMsg(int length,char * pPDU);
-TS_BOOL EncodeSmsSubmitTpdu(char* diallingNum, int dialNumLen, char* msg, int msg_len) ;
-TS_BOOL DecodeSmsSubmitTpdu(int pdu_len , char * pPDU);
-int  DecodeSmsDeliverTpdu(int pdu_len , char * pPDU);
-TS_BOOL EncodeSmsDeliverReportTpdu();
-TS_BOOL DecodeSmsSubmitReportTpdu(int length , char *data);
-TS_BOOL DecodeSmsStatusReportTpdu(int pdu_len, char * pPDU);
-
-/***************************************************************************************/
-void reverse(char* x, int len);
-char* AcItoa(int n, char* str, int b) ;
-int AcToupper(int ch);
-
-char* SmsUtilUnpackGSMCode(char* szData, const char* pIn, int in_len );
-int SmsUtilPackGSMCode( TS_BYTE* pOut, const char* szData, int in_len );
-
-void SmsUtilConvertBCD2Digit( char* pDigits, char* pBCD, int digitLen );
-void SmsUtilConvertDigit2BCD( char* pBCD, char* pDigits, int digitLen );
-
-TmDateTime* SmsUtilDecodeTimeStamp(char* pTimeStamp, TmDateTime *tmDateTime );
-unsigned char* SmsUtilEncodeTimeStamp( TmDateTime* tmDateTime, unsigned char* pTimeStamp );
-
-
-int  SmsUtilDecodeAddrField(char *diallingNum, char * pAddrField, int *result_ton, int *result_npi );
-int SmsUtilEncodeAddrField( unsigned char* pAddrField, char* diallingNum, int dialnumLen, int ton, int npi );
-
-int SmsUtilDecodeScAddrField( TelSmsAddressInfo_t* pSmsAddrField, TS_BYTE* pAddrField );
- int  SmsUtilEncodeScAddrField( TS_BYTE* pAddrField, TelSmsAddressInfo_t * pSmsAddrField );
-
-void SmsUtilDecodeDCS( tapi_nettext_coding_scheme* pCodingScheme,   unsigned char dcs );
-void SmsUtilEncodeDCS( TS_BYTE* pDCS, tapi_nettext_coding_scheme* pCodingScheme);
-
- TS_UINT8 SmsUtilEncodeValidity( TS_BYTE* pValidity, tapi_nettext_vp* pVP );
-
-
-
-
diff --git a/src/test_apps/tapi_sound_test.c b/src/test_apps/tapi_sound_test.c
deleted file mode 100644 (file)
index 291a9df..0000000
+++ /dev/null
@@ -1,476 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <string.h>
-#include <unistd.h>
-
-#include "assert.h"
-#include "glib.h"
-
-#include "ITapiSound.h"
-#include "TelUtility.h"
-#include "TapiEvent.h"
-#include "TapiCommon.h"
-
-#define TEST_DEBUG(frmt, args...)      \
-       {do { fprintf(stderr, "[SND Test][%s:%04d] " frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-
-#ifndef false
-       #define false 0
-#endif
-#ifndef true
-       #define true  !0
-#endif
-#ifndef bool
-       #define bool  char
-#endif
-
-#define MAX_CALL_INDEX                         6
-
-int data_status_;
-int data_service_;
-int callId;
-
-int tapi_thread_id;
-
-
-// this contains the tapi noti error info
-int error_code;
-
-
-// same as tapievent
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}data_t;
-
-static unsigned int *  SOUND_subscription_id;
-
-extern int  EvtDeliveryHandle;
-
-//static int  sound_app_callback (int group, int action, void* data, int length)
-//static int  sound_async_event_callback  (TelTapiEventClass_t eventClass, int eventType, int  param1,void * param2)
-static int  sound_async_event_callback (TelTapiEvent_t *event)
-{
-       TEST_DEBUG("EVENT TYPE:[0x%x], STATUS:[0x%x]", event->EventType, event->Status);
-
-       switch (event->EventClass)
-       {
-               case TAPI_EVENT_CLASS_SOUND:
-                       switch (event->EventType)
-                       {
-                               case TAPI_EVENT_SOUND_VOLUMECTRL_RSP: {
-                                       TEST_DEBUG("***  TAPI_EVENT_SOUND_MICGAINCTRL_RSP received  ****");
-
-                                       tapi_sound_volumn_ctrl_res vlm_ctrl_info;
-                                       int index;
-
-                                       memcpy(&vlm_ctrl_info, event->pData, sizeof(tapi_sound_volumn_ctrl_res));
-
-                                       TEST_DEBUG("num record:[%d]",vlm_ctrl_info.num_record);
-
-                                       for(index=0;index<vlm_ctrl_info.num_record;index++)
-                                       {
-                                               TEST_DEBUG("index:[%d], vol type:[0x%x]",index, vlm_ctrl_info.pinfo[index].type);
-                                               TEST_DEBUG("index:[%d], vol level:[0x%x]",index, vlm_ctrl_info.pinfo[index].level);
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SOUND_MICMUTECTRL_RSP:
-                                       TEST_DEBUG("***  TAPI_EVENT_SOUND_MICMUTECTRL_RSP received  ****");
-                                       tapi_sound_mic_mute_t *mute_status = NULL;
-                                       mute_status = (tapi_sound_mic_mute_t *)(event->pData);
-                                       if(*mute_status == TAPI_SOUND_MIC_UNMUTE){
-                                               TEST_DEBUG("MIC Unmute");
-                                       }
-                                       else if(*mute_status == TAPI_SOUND_MIC_MUTE){
-                                               TEST_DEBUG("MIC Mute");
-                                       }
-                                       else{
-                                               TEST_DEBUG("Unknown state");
-                                       }
-                                       break;
-
-                               case TAPI_EVENT_SOUND_ERROR_IND:
-                                       TEST_DEBUG("***  TAPI_EVENT_SOUND_ERROR_IND received  ****");
-                                       break;
-
-                               default:
-                                       TEST_DEBUG("***  Default Event  %x ****", event->EventType);
-                                       break;
-
-                       }
-
-                       break;
-
-               default:
-                       TEST_DEBUG("*** Other TAPI EVENT received : class : %x ****", event->EventClass);
-                       break;
-
-       }
-
-       return TRUE;
-}
-
-int sound_test_subscribe_tapi_events (void)
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfSOUNDEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int SOUNDEvtList[] =
-       {
-               TAPI_EVENT_SOUND_VOLUMECTRL_RSP,              /**<     */
-               TAPI_EVENT_SOUND_ERROR_IND,      /**<     */
-               TAPI_EVENT_SOUND_AUDIOPATHCTRL_NOTI,      /**<     */
-               TAPI_EVENT_SOUND_AUDIOSOURCECTRL_NOTI,      /**<     */
-               TAPI_EVENT_SOUND_MICMUTECTRL_RSP,      /**<     */
-       };
-
-       iNumOfSOUNDEvt = sizeof(SOUNDEvtList)/sizeof(int);
-       //TAPI_CALLOC(SOUND_subscription_id, iNumOfSOUNDEvt, unsigned int)
-       //#define TAPI_CALLOC(ptr, no_elements, type)
-       SOUND_subscription_id = (unsigned int *) calloc (iNumOfSOUNDEvt , sizeof (unsigned int));
-       if(SOUND_subscription_id == NULL)\
-       {
-               TEST_DEBUG("calloc error -NULL, errno is [%d]", errno);
-       }
-
-       for( i=0 ; i< iNumOfSOUNDEvt; i++ )
-       {
-               api_err = tel_register_event(SOUNDEvtList[i], &SOUND_subscription_id[i],(TelAppCallback)&sound_async_event_callback,NULL);
-               if(api_err != TAPI_API_SUCCESS)
-               {
-                       TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", SOUNDEvtList[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-}
-
-
-int sound_read_key_input(void)
-{
-       int ret;
-       char buf[256];
-       int requestId;
-       TapiResult_t ret_val = TAPI_API_SUCCESS;
-
-
-       tapi_sound_volume_type_t vol_type;
-       tapi_sound_volume_control_t vol_control;
-       tapi_sound_mic_mute_t micmute_set;
-       tapi_sound_audio_path_t  vc_path;
-       tapi_sound_voice_recording_status_t voice_record ;
-
-
-       memset(&vol_control, 0, sizeof(tapi_sound_volume_type_t));
-       memset(&vol_control, 0, sizeof(tapi_sound_volume_control_t));
-       memset(&micmute_set, 0, sizeof(tapi_sound_mic_mute_t));
-       memset(&vc_path, 0, sizeof(tapi_sound_audio_path_t));
-
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-                        perror("read(1)");
-               return -1;
-        }
-       else if (ret == 0)
-               return ret;
-
-       TEST_DEBUG("*************** SOUND TEST MENU     ***************");
-       TEST_DEBUG("VOLUME CTRL GET:[vlmget]");
-       TEST_DEBUG("VOLUME CTRL SET:[vlmset]");
-       TEST_DEBUG("MIC_MUTE_SET:[mmset] ");
-       TEST_DEBUG("MIC_MUTE_GET:[mmget] ");
-       TEST_DEBUG("VOICE_PATH_SET:[vpathset] ");
-       TEST_DEBUG("AUDIO_LOOPBACK:[loopback] ");
-       TEST_DEBUG("quit Sound test:[quit] ");
-       TEST_DEBUG("Voice Call Recording on test:[vcre] ");
-       TEST_DEBUG("Voice Call Recording off test:[vcrd] ");
-       TEST_DEBUG("*************************************************");
-
-       if(strncmp(buf, "vlmget", 6) == 0)
-       {
-               vol_type =TAPI_SOUND_VOL_VOICE;
-               ret_val= tel_get_sound_volume_info(vol_type,&requestId);
-               TEST_DEBUG("tapi_sound_volume_control_get return value is %d ",ret_val);
-       }
-       else if(strncmp(buf, "vlmset", 6) == 0)
-       {
-               vol_control.volume=TAPI_SOUND_VOLUME_LEVEL_7;
-               vol_control.vol_type=TAPI_SOUND_VOL_VOICE;
-
-               ret_val= tel_set_sound_volume_info(vol_control,&requestId);
-               TEST_DEBUG("tapi_sound_volume_control_set return value is %d ",ret_val);
-        }
-        else if(strncmp(buf, "mmset", 5) == 0)
-       {
-               micmute_set=TAPI_SOUND_MIC_UNMUTE;
-               TEST_DEBUG("micmute set value = TAPI_SOUND_MIC_UNMUTE");
-               ret_val=tel_set_sound_mute_status(micmute_set,&requestId);
-               TEST_DEBUG("tapi_sound_micmute_control_set return value is %d ",ret_val);
-       }
-        else if(strncmp(buf, "mmget", 5) == 0)
-       {
-               micmute_set=TAPI_SOUND_MIC_UNMUTE;
-               TEST_DEBUG("micmute set value = TAPI_SOUND_MIC_UNMUTE");
-               ret_val=tel_get_sound_mute_status(&requestId);
-               TEST_DEBUG("tapi_sound_micmute_control_get return value is %d ",ret_val);
-       }
-       else if(strncmp(buf, "vcre", 4) == 0)
-       {
-               voice_record=TAPI_SOUND_VOICE_RECORDING_ON;
-               TEST_DEBUG("voice_record = TAPI_SOUND_VOICE_RECORDING_ON");
-
-               ret_val=tel_control_sound_voice_recording(TAPI_SOUND_VOICE_RECORDING_ON,&requestId);
-
-               TEST_DEBUG("tel_control_sound_voice_recording on return value is %d ",ret_val);
-       }
-       else if(strncmp(buf, "vcrd", 4) == 0)
-       {
-               voice_record=TAPI_SOUND_VOICE_RECORDING_OFF;
-               TEST_DEBUG("voice_record = TAPI_SOUND_VOICE_RECORDING_OFF");
-               ret_val=tel_control_sound_voice_recording(TAPI_SOUND_VOICE_RECORDING_OFF,&requestId);
-
-               TEST_DEBUG("tel_control_sound_voice_recording off return value is %d ",ret_val);
-       }
-       else if(strncmp(buf, "vpathset", 8) == 0)
-       {
-               int iSelect = 0;
-               TEST_DEBUG("1. TAPI_SOUND_HANDSET");
-               TEST_DEBUG("2. TAPI_SOUND_HEADSET");
-               TEST_DEBUG("3. TAPI_SOUND_HANDSFREE");
-               TEST_DEBUG("4. TAPI_SOUND_BLUETOOTH");
-               TEST_DEBUG("5. TAPI_SOUND_STEREO_BLUETOOTH");
-               TEST_DEBUG("6. TAPI_SOUND_SPK_PHONE");
-               TEST_DEBUG("7. TAPI_SOUND_HEADSET_3_5PI");
-
-               TEST_DEBUG("Select: ");
-               scanf("%d", &iSelect);
-
-               switch(iSelect)
-               {
-                       case 1:
-                               vc_path = TAPI_SOUND_HANDSET;
-                               TEST_DEBUG("TAPI_SOUND_HANDSET");
-                               break;
-                       case 2:
-                               vc_path = TAPI_SOUND_HEADSET;
-                               TEST_DEBUG("TAPI_SOUND_HEADSET");
-                               break;
-                       case 3:
-                               vc_path = TAPI_SOUND_HANDSFREE;
-                               TEST_DEBUG("TAPI_SOUND_HANDSFREE");
-                               break;
-                       case 4:
-                               vc_path = TAPI_SOUND_BLUETOOTH;
-                               TEST_DEBUG("TAPI_SOUND_BLUETOOTH");
-                               break;
-                       case 5:
-                               vc_path = TAPI_SOUND_STEREO_BLUETOOTH;
-                               TEST_DEBUG("TAPI_SOUND_STEREO_BLUETOOTH");
-                               break;
-                       case 6:
-                               vc_path = TAPI_SOUND_SPK_PHONE;
-                               TEST_DEBUG("TAPI_SOUND_SPK_PHONE");
-                               break;
-                       case 7:
-                               vc_path = TAPI_SOUND_HEADSET_3_5PI;
-                               TEST_DEBUG("TAPI_SOUND_HEADSET_3_5PI");
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!\n");
-                               return 0;
-                               break;
-               }
-
-               ret_val=tel_set_sound_path(vc_path,&requestId);
-               TEST_DEBUG("vc_path:[%d],  return value [%d] ",vc_path, ret_val);
-       }
-
-       else if(strncmp(buf, "loopback", 8) == 0)
-       {
-               TelAudioLoopbackMode_t lpMode;
-               int iSelect = 0;
-
-               TEST_DEBUG("Select Audio Loopback Path");
-               TEST_DEBUG("1. TAPI_SOUND_HANDSET");
-               TEST_DEBUG("2. TAPI_SOUND_HEADSET");
-               TEST_DEBUG("3. TAPI_SOUND_HANDSFREE");
-               TEST_DEBUG("4. TAPI_SOUND_BLUETOOTH");
-               TEST_DEBUG("5. TAPI_SOUND_STEREO_BLUETOOTH");
-               TEST_DEBUG("6. TAPI_SOUND_SPK_PHONE");
-               TEST_DEBUG("7. TAPI_SOUND_HEADSET_3_5PI");
-
-               TEST_DEBUG("Select: ");
-               scanf("%d", &iSelect);
-
-               switch(iSelect)
-               {
-                       case 1:
-                               lpMode.path = TAPI_SOUND_HANDSET;
-                               TEST_DEBUG("TAPI_SOUND_HANDSET");
-                               break;
-                       case 2:
-                               lpMode.path = TAPI_SOUND_HEADSET;
-                               TEST_DEBUG("TAPI_SOUND_HEADSET");
-                               break;
-                       case 3:
-                               lpMode.path = TAPI_SOUND_HANDSFREE;
-                               TEST_DEBUG("TAPI_SOUND_HANDSFREE");
-                               break;
-                       case 4:
-                               lpMode.path = TAPI_SOUND_BLUETOOTH;
-                               TEST_DEBUG("TAPI_SOUND_BLUETOOTH");
-                               break;
-                       case 5:
-                               lpMode.path = TAPI_SOUND_STEREO_BLUETOOTH;
-                               TEST_DEBUG("TAPI_SOUND_STEREO_BLUETOOTH");
-                               break;
-                       case 6:
-                               lpMode.path = TAPI_SOUND_SPK_PHONE;
-                               TEST_DEBUG("TAPI_SOUND_SPK_PHONE");
-                               break;
-                       case 7:
-                               lpMode.path = TAPI_SOUND_HEADSET_3_5PI;
-                               TEST_DEBUG("TAPI_SOUND_HEADSET_3_5PI");
-                               break;
-                       default:
-                               TEST_DEBUG("Wrong Selection!!\n");
-                               return 0;
-                               break;
-               }
-
-               TEST_DEBUG("Enable[1] Disable[0]");
-               scanf("%d", &iSelect);
-
-               if(iSelect == 1){
-                       lpMode.status = TAPI_SOUND_AUDIO_LOOPBACK_PCM_ON;
-               }
-               else if(iSelect == 0){
-                       lpMode.status = TAPI_SOUND_AUDIO_LOOPBACK_OFF;
-               }
-               else{
-                       TEST_DEBUG("Unknown Type loopback status!\n");
-                       return 0;
-               }
-
-               ret_val=tel_set_sound_loopback( &lpMode, &requestId);
-               TEST_DEBUG("audio loopback return value [%d] \n", ret_val);
-       }
-       else if(strncmp(buf, "quit", 4) == 0)
-       {
-               TEST_DEBUG("sound test done ");
-               return -1;
-       }
-       memset(buf, '\0', 256);
-
-       return 0;
-
-}
-
-
-void sound_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-
-    while (1)
-               {
-        FD_ZERO(&readfds);
-        FD_SET(0, &readfds);
-
-
-        ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-        if (ret) {
-
-           if (FD_ISSET(0, &readfds)) {
-                 if(sound_read_key_input()<0)
-                       break;
-            }
-        }
-    }
-}
-
-
-
-void* sound_test_thread_loop(void* data)
-{
-       TEST_DEBUG(" sound_test_thread_loop : called...");
-
-       sound_select_loop();
-
-       TEST_DEBUG(" sound_test_thread_loop : stdin Loop exited");
-
-       pthread_exit(NULL);
-}
-
-#if 0
-int sound_main(int argc, char *argv[])
-{
-
-       pthread_t  p_thread;
-
-//     ret = get_handle();
-
-
-       tapi_thread_id = pthread_create(&p_thread, NULL, sound_test_thread_loop, NULL);
-
-       if(tapi_thread_id != 0)
-       {
-               TEST_DEBUG("Failed while creating a thread to read from stdin");
-               return -1;
-       }
-       else
-       {
-               TEST_DEBUG("a thread was created to read from stdin ..");
-       }
-
-       sound_test_subscribe_tapi_events();
-
-       pthread_join(p_thread, NULL);
-
-       TEST_DEBUG("Exiting PS test program bye bye !");
-
-       return 0;
-
-}
-#endif
-
diff --git a/src/test_apps/tapi_ss_test.c b/src/test_apps/tapi_ss_test.c
deleted file mode 100644 (file)
index 91c3129..0000000
+++ /dev/null
@@ -1,1189 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include "assert.h"
-#include "glib.h"
-
-#include "TelErr.h"
-#include "TelUtility_ext.h"
-#include "ITapiMisc.h"
-#include "ITapiSs.h"
-#include "TapiCommon.h"
-#include "ITapiSim.h"
-
-
-#define TEST_DEBUG(frmt, args...)      \
-       {do { fprintf(stderr, "[SS Test][%s:%04d] " frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-
-#ifndef bool
-       #define bool  char
-#endif
-
-// same as tapievent
-typedef struct
-{
-       int group;
-       int type;
-       int ID;
-       int status;
-       void *dst;
-}data_t;
-
-static unsigned int *  SS_subscription_id;
-
-extern int EvtDeliveryHandle ;
-
-
-int ss_strlen2(register const char * s ) {
-       int count = 0 ;
-       while( *s++ ) count ++ ;
-       return count ;
-} // end strlen()
-
-
-int ss_fgets(register char * digit, int n)
-{
-       if( ! fgets( digit , n , stdin ) )  return -1 ;
-
-       if( *(digit + (n = ss_strlen2(digit)-1)) ^ '\n' )  {
-               n = 0 ;
-               while( getchar() ^ '\n' ) n -- ;
-               if( n ) return 1 ;
-
-               return 0;
-       }
-       else
-               *( digit + n ) = 0 ;
-       return 0 ;
-}
-
-static int _PrintTeleCommService(TelSsTeleService_t telservice)
-{
-       switch(telservice)
-       {
-               case TAPI_SS_TS_ALL_TELESERVICES:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_TELESERVICES ");
-                       break;
-               case TAPI_SS_TS_ALL_SPEECH:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_SPEECH ");
-                       break;
-               case TAPI_SS_TS_ALL_DATA_TELESERVICES:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_DATA_TELESERVICES ");
-                       break;
-               case TAPI_SS_TS_FACS:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_FACS ");
-                       break;
-               case TAPI_SS_TS_SMS:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_SMS ");
-                       break;
-               case TAPI_SS_TS_ALL_TELESERVICES_EXCEPT_SMS:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_TELESERVICES_EXCEPT_SMS ");
-                       break;
-               case TAPI_SS_TS_ALL_PLMN_SPEC_TELE:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_PLMN_SPEC_TELE ");
-                       break;
-               case TAPI_SS_BS_ALL_BEARER_SERVICES:
-                       TEST_DEBUG("TeleService: TAPI_SS_BS_ALL_BEARER_SERVICES ");
-                       break;
-               case TAPI_SS_BS_ALL_ASYNCHRONOUS:
-                       TEST_DEBUG("TeleService: TAPI_SS_BS_ALL_ASYNCHRONOUS ");
-                       break;
-               case TAPI_SS_BS_ALL_SYNCHRONOUS:
-                       TEST_DEBUG("TeleService: TAPI_SS_BS_ALL_SYNCHRONOUS ");
-                       break;
-               case TAPI_SS_BS_DATA_CIRCUIT_SYNC:
-                       TEST_DEBUG("TeleService: TAPI_SS_BS_DATA_CIRCUIT_SYNC ");
-                       break;
-               case TAPI_SS_TS_ALL_DATA:
-                       TEST_DEBUG("TeleService: TAPI_SS_TS_ALL_DATA ");
-                       break;
-               case TAPI_SS_ALL_TELE_BEARER:
-                       TEST_DEBUG("TeleService: TAPI_SS_ALL_TELE_BEARER ");
-                       break;
-               default:
-                       TEST_DEBUG("TeleService: %d ", telservice);
-                       break;
-       }
-
-       return 0;
-}
-static int _PrintBarringType(TelSsCallBarType_t BarType)
-{
-       switch(BarType)
-       {
-               case TAPI_CALL_BARRING_ALL:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL ");
-                       break;
-               case TAPI_CALL_BARRING_OUTGOING:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_OUTGOING ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_OUTGOING_CALLS:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_OUTGOING_CALLS ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL_EXCEPT:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_OUTGOING_INTERN_CALL_EXCEPT ");
-                       break;
-               case TAPI_CALL_BARRING_INCOMING:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_INCOMING ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_INCOMING_CALLS:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_INCOMING_CALLS ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_INCOMING_CALLS_ROAMING:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_INCOMING_CALLS_ROAMING ");
-                       break;
-               case TAPI_CALL_BARRING_ALL_INCOMING_CALLS_INSIM:
-                       TEST_DEBUG("BarringType: TAPI_CALL_BARRING_ALL_INCOMING_CALLS_INSIM ");
-                       break;
-               default:
-                       TEST_DEBUG("BarringType: None [%d] ", BarType);
-                       break;
-       }
-
-       return 0;
-}
-
-static int _PrintSsStatus(TelSsStatus_t Status)
-{
-       switch(Status)
-       {
-               case TAPI_SS_STATUS_ACTIVE:
-                       TEST_DEBUG("SS Status: TAPI_SS_STATUS_ACTIVE ");
-                       break;
-               case TAPI_SS_STATUS_REGISTERED:
-                       TEST_DEBUG("SS Status: TAPI_SS_STATUS_REGISTERED (for CF) ");
-                       break;
-               default:
-                       TEST_DEBUG("SS Status: Not Active ");
-                       break;
-       }
-
-       return 0;
-}
-
-static int _PrintSsCliType(TelSsLineIdentificationType_t CliType)
-{
-       switch(CliType)
-       {
-               case TAPI_CALLING_LINE_IDENTITY_PRESENTATION:
-                       TEST_DEBUG("Type: TAPI_CALLING_LINE_IDENTITY_PRESENTATION ");
-                       break;
-               case TAPI_CALLING_LINE_IDENTITY_RESTRICTION:
-                       TEST_DEBUG("Type: TAPI_CALLING_LINE_IDENTITY_RESTRICTION ");
-                       break;
-               case TAPI_CONNECTED_LINE_IDENTITY_PRESENTATION:
-                       TEST_DEBUG("Type: TAPI_CONNECTED_LINE_IDENTITY_PRESENTATION ");
-                       break;
-               case TAPI_CONNECTED_LINE_IDENTITY_RESTRICTION:
-                       TEST_DEBUG("Type: TAPI_CONNECTED_LINE_IDENTITY_RESTRICTION ");
-                       break;
-               case TAPI_CALLED_LINE_IDENTITY_PRESENTATION:
-                       TEST_DEBUG("Type: TAPI_CALLED_LINE_IDENTITY_PRESENTATION ");
-                       break;
-               case TAPI_CALLING_NAME_PRESENTATION:
-                       TEST_DEBUG("Type: TAPI_CALLING_NAME_PRESENTATION ");
-                       break;
-               default:
-                       TEST_DEBUG("Type: None [%d] ", CliType);
-                       break;
-       }
-
-       return 0;
-}
-
-static int _PrintSsCliStatus(TelSsCliStatus_t CliStatus)
-{
-       switch(CliStatus)
-       {
-               case TAPI_CLI_STATUS_NOT_PROVISONED:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_NOT_PROVISONED ");
-                       break;
-               case TAPI_CLI_STATUS_PROVISIONED:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_PROVISIONED ");
-                       break;
-               case TAPI_CLI_STATUS_ACTIVATED:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_ACTIVATED ");
-                       break;
-               case TAPI_CLI_STATUS_UNKOWN:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_UNKOWN ");
-                       break;
-               case TAPI_CLI_STATUS_TEMP_RESTRICTED:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_TEMP_RESTRICTED ");
-                       break;
-               case TAPI_CLI_STATUS_TEMP_ALLOWED:
-                       TEST_DEBUG("CliStatus: TAPI_CLI_STATUS_TEMP_ALLOWED ");
-                       break;
-               default:
-                       TEST_DEBUG("CliStatus: None [%d] ", CliStatus);
-                       break;
-       }
-
-       return 0;
-}
-
-static int _PrintSsUssdRecord(TelSsUssdMsgIndInfo_t ussd_record)
-{
-       switch(ussd_record.IndType)
-       {
-               case TAPI_USSD_IND_NOTIFY:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_NOTIFY ");
-                       break;
-               case TAPI_USSD_IND_NO_ACTION_REQUIRE:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_NO_ACTION_REQUIRE ");
-                       break;
-               case TAPI_USSD_IND_ACTION_REQUIRE:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_ACTION_REQUIRE ");
-                       break;
-               case TAPI_USSD_IND_TERMINATED_BY_NET:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_TERMINATED_BY_NET ");
-                       break;
-               case TAPI_USSD_IND_OTHER_CLIENT:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_OTHER_CLIENT ");
-                       break;
-               case TAPI_USSD_IND_NOT_SUPPORT:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_NOT_SUPPORT ");
-                       break;
-               case TAPI_USSD_IND_TIME_OUT:
-                       TEST_DEBUG("UssdIndType: TAPI_USSD_IND_TIME_OUT ");
-                       break;
-               default:
-                       TEST_DEBUG("UssdIndType: None [%d] ", ussd_record.IndType);
-                       break;
-       }
-
-       TEST_DEBUG("RequestedBySAT:[%d]",ussd_record.UssdInfo.RequestedBySAT);
-       TEST_DEBUG("DCS         : [0x%x]",ussd_record.UssdInfo.Dcs);
-       TEST_DEBUG("ussd length : [%d] ", ussd_record.UssdInfo.UssdStringLength);
-       TEST_DEBUG("ussd string : [\n%s\n] ", ussd_record.UssdInfo.szUssdString);
-
-       return 0;
-}
-
-static int _PrintCFNoReplyWaitTime(TelSsNoReplyTime_t time)
-{
-       switch(time)
-       {
-               case TAPI_SS_CF_NO_REPLY_TIME_5_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_5_SECS ");
-                       break;
-               case TAPI_SS_CF_NO_REPLY_TIME_10_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_10_SECS ");
-                       break;
-               case TAPI_SS_CF_NO_REPLY_TIME_15_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_15_SECS ");
-                       break;
-               case TAPI_SS_CF_NO_REPLY_TIME_20_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_20_SECS ");
-                       break;
-               case TAPI_SS_CF_NO_REPLY_TIME_25_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_25_SECS ");
-                       break;
-               case TAPI_SS_CF_NO_REPLY_TIME_30_SECS:
-                       TEST_DEBUG("CF reply time : TAPI_SS_CF_NO_REPLY_TIME_30_SECS ");
-                       break;
-               default:
-                       TEST_DEBUG("CF reply time: None [%d] ", time);
-                       break;
-       }
-       return 0;
-}
-
-static int _PrintCFCondition(TelSsForwardWhen_t cond)
-{
-       switch(cond)
-       {
-               case TAPI_SS_FORWARD_WHEN_UNCONDITIONAL_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_UNCONDITIONAL_EV ");
-                       break;
-               case TAPI_SS_FORWARD_WHEN_BUSY_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_BUSY_EV ");
-                       break;
-               case TAPI_SS_FORWARD_WHEN_NO_ANSWER_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_NO_ANSWER_EV ");
-                       break;
-               case TAPI_SS_FORWARD_WHEN_NOT_REACHABLE_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_NOT_REACHABLE_EV ");
-                       break;
-               case TAPI_SS_FORWARD_WHEN_ALL_FORWARDING_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_ALL_FORWARDING_EV ");
-                       break;
-               case TAPI_SS_FORWARD_WHEN_ALL_CONDITIONAL_EV:
-                       TEST_DEBUG("CF condition : TAPI_SS_FORWARD_WHEN_ALL_CONDITIONAL_EV ");
-                       break;
-               default:
-                       TEST_DEBUG("CF condition : None [%d] ", cond);
-                       break;
-       }
-       return 0;
-}
-
-//static int  ss_async_event_callback(TelTapiEventClass_t eventClass, int eventType, int  param1,void * param2)
-static int  ss_async_event_callback(TelTapiEvent_t     *event)
-{
-       TEST_DEBUG("EVENT TYPE:[0x%x], STATUS:[0x%x]", event->EventType, event->Status);
-
-       int i = 0;
-
-       switch(event->EventClass)
-       {
-               case TAPI_EVENT_CLASS_SS:
-               {
-                       switch(event->EventType)
-                       {
-                               case TAPI_EVENT_SS_REL_COMP_MSG_NOTIFY:
-                               {
-                                       TelSsRelCompMsgInfo_t      rel_comp_msg;
-                                       memcpy(&rel_comp_msg, (TelSsRelCompMsgInfo_t *)event->pData, sizeof(TelSsRelCompMsgInfo_t));
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_REL_COMP_MSG_NOTIFY  ##### ");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_WAITING_CNF:
-                               {
-                                       TelSsInfo_t SsInfo = {0,};
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_WAITING_CNF  ##### ");
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("Index:[%d]",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.WaitingRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.WaitingRecord.rec_class[i].TeleCommService);
-                                               }
-                                       }
-                               }
-
-                                       break;
-
-                               case TAPI_EVENT_SS_WAITING_QUERYSTATUS_CNF:
-                               {
-                                       TelSsInfo_t SsInfo = {0,};
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_WAITING_QUERYSTATUS_CNF  ##### ");
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("Index:[%d]",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.WaitingRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.WaitingRecord.rec_class[i].TeleCommService);
-                                               }
-                                       }
-                               }
-                                       break;
-                               case TAPI_EVENT_SS_BARRING_CNF:
-                               {
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_BARRING_CNF  ##### ");
-                                       TelSsInfo_t SsInfo = {0,};
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("index:[%d] ",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.BarringRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.BarringRecord.rec_class[i].TeleCommService);
-                                                       _PrintBarringType(SsInfo.SsRecord.BarringRecord.rec_class[i].Flavour);
-
-                                               }
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_BARRING_QUERYSTATUS_CNF:
-                               {
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_BARRING_QUERYSTATUS_CNF  ##### ");
-                                       TelSsInfo_t SsInfo = {0,};
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("index:[%d] ",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.BarringRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.BarringRecord.rec_class[i].TeleCommService);
-                                                       _PrintBarringType(SsInfo.SsRecord.BarringRecord.rec_class[i].Flavour);
-                                               }
-
-                                       }
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_FORWARD_CNF:
-                               {
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_FORWARD_CNF  ##### ");
-                                       TelSsInfo_t SsInfo = {0,};
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("index:[%d] ",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.ForwardingRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.ForwardingRecord.rec_class[i].TeleCommService);
-                                                       _PrintCFNoReplyWaitTime(SsInfo.SsRecord.ForwardingRecord.rec_class[i].NoReplyWaitTime);
-                                                       _PrintCFCondition(SsInfo.SsRecord.ForwardingRecord.rec_class[i].ForwardCondition);
-                                                       TEST_DEBUG("bCFNumPresent:[%d] ",SsInfo.SsRecord.ForwardingRecord.rec_class[i].bCallForwardingNumberPresent);
-                                                       TEST_DEBUG("bCFNum:[%s] ",SsInfo.SsRecord.ForwardingRecord.rec_class[i].szCallForwardingNumber);
-                                               }
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_FORWARD_QUERYSTATUS_CNF:
-                               {
-                                       TEST_DEBUG("####  Received Event :TAPI_EVENT_SS_FORWARD_QUERYSTATUS_CNF  ##### ");
-                                       TelSsInfo_t SsInfo = {0,};
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-
-                                               TEST_DEBUG("Number of records %d ",SsInfo.NumberOfRecords);
-
-                                               for(i=0;i<SsInfo.NumberOfRecords;i++)
-                                               {
-                                                       TEST_DEBUG("index:[%d] ",i);
-                                                       _PrintSsStatus(SsInfo.SsRecord.ForwardingRecord.rec_class[i].Status);
-                                                       _PrintTeleCommService(SsInfo.SsRecord.ForwardingRecord.rec_class[i].TeleCommService);
-                                                       _PrintCFNoReplyWaitTime(SsInfo.SsRecord.ForwardingRecord.rec_class[i].NoReplyWaitTime);
-                                                       _PrintCFCondition(SsInfo.SsRecord.ForwardingRecord.rec_class[i].ForwardCondition);
-                                                       TEST_DEBUG("bCFNumPresent:[%d] ",SsInfo.SsRecord.ForwardingRecord.rec_class[i].bCallForwardingNumberPresent);
-                                                       TEST_DEBUG("bCFNum:[%s] ",SsInfo.SsRecord.ForwardingRecord.rec_class[i].szCallForwardingNumber);
-                                               }
-                                       }
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_BARRING_CHANGEPASS_CNF:
-                               {
-                                       TEST_DEBUG("####  Received Event : TAPI_EVENT_SS_BARRING_CHANGEPASS_CNF  ##### ");
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_CLI_QUERYSTATUS_CNF:
-                               {
-                                       TelSsInfo_t SsInfo = {0,};
-
-                                       TEST_DEBUG("####  Received Event : TAPI_EVENT_SS_CLI_QUERYSTATUS_CNF #### ");
-
-                                       if (event->pData!=NULL)
-                                       {
-                                               memcpy(&SsInfo, (TelSsInfo_t*)event->pData, sizeof(TelSsInfo_t));
-                                                _PrintSsCliType(SsInfo.SsRecord.CliRecord.IdentificationType);
-                                               _PrintSsCliStatus(SsInfo.SsRecord.CliRecord.CliStatus);
-                                       }
-
-                               }
-                                       break;
-
-                               case TAPI_EVENT_SS_USSD_CNF:
-                               {
-                                       TelSsUssdMsgIndInfo_t      ussd_record;
-                                       TEST_DEBUG("####  Received Event : TAPI_EVENT_SS_USSD_CNF #### ");
-
-                                       if (event->pData != NULL)
-                                       {
-                                               memcpy(&ussd_record, (TelSsUssdMsgIndInfo_t *)event->pData, sizeof(TelSsUssdMsgInfo_t));
-                                               _PrintSsUssdRecord(ussd_record);
-                                       }
-                                       else
-                                       {
-                                               TEST_DEBUG("NULL param");
-                                       }
-
-                               }
-                                       break;
-                               //Indication with ACTION_REQUIRE
-                               case TAPI_EVENT_SS_USSD_IND:
-                               {
-                                       TelSsUssdMsgIndInfo_t      ussd_record;
-                                       TEST_DEBUG("####  Received Event : TAPI_EVENT_SS_USSD_IND  ##### ");
-
-                                       if (event->pData != NULL)
-                                       {
-                                               memcpy(&ussd_record, (TelSsUssdMsgInfo_t *)event->pData, sizeof(TelSsUssdMsgInfo_t));
-                                               _PrintSsUssdRecord(ussd_record);
-                                       }
-                                       else
-                                       {
-                                               TEST_DEBUG("NULL param");
-                                       }
-
-                               }
-                               break;
-
-
-                               case TAPI_EVENT_SS_AOC_RSP:
-                               {
-                                       TelCallAocInfo_t aoc_info;
-                                       TEST_DEBUG("####  Received Event : SS -- TAPI_EVENT_SS_AOC_RSP---#### ");
-                                       if(event->Status != 0)
-                                       {
-                                               memcpy(&aoc_info, (TelCallAocInfo_t*)event->pData, sizeof(TelCallAocInfo_t));
-
-                                               TEST_DEBUG("############# AOC TYPE :%d",aoc_info.AocType);
-                                               TEST_DEBUG("Printing ### ACM : [%ld]  MAX_ACM :[%ld] CCM:[%0.4f] Char type:[%d] ",aoc_info.ACM,aoc_info.MaxAcm,aoc_info.CCM,aoc_info.CharTypeOfCurrency);
-                                               TEST_DEBUG("Currency : %c %c %c ",aoc_info.szCurrency[0], aoc_info.szCurrency[1], aoc_info.szCurrency[2]);
-                                       }
-
-                               }
-                                       break;
-                               case TAPI_EVENT_SS_SET_AOC_CNF:
-                                       TEST_DEBUG("####  Received Event : SS -- TAPI_EVENT_SS_SET_AOC_CNF---#### ");
-                                       break;
-                               case TAPI_EVENT_SS_BARRING_TYPE_IND:
-                               {
-                                       TelSsCallBarType_t BarringType;
-                                       TEST_DEBUG("####  Received Event : SS -- TAPI_EVENT_SS_BARRING_TYPE_IND---#### ");
-
-                                       memcpy(&BarringType, (TelSsCallBarType_t*)event->pData, sizeof(TelSsCallBarType_t));
-                                       TEST_DEBUG("########### BarringType received is [%x]",BarringType);
-                               }
-                                       break;
-
-                               default:
-                                       break;
-                       }
-               }
-                       break;
-
-               default:
-                       break;
-       }
-       TEST_DEBUG("###################################################################");
-
-       return 1;
-
-}
-
-
-
-int ss_read_key_input(void)
-{
-       int ret2;
-       char buf[256];
-       int request_id =0;
-       TapiResult_t ret = TAPI_API_SUCCESS;
-
-       ret2 = read(0, buf, sizeof(buf));
-        if (ret2 < 0) {
-         if (errno == EINTR)
-         perror("read(1)");
-         return -1;
-        } else if (ret2 == 0) return ret2;
-
-
-       printf("\n########## SS TEST Application #########\n");
-       printf("########## Supplementary Services  - Options ############\n");
-
-       printf("Call Waiting [1] Call Barring  [2] Call Forwarding [3] \n");
-       printf("Query Status [a]    Activate [b]   Deactivate [c]  Registration [d]  Deregistration [e]\n");
-       printf("Change Call barring Password  Enter - [cbp]\n");
-       printf("Interrogate  the Status of Line Identity Services like CLIP, CLIR etc - Enter [cli]\n");
-       printf("Send USSD String  - Enter [ussd]\n");
-       printf("Test AOC  - First - SimOpen and Enter PIN2 ---[simopen] [pin2]\n");
-       printf("Read AOC Information - Enter [raoc] \n");
-       printf("Set Maximum Cost limit- [5e], Set Price/Unit Currency-[5f], Reset Cost Limit-[5g]\n");
-       printf("quit - [quit]\n");
-
-       printf("##########################################\n");
-       printf("SS Enter key   : %s", buf);
-
-       /* Call waiting */
-       if(strncmp(buf, "1a", 2) == 0 )
-       {
-               char cwType[1];
-               TelSsWaitingInfo_t cwInfo = {0,};
-               TEST_DEBUG("### Interrogate the status of Call Waiting  #### ");
-
-               TEST_DEBUG("Select the Call Waiting Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cwType,2);
-
-               cwInfo.CallType = atoi(cwType);
-
-               TEST_DEBUG("SS CallType:[%d]",cwInfo.CallType);
-
-               ret = tel_get_ss_waiting_status(cwInfo.CallType,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-
-       if(strncmp(buf, "1b", 2) == 0 )
-       {
-               char cwType[1];
-               TEST_DEBUG("### Activate Call Waiting  #### ");
-               TelSsWaitingInfo_t cwInfo = {0,};
-
-               TEST_DEBUG("Select the Call Waiting Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cwType,2);
-
-               cwInfo.CallType = atoi(cwType);
-               cwInfo.Mode = TAPI_SS_CW_ACTIVATE;
-
-               TEST_DEBUG("SS CallType:[%d]",cwInfo.CallType);
-               ret = tel_set_ss_waiting(&cwInfo,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-
-       if(strncmp(buf, "1c", 2) == 0 )
-       {
-               char cwType[1];
-               TEST_DEBUG("### DeActivate Call Waiting  #### ");
-               TelSsWaitingInfo_t cwInfo = {0,};
-
-               TEST_DEBUG("Select the Call Waiting Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cwType,2);
-
-               cwInfo.CallType = atoi(cwType);
-               cwInfo.Mode = TAPI_SS_CW_DEACTIVATE;
-
-               TEST_DEBUG("SS CallType:[%d]",cwInfo.CallType);
-               ret = tel_set_ss_waiting(&cwInfo,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-
-       }
-
-       /* Call barring */
-       if(strncmp(buf, "2a", 2) == 0)
-       {
-               TelSsCallBarringInfo_t  cb_req = {0,};
-               char cbType[1];
-               char cba_fla[10];
-               TEST_DEBUG("####        Interrogate Status of Call barring for Voice Calls              ####");
-
-               TEST_DEBUG("Enter Call Barring Flavor type(BAOC -2, BAIC-6) ");
-               TEST_DEBUG(" All Barring -[0] Out Going calls - [1] All outgoing calls [2] ");
-               TEST_DEBUG(" Outgoing Intl calls -[3] All ougoing intl calls except home[4] - Barring incoming [5]  All Incoming calls [6]");
-               TEST_DEBUG(" All incoming calls in roaming -[7] All incoming calls in Sim [2] ");
-               ss_fgets(cba_fla,5);
-               cb_req.Type = atoi(cba_fla);
-
-               TEST_DEBUG("Select the SS Call Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cbType,2);
-               cb_req.CallType = atoi(cbType);
-
-               TEST_DEBUG("CB type:[%d], SS CallType:[%d]", cb_req.Type, cb_req.CallType);
-
-               ret = tel_get_ss_barring_status(cb_req.Type, cb_req.CallType,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-         }
-
-       if(strncmp(buf, "2b",2) == 0)
-       {
-               TelSsCallBarringInfo_t  cb_req = {0,};
-               char cbType[1];
-               char cba_fla[10];
-               char new_pwd[10];
-
-               TEST_DEBUG("####        Activate the Call Barring for Voice calls.      ####");
-
-               TEST_DEBUG("Enter Call Barring Flavor type(BAOC -2, BAIC-6) ");
-               TEST_DEBUG(" All Barring -[0] Out Going calls - [1] All outgoing calls [2] ");
-               TEST_DEBUG(" Outgoing Intl calls -[3] All ougoing intl calls except home[4] - Barring incoming [5]  All Incoming calls [6]");
-               TEST_DEBUG(" All incoming calls in roaming -[7] All incoming calls in Sim [8] ");
-
-               ss_fgets(cba_fla,5);
-               cb_req.Type = atoi(cba_fla);
-               TEST_DEBUG(" Enter Call Barring  Password - size minimum 4 bytes");
-               ss_fgets(new_pwd,5);
-               memcpy(&cb_req.szPassword,&new_pwd,4);
-               cb_req.Mode =  TAPI_SS_CALL_BAR_ACTIVATE;
-
-               TEST_DEBUG("Select the SS Call Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cbType,2);
-               cb_req.CallType = atoi(cbType);
-
-               TEST_DEBUG("CB type:[%d], SS CallType:[%d]", cb_req.Type, cb_req.CallType);
-
-               ret = tel_set_ss_barring(&cb_req,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-
-       if(strncmp(buf, "2c", 2) == 0)
-       {
-               TelSsCallBarringInfo_t  cb_req = {0,};
-               char cbType[1];
-
-               char cba_fla[10];
-               char new_pwd[10];
-               TEST_DEBUG("Enter Call Barring Flavor type(BAOC -2, BAIC-6) ");
-               TEST_DEBUG(" All Barring -[0] Out Going calls - [1] All outgoing calls [2] ");
-               TEST_DEBUG(" Outgoing Intl calls -[3] All ougoing intl calls except home[4] - Barring incoming [5]  All Incoming calls [6]");
-               TEST_DEBUG(" All incoming calls in roaming -[7] All incoming calls in Sim [8] ");
-
-               ss_fgets(cba_fla,5);
-               cb_req.Type = atoi(cba_fla);
-
-               TEST_DEBUG(" Enter Call Barring  Password - size minimum 4 bytes");
-               ss_fgets(new_pwd,5);
-               memcpy(&cb_req.szPassword,&new_pwd,4);
-
-               TEST_DEBUG("Select the SS Call Type ");
-               TEST_DEBUG(" voice-[0], data circuit sync-[6], all tele bearer-[7]");
-               ss_fgets(cbType,2);
-               cb_req.CallType = atoi(cbType);
-
-               cb_req.Mode =  TAPI_SS_CALL_BAR_DEACTIVATE;
-
-               TEST_DEBUG("CB type:[%d], SS CallType:[%d]", cb_req.Type, cb_req.CallType);
-
-               ret = tel_set_ss_barring(&cb_req,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret, request_id);
-       }
-
-
-       if(strncmp(buf, "3a", 2) == 0)
-       {
-               char flavor[1];
-               char cfType[1];
-
-               TelSsForwardInfo_t  cfReq ={0,};
-
-
-               TEST_DEBUG("### Interrogate the Status of Call forwarding .");
-               TEST_DEBUG("Select the Call Forwarding Flavor ");
-               TEST_DEBUG(" CF-Unconditional -[0]  CF-Busy [1]  CF-No Reply [2]  CF-Not reachable [3] CF -All forwarding[4] All Cond CF [5]  ");
-               ss_fgets(flavor,2);
-               cfReq.Condition = atoi(flavor);
-
-               TEST_DEBUG("Select the Call Forwarding Type ");
-               TEST_DEBUG("voice -[0] data -[3] fax-[4] all_tele and bearer -[5] ");
-               ss_fgets(cfType,2);
-               cfReq.Type = atoi(cfType);
-
-               TEST_DEBUG("CF Flavor:[%d], SS CF CallType:[%d]", cfReq.Condition, cfReq.Type);
-
-               ret = tel_get_ss_forward_status(cfReq.Type,  cfReq.Condition,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-
-       }
-       if(strncmp(buf, "3b", 2) == 0)
-       {
-
-               char cf_number[20];
-               unsigned char len;
-               char flavor[1];
-               char cfType[1];
-
-               TelSsForwardInfo_t  cfActReq ={0,};
-
-               TEST_DEBUG("#### Call Forwarding Activation #### ");
-               TEST_DEBUG("Enter the Call forwarding number ");
-               ss_fgets(cf_number,15);
-               len = strlen(cf_number);
-               TEST_DEBUG("Length of CF number :%d ",len);
-               memcpy(&(cfActReq.szPhoneNumber),cf_number,len);
-
-               TEST_DEBUG("Select the Call Forwarding Flavor ");
-               TEST_DEBUG(" CF-Unconditional -[0]  CF-Busy [1]  CF-No Reply [2]  CF-Not reachable [3] CF -All forwarding[4] All Cond CF [5] ");
-               ss_fgets(flavor,2);
-               cfActReq.Condition = atoi(flavor);
-               TEST_DEBUG("********** flavor=%x ",cfActReq.Condition);
-
-               TEST_DEBUG("Select the Call Forwarding Type ");
-               TEST_DEBUG("voice -[0] data -[3] fax-[4] all_tele and bearer -[5] ");
-               ss_fgets(cfType,2);
-               cfActReq.Type = atoi(cfType);
-
-               cfActReq.NoReplyConditionTimer = TAPI_SS_CF_NO_REPLY_TIME_10_SECS;
-               cfActReq.Mode=  TAPI_CALL_FORWARD_MODE_ENABLE_EV;
-
-               TEST_DEBUG("CF Flavor:[%d], SS CF CallType:[%d]", cfActReq.Condition, cfActReq.Type);
-
-               ret = tel_set_ss_forward(&cfActReq,&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-
-       }
-       if(strncmp(buf, "3c", 2) == 0)
-       {
-               char cf_number[20];
-               unsigned char len;
-               char flavor[1];
-               char cfType[1];
-               TelSsForwardInfo_t  cfActReq ={0,};
-
-               TEST_DEBUG("#### Call Forwarding DEActivation #### ");
-               TEST_DEBUG("Enter the Call forwarding number ");
-               ss_fgets(cf_number,15);
-               len = strlen(cf_number);
-               TEST_DEBUG("Length of CF number :%d ",len);
-               memcpy(&(cfActReq.szPhoneNumber),cf_number,len);
-
-               TEST_DEBUG("Select the Call Forwarding Flavor ");
-               TEST_DEBUG(" CF-Unconditional -[0]  CF-Busy [1]  CF-No Reply [2]  CF-Not reachable [3] CF -All forwarding[4] All Cond CF [5] ");
-
-               ss_fgets(flavor,2);
-               cfActReq.Condition = atoi(flavor);
-               TEST_DEBUG("********** flavor=%x ",cfActReq.Condition);
-
-               TEST_DEBUG("Select the Call Forwarding Type ");
-               TEST_DEBUG("voice -[0] data -[3] fax-[4] all_tele and bearer -[5] ");
-               ss_fgets(cfType,2);
-               cfActReq.Type = atoi(cfType);
-
-               cfActReq .NoReplyConditionTimer = TAPI_SS_CF_NO_REPLY_TIME_10_SECS;
-               cfActReq.Mode=  TAPI_CALL_FORWARD_MODE_DISABLE_EV;
-
-               TEST_DEBUG("CF Flavor:[%d], SS CF CallType:[%d]", cfActReq.Condition, cfActReq.Type);
-
-               ret = tel_set_ss_forward(&cfActReq,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-
-       }
-       if(strncmp(buf, "3d", 2) == 0)
-       {
-
-               char cf_number[20];
-               unsigned char len;
-               char flavor[1];
-               char cfType[1];
-
-               TelSsForwardInfo_t  cfActReq ={0,};
-
-               TEST_DEBUG("#### Call Forwarding Registration #### ");
-               TEST_DEBUG("Enter the Call forwarding number ");
-               ss_fgets(cf_number,15);
-               len = strlen(cf_number);
-               TEST_DEBUG("Length of CF number :%d ",len);
-               memcpy(&(cfActReq.szPhoneNumber),cf_number,len);
-
-               TEST_DEBUG("Select the Call Forwarding Flavor ");
-               TEST_DEBUG(" CF-Unconditional -[0]  CF-Busy [1]  CF-No Reply [2]  CF-Not reachable [3] CF -All forwarding[4] All Cond CF [5] ");
-               ss_fgets(flavor,2);
-
-               cfActReq.Condition = atoi(flavor);
-               TEST_DEBUG("********** flavor=%x ",cfActReq.Condition);
-
-
-               TEST_DEBUG("Select the Call Forwarding Type ");
-               TEST_DEBUG("voice -[0] data -[3] fax-[4] all_tele and bearer -[5] ");
-               ss_fgets(cfType,2);
-
-               cfActReq.Type = atoi(cfType);
-
-               cfActReq.NoReplyConditionTimer = TAPI_SS_CF_NO_REPLY_TIME_10_SECS;
-               cfActReq.Mode=  TAPI_CALL_FORWARD_MODE_REGISTRATION_EV;
-
-               TEST_DEBUG("CF Flavor:[%d], SS CF CallType:[%d]", cfActReq.Condition, cfActReq.Type);
-
-               ret = tel_set_ss_forward(&cfActReq,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-
-
-       }
-       if(strncmp(buf, "3e", 2) == 0)
-       {
-               char cf_number[20];
-               unsigned char len;
-               char flavor[1];
-               char cfType[1];
-               TelSsForwardInfo_t  cfActReq ={0,};
-
-               TEST_DEBUG("#### Call Forwarding Deregistration #### ");
-               TEST_DEBUG("Enter the Call forwarding number ");
-               ss_fgets(cf_number,15);
-               len = strlen(cf_number);
-               TEST_DEBUG("Length of CF number :%d ",len);
-               memcpy(&(cfActReq.szPhoneNumber),cf_number,len);
-
-               TEST_DEBUG("Select the Call Forwarding Flavor ");
-               TEST_DEBUG(" CF-Unconditional -[0]  CF-Busy [1]  CF-No Reply [2]  CF-Not reachable [3] CF -All CF [4] All Cond CF [5]  ");
-               ss_fgets(flavor,2);
-               cfActReq.Condition = atoi(flavor);
-               TEST_DEBUG("********** flavor=%x ",cfActReq.Condition);
-
-               TEST_DEBUG("Select the Call Forwarding Type ");
-               TEST_DEBUG("voice -[0] data -[3] fax-[4] all_tele and bearer -[5] ");
-               ss_fgets(cfType,2);
-
-               cfActReq.Type = atoi(cfType);
-
-               cfActReq.NoReplyConditionTimer = TAPI_SS_CF_NO_REPLY_TIME_10_SECS;
-               cfActReq.Mode=  TAPI_CALL_FORWARD_MODE_ERASURE_EV;
-
-               TEST_DEBUG("CF Flavor:[%d], SS CF CallType:[%d]", cfActReq.Condition, cfActReq.Type);
-
-               ret = tel_set_ss_forward(&cfActReq,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-
-
-       /* Change Call barring password */
-       if(strncmp(buf, "cbp",3) == 0)
-       {
-               char old_pwd[10];
-               char new_pwd[10];
-               char new_pwd_again[10];
-
-               memset(old_pwd, 0, 10);
-               memset(new_pwd, 0, 10);
-               memset(new_pwd_again, 0, 10);
-
-               TEST_DEBUG("####        Change the Call Barring Password        ####");
-               TEST_DEBUG(" Enter Call Barring Old Password - size minimum 4 bytes");
-               ss_fgets(old_pwd,5);
-
-               TEST_DEBUG(" Enter Call Barring New Password - size minimum 4 bytes");
-               ss_fgets(new_pwd,5);
-
-               TEST_DEBUG(" Enter Call Barring New Password Again - size minimum 4 bytes");
-               ss_fgets(new_pwd_again,5);
-
-               ret = tel_change_ss_barring_password(old_pwd, new_pwd, new_pwd_again,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-
-       /* CLI */
-       if(strncmp(buf, "cli", 3) == 0)
-       {
-               char cli_type[1];
-               TEST_DEBUG("####        Interrogate the Status of CLI Services (except CDIP) ####");
-               TEST_DEBUG(" CLIP -[1] CLIR -[2] COLP -[3] COLR-[4] CDIP-[5] CNAP -[6] ");
-               ss_fgets(cli_type,2);
-
-               TEST_DEBUG("CLI type:[%d]", atoi(cli_type));
-
-               ret = tel_get_ss_cli_status(atoi(cli_type),&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret,request_id);
-       }
-       /* USSD */
-       if(strncmp(buf, "ussd", 4) == 0)
-       {
-
-               char ussdString[TAPI_SS_USSD_DATA_SIZE_MAX];
-               int  ret;
-
-               memset(ussdString, 0, TAPI_SS_USSD_DATA_SIZE_MAX);
-               strcpy(ussdString , "*124#");
-
-               TEST_DEBUG("ussd string:[%s],ussd len:[%d]", ussdString, strlen(ussdString));
-               ret= tel_send_ss_ussd_request(ussdString,&request_id);
-               TEST_DEBUG(" API RETURN VAL:[%d]",ret);
-
-       }
-
-    /* Read AOC */
-    if(strncmp(buf, "raoc", 4) == 0)
-       {
-               char aoc_type[1];
-               TEST_DEBUG("Read AOC Information - Select AOC type");
-               TEST_DEBUG("ACM Accumulated Call meter -[1]  CCM -[2]  Cost Limit MAX ACM -[4]  Price per unit currency PUC [8]");
-
-               ss_fgets(aoc_type,2);
-               TEST_DEBUG("Aoc Type :%d",atoi(aoc_type));
-
-               ret = tel_get_ss_aoc_info(atoi(aoc_type),&request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret);
-       }
-
-       /* SIM OPEN */
-       if(strncmp(buf, "simopen", 7) == 0)
-       {
-               int i = 0;
-               TelSimStatusData_t SimOpenData = {0,};
-
-               TEST_DEBUG("********************************************");
-
-               TEST_DEBUG("open sim");
-       }
-
-       /* Enter PIN2 */
-       if(strncmp(buf, "pin2", 4) == 0)
-       {
-               /* nothing */
-       }
-
-       if(strncmp(buf, "5e", 2) == 0)
-       {
-               TEST_DEBUG("########### Setting Maximum Cost Limit -  MAX_ACM Value..############# ");
-               TelCallAocInfo_t pAocSetInfo = {0,};
-               char maxacm_val[10];
-               TEST_DEBUG("Enter the MAX ACM value ");
-               ss_fgets(maxacm_val,5);
-
-               pAocSetInfo.AocType = TAPI_SS_AOC_TYPE_MAXACM;
-
-               pAocSetInfo.MaxAcm =atoi(maxacm_val);
-
-               ret = tel_set_ss_aoc_info(&pAocSetInfo, &request_id);
-
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret, request_id);
-       }
-       if(strncmp(buf, "5f", 2) == 0)
-       {
-               TEST_DEBUG("########### Setting Price/Unit Currency - PPUC Value.############# ");
-               TelCallAocInfo_t *pAocSetInfo;
-               char ppu_curr[10];
-
-               TEST_DEBUG("Enter price per unit currency Characters ");
-               ss_fgets(ppu_curr,3);
-               pAocSetInfo = calloc(1,sizeof(TelCallAocInfo_t));
-
-               pAocSetInfo->AocType = TAPI_SS_AOC_TYPE_PUC;
-
-
-               pAocSetInfo->PPM = 0x02;
-
-               pAocSetInfo->CharTypeOfCurrency = 0x02;
-               pAocSetInfo->szCurrency[0] = ppu_curr[0];
-               pAocSetInfo->szCurrency[1] = ppu_curr[1];
-               pAocSetInfo->szCurrency[2] = ppu_curr[2];
-
-               TEST_DEBUG("Set  AOC Request");
-
-               ret = tel_set_ss_aoc_info(pAocSetInfo,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret, request_id);
-
-               free(pAocSetInfo);
-
-       }
-       if(strncmp(buf, "5g", 2) == 0)
-       {
-               TEST_DEBUG("################## Resetting Total Cost   MAX ACM..################ ");;
-               TelCallAocInfo_t  *pAocSetInfo;
-               pAocSetInfo = calloc(1,sizeof(TelCallAocInfo_t));
-
-               pAocSetInfo->AocType = TAPI_SS_AOC_TYPE_RESET;
-
-               ret = tel_set_ss_aoc_info(pAocSetInfo,&request_id);
-               TEST_DEBUG("Tapi return api_err value is [0x%x]  RequestID:[%d]", ret, request_id);
-
-               free(pAocSetInfo);
-       }
-
-       if(strncmp(buf, "quit", 4) == 0)
-       {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu");
-               return -1;
-       }
-
-       memset(buf, '\0', 256);
-       return 0;
-}
-
-
-/*****************************************************************/
-
-void ss_select_loop(void)
-{
-       int ret;
-       fd_set readfds;
-
-    while (1) {
-        FD_ZERO(&readfds);
-        FD_SET(0, &readfds);
-
-
-        ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-        if (ret) {
-
-           if (FD_ISSET(0, &readfds)) {
-                 if(ss_read_key_input()<0)
-                       break;
-            }
-        }
-    }
-}
-
-int ss_test_subscribe_tapi_events(void)
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfSSEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int SSEvtList[] =
-       {
-               TAPI_EVENT_SS_BARRING_CNF,   /**<0x0400,        This confirmation event is sent when Barring activation/deactivation is requested*/
-               TAPI_EVENT_SS_BARRING_CHANGEPASS_CNF,   /**<    This event is returned as Barring password change confirmation*/
-               TAPI_EVENT_SS_BARRING_QUERYSTATUS_CNF,   /**<   This event is returned  as Barring status query confirmation*/
-               TAPI_EVENT_SS_FORWARD_CNF,   /**<       This event is returned as confirmation for Forward Activation/Deactivation/Registration/Erasure */
-               TAPI_EVENT_SS_FORWARD_QUERYSTATUS_CNF,   /**<   This event is returned as confirmation for Forward Status query confirmation*/
-               TAPI_EVENT_SS_WAITING_CNF,   /**<       This event is returned as confirmation for Call waiting activation/deactivation*/
-               TAPI_EVENT_SS_WAITING_QUERYSTATUS_CNF,   /**<   This event is returned as Call waiting status query confirmation*/
-               TAPI_EVENT_SS_USSD_CNF,   /**<  This event is returned as USSD send confirmation*/
-               TAPI_EVENT_SS_USSD_CANCEL_CNF,  /**<    This event is returned as USSD cancel confirmation      >**/
-               TAPI_EVENT_SS_USSD_IND,   /**<  This is an unsolicited USSD indication*/
-               TAPI_EVENT_SS_CLI_QUERYSTATUS_CNF,   /**<       This event is indicated to the Application for CLI service interrogation*/
-               TAPI_EVENT_SS_REL_COMP_MSG_NOTIFY, /**< This event is indicated to the Application when tapi receives Release complete message notification for any SS transactions*/
-               TAPI_EVENT_SS_AOC_RSP,                          /**<This event is used to send the aoc information */
-               TAPI_EVENT_SS_SET_AOC_CNF,                      /**<This event is used to send the confirmation for setting aoc values */
-               TAPI_EVENT_SS_BARRING_TYPE_IND,         /**<This event is used to send the barring type while making an MO call */
-       };
-
-       iNumOfSSEvt = sizeof(SSEvtList)/sizeof(int);
-       TAPI_CALLOC(SS_subscription_id, iNumOfSSEvt, unsigned int)
-
-
-       for( i=0 ; i< iNumOfSSEvt; i++ )
-       {
-               api_err = tel_register_event(SSEvtList[i], &SS_subscription_id[i],(TelAppCallback)&ss_async_event_callback,NULL);
-               if(api_err != TAPI_API_SUCCESS)
-               {
-                       TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", SSEvtList[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-
-}
diff --git a/src/test_apps/tapi_svc_test.c b/src/test_apps/tapi_svc_test.c
deleted file mode 100644 (file)
index 89e288f..0000000
+++ /dev/null
@@ -1,555 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <pthread.h>
-#include <assert.h>
-#include <glib.h>
-#include <unistd.h>
-#include <string.h>
-
-#include "ITapiProductivity.h"
-#include "TapiCommon.h"
-#include "TapiEvent.h"
-
-#define TEST_DEBUG(frmt, args...) \
-{do { fprintf(stderr, "[SVC Test][%s:%04d] "frmt "\n", __func__,__LINE__, ##args); } while (FALSE); }
-
-
-#define SVC_TEST_KEY_END                               0x51
-#define SVC_TEST_KEY_SOFT_RIGHT                0x5C
-#define SVC_TEST_KEY_VALUE_0                   0x30
-#define SVC_TEST_KEY_VALUE_1                   0x31
-#define SVC_TEST_KEY_VALUE_2                   0x32
-#define SVC_TEST_KEY_VALUE_3                   0x33
-#define SVC_TEST_KEY_VALUE_4                   0x34
-#define SVC_TEST_KEY_VALUE_5                   0x35
-#define SVC_TEST_KEY_VALUE_6                   0x36
-#define SVC_TEST_KEY_VALUE_7                   0x37
-#define SVC_TEST_KEY_VALUE_8                   0x38
-#define SVC_TEST_KEY_VALUE_9                   0x39
-
-extern int EvtDeliveryHandle ;
-
-typedef struct
-{
-       int group;
-       int type;
-       int len;
-       void *dst;
-}data_t;
-
-static unsigned int *  SVC_subscription_id;
-
-int error_code;
-
-//static int  svc_async_event_callback  (tapi_svcmode_event_t event ,void * data)
-static int  svc_async_event_callback(TelTapiEvent_t    *event)
-{
-
-       switch(event->EventType)
-       {
-               case TAPI_EVENT_SVCMODE_START_NOTI:
-               {
-                       tapi_service_mode_t  svc_mode;
-                       memcpy(&svc_mode , event->pData , sizeof(tapi_service_mode_t));
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_START $$$$$$ ");
-                       TEST_DEBUG("svc_mode:[%d]", svc_mode);
-               }
-                       break;
-
-               case TAPI_EVENT_SVCMODE_END_NOTI:
-               {
-                       tapi_service_mode_end_t reset_mode;
-                       memcpy(&reset_mode , event->pData , sizeof(tapi_service_mode_end_t));
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_END $$$$$$ ");
-                       TEST_DEBUG("svc_mode:[%d], reset:[%d]", reset_mode.service_mode, reset_mode.reset);
-               }
-                       break;
-
-               case TAPI_EVENT_SVCMODE_CHANGE_NOTI:
-               {
-                       tapi_service_mode_t  svc_mode;
-                       memcpy(&svc_mode , event->pData , sizeof(tapi_service_mode_t));
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_CHANGE $$$$$$ ");
-                       TEST_DEBUG("svc_mode:[%d]", svc_mode);
-               }
-                       break;
-
-               case TAPI_EVENT_SVCMODE_SCREEN_CFG_NOTI:
-               {
-                       tapi_screen_config_t screen_config;
-                       memcpy(&screen_config , event->pData , sizeof(tapi_screen_config_t));
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_SCREEN_CFG $$$$$$ ");
-                       TEST_DEBUG("line num:[%d], keypad:[%d]", screen_config.line_number, screen_config.keypad);
-               }
-                       break;
-
-               case TAPI_EVENT_SVCMODE_DISP_SCREEN_NOTI:
-               {
-                       tapi_service_display_info_t display_screen;
-                       int num_of_lines, line_count;
-
-                       memcpy(&display_screen , event->pData , sizeof(tapi_service_display_info_t));
-
-                       num_of_lines = display_screen.num_of_lines;
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_DISP_SCREEN $$$$$$ ");
-                       TEST_DEBUG("num_of_lines :[%d]", display_screen.num_of_lines);
-
-                       line_count =0;
-
-                       TEST_DEBUG("===================================================");
-                       while(num_of_lines > 0)
-                       {
-                               /* LINE COUNT - LINE NUMBER - LINE REVRES - DISPLAY STRING */
-                               TEST_DEBUG("#[%d-%d-%d]:[%s]", line_count, display_screen.display[line_count].line, display_screen.display[line_count].reverse, display_screen.display[line_count].string);
-                               num_of_lines--;
-                               line_count++;
-                       }
-                       TEST_DEBUG("===================================================");
-
-               }
-                       break;
-
-               case    TAPI_EVENT_SVCMODE_DEVICE_TEST_NOTI:
-               {
-                       tapi_device_info_t  device_info;
-                       memcpy(&device_info , event->pData , sizeof(tapi_device_info_t));
-                       TEST_DEBUG("$$$$$$ TAPI_SVCMODE_EVENT_SVCMODE_DEVICE_TEST $$$$$$ ");
-                       TEST_DEBUG("dev id:[%d], dev status:[%d]",device_info.device_id, device_info.device_status);
-               }
-                       break;
-
-               default:
-                  break;
-       }
-
-    return TRUE;
-}
-
-int svc_read_key_input(void)
-{
-       int ret;
-       char buf[512];
-
-       static tapi_service_mode_t  svc_mode = -1; // staic. (for svc mode end)
-       tapi_test_mode_sub_t test_sub = -1;
-
-
-       memset(buf,0, sizeof(buf));
-
-       printf("\n########################################################\n");
-       printf("1. tel_start_svcmode (main)\n");
-       printf("2a. tel_send_svcmode_keycode (END)\n");
-       printf("2b. tel_send_svcmode_keycode (SOFT RIGHT)\n");
-       printf("2c. tel_send_svcmode_keycode (1~9)\n");
-       printf("3. tel_end_svcmode \n");
-       printf("4. tel_start_svcmode (monitor)\n");
-       printf("quit. QUIT\n");
-       printf("For escape : [2a] -> [3]\n");
-       printf("########################################################\n\n");
-
-       ret = read(0, buf, sizeof(buf));
-
-       if (ret < 0)
-       {
-               if (errno == EINTR)
-               perror("read(1)");
-               return -1;
-       }
-       else if (ret == 0) return ret;
-
-
-       if( memcmp(buf,"1",sizeof("1")-1) == 0 )
-       {
-               TEST_DEBUG("START SERVICE MODE (MAIN)");
-
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_ENTER;
-
-               tel_start_svcmode(svc_mode, test_sub);
-       }
-
-       if( memcmp(buf,"2a",sizeof("2a")-1) == 0 )
-       {
-               TEST_DEBUG("PROCESS KEY CODE (END)");
-
-               tel_send_svcmode_keycode(SVC_TEST_KEY_END);
-       }
-
-       if( memcmp(buf,"2b",sizeof("2b")-1) == 0 )
-       {
-               TEST_DEBUG("PROCESS KEY CODE (SOFT RIGHT)");
-
-               tel_send_svcmode_keycode(SVC_TEST_KEY_SOFT_RIGHT);
-       }
-
-       if( memcmp(buf,"2c",sizeof("2c")-1) == 0 )
-       {
-               int iKey = 0;
-               TEST_DEBUG("INPUT KEY NUMBER:");
-               scanf("%d", &iKey);
-               tel_send_svcmode_keycode(iKey+SVC_TEST_KEY_VALUE_0);
-               getchar();
-       }
-
-       if( memcmp(buf,"3",sizeof("3")-1) == 0 )
-       {
-               TEST_DEBUG("END SERVICE MODE");
-
-               tel_end_svcmode(svc_mode);
-       }
-
-       if( memcmp(buf,"4",sizeof("4")-1) == 0 )
-       {
-               TEST_DEBUG("START SERVICE MODE : MONITOR");
-
-               svc_mode        =       TAPI_SVC_MODE_MONITOR;
-               test_sub        =       TAPI_TESTMODE_ENTER;
-
-               tel_start_svcmode(svc_mode, test_sub);
-       }
-
-
-       if( memcmp(buf,"a",sizeof("a")-1) == 0 )
-       {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_SW_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_SW_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-       }
-
-        if( memcmp(buf,"b",sizeof("b")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_FTA_SW_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_FTA_SW_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"c",sizeof("c")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_FTA_HW_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_FTA_HW_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"d",sizeof("d")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_ALL_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_ALL_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-#if 1
-        if( memcmp(buf,"e",sizeof("e")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_BATTERY_INFO_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_BATTERY_INFO_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"f",sizeof("f")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub                =       TAPI_TESTMODE_CIPHERING_PROTECTION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_CIPHERING_PROTECTION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"g",sizeof("g")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_INTEGRITY_PROTECTION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_INTEGRITY_PROTECTION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"h",sizeof("h")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_IMEI_READ_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_IMEI_READ_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"i",sizeof("i")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_BLUETOOTH_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_BLUETOOTH_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"j",sizeof("j")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_VIBRATOR_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_VIBRATOR_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"k",sizeof("k")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub                =       TAPI_TESTMODE_MELODY_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_MELODY_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"l",sizeof("l")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_MP3_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_MP3_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"m",sizeof("m")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_FACTORY_RESET_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_FACTORY_RESET_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"n",sizeof("n")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_FACTORY_PRECONFIG_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_FACTORY_PRECONFIG_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"o",sizeof("o")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_TFS4_EXPLORE_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_TFS4_EXPLORE_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"p",sizeof("p")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_RTC_TIME_DISPLAY_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_RTC_TIME_DISPLAY_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"q",sizeof("q")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_RSC_FILE_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_RSC_FILE_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-       }
-
-        if( memcmp(buf,"r",sizeof("r")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_USB_DRIVER_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_USB_DRIVER_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"s",sizeof("s")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_USB_UART_DIAG_CONTROL_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_USB_UART_DIAG_CONTROL_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-
-        if( memcmp(buf,"t",sizeof("t")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_RRC_VERSION_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_RRC_VERSION_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"u",sizeof("u")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_GPSONE_SS_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_GPSONE_SS_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"v",sizeof("v")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_BAND_SEL_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_BAND_SEL_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"w",sizeof("w")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_GCF_TESTMODE_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_GCF_TESTMODE_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"x",sizeof("x")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_GSM_FACTORY_AUDIO_LB_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_GSM_FACTORY_AUDIO_LB_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"y",sizeof("y")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_FACTORY_VF_TEST_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_FACTORY_VF_TEST_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-        if( memcmp(buf,"z",sizeof("z")-1) == 0 )
-        {
-               svc_mode        =       TAPI_SVC_MODE_TEST_MANUAL;
-               test_sub        =       TAPI_TESTMODE_TOTAL_CALL_TIME_INFO_ENTER;
-
-               TEST_DEBUG("START SERVICE MODE: TAPI_TESTMODE_TOTAL_CALL_TIME_INFO_ENTER");
-
-               tel_start_svcmode(svc_mode, test_sub);
-        }
-#endif
-       if(strncmp(buf, "quit", 4) == 0)
-        {
-               TEST_DEBUG("Finished Testing this module, Going back to Main Menu\n");
-               return -1;
-        }
-
-    return 0;
-}
-
-
-void svc_select_loop(void)
-{
-    int ret;
-    fd_set readfds;
-
-    while (1)
-       {
-               FD_ZERO(&readfds);
-               FD_SET(0, &readfds);
-
-                ret = select(0 + 1, &readfds, NULL, NULL, NULL);
-               if (ret)
-                {
-                    if (FD_ISSET(0, &readfds))
-                        {
-                             if(svc_read_key_input()<0)
-                                       break;
-                       }
-               }
-        }
-}
-
-int svc_test_subscribe_tapi_events(void)
-{
-       int i = 0;
-       int ret_val = TRUE;
-       int iNumOfSVCEvt = 0;
-       TapiResult_t    api_err = TAPI_API_SUCCESS;
-
-
-       int SVCEvtList[] =
-       {
-        TAPI_EVENT_SVCMODE_START_NOTI,
-        TAPI_EVENT_SVCMODE_END_NOTI,
-        TAPI_EVENT_SVCMODE_CHANGE_NOTI,
-        TAPI_EVENT_SVCMODE_SCREEN_CFG_NOTI,
-        TAPI_EVENT_SVCMODE_DISP_SCREEN_NOTI,
-        TAPI_EVENT_SVCMODE_DEVICE_TEST_NOTI,
-
-       }; // TODO: event updated
-
-       iNumOfSVCEvt = sizeof(SVCEvtList)/sizeof(int);
-       SVC_subscription_id = (unsigned int *)calloc(iNumOfSVCEvt, sizeof(unsigned int));
-
-
-       for( i=0 ; i< iNumOfSVCEvt; i++ )
-       {
-               api_err = tel_register_event(SVCEvtList[i], &SVC_subscription_id[i],(TelAppCallback)&svc_async_event_callback,NULL);
-               if(api_err != TAPI_API_SUCCESS)
-               {
-                       TEST_DEBUG("isn't subscribed. event id is %d, api_err is %d\n", SVCEvtList[i],api_err);
-                       ret_val = FALSE;
-                       break;
-               }
-       }
-
-       return ret_val;
-}
diff --git a/src/test_apps/tapi_test_app.c b/src/test_apps/tapi_test_app.c
deleted file mode 100644 (file)
index 9cf3308..0000000
+++ /dev/null
@@ -1,383 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include <stdlib.h>
-#include <string.h>
-#include <sys/time.h>
-#include <pthread.h>     /* pthread functions and data structures */
-#include <signal.h>
-#include <stdio.h>
-#include <errno.h>
-#include <unistd.h>
-#include <glib.h>
-
-#include "tapi_test_utility.h"
-#include "TapiCommon.h"
-
-#define TAPI_TEST_MAX_LIST             10
-
-#define TAPI_TEST_COMMON_ID            1
-#define TAPI_TEST_PWR_ID               2
-#define TAPI_TEST_CALL_ID              3
-#define TAPI_TEST_SIM_ID               4
-#define TAPI_TEST_SS_ID                        5
-#define TAPI_TEST_SMS_ID               6
-#define TAPI_TEST_NW_ID                        7
-#define TAPI_TEST_SAT_ID               8
-#define TAPI_TEST_DATA_ID              9
-#define TAPI_TEST_MISC_ID              10
-#define TAPI_TEST_SVC_ID               11
-#define TAPI_TEST_GPS_ID               12
-#define TAPI_TEST_SOUND_ID             13
-#define TAPI_TEST_CDMA_DATA_ID 14
-#define TAPI_TEST_CFG_ID               15
-#define TAPI_TEST_QUIT_ID              0
-
-int EvtDeliveryHandle = 0;
-
-/******************************************************************************
-*******************************************************************************
-*
-*                                                      S U B  M O D U L E   A P I's
-*
-******************************************************************************
-******************************************************************************/
-/*     Add the Keyboard Loop Routines here...  */
-void power_select_loop(void);
-int call_test_init(void);
-void sim_select_loop(void);
-void ss_select_loop(void);
-void sms_select_loop();
-void nw_select_loop(int option);
-void gps_select_loop();
-void misc_select_loop(int option);
-void sat_select_loop(void);
-void data_select_loop(void);
-int svc_select_loop(void);
-void sound_select_loop(void);
-void cdma_data_select_loop(void);
-void cfg_select_loop(void);
-
-
-/*     Add the Subscribe routines here....     */
-int power_test_subscribe_tapi_events (void);
-int call_test_subscribe_tapi_events (void);
-int nw_test_subscribe_tapi_events(void);
-int gps_test_subscribe_tapi_events(void);
-int misc_test_subscribe_tapi_events(void);
-int cfg_test_subscribe_tapi_events(void);
-int data_test_subscribe_tapi_events (void);
-int sat_test_subscribe_tapi_events(void);
-int sim_test_subscribe_tapi_events (void);
-int svc_test_subscribe_tapi_events(void);
-int ss_test_subscribe_tapi_events(void);
-int sms_subscribe_tapi_events();
-void cdma_data_test_subscribe_tapi_events (void);
-int sound_test_subscribe_tapi_events(void);
-
-/******************************************************************************
-*******************************************************************************
-*
-*                                                      G L O B A L   V A R I A B L E S
-*
-******************************************************************************
-******************************************************************************/
-
-
-
-/******************************************************************************
-*******************************************************************************
-*
-*                                              T A P I   T E S T   A P I's
-*
-*
-******************************************************************************
-******************************************************************************/
-
-
-//1 GMain Loop Routine.
-
-
-
-/*     Wait in the GMain Loop  to receive notifications   */
-void  tapi_test_app_noti_loop(void)
-{
-       GMainLoop *mainloop;
-
-       mainloop = g_main_loop_new (NULL, FALSE);
-
-       TAPI_TEST_DEBUG("Entering GMain Loop to Receive Notifications....\n");
-
-       g_main_loop_run (mainloop);
-
-       TAPI_TEST_DEBUG("EXITING GMAIN LOOP\n");
-
-       g_main_loop_unref(mainloop);
-
-       tel_deinit();
-}
-
-
-
-
-//2 Call the sub module Key Event Loop sub routines on demand by the User.
-
-
-/*     Call the selected sub module routine..  */
-int tapi_test_app_process_choice(int sub_mod_id)
-{
-       int ret = 1;
-
-       switch(sub_mod_id)
-       {
-               case TAPI_TEST_COMMON_ID:
-               case TAPI_TEST_PWR_ID:
-                       TAPI_TEST_DEBUG("Loading Power Module Test Routines...\n");
-                       power_select_loop();
-                       break;
-               case TAPI_TEST_CALL_ID:
-                       TAPI_TEST_DEBUG("Loading Common/Power&Display/Call Module Test Routines...\n");
-                       call_test_init();
-                       TAPI_TEST_DEBUG(" sub-module testing done.. \n");
-                       break;
-               case TAPI_TEST_SIM_ID:
-                       TAPI_TEST_DEBUG("Loading SIM Module Test Routines...\n");
-                       sim_select_loop();
-                       TAPI_TEST_DEBUG(" SIM sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_SS_ID:
-                       TAPI_TEST_DEBUG("Loading SS Module Test Routines...\n");
-                       //ss_select_loop();
-                       TAPI_TEST_DEBUG(" SS sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_SMS_ID:
-                       TAPI_TEST_DEBUG("Loading SMS module test routines...\n");
-                       sms_select_loop();
-                       TAPI_TEST_DEBUG(" SMS sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_NW_ID:
-                       TAPI_TEST_DEBUG("Loading NW Module Test Routines...\n");
-                       nw_select_loop(TAPI_TEST_NW_ID);
-                       TAPI_TEST_DEBUG("NW sub-module testing done.. \n");
-                       break;
-#if 0
-               case TAPI_TEST_SAT_ID:
-                       TAPI_TEST_DEBUG("Loading SAT Module Test Routines...\n");
-                       sat_select_loop();
-                       TAPI_TEST_DEBUG("SAT sub-module testing done.. \n");
-                       break;
-#endif
-               case TAPI_TEST_DATA_ID:
-                       TAPI_TEST_DEBUG("Loading Data Module Test Routines...\n");
-                       data_select_loop();
-                       TAPI_TEST_DEBUG("Data sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_MISC_ID:
-                       TAPI_TEST_DEBUG("Loading MISC Module Test Routines...\n");
-                       misc_select_loop(TAPI_TEST_MISC_ID);
-                       TAPI_TEST_DEBUG("MISC sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_SVC_ID:
-                       TAPI_TEST_DEBUG("Loading SVC Module Test Routines...\n");
-                       svc_select_loop();
-                       TAPI_TEST_DEBUG("SVC sub-module testing done.. \n");
-                       break;
-
-               case TAPI_TEST_GPS_ID:
-                       TAPI_TEST_DEBUG("Loading GPS Module Test Routines...\n");
-                       gps_select_loop();
-                       TAPI_TEST_DEBUG("GPS sub-module testing done.. ");
-                       break;
-
-               case TAPI_TEST_SOUND_ID:
-                       TAPI_TEST_DEBUG("Loading Sound Module Test Routines...\n");
-                       sound_select_loop();
-                       TAPI_TEST_DEBUG("Sound sub-module testing done.. ");
-                       break;
-
-               case TAPI_TEST_CDMA_DATA_ID:
-                       TAPI_TEST_DEBUG("Loading CDMA Data Module Test Routines...\n");
-                       cdma_data_select_loop();
-                       TAPI_TEST_DEBUG("CDMA Data sub-module testing done.. ");
-                       break;
-
-               case TAPI_TEST_CFG_ID:
-                       TAPI_TEST_DEBUG("Loading CFG Module Test Routines...\n");
-                       TAPI_TEST_DEBUG("CFG sub-module testing done.. ");
-                       break;
-
-               case TAPI_TEST_QUIT_ID:
-                       TAPI_TEST_DEBUG("Quit option selected. Aborting the application execution");
-                       tel_deinit();
-                       exit(0);
-                       break;
-
-               default:
-                       TAPI_TEST_DEBUG("Oops!Invalid Sub Module Id Pressed. Try Again");
-                       ret = -1;
-                       break;
-
-       }
-
-
-       return ret;
-
-}
-
-
-//2 Display the Main Menu Options for the user
-
-
-void tapi_test_app_process_keyboard(void)
-{
-       int     choice = 0;
-       char buf[255];
-
-       while (1)
-       {
-               sleep(1);
-
-               choice = 0;
-
-               printf("\n\nMain Menu: \n\n");
-
-               printf("Avaliable Sub-Modules for API testing...\n");
-
-               printf("\n\n *********************************************************\n\n");
-
-               printf(" 1:\tCommon\n 2:\tPower & Display\n 3:\tCall\n 4:\tSIM\n 5:\tSS\n 6:\tSMS\n 7:\tNW\n 8:\tSAT\n 9:\tGPRS\n 10:\tMISC\n 11:\tSVC\n 12:\tGPS & NPS\n 13:\tSOUND\n 14:\tCDMA-DATA\n 15:\tCFG\n\n");
-
-               printf("\n **********************************************************\n\n");
-
-               printf("Enter the selected sub-module <ID> shown above or <0> to Quit \n");
-
-               memset(buf, 0, 255);
-               fgets(buf, 255, stdin);
-               choice = atoi(buf);
-
-               printf("You have selected %d\n", choice);
-
-               tapi_test_app_process_choice(choice);
-
-       }
-
-}
-
-
-
-
-
-//2  This function calls the subroutines of the sub modules which will subscribe for the
-//2 Notifications. Note that GMain Loop should not be created in the called sub-routines.
-
-
-
-/*     Initialize Notification Manager, Subscribe for Events and then Wait in GMain Loop       */
-void tapi_test_app_noti_thread(void)
-{
-       if(tel_init() == TAPI_API_SUCCESS)
-       {
-               TAPI_TEST_DEBUG("tel_init() succeeded");
-       }
-       else
-       {
-               TAPI_TEST_DEBUG("tel_init() failed");
-       }
-
-       power_test_subscribe_tapi_events ();
-
-       /*      Subscribe for Call, Common, Power & Display Events      */
-       call_test_subscribe_tapi_events();
-
-       nw_test_subscribe_tapi_events();
-
-       gps_test_subscribe_tapi_events();
-
-       misc_test_subscribe_tapi_events();
-
-       data_test_subscribe_tapi_events();
-
-       //sat_test_subscribe_tapi_events();
-
-       sim_test_subscribe_tapi_events();
-
-       svc_test_subscribe_tapi_events();
-
-//     ss_test_subscribe_tapi_events();
-
-       sms_subscribe_tapi_events();
-
-       sound_test_subscribe_tapi_events ();
-
-       tel_register_app_name("org.tizen.tel_test");
-
-       cdma_data_test_subscribe_tapi_events();
-
-       /*      Enter to GMain Loop     */
-       tapi_test_app_noti_loop();
-
-       tel_deinit();
-       fprintf(stderr,"tel_deinit success\n");
-
-}
-
-
-
-/*     Entry point for the Integrated Test Application...      */
-int main(void)
-{
-       pthread_t               p_thread;
-       int                     noti_thread_id;
-
-       /*      Step 1: Version Information */
-       TAPI_TEST_DEBUG("******* Integrated TAPI Test Application: Version 0.4  *****");
-       TAPI_TEST_DEBUG("******* Buid On: %s  %s  ********", __DATE__, __TIME__);
-
-       /*      Step 2: Create a thread for Notifications       */
-       noti_thread_id = pthread_create(&p_thread, NULL,(void *)& tapi_test_app_noti_thread, NULL);
-
-       if(noti_thread_id != 0)
-       {
-               TAPI_TEST_DEBUG( "Failed to create Noti Thread");
-               return -1;
-       }
-       else
-       {
-               TAPI_TEST_DEBUG( "Successfully Created Noti Thread");
-       }
-
-       /*      Step 3: Create and Process Loop for Key Events  */
-       tapi_test_app_process_keyboard();
-
-
-       /*      Main Thread shall wait for the worker (Noti) Thread     */
-       pthread_join(noti_thread_id, NULL);
-
-       return 0;
-
-}
-/*     EOF             */
-
diff --git a/src/test_apps/tapi_test_utility.h b/src/test_apps/tapi_test_utility.h
deleted file mode 100644 (file)
index 2dc9765..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * libslp-tapi
- *
- * Copyright (c) 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyeongchul Kim <kyeongchul.kim@samsung.com>
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _TAPI_TEST_UTILITY_H_
-#define _TAPI_TEST_UTILITY_H_
-
-
-#define AUTO_LOG(frmt, args...) { \
-       {do { fprintf(log_fd, "\n%s: " frmt "\n", __TIME__, ##args); } while (FALSE) ;} \
-       fflush(log_fd); }
-
-#define TAPI_TEST_DEBUG(frmt, args...) \
-       {do { fprintf(stderr, "[TAPI Test][%s:%04d] "frmt "\n", __func__, __LINE__, ##args); } while (FALSE) ;}
-
-#endif