/** | |
* @file at_pdp_api.h | |
* @brief ÌṩÁËPDPµÄOPENCPUÏûÏ¢¶ÔÓ¦µÄ½á¹¹Ì嶨Òå | |
* | |
* Copyright (C) 2017 Sanechips Technology Co., Ltd. | |
* @author | |
* | |
* This program is free software; you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License version 2 as | |
* published by the Free Software Foundation. | |
* | |
*/ | |
#ifndef __AT_PDP_API_H__ | |
#define __AT_PDP_API_H__ | |
/******************************************************************************* | |
* Include header files * | |
******************************************************************************/ | |
/******************************************************************************* | |
* Macro definitions * | |
******************************************************************************/ | |
/******************************************************************************* | |
* Type definitions * | |
******************************************************************************/ | |
/** | |
* @brief pdp¼¤»îÐÅÏ¢½á¹¹Ì壬¶ÔÓ¦ÏûÏ¢MSG_CMD_PDP_ACT_REQ | |
* @param ip_type IPÀàÐÍ£¬È¡ÖµÎª×Ö·û´®£¬"IP","IPV6","IPV4V6"£¬×¢ÒâÈ«²¿ÊÇ´óд£¬±ØÐëÌîд | |
* @param apn ÍøÂç½ÓÈëµãÃû³Æ£¬±ØÐëÌîд | |
* @param username Óû§Ãû£¬ÐèÒª¼øÈ¨Ê±Ìîд | |
* @param password ÃÜÂ룬ÐèÒª¼øÈ¨Ê±Ìîд | |
* @param challenge ¼øÈ¨·½Ê½ÊÇCHAP_AUTHʱʹÓã¬ÐèÒª¼øÈ¨Ê±Ìîд | |
*/ | |
typedef struct { | |
char ip_type[10]; | |
char apn[100]; | |
int auth_type; | |
char username[65]; | |
char password[65]; | |
char challenge[50]; | |
//int cfgt;//ÿ°ü·¢Ë͵ȴýʱ¼ä | |
//int cfgp;//Êý¾Ý°ü±»·¢Ë͵ÄÃÅÏÞÖµ | |
} AT_PDP_ACT_REQ_INFO; | |
/*Íⲿģ¿é·¢ËÍMSG_CMD_PDP_ACT_REQ£¬½á¹¹ÌåAT_PDP_ACT_INFOת»»³ÉÄÚ²¿Ê¹ÓõĽṹÌåstruct pdp_act_req*/ | |
struct pdp_act_req | |
{ | |
/*char ip_type[10]; | |
char apn[70]; | |
int auth_type; | |
char username[65]; | |
char password[65]; | |
char challenge[50]; | |
//int at_fd; */ | |
//½«Íⲿpdp¼¤»îÏûÏ¢ÖÐЯ´øµÄÄÚÈÝ£¬×÷ΪͨÓÃpdp¼¤»îÐÅÏ¢£¬volte_param2ºÍppp_cid×÷Ϊat_ctlÄÚ²¿¶¨ÖƲÎÊýʹÓà | |
AT_PDP_ACT_REQ_INFO comm_info; | |
int ext_cid; //ÓÃÓÚÍⲿģ¿éÖ¸¶¨cid ppp²¦ºÅ£¬½øÐÐPDP_EXT×éÍø£¬¸Ãcid±ØÐëʱԤÁôcid | |
int volte_param1; | |
int volte_param2; | |
int volte_param3; | |
int ppp_cid;//½öÓÃÓÚppp²¦ºÅʱºòÖ¸¶¨cidʹÓã¬ÆäËûʱºò¾ùΪ0 | |
char default_flag; | |
}; | |
/** | |
* @brief pdpÈ¥¼¤»îÐÅÏ¢½á¹¹Ì壬¶ÔÓ¦ÏûÏ¢MSG_CMD_PDP_DEACT_REQ | |
* @param c_id pdpÉÏÏÂÎĵıêʶ | |
*/ | |
typedef struct { | |
int c_id; | |
} AT_PDP_DEACT_REQ_INFO; | |
/** | |
* @brief pdp¼¤»îÏìÓ¦ÏûÏ¢½á¹¹Ì壬¶ÔÓ¦ÏûÏ¢MSG_CMD_PDP_ACT_RSP | |
* @param result ½á¹ûÂë AT_RSP_OK/AT_RSP_ERR | |
* @param cid pdpÉÏÏÂÎĵıêʶ | |
* @param errcode Èç¹ûpdp¼¤»îʧ°Ü£¬·µ»Ø´íÎóÂë | |
*/ | |
typedef struct { | |
int result; | |
int cid; | |
int errcode; | |
} AT_PDP_ACT_RSP_INFO; | |
/** | |
* @brief pdpÈ¥¼¤»îÏìÓ¦ÏûÏ¢½á¹¹Ì壬¶ÔÓ¦ÏûÏ¢MSG_CMD_PDP_DEACT_RSP | |
* @param result ½á¹ûÂë AT_RSP_OK/AT_RSP_ERR | |
*/ | |
typedef struct { | |
int result; | |
} AT_PDP_DEACT_RSP_INFO; | |
#endif |