mirror of
https://github.com/bjoernellens1/bot_mini_description.git
synced 2024-11-21 23:03:47 +00:00
update
This commit is contained in:
parent
bc7c096cf8
commit
576d85cf4a
@ -0,0 +1,40 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
<robot xmlns:xacro="http://www.ros.org/wiki/xacro" >
|
||||||
|
|
||||||
|
<!-- Specify some standard inertial calculations https://en.wikipedia.org/wiki/List_of_moments_of_inertia -->
|
||||||
|
<!-- These make use of xacro's mathematical functionality -->
|
||||||
|
|
||||||
|
<xacro:macro name="inertial_sphere" params="mass radius *origin">
|
||||||
|
<inertial>
|
||||||
|
<xacro:insert_block name="origin"/>
|
||||||
|
<mass value="${mass}" />
|
||||||
|
<inertia ixx="${(2/5) * mass * (radius*radius)}" ixy="0.0" ixz="0.0"
|
||||||
|
iyy="${(2/5) * mass * (radius*radius)}" iyz="0.0"
|
||||||
|
izz="${(2/5) * mass * (radius*radius)}" />
|
||||||
|
</inertial>
|
||||||
|
</xacro:macro>
|
||||||
|
|
||||||
|
|
||||||
|
<xacro:macro name="inertial_box" params="mass x y z *origin">
|
||||||
|
<inertial>
|
||||||
|
<xacro:insert_block name="origin"/>
|
||||||
|
<mass value="${mass}" />
|
||||||
|
<inertia ixx="${(1/12) * mass * (y*y+z*z)}" ixy="0.0" ixz="0.0"
|
||||||
|
iyy="${(1/12) * mass * (x*x+z*z)}" iyz="0.0"
|
||||||
|
izz="${(1/12) * mass * (x*x+y*y)}" />
|
||||||
|
</inertial>
|
||||||
|
</xacro:macro>
|
||||||
|
|
||||||
|
|
||||||
|
<xacro:macro name="inertial_cylinder" params="mass length radius *origin">
|
||||||
|
<inertial>
|
||||||
|
<xacro:insert_block name="origin"/>
|
||||||
|
<mass value="${mass}" />
|
||||||
|
<inertia ixx="${(1/12) * mass * (3*radius*radius + length*length)}" ixy="0.0" ixz="0.0"
|
||||||
|
iyy="${(1/12) * mass * (3*radius*radius + length*length)}" iyz="0.0"
|
||||||
|
izz="${(1/2) * mass * (radius*radius)}" />
|
||||||
|
</inertial>
|
||||||
|
</xacro:macro>
|
||||||
|
|
||||||
|
|
||||||
|
</robot>
|
Loading…
Reference in New Issue
Block a user