I just talked with Tormod Volden of the dfu-util project. They are approaching the release of version 0.8, which will send firmware to the Core much faster than the current version and also fixes a bug resulting in an incorrect byte count in the output.
Tormod is very happy to support Spark users, and he wanted me to make sure people know that they should report any bugs in dfu-util to dfu-util@lists.gnumonks.org just like the command line output says!
Kenneth, the release is source code, so it’s “released” for any system that can build it. Like @sej7278, I’ve been using the master branch for months now as well, mainly because I flash firmware using DFU many times per day. The speed increase saves me a lot of time!
A while back we discussed about the dfu suffix and noted that future releases may need it. Whats your thoughts on adding it to the makefile to future-proof?
Yep that’s what i did, tried and tested many times on my local build setup
I had to split the vendor and product using the -v and -p instead of using -d
# Create a bin file from ELF file
%.bin : %.elf
@echo Invoking: ARM GNU Create Flash Image
$(OBJCOPY) -O binary $< $@
@echo Adding dfu-suffix to binary
dfu-suffix -v 1d50 -p 607f -a $@
@echo
here is the output, note the last line still says No valid DFU suffix signature but i think its just because there was none before it added one… and it works to stop the error when flashing
Invoking: ARM GNU Create Flash Image
arm-none-eabi-objcopy -O binary core-firmware.elf core-firmware.bin
Adding dfu-suffix to binary
dfu-suffix -v 1d50 -p 607f -a core-firmware.bin
dfu-suffix (dfu-util) 0.7
(C) 2011-2012 Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org
New DFU suffix added.
No valid DFU suffix signature
Yeah, actually, I just went back in git trying to find the commit that sped things up and found that it always took roughly 12.5 seconds with current firmware master binary (79900 bytes). It did get a tiny bit faster at some point (12.55 seconds down to 12.47 seconds). I’m not confusing it with with avrdude, but I might’ve heard it from someone else on the Spark team and not verified. The speed up might’ve been somewhere else in our factory programming process rather than dfu-util itself.
Ah, OK, I found an email conversation between me and @Dave on April 23rd where he suggested the latest dfu-util made our total factory test and programming time a handful of seconds faster, which was probably an accumulation of many small differences.
In any case, there are several improvements in 0.8 (released Sept 13, 2014) since 0.7 was released Oct 7, 2012. Many of the improvements are specific to the Spark Core and came directly out of discussions here in the community!