2019-12-12 04:45 AM
Hi,
I followed the AN3990 and managed to update the code supplied to use HAL and get it working correctly on our custom board. But in my readings on custom bootloaders in the forums, it mentions things like disabling interrupts before jumping to the program location in flash. The example code with the application code did not do the latter, so for the sake of good practices and reliability, what are correct actions before and after the jump to the code in flash.
Thanks in advance.
MikeZ
2019-12-12 05:32 AM
The RAM utilization in the app will be different in the loader, so peripheral instance structures and IRQ and callback functions will likely malfunction unless efforts are made to pass this data.
You should turn off interrupting sources prior to transfer, and reestablish them within the new operational context.
You can establish a contract both side, for example pass data or determine which side should establish clocks and external memory interfaces, then not repeat that initialization.
The expectations are not STM32 specific. Think through the logic and consequences.
2019-12-16 06:50 AM
Hi Clive1,
Thanks.
MikeZ