diff options
Diffstat (limited to 'common_features.mk')
-rw-r--r-- | common_features.mk | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/common_features.mk b/common_features.mk index ed6908f4b8..e0ae1d74c1 100644 --- a/common_features.mk +++ b/common_features.mk @@ -114,6 +114,17 @@ else SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c OPT_DEFS += -DEEPROM_EMU_STM32F072xB OPT_DEFS += -DSTM32_EEPROM_ENABLE + else ifeq ($(MCU_SERIES)_$(MCU_LDSCRIPT), STM32F0xx_STM32F042x6) + + # Stack sizes: Since this chip has limited RAM capacity, the stack area needs to be reduced. + # This ensures that the EEPROM page buffer fits into RAM + USE_PROCESS_STACKSIZE = 0x600 + USE_EXCEPTIONS_STACKSIZE = 0x300 + + SRC += $(PLATFORM_COMMON_DIR)/eeprom_stm32.c + SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c + OPT_DEFS += -DEEPROM_EMU_STM32F042x6 + OPT_DEFS += -DSTM32_EEPROM_ENABLE else ifneq ($(filter $(MCU_SERIES),STM32L0xx STM32L1xx),) OPT_DEFS += -DEEPROM_DRIVER COMMON_VPATH += $(DRIVER_PATH)/eeprom |