You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
457 B

#ifndef UART2_H
#define UART2_H
#include "sys.h"
#include "stdarg.h"
#include "stdio.h"
#include "string.h"
#define USART2_REC_LEN 200 //<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֽ<EFBFBD><EFBFBD><EFBFBD> 200
extern u8 USART2_RX_BUF[USART2_REC_LEN]; //<EFBFBD><EFBFBD><EFBFBD>ջ<EFBFBD><EFBFBD><EFBFBD>,<EFBFBD><EFBFBD><EFBFBD><EFBFBD>USART_REC_LEN<EFBFBD><EFBFBD><EFBFBD>ֽ<EFBFBD><EFBFBD>ֽ<EFBFBD>Ϊ<EFBFBD><EFBFBD><EFBFBD>з<EFBFBD>
extern u16 USART2_RX_STA; //<EFBFBD><EFBFBD><EFBFBD><EFBFBD>״̬<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
void uart2_Init(u32 baudrate);
void uart2_test(void);
void u2_printf(char *fmt,...);
void uart2_send(char* fmt, int len);
#endif