Home | Tutorials | Wiki | Issues
Ask Your Question

Can't get self_collide working

asked 2015-08-12 06:46:05 -0600

debz gravatar image

updated 2015-08-17 07:42:01 -0600

arm.worldHi everybody,

I'm building a simple arm robot. I built a world containing the ground, a sun and my arm. Then I simply launch the world using the command "gazebo arm.world" and let my arm robot fall down. But the several links of the robot don't collide. I put the tag "<self_collide>" to "true" in my arm model and I also tried to use a model_plugin to programmatically set the "self_collide" attribute for each link to "true".

Does anyone have an idea why there is no collision ? (I looked with the view->collision but nothing happens). Could it be because my links don't have any inertial properties ?

I just need the two fingers of the arm to collide together but have no idea how to process...



edit retag flag offensive close merge delete


You say nothing happens when you do view->collisions - are you sure your model has collisions? You should see orange transparent representations of them. Maybe try making the model itself transparent so its easier to see collisions.

chapulina gravatar imagechapulina ( 2015-08-12 11:54:23 -0600 )edit

Yes I did exactly what you said (view -> transparent and collisions). But nothing seems to happen. I actually would like the two fingers to be not able to get through each other (like in a real world). I know that two links connected by a joint will never collide, but here it is not the case...

debz gravatar imagedebz ( 2015-08-14 06:15:01 -0600 )edit

So it seems like you haven't added collisions to your model's SDF. Try adding some [collision](http://sdformat.org/spec?ver=1.5&elem=collision) elements?

chapulina gravatar imagechapulina ( 2015-08-14 12:11:42 -0600 )edit

Yes I did ! I added the code of the world I did in my question.

debz gravatar imagedebz ( 2015-08-17 07:41:04 -0600 )edit

2 answers

Sort by ยป oldest newest most voted

answered 2015-08-17 10:36:22 -0600

debz gravatar image

Ok, I solved this. The tag <self_collide>1</self_collide> had to be added in the two links of the two fingers. I read in the documentation that it was possible to declare it for the entire model, but it is not !

edit flag offensive delete link more

answered 2017-02-10 14:40:59 -0600

mape1082 gravatar image

A bit late but it does work when you declare it for the entire model. Only that you have to do it inside a gazebo tag:



edit flag offensive delete link more
Login/Signup to Answer

Question Tools


Asked: 2015-08-12 06:46:05 -0600

Seen: 247 times

Last updated: Feb 10