头文件问题
1.为什么要用头文件,它里面可以包括那些内容? 2.为什么要自定义头文件?
下面是一个gprs模块的头文件,我现在知道的是它是自己定义的可是上面的2个问题还不是很清楚
#ifndef _MORDEM_H_
#define _MORDEM_H_
#define UartDataWait 10
#define HttpHeadWait 20
#define MAXBAUTSET 10
#define MAXBUFFERLEN 65536
#define ut_RspTimeWait 0xFFF0
#define ul_ConRspTimeWait 0x000FFFFF
#define PDU 0
#define TEXT 1
unsigned char Sim300_Init();
void TurnOnMordem();
unsigned char SetDnsOrIp( char par);
unsigned char SetDns( char * dnsstr);
unsigned char GetCommandRsp(void);
unsigned char ReadSetBaud( char *bautratestr);
unsigned char SetBautRate( char * bautratestr);
unsigned char SetBackShow( char par);
unsigned char SetSmsMode( char par);
void SetHost( char *strhost);
void SetPort( char *strport);
void SetUrl( char *strUrl);
void SetUa( char *strUa);
void SetAccept( char *strAccept);
void SetAcceptLanguage( char *strAccept_Language);
void SetAcceptEncoding( char *strAccept_Encoding);
void SetAcceptCharset( char *strAccept_Charset);
unsigned char ConnectSever( char *type, char *host, char *port);
unsigned char SendGprsData( char *strdata);
unsigned char HttpGet(void );
unsigned char InitMordem(void);
void TestGprs(void);
unsigned char TelCall(char *telnum);
unsigned char ATH();
unsigned char SendOneSMS(uchar ur_type,uchar *ur_phone,uchar *ur_content );
unsigned char SendSms();
unsigned char SearchNetStatus();
unsigned char CheckStatus();
unsigned char SendData(unsigned char *str);
unsigned char SendDataGprs(unsigned char *strdata);//通过gprs发送数据
void GprsInit();
#endif