Add a spring on leg

Typically: "How do I... ", "How can I... " questions
Post Reply
hubertjw
Posts: 9
Joined: 19 Feb 2016, 10:38

Add a spring on leg

Post by hubertjw »

Hello,

I've modelled a biped robot and now I want to add springs between its "feet" and its "hips" but I'm unsure about the way it works. Right now I've added a prismatic joint set as a spring between the foot and a first dummy. The second dummy is a child of the "hips".

here is an image of my setup
https://drive.google.com/file/d/0B_iCEk ... sp=sharing

Is this the way I am supposed to go ?

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

Re: Add a spring on leg

Post by coppelia »

Hello,

so, what you basically want to do is to have a loop in each of your legs, when the loop closing is a spring/damper?
Your approach goes in the right direction. You however forgot to add spherical joints at each end of the prismatic joint (with auxiliary shapes in-between), otherwise you have an over-constrained mechanism that will block.

Cheers

hubertjw
Posts: 9
Joined: 19 Feb 2016, 10:38

Re: Add a spring on leg

Post by hubertjw »

Thanks for the answer !

hubertjw
Posts: 9
Joined: 19 Feb 2016, 10:38

Re: Add a spring on leg

Post by hubertjw »

I added spherical joints but i don't think this is behaving the way I'd like it to.

Basically, I want to add some elasticity to the movement of the leg by adding a spring that would damp the movements.

Is there a mistake in the way I built the leg ?
https://drive.google.com/open?id=0B_iCE ... zVYSkNseDg

The whole scene is available here : https://drive.google.com/open?id=0B_iCE ... Vg0Q0trcDQ

Thanks !

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

Re: Add a spring on leg

Post by coppelia »

When you run the simulation, you will see an error icon next to joint Prismatic_joint. In your case, this is because you have following:

Code: Select all

Spherical_joint --> Spring_anchor2
                --> Dummy --> Prismatic_joint --> Dummy0 --> Spherical_joint0
But it should be like:

Code: Select all

Spherical_joint --> Spring_anchor2 --> Prismatic_joint --> auxiliaryMass --> Spherical_joint0
Make sure to carefully read this section, that explains about allowed and forbidden construction schemes.

Cheers

hubertjw
Posts: 9
Joined: 19 Feb 2016, 10:38

Re: Add a spring on leg

Post by hubertjw »

Thanks for the reply, I modifed my setup
https://drive.google.com/open?id=0B_iCE ... XY5R3JoNmc
but the spring falls off now and I don't get why. Do you know what am I missing ?

Thanks for the replies.

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

Re: Add a spring on leg

Post by coppelia »

Always look at the scene hierarchy, to see if all objects that should be dynamically enabled are actually dynamically enabled. In your scene, Spherical_joint and Spherical_joint0 are not. They are in passive mode, but should be in force/torque mode.

Additionally, all the auxiliary masses (e.g. Spring_anchor3, Spring_anchor2 and Spring_anchor1_002 should be non-respondable, since currently they are colliding with the robot and generating collision responses.

Finally, you will also have to adjust those auxiliary masses, they are way too different than the other masses in the robot (design considerations 7 & 8 here).

Cheers

hubertjw
Posts: 9
Joined: 19 Feb 2016, 10:38

Re: Add a spring on leg

Post by hubertjw »

Great ! It starts to work the way I want , thank you very much !

Post Reply