2020-07-15 11:52:15 +02:00
|
|
|
# Copyright (c) 2020 Inria
|
|
|
|
#
|
|
|
|
# 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_STM32
|
|
|
|
bool
|
|
|
|
select HAS_CPU_STM32
|
|
|
|
select HAS_PERIPH_CPUID
|
|
|
|
select HAS_PERIPH_GPIO
|
|
|
|
select HAS_PERIPH_GPIO_IRQ
|
2020-06-29 22:15:48 +02:00
|
|
|
select HAS_PERIPH_TIMER_PERIODIC
|
2021-01-13 20:48:29 +01:00
|
|
|
select HAS_PERIPH_RTT_OVERFLOW
|
2020-07-15 11:52:15 +02:00
|
|
|
select HAS_PERIPH_UART_MODECFG
|
|
|
|
select HAS_PERIPH_UART_NONBLOCKING
|
|
|
|
|
2021-09-17 10:24:08 +02:00
|
|
|
# This CPU requires periph_rtc when periph_rtc_mem
|
|
|
|
select MODULE_PERIPH_RTC if MODULE_PERIPH_RTC_MEM && HAS_PERIPH_RTC
|
|
|
|
|
2022-10-26 11:55:43 +02:00
|
|
|
menu "STM32 configuration"
|
|
|
|
|
2020-09-11 08:32:37 +02:00
|
|
|
# Common CPU symbol
|
2020-07-15 11:52:15 +02:00
|
|
|
config CPU
|
|
|
|
default "stm32" if CPU_STM32
|
|
|
|
|
2020-09-11 08:32:37 +02:00
|
|
|
# Definition of specific features
|
|
|
|
config HAS_CPU_STM32
|
|
|
|
bool
|
|
|
|
help
|
|
|
|
Indicates that a 'stm32' cpu is being used.
|
|
|
|
|
|
|
|
config HAS_BOOTLOADER_STM32
|
|
|
|
bool
|
|
|
|
help
|
|
|
|
Indicates that the stm32 bootloader is being used.
|
|
|
|
|
2021-12-10 14:02:33 +01:00
|
|
|
config MODULE_BOOTLOADER_STM32
|
|
|
|
bool "STM32 DFU/UART/SPI bootloader"
|
|
|
|
depends on HAS_BOOTLOADER_STM32
|
|
|
|
depends on TEST_KCONFIG
|
|
|
|
|
2022-10-26 11:55:43 +02:00
|
|
|
|
|
|
|
menu "STM32 clock configuration"
|
|
|
|
depends on CPU_STM32
|
|
|
|
|
|
|
|
rsource "kconfigs/Kconfig.clk"
|
|
|
|
rsource "kconfigs/$(CPU_FAM)/Kconfig.clk"
|
|
|
|
|
|
|
|
endmenu
|
|
|
|
|
|
|
|
rsource "kconfigs/$(CPU_FAM)/Kconfig"
|
|
|
|
rsource "kconfigs/$(CPU_FAM)/Kconfig.lines"
|
|
|
|
rsource "kconfigs/$(CPU_FAM)/Kconfig.models"
|
2020-09-24 15:21:07 +02:00
|
|
|
|
2021-10-12 20:00:19 +02:00
|
|
|
choice
|
2021-12-19 10:37:29 +01:00
|
|
|
prompt "ReaDout Protection level"
|
|
|
|
default RDP0
|
|
|
|
help
|
2022-10-26 11:49:00 +02:00
|
|
|
Set minimum running RDP level.
|
|
|
|
RDP0 is full debug permissions, RDP1 disables read from Flash but
|
|
|
|
otherwise leaves debug enabled, RDP2 disables JTAG completely. If
|
|
|
|
there is a mismatch between desired RDP level here and RDP level
|
|
|
|
set on the chip, early cpu init will hang. This ensures production
|
|
|
|
devices with the wrong RDP level, by fault or malace intent, will
|
|
|
|
not run. See cpu manual for further details on RDP.
|
2021-12-19 10:33:12 +01:00
|
|
|
depends on (CPU_FAM_F1 || CPU_FAM_F2 || CPU_FAM_F3 || CPU_FAM_F4 || CPU_FAM_F7)
|
2021-10-12 20:00:19 +02:00
|
|
|
config RDP0
|
2021-12-19 10:37:29 +01:00
|
|
|
bool "RDP0"
|
2021-10-12 20:00:19 +02:00
|
|
|
config RDP1
|
2021-12-19 10:37:29 +01:00
|
|
|
bool "RDP1"
|
2021-10-12 20:00:19 +02:00
|
|
|
config RDP2
|
2021-12-19 10:37:29 +01:00
|
|
|
bool "RDP2"
|
2021-10-12 20:00:19 +02:00
|
|
|
endchoice
|
|
|
|
|
2023-07-23 18:47:38 +02:00
|
|
|
rsource "periph/Kconfig.fmc"
|
|
|
|
|
2021-05-19 17:41:00 +02:00
|
|
|
if TEST_KCONFIG
|
|
|
|
|
2023-07-30 09:43:10 +02:00
|
|
|
rsource "lcd_fmc/Kconfig"
|
2021-05-19 17:41:00 +02:00
|
|
|
rsource "periph/Kconfig"
|
|
|
|
rsource "stmclk/Kconfig"
|
|
|
|
rsource "vectors/Kconfig"
|
|
|
|
|
|
|
|
endif # TEST_KCONFIG
|
|
|
|
|
2022-10-26 11:55:43 +02:00
|
|
|
endmenu
|
|
|
|
|
2020-07-15 11:52:15 +02:00
|
|
|
source "$(RIOTCPU)/cortexm_common/Kconfig"
|