[ABANDONED] After successful flashing of STM32G474, get Flash status register PROGERR, PGAERR, PGSERR

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [ABANDONED] After successful flashing of STM32G474, get Flash status register PROGERR, PGAERR, PGSERR

    I'm encountering an issue with J-Flash 7.94 when flashing an STM32G474 chip with a J-Link Compact Plus. After successful erasure of mcu and successful hex file download, attempts to write to the flash memory (within the firmware, not via J-Flash) trigger Flash error status register messages: PROGERR, PGAERR, PGSERR.

    Notably, using J-Flash 7.88e or earlier version or an ST-Link don't trigger the same issue. I have compared the Flash memory after using ST-Link and J-Link and they are identical, ruling out any prior writes to the relevant part of the flash memory. I have also compared the option bytes after I flashed with J-Link and ST-Link and they are identical as well.

    I also believe the firmware isn't the cause, as J-Flash versions 7.88e or earlier version work fine, ST-Link as well.

    I am not sure which specific J-flash version introduce this issue as after J-Flash version 7.88e, STM32G4 suffered from a known erase issue from the J-Flash which is fixed after J-Flash version 7.92g and 7.94 according to the release notes.

    I have attached the jflash output, log, flash register before and after flash memory write, cpu registers.
    Images
    • CPU register.png

      15.58 kB, 1,148×317, viewed 50 times
    • Flash register after flash memory write.png

      12.44 kB, 483×308, viewed 59 times
    • Flash register before flash memory write.png

      12.52 kB, 503×274, viewed 53 times
    Files
    • J-Link output.txt

      (3.25 kB, downloaded 57 times, last: )
    • jlink_log.txt

      (21.42 kB, downloaded 56 times, last: )