Skip to main content
Hans T
Associate III
March 23, 2021
Question

STM32CubeProgrammer doesn't support DFU files

  • March 23, 2021
  • 7 replies
  • 7211 views

Hello,

I'am use the STM32CubeProgrammer v2.60

In the USB programming mode, I cannot load DFU files.

Is it possible that this option is added, and a possibility to create DFU files ?

Thanks Hans

This topic has been closed for replies.

7 replies

Technical Moderator
March 29, 2021

Hello @Hans T​ ,

I advise you to update and use the latest STM32CubeProgrammer V2.7.0.

Have a look at the STM32CubeProgrammer V2.7.0 released, which details the enhancement and fixed issues.

Please let me know if this solved your issue, if so please "Select as Best" button.

If you still need help, feel free to share more details about the hardware used. 

Imen

"When your question is answered, please close this topic by clicking ""Accept as Solution"".ThanksImen"
SHers
Associate II
August 27, 2021

I have STM32CubeProgrammer v2.8.0 on my Windows 10 system, and while I can program MCUs with HEX files, the tool apparently does not support the DFU file format any more. The DFU file type does not appear as an option in the Open File dialog. The MCU is correctly listed by the operating system as "STM32 Bootloader." This is not a connectivity or system configuration issue, but one of file format support in the tools.

The old DfUse utility is also nonfunctional, disabled either by the new Cube Programmer driver or by a Windows update. I discovered these unpleasant facts by trying to program an MCU with a DFU file.

My company has invested significant effort in standardizing our firmware installation procedures to use code images as DFU files in production and field service. I urgently want to know whether ST has deprecated support for the DFU file format; if so, we have some internal re-engineering to do.

It is also worth noting that I've been unable to find any reference by ST on discontinuing support for DFU files. The STM32CubeProgrammer release notes and documentation make no mention of this.

Please clarify ST's position on DFU file format support.

Thank you.

Tesla DeLorean
Guru
August 27, 2021

Agreed it is a nice universal format for an object file describing sparse data, and not exposing a billion symbols.

Used here as a format of choice when updating from MicroSD cards, and for the user that wants to use DFU tools more directly.

I guess the headache from the ST side would be how to support external memories (and loaders) via the ROM based system loader. A home-brewer DFU loader implementation could obviously support ones own board configurations.

We really need some embedded software developers, real-world ones, driving the goals and expectations for these programming tools, and getting them vigorously tested in SW QA

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
Houda GHABRI
ST Employee
March 31, 2021

Hi @Hans T​ ,

DFU files are not supported by STM32CubeProgrammer.

I will report this point to the STM32CubeProgrammer team and see if we can address this modification.

Hope this helps you

Houda

Hans T
Hans TAuthor
Associate III
August 27, 2021

DFU application was an easy way to perform update by a customer who has no knowledge of all kinds of programming programs.

I don't have a program yet to update a dual core ARM from SD card.

so, I miss an compact and easy DFU tool.

It would be useful for a customer

1 connect PC to hardware by usb

2 put the hardware in DFU mode / reset arm

3 load DFU file

4 program DFU

ready

Hans T
Hans TAuthor
Associate III
March 31, 2021

Thank you,

It would be nice if could load DFU files.

And can create 1 or 2 hex files in one DFU file. this is useful for the dual core STM32H7

MPear.2
Visitor II
March 23, 2022

I had the same issue where the DfuSe Program is not working on Windows 10 Correctly.

After a lot of Brain ache I discovered the small convertor program within the DfuSe https://www.st.com/en/development-tools/stsw-stm32080.html

(Dfu File Manager) You can convert the .Dfu file To Binary or Hex and then use the STM32 Cube Program on the USU programming mode. Wooo Hoooo.

PChao.2
Associate
March 23, 2022

@MPear.2​ Awesome link! Thank you. I'll have to take a look at it.

I actually found a way to still use the old DFU programming mode. To get it to work, you have to set your device into the boot loader mode that you would do normally to program it in DFU mode. Then find the driver "STM32 Bootloader" in device manager and right-click on it to select Update Driver.

0693W00000LvVOqQAN.png 

After that choose:

Browse my computer for drivers (Locate and install a driver manually)

0693W00000LvVPAQA3.png 

Then pick:

Let me pick from a list of available drivers on my computer

0693W00000LvVPeQAN.png 

Check the checkbox "Show compatible hardware"

Now you'll see 2 options to pick from

  • STM Device in DFU Mode
  • STM32 Bootloader

Pick STM Device in DFU Mode and click next. The installing driver message will show up and then it's done.

0693W00000LvVQ3QAN.png 

Now in Device Manager, you'll see STM Device in DFU Mode instead of the STM32 Bootloader.

0693W00000LvVQIQA3.png 

Now your DFUse demo program will be able to detect the device and still program with the DFU file.

0693W00000LvVQhQAN.png 

0693W00000LvVR6QAN.png 

0693W00000LvVRzQAN.pngUnfortunately, you have to do this per device since any new STM device discovered by Windows for the first time will choose the STM32 Bootloader. Once you have done it once, Windows would remember that it's a DFU Mode device.

If you are writing your own DFU loader, beware that the newer STM32L4x devices are not supported right off the bat so you have to figure out the correct mapping for the byte data. I'll try to push my Csharp codes on GitHub that successfully do a DFU programming in my application.

You can always go back to the STM32 Bootloader driver by doing the same process here but pick the STM32 Bootloader driver instead.

PGrom.1
Visitor II
October 18, 2022

I can confirm this works. Thank you very much for saving my day @Patrickhaopricha​ 

PChao.2
Associate
March 23, 2022

I wish there's a demo program on how to use the new STM32 Bootloader mode as STM32CubeProgrammer. I'd actually prefer to use that since it's a lot faster at loading the new firmware than doing it in the DFU mode.

MPear.2
Visitor II
March 25, 2022

Thanks for all your help Peeps!

cpryor
Explorer
August 30, 2023

How do I burn DFU files at ALL, after Win11 blocking the old dfudemo drivers?

Win11 is blocking the drivers, if you have kernel isolation on. I can not ask my customer to disable security for this.

Also stm32cubeprogrammer is listing my device as unknown device ID 0x000. But can still do the work...

Please add DFU file format support !  Or better give us new drivers for the old dfuSE updater tool.