2026-01-21 12:32 AM - last edited on 2026-01-21 12:38 AM by mƎALLEm
We are developing a STiROT/OEMuROT bootloader for a customer using the above chip. This is based on the STM32H7S78-DK sample. The customer has developed the main application and have added support to download a new firmware image over Ethernet. This image is stored in external RAM and once downloaded an md5 checksum of the image is stored and a flag is set to indicate that new firmware is available. At this point the device is restarted to switch to the bootloader.
We've added code to the bootloader that checks if a new firmware image is available in external RAM. If a new image is available the bootloader validates that the image is OK by recalculating the md5 checksum. The validation passes and at this point a section in external FLASH is erased. After the erase completes, the image in external RAM is copied into the external FLASH and the copied image is validated via md5 checksum - which fails.
On further investigation it is the data being read from external RAM that is incorrect (we downloaded an image with known data to test this). So it appears that erasing external FLASH causes some corruption of either the data in external RAM or reading the data. This error is repeatable: the error occurs at the same address in external RAM, and reads the same (incorrect) value. We have a number of devices available to us and all exhibit this behaviour, though while the errors are repeatable for each devices they can differ between devices in terms of location and values. We've also tried with the STM32H7S78-DK development board and have the same behaviour.
Other information: XSPI1 and 2 are swapped, MCE is disabled.
We've also applied the latest changes to Src/stm32h7rsxx_hal_xspi.c, commit 0838ced without success.
Has anyone encountered anything similar to this?
Any suggestions on likely causes or configuration changes that we could try will be greatly appreciated!
2026-01-21 1:31 AM
Hello @ken5 and welcome to the community;
For this application, I recommend you to configure your project step by step (without Ethernet, then add ethernet)
Also, I advise you to look at Security:How to start with STiRoT OEMuRoT on STM32H7S - stm32mcu wiki.
Through this practical example you will learn:
I hope this help you.
Thank you.
Kaouthar
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.