From 77062e9a36b3167ea1ff747e5577a67969273c31 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Mon, 24 Jan 2022 08:49:36 +1100 Subject: Add L432, L442. (#16016) --- builddefs/mcu_selection.mk | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) (limited to 'builddefs') 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 + # /os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES) + MCU_FAMILY = STM32 + MCU_SERIES = STM32L4xx + + # Linker script to use + # - it should exist either in /os/common/startup/ARMCMx/compilers/GCC/ld/ + # or /ld/ + MCU_LDSCRIPT ?= STM32L432xC + + # Startup code to use + # - it should exist in /os/common/startup/ARMCMx/compilers/GCC/mk/ + MCU_STARTUP ?= stm32l4xx + + # Board: it should exist either in /os/hal/boards/, + # /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 -- cgit v1.2.1