Dual Flash BANK switch on STM32G47x --- No matter how I set, FB_MODE is always 0
We are working on a remote FW update feature, where we receive the FW binary from USB. The process starts with erasing a region in flash bank 2 (0x08040000). Then it receives the FW image and flashes them. Finally, it CRC checks the entire new FW in the bank2.
Then We will switch bank1 to bank2 step by setting BFB2 to 1. And I am sure that main flash is boot area and DBANK bit is 1. Moreover I read AN2606 and AN4767, even I test ST example code( NUCLEO-G474RE\Examples\FLASH\FLASH_DualBoot ) on NUCLEO-G474RE board.
Unfortunately, all of the test is failed.
For my test, FLASH_OPTR BFB2 is set to 1 that I can watch it on STM32CubeProgrammer. But the BF_MODE bit of SYSCFG->MEMRMP is always 0, I don't know whether the flash bank is switched successfully or not.
Would you please investigate what happened?
Any help will be great and appreciated! Thank you.