Skip to content

Commit

Permalink
change conditioning to not trigger logging for a failed return as well
Browse files Browse the repository at this point in the history
  • Loading branch information
saikishor committed Sep 26, 2024
1 parent 023a204 commit 3bd19bf
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions controller_manager/src/controller_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2310,7 +2310,13 @@ controller_interface::return_type ControllerManager::update(
}

*loaded_controller.next_update_cycle_time += controller_period;
if (!trigger_status)

if (controller_ret != controller_interface::return_type::OK)
{
failed_controllers_list.push_back(loaded_controller.info.name);
ret = controller_ret;
}
else if (!trigger_status)
{
RCLCPP_WARN(
get_logger(),
Expand All @@ -2319,12 +2325,6 @@ controller_interface::return_type ControllerManager::update(
loaded_controller.info.name.c_str(), time.seconds(),
loaded_controller.next_update_cycle_time->seconds());
}

if (controller_ret != controller_interface::return_type::OK)
{
failed_controllers_list.push_back(loaded_controller.info.name);
ret = controller_ret;
}
}
}
}
Expand Down

0 comments on commit 3bd19bf

Please sign in to comment.