/* Configure board USART communication with PC or other terminal.  */
static void configure_usart(void)
/* Configure board USART communication with PC or other terminal.  */
static void configure_usart(void)
{
	const sam_usart_opt_t usart_console_settings = {
		BOARD_USART_BAUDRATE,
		US_MR_CHRL_8_BIT,
		US_MR_PAR_NO,
		US_MR_NBSTOP_1_BIT,
		US_MR_CHMODE_NORMAL,
		BOARD_USART_IRDA_FILTER
	};
	sysclk_enable_peripheral_clock(BOARD_ID_USART);
	usart_init_irda(BOARD_USART, &usart_console_settings, sysclk_get_peripheral_hz());
	usart_disable_interrupt(BOARD_USART, ALL_INTERRUPT_MASK);
	usart_enable_tx(BOARD_USART);
	usart_enable_rx(BOARD_USART);
	NVIC_EnableIRQ(USART_IRQn);
}