summaryrefslogtreecommitdiff
path: root/builddefs
diff options
context:
space:
mode:
authorNick Brassel <nick@tzarc.org>2022-01-24 08:49:36 +1100
committerGitHub <noreply@github.com>2022-01-24 08:49:36 +1100
commit77062e9a36b3167ea1ff747e5577a67969273c31 (patch)
tree7afbc8881b5766fc7071d01bcc995ff2f709042a /builddefs
parent0f53e1333fc2f136fb64b6f286d19f8963a46fe4 (diff)
Add L432, L442. (#16016)
Diffstat (limited to 'builddefs')
-rw-r--r--builddefs/mcu_selection.mk37
1 files changed, 37 insertions, 0 deletions
diff --git a/builddefs/mcu_selection.mk b/builddefs/mcu_selection.mk
index 3a5768de73..9fdd22c3b6 100644
--- a/builddefs/mcu_selection.mk
+++ b/builddefs/mcu_selection.mk
@@ -502,6 +502,43 @@ ifneq ($(findstring STM32G474, $(MCU)),)
STM32_BOOTLOADER_ADDRESS ?= 0x1FFF0000
endif
+ifneq (,$(filter $(MCU),STM32L432 STM32L442))
+ # Cortex version
+ MCU = cortex-m4
+
+ # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
+ ARMV = 7
+
+ ## chip/board settings
+ # - the next two should match the directories in
+ # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
+ MCU_FAMILY = STM32
+ MCU_SERIES = STM32L4xx
+
+ # Linker script to use
+ # - it should exist either in <chibios>/os/common/startup/ARMCMx/compilers/GCC/ld/
+ # or <keyboard_dir>/ld/
+ MCU_LDSCRIPT ?= STM32L432xC
+
+ # Startup code to use
+ # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/
+ MCU_STARTUP ?= stm32l4xx
+
+ # Board: it should exist either in <chibios>/os/hal/boards/,
+ # <keyboard_dir>/boards/, or drivers/boards/
+ BOARD ?= GENERIC_STM32_L432XC
+
+ PLATFORM_NAME ?= platform_l432
+
+ USE_FPU ?= yes
+
+ # UF2 settings
+ UF2_FAMILY ?= STM32L4
+
+ # Bootloader address for STM32 DFU
+ STM32_BOOTLOADER_ADDRESS ?= 0x1FFF0000
+endif
+
ifneq (,$(filter $(MCU),STM32L433 STM32L443))
# Cortex version
MCU = cortex-m4