mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-12-28 07:51:19 +01:00
board/arduino-due: added missing UART defines
- added port defines to periph_conf.h - added feature to Makefile.features
This commit is contained in:
parent
3c9c95f7b1
commit
3b193b99b5
@ -1 +1 @@
|
||||
FEATURES_PROVIDED += periph_gpio periph_spi periph_random
|
||||
FEATURES_PROVIDED += periph_uart periph_gpio periph_spi periph_random
|
||||
|
||||
@ -60,15 +60,17 @@ extern "C" {
|
||||
* @name UART configuration
|
||||
* @{
|
||||
*/
|
||||
#define UART_NUMOF (1U)
|
||||
#define UART_NUMOF (4U)
|
||||
#define UART_0_EN 1
|
||||
#define UART_1_EN 0
|
||||
#define UART_2_EN 0
|
||||
#define UART_3_EN 0
|
||||
#define UART_1_EN 1
|
||||
#define UART_2_EN 1
|
||||
#define UART_3_EN 1
|
||||
#define UART_IRQ_PRIO 1
|
||||
|
||||
/* UART 0 device configuration */
|
||||
#define UART_0_DEV UART
|
||||
#define UART_0_CLKEN() (PMC->PMC_PCER0 |= (1 << ID_UART))
|
||||
#define UART_0_CLKDIS() (PMC->PMC_PCER0 &= ~(1 << ID_UART))
|
||||
#define UART_0_IRQ UART_IRQn
|
||||
#define UART_0_ISR isr_uart
|
||||
/* UART 0 pin configuration */
|
||||
@ -76,12 +78,34 @@ extern "C" {
|
||||
#define UART_0_PINS (PIO_PA8 | PIO_PA9)
|
||||
|
||||
/* UART 1 device configuration */
|
||||
#define UART_1_DEV
|
||||
#define UART_1_IRQ
|
||||
#define UART_1_ISR
|
||||
#define UART_1_DEV USART0
|
||||
#define UART_1_CLKEN() (PMC->PMC_PCER0 |= (1 << ID_USART0))
|
||||
#define UART_1_CLKDIS() (PMC->PMC_PCER0 &= ~(1 << ID_USART0))
|
||||
#define UART_1_IRQ USART0_IRQn
|
||||
#define UART_1_ISR isr_usart0
|
||||
/* UART 1 pin configuration */
|
||||
#define UART_1_PORT
|
||||
#define UART_1_PINS
|
||||
#define UART_1_PORT PIOA
|
||||
#define UART_1_PINS (PIO_PA10 | PIO_PA11)
|
||||
|
||||
/* UART 1 device configuration */
|
||||
#define UART_2_DEV USART1
|
||||
#define UART_2_CLKEN() (PMC->PMC_PCER0 |= (1 << ID_USART1))
|
||||
#define UART_2_CLKDIS() (PMC->PMC_PCER0 &= ~(1 << ID_USART1))
|
||||
#define UART_2_IRQ USART1_IRQn
|
||||
#define UART_2_ISR isr_usart1
|
||||
/* UART 1 pin configuration */
|
||||
#define UART_2_PORT PIOA
|
||||
#define UART_2_PINS (PIO_PA12 | PIO_PA13)
|
||||
|
||||
/* UART 1 device configuration */
|
||||
#define UART_3_DEV USART3
|
||||
#define UART_3_CLKEN() (PMC->PMC_PCER0 |= (1 << ID_USART3))
|
||||
#define UART_3_CLKDIS() (PMC->PMC_PCER0 &= ~(1 << ID_USART3))
|
||||
#define UART_3_IRQ USART3_IRQn
|
||||
#define UART_3_ISR isr_usart3
|
||||
/* UART 1 pin configuration */
|
||||
#define UART_3_PORT PIOD
|
||||
#define UART_3_PINS (PIO_PD4 | PIO_PD5)
|
||||
/** @} */
|
||||
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user