Can't burn firmware into Crazyflie 2.0

Firmware/software/electronics
jonasdn
Expert
Posts: 132
Joined: Mon Mar 01, 2021 3:13 pm

Re: Can't burn firmware into Crazyflie 2.0

Post by jonasdn »

Hi jacobgk2!

I am glad to hear that the most urgent issue was solved! For the cold boot, perhaps you could help us to understand what's going on by running the following command:

Code: Select all

$ python3 -m cfloader flash /path/to/firmware-file stm32-fw
You can get a firmware file from here: https://github.com/bitcraze/crazyflie-f ... ag/2021.03 (cf2.2021.03.bin)

Thanks!
jacobgk2
Beginner
Posts: 12
Joined: Fri Jul 17, 2020 2:46 pm

Re: Can't burn firmware into Crazyflie 2.0

Post by jacobgk2 »

Hi again jonasdn!

After downloading the cf2-2021.03.bin file, I ran the provided command in a command prompt and a "No module named cfloader" error was thrown. I ran the following command to make sure cfloader had been installed:

Code: Select all

pip3 install cfloader
and I got a "Requirement already satisfied" response. Do you know what the issue might be here?

As always, thank you for all of your help!
jacobgk2
Beginner
Posts: 12
Joined: Fri Jul 17, 2020 2:46 pm

Re: Can't burn firmware into Crazyflie 2.0

Post by jacobgk2 »

UPDATE: I'm not sure what changed but going back into the Crazyflie PC client and back into the cold boot (recovery) menu, I was able to connect to and flash the latest firmware release to my Crazyflie. That being said all of my issues pertaining to flashing have been resolved!
jacobgk2
Beginner
Posts: 12
Joined: Fri Jul 17, 2020 2:46 pm

Re: Can't burn firmware into Crazyflie 2.0

Post by jacobgk2 »

I am back to having an issue with cfloader, but only on the Virtual Machine. I have the most recent Virtual Box and VM release. Flashing was working fairly recently though because I was able to follow the LED change tutorial a few weeks back. Now when I go into Visual Studio Code and run the

Code: Select all

make
make cload
commands, make runs fine but I get the following error after make cload:

Code: Select all

/usr/bin/python3: No module named cfloader.__main__; 'cfloader' is a package and cannot be directly executed
make: *** [Makefile:438: cload] Error 1
I have performed the following steps in an attempt to resolve the issue:
  1. Click the "Update all projects" icon to update everything.
  2. In the Terminal, type

    Code: Select all

    cd crazyflie-lib-python
    pip3 install -e .
    I have also tried with

    Code: Select all

    pip3 install --user -e .
  3. In the same Terminal, type

    Code: Select all

    pip3 install cfloader
    which returns a "Requirement already satisfied" line
  4. I have also tried downloading the most recent firmware release and running the following command

    Code: Select all

    python3 -m cfloader flash /path/ stm32-fw
    which returns the same error as above.
I'm not sure what could be causing this issue or how to try to resolve it at this point so any help would be greatly appreciated!
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: Can't burn firmware into Crazyflie 2.0

Post by kimberly »

Hi!

Sorry for extremely late reply...

There has been recently a full release so it would be good to try again! Update all projects and then for both crazyflie-lib-python and crazyflie-client-python repositories do the

Code: Select all

pip3 install -e .
Cfloader is actually part of the client repository, so that is probably why there was a mismatch between those libraries.

If everything fails, you could also try to install it all from latest release to really make sure it is okay:

Code: Select all

pip3 uninstall cflib cfclient
pip3 install cflcient
This should be fine if you are not planning to do any development for both the cflcient and cfclib
jacobgk2
Beginner
Posts: 12
Joined: Fri Jul 17, 2020 2:46 pm

Re: Can't burn firmware into Crazyflie 2.0

Post by jacobgk2 »

kimberly wrote: Mon Jul 05, 2021 2:46 pm
If everything fails, you could also try to install it all from latest release to really make sure it is okay:

Code: Select all

pip3 uninstall cflib cfclient
pip3 install cflcient
This worked for me! Thank you so much for the help.
Post Reply