Skip to content
This repository was archived by the owner on Jul 10, 2025. It is now read-only.

gazebo_ros_wheel_slip: support parameters specified in launch file#1126

Merged
scpeters merged 1 commit intoros-simulation:noetic-develfrom
scpeters:wheel_slip_noetic_ignore_cfg_default
Jun 24, 2020
Merged

gazebo_ros_wheel_slip: support parameters specified in launch file#1126
scpeters merged 1 commit intoros-simulation:noetic-develfrom
scpeters:wheel_slip_noetic_ignore_cfg_default

Conversation

@scpeters
Copy link
Copy Markdown
Member

This re-targets #1111 to noetic.

The gazebo_ros_wheel_slip plugin currently ignores slip compliance values specified in a launch file due to the check of the level parameter added in 3cf9f5e, which ensures that parameter values specified in the urdf / sdf xml parameters are not over-ridden by the default values specified in the .cfg file. In order to respect the values set in launch files but ignore the defaults in the .cfg file, change the .cfg default values to -1 and adjust the callback to ignore negative values. This is fine because gazebo's WheelSlipPlugin already has default values for the slip compliance parameters, so the .cfg defaults are extraneous.

This also reverts 3cf9f5e so that the level parameter is ignored again.

See also the comment by @Maxx84 on #1111: #1111 (comment)

The WheelSlipPlugin already has default values for the slip
compliance parameters, so ignore the default values set in
WheelSlip.cfg by making them negative and instruct the
callback to ignore negative values.
Also, ignore the `level` variable in callback so that
parameters set in launch file will not be ignored.
@scpeters scpeters changed the title WheelSlip.cfg: ignore default parameter values gazebo_ros_wheel_slip: support parameters specified in launch file Jun 17, 2020
Copy link
Copy Markdown
Collaborator

@jacobperron jacobperron left a comment

Choose a reason for hiding this comment

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

LGTM

@scpeters
Copy link
Copy Markdown
Member Author

one unrelated test failure; it's probably flaky

@scpeters scpeters merged commit bf07b40 into ros-simulation:noetic-devel Jun 24, 2020
@scpeters scpeters deleted the wheel_slip_noetic_ignore_cfg_default branch June 24, 2020 21:32
cohen39 pushed a commit to cohen39/gazebo_ros_pkgs that referenced this pull request Nov 15, 2021
The WheelSlipPlugin already has default values for the slip
compliance parameters, so ignore the default values set in
WheelSlip.cfg by making them negative and instruct the
callback to ignore negative values.
Also, ignore the `level` variable in callback so that
parameters set in launch file will not be ignored.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants