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

Add collision sensors #10

Open
2 tasks done
irisxu02 opened this issue Jan 7, 2025 · 1 comment
Open
2 tasks done

Add collision sensors #10

irisxu02 opened this issue Jan 7, 2025 · 1 comment

Comments

@irisxu02
Copy link
Collaborator

irisxu02 commented Jan 7, 2025

Follow the sensors tutorial to add collision sensors on static objects.

  • Update the sdf template for new worlds to include sensors and contact plugins
  • Update the sdf template for new environment objects to include TouchPlugin
  • [ ]

TouchPlugin tags:

  • target: how do we make sure that all other objects/relevant objects that could potentially collide with the static object are included as "target"?
  • namespace should match object name - requires updating scripts to make this change automatically upon loading new object.

Check if compatible:

    <plugin
      filename="ignition-gazebo-sensors-system"
      name="gz::sim::systems::Sensors">
      <render_engine>ogre2</render_engine>
    </plugin>
    <plugin filename="libignition-gazebo-contact-system.so"
        name="ignition::gazebo::systems::Contact">
    </plugin>

Usage:

  • e.g. listen to collision topic e.g. ign topic -e -t /wall/touched
@irisxu02
Copy link
Collaborator Author

Write custom plugin to publish human-readable message containing information like contact point and entities that collided. For example, listen to topic /physics/contacts (should enable publishing to this from physics plugin)
then report a formatted message
"Collision detected between box::link::collision and wall::link::collision at position: (0.5, 1.2, 0.0)"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant