cancel
Showing results for 
Search instead for 
Did you mean: 

Using connectDfuBootloader in CubeProgrammer_API.dll

MSSloan1962
Associate III

The callback messages seem corrupt and I get a connection error or -16

2025-12-09 12-05-03.130|INFO||: Type = 0 Message = USB speed : Full Speed (12MBit/s)
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = Manuf. ID : 
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = Product ID : STMicroelectronics
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = SN : STM32 BOOTLOADER
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = DFU protocol: 1.1
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = Board : --
2025-12-09 12-05-03.130|INFO||: Type = 0 Message = Device ID : unknown

Should be:

2025-12-04 14-55-46.892|INFO||: Type = 0 Message = USB speed : Full Speed (12MBit/s)
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = Manuf. ID : STMicroelectronics
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = Product ID : DFU in FS Mode
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = SN : 200364500000
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = DFU protocol: 1.1|
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = Board : --
2025-12-04 14-55-46.892|INFO||: Type = 0 Message = Device ID : 0x0450

with a connection error = 0

Got another example of corruption:

2025-12-01 17-06-32.303|INFO||: Type = 0 Message = USB speed : Full Speed (12MBit/s)
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = Manuf. ID : 
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = Product ID : 
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = SN : STMicroelectronics
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = DFU protocol: 1.1
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = Board : --
2025-12-01 17-06-32.303|INFO||: Type = 0 Message = Device ID : unknown

I'm assuming that each non-working device is reporting the same corruption but different non-working devices give different corruptions but all are giving the connection error -16

1 REPLY 1
Kouthair
ST Employee

Hello there MSSloan1962,

Apologies for the delayed response.

The connection error -16 indicates that RDP is enabled. You can set RDU to 1 to change RDP from Level 1 to Level 0.

You can also find more about the error codes in the CubeProgrammer_API.h file.
rdu.png

Could you please try the official API example or the GUI version and confirm whether they display the correct target information?

Kouthair

If a post has helped you, make sure to mark it as a solution.