Skip to content

Commit

Permalink
added logging for expectation management
Browse files Browse the repository at this point in the history
  • Loading branch information
saikishor committed Jul 3, 2023
1 parent 2ca3c7b commit f3c1e8e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions controller_manager/src/controller_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -553,6 +553,18 @@ controller_interface::return_type ControllerManager::configure_controller(
controller_name, std::make_unique<ControllerThreadWrapper>(controller, update_rate_));
}

const auto controller_update_rate = controller->get_update_rate();
const auto cm_update_rate = get_update_rate();
if (controller_update_rate > cm_update_rate)
{
RCLCPP_WARN(
get_logger(),
"The controller : %s update rate : %d Hz should be less than or equal to controller "
"manager's update rate : %d Hz!. The controller will be updated at controller_manager's "
"update rate.",
controller_name.c_str(), controller_update_rate, cm_update_rate);
}

// CHAINABLE CONTROLLERS: get reference interfaces from chainable controllers
if (controller->is_chainable())
{
Expand Down

0 comments on commit f3c1e8e

Please sign in to comment.