Unable to connect to board after running Regression.sh in TF-M application
Hi, I followed all the steps from the UM2851 documentation about TF-M application. At point 10.2 I ran the regression.sh script, with the below output:
regression script started
Regression to RDP 0, enable tz
-------------------------------------------------------------------
STM32CubeProgrammer v2.17.0
-------------------------------------------------------------------
ST-LINK SN : 003B00243232510239353236
ST-LINK FW : V3J15M6
Board : B-U585I-IOT02A
Voltage : 3.30V
SWD freq : 8000 KHz
Connect mode: Hot Plug
Reset mode : Software reset
Device ID : 0x482
Revision ID : Rev X
Device name : STM32U575/STM32U585
Flash size : 2 MBytes (default)
Device type : MCU
Device CPU : Cortex-M33
BL Version : 0x0
Debug in Low Power mode enabled
UPLOADING OPTION BYTES DATA ...
Bank : 0x00
Address : 0x40022040
Size : 36 Bytes
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ 100%▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ 100%
Bank : 0x01
Address : 0x40022068
Size : 8 Bytes
PROGRAMMING OPTION BYTES AREA ...
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ 50%
Bank : 0x01
Address : 0x40022068
Size : 8 Bytes
Bank : 0x00
Address : 0x40022040
Size : 36 Bytes
Reconnecting...
Error: failed to reconnect after reset !
Error: Unable to reconnect after setting the Option Bytes
Now I'm no longer able to connect my board to STM32Cube Programmer, unless I keep on pressing the reset button. It seems like the regression.sh script erased everything, and there is no option byte configured, as by the pictures below:




I tried to set all of them manually, but the configuration is not saved, it cannot flash it onto the device.
When I release the reset button, the device disconnects:
12:45:15 : Error: Unable to get core ID
12:45:15 : Error: Unable to get core ID
12:45:15 : Error: Unable to get core ID
12:45:15 : Warning: Connection to device 0x482 is lost
12:45:16 : Disconnected from device.
Your kind support please. Thanks!
