-
Notifications
You must be signed in to change notification settings - Fork 269
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
Buoyancy: fix center of volume's reference frame #1302
Conversation
Signed-off-by: Louise Poubel <louise@openrobotics.org>
Signed-off-by: Louise Poubel <louise@openrobotics.org>
Codecov Report
@@ Coverage Diff @@
## ign-gazebo3 #1302 +/- ##
===============================================
- Coverage 77.25% 77.16% -0.09%
===============================================
Files 227 227
Lines 13535 13574 +39
===============================================
+ Hits 10457 10475 +18
- Misses 3078 3099 +21
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching this. Tested before and after the fix and can confirm this fix indeed does solve the problem at hand. Same problem affects graded buoyancy ☠️ I'll go take alook and fix it.
This pull request has been mentioned on Gazebo Community. There might be relevant details there: https://community.gazebosim.org/t/new-ignition-releases-2022-03-01-citadel-edifice-fortress/1313/1 |
This pull request has been mentioned on Gazebo Community. There might be relevant details there: https://community.gazebosim.org/t/new-ignition-releases-2022-04-13-fortress-edifice/1367/1 |
🦟 Bug fix
Summary
While working with a model that uses NED / FSK orientation, I noticed that the center of volume calculation on the buoyancy plugin was using the wrong reference frame. According to the documentation and the usage, the reference frame is expected to be the parent link. But the value provided was being calculated in the world frame. That's evident when using a model that's oriented with Z down.
Test it
I added a test world with 4 models that are supposed to be neutrally buoyant. Without this fix, the model that has a CoV offset and starts with a non-zero orientation isn't stable:
Checklist
codecheck
passed (See contributing)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.🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸