SATDefs.h
上传用户:lqx1163
上传日期:2014-08-13
资源大小:9183k
文件大小:11k
源码类别:

MTK

开发平台:

C/C++

  1. /*****************************************************************************
  2. *  Copyright Statement:
  3. *  --------------------
  4. *  This software is protected by Copyright and the information contained
  5. *  herein is confidential. The software may not be copied and the information
  6. *  contained herein may not be used or disclosed except with the written
  7. *  permission of MediaTek Inc. (C) 2005
  8. *
  9. *  BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
  10. *  THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE")
  11. *  RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
  12. *  AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
  13. *  EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
  14. *  MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
  15. *  NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
  16. *  SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
  17. *  SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
  18. *  THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
  19. *  NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
  20. *  SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
  21. *
  22. *  BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
  23. *  LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
  24. *  AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
  25. *  OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
  26. *  MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE. 
  27. *
  28. *  THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
  29. *  WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
  30. *  LAWS PRINCIPLES.  ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
  31. *  RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
  32. *  THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
  33. *
  34. *****************************************************************************/
  35. /*******************************************************************************
  36.  * Filename:
  37.  * ---------
  38.  * SATDefs.h
  39.  *
  40.  * Project:
  41.  * --------
  42.  *   MAUI
  43.  *
  44.  * Description:
  45.  * ------------
  46.  *   SIM application toolkit related functions
  47.  *
  48.  * Author:
  49.  * -------
  50.  * -------
  51.  *
  52. *==============================================================================
  53.  *             HISTORY
  54.  * Below this line, this part is controlled by PVCS VM. DO NOT MODIFY!! 
  55.  *------------------------------------------------------------------------------
  56.  * removed!
  57.  *
  58.  * removed!
  59.  * removed!
  60.  * removed!
  61.  *
  62.  * removed!
  63.  * removed!
  64.  * removed!
  65.  *
  66.  * removed!
  67.  * removed!
  68.  * removed!
  69.  *
  70.  *------------------------------------------------------------------------------
  71.  * Upper this line, this part is controlled by PVCS VM. DO NOT MODIFY!! 
  72.  *============================================================================== 
  73.  *******************************************************************************/
  74. /**
  75.  * Copyright Notice
  76.  * ?2002 - 2003, Pixtel Communications, Inc., 1489 43rd Ave. W.,
  77.  * Vancouver, B.C. V6M 4K8 Canada. All Rights Reserved.
  78.  *  (It is illegal to remove this copyright notice from this software or any
  79.  *  portion of it)
  80.  */
  81.  /**************************************************************
  82.    FILENAME : SATDefs.h
  83.    PURPOSE     : SAT application 
  84.    REMARKS     : nil
  85.    AUTHOR      : NEERAJ SHARMA
  86.    DATE     : Mar 24,03
  87. **************************************************************/
  88. #ifndef _PIXTEL_SATDEFS_H
  89. #define _PIXTEL_SATDEFS_H
  90. #ifdef MMI_ON_HARDWARE_P
  91. #include "custom_util.h"
  92. #define ALLOCATE_ITM(src_mod) allocate_ilm(src_mod)
  93. /* micha1229 */
  94. #define SEND_MSG(Message)      
  95.    {                              
  96.       Message->sap_id=INVALID_SAP;
  97.       msg_send_ext_queue(Message);
  98.    }
  99. #else /* MMI_ON_HARDWARE_P */ 
  100. #define ALLOCATE_ITM(src_mod) OslMalloc(sizeof(MYQUEUE))
  101. #define SEND_MSG(Message)      
  102.    {                              
  103.       OslMsgSendExtQueue(Message);
  104.       OslMfree(Message);          
  105.    }
  106. #endif /* MMI_ON_HARDWARE_P */ 
  107. /* micha0714 */
  108. #define SAT_MESSAGE_WAIT_TIMER_DURATION   15000 /* diamond, 2005/06/15 modified for DRAGONFLY_DEMO SCR #1011 */
  109. #define SAT_NO_RESPONSE_TIMER_DURATION 180000
  110. #define SAT_DISPLAY_TEXT_DELAY_DURATION   5000  /* diamond, 2005/07/11 duration for DISPLAY TEXT "clear after a delay" case */
  111. #define SAT_HELP_TIMER_DURATION     90000
  112. #define MAX_ICON_SUPPORT      15 /* diamond, 2006/05/22 Support 15 SAT icons */
  113. #define SAT_BASIC_IMAGE       0x11
  114. #define SAT_COLORR_IMAGE      0x21
  115. #define SAT_LANG_CHINESE      "zh"
  116. #define SAT_LANG_ENGLISH      "en"
  117. #define INPUT_TYPE_YES_NO     200
  118. #ifdef MMI_ON_HARDWARE_P
  119. #include "sim_common_enums.h"
  120. #define  SAT_FILE_IMG_IDX  FILE_IMG_IDX
  121. #else /* MMI_ON_HARDWARE_P */ 
  122. #define  SAT_FILE_IMG_IDX  20
  123. #endif /* MMI_ON_HARDWARE_P */ 
  124. typedef enum
  125. {
  126.     SAT_ICON_SELF_EX = 0x00,
  127.     SAT_ICON_NOT_SELF_EX
  128. } SAT_ICON_SELFEX_ATTR;
  129. typedef enum
  130. {
  131.     SCR_ID_SAT_MAINMENU = SAT_BASE + 1,
  132.     SCR_ID_SAT_SUBMENU = SAT_BASE + 1,
  133.     SCR_ID_SAT_DISPLAYTEXT = SAT_BASE + 1,
  134.     SCR_ID_SAT_GETINPUT = SAT_BASE + 1,
  135.     SCR_ID_SAT_GETINKEY = SAT_BASE + 1,
  136.     SCR_ID_SAT_CMCALLBACK = SAT_BASE + 1,
  137.     SCR_ID_SAT_SENDSMS = SAT_BASE + 1,
  138.     SCR_ID_SAT_SENDSS = SAT_BASE + 1,
  139.     SCR_ID_SAT_SENDUSSD = SAT_BASE + 1,
  140.     SCR_ID_SAT_PLAYTONE = SAT_BASE + 1,
  141.     SCR_ID_SAT_WAITSCREEN = SAT_BASE + 1,
  142.     SCR_ID_SAT_SEND_SMS_CONF = SAT_BASE + 1,
  143.     SCR_ID_SAT_LAUNCH_BROWSER_CONF = SAT_BASE + 1,
  144.     SCR_ID_SAT_SEND_DTMF_CONF = SAT_BASE + 1,
  145.     SCR_ID_SAT_SENDDTMF = SAT_BASE + 1,
  146.     SCR_ID_SAT_SEND_AT_CMD = SAT_BASE + 1,
  147.     SCR_ID_SAT_HISTORY = SAT_BASE + 1,
  148. #ifdef __SATCE__
  149.     SAT_OPEN_CHANNEL_CONF_SCREENID = SAT_BASE + 1,
  150.     SAT_OPEN_CHANNEL_SCREENID = SAT_BASE + 1,
  151.     SAT_CLOSE_CHANNEL_SCREENID = SAT_BASE + 1,
  152.     SAT_SEND_DATA_CONF_SCREENID = SAT_BASE + 1,
  153.     SAT_SEND_DATA_SCREENID = SAT_BASE + 1,
  154.     SAT_RECV_DATA_CONF_SCREENID = SAT_BASE + 1,
  155.     SAT_RECV_DATA_SCREENID = SAT_BASE + 1,
  156. #endif /* __SATCE__ */ 
  157.     SAT_SCR_INPUT_METHOD_AND_DONE,
  158.     /* diamond, 2005/12/12 Display SS reponse */
  159.     SCR_ID_SAT_DISPLAY_SS
  160. } SAT_SCREEN_ID;
  161. typedef enum
  162. {
  163.     SAT_CALL_DISCONNECT_BEFORE_CONNECT = 0x00,
  164.     SAT_CALL_DISCONNECT_AFTER_CONNECT
  165. } SAT_CALL_EXIT_CAUSE;
  166. typedef enum
  167. {
  168.     SAT_NONE_CMD = 0x00,
  169.     SAT_SELECT_ITEM_CMD,
  170.     SAT_DISPLAY_TEXT_CMD,
  171.     SAT_GET_INPUT,
  172.     SAT_GET_INKEY,
  173.     SAT_CALL_SETUP_CMD,
  174.     SAT_SEND_SMS_CMD,
  175.     SAT_PLAY_TONE_CMD,
  176.     SAT_LAUNCH_BROWSER_CMD,
  177.     SAT_SEND_DTMF_CMD,
  178.     SAT_SEND_SS_CMD,
  179.     SAT_SEND_USSD_CMD,
  180.     SAT_IMAGE_IDLE_CMD,
  181.     SAT_IMAGE_READLEN_CMD,
  182.     SAT_IMAGE_READINST_CMD,
  183.     SAT_IMAGE_READDATA_CMD
  184. } SAT_CMD_STATE;
  185. typedef enum
  186. {
  187.     SAT_WAIT_IMAGE_ID = SAT_BASE + 1,
  188.     SAT_TITLE_IMAGE_ID,
  189.     SAT_HELP_IMAGE_ID
  190. } SAT_IMAGE_LIST;
  191. typedef enum
  192. {
  193.     SAT_WAIT_STRING_ID = SAT_BASE + 1,
  194.     /* micha0702 */
  195.     SAT_GET_INPUT_LENGTH_NOT_ENOUGH,
  196.     SAT_ABORT_STRING_ID,
  197.     SAT_SETUP_CALL_CONF_STRING_ID,
  198.     SAT_SEND_SMS_CONF_STRING_ID,
  199.     SAT_SEND_SMS_STRING_ID,
  200.     SAT_SMS_ERROR_STRING_ID,
  201.     SAT_SMS_SUCCESS_STRING_ID,
  202.     SAT_SEND_SS_STRING_ID,
  203.     SAT_SS_ERROR_STRING_ID,
  204.     SAT_SS_SUCCESS_STRING_ID,
  205.     SAT_SEND_USSD_STRING_ID,
  206.     SAT_USSD_ERROR_STRING_ID,
  207.     SAT_USSD_SUCCESS_STRING_ID,
  208.     SAT_SEND_DTMF_CONF_STRING_ID,
  209.     SAT_SEND_DTMF_STRING_ID,
  210.     SAT_DTMF_ERROR_STRING_ID,
  211.     SAT_DTMF_SUCCESS_STRING_ID,
  212.     SAT_DTMF_ABORT_STRING_ID,
  213.     SAT_LAUNCH_BROWSER_CONF_STRING_ID,  /* diamond, 2005/01/11 LAUNCH BROWSER confirmation string */
  214.     SAT_NEXT_ACTION_REFRESH_STRING_ID,
  215.     SAT_NEXT_ACTION_MORE_TIME_STRING_ID,
  216.     SAT_NEXT_ACTION_POLL_INTERVAL_STRING_ID,
  217.     SAT_NEXT_ACTION_POLLING_OFF_STRING_ID,
  218.     SAT_NEXT_ACTION_SETUP_EVENT_LIST_STRING_ID,
  219.     SAT_NEXT_ACTION_SETUP_CALL_STRING_ID,
  220.     SAT_NEXT_ACTION_SEND_SS_STRING_ID,
  221.     SAT_NEXT_ACTION_SEND_USSD_STRING_ID,
  222.     SAT_NEXT_ACTION_SEND_SMS_STRING_ID,
  223.     SAT_NEXT_ACTION_SEND_DTMF_STRING_ID,
  224.     SAT_NEXT_ACTION_LAUNCH_BROWSER_STRING_ID,
  225.     SAT_NEXT_ACTION_PLAY_TONE_STRING_ID,
  226.     SAT_NEXT_ACTION_DISPLAY_TEXT_STRING_ID,
  227.     SAT_NEXT_ACTION_GET_INKEY_STRING_ID,
  228.     SAT_NEXT_ACTION_GET_INPUT_STRING_ID,
  229.     SAT_NEXT_ACTION_SELECT_ITEM_STRING_ID,
  230.     SAT_NEXT_ACTION_SETUP_MENU_STRING_ID,
  231.     SAT_NEXT_ACTION_PROVIDE_LOCAL_INFO_STRING_ID,
  232.     SAT_NEXT_ACTION_TIMER_MANAGEMENT_STRING_ID,
  233.     SAT_NEXT_ACTION_SETUP_IDLE_TEXT_STRING_ID,
  234.     SAT_NEXT_ACTION_PERFORM_CARD_APDU_STRING_ID,
  235.     SAT_NEXT_ACTION_POWER_ON_CARD_STRING_ID,
  236.     SAT_NEXT_ACTION_POWER_OFF_CARD_STRING_ID,
  237.     SAT_NEXT_ACTION_GET_READER_STATUS_STRING_ID,
  238.     SAT_NEXT_ACTION_RUN_AT_COMMAND_STRING_ID,
  239.     SAT_NEXT_ACTION_LANGUAGE_NOTIFICATION_STRING_ID,
  240.     SAT_NEXT_ACTION_OPEN_CHANNEL_STRING_ID,
  241.     SAT_NEXT_ACTION_CLOSE_CHANNEL_STRING_ID,
  242.     SAT_NEXT_ACTION_RECEIVE_DATA_STRING_ID,
  243.     SAT_NEXT_ACTION_SEND_DATA_STRING_ID,
  244.     SAT_NEXT_ACTION_GET_CHANNEL_STATUS_STRING_ID,
  245.     SAT_NEXT_ACTION_RESERVED_FOR_TIA_STRING_ID,
  246.     SAT_NEXT_ACTION_END_SESSION_STRING_ID,
  247. #ifdef __SATCE__
  248.     SAT_OPEN_CHANNEL_STRING_ID,
  249.     SAT_OPEN_CHANNEL_CONF_STRING_ID,
  250.     SAT_OPEN_CHANNEL_SUCCESS_STRING_ID,
  251.     SAT_OPEN_CHANNEL_FAIL_STRING_ID,
  252.     SAT_SEND_DATA_STRING_ID,
  253.     SAT_SEND_DATA_CONF_STRING_ID,
  254.     SAT_SEND_DATA_SUCCESS_STRING_ID,
  255.     SAT_SEND_DATA_FAIL_STRING_ID,
  256.     SAT_RECV_DATA_STRING_ID,
  257.     SAT_RECV_DATA_CONF_STRING_ID,
  258.     SAT_RECV_DATA_SUCCESS_STRING_ID,
  259.     SAT_RECV_DATA_FAIL_STRING_ID,
  260. #endif /* __SATCE__ */ 
  261.     SAT_PLAY_TONE_STRING_ID,
  262.     SAT_NUM_CHANGED_BY_SIM_STRING_ID,
  263.     SAT_HELP_STRING_ID
  264. } SAT_STRING_LIST;
  265. typedef enum
  266. {
  267.     SAT_NEXT_ACTION_NONE = 0x00,
  268.     SAT_NEXT_ACTION_REFRESH = 0x01,
  269.     SAT_NEXT_ACTION_MORE_TIME = 0x02,
  270.     SAT_NEXT_ACTION_POLL_INTERVAL = 0x03,
  271.     SAT_NEXT_ACTION_POLLING_OFF = 0x04,
  272.     SAT_NEXT_ACTION_SETUP_EVENT_LIST = 0x05,
  273.     SAT_NEXT_ACTION_SETUP_CALL = 0x10,
  274.     SAT_NEXT_ACTION_SEND_SS = 0x11,
  275.     SAT_NEXT_ACTION_SEND_USSD = 0x12,
  276.     SAT_NEXT_ACTION_SEND_SMS = 0x13,
  277.     SAT_NEXT_ACTION_SEND_DTMF = 0x14,
  278.     SAT_NEXT_ACTION_LAUNCH_BROWSER = 0x15,
  279.     SAT_NEXT_ACTION_PLAY_TONE = 0x20,
  280.     SAT_NEXT_ACTION_DISPLAY_TEXT = 0x21,
  281.     SAT_NEXT_ACTION_GET_INKEY = 0x22,
  282.     SAT_NEXT_ACTION_GET_INPUT = 0x23,
  283.     SAT_NEXT_ACTION_SELECT_ITEM = 0x24,
  284.     SAT_NEXT_ACTION_SETUP_MENU = 0x25,
  285.     SAT_NEXT_ACTION_PROVIDE_LOCAL_INFO = 0x26,
  286.     SAT_NEXT_ACTION_TIMER_MANAGEMENT = 0x27,
  287.     SAT_NEXT_ACTION_SETUP_IDLE_TEXT = 0x28,
  288.     SAT_NEXT_ACTION_PERFORM_CARD_APDU = 0x30,
  289.     SAT_NEXT_ACTION_POWER_ON_CARD = 0x31,
  290.     SAT_NEXT_ACTION_POWER_OFF_CARD = 0x32,
  291.     SAT_NEXT_ACTION_GET_READER_STATUS = 0x33,
  292.     SAT_NEXT_ACTION_RUN_AT_COMMAND = 0x34,
  293.     SAT_NEXT_ACTION_LANGUAGE_NOTIFICATION = 0x35,
  294.     SAT_NEXT_ACTION_OPEN_CHANNEL = 0x40,
  295.     SAT_NEXT_ACTION_CLOSE_CHANNEL = 0x41,
  296.     SAT_NEXT_ACTION_RECEIVE_DATA = 0x42,
  297.     SAT_NEXT_ACTION_SEND_DATA = 0x43,
  298.     SAT_NEXT_ACTION_GET_CHANNEL_STATUS = 0x44,
  299.     SAT_NEXT_ACTION_RESERVED_FOR_TIA = 0x60,
  300.     SAT_NEXT_ACTION_END_SESSION = 0x81
  301. } SAT_NEXT_ACTION_LIST;
  302. typedef enum
  303. {
  304.     SAT_PRI_NORMAL = 0,
  305.     SAT_PRI_HIGH = 1
  306. } SAT_DSPL_PRIORITY;
  307. typedef enum
  308. {
  309.     SAT_CLEAR_AFTER_DELAY = 0,
  310.     SAT_CLEAR_BY_USR = 1
  311. } SAT_CLEAR_TEXT;
  312. #endif /* _PIXTEL_SATDEFS_H */