TLx493D 3D Hall Sensor Generic Library  1.3
Generic library for the TLx493D 3D Hall sensor family
uart.h
Go to the documentation of this file.
1 /*
2 *****************************************************************************
3 * Copyright (C) 2019 Infineon Technologies AG. All rights reserved.
4 *
5 * Infineon Technologies AG (INFINEON) is supplying this file for use
6 * exclusively with Infineon's products. This file can be freely
7 * distributed within development tools and software supporting such microcontroller
8 * products.
9 *
10 * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED
11 * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
12 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE.
13 * INFINEON SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR DIRECT, INDIRECT, INCIDENTAL,
14 * ASPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
15 *
16 ******************************************************************************
17 */
18 
22 #ifndef SRC_PERIPHERALS_UART_UART_H_
23 #define SRC_PERIPHERALS_UART_UART_H_
24 
25 #include <stdint.h>
26 #include <stdbool.h>
27 
28 
29 
31 void UART_init(void);
32 
34 uint8_t UART_available(void);
35 
38 void UART_read(uint8_t *data, uint32_t count);
39 
41 uint8_t UART_read_byte(void);
42 
44 void UART_clear_rx_fifo(void);
45 
47 void UART_write(void *data, uint32_t count);
48 
49 #endif /* SRC_PERIPHERALS_UART_UART_H_ */
void UART_write(void *data, uint32_t count)
Write count bytes from the data array to UART.
Definition: uart.c:88
void UART_init(void)
Initialize the UART peripheral.
Definition: uart.c:29
uint8_t UART_read_byte(void)
Read last received data byte. Not blocking.
Definition: uart.c:76
void UART_clear_rx_fifo(void)
Discard all data from the receive FIFO buffer.
Definition: uart.c:106
void UART_read(uint8_t *data, uint32_t count)
Read count bytes to the data array. If not enough bytes available, will block until available...
Definition: uart.c:60
uint8_t UART_available(void)
Return number of bytes available for reading.
Definition: uart.c:82