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 service for adding systems to an entity #1524

Merged
merged 50 commits into from
Jun 23, 2022
Merged

Conversation

iche033
Copy link
Contributor

@iche033 iche033 commented Jun 7, 2022

🎉 New feature

Summary

Adds a service for adding systems / plugins to an entity at run time. The service accepts the new EntityPlugin_V.proto msg introduced in gazebosim/gz-msgs#261 that contains the entity id and an array of plugins / systems to add to the entity.

Test it

Run the INTEGRATION_entity_system test. It adds the diff_drive plugin to a vehicle model and verifies that it starts moving after the plugin is added.

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.

Nate Koenig and others added 30 commits February 10, 2022 20:59
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
Signed-off-by: Nate Koenig <[email protected]>
@chapulina chapulina added the 🏯 fortress Ignition Fortress label Jun 8, 2022
Copy link
Contributor

@chapulina chapulina left a comment

Choose a reason for hiding this comment

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

Did a first pass, the functionality works for me. Tested manually like this, for some fun results:

ign gazebo shapes.sdf -v 4 -r &
ign service -s /world/shapes/entity/system/add --reqtype ignition.msgs.EntityPlugin_V --reptype ignition.msgs.Boolean --timeout 3000 --req 'entity: {id: 1}, plugins: {name: "ignition::gazebo::systems::Buoyancy", filename: "ignition-gazebo-buoyancy-system"}'

src/SimulationRunner.cc Outdated Show resolved Hide resolved
src/SimulationRunner.cc Outdated Show resolved Hide resolved
test/integration/entity_system.cc Outdated Show resolved Hide resolved
src/SimulationRunner.cc Outdated Show resolved Hide resolved
src/SimulationRunner.cc Outdated Show resolved Hide resolved
nkoenig and others added 8 commits June 15, 2022 05:14
@iche033 iche033 changed the base branch from ign-gazebo6 to use_sdf_plugin June 15, 2022 23:24
Signed-off-by: Ian Chen <[email protected]>
Copy link
Contributor

@chapulina chapulina left a comment

Choose a reason for hiding this comment

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

LGTM, let's just wait for #1352 to be merged first.

We also need an ign-msgs8 release with gazebosim/gz-msgs#261, I started a forward-port so we get more into the release: gazebosim/gz-msgs#264

@chapulina chapulina mentioned this pull request Jun 23, 2022
7 tasks
Base automatically changed from use_sdf_plugin to ign-gazebo6 June 23, 2022 19:47
@chapulina chapulina removed the needs upstream release Blocked by a release of an upstream library label Jun 23, 2022
Signed-off-by: Louise Poubel <[email protected]>
Signed-off-by: Louise Poubel <[email protected]>
@codecov
Copy link

codecov bot commented Jun 23, 2022

Codecov Report

Merging #1524 (efef477) into ign-gazebo6 (ccbda48) will increase coverage by 0.00%.
The diff coverage is 83.33%.

❗ Current head efef477 differs from pull request most recent head 2ba4994. Consider uploading reports for the commit 2ba4994 to get more accurate results

@@             Coverage Diff              @@
##           ign-gazebo6    #1524   +/-   ##
============================================
  Coverage        63.96%   63.96%           
============================================
  Files              317      317           
  Lines            25584    25613   +29     
============================================
+ Hits             16364    16383   +19     
- Misses            9220     9230   +10     
Impacted Files Coverage Δ
src/SimulationRunner.cc 90.93% <69.23%> (-1.11%) ⬇️
src/SystemManager.cc 97.08% <89.65%> (-2.92%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ccbda48...2ba4994. Read the comment docs.

@chapulina chapulina merged commit 255e1e0 into ign-gazebo6 Jun 23, 2022
@chapulina chapulina deleted the entity_system_add branch June 23, 2022 23:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏯 fortress Ignition Fortress OOBE 📦✨ Out-of-box experience
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

5 participants