From 911c2366d3b40ddcc3bfb2155b9eb85ae2d7776e Mon Sep 17 00:00:00 2001 From: Ryan Friedman Date: Wed, 9 Aug 2023 23:38:38 -0600 Subject: [PATCH] AP_DDS: Add todo for handling control failures to rosout Signed-off-by: Ryan Friedman --- libraries/AP_DDS/AP_DDS_Client.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libraries/AP_DDS/AP_DDS_Client.cpp b/libraries/AP_DDS/AP_DDS_Client.cpp index c0e394c80a1869..57d7196baf8847 100644 --- a/libraries/AP_DDS/AP_DDS_Client.cpp +++ b/libraries/AP_DDS/AP_DDS_Client.cpp @@ -477,7 +477,9 @@ void AP_DDS_Client::on_topic (uxrSession* uxr_session, uxrObjectId object_id, ui float(rx_velocity_control_topic.twist.linear.x), float(-rx_velocity_control_topic.twist.linear.z) }; const float yaw_rate = -rx_velocity_control_topic.twist.angular.z; - external_control->set_linear_velocity_and_yaw_rate(linear_velocity, yaw_rate); + if (!external_control->set_linear_velocity_and_yaw_rate(linear_velocity, yaw_rate)) { + // TODO #23430 handle velocity control failure through rosout, throttled. + } #endif // AP_EXTERNAL_CONTROL_ENABLED break; }