Closed iche033 closed 4 months ago
It seems like a small erp2
value causes objects to be slight more unstable when two objects are attached by a joint. The new erp2
value caused a few vel checks in joint_features
to fail and I had to increase tolerance for the tests to pass. bae4277. Let me know if that shouldn't be done.
Attention: Patch coverage is 50.00000%
with 1 lines
in your changes are missing coverage. Please review.
Project coverage is 79.07%. Comparing base (
18e0dad
) to head (801dbdd
).
Files | Patch % | Lines |
---|---|---|
bullet-featherstone/src/SDFFeatures.cc | 0.00% | 1 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
🦟 Bug fix
Summary
Mesh collisions are quite unstable in our bullet-featherstone implementation. Sometimes they explode and fly away on contact. The bullet-featherstone's multibody constraint solve applies a large impulse (uncapped) when penetration occurs. To reduce this effect, we tune 2 parameters:
Here's original behavior: erp = 0.2, margin = 0.001 Box meshes explode on contact
Here's testing with just increasing the margin and leaving the erp untouched: erp = 0.2, margin = 0.01 Stability improved but there are still small bounces due to penetration
Here's the new behavior with improved stability even when the top box is dropped from higher z: erp = 0.002, margin = 0.01
The downside of having a larger margin is that the mesh collision has a small gap when resting on top of one another.
This will need to be addressed
To test
To reproduce the tests above, first you'll need these 2 PRs that allow bullet-featherstone in gz-phsyics to load meshes from relative paths:
You can download the world and model files for testing:
Run gz-sim with bullet-featherstone plugin:
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.