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

New Apply Link Wrench system #1593

Merged
merged 12 commits into from
Jul 23, 2022
Merged

Conversation

chapulina
Copy link
Contributor

@chapulina chapulina commented Jul 14, 2022

🎉 New feature

Summary

I needed a convenient way of applying forces to models without a plugin, so I thought I'd add a system that exposes a topic for applying wrenches to links.

The idea is similar to Gazebo classic's ~/scoped/link/name/wrench topic, but here there's a single topic for the entire world, and the exact entity is defined in the message. This way, we don't pollute the topic space, allow different ways of choosing entities (by ID, by type, etc), and don't need to instantiate the plugin for each entity.

I needed to add a few different things to implement this plugin. I'll break this into smaller PRs for each functionality, adding tests as needed.

Test it

Try the example world:

ign gazebo src/ign-gazebo/examples/worlds/apply_link_wrench.sdf

With example commands, i.e.

ign topic -t "/world/apply_link_wrench/wrench" -m ignition.msgs.EntityWrench  -p "entity: {name: 'box::link', type: LINK}, wrench: {force: {x: -1000, z: 10000}, torque: {y: -1000}}"

apply_wrench

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸

Signed-off-by: Louise Poubel <[email protected]>
@chapulina chapulina added the MBARI buoy Sponsored by MBARI buoy sim project: https://github.com/osrf/buoy_sim label Jul 14, 2022
@chapulina chapulina added the 🏰 citadel Ignition Citadel label Jul 15, 2022
@chapulina chapulina added the needs upstream release Blocked by a release of an upstream library label Jul 15, 2022
@chapulina chapulina changed the base branch from ign-gazebo3 to chapulina/3/entity_from_msg July 15, 2022 16:45
Signed-off-by: Louise Poubel <[email protected]>
Signed-off-by: Louise Poubel <[email protected]>
Signed-off-by: Louise Poubel <[email protected]>
Signed-off-by: Louise Poubel <[email protected]>
Signed-off-by: Louise Poubel <[email protected]>
Base automatically changed from chapulina/3/entity_from_msg to ign-gazebo3 July 19, 2022 18:14
Signed-off-by: Louise Poubel <[email protected]>
@chapulina chapulina removed the needs upstream release Blocked by a release of an upstream library label Jul 19, 2022
Signed-off-by: Louise Poubel <[email protected]>
@chapulina chapulina marked this pull request as ready for review July 19, 2022 19:25
Copy link
Contributor

@quarkytale quarkytale left a comment

Choose a reason for hiding this comment

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

Works for me!
(Nit the apply wrench on box command in the description has "type" missing, fixed it)

src/Util_TEST.cc Show resolved Hide resolved
examples/worlds/apply_link_wrench.sdf Outdated Show resolved Hide resolved
Signed-off-by: Louise Poubel <[email protected]>
@chapulina chapulina merged commit 8552299 into ign-gazebo3 Jul 23, 2022
@chapulina chapulina deleted the chapulina/3/apply_link_wrench branch July 23, 2022 02:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏰 citadel Ignition Citadel MBARI buoy Sponsored by MBARI buoy sim project: https://github.com/osrf/buoy_sim
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants