This commit is contained in:
Attila Body 2020-02-10 15:06:45 +01:00
parent 90d89c7fbe
commit 49383b1b32
68 changed files with 3385 additions and 610 deletions

View file

@ -0,0 +1,27 @@
/*
* UartBase.h
*
* Created on: Feb 4, 2020
* Author: abody
*/
#ifndef F4LL_CPP_UARTBASE_H_
#define F4LL_CPP_UARTBASE_H_
#include <platform/usart_ll.h>
#include <f4ll_cpp/dmahelper.h>
class UartBase
{
public:
UartBase() = delete;
protected:
UartBase(USART_TypeDef *uart, DMA_TypeDef *dma, uint32_t stream_rx, uint32_t stream_tx);
void SetupTransmit(void *buffer, uint16_t length);
void SetupReceive(void *buffer, uint16_t length);
USART_TypeDef *m_uart;
DmaHelper m_rxDma;
DmaHelper m_txDma;
};
#endif /* F4LL_CPP_UARTBASE_H_ */