2023-11-13 01:09 PM
Hi, we need a buffer about 200KB on CM4 MCU (STM32MP153)
We change the linker file as below, that allow 256KB heap (combine SRAM2 and SRAM3)
But every time the buffer has more than 0x30000 (192KB) then it is failed, seem we can't combine SRAM2 and SRAM3 into one buffer. If the buffer stays on SRAM2 or SRAM3 only then it works, but if the buffer starts on SRAM2 and the end is on SRAM3 then fail.
Does anyone know the reason?
2023-11-13 11:16 PM
Hi @Dat Tran
SRAM2 is 128KB, SRAM3 is 64KB and SRAM4 is 64KB.
So, sound logical that SRAM2+SRAM3 is working up to 192KB.
What is the 'fail' you encounter ? bad data ? abort ? else ?
Maybe SRAM4 has some restriction for Cortex-M4 inside ETZPC or it is used by Linux which overwrite your data.
See https://wiki.st.com/stm32mpu/wiki/STM32MP15_RAM_mapping#Zoom_in_the_Cortex-A7-2FCortex-M4_shared_memory
Regards
2023-11-14 05:21 AM
Hi PatrickF,
The problem I am facing is "Failed pre launch" as picture below, when the buffer is start on SRAM2 and end is on SRAM3. But if I make buffer smaller like 100KB (stay only on SRAM2) or 32KB (moved and stay only on SRAM3) then the program runs fine.