4 view display option for display function

This commit is contained in:
Thomas Dehaeze 2020-02-12 14:16:32 +01:00
parent 54f86884d5
commit aad36ca47f
3 changed files with 322 additions and 164 deletions

View File

@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head> <head>
<!-- 2020-02-11 mar. 17:52 --> <!-- 2020-02-12 mer. 14:16 -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Stewart Platform - Definition of the Architecture</title> <title>Stewart Platform - Definition of the Architecture</title>
@ -297,85 +297,85 @@ for the JavaScript code in this tag.
<ul> <ul>
<li><a href="#orgd89f0e1">5.1. <code>initializeStewartPlatform</code>: Initialize the Stewart Platform structure</a> <li><a href="#orgd89f0e1">5.1. <code>initializeStewartPlatform</code>: Initialize the Stewart Platform structure</a>
<ul> <ul>
<li><a href="#org9b53b28">Documentation</a></li> <li><a href="#org7e0b516">Documentation</a></li>
<li><a href="#org43e5d7b">Function description</a></li> <li><a href="#org51076d4">Function description</a></li>
<li><a href="#orgd567fc1">Initialize the Stewart structure</a></li> <li><a href="#orgd567fc1">Initialize the Stewart structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orgb11894c">5.2. <code>initializeFramesPositions</code>: Initialize the positions of frames {A}, {B}, {F} and {M}</a> <li><a href="#orgb11894c">5.2. <code>initializeFramesPositions</code>: Initialize the positions of frames {A}, {B}, {F} and {M}</a>
<ul> <ul>
<li><a href="#org78163aa">Documentation</a></li> <li><a href="#org9ab3ee7">Documentation</a></li>
<li><a href="#org58e74af">Function description</a></li> <li><a href="#org9e0f060">Function description</a></li>
<li><a href="#org75ad918">Optional Parameters</a></li> <li><a href="#org6a57a47">Optional Parameters</a></li>
<li><a href="#org458592e">Compute the position of each frame</a></li> <li><a href="#org458592e">Compute the position of each frame</a></li>
<li><a href="#org29fd7cf">Populate the <code>stewart</code> structure</a></li> <li><a href="#org31b0fc0">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org9057387">5.3. <code>generateGeneralConfiguration</code>: Generate a Very General Configuration</a> <li><a href="#org9057387">5.3. <code>generateGeneralConfiguration</code>: Generate a Very General Configuration</a>
<ul> <ul>
<li><a href="#org304afd4">Documentation</a></li> <li><a href="#org0272259">Documentation</a></li>
<li><a href="#orgdbbe92d">Function description</a></li> <li><a href="#orgbd08cb7">Function description</a></li>
<li><a href="#orgc9aa5c6">Optional Parameters</a></li> <li><a href="#orgfade903">Optional Parameters</a></li>
<li><a href="#org232e4c2">Compute the pose</a></li> <li><a href="#org232e4c2">Compute the pose</a></li>
<li><a href="#org1af60d1">Populate the <code>stewart</code> structure</a></li> <li><a href="#org67d9f70">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org861f6de">5.4. <code>computeJointsPose</code>: Compute the Pose of the Joints</a> <li><a href="#org861f6de">5.4. <code>computeJointsPose</code>: Compute the Pose of the Joints</a>
<ul> <ul>
<li><a href="#orgc791fb6">Documentation</a></li> <li><a href="#org7f013d7">Documentation</a></li>
<li><a href="#org07a9faa">Function description</a></li> <li><a href="#orgfb0d4ad">Function description</a></li>
<li><a href="#org1873f06">Check the <code>stewart</code> structure elements</a></li> <li><a href="#org7bc221e">Check the <code>stewart</code> structure elements</a></li>
<li><a href="#org52b0d4c">Compute the position of the Joints</a></li> <li><a href="#org52b0d4c">Compute the position of the Joints</a></li>
<li><a href="#org4b76b0f">Compute the strut length and orientation</a></li> <li><a href="#org4b76b0f">Compute the strut length and orientation</a></li>
<li><a href="#orgd621d5e">Compute the orientation of the Joints</a></li> <li><a href="#orgd621d5e">Compute the orientation of the Joints</a></li>
<li><a href="#orgbe4fa22">Populate the <code>stewart</code> structure</a></li> <li><a href="#orgc7895ed">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org329bef9">5.5. <code>initializeStewartPose</code>: Determine the initial stroke in each leg to have the wanted pose</a> <li><a href="#org329bef9">5.5. <code>initializeStewartPose</code>: Determine the initial stroke in each leg to have the wanted pose</a>
<ul> <ul>
<li><a href="#orga659915">Function description</a></li> <li><a href="#org67023b1">Function description</a></li>
<li><a href="#orge99ec9f">Optional Parameters</a></li> <li><a href="#org1173285">Optional Parameters</a></li>
<li><a href="#org3d3ef62">Use the Inverse Kinematic function</a></li> <li><a href="#org3d3ef62">Use the Inverse Kinematic function</a></li>
<li><a href="#org6a8b77e">Populate the <code>stewart</code> structure</a></li> <li><a href="#orgd1a2f9c">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org6ff5b31">5.6. <code>initializeCylindricalPlatforms</code>: Initialize the geometry of the Fixed and Mobile Platforms</a> <li><a href="#org6ff5b31">5.6. <code>initializeCylindricalPlatforms</code>: Initialize the geometry of the Fixed and Mobile Platforms</a>
<ul> <ul>
<li><a href="#org70b7362">Function description</a></li> <li><a href="#orge50412f">Function description</a></li>
<li><a href="#orgee6ed82">Optional Parameters</a></li> <li><a href="#org0be1736">Optional Parameters</a></li>
<li><a href="#org25a390a">Compute the Inertia matrices of platforms</a></li> <li><a href="#org25a390a">Compute the Inertia matrices of platforms</a></li>
<li><a href="#org19d03f1">Populate the <code>stewart</code> structure</a></li> <li><a href="#org7396a3c">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org60aa215">5.7. <code>initializeCylindricalStruts</code>: Define the inertia of cylindrical struts</a> <li><a href="#org60aa215">5.7. <code>initializeCylindricalStruts</code>: Define the inertia of cylindrical struts</a>
<ul> <ul>
<li><a href="#org686a076">Function description</a></li> <li><a href="#org3e05aa9">Function description</a></li>
<li><a href="#orgda13332">Optional Parameters</a></li> <li><a href="#org0447834">Optional Parameters</a></li>
<li><a href="#orgc056498">Compute the properties of the cylindrical struts</a></li> <li><a href="#orgc056498">Compute the properties of the cylindrical struts</a></li>
<li><a href="#org601053b">Populate the <code>stewart</code> structure</a></li> <li><a href="#org3e2ac57">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org3ad0cd1">5.8. <code>initializeStrutDynamics</code>: Add Stiffness and Damping properties of each strut</a> <li><a href="#org3ad0cd1">5.8. <code>initializeStrutDynamics</code>: Add Stiffness and Damping properties of each strut</a>
<ul> <ul>
<li><a href="#orgdb94cd8">Documentation</a></li> <li><a href="#org53a2929">Documentation</a></li>
<li><a href="#org38928ae">Function description</a></li> <li><a href="#org1ab40de">Function description</a></li>
<li><a href="#org5d465fb">Optional Parameters</a></li> <li><a href="#org21f3e3c">Optional Parameters</a></li>
<li><a href="#orgadb8327">Add Stiffness and Damping properties of each strut</a></li> <li><a href="#orgadb8327">Add Stiffness and Damping properties of each strut</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orgd8d403e">5.9. <code>initializeAmplifiedStrutDynamics</code>: Add Stiffness and Damping properties of each strut for an amplified piezoelectric actuator</a> <li><a href="#orgd8d403e">5.9. <code>initializeAmplifiedStrutDynamics</code>: Add Stiffness and Damping properties of each strut for an amplified piezoelectric actuator</a>
<ul> <ul>
<li><a href="#org7e0b516">Documentation</a></li> <li><a href="#org2d49efc">Documentation</a></li>
<li><a href="#orgd36c473">Function description</a></li> <li><a href="#orga83094e">Function description</a></li>
<li><a href="#org3cae5a2">Optional Parameters</a></li> <li><a href="#orgf97e68f">Optional Parameters</a></li>
<li><a href="#org9b435e8">Compute the total stiffness and damping</a></li> <li><a href="#org9b435e8">Compute the total stiffness and damping</a></li>
<li><a href="#org6cc3cd5">Populate the <code>stewart</code> structure</a></li> <li><a href="#org2ca28bc">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#orgeb6173a">5.10. <code>initializeJointDynamics</code>: Add Stiffness and Damping properties for spherical joints</a> <li><a href="#orgeb6173a">5.10. <code>initializeJointDynamics</code>: Add Stiffness and Damping properties for spherical joints</a>
<ul> <ul>
<li><a href="#org8a14eeb">Function description</a></li> <li><a href="#org92a2eb6">Function description</a></li>
<li><a href="#orgcfba56a">Optional Parameters</a></li> <li><a href="#org6de493f">Optional Parameters</a></li>
<li><a href="#orgc6d4183">Add Actuator Type</a></li> <li><a href="#orgc6d4183">Add Actuator Type</a></li>
<li><a href="#orgc0e613c">Add Stiffness and Damping in Translation of each strut</a></li> <li><a href="#orgc0e613c">Add Stiffness and Damping in Translation of each strut</a></li>
<li><a href="#org04698fc">Add Stiffness and Damping in Rotation of each strut</a></li> <li><a href="#org04698fc">Add Stiffness and Damping in Rotation of each strut</a></li>
@ -383,22 +383,23 @@ for the JavaScript code in this tag.
</li> </li>
<li><a href="#orgea07e0e">5.11. <code>initializeInertialSensor</code>: Initialize the inertial sensor in each strut</a> <li><a href="#orgea07e0e">5.11. <code>initializeInertialSensor</code>: Initialize the inertial sensor in each strut</a>
<ul> <ul>
<li><a href="#orgd686f52">Function description</a></li> <li><a href="#org33251d6">Function description</a></li>
<li><a href="#org57e140f">Optional Parameters</a></li> <li><a href="#org405e558">Optional Parameters</a></li>
<li><a href="#org463075d">Compute the properties of the sensor</a></li> <li><a href="#org463075d">Compute the properties of the sensor</a></li>
<li><a href="#org31b0fc0">Populate the <code>stewart</code> structure</a></li> <li><a href="#orgfd7f4a6">Populate the <code>stewart</code> structure</a></li>
</ul> </ul>
</li> </li>
<li><a href="#org5266e9d">5.12. <code>displayArchitecture</code>: 3D plot of the Stewart platform architecture</a> <li><a href="#org5266e9d">5.12. <code>displayArchitecture</code>: 3D plot of the Stewart platform architecture</a>
<ul> <ul>
<li><a href="#org51076d4">Function description</a></li> <li><a href="#orgbbfef24">Function description</a></li>
<li><a href="#org6a57a47">Optional Parameters</a></li> <li><a href="#orgf940506">Optional Parameters</a></li>
<li><a href="#org7bc221e">Check the <code>stewart</code> structure elements</a></li> <li><a href="#org12d315f">Check the <code>stewart</code> structure elements</a></li>
<li><a href="#orgc088b18">Figure Creation, Frames and Homogeneous transformations</a></li> <li><a href="#orgc088b18">Figure Creation, Frames and Homogeneous transformations</a></li>
<li><a href="#orgc25a979">Fixed Base elements</a></li> <li><a href="#orgc25a979">Fixed Base elements</a></li>
<li><a href="#org8417772">Mobile Platform elements</a></li> <li><a href="#org8417772">Mobile Platform elements</a></li>
<li><a href="#org5f40b79">Legs</a></li> <li><a href="#org5f40b79">Legs</a></li>
<li><a href="#org81be27b">5.12.1. Figure parameters</a></li> <li><a href="#org81be27b">5.12.1. Figure parameters</a></li>
<li><a href="#orgf41db0f">5.12.2. Subplots</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -768,7 +769,7 @@ The obtained <code>stewart</code> Matlab structure contains all the information
The function <code>displayArchitecture</code> can be used to display the current Stewart configuration: The function <code>displayArchitecture</code> can be used to display the current Stewart configuration:
</p> </p>
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">displayArchitecture(stewart); <pre class="src src-matlab">displayArchitecture(stewart, <span class="org-string">'views'</span>, <span class="org-string">'all'</span>);
</pre> </pre>
</div> </div>
@ -842,11 +843,11 @@ This Matlab function is accessible <a href="../src/initializeStewartPlatform.m">
</p> </p>
</div> </div>
<div id="outline-container-org9b53b28" class="outline-4"> <div id="outline-container-org7e0b516" class="outline-4">
<h4 id="org9b53b28">Documentation</h4> <h4 id="org7e0b516">Documentation</h4>
<div class="outline-text-4" id="text-org9b53b28"> <div class="outline-text-4" id="text-org7e0b516">
<div id="org31aa0ac" class="figure"> <div id="org405cd8e" class="figure">
<p><img src="figs/stewart-frames-position.png" alt="stewart-frames-position.png" /> <p><img src="figs/stewart-frames-position.png" alt="stewart-frames-position.png" />
</p> </p>
<p><span class="figure-number">Figure 7: </span>Definition of the position of the frames</p> <p><span class="figure-number">Figure 7: </span>Definition of the position of the frames</p>
@ -854,9 +855,9 @@ This Matlab function is accessible <a href="../src/initializeStewartPlatform.m">
</div> </div>
</div> </div>
<div id="outline-container-org43e5d7b" class="outline-4"> <div id="outline-container-org51076d4" class="outline-4">
<h4 id="org43e5d7b">Function description</h4> <h4 id="org51076d4">Function description</h4>
<div class="outline-text-4" id="text-org43e5d7b"> <div class="outline-text-4" id="text-org51076d4">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStewartPlatform</span>() <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStewartPlatform</span>()
<span class="org-comment">% initializeStewartPlatform - Initialize the stewart structure</span> <span class="org-comment">% initializeStewartPlatform - Initialize the stewart structure</span>
@ -915,11 +916,11 @@ This Matlab function is accessible <a href="../src/initializeFramesPositions.m">
</p> </p>
</div> </div>
<div id="outline-container-org78163aa" class="outline-4"> <div id="outline-container-org9ab3ee7" class="outline-4">
<h4 id="org78163aa">Documentation</h4> <h4 id="org9ab3ee7">Documentation</h4>
<div class="outline-text-4" id="text-org78163aa"> <div class="outline-text-4" id="text-org9ab3ee7">
<div id="org405cd8e" class="figure"> <div id="orgf487bc2" class="figure">
<p><img src="figs/stewart-frames-position.png" alt="stewart-frames-position.png" /> <p><img src="figs/stewart-frames-position.png" alt="stewart-frames-position.png" />
</p> </p>
<p><span class="figure-number">Figure 8: </span>Definition of the position of the frames</p> <p><span class="figure-number">Figure 8: </span>Definition of the position of the frames</p>
@ -927,9 +928,9 @@ This Matlab function is accessible <a href="../src/initializeFramesPositions.m">
</div> </div>
</div> </div>
<div id="outline-container-org58e74af" class="outline-4"> <div id="outline-container-org9e0f060" class="outline-4">
<h4 id="org58e74af">Function description</h4> <h4 id="org9e0f060">Function description</h4>
<div class="outline-text-4" id="text-org58e74af"> <div class="outline-text-4" id="text-org9e0f060">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeFramesPositions</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeFramesPositions</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeFramesPositions - Initialize the positions of frames {A}, {B}, {F} and {M}</span> <span class="org-comment">% initializeFramesPositions - Initialize the positions of frames {A}, {B}, {F} and {M}</span>
@ -952,9 +953,9 @@ This Matlab function is accessible <a href="../src/initializeFramesPositions.m">
</div> </div>
</div> </div>
<div id="outline-container-org75ad918" class="outline-4"> <div id="outline-container-org6a57a47" class="outline-4">
<h4 id="org75ad918">Optional Parameters</h4> <h4 id="org6a57a47">Optional Parameters</h4>
<div class="outline-text-4" id="text-org75ad918"> <div class="outline-text-4" id="text-org6a57a47">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -982,9 +983,9 @@ FO_A = MO_B <span class="org-type">+</span> FO_M; <span class="org-comment">% Po
</div> </div>
</div> </div>
<div id="outline-container-org29fd7cf" class="outline-4"> <div id="outline-container-org31b0fc0" class="outline-4">
<h4 id="org29fd7cf">Populate the <code>stewart</code> structure</h4> <h4 id="org31b0fc0">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org29fd7cf"> <div class="outline-text-4" id="text-org31b0fc0">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.geometry.H = H; <pre class="src src-matlab">stewart.geometry.H = H;
stewart.geometry.FO_M = FO_M; stewart.geometry.FO_M = FO_M;
@ -1008,9 +1009,9 @@ This Matlab function is accessible <a href="../src/generateGeneralConfiguration.
</p> </p>
</div> </div>
<div id="outline-container-org304afd4" class="outline-4"> <div id="outline-container-org0272259" class="outline-4">
<h4 id="org304afd4">Documentation</h4> <h4 id="org0272259">Documentation</h4>
<div class="outline-text-4" id="text-org304afd4"> <div class="outline-text-4" id="text-org0272259">
<p> <p>
Joints are positions on a circle centered with the Z axis of {F} and {M} and at a chosen distance from {F} and {M}. Joints are positions on a circle centered with the Z axis of {F} and {M} and at a chosen distance from {F} and {M}.
The radius of the circles can be chosen as well as the angles where the joints are located (see Figure <a href="#org4c354b6">9</a>). The radius of the circles can be chosen as well as the angles where the joints are located (see Figure <a href="#org4c354b6">9</a>).
@ -1025,9 +1026,9 @@ The radius of the circles can be chosen as well as the angles where the joints a
</div> </div>
</div> </div>
<div id="outline-container-orgdbbe92d" class="outline-4"> <div id="outline-container-orgbd08cb7" class="outline-4">
<h4 id="orgdbbe92d">Function description</h4> <h4 id="orgbd08cb7">Function description</h4>
<div class="outline-text-4" id="text-orgdbbe92d"> <div class="outline-text-4" id="text-orgbd08cb7">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">generateGeneralConfiguration</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">generateGeneralConfiguration</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% generateGeneralConfiguration - Generate a Very General Configuration</span> <span class="org-comment">% generateGeneralConfiguration - Generate a Very General Configuration</span>
@ -1052,9 +1053,9 @@ The radius of the circles can be chosen as well as the angles where the joints a
</div> </div>
</div> </div>
<div id="outline-container-orgc9aa5c6" class="outline-4"> <div id="outline-container-orgfade903" class="outline-4">
<h4 id="orgc9aa5c6">Optional Parameters</h4> <h4 id="orgfade903">Optional Parameters</h4>
<div class="outline-text-4" id="text-orgc9aa5c6"> <div class="outline-text-4" id="text-orgfade903">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1089,9 +1090,9 @@ Mb = zeros(3,6);
</div> </div>
</div> </div>
<div id="outline-container-org1af60d1" class="outline-4"> <div id="outline-container-org67d9f70" class="outline-4">
<h4 id="org1af60d1">Populate the <code>stewart</code> structure</h4> <h4 id="org67d9f70">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org1af60d1"> <div class="outline-text-4" id="text-org67d9f70">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.platform_F.Fa = Fa; <pre class="src src-matlab">stewart.platform_F.Fa = Fa;
stewart.platform_M.Mb = Mb; stewart.platform_M.Mb = Mb;
@ -1113,9 +1114,9 @@ This Matlab function is accessible <a href="../src/computeJointsPose.m">here</a>
</p> </p>
</div> </div>
<div id="outline-container-orgc791fb6" class="outline-4"> <div id="outline-container-org7f013d7" class="outline-4">
<h4 id="orgc791fb6">Documentation</h4> <h4 id="org7f013d7">Documentation</h4>
<div class="outline-text-4" id="text-orgc791fb6"> <div class="outline-text-4" id="text-org7f013d7">
<div id="org8ffb841" class="figure"> <div id="org8ffb841" class="figure">
<p><img src="figs/stewart-struts.png" alt="stewart-struts.png" /> <p><img src="figs/stewart-struts.png" alt="stewart-struts.png" />
@ -1125,9 +1126,9 @@ This Matlab function is accessible <a href="../src/computeJointsPose.m">here</a>
</div> </div>
</div> </div>
<div id="outline-container-org07a9faa" class="outline-4"> <div id="outline-container-orgfb0d4ad" class="outline-4">
<h4 id="org07a9faa">Function description</h4> <h4 id="orgfb0d4ad">Function description</h4>
<div class="outline-text-4" id="text-org07a9faa"> <div class="outline-text-4" id="text-orgfb0d4ad">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">computeJointsPose</span>(<span class="org-variable-name">stewart</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">computeJointsPose</span>(<span class="org-variable-name">stewart</span>)
<span class="org-comment">% computeJointsPose -</span> <span class="org-comment">% computeJointsPose -</span>
@ -1160,9 +1161,9 @@ This Matlab function is accessible <a href="../src/computeJointsPose.m">here</a>
</div> </div>
</div> </div>
<div id="outline-container-org1873f06" class="outline-4"> <div id="outline-container-org7bc221e" class="outline-4">
<h4 id="org1873f06">Check the <code>stewart</code> structure elements</h4> <h4 id="org7bc221e">Check the <code>stewart</code> structure elements</h4>
<div class="outline-text-4" id="text-org1873f06"> <div class="outline-text-4" id="text-org7bc221e">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">assert(isfield(stewart.platform_F, <span class="org-string">'Fa'</span>), <span class="org-string">'stewart.platform_F should have attribute Fa'</span>) <pre class="src src-matlab">assert(isfield(stewart.platform_F, <span class="org-string">'Fa'</span>), <span class="org-string">'stewart.platform_F should have attribute Fa'</span>)
Fa = stewart.platform_F.Fa; Fa = stewart.platform_F.Fa;
@ -1233,9 +1234,9 @@ MRb = zeros(3,3,6);
</div> </div>
</div> </div>
<div id="outline-container-orgbe4fa22" class="outline-4"> <div id="outline-container-orgc7895ed" class="outline-4">
<h4 id="orgbe4fa22">Populate the <code>stewart</code> structure</h4> <h4 id="orgc7895ed">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-orgbe4fa22"> <div class="outline-text-4" id="text-orgc7895ed">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.geometry.Aa = Aa; <pre class="src src-matlab">stewart.geometry.Aa = Aa;
stewart.geometry.Ab = Ab; stewart.geometry.Ab = Ab;
@ -1268,9 +1269,9 @@ This Matlab function is accessible <a href="../src/initializeStewartPose.m">here
</p> </p>
</div> </div>
<div id="outline-container-orga659915" class="outline-4"> <div id="outline-container-org67023b1" class="outline-4">
<h4 id="orga659915">Function description</h4> <h4 id="org67023b1">Function description</h4>
<div class="outline-text-4" id="text-orga659915"> <div class="outline-text-4" id="text-org67023b1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStewartPose</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStewartPose</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeStewartPose - Determine the initial stroke in each leg to have the wanted pose</span> <span class="org-comment">% initializeStewartPose - Determine the initial stroke in each leg to have the wanted pose</span>
@ -1294,9 +1295,9 @@ This Matlab function is accessible <a href="../src/initializeStewartPose.m">here
</div> </div>
</div> </div>
<div id="outline-container-orge99ec9f" class="outline-4"> <div id="outline-container-org1173285" class="outline-4">
<h4 id="orge99ec9f">Optional Parameters</h4> <h4 id="org1173285">Optional Parameters</h4>
<div class="outline-text-4" id="text-orge99ec9f"> <div class="outline-text-4" id="text-org1173285">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1318,9 +1319,9 @@ This Matlab function is accessible <a href="../src/initializeStewartPose.m">here
</div> </div>
</div> </div>
<div id="outline-container-org6a8b77e" class="outline-4"> <div id="outline-container-orgd1a2f9c" class="outline-4">
<h4 id="org6a8b77e">Populate the <code>stewart</code> structure</h4> <h4 id="orgd1a2f9c">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org6a8b77e"> <div class="outline-text-4" id="text-orgd1a2f9c">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.actuators.Leq = dLi; <pre class="src src-matlab">stewart.actuators.Leq = dLi;
</pre> </pre>
@ -1341,9 +1342,9 @@ This Matlab function is accessible <a href="../src/initializeCylindricalPlatform
</p> </p>
</div> </div>
<div id="outline-container-org70b7362" class="outline-4"> <div id="outline-container-orge50412f" class="outline-4">
<h4 id="org70b7362">Function description</h4> <h4 id="orge50412f">Function description</h4>
<div class="outline-text-4" id="text-org70b7362"> <div class="outline-text-4" id="text-orge50412f">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeCylindricalPlatforms</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeCylindricalPlatforms</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeCylindricalPlatforms - Initialize the geometry of the Fixed and Mobile Platforms</span> <span class="org-comment">% initializeCylindricalPlatforms - Initialize the geometry of the Fixed and Mobile Platforms</span>
@ -1377,9 +1378,9 @@ This Matlab function is accessible <a href="../src/initializeCylindricalPlatform
</div> </div>
</div> </div>
<div id="outline-container-orgee6ed82" class="outline-4"> <div id="outline-container-org0be1736" class="outline-4">
<h4 id="orgee6ed82">Optional Parameters</h4> <h4 id="org0be1736">Optional Parameters</h4>
<div class="outline-text-4" id="text-orgee6ed82"> <div class="outline-text-4" id="text-org0be1736">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1414,9 +1415,9 @@ This Matlab function is accessible <a href="../src/initializeCylindricalPlatform
</div> </div>
</div> </div>
<div id="outline-container-org19d03f1" class="outline-4"> <div id="outline-container-org7396a3c" class="outline-4">
<h4 id="org19d03f1">Populate the <code>stewart</code> structure</h4> <h4 id="org7396a3c">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org19d03f1"> <div class="outline-text-4" id="text-org7396a3c">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.platform_F.type = 1; <pre class="src src-matlab">stewart.platform_F.type = 1;
@ -1452,9 +1453,9 @@ This Matlab function is accessible <a href="../src/initializeCylindricalStruts.m
</p> </p>
</div> </div>
<div id="outline-container-org686a076" class="outline-4"> <div id="outline-container-org3e05aa9" class="outline-4">
<h4 id="org686a076">Function description</h4> <h4 id="org3e05aa9">Function description</h4>
<div class="outline-text-4" id="text-org686a076"> <div class="outline-text-4" id="text-org3e05aa9">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeCylindricalStruts</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeCylindricalStruts</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeCylindricalStruts - Define the mass and moment of inertia of cylindrical struts</span> <span class="org-comment">% initializeCylindricalStruts - Define the mass and moment of inertia of cylindrical struts</span>
@ -1487,9 +1488,9 @@ This Matlab function is accessible <a href="../src/initializeCylindricalStruts.m
</div> </div>
</div> </div>
<div id="outline-container-orgda13332" class="outline-4"> <div id="outline-container-org0447834" class="outline-4">
<h4 id="orgda13332">Optional Parameters</h4> <h4 id="org0447834">Optional Parameters</h4>
<div class="outline-text-4" id="text-orgda13332"> <div class="outline-text-4" id="text-org0447834">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1537,9 +1538,9 @@ I_M = zeros(3, 3, 6); <span class="org-comment">% Inertia of the "mobile" part o
</div> </div>
</div> </div>
<div id="outline-container-org601053b" class="outline-4"> <div id="outline-container-org3e2ac57" class="outline-4">
<h4 id="org601053b">Populate the <code>stewart</code> structure</h4> <h4 id="org3e2ac57">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org601053b"> <div class="outline-text-4" id="text-org3e2ac57">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.struts_M.type = 1; <pre class="src src-matlab">stewart.struts_M.type = 1;
@ -1575,9 +1576,9 @@ This Matlab function is accessible <a href="../src/initializeStrutDynamics.m">he
</p> </p>
</div> </div>
<div id="outline-container-orgdb94cd8" class="outline-4"> <div id="outline-container-org53a2929" class="outline-4">
<h4 id="orgdb94cd8">Documentation</h4> <h4 id="org53a2929">Documentation</h4>
<div class="outline-text-4" id="text-orgdb94cd8"> <div class="outline-text-4" id="text-org53a2929">
<div id="orgbbfb204" class="figure"> <div id="orgbbfb204" class="figure">
<p><img src="figs/piezoelectric_stack.jpg" alt="piezoelectric_stack.jpg" width="500px" /> <p><img src="figs/piezoelectric_stack.jpg" alt="piezoelectric_stack.jpg" width="500px" />
@ -1606,9 +1607,9 @@ A simplistic model of such amplified actuator is shown in Figure <a href="#org62
</div> </div>
</div> </div>
<div id="outline-container-org38928ae" class="outline-4"> <div id="outline-container-org1ab40de" class="outline-4">
<h4 id="org38928ae">Function description</h4> <h4 id="org1ab40de">Function description</h4>
<div class="outline-text-4" id="text-org38928ae"> <div class="outline-text-4" id="text-org1ab40de">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStrutDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeStrutDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeStrutDynamics - Add Stiffness and Damping properties of each strut</span> <span class="org-comment">% initializeStrutDynamics - Add Stiffness and Damping properties of each strut</span>
@ -1630,9 +1631,9 @@ A simplistic model of such amplified actuator is shown in Figure <a href="#org62
</div> </div>
</div> </div>
<div id="outline-container-org5d465fb" class="outline-4"> <div id="outline-container-org21f3e3c" class="outline-4">
<h4 id="org5d465fb">Optional Parameters</h4> <h4 id="org21f3e3c">Optional Parameters</h4>
<div class="outline-text-4" id="text-org5d465fb"> <div class="outline-text-4" id="text-org21f3e3c">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1670,9 +1671,9 @@ This Matlab function is accessible <a href="../src/initializeAmplifiedStrutDynam
</p> </p>
</div> </div>
<div id="outline-container-org7e0b516" class="outline-4"> <div id="outline-container-org2d49efc" class="outline-4">
<h4 id="org7e0b516">Documentation</h4> <h4 id="org2d49efc">Documentation</h4>
<div class="outline-text-4" id="text-org7e0b516"> <div class="outline-text-4" id="text-org2d49efc">
<p> <p>
An amplified piezoelectric actuator is shown in Figure <a href="#org9e7e9ad">13</a>. An amplified piezoelectric actuator is shown in Figure <a href="#org9e7e9ad">13</a>.
</p> </p>
@ -1705,9 +1706,9 @@ A simplistic model of such amplified actuator is shown in Figure <a href="#orgcf
</div> </div>
</div> </div>
<div id="outline-container-orgd36c473" class="outline-4"> <div id="outline-container-orga83094e" class="outline-4">
<h4 id="orgd36c473">Function description</h4> <h4 id="orga83094e">Function description</h4>
<div class="outline-text-4" id="text-orgd36c473"> <div class="outline-text-4" id="text-orga83094e">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeAmplifiedStrutDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeAmplifiedStrutDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeAmplifiedStrutDynamics - Add Stiffness and Damping properties of each strut</span> <span class="org-comment">% initializeAmplifiedStrutDynamics - Add Stiffness and Damping properties of each strut</span>
@ -1735,9 +1736,9 @@ A simplistic model of such amplified actuator is shown in Figure <a href="#orgcf
</div> </div>
</div> </div>
<div id="outline-container-org3cae5a2" class="outline-4"> <div id="outline-container-orgf97e68f" class="outline-4">
<h4 id="org3cae5a2">Optional Parameters</h4> <h4 id="orgf97e68f">Optional Parameters</h4>
<div class="outline-text-4" id="text-org3cae5a2"> <div class="outline-text-4" id="text-orgf97e68f">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1762,9 +1763,9 @@ C = args.Ca <span class="org-type">+</span> args.Cr;
</div> </div>
</div> </div>
<div id="outline-container-org6cc3cd5" class="outline-4"> <div id="outline-container-org2ca28bc" class="outline-4">
<h4 id="org6cc3cd5">Populate the <code>stewart</code> structure</h4> <h4 id="org2ca28bc">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org6cc3cd5"> <div class="outline-text-4" id="text-org2ca28bc">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.actuators.type = 2; <pre class="src src-matlab">stewart.actuators.type = 2;
@ -1794,9 +1795,9 @@ This Matlab function is accessible <a href="../src/initializeJointDynamics.m">he
</p> </p>
</div> </div>
<div id="outline-container-org8a14eeb" class="outline-4"> <div id="outline-container-org92a2eb6" class="outline-4">
<h4 id="org8a14eeb">Function description</h4> <h4 id="org92a2eb6">Function description</h4>
<div class="outline-text-4" id="text-org8a14eeb"> <div class="outline-text-4" id="text-org92a2eb6">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeJointDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeJointDynamics</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeJointDynamics - Add Stiffness and Damping properties for the spherical joints</span> <span class="org-comment">% initializeJointDynamics - Add Stiffness and Damping properties for the spherical joints</span>
@ -1831,9 +1832,9 @@ This Matlab function is accessible <a href="../src/initializeJointDynamics.m">he
</div> </div>
</div> </div>
<div id="outline-container-orgcfba56a" class="outline-4"> <div id="outline-container-org6de493f" class="outline-4">
<h4 id="orgcfba56a">Optional Parameters</h4> <h4 id="org6de493f">Optional Parameters</h4>
<div class="outline-text-4" id="text-orgcfba56a"> <div class="outline-text-4" id="text-org6de493f">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -1959,9 +1960,9 @@ This Matlab function is accessible <a href="../src/initializeInertialSensor.m">h
</p> </p>
</div> </div>
<div id="outline-container-orgd686f52" class="outline-4"> <div id="outline-container-org33251d6" class="outline-4">
<h4 id="orgd686f52">Function description</h4> <h4 id="org33251d6">Function description</h4>
<div class="outline-text-4" id="text-orgd686f52"> <div class="outline-text-4" id="text-org33251d6">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeInertialSensor</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[stewart]</span> = <span class="org-function-name">initializeInertialSensor</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% initializeInertialSensor - Initialize the inertial sensor in each strut</span> <span class="org-comment">% initializeInertialSensor - Initialize the inertial sensor in each strut</span>
@ -1987,9 +1988,9 @@ This Matlab function is accessible <a href="../src/initializeInertialSensor.m">h
</div> </div>
</div> </div>
<div id="outline-container-org57e140f" class="outline-4"> <div id="outline-container-org405e558" class="outline-4">
<h4 id="org57e140f">Optional Parameters</h4> <h4 id="org405e558">Optional Parameters</h4>
<div class="outline-text-4" id="text-org57e140f"> <div class="outline-text-4" id="text-org405e558">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -2030,9 +2031,9 @@ This Matlab function is accessible <a href="../src/initializeInertialSensor.m">h
</div> </div>
</div> </div>
<div id="outline-container-org31b0fc0" class="outline-4"> <div id="outline-container-orgfd7f4a6" class="outline-4">
<h4 id="org31b0fc0">Populate the <code>stewart</code> structure</h4> <h4 id="orgfd7f4a6">Populate the <code>stewart</code> structure</h4>
<div class="outline-text-4" id="text-org31b0fc0"> <div class="outline-text-4" id="text-orgfd7f4a6">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">stewart.sensors.inertial = sensor; <pre class="src src-matlab">stewart.sensors.inertial = sensor;
</pre> </pre>
@ -2053,9 +2054,9 @@ This Matlab function is accessible <a href="../src/displayArchitecture.m">here</
</p> </p>
</div> </div>
<div id="outline-container-org51076d4" class="outline-4"> <div id="outline-container-orgbbfef24" class="outline-4">
<h4 id="org51076d4">Function description</h4> <h4 id="orgbbfef24">Function description</h4>
<div class="outline-text-4" id="text-org51076d4"> <div class="outline-text-4" id="text-orgbbfef24">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[]</span> = <span class="org-function-name">displayArchitecture</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>) <pre class="src src-matlab"><span class="org-keyword">function</span> <span class="org-variable-name">[]</span> = <span class="org-function-name">displayArchitecture</span>(<span class="org-variable-name">stewart</span>, <span class="org-variable-name">args</span>)
<span class="org-comment">% displayArchitecture - 3D plot of the Stewart platform architecture</span> <span class="org-comment">% displayArchitecture - 3D plot of the Stewart platform architecture</span>
@ -2076,6 +2077,7 @@ This Matlab function is accessible <a href="../src/displayArchitecture.m">here</
<span class="org-comment">% - joints [true/false] - Display the Joints</span> <span class="org-comment">% - joints [true/false] - Display the Joints</span>
<span class="org-comment">% - labels [true/false] - Display the Labels</span> <span class="org-comment">% - labels [true/false] - Display the Labels</span>
<span class="org-comment">% - platforms [true/false] - Display the Platforms</span> <span class="org-comment">% - platforms [true/false] - Display the Platforms</span>
<span class="org-comment">% - views ['all', 'xy', 'yz', 'xz', 'default'] -</span>
<span class="org-comment">%</span> <span class="org-comment">%</span>
<span class="org-comment">% Outputs:</span> <span class="org-comment">% Outputs:</span>
</pre> </pre>
@ -2083,9 +2085,9 @@ This Matlab function is accessible <a href="../src/displayArchitecture.m">here</
</div> </div>
</div> </div>
<div id="outline-container-org6a57a47" class="outline-4"> <div id="outline-container-orgf940506" class="outline-4">
<h4 id="org6a57a47">Optional Parameters</h4> <h4 id="orgf940506">Optional Parameters</h4>
<div class="outline-text-4" id="text-org6a57a47"> <div class="outline-text-4" id="text-orgf940506">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">arguments <pre class="src src-matlab">arguments
stewart stewart
@ -2099,15 +2101,16 @@ This Matlab function is accessible <a href="../src/displayArchitecture.m">here</
args.joints logical {mustBeNumericOrLogical} = <span class="org-constant">true</span> args.joints logical {mustBeNumericOrLogical} = <span class="org-constant">true</span>
args.labels logical {mustBeNumericOrLogical} = <span class="org-constant">true</span> args.labels logical {mustBeNumericOrLogical} = <span class="org-constant">true</span>
args.platforms logical {mustBeNumericOrLogical} = <span class="org-constant">true</span> args.platforms logical {mustBeNumericOrLogical} = <span class="org-constant">true</span>
args.views char {mustBeMember(args.views,{<span class="org-string">'all'</span>, <span class="org-string">'xy'</span>, <span class="org-string">'xz'</span>, <span class="org-string">'yz'</span>, <span class="org-string">'default'</span>})} = <span class="org-string">'default'</span>
<span class="org-keyword">end</span> <span class="org-keyword">end</span>
</pre> </pre>
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-org7bc221e" class="outline-4"> <div id="outline-container-org12d315f" class="outline-4">
<h4 id="org7bc221e">Check the <code>stewart</code> structure elements</h4> <h4 id="org12d315f">Check the <code>stewart</code> structure elements</h4>
<div class="outline-text-4" id="text-org7bc221e"> <div class="outline-text-4" id="text-org12d315f">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">assert(isfield(stewart.platform_F, <span class="org-string">'FO_A'</span>), <span class="org-string">'stewart.platform_F should have attribute FO_A'</span>) <pre class="src src-matlab">assert(isfield(stewart.platform_F, <span class="org-string">'FO_A'</span>), <span class="org-string">'stewart.platform_F should have attribute FO_A'</span>)
FO_A = stewart.platform_F.FO_A; FO_A = stewart.platform_F.FO_A;
@ -2136,7 +2139,12 @@ Mb = stewart.platform_M.Mb;
The reference frame of the 3d plot corresponds to the frame \(\{F\}\). The reference frame of the 3d plot corresponds to the frame \(\{F\}\).
</p> </p>
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab"><span class="org-type">figure</span>; <pre class="src src-matlab"><span class="org-keyword">if</span> <span class="org-type">~</span>strcmp(args.views, <span class="org-string">'all'</span>)
<span class="org-type">figure</span>;
<span class="org-keyword">else</span>
f = <span class="org-type">figure</span>(<span class="org-string">'visible'</span>, <span class="org-string">'off'</span>);
<span class="org-keyword">end</span>
hold on; hold on;
</pre> </pre>
</div> </div>
@ -2367,15 +2375,65 @@ Plot the legs connecting the joints of the fixed base to the joints of the mobil
<h4 id="org81be27b"><span class="section-number-4">5.12.1</span> Figure parameters</h4> <h4 id="org81be27b"><span class="section-number-4">5.12.1</span> Figure parameters</h4>
<div class="outline-text-4" id="text-5-12-1"> <div class="outline-text-4" id="text-5-12-1">
<div class="org-src-container"> <div class="org-src-container">
<pre class="src src-matlab">view([1 <span class="org-type">-</span>0.6 0.4]); <pre class="src src-matlab"><span class="org-keyword">switch</span> <span class="org-constant">args.views</span>
<span class="org-keyword">case</span> <span class="org-string">'default'</span>
view([1 <span class="org-type">-</span>0.6 0.4]);
<span class="org-keyword">case</span> <span class="org-string">'xy'</span>
view([0 0 1]);
<span class="org-keyword">case</span> <span class="org-string">'xz'</span>
view([0 <span class="org-type">-</span>1 0]);
<span class="org-keyword">case</span> <span class="org-string">'yz'</span>
view([1 0 0]);
<span class="org-keyword">end</span>
<span class="org-type">axis</span> equal; <span class="org-type">axis</span> equal;
<span class="org-type">axis</span> off; <span class="org-type">axis</span> off;
</pre> </pre>
</div> </div>
</div> </div>
</div> </div>
<div id="outline-container-orgf41db0f" class="outline-4">
<h4 id="orgf41db0f"><span class="section-number-4">5.12.2</span> Subplots</h4>
<div class="outline-text-4" id="text-5-12-2">
<div class="org-src-container">
<pre class="src src-matlab"><span class="org-keyword">if</span> strcmp(args.views, <span class="org-string">'all'</span>)
hAx = findobj(<span class="org-string">'type'</span>, <span class="org-string">'axes'</span>);
<span class="org-type">figure</span>;
s1 = subplot(2,2,1);
copyobj(<span class="org-type">get</span>(hAx(<span class="org-variable-name">1</span>), <span class="org-string">'Children'</span>), s1);
view([0 0 1]);
<span class="org-type">axis</span> equal;
<span class="org-type">axis</span> off;
title(<span class="org-string">'Top'</span>)
s2 = subplot(2,2,2);
copyobj(<span class="org-type">get</span>(hAx(<span class="org-variable-name">1</span>), <span class="org-string">'Children'</span>), s2);
view([1 <span class="org-type">-</span>0.6 0.4]);
<span class="org-type">axis</span> equal;
<span class="org-type">axis</span> off;
s3 = subplot(2,2,3);
copyobj(<span class="org-type">get</span>(hAx(<span class="org-variable-name">1</span>), <span class="org-string">'Children'</span>), s3);
view([1 0 0]);
<span class="org-type">axis</span> equal;
<span class="org-type">axis</span> off;
title(<span class="org-string">'Front'</span>)
s4 = subplot(2,2,4);
copyobj(<span class="org-type">get</span>(hAx(<span class="org-variable-name">1</span>), <span class="org-string">'Children'</span>), s4);
view([0 <span class="org-type">-</span>1 0]);
<span class="org-type">axis</span> equal;
<span class="org-type">axis</span> off;
title(<span class="org-string">'Side'</span>)
<span class="org-keyword">end</span>
</pre>
</div> </div>
</div> </div>
</div>
</div>
</div>
<p> <p>
@ -2386,7 +2444,7 @@ Plot the legs connecting the joints of the fixed base to the joints of the mobil
</div> </div>
<div id="postamble" class="status"> <div id="postamble" class="status">
<p class="author">Author: Dehaeze Thomas</p> <p class="author">Author: Dehaeze Thomas</p>
<p class="date">Created: 2020-02-11 mar. 17:52</p> <p class="date">Created: 2020-02-12 mer. 14:16</p>
</div> </div>
</body> </body>
</html> </html>

View File

@ -241,7 +241,7 @@ The obtained =stewart= Matlab structure contains all the information for analysi
The function =displayArchitecture= can be used to display the current Stewart configuration: The function =displayArchitecture= can be used to display the current Stewart configuration:
#+begin_src matlab #+begin_src matlab
displayArchitecture(stewart); displayArchitecture(stewart, 'views', 'all');
#+end_src #+end_src
#+header: :tangle no :exports results :results none :noweb yes #+header: :tangle no :exports results :results none :noweb yes
@ -1450,6 +1450,7 @@ This Matlab function is accessible [[file:../src/displayArchitecture.m][here]].
% - joints [true/false] - Display the Joints % - joints [true/false] - Display the Joints
% - labels [true/false] - Display the Labels % - labels [true/false] - Display the Labels
% - platforms [true/false] - Display the Platforms % - platforms [true/false] - Display the Platforms
% - views ['all', 'xy', 'yz', 'xz', 'default'] -
% %
% Outputs: % Outputs:
#+end_src #+end_src
@ -1471,6 +1472,7 @@ This Matlab function is accessible [[file:../src/displayArchitecture.m][here]].
args.joints logical {mustBeNumericOrLogical} = true args.joints logical {mustBeNumericOrLogical} = true
args.labels logical {mustBeNumericOrLogical} = true args.labels logical {mustBeNumericOrLogical} = true
args.platforms logical {mustBeNumericOrLogical} = true args.platforms logical {mustBeNumericOrLogical} = true
args.views char {mustBeMember(args.views,{'all', 'xy', 'xz', 'yz', 'default'})} = 'default'
end end
#+end_src #+end_src
@ -1503,7 +1505,12 @@ This Matlab function is accessible [[file:../src/displayArchitecture.m][here]].
The reference frame of the 3d plot corresponds to the frame $\{F\}$. The reference frame of the 3d plot corresponds to the frame $\{F\}$.
#+begin_src matlab #+begin_src matlab
figure; if ~strcmp(args.views, 'all')
figure;
else
f = figure('visible', 'off');
end
hold on; hold on;
#+end_src #+end_src
@ -1691,11 +1698,56 @@ Plot the legs connecting the joints of the fixed base to the joints of the mobil
*** Figure parameters *** Figure parameters
#+begin_src matlab #+begin_src matlab
view([1 -0.6 0.4]); switch args.views
case 'default'
view([1 -0.6 0.4]);
case 'xy'
view([0 0 1]);
case 'xz'
view([0 -1 0]);
case 'yz'
view([1 0 0]);
end
axis equal; axis equal;
axis off; axis off;
#+end_src #+end_src
*** Subplots
#+begin_src matlab
if strcmp(args.views, 'all')
hAx = findobj('type', 'axes');
figure;
s1 = subplot(2,2,1);
copyobj(get(hAx(1), 'Children'), s1);
view([0 0 1]);
axis equal;
axis off;
title('Top')
s2 = subplot(2,2,2);
copyobj(get(hAx(1), 'Children'), s2);
view([1 -0.6 0.4]);
axis equal;
axis off;
s3 = subplot(2,2,3);
copyobj(get(hAx(1), 'Children'), s3);
view([1 0 0]);
axis equal;
axis off;
title('Front')
s4 = subplot(2,2,4);
copyobj(get(hAx(1), 'Children'), s4);
view([0 -1 0]);
axis equal;
axis off;
title('Side')
end
#+end_src
* Bibliography :ignore: * Bibliography :ignore:
bibliographystyle:unsrt bibliographystyle:unsrt
bibliography:ref.bib bibliography:ref.bib

View File

@ -17,6 +17,7 @@ function [] = displayArchitecture(stewart, args)
% - joints [true/false] - Display the Joints % - joints [true/false] - Display the Joints
% - labels [true/false] - Display the Labels % - labels [true/false] - Display the Labels
% - platforms [true/false] - Display the Platforms % - platforms [true/false] - Display the Platforms
% - views ['all', 'xy', 'yz', 'xz', 'default'] -
% %
% Outputs: % Outputs:
@ -32,6 +33,7 @@ arguments
args.joints logical {mustBeNumericOrLogical} = true args.joints logical {mustBeNumericOrLogical} = true
args.labels logical {mustBeNumericOrLogical} = true args.labels logical {mustBeNumericOrLogical} = true
args.platforms logical {mustBeNumericOrLogical} = true args.platforms logical {mustBeNumericOrLogical} = true
args.views char {mustBeMember(args.views,{'all', 'xy', 'xz', 'yz', 'default'})} = 'default'
end end
assert(isfield(stewart.platform_F, 'FO_A'), 'stewart.platform_F should have attribute FO_A') assert(isfield(stewart.platform_F, 'FO_A'), 'stewart.platform_F should have attribute FO_A')
@ -49,7 +51,12 @@ Fa = stewart.platform_F.Fa;
assert(isfield(stewart.platform_M, 'Mb'), 'stewart.platform_M should have attribute Mb') assert(isfield(stewart.platform_M, 'Mb'), 'stewart.platform_M should have attribute Mb')
Mb = stewart.platform_M.Mb; Mb = stewart.platform_M.Mb;
figure; if ~strcmp(args.views, 'all')
figure;
else
f = figure('visible', 'off');
end
hold on; hold on;
FTa = [eye(3), FO_A; ... FTa = [eye(3), FO_A; ...
@ -185,6 +192,47 @@ if args.legs
end end
end end
view([1 -0.6 0.4]); switch args.views
case 'default'
view([1 -0.6 0.4]);
case 'xy'
view([0 0 1]);
case 'xz'
view([0 -1 0]);
case 'yz'
view([1 0 0]);
end
axis equal; axis equal;
axis off; axis off;
if strcmp(args.views, 'all')
hAx = findobj('type', 'axes');
figure;
s1 = subplot(2,2,1);
copyobj(get(hAx(1), 'Children'), s1);
view([0 0 1]);
axis equal;
axis off;
title('Top')
s2 = subplot(2,2,2);
copyobj(get(hAx(1), 'Children'), s2);
view([1 -0.6 0.4]);
axis equal;
axis off;
s3 = subplot(2,2,3);
copyobj(get(hAx(1), 'Children'), s3);
view([1 0 0]);
axis equal;
axis off;
title('Front')
s4 = subplot(2,2,4);
copyobj(get(hAx(1), 'Children'), s4);
view([0 -1 0]);
axis equal;
axis off;
title('Side')
end