Page 2 of 6
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 5:58 pm
by Call_me_a_Cab
Erm, really basic question here....
Where is "config.mk"?
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 6:12 pm
by chad
Call_me_a_Cab wrote:Erm, really basic question here....
Where is "config.mk"?
Hi @Call_me_a_Cab, there is a sample one (config.mk.example) in crazyflie-firmware/tools/make. You can either use that one and rename it config.mk or just create a new file called config.mk and add the parameter. The main Makefile in the crazyflie-firmware directory will pick it up from crazyflie-firmware/tools/make.
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 6:25 pm
by Call_me_a_Cab
Thanks Chad,
I read that and thought... Yeah that makes some sense..
However, within the VM 0.8 in eclipse in crazyflie-firmware I do not have a tools folder!?
God this is coming difficultly to me haha
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 6:29 pm
by nanobot9000
I noticed the same thing. I copied a tools folder from one of the other projects and put it in the firmware project. Not sure why there is not a tools folder or if what I did was OK, but I think it worked.
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 6:30 pm
by chad
No sweat. I think the 0.8 VM has aged out a bit and the crazyflie-firmware is on the wrong branch. Try this:
In the crazyflie-firmware directory:
It might say "crazyflie2". If so, do this:
Code: Select all
git checkout master
git pull
git branch
It should say "master". Then, check and see if you have the directory.
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 7:17 pm
by Call_me_a_Cab
Sorted!
Thanks a lot
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Mon Jun 06, 2016 9:03 pm
by theseankelly
I'm so glad this has been useful! PID tuning is more of a dark art than a science. Lots of guess and test. I encourage everyone to play with the params and see how they affect flight. I'm certain there's a better set of coefficients than what I came up with!!
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Tue Jun 07, 2016 1:03 am
by nanobot9000
Thanks for the tip on pulling down the updated master - that fixed the missing tools folder for sure.
I am new to this git business and am enjoying learning. I do have what is probably a silly question, but after I create the config.mk with the appropriate statement how do I know for sure that the build was correct aside from the behavior once I load it? Is there some number in this example that tells me it used my config.mk as part of enabling the experimental PID?
Code: Select all
Crazyflie 2.0 build!
Build 97:c2a88215d5dd (2016.02-97) CLEAN
Version extracted from git
Crazyloader build!
text data bss dec hex filename
99784 1668 35956 137408 218c0 cf2.elf
rm version.c
bitcraze@bitcraze-vm:~/projects/crazyflie-firmware$
Thanks,
Mike
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Tue Jun 07, 2016 8:45 pm
by liwanggt
I have noticed that the VM is on the "crazyflie2 branch" by default, rather than the "master branch". I also noticed that the crazyflie 2.0 I recently bought came with the "crazyflie2 branch" firmware. My question is: what is the difference between those two branches in terms of attitude estimation and control algorithms.
From the hovering experiments I performed using Crazyflie ROS driver and Optitrack, I found the "crazyflie2 branch" firmware performing slightly better than the "master branch" firmware. The difference is observed when I tried to make it hover at a fixed point. I haven't tested their difference in following given trajectories yet.
Li
chad wrote:No sweat. I think the 0.8 VM has aged out a bit and the crazyflie-firmware is on the wrong branch. Try this:
In the crazyflie-firmware directory:
It might say "crazyflie2". If so, do this:
Code: Select all
git checkout master
git pull
git branch
It should say "master". Then, check and see if you have the directory.
Re: Tuning crazyflie for smooth, stable and responsive flight
Posted: Wed Jun 08, 2016 1:48 am
by chad
@liwanggt
The VM is a little old now. The crazyflie2 branch was for initial work on the Crazyflie 2. Once the Crazyflie 2 and Crazyflie Nano (1.0) firmwares were merged, all work continued on master. The last commit on the crazyflie2 branch was back on Jul 20, 2015 -
nearly a year ago!
There are significant differences between the two branches - crazyflie2 is 286 commits behind the master branch! You can look through
the comparison on GitHub.