#include <aversive.h>
#include <aversive/list.h>
#include <uart.h>
#include <uart_defs.h>
#include <uart_private.h>
Go to the source code of this file.
Functions | |
void | uart_send_next_char (uint8_t num) |
void | uart_init (void) |
Variables | |
struct cirbuf | g_tx_fifo [UART_HW_NUM] |
struct cirbuf | g_rx_fifo [UART_HW_NUM] |
event * | rx_event [UART_HW_NUM] |
event * | tx_event [UART_HW_NUM] |
struct regs | uart_regs [UART_HW_NUM] |
Definition in file uart.c.
void uart_init | ( | void | ) |
Initialisation function. This function puts the registers of the microcontroler in a correct state in order to use the uart. It uses the configuration file <uart_config.h> ; this function is equivalent to call uartX_setconf(NULL) for each uart.
Definition at line 239 of file uart.c.
Referenced by main().
void uart_send_next_char | ( | uint8_t | num | ) |
This is the interruption function which occurs when there is a new unread data in the reception buffer. transmit next character of fifo if any, and call the event function. This function is executed with intr locked.
Definition at line 171 of file uart.c.
References cbi, cirbuf_del_buf_tail(), cirbuf_del_tail(), cirbuf_get_buf_tail(), CIRBUF_GET_LEN, cirbuf_get_tail(), CIRBUF_IS_EMPTY, parse_doc::elt, g_tx_fifo, sbi, uart_getconf_nbits(), regs::ucsrb, and UDRIE.
Referenced by uart_send(), and uart_send_9bits().
The reception fifo of uart
Definition at line 32 of file uart.c.
Referenced by uart_9bits_recv_nowait(), uart_recv_nowait(), and uart_setconf().
The emission fifo of uart
Definition at line 31 of file uart.c.
Referenced by uart_send(), uart_send_9bits(), uart_send_9bits_nowait(), uart_send_next_char(), uart_send_nowait(), and uart_setconf().
Definition at line 35 of file uart.c.
Referenced by mf2_client_register_rx_event(), mf2_server_register_rx_event(), mf2_server_timer_cb(), SIGNAL(), and uart_register_rx_event().
Definition at line 36 of file uart.c.
Referenced by mf2_client_register_tx_event(), mf2_server_register_tx_event(), SIGNAL(), and uart_register_tx_event().
Definition at line 38 of file uart.c.
Referenced by uart_getconf(), uart_getconf_nbits(), uart_send(), uart_send_9bits(), uart_send_9bits_nowait(), uart_send_nowait(), and uart_setconf().