cancel
Showing results for 
Search instead for 
Did you mean: 

How can I convert an ELF file to DFU file? We use WICED to generate an ELF and BIN file. The conversion tool "DFU File Manager" can convert a BIN file, but when I try to download the DFU file with "ST7 DFU Demo" and "DfuSe Demo" I get "not DFU file"

JDrei.1
Associate II
 
8 REPLIES 8
F.Belaid
ST Employee

Hello @Community member​,

Could you specify the Wifi module used? and on which STM32 product? you may check Cypress WICED SDK version? For example, it is mentioned in H7B3-Discovery Kit User manual UM2569 that only Cypress WICED SDK 3.5.2 or later supports the hardware module.

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.

JDrei.1
Associate II

We are using 43xxx_Wi-Fi, STM32F412ZGT6 and Version: Luna Service Release 2 (4.4.2)

Build id: 20150219-0600.

Are you saying WICED can build a DFU file?

I built an ELF with USB DFU class device using STM32Cube. I cannot get convert the ELF file to DFU that either "ST7 DFU Demo" or "DfuSe Demo". Using "DFU File Manager" to generate DFU...

I don't recall if the DFU Manager will take .ELF input

You might want to check this

https://github.com/majbthrd/elf2dfuse

I wrote a similar tool years ago, but not sure it dealt with multi-sections .ELF.

Not sure how complex your .ELF is.

DFU File Manager should be able to process a .HEX

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..

My app was a HEX2DFU one

Perhaps you can zip up your .ELF / .HEX, and attach, so I can gauge the complexity.

email should be in the profile if you prefer that method.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
JDrei.1
Associate II

I was able to use elf2dfuse to create a DFU file. DfuSe downloaded the file and verified. However when I reboot my board, the firmware was not updated.0693W00000Y9AHQQA3.pngI have attached the ELF and DFU files. Also, I included the STM32Cube project et al that I loaded to handle DFU transfer. It enumerates, but not sure if it's actually programming the flash.

JDrei.1
Associate II

Operator error on DfuSe Demo verify, so ignore the above picture. Now I get:0693W00000Y9AQdQAN.pngI'm guessing the firmware I have loaded in my board will enumerate as a DFU device, but does not actually program the flash.

The .ELF look built differently from the project

Assuming you have a loader of some sort, as the primary .ELF starts at 0x0800C000 address, and not 0x08000000

Attached are a couple of .DFU

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
JDrei.1
Associate II

The ELF from the project includes DFU. I use ST-LINK to download it. The other DFU is my project built with WICED. I'll eventually port the STM32Cube source into my project...if I can get it working.

When I try test1.dfu...0693W00000Y9AgzQAF.pngWhen I try test2.dfu...

0693W00000Y9AhEQAV.pngAfter power cycle, the original STM32 app is still running.