2 * Copyright 2012 Samsung Electronics Co., Ltd
\r
4 * Licensed under the Flora License, Version 1.0 (the "License");
\r
5 * you may not use this file except in compliance with the License.
\r
6 * You may obtain a copy of the License at
\r
8 * http://www.tizenopensource.org/license
\r
10 * Unless required by applicable law or agreed to in writing, software
\r
11 * distributed under the License is distributed on an "AS IS" BASIS,
\r
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
13 * See the License for the specific language governing permissions and
\r
14 * limitations under the License.
\r
17 #ifndef _CISS_CONVERTER_MMI_H_
\r
18 #define _CISS_CONVERTER_MMI_H_
\r
22 #endif /* __cplusplus */
\r
24 #include "ITapiSs.h"
\r
25 #include "ciss-common.h"
\r
28 #define MAX_BSG_LEN 2
\r
30 /* ALS_SUPPORT bug id: QCOM00001874 : entry increment by one for auxilliary telephony: Hari */
\r
31 #ifdef FEATURE_SAMSUNG_ALS
\r
32 #define MAX_BSG_ENTRY 47
\r
34 #define MAX_BSG_ENTRY 46
\r
38 ** Local Supplementary Service Codes (SC)
\r
41 #define CISS_ENG_SC_ALL ""
\r
42 #define CISS_ENG_SC_CF "002"
\r
43 #define CISS_ENG_SC_CFC "004"
\r
44 #define CISS_ENG_SC_CFU "21"
\r
45 #define CISS_ENG_SC_CFB "67"
\r
46 #define CISS_ENG_SC_CFNRY "61"
\r
47 #define CISS_ENG_SC_CFNRC "62"
\r
48 #define CISS_ENG_SC_CLIP "30"
\r
49 #define CISS_ENG_SC_CLIR "31"
\r
50 #define CISS_ENG_SC_COLP "76"
\r
51 #define CISS_ENG_SC_COLR "77"
\r
52 #define CISS_ENG_SC_CNAP "300"
\r
53 #define CISS_ENG_SC_CW "43"
\r
54 #define CISS_ENG_SC_B "330"
\r
55 #define CISS_ENG_SC_OB "333"
\r
56 #define CISS_ENG_SC_IB "353"
\r
57 #define CISS_ENG_SC_BAOC "33"
\r
58 #define CISS_ENG_SC_BOIC "331"
\r
59 #define CISS_ENG_SC_BOICEXHC "332"
\r
60 #define CISS_ENG_SC_BAIC "35"
\r
61 #define CISS_ENG_SC_BICROAM "351"
\r
64 ** Local Basic Service Codes
\r
67 #define CISS_ENG_BSG_ALL ""
\r
68 #define CISS_ENG_BSG_ALL_TS "10"
\r
69 #define CISS_ENG_BSG_TELEPHONY "11"
\r
70 /* ALS_SUPPORT : added MMI code for auxilliary telephony */
\r
71 #ifdef FEATURE_SAMSUNG_ALS
\r
72 #define CISS_ENG_BSG_AUX_TELEPHONY "89"
\r
74 #define CISS_ENG_BSG_ALL_DATA "12"
\r
75 #define CISS_ENG_BSG_FAX "13"
\r
76 #define CISS_ENG_BSG_SMS "16"
\r
77 #define CISS_ENG_BSG_ALL_TELE_EX_SMS "19"
\r
78 #define CISS_ENG_BSG_PLMN_TELE_ALL "50"
\r
79 #define CISS_ENG_BSG_PLMN_TELE_1 "51"
\r
80 #define CISS_ENG_BSG_PLMN_TELE_2 "51"
\r
81 #define CISS_ENG_BSG_PLMN_TELE_3 "53"
\r
82 #define CISS_ENG_BSG_PLMN_TELE_4 "54"
\r
83 #define CISS_ENG_BSG_PLMN_TELE_5 "55"
\r
84 #define CISS_ENG_BSG_PLMN_TELE_6 "56"
\r
85 #define CISS_ENG_BSG_PLMN_TELE_7 "57"
\r
86 #define CISS_ENG_BSG_PLMN_TELE_8 "58"
\r
87 #define CISS_ENG_BSG_PLMN_TELE_9 "59"
\r
88 #define CISS_ENG_BSG_PLMN_TELE_A "60"
\r
89 #define CISS_ENG_BSG_PLMN_TELE_B "61"
\r
90 #define CISS_ENG_BSG_PLMN_TELE_C "62"
\r
91 #define CISS_ENG_BSG_PLMN_TELE_D "63"
\r
92 #define CISS_ENG_BSG_PLMN_TELE_E "64"
\r
93 #define CISS_ENG_BSG_PLMN_TELE_F "65"
\r
95 #define CISS_ENG_BSG_ALL_BS "20"
\r
96 #define CISS_ENG_BSG_ALL_ASYNC "21"
\r
97 #define CISS_ENG_BSG_ALL_SYNC "22"
\r
98 #define CISS_ENG_BSG_ALL_DC_SYNC "24"
\r
99 #define CISS_ENG_BSG_ALL_DC_ASYNC "25"
\r
100 #define CISS_ENG_BSG_ALL_DED_PACKET "26"
\r
101 #define CISS_ENG_BSG_ALL_DED_PAD "27"
\r
102 #define CISS_ENG_BSG_12_KBIT "29"
\r
103 #define CISS_ENG_BSG_PLMN_BEAR_ALL "70"
\r
104 #define CISS_ENG_BSG_PLMN_BEAR_1 "71"
\r
105 #define CISS_ENG_BSG_PLMN_BEAR_2 "71"
\r
106 #define CISS_ENG_BSG_PLMN_BEAR_3 "73"
\r
107 #define CISS_ENG_BSG_PLMN_BEAR_4 "74"
\r
108 #define CISS_ENG_BSG_PLMN_BEAR_5 "75"
\r
109 #define CISS_ENG_BSG_PLMN_BEAR_6 "76"
\r
110 #define CISS_ENG_BSG_PLMN_BEAR_7 "77"
\r
111 #define CISS_ENG_BSG_PLMN_BEAR_8 "78"
\r
112 #define CISS_ENG_BSG_PLMN_BEAR_9 "79"
\r
113 #define CISS_ENG_BSG_PLMN_BEAR_A "80"
\r
114 #define CISS_ENG_BSG_PLMN_BEAR_B "81"
\r
115 #define CISS_ENG_BSG_PLMN_BEAR_C "82"
\r
116 #define CISS_ENG_BSG_PLMN_BEAR_D "83"
\r
117 #define CISS_ENG_BSG_PLMN_BEAR_E "84"
\r
118 #define CISS_ENG_BSG_PLMN_BEAR_F "85"
\r
129 char* local_sc; /* local value of Service Code */
\r
130 unsigned char tapi_flavor; /* TAPI flavor */
\r
131 unsigned char ss_type; /* barring, fwding, waiting, etc*/
\r
132 } sc_table_element_type;
\r
135 /* convert between local and network BSG values */
\r
137 char *local_bsg; /* local BSG value */
\r
138 char bsg_type; /* BSG type - bearer services, teleservices */
\r
139 TelSsTeleService_t tapi_bsg_code; /* TAPI BSG value */
\r
140 } bsg_table_element_type;
\r
142 int _ciss_convert_bsg_to_tapi_bsg(char *local_bsg, TelSsTeleService_t *tapi_bsg);
\r
143 int _ciss_convert_sc_to_tapi_flavor(char *sc, unsigned char *tapi_flavor, unsigned char *ss_type);
\r
145 /* temporarily added : need to correct when changes are finalized
\r
146 added for call divert type */
\r
147 int _ciss_get_tapi_forward_type(TelSsTeleService_t TelecommSvc, TelSsForwardType_t *pForwardType);
\r
149 /* temporarily added : need to correct when changes are finalized
\r
150 added for call barring type and call waiting */
\r
151 int _ciss_get_tapi_call_type(TelSsTeleService_t TelecommSvc, TelSsCallType_t *pCallType);
\r
154 * This function gets the ciss error from the tapi error.
\r
156 * @return This function returns TRUE on success, or false on failure.
\r
157 * @param[in] tapi_err the tapi error
\r
158 * @param[out] ciss_err the ciss error.
\r
160 int _ciss_get_error_from_tapi_error(ciss_err_t *ciss_err, TelSsCause_t tapi_err);
\r
163 * This function gets the tapi ussd repsonse type from ciss repsonse type.
\r
165 * @return This function returns TRUE on success, or false on failure.
\r
166 * @param[in] resp_type the ciss repsonse type
\r
167 * @param[out] p_tapi_resptype the tapi repsonse type.
\r
169 int _ciss_get_tapi_ussd_resp_type(ciss_ussd_response_type_t resp_type, TelSsUssdRespType_t *p_tapi_resptype);
\r
172 * This function gets the tapi ussd indication type from ciss indication type.
\r
174 * @return This function returns TRUE on success, or false on failure.
\r
175 * @param[in] ind_type the ciss indication type
\r
176 * @param[out] p_tapi_indtype the tapi indication type.
\r
178 int _ciss_get_tapi_ussd_ind_type(ciss_ussd_ind_type_t ind_type, TelSsUssdIndType_t *p_tapi_indtype);
\r
181 * This function gets the ciss sbse service from the tapi tele service
\r
183 * @return This function returns TRUE on success, or false on failure.
\r
184 * @param[in] tapi_tele_service the tapi tele service
\r
185 * @param[out] ciss_tele_service the ciss tele service
\r
187 int _ciss_get_telecomm_svc(TelSsTeleService_t in_teleservice, ciss_telecomm_svc_t *out_teleservice);
\r
190 * This function gets the ciss flavor type of call forward from the tapi flavor type
\r
192 * @return This function returns TRUE on success, or false on failure.
\r
193 * @param[in] tapi_flavor_type the tapi flavor type
\r
194 * @param[out] ciss_flavor_type the ciss flavor type
\r
196 int _ciss_get_forward_flavor_type(TelSsForwardWhen_t in_flavor, ciss_flavor_t *out_flavor);
\r
199 * This function gets the ciss flavor type of call barring from the tapi flavor type
\r
201 * @return This function returns TRUE on success, or false on failure.
\r
202 * @param[in] tapi_flavor_type the tapi flavor type
\r
203 * @param[out] ciss_flavor_type the ciss flavor type
\r
205 int _ciss_get_barring_flavor_type(TelSsCallBarType_t in_flavor, ciss_flavor_t *out_flavor);
\r
208 * This function gets the ciss status type from the tapi status type
\r
210 * @return This function returns TRUE on success, or false on failure.
\r
211 * @param[in] tapi_status_type the tapi status type.
\r
212 * @param[out] ciss_status_type the ciss status type.
\r
214 int _ciss_get_result_status_type(TelSsStatus_t in_status, ciss_status_t *out_status);
\r
217 * This function gets the ciss indication type from the tapi indication type
\r
219 * @return This function returns TRUE on success, or false on failure.
\r
220 * @param[in] tapi_indtype the tapi indication type.
\r
221 * @param[out] p_ind_type the ciss indication type.
\r
223 int _ciss_get_requested_tapi_ussd_ind_type(ciss_ussd_ind_type_t *p_ind_type, TelSsUssdIndType_t tapi_indtype);
\r
225 void _ciss_ui_mmi_get_service_name(ciss_service_t in_service, char *service_name);
\r
226 void _ciss_ui_mmi_get_flavor_name(ciss_flavor_t in_flavor, char *flavor_name);
\r
227 void _ciss_ui_mmi_get_bearer_name(ciss_service_t ss_type, ciss_telecomm_svc_t in_teleservice, char *teleservice_name);
\r
228 void _ciss_ui_mmi_get_result_status_type(ciss_service_t ss_type, ciss_status_t result_status, char *szResult);
\r
229 #endif /* _CISS_CONVERTER_MMI_H_ */
\r