rtl: implemented RTL based on cone shape

- user defines a cone half angle which defines the RTL altitude behavior
- if vehicle is outside the cone it will climb until it intersects the cone
and then return at this altitude.
- if vehicle is inside the cone or above the predefined return altitude (RTL_RETURN_ALT)
then it will return at the current altitude

Signed-off-by: RomanBapst <bapstroman@gmail.com>
This commit is contained in:
RomanBapst
2019-07-05 18:05:09 +02:00
committed by Mathieu Bresciani
parent f7a460427b
commit 81ee40eac8
3 changed files with 67 additions and 12 deletions
+13
View File
@@ -116,3 +116,16 @@ PARAM_DEFINE_FLOAT(RTL_MIN_DIST, 5.0f);
* @group Return Mode
*/
PARAM_DEFINE_INT32(RTL_TYPE, 0);
/**
* Half-angle of the RTL cone.
*
* Defines the half-angle of the cone which defines the vehicle RTL behavior.
*
* @unit degrees
* @min 0
* @max 90
* @increment 1
* @group Return Mode
*/
PARAM_DEFINE_INT32(RTL_CONE_ANG, 30);