...
First use Passby control to “spin up” motors to 20% throttle before takeoff, this reduces current spikes and increases motor longevity.
Next, add a takeoff state to path manager that calls the
LandingTakeoffManager
to figure out Path/speed targets- Either use waypoints or passby to set the throttle and move the drone
Pass vertical waypoint targets along at a set known frequency.
Reach takeoff end height and transition to either hover or follow next waypoints.
Path Manager Component:
Call the LandingTakeoffManager
to calculate the velocity at the current waypoints to follow to get to the takeoff height. Feed that data into the waypoint manager.
Landing Takeoff Manager:
Use waypoints as targets that the drone attempts to meet at a set frequency. As drone approaches target, shorten the distance to the next waypoint to slow down drone ascent.
The profile to be used can be seen below:
https://www.desmos.com/calculator/kbamddthi9
Future Idea (Not happening for 2022 competition)
Ideally calculate ascent speed using Gaussian Profile:
...