Skip to content

Commit

Permalink
add explain for stiffness and damping
Browse files Browse the repository at this point in the history
  • Loading branch information
Masaaki Hijikata committed Mar 28, 2024
1 parent e8a8a04 commit a586714
Show file tree
Hide file tree
Showing 25 changed files with 315 additions and 145 deletions.
4 changes: 2 additions & 2 deletions 404.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@


<link rel="icon" href="/assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -901,7 +901,7 @@ <h1>404 - Not found</h1>
<script id="__config" type="application/json">{"base": "/", "features": [], "search": "/assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="/assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="/assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Demos/demo_for_arm_robot/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -989,7 +989,7 @@ <h1 id="demo-for-arm-robot">Demo For Arm Robot</h1>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Demos/demo_for_mobile_robot/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -994,7 +994,7 @@ <h1 id="demo-for-mobile-robot">Demo For Mobile Robot</h1>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions LICENSE/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -959,7 +959,7 @@ <h1 id="license">LICENSE</h1>
<script id="__config" type="application/json">{"base": "..", "features": [], "search": "../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Tutorials/how_to_spawn_robot/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -1129,7 +1129,7 @@ <h2 id="how-to-start-up-a-node">How to start up a node</h2>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Tutorials/how_to_use_simulator_launcher/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -1048,7 +1048,7 @@ <h2 id="use-from-launch-file">Use from Launch File</h2>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
94 changes: 66 additions & 28 deletions Tutorials/setup_urdf_for_ros2_control/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -527,6 +527,15 @@
</span>
</a>

</li>

<li class="md-nav__item">
<a href="#set-up-joint-stiffness-and-damping" class="md-nav__link">
<span class="md-ellipsis">
Set up Joint Stiffness and Damping
</span>
</a>

</li>

</ul>
Expand Down Expand Up @@ -946,6 +955,15 @@
</span>
</a>

</li>

<li class="md-nav__item">
<a href="#set-up-joint-stiffness-and-damping" class="md-nav__link">
<span class="md-ellipsis">
Set up Joint Stiffness and Damping
</span>
</a>

</li>

</ul>
Expand All @@ -966,45 +984,65 @@
<h1 id="set-up-urdf-for-ros2_control">Set up URDF for ros2_control</h1>
<h2 id="introduction-to-ros2_control">Introduction to ros2_control</h2>
<p>The ros2_control offers a developers a common API that allows your software to switch between many different robot types, and the sensors they have built in, by simply changing some launch arguments. For example if we inspect the Panda Robot’s ros2_control.xacro we can see it uses a flag use_fake_hardware to switch between being simulated or connecting to a physical robot.</p>
<pre><code class="language-xml">&lt;hardware&gt;
&lt;xacro:if value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;mock_components/GenericSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;xacro:unless value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;franka_hardware/FrankaHardwareInterface&lt;/plugin&gt;
&lt;param name=&quot;robot_ip&quot;&gt;${robot_ip}&lt;/param&gt;
&lt;/xacro:unless&gt;
&lt;/hardware&gt;
<pre><code class="language-xml">&lt;ros2_control&gt;
&lt;hardware&gt;
&lt;xacro:if value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;mock_components/GenericSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;xacro:unless value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;franka_hardware/FrankaHardwareInterface&lt;/plugin&gt;
&lt;param name=&quot;robot_ip&quot;&gt;${robot_ip}&lt;/param&gt;
&lt;/xacro:unless&gt;
&lt;/hardware&gt;
&lt;/ros2_control&gt;
</code></pre>
<p>Hardware Components can be of different types, but the plugin "mock_components/GenericSystem" is very a simple System that forwards the incoming command_interface values to the tracked state_interface of the joints (i.e., perfect control of the simulated joints).</p>
<p>To use ros2_control with Isaac Sim, we have to introduce isaac_ros2_control. This Hardware Interface is a System that read / write joint state / command from shared memory.
There is another method using topic_based_ros2_control, but this one did not work well with mobile robots due to problems with positional commands.
isaac_ros2_control retrieves the shared memory associated with the name attribute of the robot tag and reads and writes information about the joint.
Therefore, when operating multiple robots, it is necessary to change the name attribute value of the robot tag of the URDF to be read.
The following is an example of introducing isaac_ros2_control.</p>
<pre><code class="language-xml">&lt;hardware&gt;
&lt;xacro:if value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;fake_components/GenericSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;xacro:if value=&quot;${use_sim}&quot;&gt;
&lt;plugin&gt;isaac_ros2_control/IsaacSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;/hardware&gt;
<pre><code class="language-xml">&lt;ros2_control&gt;
&lt;hardware&gt;
&lt;xacro:if value=&quot;${use_fake_hardware}&quot;&gt;
&lt;plugin&gt;fake_components/GenericSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;xacro:if value=&quot;${use_sim}&quot;&gt;
&lt;plugin&gt;isaac_ros2_control/IsaacSystem&lt;/plugin&gt;
&lt;/xacro:if&gt;
&lt;/hardware&gt;
&lt;/ros2_control&gt;
</code></pre>
<h2 id="set-up-joint-information">Set up Joint Information</h2>
<p>Within the ros2_control tag in the URDF, joint information must be included in addition to the ros2_control plugin information.
The following is an example of description of joint information.</p>
<pre><code class="language-xml">&lt;joint&gt;
&lt;command_interface name=&quot;velocity&quot;&gt;
&lt;param name=&quot;min&quot;&gt;-1&lt;/param&gt;
&lt;param name=&quot;max&quot;&gt; 1&lt;/param&gt;
&lt;/command_interface&gt;
&lt;state_interface name=&quot;position&quot;/&gt;
&lt;state_interface name=&quot;velocity&quot;/&gt;
&lt;state_interface name=&quot;effort&quot;/&gt;
&lt;/joint&gt;
<pre><code class="language-xml">&lt;ros2_control&gt;
&lt;joint&gt;
&lt;command_interface name=&quot;velocity&quot;&gt;
&lt;param name=&quot;min&quot;&gt;-1&lt;/param&gt;
&lt;param name=&quot;max&quot;&gt; 1&lt;/param&gt;
&lt;/command_interface&gt;
&lt;state_interface name=&quot;position&quot;/&gt;
&lt;state_interface name=&quot;velocity&quot;/&gt;
&lt;state_interface name=&quot;effort&quot;/&gt;
&lt;/joint&gt;
&lt;/ros2_control&gt;
</code></pre>
<p>Note that the joint information used in isaac_ros2_control must contain one command_interface (position or velocity) and three state_interface (position and velocity and effort).</p>
<h2 id="set-up-joint-stiffness-and-damping">Set up Joint Stiffness and Damping</h2>
<p>In Isaac Sim, the force output by the joint is given by</p>
<pre><code>force=stiffness*(position-targetposition)+damping*(velocity-targetvelocity)
</code></pre>
<p>The stiffness and damping are not defined in default URDF.
In this package, they are defined in isaac_drive_api tag in joint tag like below.</p>
<pre><code>&lt;robot&gt;
&lt;joint&gt;
&lt;isaac_drive_api stiffness=&quot;0&quot; damping=&quot;150000&quot;/&gt;
&lt;/joint&gt;
&lt;/robot&gt;
</code></pre>
<p>Note that the joint tag that include the isaac_drive_api tag is not exist in ros2_control tag.</p>
<p>In default behaviour, the stiffness and damping are set zero.</p>



Expand Down Expand Up @@ -1054,7 +1092,7 @@ <h2 id="set-up-joint-information">Set up Joint Information</h2>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Tutorials/setup_urdf_for_sensors/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -1093,7 +1093,7 @@ <h2 id="description-of-depth-camera-information">Description of Depth Camera inf
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
4 changes: 2 additions & 2 deletions Tutorials/tutorial/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@


<link rel="icon" href="../../assets/images/favicon.png">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.12">
<meta name="generator" content="mkdocs-1.5.3, mkdocs-material-9.5.15">



Expand Down Expand Up @@ -953,7 +953,7 @@ <h1 id="tutorials">Tutorials</h1>
<script id="__config" type="application/json">{"base": "../..", "features": [], "search": "../../assets/javascripts/workers/search.b8dbb3d2.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}}</script>


<script src="../../assets/javascripts/bundle.c8d2eff1.min.js"></script>
<script src="../../assets/javascripts/bundle.bd41221c.min.js"></script>


</body>
Expand Down
Loading

0 comments on commit a586714

Please sign in to comment.