2022-05-14 01:50 PM
Hi to everyone. I'm developing bootloader for stm32h745. My idea is to rewrite FLASH of the M4(0x81000000) core using proramm executing int M7 core. So For this first i need to stop M4, programm M4 flash and then restart it. The issue is how to stop and start M4 from the M7. Is there any hardware options to do this thing ?
2022-05-15 01:53 AM
Is there any need to stop the M4? It could be redirected to a holding loop in the M7's code area, afterwards a reset to the M4 would be sufficient.
But regarding you question:
BOOT_CM7 and BOOT_CM4 in flash option bytes, however, rewriting option bytes is rather intrusive and risky. Option byte reload must be done afterwards. And reversal after the update ...
Another option is HOLD1, HOLD2 in PWR_CPU2CR and PWR_CPU1CR, respectively. Then you'd have to go through stop mode and auto-wakeup.
You would have to issue a system reset to M4 at some time by writing to SYSRESETREQ bit in AIRCR of the M4.