Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pid_longitudinal_controller): add virtual wall for dry steering and emergency #9685

Merged

Conversation

takayuki5168
Copy link
Contributor

@takayuki5168 takayuki5168 commented Dec 17, 2024

Description

This PR added a virtual wall when the pid_longitudinal_controller is in an emergency as follows.

image
image

Related links

How was this PR tested?

psim worked.

Notes for reviewers

None.

Interface changes

None.

Effects on system behavior

None.

@takayuki5168 takayuki5168 added the run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) label Dec 17, 2024
@github-actions github-actions bot added the component:control Vehicle control algorithms and mechanisms. (auto-assigned) label Dec 17, 2024
Copy link

github-actions bot commented Dec 17, 2024

Thank you for contributing to the Autoware project!

🚧 If your pull request is in progress, switch it to draft mode.

Please ensure:

Signed-off-by: Takayuki Murooka <[email protected]>
@@ -562,8 +563,8 @@ PidLongitudinalController::ControlData PidLongitudinalController::getControlData

// distance to stopline
control_data.stop_dist = longitudinal_utils::calcStopDistance(
control_data.interpolated_traj.points.at(control_data.nearest_idx).pose,
control_data.interpolated_traj, m_ego_nearest_dist_threshold, m_ego_nearest_yaw_threshold);
current_pose, control_data.interpolated_traj, m_ego_nearest_dist_threshold,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change using current_pose is necessary to calculate the negative distance when the ego exceeds the stop point so that the pid_longitudinal_controller will be in an emergency.

Is this okay for you considering the following PR where you replaced current_pose with control_data.interpolated_traj.points.at(control_data.nearest_idx).pose?
#4712

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@brkay54
I will merge now, but let me know anytime if the change does not look good to you.

Copy link

codecov bot commented Dec 17, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 29.80%. Comparing base (33190c6) to head (b82f277).
Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
...nal_controller/src/pid_longitudinal_controller.cpp 50.00% 3 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9685      +/-   ##
==========================================
- Coverage   29.81%   29.80%   -0.01%     
==========================================
  Files        1443     1444       +1     
  Lines      108607   108629      +22     
  Branches    42668    42674       +6     
==========================================
+ Hits        32378    32379       +1     
- Misses      73049    73068      +19     
- Partials     3180     3182       +2     
Flag Coverage Δ *Carryforward flag
differential 32.61% <50.00%> (?)
total 29.80% <ø> (-0.01%) ⬇️ Carriedforward from 33190c6

*This pull request uses carry forward flags. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@takayuki5168 takayuki5168 marked this pull request as ready for review December 18, 2024 02:39
@takayuki5168 takayuki5168 merged commit f87d732 into autowarefoundation:main Dec 19, 2024
32 of 33 checks passed
@takayuki5168 takayuki5168 deleted the feat/velocity-control-virtual-wall branch December 19, 2024 04:23
kyoichi-sugahara pushed a commit to kyoichi-sugahara/autoware.universe that referenced this pull request Dec 25, 2024
…and emergency (autowarefoundation#9685)

* feat(pid_longitudinal_controller): add virtual wall for dry steering and emergency

Signed-off-by: Takayuki Murooka <[email protected]>

* fix

Signed-off-by: Takayuki Murooka <[email protected]>

---------

Signed-off-by: Takayuki Murooka <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:control Vehicle control algorithms and mechanisms. (auto-assigned) run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci)
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants