From 8158cdfcf43065af2709f8e90cc2f7ee7320fddf Mon Sep 17 00:00:00 2001 From: Roman Bapst Date: Mon, 17 Sep 2018 01:29:38 +0200 Subject: [PATCH] navigator: set yaw_valid flag in reposition triplet (#10294) - yaw_valid flag was always left at false which made the position controller reject the yaw setpoint of the reposition command --- src/modules/navigator/navigator_main.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/modules/navigator/navigator_main.cpp b/src/modules/navigator/navigator_main.cpp index 190eed7239..c55dade689 100644 --- a/src/modules/navigator/navigator_main.cpp +++ b/src/modules/navigator/navigator_main.cpp @@ -323,9 +323,11 @@ Navigator::run() // Go on and check which changes had been requested if (PX4_ISFINITE(cmd.param4)) { rep->current.yaw = cmd.param4; + rep->current.yaw_valid = true; } else { rep->current.yaw = NAN; + rep->current.yaw_valid = false; } if (PX4_ISFINITE(cmd.param5) && PX4_ISFINITE(cmd.param6)) {