<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Hello,</div><div class=""><br class=""></div>I think I found the solution, the rtdm interface for xenomai 3 allows to manage only one device, it is necessary to increase the value of « device_count »  of the « rtdm_driver »  structure in the rtdm_xenomai_v3.c file (line 282). <div class="">Philippe</div><div class=""><br class=""><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">Le 28 oct. 2021 à 15:58, Zanne Philippe <<a href="mailto:zanne.philippe@unistra.fr" class="">zanne.philippe@unistra.fr</a>> a écrit :</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Dear all,<div class=""><br class=""></div><div class="">I have the same problem. </div><div class=""><br class=""></div><div class="">My system specs </div><div class="">Linux Distribution  : ubuntu 20.04, </div><div class="">Kernel version 4.19, </div><div class="">Xenomai 3.1, </div><div class="">Master version 1.5.2 + Gavin Lambert patch set</div><div class="">Ethernet Driver : ec_e1000e</div><div class=""><br class=""></div><div class="">The problem is reproducible using the xenomai example of etherlab master : When I run the program on master#0 everything works as expected, if I run the program on master#1 it is not able to access the device,  the function ecrt_request_master(1) returns the error « Failed to open /dev/rtdm/EtherCAT1: No such device or address ».</div><div class="">After starting Ethercat service the output of the dmesg command is as follows:</div><div class=""><br class=""></div><div class=""><div class="">[  460.502346] EtherCAT: Master driver 1.5.2 365eea9297ef+</div><div class="">[  460.502441] EtherCAT 0: Registered RTDM device EtherCAT0.</div><div class="">[  460.502491] EtherCAT 1: Registered RTDM device EtherCAT1.</div><div class="">[  460.502491] EtherCAT: 2 masters waiting for devices.</div><div class="">[  460.511205] e1000e 0000:07:00.0 enp7s0: removed PHC</div><div class="">[  460.577656] e1000e: enp7s0 NIC Link is Down</div><div class="">[  460.595500] e1000e 0000:00:19.0 enp0s25: removed PHC</div><div class="">[  460.682249] e1000e: enp0s25 NIC Link is Down</div><div class="">[  460.735962] ec_e1000e: EtherCAT-capable Intel(R) PRO/1000 Network Driver - 3.2.6-k-EtherCAT</div><div class="">[  460.735963] ec_e1000e: Copyright(c) 1999 - 2015 Intel Corporation.</div><div class="">[  460.736267] ec_e1000e 0000:00:19.0: Interrupt Throttling Rate (ints/sec) set to dynamic conservative mode</div><div class="">[  460.816493] ec_e1000e 0000:00:19.0 0000:00:19.0 (uninitialized): registered PHC clock</div><div class="">[  460.892157] EtherCAT: Accepting 90:1B:0E:A6:10:79 as main device for master 0.</div><div class="">[  460.989318] EtherCAT 0: Starting EtherCAT-IDLE thread.</div><div class="">[  460.989456] ec_e1000e 0000:00:19.0 ecm0 (uninitialized): (PCI Express:2.5GT/s:Width x1) 90:1b:0e:a6:10:79</div><div class="">[  460.989457] ec_e1000e 0000:00:19.0 ecm0 (uninitialized): Intel(R) PRO/1000 Network Connection</div><div class="">[  460.989498] ec_e1000e 0000:00:19.0 ecm0 (uninitialized): MAC: 11, PHY: 12, PBA No: FFFFFF-0FF</div><div class="">[  460.989723] ec_e1000e 0000:07:00.0: Interrupt Throttling Rate (ints/sec) set to dynamic conservative mode</div><div class="">[  461.032767] ec_e1000e 0000:07:00.0 0000:07:00.0 (uninitialized): registered PHC clock</div><div class="">[  461.080570] EtherCAT: Accepting 68:05:CA:3C:26:A8 as main device for master 1.</div><div class="">[  461.145721] EtherCAT 1: Starting EtherCAT-IDLE thread.</div><div class="">[  461.145778] ec_e1000e 0000:07:00.0 ecm1 (uninitialized): (PCI Express:2.5GT/s:Width x1) 68:05:ca:3c:26:a8</div><div class="">[  461.145779] ec_e1000e 0000:07:00.0 ecm1 (uninitialized): Intel(R) PRO/1000 Network Connection</div><div class="">[  461.145795] ec_e1000e 0000:07:00.0 ecm1 (uninitialized): MAC: 3, PHY: 8, PBA No: E46981-008</div><div class="">[  463.147267] ec_e1000e: ecm1 NIC Link is Up 100 Mbps Full Duplex, Flow Control: None</div><div class="">[  463.147384] ec_e1000e 0000:07:00.0 ecm1 (uninitialized): 10/100 speed: disabling TSO</div><div class="">[  463.147388] EtherCAT 1: Link state of ecm1 changed to UP.</div><div class="">[  463.148591] EtherCAT 1: 3 slave(s) responding on main device.</div><div class="">[  463.148592] EtherCAT 1: Slave states on main device: PREOP.</div><div class="">[  463.148815] EtherCAT 1: Scanning bus.</div><div class="">[  463.359813] EtherCAT 1: Bus scanning completed in 211 ms.</div><div class="">[  463.359815] EtherCAT 1: Using slave main-0 as DC reference clock.</div><div class="">[  463.364853] EtherCAT 1: Slave states on main device: INIT, PREOP.</div><div class="">[  463.368902] EtherCAT 1: Slave states on main device: INIT.</div><div class="">[  463.372933] EtherCAT 1: Slave states on main device: PREOP.</div></div><div class=""><br class=""></div><div class="">and the output of the command "ethercat -m 1 slaves » is :</div><div class=""><div class="">sudo ethercat -m 1 slaves</div><div class="">0  0:0  PREOP  +  EK1100 EtherCAT-Koppler (2A E-Bus)</div><div class="">1  0:1  PREOP  +  EL2008 8K. Dig. Ausgang 24V, 0.5A</div><div class="">2  0:2  PREOP  +  EL3102 2K. Ana. Eingang +/-10V, Diff.</div></div><div class=""><br class=""></div><div class="">SDO request on master 1 seems to work, for example the command « ethercat -m 1 -p 2 upload -t int16 0x3102 0X2 » returns consistent values. </div><div class="">I tried changing the order of the masters, changing the ethernet board (ec_igb), the problem is still the same.</div><div class="">Do you have any test ideas to determine where this error comes from?</div><div class="">Thank you</div><div class="">Philippe</div><div class=""><br class=""></div><div class="">  </div><div class=""><div class=""><blockquote type="cite" class=""><div class="">Le 26 août 2021 à 07:49, HoThanhtam <<a href="mailto:thanhtam.ho@neuromeka.com" class="">thanhtam.ho@neuromeka.com</a>> a écrit :</div><br class="Apple-interchange-newline"><div class="">
 
 <div class=""><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class="">Hello </div><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class="">I am using unofficial patchset to be able to use the EtherCAT master code in Xenomai 3. I enabled 2 masters on 2 NIC ports. I built an application using libethercat_rtdm, this application work fine if I conrtol slave via Master#0. However when I switch to Master#1 ( ecrt_request_master(1) ) then I got the error "Failed to open /dev/rtdm/EtherCAT1: No such device or address" althought both /dev/rtdm/EtherCAT0 and /dev/rtdm/EtherCAT1 exist. </div><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class="">By the way, this application worked well on Xenomai 2 system, on both Master#0 and Master#1.</div><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class="">Any advise?</div><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class="">Thank you.</div><div style="font-family: 굴림체; font-size: 9pt; margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div> 
 </div>
-- <br class="">Etherlab-users mailing list<br class=""><a href="mailto:Etherlab-users@etherlab.org" class="">Etherlab-users@etherlab.org</a><br class=""><a href="https://lists.etherlab.org/mailman/listinfo/etherlab-users" class="">https://lists.etherlab.org/mailman/listinfo/etherlab-users</a><br class=""></div></blockquote></div><br class=""></div></div>-- <br class="">Etherlab-users mailing list<br class=""><a href="mailto:Etherlab-users@etherlab.org" class="">Etherlab-users@etherlab.org</a><br class="">https://lists.etherlab.org/mailman/listinfo/etherlab-users<br class=""></div></blockquote></div><br class=""></div></div></body></html>