cancel
Showing results for 
Search instead for 
Did you mean: 

STM32CubeProgrammer doesn't support DFU files

Hans T
Associate III

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

16 REPLIES 16

Any updates on this? ST's DFuSe demo program did support DFU files (in ST's somewhat unique and nonstandard variant), and several of your customers standardized on this format and tool set. Dropping support for the format without explanation isn't exactly customer-friendly.

Now, I like the added functionality and improved interface od the STM32CubeProgrammer, but there's no significant technical impediment to supporting it in the new tool. (I know this because I wrote my own hex-to-DFU converter in C.)

Heck, make the souce tree for this tool available and I'll add DFU support myself.

MPear.2
Associate

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.

@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.

PChao.2
Associate II

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
Associate

Thanks for all your help Peeps!

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

cpryor
Associate II

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.