uart.h
来自「ucos on lpc213x ,and a sample for the ar」· C头文件 代码 · 共 47 行
H
47 行
//--------------------file begin------------------------------------------------------------------------
// this file is declare the UART functions
#ifndef __UART__
#define __UART__
#include "config.h"
#define UART_BPS_1 115200
#define UART_BPS_2 9600
//--------------------------------------UART0-----------------------------------------------------
// declare UART0 functions
void UART0_Init (void);
uint8 UART0_GetByte (void);
void UART0_GetStr (uint8 *s, uint32 n);
void UART0_SendByte (uint8 dat);
void UART0_SendStr (char *str);
//--------------------------------------UART0-----------------------------------------------------
//--------------------------------------UART1-----------------------------------------------------
// declare UART1 functions
void UART1_Init (void);
uint8 UART1_GetByte (void);
void UART1_GetStr (uint8 *s, uint32 n);
void UART1_SendByte (uint8 dat);
void UART1_SendStr (char *str);
//--------------------------------------UART1-----------------------------------------------------
//--------------------------------------UART2-----------------------------------------------------
// declare UART2 functions ;because use the GPIO mapped
void UART2_Init (void);
uint8 UART2_GetByte (void);
void UART2_GetStr (uint8 *s, uint32 n);
void UART2_SendByte (uint8 dat);
void UART2_SendStr (char *str);
//--------------------------------------UART2-----------------------------------------------------
#endif
//--------------------file end------------------------------------------------------------------------
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?