Hello,
I have bought the crazyflie 2.1 and have been able to fly it through my samsung mobile and through a gamepad using the VM that you have made available. I am working using the VM and now I would to go a little bit further. That is why I am following the "Getting started with development": https://www.bitcraze.io/documentation/t ... velopment/
Things go wrong when I want to build the source code after the small change in led.h
Things go wrong when "MAKE CLOAD". I have the following message:
make all DEBUG=0 CLOAD=1
CLEAN_VERSION
make[1]: *** No rule to make target 'list.o', needed by 'cf2.elf'. Stop.
Makefile:397: recipe for target 'build' failed
make: *** [build] Error 2
18:02:00 Build Failed. 3 errors, 0 warnings. (took 4s.3ms)
FYI: I have been able to download and update the latest firmware (firmware-cf2-2021.03-rc4.zip) in the crazyflie as explained under:
https://www.bitcraze.io/documentation/t ... fig-client
The latest update works fine and I can connect and fly the crazyflie.
Can anyone help me ?
Thanks. Franky
Problem when building code: MAKE CLOAD
Re: Problem when building code: MAKE CLOAD
I have now tried things directly using the terminal window with the same problem:
bitcraze@ubuntu:~$ cd /home/bitcraze/projects/crazyflie-firmware
bitcraze@ubuntu:~/projects/crazyflie-firmware$ make clean
CLEAN
bitcraze@ubuntu:~/projects/crazyflie-firmware$ make
CLEAN_VERSION
make[1]: *** No rule to make target 'list.o', needed by 'cf2.elf'. Stop.
Makefile:397: recipe for target 'build' failed
make: *** [build] Error 2
Regards,
Franky
bitcraze@ubuntu:~$ cd /home/bitcraze/projects/crazyflie-firmware
bitcraze@ubuntu:~/projects/crazyflie-firmware$ make clean
CLEAN
bitcraze@ubuntu:~/projects/crazyflie-firmware$ make
CLEAN_VERSION
make[1]: *** No rule to make target 'list.o', needed by 'cf2.elf'. Stop.
Makefile:397: recipe for target 'build' failed
make: *** [build] Error 2
Regards,
Franky
Re: Problem when building code: MAKE CLOAD
Hi!
It looks like you are missing submodules in your repo (maybe you forgot the --recursive flag when cloning)?
Could you do this while in the base folder of the crazyflie-firmware repo:
Then make should work.
btw, you should first do 'make all' and afterwards do 'make cload'. Check the build and flashing instructions of the readme of the repo
update: I saw that @arnaud gave you those instructions of make cload, it should be fine then! but it still is good to read the instructions
It looks like you are missing submodules in your repo (maybe you forgot the --recursive flag when cloning)?
Could you do this while in the base folder of the crazyflie-firmware repo:
Code: Select all
git submodule init
git submodule update
btw, you should first do 'make all' and afterwards do 'make cload'. Check the build and flashing instructions of the readme of the repo
update: I saw that @arnaud gave you those instructions of make cload, it should be fine then! but it still is good to read the instructions
Re: Problem when building code: MAKE CLOAD
Thank you for the reply. I have followed the instructions. This is the message I get:
bitcraze@ubuntu:~$ cd /home/bitcraze/projects/crazyflie-firmware
bitcraze@ubuntu:~/projects/crazyflie-firmware$ git submodule init
bitcraze@ubuntu:~/projects/crazyflie-firmware$ git submodule update
fatal: remote error: upload-pack: not our ref a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4
fatal: The remote end hung up unexpectedly
Fetched in submodule path 'vendor/CMSIS', but it did not contain a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4. Direct fetching of that commit failed.
Note that this is also one of the messages I get when I start from the VM and I "Update source code" as explained in
https://www.bitcraze.io/documentation/t ... yflie-2-x/
The message is
Updating /home/bitcraze/projects/crazyflie2-exp-template-electronics
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-nrf-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-nrf-firmware
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-stm-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie-android-client
Already up to date.
Updating /home/bitcraze/projects/crazyflie-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie-clients-python
Already up to date.
Updating /home/bitcraze/projects/crazyflie-firmware
Already up to date.
fatal: remote error: upload-pack: not our ref a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4
fatal: The remote end hung up unexpectedly
Fetched in submodule path 'vendor/CMSIS', but it did not contain a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4. Direct fetching of that commit failed.
Updating /home/bitcraze/projects/crazyflie-lib-python
Already up to date.
Updating /home/bitcraze/projects/crazyradio-firmware
Already up to date.
Updating /home/bitcraze/projects/lps-node-firmware
Already up to date.
Press any key to exit
This is a message that I had right from the start ...
Regards,
Franky
bitcraze@ubuntu:~$ cd /home/bitcraze/projects/crazyflie-firmware
bitcraze@ubuntu:~/projects/crazyflie-firmware$ git submodule init
bitcraze@ubuntu:~/projects/crazyflie-firmware$ git submodule update
fatal: remote error: upload-pack: not our ref a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4
fatal: The remote end hung up unexpectedly
Fetched in submodule path 'vendor/CMSIS', but it did not contain a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4. Direct fetching of that commit failed.
Note that this is also one of the messages I get when I start from the VM and I "Update source code" as explained in
https://www.bitcraze.io/documentation/t ... yflie-2-x/
The message is
Updating /home/bitcraze/projects/crazyflie2-exp-template-electronics
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-nrf-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-nrf-firmware
Already up to date.
Updating /home/bitcraze/projects/crazyflie2-stm-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie-android-client
Already up to date.
Updating /home/bitcraze/projects/crazyflie-bootloader
Already up to date.
Updating /home/bitcraze/projects/crazyflie-clients-python
Already up to date.
Updating /home/bitcraze/projects/crazyflie-firmware
Already up to date.
fatal: remote error: upload-pack: not our ref a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4
fatal: The remote end hung up unexpectedly
Fetched in submodule path 'vendor/CMSIS', but it did not contain a65b7c9a3e6502127fdb80eb288d8cbdf251a6f4. Direct fetching of that commit failed.
Updating /home/bitcraze/projects/crazyflie-lib-python
Already up to date.
Updating /home/bitcraze/projects/crazyradio-firmware
Already up to date.
Updating /home/bitcraze/projects/lps-node-firmware
Already up to date.
Press any key to exit
This is a message that I had right from the start ...
Regards,
Franky
Re: Problem when building code: MAKE CLOAD
ah oke if you already have the submodules than it probably needs to sync. please try this and update us on the result.
Code: Select all
git submodule sync
git submodule update
Re: Problem when building code: MAKE CLOAD
Yes ! Thank you for helping the crazyflie newbie that I am. Very happy to have a completely working VM. Up for new discoveries.
Re: Problem when building code: MAKE CLOAD
I really appreciate this thread, I had the exact same problem. But for me I still had problems even after this.
The "make all" command now works perfectly, but "make cload" now gives an error:
My VM is able to find the Crazyradio usb dongle, so I hope it is not that which is the problem. I would be very appreciative if anyone had any idea about how to solve this.
The "make all" command now works perfectly, but "make cload" now gives an error:
Code: Select all
make cload
python3 -m cfloader flash cf2.bin stm32-fw
Traceback (most recent call last):
File "/usr/lib/python3.6/runpy.py", line 183, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "/usr/lib/python3.6/runpy.py", line 142, in _get_module_details
return _get_module_details(pkg_main_name, error)
File "/usr/lib/python3.6/runpy.py", line 109, in _get_module_details
__import__(pkg_name)
File "/home/bitcraze/projects/crazyflie-clients-python/src/cfloader/__init__.py", line 35, in <module>
from cflib.bootloader import Bootloader, Target
ImportError: cannot import name 'Target'
Makefile:437: recipe for target 'cload' failed
make: *** [cload] Error 1
Re: Problem when building code: MAKE CLOAD
Hello again!
I got a bit further since the last post. As it seemed the problem was with cflib I tried to navigate to its source folder and install it with "pip3 install -e .". First it was a problem that my pip was not upgraded, so I upgraded it. Then it did not work due to some permission problem, which has already been discussed here sort of: viewtopic.php?t=2482. So I just tried to download cfclient as pip3 install cfclient.
That actually worked, now "make cload" works in the firmware folder. I think the next step is to install cfclient in developer mode. But I think I will be able to do it from the link above.
Thank you again for the help on this thread. I had already tried to download cfclient like this, but then it did not work due to not having done "git submodule sync" I think.
I got a bit further since the last post. As it seemed the problem was with cflib I tried to navigate to its source folder and install it with "pip3 install -e .". First it was a problem that my pip was not upgraded, so I upgraded it. Then it did not work due to some permission problem, which has already been discussed here sort of: viewtopic.php?t=2482. So I just tried to download cfclient as pip3 install cfclient.
That actually worked, now "make cload" works in the firmware folder. I think the next step is to install cfclient in developer mode. But I think I will be able to do it from the link above.
Thank you again for the help on this thread. I had already tried to download cfclient like this, but then it did not work due to not having done "git submodule sync" I think.