15 lines
309 B
C
15 lines
309 B
C
#ifndef DRIVER_UART_H
|
|
#define DRIVER_UART_H
|
|
|
|
#include "stm32f10x.h"
|
|
|
|
typedef struct {
|
|
USART_TypeDef *usart;
|
|
uint32_t baudrate;
|
|
} MyUART_Struct_TypeDef;
|
|
|
|
void MyUart_Init(USART_TypeDef config);
|
|
void MyUart_SendByte(USART_TypeDef *usart, uint8_t data);
|
|
uint8_t MyUart_ReceiveByte(USART_TypeDef *usart);
|
|
|
|
#endif
|