cancel
Showing results for 
Search instead for 
Did you mean: 

STM32MP157F-DK2 STMCubeProgrammer flashing USB reconnect error

LGara.1
Associate

While setting up my STM32MP157F-DK2 discovery kit, I followed the steps through the Populate the SDCard section and the flashing process failed with the following message when attempting to flash with the FlashLayout_sdcard_stm32mp157f-dk2-optee.tsv binary.

After failing with the expected flash file I tried flashing again with the FlashLayout_sdcard_stm32mp157c-dk2-optee.tsv binary and the flash process succeeded. Is this expected? I confirmed that my board is a rev F DK-2 and not rev C. I'm not sure what differences there are between the two revisions and if there is any missing functionality with the rev C binary.

16:09:26 : STM32CubeProgrammer API v2.12.0 | Linux-64Bits

16:09:37 : USB speed  : High Speed (480MBit/s)

16:09:37 : Manuf. ID  : STMicroelectronics

16:09:37 : Product ID : DFU in HS Mode @Device ID /0x500, @Revision ID /0x0000

16:09:37 : SN         : 003F00333438511436383238

16:09:37 : DFU protocol: 1.1

16:09:37 : Board      : --

16:09:37 : Device ID  : 0x0500

16:10:48 : Read TSV File: /home/loren/STM32MPU_workspace/STM32MP1-Ecosystem-v4.1.0/Starter-Package/stm32mp1-openstlinux-5.15-yocto-kirkstone-mp1-v22.11.23/images/stm32mp1/flashlayout_st-image-weston/optee/FlashLayout_sdcard_stm32mp157f-dk2-optee.tsv

16:10:48 : Number of partitions: 13

16:11:45 : Start Embedded Flashing service

16:11:45 : Memory Programming ...

16:11:45 : Opening and parsing file: tf-a-stm32mp157f-dk2-usb.stm32

16:11:45 :  File         : tf-a-stm32mp157f-dk2-usb.stm32

16:11:45 :  Size         : 220.38 KB

16:11:45 :  Partition ID : 0x01

16:11:45 : Download in Progress:

16:11:46 : File download complete

16:11:46 : Time elapsed during download operation: 00:00:00.902

16:11:46 : RUNNING Program ...

16:11:46 :  PartID:     :0x01

16:11:46 : Start operation done successfully at partition 0x01

16:11:46 : Memory Programming ...

16:11:46 : Opening and parsing file: fip-stm32mp157f-dk2-optee.bin

16:11:46 :  File         : fip-stm32mp157f-dk2-optee.bin

16:11:46 :  Size         : 1.47 MB

16:11:46 :  Partition ID : 0x03

16:11:46 : Download in Progress:

16:11:47 : File download complete

16:11:47 : Time elapsed during download operation: 00:00:01.337

16:11:47 : RUNNING Program ...

16:11:47 :  PartID:     :0x03

16:11:48 : Reconnecting the device ...

16:11:52 : USB speed  : High Speed (480MBit/s)

16:11:52 : Manuf. ID  : STMicroelectronics

16:11:52 : Product ID : USB download gadget@Device ID /0x500, @Revision ID /0x2001, @Name /STM32MP157FAC Rev.Z,

16:11:52 : SN         : 003F00333438511436383238

16:11:52 : DFU protocol: 1.1

16:11:52 : Board      : --

16:11:52 : Device ID  : 0x0500

16:11:52 : Device name : STM32MP157FAC Rev.Z

16:11:52 : Device type :

16:11:52 : Device CPU :

16:11:52 : Start operation done successfully at partition 0x03

16:11:52 : Flashlayout Programming ...

16:11:52 : Running Flashlayout Partition ...

16:11:52 : Reconnecting the device ...

16:11:52 : USB speed  : High Speed (480MBit/s)

16:11:52 : Manuf. ID  : STMicroelectronics

16:11:52 : Product ID : USB download gadget@Device ID /0x500, @Revision ID /0x2001, @Name /STM32MP157FAC Rev.Z,

16:11:52 : SN         : 003F00333438511436383238

16:11:52 : DFU protocol: 1.1

16:11:52 : Board      : --

16:11:52 : Device ID  : 0x0500

16:11:52 : Device name : STM32MP157FAC Rev.Z

16:11:52 : Device type :

16:11:52 : Device CPU :

16:11:52 : Flashlayout partition started successfully

16:11:52 : Memory Programming ...

16:11:52 : Opening and parsing file: tf-a-stm32mp157f-dk2-sdcard.stm32

16:11:52 :  File         : tf-a-stm32mp157f-dk2-sdcard.stm32

16:11:52 :  Size         : 220.41 KB

16:11:52 :  Partition ID : 0x04

16:11:52 : Download in Progress:

16:11:53 : File download complete

16:11:53 : Time elapsed during download operation: 00:00:00.122

16:11:53 : RUNNING Program ...

16:11:53 :  PartID:     :0x04

16:11:53 : Start operation done successfully at partition 0x04

16:11:53 : Memory Programming ...

16:11:53 : Opening and parsing file: tf-a-stm32mp157f-dk2-sdcard.stm32

16:11:53 :  File         : tf-a-stm32mp157f-dk2-sdcard.stm32

16:11:53 :  Size         : 220.41 KB

16:11:53 :  Partition ID : 0x05

16:11:53 : Download in Progress:

16:11:53 : File download complete

16:11:53 : Time elapsed during download operation: 00:00:00.121

16:11:53 : RUNNING Program ...

16:11:53 :  PartID:     :0x05

16:11:53 : Start operation done successfully at partition 0x05

16:11:53 : Memory Programming ...

16:11:53 : Opening and parsing file: metadata.bin

16:11:53 :  File         : metadata.bin

16:11:53 :  Size         : 96.00 B

16:11:53 :  Partition ID : 0x06

16:11:53 : Download in Progress:

16:11:53 : File download complete

16:11:53 : Time elapsed during download operation: 00:00:00.006

16:11:53 : RUNNING Program ...

16:11:53 :  PartID:     :0x06

16:11:53 : Start operation done successfully at partition 0x06

16:11:53 : Memory Programming ...

16:11:53 : Opening and parsing file: metadata.bin

16:11:53 :  File         : metadata.bin

16:11:53 :  Size         : 96.00 B

16:11:53 :  Partition ID : 0x07

16:11:53 : Download in Progress:

16:11:53 : File download complete

16:11:53 : Time elapsed during download operation: 00:00:00.006

16:11:53 : RUNNING Program ...

16:11:53 :  PartID:     :0x07

16:11:53 : Start operation done successfully at partition 0x07

16:11:53 : Memory Programming ...

16:11:53 : Opening and parsing file: fip-stm32mp157f-dk2-optee.bin

16:11:53 :  File         : fip-stm32mp157f-dk2-optee.bin

16:11:53 :  Size         : 1.47 MB

16:11:53 :  Partition ID : 0x08

16:11:53 : Download in Progress:

16:11:54 : File download complete

16:11:54 : Time elapsed during download operation: 00:00:00.788

16:11:54 : RUNNING Program ...

16:11:54 :  PartID:     :0x08

16:11:54 : Start operation done successfully at partition 0x08

16:11:54 : Memory Programming ...

16:11:54 : Opening and parsing file: st-image-bootfs-openstlinux-weston-stm32mp1.ext4

16:11:54 :  File         : st-image-bootfs-openstlinux-weston-stm32mp1.ext4

16:11:54 :  Size         : 64.00 MB

16:11:54 :  Partition ID : 0x10

16:11:54 : Download in Progress:

16:11:54 : Error: failed to download Segment[0]

16:11:54 : Error: failed to download the File

16:11:54 : Error: Download partition 0x10 failed

16:11:54 : Error: TSV flashing service failed

16:11:54 : Warning: Connection to device 0x500 is lost

16:11:54 : Disconnected from device.

1 ACCEPTED SOLUTION

Accepted Solutions
Kevin HUBER
ST Employee

Hello @LGara.1​ ,

Sorry, the file available in the post above was for the ecosystem v3.1.

Please can you make a try with this one instead.

Best Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Select as Best' on the reply which solved your issue or answered your question. See also 'Best Answers'

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

View solution in original post

3 REPLIES 3
Kevin HUBER
ST Employee

Hello @LGara.1​ ,

You encounter the same issue than this post:

https://community.st.com/s/question/0D53W00000wzkIuSAI/fail-the-image-flashing-on-stm32mpu157fdk2

Please can you make a try with the file shared in Best Answer.

Best Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Kevin HUBER
ST Employee

Hello @LGara.1​ ,

Sorry, the file available in the post above was for the ecosystem v3.1.

Please can you make a try with this one instead.

Best Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Select as Best' on the reply which solved your issue or answered your question. See also 'Best Answers'

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Thanks! This resolved the issue.