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

📄 dtmux_common.h

📁 3G module test program
💻 H
字号:
/****************************************************************
*  COPYRIGHT DaTang Mobile Communications Equipment CO.,LTD         *
*****************************************************************/
/****************************************************************
 * FileName::   dtmux_common.h
 * version::     1.00
 * Purpose:     This header file which defined the interface message
 *                              type is provided for upper layer.
 * Authors:     xuyilin, xiaoyansong
 * Notes:        N/A
 ****************************************************************/
/*
 *      HISTORY OF CHANGES               
 ******************************************************************
 * xiaoyansong 2006-05-08 Enh00000779 update notes
 * xiaoyansong 2007-08-24 support Linux
 */
#ifndef DTMUX_COMMON_H
#define DTMUX_COMMON_H

/*************Interface const defination****************************/
#define MUX_PORT_NUM   200

/*************Interface struct defination****************************/
typedef struct _DTMUX_INIT_PARAM_
{
    int autoopen_device; //whether open device when dtmux init,0-not,1-auto open
    int baudrate;        //set device budrate
    int enable_test;    //MUX test service, heartbeat checking, 0-disable,1-enable
    int enable_tr;      //if all ports are closed, device will be closed after 3 seconds, 0-disable,1-enable
    int mode;           //0-MUX_BASIC_MODE, 1-MUX_ADVANCED_MODE
}DTMUX_INIT_PARAM;

/*************Interface port control defination****************************/
#define MUX_PPPD_START  1   //start pppd
#define MUX_PPPD_STOP  2    //stop pppd

#ifdef __cplusplus
extern "C" {
#endif

signed long int dtmux_init(const char *pathname, void *param);
signed long int dtmux_exit(void);
signed long int dtmux_port_open (unsigned char port);
signed long int dtmux_port_close (unsigned char port);
signed long int dtmux_port_read(unsigned char port, void *buf, unsigned long int count, unsigned long int timeout);
signed long int dtmux_port_write (unsigned char port, void * buf, unsigned long int count);
signed long int dtmux_port_control (unsigned char port, signed long int cmd, unsigned long param);

#ifdef __cplusplus
}
#endif 

#endif /*ifdef DTMUX_COMMON_H*/

/*----------- End of dtmux_common.h--------------------------------------*/

⌨️ 快捷键说明

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