Recover board using DFU
This page describes how to recover a board using DFU mode, this procedure only applies to DFU capable devices like Revolution, RevoNano or Sparky2 boards.
Unfortunately, the CPU used on the CC3D flight controller does not support the DFU bootloader, see this page instead. Note that the page seems to be unviewable now and you may need to view it on archive.org.
During production of the STM32 micro-controller, a low level bootloader is programmed into the device as part of the process. One of the serial communication interfaces on which this bootloader is available is the USB port and it supports the DFU protocol.
The only hardware required is your flight controller and a USB cable.
Prepare board for DFU mode
You need to short the two SBL pads in your flight controller.
Pictures below show SBL pads location for Revolution, RevoNano and Sparky2 boards:
Be careful, in some cases there is others components around.
Put a solder joint only between the two pads!
After is done the controller will show only one led on (the power led) and the other leds do not blink anymore because the internal boot loader does not control it at all.
Install Zadig driver (windows)
After you connect your DFU device to the computer, a window pop up ask for a driver install.
Cancel the process and download Zadig software from this page: http://zadig.akeo.ie/
- Start the program you just downloaded while the board is connected, you should see STM32 BOOTLOADER in the drop down menu.
- Hit the install driver button
- Wait the install is finished and close Zadig software.
Flash the board
Using console (Gnu Linux / OSX)
You may need to install the dfu-util package under Linux.
sudo apt-get install dfu-util
or OSX:
brew install dfu-util
Connect board with SBL pads soldered to the computer.
Next step can be done using the dfu-util program and console command:
dfu-util -d 0483:df11 -c 1 -i 0 -a 0 -D firmware_file.bin -s 0x08000000
This assumes you already compiled the firmware file you need.
Something like this can be used as well:
make dfuutil_install make ef_<BOARD>_dfu
Where <BOARD> can be revolution or sparky2
You can also download the LibrePilot_dfu_flash.zip archive for firmware files to be flashed.
Using DFU script (Windows)
- Download the zip archive: LibrePilot_dfu_flash.zip
- Uncompress the archive's content, you can see firmware files and flash_script.bat
- Connect board with SBL pads soldered to the computer.
- Double click on flash_script.bat file
- Choose the firmware you want, example the number 2 for Revolution - entire flash and hit enter key
- Wait until the programming is finished, it can take a while for entire flash firmware.
- Disconnect board
- Remove solder join between SBL pads!
Hopefully you can now connect your board to GCS.
Your flight controller should run the firmware correctly but may need a firmware update.
Please note there is also Taulabs files for Sparky2, this allow flashing dRonin/Taulabs compatible bootloader.