13#include "target_constants.h"
35 bool transmit(
const char* txbuf,uint16_t size,uint32_t timeout = 10000);
37 bool receive(
char* rxbuf,uint16_t size,uint32_t timeout = 10000);
44 bool takeSemaphore(
bool txsem =
true,uint32_t blocktime = portMAX_DELAY);
virtual void endUartTransfer(UARTPort *port, bool transmit)
virtual void uartRcv(char &buf)
virtual void startUartTransfer(UARTPort *port, bool transmit)
UART_InitTypeDef & getConfig()
cpp_freertos::BinarySemaphore rxsemaphore
bool receive(char *rxbuf, uint16_t size, uint32_t timeout=10000)
UART_HandleTypeDef * getHuart()
bool giveSemaphore(bool txsem=true)
bool waitingForSingleBytes
bool takeSemaphore(bool txsem=true, uint32_t blocktime=portMAX_DELAY)
UART_HandleTypeDef & huart
volatile char uart_buf[UART_BUF_SIZE]
bool freePort(UARTDevice *device)
bool reservePort(UARTDevice *device)
bool receive_IT(char *rxbuf, uint16_t size)
bool transmit_IT(const char *txbuf, uint16_t size)
bool reconfigurePort(UART_InitTypeDef &config)
bool transmit(const char *txbuf, uint16_t size, uint32_t timeout=10000)
bool transmit_DMA(const char *txbuf, uint16_t size)
bool receive_DMA(char *rxbuf, uint16_t size)
UARTPort(UART_HandleTypeDef &huart)
cpp_freertos::BinarySemaphore semaphore
void uartTxComplete(UART_HandleTypeDef *huart)
void uartRxComplete(UART_HandleTypeDef *huart)