navigator: convert to radians in configuration getter

This commit is contained in:
Matthias Grob
2019-11-22 16:54:01 +01:00
committed by Daniel Agar
parent 334a599b2d
commit 9f545ae3cf
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -345,7 +345,7 @@ MissionBlock::is_mission_item_reached()
float yaw_err = wrap_pi(_mission_item.yaw - cog);
/* accept yaw if reached or if timeout is set in which case we ignore not forced headings */
if (fabsf(yaw_err) < math::radians(_navigator->get_yaw_threshold())
if (fabsf(yaw_err) < _navigator->get_yaw_threshold()
|| (_navigator->get_yaw_timeout() >= FLT_EPSILON && !_mission_item.force_heading)) {
_waypoint_yaw_reached = true;
+1 -1
View File
@@ -286,7 +286,7 @@ public:
float get_takeoff_min_alt() const { return _param_mis_takeoff_alt.get(); }
bool get_takeoff_required() const { return _param_mis_takeoff_req.get(); }
float get_yaw_timeout() const { return _param_mis_yaw_tmt.get(); }
float get_yaw_threshold() const { return _param_mis_yaw_err.get(); }
float get_yaw_threshold() const { return math::radians(_param_mis_yaw_err.get()); }
float get_vtol_back_trans_deceleration() const { return _param_back_trans_dec_mss; }
float get_vtol_reverse_delay() const { return _param_reverse_delay; }