Page 1 of 1
Maintain altitude when flying over obstacle in autonomous flight
Posted: Wed Aug 19, 2020 1:20 pm
Is it possible for the crazyflie to maintain altitude when flying over an object in autonomous flight using flowdeck and LPS system?
If yes, please guide me how to do it.
Re: Maintain altitude when flying over obstacle in autonomous flight
Posted: Thu Aug 20, 2020 8:22 am
This is not possible out of the box. The problem is that the estimator puts a lot of trust into the distance data from the flow deck, but there are a couple of options:
1. Add some logic that identifies changes in the "floor level" and offsets the measured distance from the flow deck. This is related to https://github.com/bitcraze/crazyflie-f ... issues/540
2. Reduce the trust in the distance measurement from the flow deck, which will put more emphasis on the data from the LPS system instead for Z. This is controlled by the std dev parameter when sending measurements to the kalman estimator, a larger value means less trust (or actually that the data is more noisy). The distance measurements are sent to the estimator using the rangeEnqueueDownRangeInEstimator() function calls (in the crazyflie firmware) from the zranger.c or zranger2.c files (depending on which deck you have). You can play with expStdA and expStdB, or remove the call all together. If you remove the call you should (I think) get good accuracy in X and Y with assistance from the flow sensor, while Z will be slightly less good since it is calculated only from the LPS data and IMU.