12345678910111213141516171819202122232425262728293031323334 |
- #ifndef __SERIAL_H_
- #define __SERIAL_H_
- typedef enum {INF = 0, DEBUG =1} TRACE_TYPE;
- #define COM_SEL_MCU 0
- #define COM_SEL_GPS 1
- #define COM_SEL_MODEM 2
- #define UART1_RX_BUFFER_SIZE 200
- #define UART2_RX_BUFFER_SIZE (512+30) //(IAP_RX_BUF+20)//+ZIPRECVU:1,256,xxx //512+30
- #define UART3_RX_BUFFER_SIZE 300
- extern unsigned short g_usUart1RecvLen;
- extern unsigned char RxBuffer1[UART1_RX_BUFFER_SIZE];
- void Uart1Init(void);
- void Uart1RxEnable(int en);
- void SlwTrace(TRACE_TYPE type,char *buf,char needEnd);
- void UART1RxTxISRHandler(void);
- extern unsigned short rx1_ct;
- void Uart2Init(void);
- void UART2RxTxISRHandler(void);
- void Uart2Send(unsigned char *txbuf,unsigned short len);
- void Uart2RecvProcess(void);
- extern unsigned short g_usUart3RecvLen;
- extern unsigned char RxBuffer3[UART3_RX_BUFFER_SIZE];
- void Uart3Init(void);
- void UART3RxTxISRHandler(void);
- void ComSelect(unsigned char sel);
- #endif
|