Skip to content

Commit

Permalink
Obtain time from node. (#3032)
Browse files Browse the repository at this point in the history
Signed-off-by: Jelmer de Wolde <jelmer.de.wolde@alliander.com>
  • Loading branch information
Jelmerdw authored Oct 16, 2024
1 parent 56d1ab1 commit 7db58f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions moveit_ros/moveit_servo/src/servo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -648,8 +648,8 @@ KinematicState Servo::getCurrentRobotState(bool block_for_current_state) const
bool have_current_state = false;
while (rclcpp::ok() && !have_current_state)
{
have_current_state = planning_scene_monitor_->getStateMonitor()->waitForCurrentState(
rclcpp::Clock(RCL_ROS_TIME).now(), ROBOT_STATE_WAIT_TIME /* s */);
have_current_state =
planning_scene_monitor_->getStateMonitor()->waitForCurrentState(node_->now(), ROBOT_STATE_WAIT_TIME /* s */);
if (!have_current_state)
{
RCLCPP_WARN(logger_, "Waiting for the current state");
Expand Down

0 comments on commit 7db58f8

Please sign in to comment.