2023-08-06 07:13 PM
I want to use some part of flash memory as ram but i am getting below error
C:/ST/STM32CubeIDE_1.13.0/STM32CubeIDE/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.11.3.rel1.win32_1.1.0.202305231506/tools/bin/../lib/gcc/arm-none-eabi/11.3.1/../../../../arm-none-eabi/bin/ld.exe: Radar_Data_Acquisition_FW.elf section `user_settings_section' will not fit in region `RAM'
C:/ST/STM32CubeIDE_1.13.0/STM32CubeIDE/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.11.3.rel1.win32_1.1.0.202305231506/tools/bin/../lib/gcc/arm-none-eabi/11.3.1/../../../../arm-none-eabi/bin/ld.exe: Radar_Data_Acquisition_FW.elf section `user_settings_section' will not fit in region `FLASH'
C:/ST/STM32CubeIDE_1.13.0/STM32CubeIDE/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.11.3.rel1.win32_1.1.0.202305231506/tools/bin/../lib/gcc/arm-none-eabi/11.3.1/../../../../arm-none-eabi/bin/ld.exe: region `RAM' overflowed by 389856 bytes
C:/ST/STM32CubeIDE_1.13.0/STM32CubeIDE/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.11.3.rel1.win32_1.1.0.202305231506/tools/bin/../lib/gcc/arm-none-eabi/11.3.1/../../../../arm-none-eabi/bin/ld.exe: region `FLASH' overflowed by 194904 bytes
collect2.exe: error: ld returned 1 exit status
what i configured:
MEMORY
{
RAM (xrw) : ORIGIN = 0x20000000, LENGTH = 256K
FLASH (rx) : ORIGIN = 0x8000000, LENGTH = 312K
RAM2 (xrx) : ORIGIN = 0x804E000, LENGTH = 200K
}
.user_settings_section (NOLOAD):
{
. = ALIGN(4);
KEEP(*(.user_settings_section)) /* Config section */
. = ALIGN(4);
} >RAM2
in .c code
uint16_t myarray[200000] __attribute__((section("user_settings_section"), used));
can anyone please help me on this.
Solved! Go to Solution.
2023-08-06 08:24 PM
>>is it possible ?
No, not in the way you imagine it working.
It is slow and has width issues, although you don't identify the part in question. Why can't you just output to the UART? Probably the same reason the FLASH won't work. You've got some other fast backing store you can use?
2023-08-06 07:21 PM
FLASH cannot be used as RAM.
2023-08-06 07:27 PM
i red dma can access flash memory i want to store adc samples to flash and from flash using dma i want to trasfer data via uart
is it possible ?
2023-08-06 08:24 PM
>>is it possible ?
No, not in the way you imagine it working.
It is slow and has width issues, although you don't identify the part in question. Why can't you just output to the UART? Probably the same reason the FLASH won't work. You've got some other fast backing store you can use?