Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: Takayuki Murooka <[email protected]>
  • Loading branch information
takayuki5168 committed Nov 10, 2023
1 parent 4c82aaf commit dd06455
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ VelocityLimit getHardestLimit(
// find hardest max velocity
if (max_velocity < hardest_max_velocity) {
hardest_limit.stamp = limit.second.stamp;
hardest_limit.sender = limit.first;

Check warning on line 49 in planning/external_velocity_limit_selector/src/external_velocity_limit_selector_node.cpp

View check run for this annotation

Codecov / codecov/patch

planning/external_velocity_limit_selector/src/external_velocity_limit_selector_node.cpp#L49

Added line #L49 was not covered by tests
hardest_limit.max_velocity = max_velocity;
hardest_max_velocity = max_velocity;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -897,10 +897,12 @@ void MotionVelocitySmootherNode::applyExternalVelocityLimit(TrajectoryPoints & t
*inserted_index, traj.size(), external_velocity_limit_.velocity, traj);

// create virtual wall
const auto virtual_wall_marker = motion_utils::createStopVirtualWallMarker(
traj.at(*inserted_index).pose, external_velocity_limit_.sender, this->now(), 0,
base_link2front_);
pub_virtual_wall_->publish(virtual_wall_marker);
if (std::abs(external_velocity_limit_.velocity) < 1e-3) {
const auto virtual_wall_marker = motion_utils::createStopVirtualWallMarker(
traj.at(*inserted_index).pose, external_velocity_limit_.sender, this->now(), 0,
base_link2front_);
pub_virtual_wall_->publish(virtual_wall_marker);
}

RCLCPP_DEBUG(
get_logger(), "externalVelocityLimit : limit_vel = %.3f", external_velocity_limit_.velocity);
Expand Down

0 comments on commit dd06455

Please sign in to comment.