Commit 7441ba77 authored by Tobias Badertscher's avatar Tobias Badertscher Committed by Damien George
Browse files

stmhal: L4: Make CCM/DTCM RAM start-up conditional on MCU type.

parent adaaf439
...@@ -367,13 +367,15 @@ int main(void) { ...@@ -367,13 +367,15 @@ int main(void) {
__GPIOC_CLK_ENABLE(); __GPIOC_CLK_ENABLE();
__GPIOD_CLK_ENABLE(); __GPIOD_CLK_ENABLE();
#if defined(__HAL_RCC_DTCMRAMEN_CLK_ENABLE) #if defined(MCU_SERIES_F4) || defined(MCU_SERIES_F7)
// The STM32F746 doesn't really have CCM memory, but it does have DTCM, #if defined(__HAL_RCC_DTCMRAMEN_CLK_ENABLE)
// which behaves more or less like normal SRAM. // The STM32F746 doesn't really have CCM memory, but it does have DTCM,
__HAL_RCC_DTCMRAMEN_CLK_ENABLE(); // which behaves more or less like normal SRAM.
#else __HAL_RCC_DTCMRAMEN_CLK_ENABLE();
// enable the CCM RAM #else
__CCMDATARAMEN_CLK_ENABLE(); // enable the CCM RAM
__CCMDATARAMEN_CLK_ENABLE();
#endif
#endif #endif
#if defined(MICROPY_BOARD_EARLY_INIT) #if defined(MICROPY_BOARD_EARLY_INIT)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment