Page 1 of 1
[SOLVED] Flashing Crazyflie Firmware
Posted: Fri Dec 26, 2014 11:21 am
by ArthurA
Hey,
I got my CF 2 yesterday for christmas and I'm extremely pleased with it so far
I'm having a bit of a problem with flashing the latest firmware. I can build it fine, but when I try to flash it I get this:
Code: Select all
12:12:29 **** Build of configuration Default for project crazyflie-firmware ****
make cload
../crazyflie-clients-python/bin/cfloader flash cflie.bin
Restart the CrazyFlie you want to bootload in the next 10 seconds ...
make: *** [cload] Error 255
Cannot connect the bootloader!
12:12:43 Build Finished (took 13s.730ms)
The strange thins is the
Code: Select all
../crazyflie-clients-python/bin/cfloader flash cflie.bin
line hangs for a few seconds, and then all of the rest appears with the error message...
I reset the CF while that line is running like here:
https://www.youtube.com/watch?v=chWrNh73YBw, but it still doesn't work.
Anyone know why this could be?
Re: Flashing Crazyflie Firmware
Posted: Fri Dec 26, 2014 11:22 am
by ArthurA
Oh yes, and I'm running this in the VM rev 0.5 with all of the repos updated.
Re: Flashing Crazyflie Firmware
Posted: Fri Dec 26, 2014 11:28 am
by tobias
We just released
WM 0.6. I don't think it works in 0.5 without a lot of modifications.
Re: Flashing Crazyflie Firmware
Posted: Fri Dec 26, 2014 11:39 am
by ArthurA
tobias wrote:We just released
WM 0.6. I don't think it works in 0.5 without a lot of modifications.
Oh I didn't know that. The reason that I haven't been using 0.6 is that I can't download it- when I click on any of the links (torrent or direct) I just get
Welcome to nginx!. Is that an access problem???
Re: Flashing Crazyflie Firmware
Posted: Fri Dec 26, 2014 7:19 pm
by tobias
Yep, definitely something wrong with the access rights. I'll send an email to Arnaud an hope he can fix it quickly.
Re: Flashing Crazyflie Firmware
Posted: Sat Dec 27, 2014 12:39 pm
by chonchonchon
same for me : Welcome to nginx!

Re: Flashing Crazyflie Firmware
Posted: Sun Dec 28, 2014 9:35 am
by marcus
The new VM i now uploaded
here. But looking at the printout in your initial post you are probably on the wrong crayflie-firmware branch, you should switch to the crazyflie2 branch if you want to build the firmware for the Crazyflie 2.0. There's a missing parameter for the cfloader script on the main branch for the Crazyflie 1.0, I've added an issue
here for bootloading the CF1.
Re: Flashing Crazyflie Firmware
Posted: Wed Jan 14, 2015 3:51 pm
by ArthurA
Just got my new crazyradio in the post (I broke my old one) and tried flashing the crazyflie with it using the vm 0.6, but it still doesn't work, even after updating the repos. Here are the errors:
Code: Select all
16:47:41 **** Build of configuration Default for project crazyflie2-stm-bootloader ****
make flash
openocd -d2 -f interface/stlink-v2.cfg -f target/stm32f4x_stlink.cfg -c init -c targets -c "reset halt" \
-c "flash write_image erase cf2loader.elf" -c "verify_image cf2loader.elf" -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Error: open failed
in procedure 'transport'
in procedure 'init'
Makefile:169: recipe for target 'flash' failed
make: *** [flash] Error 1
16:47:41 Build Finished (took 486ms)
Code: Select all
16:50:11 **** Build of configuration Default for project crazyflie2-nrf-firmware ****
make flash
arm-none-eabi-gcc -mcpu=cortex-m0 -mthumb -DNRF51 -I Include -I Include/gcc -Iinterface -g3 -O0 -Wall -fsingle-precision-constant -ffast-math -DS110=1 -DBLE=1 -DBLE_STACK_SUPPORT_REQD -DNRF51 -Inrf51_sdk/nrf51822/Include/gcc -Inrf51_sdk/nrf51822/Include/ -Inrf51_sdk/nrf51822/Include/ble/ -Inrf51_sdk/nrf51822/Include/ble/ble_services/ -Is110/s110_nrf51822_7.0.0_API/include -Inrf51_sdk/nrf51822/Include/app_common/ -Inrf51_sdk/nrf51822/Include/sd_common/ -c -o src/ble/ble.o src/ble/ble.c
src/ble/ble.c:19:27: fatal error: nordic_common.h: No such file or directory
#include "nordic_common.h"
^
<builtin>: recipe for target 'src/ble/ble.o' failed
compilation terminated.
make: *** [src/ble/ble.o] Error 1
16:50:12 Build Finished (took 797ms)
^^ I did click the all (no ble) option first if that makes a difference.
Any ideas?
Edit: I also can connect to the crazyflie via the client, so i have all of that configured.
Re: Flashing Crazyflie Firmware
Posted: Wed Jan 14, 2015 11:44 pm
by chad
You are trying to flash the STM32 firmware, right? And you're using the Crazyradio to flash (i.e. over-the-air)?
Inside the crazyflie-firmware directory, if I do:
And then do:
Then turn on the Crazyflie in bootloader mode (hold down power button for 3 seconds until blue light flashes) and wait a few seconds until it flashes. It seems to work ok for me. Does this work for you?
Here's some more info about OTA flashing on the wiki.
Re: Flashing Crazyflie Firmware
Posted: Thu Jan 15, 2015 7:38 am
by ArthurA
Thanks Chad, I forgot I had to put the flie in bootloader mode *facepalm*.