AnsweredAssumed Answered

Bootloader. Load program with stack on CCM

Question asked by Kyb.Ivan on Oct 26, 2015
Latest reply on Oct 28, 2015 by Clive One
This code snippet is from STM32 IAP example. It is common for most bootloaders.
// Check if valid stack address (RAM address) then jump to user application
    if( ((*(__IO uint32_t*)MAIN_PROGRAM_START_ADDRESS) & 0x2FFE0000 ) == 0x20000000 )

I can't understand what is 0x2FFE0000.
It works fine while stack is located in default RAM. But I have relocate it to core-coupled memory (CCM). The next snippet is part of mdk-arm scatter file:

    RW_IRAM2 0x10000000 0x00010000  {  ; Core-coupled memory (CCM). No DMA avaliable.
        .ANY (CCM_DATA)
        startup_stm32f4xx.o (STACK)     ; reallocating the STACK to the CCM
    }

How should 1st snippet be changed?

Outcomes