Grasping an object with a robotic arm
I want to grab objects simple cubes using a robotic arm. I have set up material with high friction values for both the gripper and the object. Currently when the gripper closes the object wiggles its way out of the gripper's fingers. I'm using a controller to control the gripper. Link to video
I want to achieve something like the starting of this video. I'm using Unity 2019.3.13f1 which uses PhysX 4.1 I have also tried their new Temporal Gauss Seidel solver but that doesn't help either. What should I do to get results like that?
PS: I do understand that one way to do this could be to use OnCollisionEnter
, OnCollisionStay
and OnCollisionExit
callbacks to attach and detach the object into the robotic arms' hierarchy, but I want to avoid that and keep the simulation as physics based as possible!
Answer by Edy · Jul 03, 2020 at 10:51 AM
You need to use articulations for that, not the regular Rigidbody-Joint sets. Articulations are used in the video you referred. Articulations are exposed from Unity 2020.1 (beta, at the time of writing this) in the object ArticulationBody:
https://docs.unity3d.com/2020.1/Documentation/ScriptReference/ArticulationBody.html
Here you have an introduction to articulations:
https://blogs.unity3d.com/2020/05/20/use-articulation-bodies-to-easily-prototype-industrial-designs-with-realistic-motion-and-behavior/
And here you have an example Unity project using articulations to implement a roboting arm that can pick up objects:
https://github.com/Unity-Technologies/articulations-robot-demo