mirror of
https://github.com/apache/nuttx.git
synced 2026-06-07 01:05:54 +08:00
EFM32: Add configuration option to use USARTs as SPI
This commit is contained in:
@@ -103,7 +103,7 @@ ifneq ($(CONFIG_ARCH_IDLE_CUSTOM),y)
|
||||
CHIP_CSRCS += efm32_idle.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_EFM32_USART),y)
|
||||
ifeq ($(CONFIG_EFM32_USART_ISUART),y)
|
||||
CHIP_CSRCS += efm32_serial.c
|
||||
else
|
||||
ifeq ($(CONFIG_EFM32_UART),y)
|
||||
|
||||
@@ -66,10 +66,12 @@
|
||||
# undef CONFIG_EFM32_LEUART1
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_EFM32_USART
|
||||
# undef CONFIG_EFM32_USART0
|
||||
# undef CONFIG_EFM32_USART1
|
||||
# undef CONFIG_EFM32_USART2
|
||||
/* Is there a UART device? Or an SPI device? */
|
||||
|
||||
#ifndef CONFIG_EFM32_USART_ISUART
|
||||
# undef CONFIG_EFM32_USART0_ISUART
|
||||
# undef CONFIG_EFM32_USART1_ISUART
|
||||
# undef CONFIG_EFM32_USART2_ISUART
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_EFM32_UART
|
||||
@@ -77,13 +79,6 @@
|
||||
# undef CONFIG_EFM32_UART1
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_EFM32_LEUART
|
||||
# undef CONFIG_EFM32_LEUART0
|
||||
# undef CONFIG_EFM32_LEUART1
|
||||
#endif
|
||||
|
||||
/* Is there a UART device? Or an SPI device? */
|
||||
|
||||
#ifndef CONFIG_EFM32_USART0
|
||||
# undef CONFIG_EFM32_USART0_ISUART
|
||||
# undef CONFIG_EFM32_USART0_ISSPI
|
||||
@@ -117,6 +112,11 @@
|
||||
|
||||
/* Is there an LEUART device? */
|
||||
|
||||
#ifndef CONFIG_EFM32_LEUART
|
||||
# undef CONFIG_EFM32_LEUART0
|
||||
# undef CONFIG_EFM32_LEUART1
|
||||
#endif
|
||||
|
||||
#undef HAVE_LEUART_DEVICE
|
||||
#if defined(CONFIG_EFM32_LEUART0) || defined(CONFIG_EFM32_LEUART1)
|
||||
# define HAVE_LEUART_DEVICE 1
|
||||
|
||||
Reference in New Issue
Block a user