78 uint8_t bits __attribute__((unused)),
uint8_t stop __attribute__((unused)),
uint8_t __attribute__((unused)) parity)
168 #ifndef UART0_VIC_SLOT
169 #define UART0_VIC_SLOT 5
174 #ifdef USE_UART0_RX_ONLY
175 #warning "USE_UART0_RX_ONLY is deprecated, please set USE_UART0_TX=FALSE instead"
176 #define USE_UART0_TX FALSE
178 #define USE_UART0_TX TRUE
182 #define USE_UART0_RX TRUE
185 void uart0_ISR(
void) __attribute__((naked));
198 void uart0_init(
void)
204 #if USE_UART0_RX && USE_UART0_TX
231 #ifndef UART1_VIC_SLOT
232 #define UART1_VIC_SLOT 6
237 #ifdef USE_UART1_RX_ONLY
238 #warning "USE_UART1_RX_ONLY is deprecated, please set USE_UART1_TX=FALSE instead"
239 #define USE_UART1_TX FALSE
241 #define USE_UART1_TX TRUE
245 #define USE_UART1_RX TRUE
248 void uart1_ISR(
void) __attribute__((naked));
261 void uart1_init(
void)
267 #if USE_UART1_RX && USE_UART0_TX
uint8_t tx_buf[UART_TX_BUFFER_SIZE]
Transmit buffer.
uint8_t rx_buf[UART_RX_BUFFER_SIZE]
Receive buffer.
arch independent UART (Universal Asynchronous Receiver/Transmitter) API
void uart_periph_set_baudrate(struct uart_periph *p, uint32_t baud)
Set baudrate.
volatile uint8_t tx_running
static void uart_ISR(struct uart_periph *p)
#define UART_RX_BUFFER_SIZE
void * reg_addr
UART Register.
static void uart_enable_interrupts(struct uart_periph *p)
static void uart_set_baudrate(struct uart_periph *p, uint32_t baud)
void uart_periph_init(struct uart_periph *p)
unsigned restoreIRQ(unsigned oldCPSR)
void uart_put_byte(struct uart_periph *p, long fd, uint8_t data)
Uart transmit implementation.
void uart_periph_set_bits_stop_parity(struct uart_periph *p, uint8_t bits, uint8_t stop, uint8_t parity)
Set parity and stop bits.
unsigned disableIRQ(void)
int baudrate
UART Baudrate.
#define UART_TX_BUFFER_SIZE
static void uart_disable_interrupts(struct uart_periph *p)