From 8ecd9fd1ee17278c1312cf409abb8828f67829dc Mon Sep 17 00:00:00 2001 From: Sai Kishor Kothakota Date: Wed, 28 Jun 2023 07:39:56 +0200 Subject: [PATCH] Add debug print of reordered controllers list once they are sorted --- controller_manager/src/controller_manager.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/controller_manager/src/controller_manager.cpp b/controller_manager/src/controller_manager.cpp index 25aa52b4ac..27029daafe 100644 --- a/controller_manager/src/controller_manager.cpp +++ b/controller_manager/src/controller_manager.cpp @@ -1149,6 +1149,12 @@ controller_interface::return_type ControllerManager::switch_controller( &ControllerManager::controller_sorting, this, std::placeholders::_1, std::placeholders::_2, to)); + RCLCPP_DEBUG(get_logger(), "Reordered controllers list is:"); + for (const auto & ctrl : to) + { + RCLCPP_DEBUG(this->get_logger(), "\t%s", ctrl.info.name.c_str()); + } + // switch lists rt_controllers_wrapper_.switch_updated_list(guard); // clear unused list