Actuator; how does it work

Discussion in 'Modeling' started by Delay Lama, Jan 6, 2019.

  1. Hello,

    I am back, with another "problem". I cant figure out how to work with actuators. I tried to build two elements (capsules) and connect those via an joint. I try to use this joint to change the angle between these two elements. But my attempts are failing.
    Code:
        <body name="main_pill" pos="0 0 0">
            <!-- size (radius und rundung, länge des Mittelteils) -->
    
    
            <geom name="main" type="capsule" fromto="0 0 1 0 0 3" size="1"/>
            <joint type="free"/>
    
            <body name="second_pill" pos="0 0 7">
    
                <geom name="second" type="capsule" size="1 1"/>
                <joint name="winkel" type="hinge" pos="0 0 -2.5" axis="1 0 0" limited="true" range="-45 45" damping="5" stiffness="20" armature="0.02"/>
    
    
            </body> 
        </body>
    
    
    
        </worldbody>
    <actuator>
        <general name="winkel"joint="winkel" gear="200"/>
    </actuator>
    The upper Part is falling a side and dragging the hole construct with it. afterwards i cant stretch the Joint to original position or switch it to opposite direction.

    Is there a simple Joint to use for first positive results?
    Do you have a idea what i am missing?

    Thanks for your help.

    Edit: I am sorry for this unstructured question, but I am heavily confused right now. And I am not sure where in the MuJoCo manual I should start to read to understand, how I can build actuators that do what I want them to do, maybe you can give some advise where to start?
     
    Last edited: Jan 6, 2019