From 44be83e4bb5d61aa31a86db9ade74fc9b8a52e7e Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 11:27:26 +0200 Subject: [PATCH 1/5] cpu/sam3: Add Kconfig symbols --- cpu/sam3/Kconfig | 37 +++++++++++++++++++++++++++++++++++++ cpu/sam3/Makefile.features | 2 +- 2 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 cpu/sam3/Kconfig diff --git a/cpu/sam3/Kconfig b/cpu/sam3/Kconfig new file mode 100644 index 0000000000..d42f79c963 --- /dev/null +++ b/cpu/sam3/Kconfig @@ -0,0 +1,37 @@ +# Copyright (c) 2020 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. +# + +config CPU_FAM_SAM3 + bool + select CPU_CORE_CORTEX_M3 + select HAS_CORTEXM_MPU + select HAS_CPU_SAM3 + select HAS_PERIPH_CPUID + select HAS_PERIPH_HWRNG + +## CPU Models +config CPU_MODEL_SAM3X8E + bool + select CPU_FAM_SAM3 + +## Declaration of specific features +config HAS_CPU_SAM3 + bool + help + Indicates that a 'sam3' cpu is being used. + +## Common CPU symbols +config CPU_FAM + default "sam3" if CPU_FAM_SAM3 + +config CPU_MODEL + default "sam3x8e" if CPU_MODEL_SAM3X8E + +config CPU + default "sam3" if CPU_FAM_SAM3 + +source "$(RIOTCPU)/cortexm_common/Kconfig" diff --git a/cpu/sam3/Makefile.features b/cpu/sam3/Makefile.features index 77b4c805a7..20d5c599c2 100644 --- a/cpu/sam3/Makefile.features +++ b/cpu/sam3/Makefile.features @@ -5,4 +5,4 @@ FEATURES_PROVIDED += cortexm_mpu FEATURES_PROVIDED += periph_cpuid FEATURES_PROVIDED += periph_hwrng --include $(RIOTCPU)/cortexm_common/Makefile.features +include $(RIOTCPU)/cortexm_common/Makefile.features From 6c2fc7fe2449acfac06950e215d65004026481f8 Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 11:27:43 +0200 Subject: [PATCH 2/5] boards/common/arduino-due: Add Kconfig symbols --- boards/common/arduino-due/Kconfig | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 boards/common/arduino-due/Kconfig diff --git a/boards/common/arduino-due/Kconfig b/boards/common/arduino-due/Kconfig new file mode 100644 index 0000000000..8e8f67fd5c --- /dev/null +++ b/boards/common/arduino-due/Kconfig @@ -0,0 +1,19 @@ +# Copyright (c) 2020 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. + +config BOARD_COMMON_ARDUINO_DUE + bool + select CPU_MODEL_SAM3X8E + select HAS_ARDUINO + select HAS_PERIPH_ADC + select HAS_PERIPH_DAC + select HAS_PERIPH_GPIO + select HAS_PERIPH_GPIO_IRQ + select HAS_PERIPH_PWM + select HAS_PERIPH_RTT + select HAS_PERIPH_SPI + select HAS_PERIPH_TIMER + select HAS_PERIPH_UART From bced4d1f860479abbf7bacafa0c831e6ecb83479 Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 11:28:00 +0200 Subject: [PATCH 3/5] boards/arduino-due: Add Kconfig symbols --- boards/arduino-due/Kconfig | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 boards/arduino-due/Kconfig diff --git a/boards/arduino-due/Kconfig b/boards/arduino-due/Kconfig new file mode 100644 index 0000000000..272b90ad8b --- /dev/null +++ b/boards/arduino-due/Kconfig @@ -0,0 +1,15 @@ +# Copyright (c) 2020 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. + +config BOARD + default "arduino-due" if BOARD_ARDUINO_DUE + +config BOARD_ARDUINO_DUE + bool + default y + select BOARD_COMMON_ARDUINO_DUE + +source "$(RIOTBOARD)/common/arduino-due/Kconfig" From 77a284cd1c0a295c509bc431446c8052ab5a4cb2 Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 11:28:16 +0200 Subject: [PATCH 4/5] boards/udoo: Add Kconfig symbols --- boards/udoo/Kconfig | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 boards/udoo/Kconfig diff --git a/boards/udoo/Kconfig b/boards/udoo/Kconfig new file mode 100644 index 0000000000..80314be883 --- /dev/null +++ b/boards/udoo/Kconfig @@ -0,0 +1,15 @@ +# Copyright (c) 2020 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. + +config BOARD + default "udoo" if BOARD_UDOO + +config BOARD_UDOO + bool + default y + select BOARD_COMMON_ARDUINO_DUE + +source "$(RIOTBOARD)/common/arduino-due/Kconfig" From 9f9178b944eecb893c0264700f8aa96827f4c700 Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 11:28:27 +0200 Subject: [PATCH 5/5] tests/kconfig_features: Add sam3-based boards to whitelist --- tests/kconfig_features/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/kconfig_features/Makefile b/tests/kconfig_features/Makefile index 3bebd42183..91b86633bb 100644 --- a/tests/kconfig_features/Makefile +++ b/tests/kconfig_features/Makefile @@ -4,6 +4,7 @@ BOARD_WHITELIST += 6lowpan-clicker \ acd52832 \ adafruit-clue \ airfy-beacon \ + arduino-due \ arduino-duemilanove \ arduino-leonardo \ arduino-mega2560 \ @@ -156,6 +157,7 @@ BOARD_WHITELIST += 6lowpan-clicker \ telosb \ thingy52 \ ublox-c030-u201 \ + udoo \ usb-kw41z \ waspmote-pro \ weact-f411ce \