2022-11-24 04:34 AM
Linker scripts generated by STM32CubeIDE 1.10.1 for the STM32WB55 (but also other STM32 platforms) reserve the first 4 bytes of RAM1. Below is an excerpt from STM32WB55RGVX_FLASH.ld demostrating that. Similarly every STM32 linker script I've seen appears to reserve first 4 (sometimes 8) bytes of RAM.
Why are those 4 bytes of RAM1 reserved? Can I reclaim them and use for my own purposes?
MEMORY
{
FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 512K
RAM1 (xrw) : ORIGIN = 0x20000004, LENGTH = 0x2FFFC
RAM_SHARED (xrw) : ORIGIN = 0x20030000, LENGTH = 10K
}
Solved! Go to Solution.
2022-11-24 04:51 AM
Thes 4 bytes are used when using the OTA FW provided by ST. If you dont intend to use OTA or develop your own way, you can use these 4 bytes at the start of the SRAM1 memory.
2022-11-24 04:51 AM
Thes 4 bytes are used when using the OTA FW provided by ST. If you dont intend to use OTA or develop your own way, you can use these 4 bytes at the start of the SRAM1 memory.
2022-11-24 04:55 AM
Ah, great - thank you. I've been googling for hours and it seemed a likely explanation but there's not a single sentence that directly confirms it.
Just to clarify - "when using OTA FW provided by ST" means an example OTA implementation (e.g. https://github.com/STMicroelectronics/STM32CubeWB/tree/master/Projects/P-NUCLEO-WB55.Nucleo/Applications/BLE/BLE_Ota) and not the bootloader in boot ROM, right?
2022-11-24 05:14 AM
Correct!!
BLE_Ota is checking this address to detect whether an OTA is to be performed.
2022-11-24 05:15 AM
Wonderful, thank you again for the speedy response.