Defining actuators

Now, we can define the actuator information for all of the links. The actuator macro is defined in the robot_arm_essentials.xacro file, as shown here:

<xacro:macro name="arm_transmission" params="prefix ">

<transmission name="${prefix}_trans" type="SimpleTransmission">
<type>transmission_interface/SimpleTransmission</type>
<actuator name="${prefix}_motor">
<hardwareInterface>hardware_interface/PositionJointInterface</hardwareInterface>
<mechanicalReduction>1</mechanicalReduction>
</actuator>
<joint name="${prefix}_joint">
<hardwareInterface>hardware_interface/PositionJointInterface</hardwareInterface>
</joint>
</transmission>

</xacro:macro>

Call them in the robot arm file as follows:

<xacro:arm_transmission prefix="arm_base"/>
<xacro:arm_transmission prefix="shoulder"/>
<xacro:arm_transmission prefix="bottom_wrist"/>
<xacro:arm_transmission prefix="elbow"/>
<xacro:arm_transmission prefix="top_wrist"/>

Now that the mechanisms have been called, let's call the controllers that use them and make our robot dynamic.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.15.235.104