#include <avr32/io.h>
#include "compiler.h"
#include "board.h"
#include "power_clocks_lib.h"
#include "gpio.h"
#include "usart.h"
Macros | |
USART Settings | |
#define | EXAMPLE_TARGET_PBACLK_FREQ_HZ FOSC0 |
#define | EXAMPLE_USART (&AVR32_USART1) |
#define | EXAMPLE_USART_RX_PIN AVR32_USART1_RXD_0_0_PIN |
#define | EXAMPLE_USART_RX_FUNCTION AVR32_USART1_RXD_0_0_FUNCTION |
#define | EXAMPLE_USART_TX_PIN AVR32_USART1_TXD_0_0_PIN |
#define | EXAMPLE_USART_TX_FUNCTION AVR32_USART1_TXD_0_0_FUNCTION |
#define | EXAMPLE_USART_CLOCK_MASK AVR32_USART1_CLK_PBA |
#define | EXAMPLE_PDCA_CLOCK_HSB AVR32_PDCA_CLK_HSB |
#define | EXAMPLE_PDCA_CLOCK_PB AVR32_PDCA_CLK_PBA |
Functions | |
int | main (void) |
This is an example demonstrating the USART RS232 TX and RX functionalities using the USART driver. More... | |
#define EXAMPLE_PDCA_CLOCK_HSB AVR32_PDCA_CLK_HSB |
Referenced by main().
#define EXAMPLE_PDCA_CLOCK_PB AVR32_PDCA_CLK_PBA |
Referenced by main().
#define EXAMPLE_USART (&AVR32_USART1) |
Referenced by main().
#define EXAMPLE_USART_CLOCK_MASK AVR32_USART1_CLK_PBA |
Referenced by main().
#define EXAMPLE_USART_RX_FUNCTION AVR32_USART1_RXD_0_0_FUNCTION |
Referenced by main().
#define EXAMPLE_USART_RX_PIN AVR32_USART1_RXD_0_0_PIN |
Referenced by main().
#define EXAMPLE_USART_TX_FUNCTION AVR32_USART1_TXD_0_0_FUNCTION |
Referenced by main().
#define EXAMPLE_USART_TX_PIN AVR32_USART1_TXD_0_0_PIN |
Referenced by main().
int main | ( | void | ) |
This is an example demonstrating the USART RS232 TX and RX functionalities using the USART driver.
References usart_options_t::baudrate, EXAMPLE_PDCA_CLOCK_HSB, EXAMPLE_PDCA_CLOCK_PB, EXAMPLE_TARGET_PBACLK_FREQ_HZ, EXAMPLE_USART, EXAMPLE_USART_CLOCK_MASK, EXAMPLE_USART_RX_FUNCTION, EXAMPLE_USART_RX_PIN, EXAMPLE_USART_TX_FUNCTION, EXAMPLE_USART_TX_PIN, FOSC0, gpio_enable_module(), OSC0_STARTUP, pcl_configure_clocks(), pcl_disable_module, PCL_OSC0, pcl_switch_to_osc(), SLEEP, USART_1_STOPBIT, USART_FAILURE, usart_get_echo_line(), usart_init_rs232(), USART_NO_PARITY, USART_NORMAL_CHMODE, usart_tx_empty(), and usart_write_line().