⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ksd.h

📁 是一个手机功能的模拟程序
💻 H
📖 第 1 页 / 共 2 页
字号:
  SEQGRP_SUP_CLIR,
  SEQGRP_INV_CLIR,
  SEQGRP_SUP_CLIP,
  SEQGRP_INV_CLIP,
  SEQGRP_SUP_COLR,
  SEQGRP_INV_COLR,
  SEQGRP_SUP_COLP,
  SEQGRP_INV_COLP,
  SEQGRP_TTY_SERV,

  SEQGRP_CB,
  SEQGRP_CF,
  SEQGRP_CHLD,
  SEQGRP_CL,
  SEQGRP_CW,
  SEQGRP_DIAL,
  SEQGRP_DIAL_IDX,
  SEQGRP_PRSNT_IMEI,
  SEQGRP_PWD,
  SEQGRP_UBLK,
  SEQGRP_UNKNOWN,
  SEQGRP_USSD,
  SEQGRP_CCBS,
  SEQGRP_CTFR,

  SEQGRP_HOOK_OFF,
  SEQGRP_HOOK_ON,

  SEQGRP_MS_OFF,
  SEQGRP_MS_ON,

  SEQGRP_EM_MODE
}
T_KSD_SEQGRP;

typedef struct     /* parameter list of function cmh_ksdCB */
{
  UBYTE opCd;
  UBYTE ssCd;
  UBYTE bsCd;
  UBYTE *pwd;
} T_ACI_KSD_CB_PRM;

typedef struct     /* parameter list of function cmh_ksdCF */
{
  UBYTE opCd;
  UBYTE ssCd;
  UBYTE bsCd;
  UBYTE *num;
  UBYTE npi;
  UBYTE ton;
  UBYTE *sub;
  UBYTE tos;
  UBYTE oe;
  UBYTE time;
} T_ACI_KSD_CF_PRM;

typedef struct     /* parameter list of function cmh_ksdCL */
{
  UBYTE opCd;
  UBYTE ssCd;
} T_ACI_KSD_CL_PRM;

typedef struct     /* parameter list of function cmh_ksdCW */
{
  UBYTE opCd;
  UBYTE bsCd;
} T_ACI_KSD_CW_PRM;

typedef struct     /* parameter list of function cmh_ksdPWD */
{
  UBYTE ssCd;
  UBYTE *oldPwd;
  UBYTE *newPwd;
  UBYTE *newPwd2;
} T_ACI_KSD_PWD_PRM;

typedef struct     /* parameter list of function cmh_ksdUBLK */
{
  UBYTE ssCd;
  UBYTE *puk;
  UBYTE *pin;
} T_ACI_KSD_UBLK_PRM;

typedef struct     /* parameter list of function cmh_ksdUSSD */
{
  UBYTE* ussd;
} T_ACI_KSD_USSD_PRM;

typedef struct     /* parameter list of function cmh_ksdCCBS */
{
  UBYTE opCd;
  UBYTE idx;
} T_ACI_KSD_CCBS_PRM;

typedef struct     /* parameter list used for setting of */
{                  /* abbreviated dialing parameter      */
  CHAR* number;
  BYTE  index;
}
T_KSD_ABBR_DIAL;

typedef struct     /* parameter list of function sAT_PlusCBST */
{
  T_ACI_BS_SPEED speed;
  T_ACI_CBST_NAM name;
  T_ACI_CBST_CE  ce;
}
T_KSD_CBST;

typedef struct     /* parameter list for TTY/CTM service request */
{
  T_ACI_CTTY_REQ req;
}
T_KSD_CTTY;

typedef struct     /* parameter list of function sAT_PlusCHLD */
{
  T_ACI_CHLD_MOD mode;
  CHAR*          call;
}
T_KSD_CHLD;

typedef struct     /* parameter list of function sAT_PlusCTFR */
{
  CHAR      *number;
  T_ACI_TOA type;
  CHAR      *subaddr;
  T_ACI_TOS satype;
}
T_KSD_CTFR;

typedef struct     /* parameter list of function sAT_PlusCLCK */
{
  T_ACI_CLCK_FAC fac;
  T_ACI_CLCK_MOD mode;
  CHAR*          passwd;
  T_ACI_CLASS    class_type;
}
T_KSD_CLCK;

typedef struct     /* parameter list of function qAT_PlusCLCK */
{
  T_ACI_CLCK_FAC fac;
}
T_KSD_CLCK_QUERY;

typedef struct     /* parameter list of function sAT_PlusCLIP */
{
  T_ACA_CLIP_MOD mode;
}
T_KSD_CLIP;

typedef struct     /* parameter list of function sAT_PlusCLIR */
{
  T_ACI_CLIR_MOD mode;
}
T_KSD_CLIR;

typedef struct     /* parameter list of function sAT_PlusCOLP */
{
  T_ACA_COLP_MOD mode;
}
T_KSD_COLP;

typedef struct     /* parameter list of function sAT_PlusCOPS */
{
  T_ACI_COPS_MOD  mode;
  T_ACI_COPS_FRMT frmt;
  CHAR*           oper;
}
T_KSD_COPS;

typedef struct     /* parameter list of function sAT_PlusCRLP */
{
  SHORT iws;
  SHORT mws;
  SHORT t1;
  SHORT n2;
}
T_KSD_CRLP;

typedef struct     /* parameter list of function sAT_Dn */
{
  CHAR*             number;
  T_ACI_D_CLIR_OVRD clirOvrd;
  T_ACI_D_CUG_CTRL  cugCtrl;
  T_ACI_D_TOC       callType;
}
T_KSD_DIAL;

typedef struct     /* parameter list of function sAT_Dm */
{
  CHAR*             str;
  T_ACI_PB_STOR     mem;
  SHORT             index;
  T_ACI_D_CLIR_OVRD clirOvrd;
  T_ACI_D_CUG_CTRL  cugCtrl;
  T_ACI_D_TOC       callType;
}
T_KSD_DIAL_IDX;

typedef struct     /* parameter list of function sAT_PlusDS */
{
  T_ACI_DS_DIR  dir;
  T_ACI_DS_COMP comp;
  LONG          maxDict;
  SHORT         maxStr;
}
T_KSD_DS;

typedef struct     /* parameter list of the keypad indication */
{
  UBYTE keyCode;
  UBYTE keyStat;
}
T_KSD_KEYPAD_IND;

typedef union      /* decoded parameter for ACI function */
{
  T_ACI_KSD_CB_PRM   cb;
  T_ACI_KSD_CF_PRM   cf;
  T_ACI_KSD_CL_PRM   cl;
  T_ACI_KSD_CW_PRM   cw;
  T_ACI_KSD_PWD_PRM  pwd;
  T_ACI_KSD_UBLK_PRM ublk;
  T_ACI_KSD_USSD_PRM ussd;
  T_ACI_KSD_CCBS_PRM ccbs;

  CHAR               dtmf;
  T_KSD_ABBR_DIAL    abbrDial;
  T_KSD_CBST         cbst;
  T_KSD_CTTY         ctty;
  T_KSD_CHLD         chld;
  T_KSD_CTFR         ctfr;
  T_KSD_CLCK         clck;
  T_KSD_CLCK_QUERY   clck_query;
  T_KSD_CLIP         Clip; /* capital C in Clir, Clip and Colp is    */
  T_KSD_CLIR         Clir; /* necessary to avoid identifier conflicts*/
  T_KSD_COLP         Colp; /* (see constants in project MFW)         */
  T_KSD_COPS         cops;
  T_KSD_CRLP         crlp;
  T_KSD_DIAL         dial;
  T_KSD_DIAL_IDX     dialIdx;
  T_KSD_DS           ds;
  T_KSD_KEYPAD_IND   keypad;
}
T_KSD_SEQPARAM;

/*==== PROTOTYPES =================================================*/
/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_decode               |
+--------------------------------------------------------------------+

  PURPOSE : This function decodes the incoming keystroke sequence.

            <inSeq>:       key sequence, to be decoded
            <inCall>:      TRUE if MMI is within a call, otherwise
                           FALSE
            <outSeqGrp>:   sequence group
            <outRestSeq>:  rest key sequence, to be decoded by a
                           further call to this function
            <outSeqParam>: sequence parameter

            returns:       TRUE if decoding was successfull,
                           otherwise FALSE
*/
GLOBAL BOOL ksd_decode (CHAR*           inSeq,
                        BOOL            inCall,
                        T_KSD_SEQGRP*   outSeqGrp,
                        CHAR**          outRestSeq,
                        T_KSD_SEQPARAM* outSeqParam);

/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_getPwdHidden         |
+--------------------------------------------------------------------+

  PURPOSE : This function is used to hide passwords which are being
            entered during input of a keystroke sequence.

            <inSeq>:   key sequence to be manipulated
            <replace>: character which is used for replacing of
                       passwords
*/
GLOBAL void ksd_getPwdHidden (CHAR* inSeq,
                              CHAR  replace);

/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_isSscs               |
+--------------------------------------------------------------------+

  PURPOSE : This function return whether the given string is a
            supplementary service control string.

            <inSeq>:       key sequence

            returns:       TRUE if string is a supplementary service
                           control string, otherwise FALSE
*/
GLOBAL BOOL ksd_isSscs (CHAR* inSeq);

/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_isSATSscs            |
+--------------------------------------------------------------------+

  PURPOSE : This function return whether the given string is a
            supplementary service control string for SAT.

            <inSeq>:       key sequence

            returns:       TRUE if string is a supplementary service
                           control string for SAT, otherwise FALSE
*/
GLOBAL BOOL ksd_isSATSscs ( CHAR* inSeq );

/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_isUSSD               |
+--------------------------------------------------------------------+

  PURPOSE : This function checks whether key sequence is an
            unstructured SS command.

            <keySeq>: buffer containing the key sequence
*/
GLOBAL BOOL ksd_isUSSD (CHAR *keySeq);

/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_isFDNCheckSeq        |
+--------------------------------------------------------------------+

  PURPOSE : This function return whether the given string must check
            in FDN phonebook

            <inSeq>:       key sequence

            returns:       TRUE if string must check,
                           otherwise FALSE
*/
GLOBAL BOOL ksd_isFDNCheckSeq (CHAR* inSeq);


/*
+--------------------------------------------------------------------+
| PROJECT : GSM-PS (6147)         MODULE  : KSD                      |
| STATE   : code                  ROUTINE : ksd_isBCDForUSBand       |
+--------------------------------------------------------------------+

  PURPOSE : This function checks if US band is used and key sequence
            is "0" or "00", because these key sequences shall be send
            to network as normal dialing numbers when using US band.

            <inSeq>:       key sequence

            returns:       TRUE if US band is used and key sequence
                           is "0" or "00",
                           otherwise FALSE
*/
GLOBAL BOOL ksd_isBCDForUSBand (CHAR* inSeq);

/*==== EXPORT =====================================================*/

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -