How to erase external flash using STM32_Programmer_CLI.exe and flash loader?
MCU : STM32U5G9ZJT6Q
External Flash : MX25LM51245G
SPI Interface : HSPI1
When I use STM32_Programmer_CLI.exe I cannot erase the external flash.
Board info:

I get following error from STM32_Programmer_CLI.exe:
STM32_Programmer_CLI.exe -c port=SWD -el "C:\Users\USER\Desktop\Workspace\External_Loader\MX25LM51245G_STM32U5G9ZJ\Project\EWARM\Debug\Exe\MX25LM51245G_STM32U5G9ZJ.stldr" -e all
-------------------------------------------------------------------
STM32CubeProgrammer v2.20.0
-------------------------------------------------------------------
ST-LINK SN : 56FF70067287555130422267
ST-LINK FW : V2J46S7
Board : --
Voltage : 3.21V
SWD freq : 4000 KHz
Connect mode: Normal
Reset mode : Software reset
Device ID : 0x476
Revision ID : Rev Z
Device name : STM32U5Fx/5Gx
Flash size : 4 MBytes
Device type : MCU
Device CPU : Cortex-M33
BL Version : 0x90
Debug in Low Power mode enabled
Mass erase ...
Error: Mass erase operation failed.Please verify flash protection
How can I do that please?
I looked forums and communities and I have to say the info is rather hopeless.
