-
Notifications
You must be signed in to change notification settings - Fork 268
docs: Update collision monitor tutorial for holonomic robot #871
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -169,6 +169,8 @@ Below is the example configuration using 4 sub-polygons to cover the full range | |
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
|
|
||
|
|
||
| .. note:: | ||
| It is recommended to include a ``stopped`` sub polygon as the last entry in the ``velocity_polygons`` list to cover the entire range of the robot's velocity limits. In cases where the velocity is not within the scope of any sub polygons, the Collision Monitor will log a warning message and continue with the previously matched polygon. | ||
|
|
||
|
|
@@ -177,7 +179,7 @@ Below is the example configuration using 4 sub-polygons to cover the full range | |
|
|
||
| **For holomic robots:** | ||
|
|
||
| For holomic robots, the ``holonomic`` property should be set to ``true``. In this scenario, the ``linear_min`` and ``linear_max`` parameters should cover the robot's resultant velocity limits, while the ``theta_min`` and ``theta_max`` parameters should cover the robot's angular velocity limits. Additionally, there will be 2 more parameters, ``direction_start_angle`` and ``direction_end_angle``, to specify the resultant velocity direction. The covered direction will always span from ``direction_start_angle`` to ``direction_end_angle`` in the **counter-clockwise** direction. | ||
| For holomic robots, the ``holonomic`` property should be set to ``true``. In this scenario, the ``linear_min`` and ``linear_max`` parameters should cover the magnitude of the robot’s resultant velocity limits (using only non-negative values ``>=0.0``), while the ``theta_min`` and ``theta_max`` parameters should cover the robot's angular velocity limits. Additionally, there will be 2 more parameters, ``direction_start_angle`` and ``direction_end_angle``, to specify the resultant velocity direction. The covered direction will always span from ``direction_start_angle`` to ``direction_end_angle`` in the **counter-clockwise** direction. | ||
|
SteveMacenski marked this conversation as resolved.
Outdated
|
||
|
|
||
| .. image:: images/Collision_Monitor/holonomic_direction.png | ||
| :width: 365px | ||
|
|
@@ -187,6 +189,143 @@ Below shows some common configurations for holonomic robots that cover multiple | |
| .. image:: images/Collision_Monitor/holonomic_examples.png | ||
| :height: 2880px | ||
|
|
||
| .. code-block:: yaml | ||
|
|
||
| collision_monitor: | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Where did this come from and does this match the image?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I created this example following the pattern of the non-holonomic robot example above. regarding the parameters, the previous commit had some discrepancies with the image. I have now updated the angle ranges to match the image exactly. |
||
| ros__parameters: | ||
| base_frame_id: "base_link" | ||
| odom_frame_id: "odom" | ||
| cmd_vel_in_topic: "cmd_vel_smoothed" | ||
| cmd_vel_out_topic: "nav_vel" | ||
| state_topic: "collision_monitor_state" | ||
| transform_tolerance: 0.3 | ||
| source_timeout: 1.0 | ||
| base_shift_correction: True | ||
| stop_pub_timeout: 20000.0 | ||
| holonomic: true | ||
|
|
||
| polygons: ["VelocityPolygonSlow", "VelocityPolygonStop"] | ||
|
|
||
| # ========================================== | ||
| # 1. Slowdown Polygon | ||
| # ========================================== | ||
| VelocityPolygonSlow: | ||
| type: "velocity_polygon" | ||
| action_type: "slowdown" | ||
| slowdown_ratio: 0.5 | ||
| holonomic: true | ||
| visualize: True | ||
| enabled: True | ||
| velocity_polygons: [ | ||
| "forward", "forward_left", "left", "backward_left", | ||
| "backward", "backward_right", "right", "forward_right", | ||
| "stopped" | ||
| ] | ||
|
|
||
| forward: | ||
| points: "[[0.6, 0.4], [0.6, -0.4], [-0.3, -0.4], [-0.3, 0.4]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: -0.39 | ||
| direction_end_angle: 0.39 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| forward_left: | ||
| points: "[[0.55, 0.55], [0.55, -0.3], [-0.3, -0.3], [-0.3, 0.55]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: 0.39 | ||
| direction_end_angle: 1.18 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| left: | ||
| points: "[[0.4, 0.6], [0.4, -0.4], [-0.4, -0.4], [-0.4, 0.6]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: 1.18 | ||
| direction_end_angle: 1.96 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| backward_left: | ||
| points: "[[0.3, 0.55], [0.3, -0.3], [-0.55, -0.3], [-0.55, 0.55]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: 1.96 | ||
| direction_end_angle: 2.75 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| backward: | ||
| points: "[[0.3, 0.4], [0.3, -0.4], [-0.6, -0.4], [-0.6, 0.4]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: 2.75 | ||
| direction_end_angle: -2.75 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| backward_right: | ||
| points: "[[0.3, 0.3], [0.3, -0.55], [-0.55, -0.55], [-0.55, 0.3]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: -2.75 | ||
| direction_end_angle: -1.96 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| right: | ||
| points: "[[0.4, 0.4], [0.4, -0.6], [-0.4, -0.6], [-0.4, 0.4]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: -1.96 | ||
| direction_end_angle: -1.18 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| forward_right: | ||
| points: "[[0.55, 0.3], [0.55, -0.55], [-0.3, -0.55], [-0.3, 0.3]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| direction_start_angle: -1.18 | ||
| direction_end_angle: -0.39 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| stopped: | ||
| points: "[[0.4, 0.4], [0.4, -0.4], [-0.4, -0.4], [-0.4, 0.4]]" | ||
| linear_min: 0.0 | ||
| linear_max: 0.05 | ||
| direction_start_angle: -3.1415 | ||
| direction_end_angle: 3.1415 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| # ========================================== | ||
| # 2. Stop Polygon | ||
| # ========================================== | ||
| VelocityPolygonStop: | ||
| type: "velocity_polygon" | ||
| action_type: "stop" | ||
| holonomic: true | ||
| visualize: True | ||
| enabled: True | ||
| velocity_polygons: ["moving_stop", "stopped"] | ||
| moving_stop: | ||
| points: "[[0.35, 0.35], [0.35, -0.35], [-0.35, -0.35], [-0.35, 0.35]]" | ||
| linear_min: 0.05 | ||
| linear_max: 1.0 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
| stopped: | ||
| points: "[[0.3, 0.3], [0.3, -0.3], [-0.3, -0.3], [-0.3, 0.3]]" | ||
| linear_min: 0.0 | ||
| linear_max: 0.05 | ||
| theta_min: -1.0 | ||
| theta_max: 1.0 | ||
|
|
||
| Preparing Nav2 stack | ||
| ==================== | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.