Replies: 3 comments 6 replies
-
Under WSL, the makefile tries to run the Windows python |
Beta Was this translation helpful? Give feedback.
-
Here is an update: I deleted all files and installed everything again. I tried flashing the sample code found here: https://www.bitcraze.io/documentation/tutorials/getting-started-with-development/. Here is what happens when I try to run the build: root@NAME:/mnt/c/Users/NAME/crazyflie-firmware# make -j 12 I'm worried about the MODIFIED note here, but let me know if this is how it is supposed to be. When I run the command to flash, this is what I get: root@NAME:/mnt/c/Users/NAME/crazyflie-firmware# CLOAD_CMDS="-w radio://0/80/2M" make cload make[1]: Leaving directory '/mnt/c/Users/NAME/crazyflie-firmware/build' However, when I turn the drone on, the code I changed doesn't work. Rather than the M1 light changing from red to green, there is no light at all. |
Beta Was this translation helpful? Give feedback.
-
Update: I unplugged the drone battery, plugged it back, turned the drone on, turned the drone off, held the power button to enter bootloader mode, and everything seems to work fine now. Thanks for all your help guys! |
Beta Was this translation helpful? Give feedback.
-
I'm currently trying to run the crazyflie drone through my Windows computer. I'm not using a VM and am trying to install the firmware to my computer. I am using this link: https://www.bitcraze.io/documentation/repository/crazyflie-firmware/master/building-and-flashing/build/.
I am in the compiling section currently and have ran
$ make cf2_defconfig
$ make -j 12
The build was successful and showed CLEAN in the command prompt.
I am in this section now:
Automatically enter bootloader mode
Make sure the Crazyflie is on
In your terminal, run CLOAD_CMDS="-w [CRAZYFLIE_URI]" make cload
or run cfloader flash build/cf2.bin stm32-fw -w [CRAZYFLIE_URI] with [CRAZYFLIE_URI] being the uri of the crazyflie.
I've tried to run both the CLOUD_CMDS command and the cfloader flash command but neither works.
For CLOUD_CMDS:
root@NAME:/mnt/c/Users/NAME/crazyflie-firmware# CLOAD_CMDS="-w radio://0/80/2M" make cload
tools/kbuild/Makefile.kbuild:147: warning: overriding recipe for target 'cload'
Makefile:140: warning: ignoring old recipe for target 'cload'
make[1]: Entering directory '/mnt/c/Users/NAME/crazyflie-firmware/build'
python.exe -m cfloader -w radio://0/80/2M flash cf2.bin stm32-fw
Traceback (most recent call last):
File "", line 198, in run_module_as_main
File "", line 88, in run_code
File "C:\Users\NAME\AppData\Local\Programs\Python\Python312\Lib\site-packages\cfloader_main.py", line 1, in
from cfloader import main
ImportError: cannot import name 'main' from 'cfloader' (C:\Users\NAME\AppData\Local\Programs\Python\Python312\Lib\site-packages\cfloader_init.py)
make[1]: *** [/mnt/c/Users/NAME/crazyflie-firmware/Makefile:140: cload] Error 1
make[1]: Leaving directory '/mnt/c/Users/NAME/crazyflie-firmware/build'
make: *** [tools/kbuild/Makefile.kbuild:150: sub-make] Error 2
For cfloader:
root@NAME:/mnt/c/Users/NAME/crazyflie-firmware# cfloader flash build/cf2.bin stm32-fw -w radio://0/80/2M
cfloader: command not found
root@NAME:/mnt/c/Users/NAME/crazyflie-firmware#
For the cfloader, however, when I do "pip show cfloader", it shows:
root@NAME:/mnt/c/Users/NAME/crazyflie-firmware# pip show cfloader
Name: cfloader
Version: 0.1.4
Summary: Loads python modules from a configuration file.
Home-page: https://github.com/shachibista/cfloader
Author: Shachi Bista
Author-email: [email protected]
License: MIT license
Location: /usr/local/lib/python3.10/dist-packages
Requires:
Required-by:
root@NAME:/mnt/c/Users/NAME/crazyflie-firmware#
What do I do?
Beta Was this translation helpful? Give feedback.
All reactions