cancel
Showing results for 
Search instead for 
Did you mean: 

STMU575ZI-Q TFM Port attempt: DEV TARGET NOT HALTED / The interface firmware FAILED to reset/halt the target MCU

wxman9
Visitor

Hi everyone, I was trying to port TFM + TFM_SB on my STMU575ZI-Q Nucleo following this guide: https://www.st.com/resource/en/user_manual/um2851-getting-started-with-stm32cubeu5-tfm-application-stmicroelectronics.pdf and I've managed to flash secure bootloader and TFM. I've managed to do the regression of the MCU setting the option bytes. When I finally lunched TFM_UPDATE.sh script, logs appeared on tera term as expected, but in the end it got stuck in TFM BOOT log. So I disconnected the board and tried to repeat the process, cleaning and building again the TFM SB image, TFM Appl image etc... But When I tried to mass erase the system flash, an error has occurred: DEV TARGET NOT HALTED. When I reset the board and I observe tera term logs, I can see the following:

[INF] Flash operation: Op=0x0, Area=0x0, Address=0x0

[INF] Starting bootloader

[INF] Checking BL2 NV area

[INF] Checking BL2 NV area header

[INF] Checking BL2 NV Counter consistency

[INF] Consistent BL2 NV Counter 3 = 0x1000000

[INF] Consistent BL2 NV Counter 4 = 0x1000000

[INF] Consistent BL2 NV Counter 5 = 0x1000000

[INF] Consistent BL2 NV Counter 6 = 0x1000000

[INF] Swap type: none

[INF] Swap type: none

[INF] Swap type: none

[INF] Swap type: none

[INF] verify counter 0 1000000 1000000

[INF] counter 0 : ok

[INF] hash ref OK

[INF] verify counter 1 1000000 1000000

[INF] counter 1 : ok

[INF] hash ref OK

[INF] verify counter 2 1000000 1000000

[INF] counter 2 : ok

[INF] hash ref OK

[INF] verify counter 3 1000000 1000000

[INF] counter 3 : ok

[INF] hash ref OK

[INF] Bootloader chainload address offset: 0x28000

[INF] Jumping to the first image slot

[INF] BL2 HUK 5f5f5f5f5f4b5548..5f45554c5f5f5f5f set to BL2 SHARED DATA

[INF] BL2 SEED fc0f9140ca3243b1..dd711a1f156ad759 set to BL2 SHARED DATA

[INF] Code c006000 c0184f8

[INF] hash TFM_SBSFU_Boot 5e49fe67 .. 155df3f1


It could be due to a bad port? I would like to understand the exact reason why it happened. When I connect the board via USB, I can see the following error printed in a txt file:

The interface firmware FAILED to reset/halt the target MCU

I tried different things to solve this error and manage to gain back the connection to the board, including:

Trying to connect under reset, switching reset mode, frequency on stmcubeprogrammer, trying to use stm cube programmer CLI, trying to connect PIN 5 and 7 to force boot0 to high (which, if I correctly understood, should force the board to boot with the system bootloader), but nothing seems to work.

 

0 REPLIES 0