<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
{mso-style-priority:34;
margin-top:0cm;
margin-right:0cm;
margin-bottom:0cm;
margin-left:36.0pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle20
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;
mso-ligatures:none;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
/* List Definitions */
@list l0
{mso-list-id:1161190588;
mso-list-type:hybrid;
mso-list-template-ids:232145864 67698703 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
@list l0:level1
{mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level2
{mso-level-number-format:alpha-lower;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level3
{mso-level-number-format:roman-lower;
mso-level-tab-stop:none;
mso-level-number-position:right;
text-indent:-9.0pt;}
@list l0:level4
{mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level5
{mso-level-number-format:alpha-lower;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level6
{mso-level-number-format:roman-lower;
mso-level-tab-stop:none;
mso-level-number-position:right;
text-indent:-9.0pt;}
@list l0:level7
{mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level8
{mso-level-number-format:alpha-lower;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;}
@list l0:level9
{mso-level-number-format:roman-lower;
mso-level-tab-stop:none;
mso-level-number-position:right;
text-indent:-9.0pt;}
@list l1
{mso-list-id:1514488023;
mso-list-type:hybrid;
mso-list-template-ids:1213232222 1943335710 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
@list l1:level1
{mso-level-start-at:0;
mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;
mso-fareast-font-family:Calibri;
mso-bidi-font-family:"Times New Roman";}
@list l1:level2
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l1:level3
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l1:level4
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l1:level5
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l1:level6
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
@list l1:level7
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Symbol;}
@list l1:level8
{mso-level-number-format:bullet;
mso-level-text:o;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:"Courier New";}
@list l1:level9
{mso-level-number-format:bullet;
mso-level-text:;
mso-level-tab-stop:none;
mso-level-number-position:left;
text-indent:-18.0pt;
font-family:Wingdings;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">There’s basically two different ways to interact with SDOs once the cyclic task is running:<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<ol style="margin-top:0cm" start="1" type="1">
<li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo2">You can continue to use ecrt_master_sdo_download/upload, but only from a non-cyclic thread.<o:p></o:p></li><li class="MsoListParagraph" style="margin-left:0cm;mso-list:l0 level1 lfo2">You can use ecrt_slave_config_create_sdo_request to create one or more cyclic request objects (in advance before starting cyclic operation), then the ecrt_sdo_request_* functions to
interact with them (set up, kick it off, check status, collect results) from the cyclic thread. These are non-blocking and polled, so you need to check them every cycle while a request is in progress.<o:p></o:p></li></ol>
<p class="MsoNormal"><o:p> </o:p></p>
<span style="FONT-FAMILY: Gotham, Calibri, 'sans-serif'; COLOR: #231f20"><strong>Gavin Lambert<br></strong>
<br>
Software Engineer<br>
<br>
</span><br>
<br><img style="HEIGHT: 45px; WIDTH: 192px" src="cid:TOMRA_CMYK_final_size_times_two_cd761a01-1d1f-446e-9316-8012271820b6.png" width="192" height="45" border="0">
<br>
<a href="https://www.facebook.com/TOMRA.Food/" target="_blank"><img alt="tomra facebook" src="cid:TF-FB-icon_b77c57e4-4990-4f9d-b3a2-8e6ab45df7f2.jpg" height="30"></a> <a href="https://www.linkedin.com/company/tomra-food/" target="_blank"><img alt="tomra linkedin" src="cid:TF-LinkedIn-icon_d54c4829-dcb9-450c-9187-34b26e85ebaa.jpg" height="30"></a> <a href="https://twitter.com/TOMRAFood" target="_blank"><img alt="tomra twitter" src="cid:icons-social-media-twitter_small_2_4bae5ad2-4add-4314-a352-5b317f784956.jpg" height="30"></a> <a href="https://www.youtube.com/playlist?list=PLDD3B1A7BAE919EC6" target="_blank"><img alt="tomra youtube" src="cid:TF-Youtube-icon_8b2c830c-70d9-48da-a4db-db9191d346ba.jpg" height="30"></a> <a href="https://www.instagram.com/tomrafood/" target="_blank"><img alt="tomra instragram" src="cid:TOMRAinstagram_45b30c55-490a-4f32-8fd3-998c152e3494.jpg" height="30"></a><br>
<span style="FONT-SIZE: 75%; FONT-FAMILY: Calibri, Candara, Segoe, Optima, Arial, sans-serif; COLOR: #6e8186"> <b>Compac Technologies Ltd</b>
| 4 Henderson Place | PO Box 13 516 | Onehunga 1061 | New Zealand </span><br>
<p style="FONT-SIZE: 10pt; MARGIN-BOTTOM: 5pt; FONT-FAMILY: Arial; MARGIN-TOP: 0px"></p>
<span style="FONT-SIZE: 75%; FONT-FAMILY: Calibri, Candara, Segoe, Optima, Arial, sans-serif; COLOR: #6e8186"> Phone: +64 96 34 00 88 | <a href="https://www.compacsort.com">https://www.compacsort.com</a></span><br>
<span style="FONT-SIZE: 60%; FONT-FAMILY: Gotham, Calibri, 'sans-serif'; COLOR: #6e8186">The information contained in this communication and any attachment is confidential and may be legally privileged. It should only be read by the person(s) to whom it is addressed. If you have received this communication in error, please notify the sender and delete the communication. </span><br>
<span style="FONT-SIZE: 60%; FONT-FAMILY: Gotham, Calibri, 'sans-serif'; WIDTH: 75%; COLOR: #6e8186">
</span><div style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt">
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b>From:</b> Etherlab-users <etherlab-users-bounces@etherlab.org>
<b>On Behalf Of </b>Clement Gaspard<br>
<b>Sent:</b> Friday, May 17, 2024 3:56 AM<br>
<b>To:</b> etherlab-users <etherlab-users@etherlab.org><br>
<b>Subject:</b> [Etherlab-users] Read/Write SDO during cyclic task<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal"><span style="display:none"><o:p> </o:p></span></p>
<div>
<div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">Good afternoon everyone,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">I am controlling ZeroErr eRob Actuators using the IgH EtherCAT Master from the stable-1.5 branch.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">I have defined Tx and Rx PDO registers to read/write informations during the cyclic task.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">However, is it possible to use SDO download and upload while the cyclic task is running?<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">If not, what is the best way to consult SDO information in the shortest possible time?<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">(I have tried to use
<strong><span style="font-family:"Arial",sans-serif">ecrt_master_sdo_upload</span></strong> and
<strong><span style="font-family:"Arial",sans-serif">ecrt_master_sdo_download</span></strong> during the cyclic task without much success. However, it works if I use these functions before calling
<strong><span style="font-family:"Arial",sans-serif">ecrt_master_activate</span></strong>.)<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">For example, I would like to know the temperature of the drive regularly (only accessible via SDO and not PDO mappable as described in the actuator documentation).<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">Thank you very much in advance.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">Best regards,<o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black">---------------------------------<o:p></o:p></span></p>
</div>
<div>
<div>
<p class="MsoNormal" style="line-height:14.4pt"><b><span style="font-size:13.0pt;font-family:"Verdana",sans-serif;color:black">Clément GASPARD
</span></b><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black"><o:p></o:p></span></p>
</div>
<table class="MsoNormalTable" border="0" cellspacing="3" cellpadding="0">
<tbody>
<tr style="height:18.0pt">
<td rowspan="2" style="padding:.75pt .75pt .75pt .75pt;height:18.0pt">
<p class="MsoNormal"><img width="509" height="509" style="width:5.3in;height:5.3in" id="Picture_x0020_1" src="cid:image001.jpg@01DAA84D.47AF7440"><o:p></o:p></p>
</td>
<td valign="bottom" style="padding:.75pt .75pt .75pt .75pt;height:18.0pt">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Verdana",sans-serif">Equipe Rhoban - Dpt<span style="color:black"> Méthodes et Modèles Formels</span> | LaBRI - Université de Bordeaux</span><o:p></o:p></p>
</td>
</tr>
<tr style="height:22.5pt">
<td valign="top" style="padding:.75pt .75pt .75pt .75pt;height:22.5pt">
<p class="MsoNormal"><img width="141" height="137" style="width:1.4666in;height:1.425in" id="Picture_x0020_2" src="cid:image002.png@01DAA84D.47AF7440"><a href="mailto:clement.gaspard@u-bordeaux.fr" target="_blank"><span style="font-size:9.0pt;font-family:"Verdana",sans-serif;color:#023261">clement.gaspard@u-bordeaux.fr
</span></a><o:p></o:p></p>
</td>
</tr>
<tr style="height:18.0pt">
<td rowspan="2" style="padding:.75pt .75pt .75pt .75pt;height:18.0pt">
<p class="MsoNormal"><img border="0" width="480" height="480" style="width:5.0in;height:5.0in" id="Picture_x0020_3" src="cid:image003.png@01DAA84D.47AF7440"><o:p></o:p></p>
</td>
<td valign="bottom" style="padding:.75pt .75pt .75pt .75pt;height:18.0pt">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Verdana",sans-serif;color:black">Département Mécatronique | ENS Rennes</span><o:p></o:p></p>
</td>
</tr>
<tr style="height:22.5pt">
<td valign="top" style="padding:.75pt .75pt .75pt .75pt;height:22.5pt">
<p class="MsoNormal"><img border="0" width="141" height="137" style="width:1.4666in;height:1.425in" id="Picture_x0020_4" src="cid:image002.png@01DAA84D.47AF7440"><a href="mailto:clement.gaspard@ens-rennes.fr" target="_blank"><span style="font-size:9.0pt;font-family:"Verdana",sans-serif;color:#023261">clement.gaspard@ens-rennes.fr</span>
</a><o:p></o:p></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>