CLOAD is actually not a good setting to be used as an example since it is rarely changed, I will update the docs. Sorry for the confusion!
Your config.mk file should probably be something like:
Code: Select all
PLATFORM=CF2
# DEBUG is optional, will give a bigger binary that takes longer to flash
#DEBUG=1
# CLOAD should be 1 in most normal use cases. 1 is also the default value, so there is no need to set it here
#CLOAD=1
# Enable this to force the mellinger controller to be used
# CONTROLLER=Mellinger
You need to:To create my controller, I just add a line with my file name in the same folders as the others controllers files?
or how can I add my controller to the firmware?
1. Add the file in the same folder as the other controllers. Let's call it eduardoController.c
2. Add it in the make file, for instance on this line https://github.com/bitcraze/crazyflie-f ... efile#L174 Note the name here should be eduardoController.o
3. Add a new entry in the enum after the INDI controller (for instance ControllerTypeEduardo), https://github.com/bitcraze/crazyflie-f ... ller.h#L35
After that you are good to go (I think )
You can activate your controller by setting the
Code: Select all
stabilizer.controller
or force it in the make config with
Code: Select all
CONTROLLER=Eduardo
This is how make works. A Makefile describes what we want, for instance some object files (*.o). Somewhere else in the Makefile there is a description of how to produce an object file by compiling a C file. When make is running it will see that there is an .o file missing and it will try find the corresponding C file to compile it. You can read more about make here https://en.wikipedia.org/wiki/Make_(software)I saw some .o files in crazyflie-firmware/bin that I don't know how they are created, could you help me ??