Respondable objects

Typically: "How do I... ", "How can I... " questions
Post Reply
Davide
Posts: 9
Joined: 16 Jan 2015, 18:58

Respondable objects

Post by Davide »

Hi everybody!

I'm sorry in advance for bad english.. :)

I've downloaded your fantastic software V-REP for didactic purpose.
I am a robotics hobbyist and I want thanks you to give me the possibility to use your precious software. Thanks you very much!
Besides that I want to do so many compliments to you for what you have accomplished , I noticed that it is the result of years of hard work .

After that I studied and tried for a while , I did a small simulation to understand the basics of the dynamic engine
but in my opinion the dynamic engine does not works as expected. It's sound like a bug in the dynamic engine :)

I created a new scene with three simple objects arranged linearly at floor level :

[cuboid0]=====[cuboid1]
--------------------------------

CUBOID_0
+--> REVOLUTE JOINT
+--> +--> CUBOID_1

Floor properties set to: static & respondable
Cuboid0 properties set to: respondable.
Cuboid1 properties set to: static & respondable.
Revolute Joint properties set to: in motion mode with automatic movements enabled..
All respondable mask flags are selected for all objects, local & global.

Note:
I've just used two cuboids instead of wheels to see how the dynamics engine is involved.
I understand that is a bit strange! but I needs to see how the dynamics engine works.
In place of the cubes I could use 3d shaped servo objects to make a leg but it's the same thing naturally.

Simulation works well BUT when the Joint object rotates the CUBOID_1, the edge sinks in the floor during the rotation?!

Cuboid1 properties set to: static & respondable.
Floor properties set to: static & respondable.

In the reality the Cuboid1 would have had to lift the parent object and to move around cuboid_0 in oscillating way.
I'm wrong?

Can you help me understand how this problem can be solved ?

Thank you in advance.
Best regards.
Davide

coppelia
Site Admin
Posts: 10375
Joined: 14 Dec 2012, 00:25

Re: Respondable objects

Post by coppelia »

Hello Davide,

your second cuboid cannot be static, since it is built on a non-static cuboid (there should be a warning message when starting the simulation). Make sure to carefully read this section. So basically, if you have a static object in your construction, it needs to be at the base of the hierarchy tree. So what you can however do is have the first cuboid static, and the second non-static, that should work.

Then, but I guess you have enabled it, you need to enable the hybrid mode for your joint.

Cheers

Davide
Posts: 9
Joined: 16 Jan 2015, 18:58

Re: Respondable objects

Post by Davide »

Hello!
In facts you were exactly like you said! :)
I'm sorry for stupid question..

Now finally I begin to understand some things.
I had gotten confused because the second cuboid it turned the same well without hybrid mode.
In fact an warning had appeared in the hierarchy because I had not set up the hybrid mode in the joint one.
After I have changed the properties of the second cuboid and the joint object, it turns perfectly as in reality. :)

Now I am already developing a biped with six multishape non-pure objects.
Observing the tutorial of the hexapod with six legs, I have noticed that for every object of a leg, it needs a respondable object of identical size, before linking the multishape non-pure object to the Joint object.
I have noticed that only pure shape object can be linked with joint.

How I can create an respondable object with dimensions and positions identical to a multishape non-pure object?
Exist does a tutorial that it can teach this?
I have looked the tutorials but I have not found like creating an multishape pure object.

Thank you again.
Best regards.
Davide.

Davide
Posts: 9
Joined: 16 Jan 2015, 18:58

Re: Respondable objects

Post by Davide »

I have understood as to create a pure cuboid object with identical size and dimensions of multishape non-pure object.
I must select the multishape non-pure object that represents servo object, ungroup it and then merge the selected objects..
I must go in Edit mode then select all triangles. Click the Extract cuboid button in the shape edit dialog.
This just added a pure cuboid shape object at the same positions and with same dimensions!
Now i just Copy the pure cuboid object, undo operations until original multishape non-pure object and then Past it !!!
Now i can make it as respondable object and link it with joint object, after I can link the multishape non-pure object.
There is another faster method or is the only one that can be used?

coppelia
Site Admin
Posts: 10375
Joined: 14 Dec 2012, 00:25

Re: Respondable objects

Post by coppelia »

Actually, you do not need to have pure shapes for respondable objects. But it is recomended because of stability and speed issues.

You could also extract a convex decomposition of your shape (select your shape, then [Menu bar --> Add --> Convex decomposition of selection...]. This is not as fast and stable as with pure shapes, but is still better than to use a random mesh that is rspondable.

Cheers

Davide
Posts: 9
Joined: 16 Jan 2015, 18:58

Re: Respondable objects

Post by Davide »

A lot interesting! Thank you. :)
About "extract a convex decomposition" I have tried just now to extract a shape as you have suggested but I've noticed the colors are generated at random even if I have not checked the "Apply random colors.." option.
I have tried also to extract a convex hull from menu-bar and afterwards I've used it with "Extract Shape" function from shape editor. This function has created an Shape with the uniform colors that after I can change them, while with the function “extract a convex decomposition" I cannot change them anymore.
However they are very useful functions easy to use. Congrats.
Thank you very much for the aid.
Davide.

coppelia
Site Admin
Posts: 10375
Joined: 14 Dec 2012, 00:25

Re: Respondable objects

Post by coppelia »

When you use the convex decomposition function, it might be that V-REP will generate a grouped shape. Grouped shapes can be ungrouped in order to adjust visual properties of its composing elements. For that, select your grouped shape then [Menu bar --> Edit --> Grouping/Merging --> Ungroup selected shapes].

Cheers

Davide
Posts: 9
Joined: 16 Jan 2015, 18:58

Re: Respondable objects

Post by Davide »

Thanks a lot! =)

Post Reply