Skip to main content
Visitor II
October 8, 2026

Getting hardfaults when attempting to modify flash in the second bank

Split from this post.

 

Hi @massimogPVS ,

 

Please let me check and confirm whether your assumption about missing updates in RM0454 compared to RM0444 is correct.

I have submitted an internal ticket on this topic: 227689 (this is an internal tracking number and is not accessible or usable by customers).

-Amel

Hello,

I am also using STM32G0B0 and running into hardfaults when attempting to modify flash in the second bank. Can ST please provide an update?

    2 replies

    Andrew Neil
    Super User
    October 8, 2026

     I am also using STM32G0B0 and running into hardfaults 

     

    How to debug Cortex-M Hard Faults

    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
    ST Technical Moderator
    October 13, 2026

    Hello ​@MYoungIMB 

    If an interrupt fire while flash is busy, the CPU may try to fetch ISR code from flash and fault.

    For debugging, try:

    ​
    __disable_irq();

    /* flash erase/program sequence */

    __enable_irq();

    ​

    If hardfaults disappear, the root cause is almost certainly interrupt/code-fetch related.

    In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Saket_Om