synapticon / Etherlab_EtherCAT_Master

Clone of IgH EtherCAT Master with additional Vectioneer patches.
GNU Lesser General Public License v2.1
81 stars 54 forks source link

Master wants to read SDOs which not exist #13

Open SteffenAs opened 5 years ago

SteffenAs commented 5 years ago

The Master want to read a SDO which not exist. I think the problem occoures because the slave have no TxPdos.

My System: Debian without Desktop and the RT Preempt Kernel from the paket manager. 4.9.0-8-rt-amd64 #1 SMP PREEMPT RT Debian 4.9.130-2 (2018-10-27) x86_64 GNU/Linux

The Ethercat Configuration from the Commandline tool:

0 0:0 PREOP + EK1814 EtherCAT-EA-Koppler (1A E-Bus, 4 K. Dig. Ein, 3ms, 4 K. 1 0:1 PREOP + EL3161 1K.Ana. Eingang 0-10V 2 0:2 PREOP + EL2535 2K. Pulsweiten Strom Ausgang (24V, 1 A) 3 0:3 PREOP + EL4001 1Ch. Ana. Output 0-10V, 12bit 4 0:4 PREOP + EL9510 Netzteilklemme 10V 5 0:5 PREOP + EL3356-0010 1K . Ana. Eingang, Widerstandsbr▒cke, 24bit, hochge

The Error from the Kernel log file

Jan 10 08:14:29 Ethermax kernel: [ 5.103529] ec_master: loading out-of-tree module taints kernel. Jan 10 08:14:29 Ethermax kernel: [ 5.112188] EtherCAT: Master driver 1.5.2-sncn-5 v1.5.2-sncn-4-10-gefbf251 Jan 10 08:14:29 Ethermax kernel: [ 5.112635] EtherCAT: 1 master waiting for devices. Jan 10 08:14:29 Ethermax kernel: [ 5.120527] ec_generic: EtherCAT master generic Ethernet device module 1.5.2-sncn-5 v1.5.2-sncn-4-10-gefbf251 Jan 10 08:14:29 Ethermax kernel: [ 5.120548] EtherCAT: Accepting E0:D5:5E:E8:A8:9B as main device for master 0. Jan 10 08:14:29 Ethermax kernel: [ 5.120564] ec_generic: Binding socket to interface 3 (enp4s0). Jan 10 08:14:29 Ethermax kernel: [ 5.147299] EtherCAT 0: Starting EtherCAT-IDLE thread. Jan 10 08:14:30 Ethermax kernel: [ 5.827747] [drm] RC6 on Jan 10 08:14:30 Ethermax kernel: [ 6.213126] r8169 0000:04:00.0 enp4s0: link up Jan 10 08:14:30 Ethermax kernel: [ 6.213150] IPv6: ADDRCONF(NETDEV_CHANGE): enp4s0: link becomes ready Jan 10 08:14:30 Ethermax kernel: [ 6.215193] EtherCAT 0: Link state of ecm0 changed to UP. Jan 10 08:14:30 Ethermax kernel: [ 6.223466] EtherCAT 0: 6 slave(s) responding on main device. Jan 10 08:14:30 Ethermax kernel: [ 6.223507] EtherCAT 0: Slave states on main device: PREOP. Jan 10 08:14:30 Ethermax kernel: [ 6.223817] EtherCAT 0: Scanning bus. Jan 10 08:14:30 Ethermax kernel: [ 6.293915] random: crng init done Jan 10 08:14:30 Ethermax kernel: [ 6.293918] random: 7 urandom warning(s) missed due to ratelimiting Jan 10 08:14:30 Ethermax kernel: [ 6.763568] EtherCAT ERROR 0-3: SDO upload 0x1C13:01 aborted. Jan 10 08:14:30 Ethermax kernel: [ 6.763635] EtherCAT ERROR 0-3: SDO abort message 0x06090011: "Subindex does not exist". Jan 10 08:14:30 Ethermax kernel: [ 6.763689] EtherCAT ERROR 0-3: Failed to read index of assigned PDO 1 from SM3. Jan 10 08:14:31 Ethermax kernel: [ 7.093650] EtherCAT 0: Bus scanning completed in 868 ms. Jan 10 08:14:31 Ethermax kernel: [ 7.093653] EtherCAT 0: Using slave 0 as DC reference clock. Jan 10 08:14:31 Ethermax kernel: [ 7.104660] r8169 0000:03:00.0 enp3s0: link up

With the Commandline tool I see that the SDO not exist.

0x1c00:02, r-r-r-, uint8, 8 bit, "SubIndex 002" 0x1c00:03, r-r-r-, uint8, 8 bit, "SubIndex 003" 0x1c00:04, r-r-r-, uint8, 8 bit, "SubIndex 004" SDO 0x1c12, "RxPDO assign" 0x1c12:00, r-r-r-, uint8, 8 bit, "SubIndex 000" 0x1c12:01, r-r-r-, uint16, 16 bit, "SubIndex 001" SDO 0x1c32, "SM output parameter" 0x1c32:00, r-r-r-, uint8, 8 bit, "SubIndex 000" 0x1c32:01, rwrwrw, uint16, 16 bit, "Sync mode" 0x1c32:02, rwrwrw, uint32, 32 bit, "Cycle time"

Had anyone the same problem and know how to fix it? Thanks in advance Steffen

vtretyakov commented 5 years ago

@SteffenAs could you let me know which EtherCAT slave devices you are using?

SteffenAs commented 5 years ago

@vtretyakov I posted my configuration on the top, the problem is at slave 3 which is a EL4001 from Beckhoff. This slave is only a analog output. https://download.beckhoff.com/download/document/io/ethercat-terminals/el40xxde.pdf I think the error is not a problem but it occures at my console.

vtretyakov commented 5 years ago

@SteffenAs ah, sorry, overlooked. Have you tried using the latest changed from develop branch? There were some changes related to SDOs.

SteffenAs commented 5 years ago

I use the version 5 of the Master. https://github.com/synapticon/Etherlab_EtherCAT_Master/releases/download/v1.5.2-sncn-5/EtherCAT_Master-1.5.2-sncn-5.zip

Should I test version 6? In the changelog I doesnt find something which could help me. https://github.com/synapticon/Etherlab_EtherCAT_Master/commit/8f07db79b73a7061a098c346210cfd258d673b02

vtretyakov commented 5 years ago

@SteffenAs I would suggest to give it a try. There is a compilation script inside sncn_installer folder. That is maximum we can help at this point. We have a very limited experience with Beckhoff devices, so we may have not experienced the same issues. You may try to find other distributions in the web or post your issue on the official IgH mailing list (you'll find it in EtherLab website). If you find a solution, we would be very happy if you could share it with us. We are voluntarily supporting this open source solution but primarily testing it on Synapticon's SOMANET devices.

zakharov commented 5 years ago

Hello Steffen. When does the master try to read this SDO? Is it happening when you start your application, during the switch from PREOP to OP? Or is it happening even when the master is idle?

SteffenAs commented 5 years ago

@zakharov It happens without an application on system startup or if I restart the master

zakharov commented 5 years ago

Maybe this error message is not a problem after all? Did you try to run your application?

solomonould commented 6 months ago

has anyone else had this or have any info on resolutions? im experiencing the same thing, the ethercat sdo command shows [SDO 0x1c33, "Input Sync Manager Parameter" 0x1c33:00, r-r-r-, uint8, 8 bit, "Number of entries" 0x1c33:01, rwr-r-, uint16, 16 bit, "Synchronization Type" 0x1c33:02, rwr-r-, uint32, 32 bit, "Cycle Time" 0x1c33:03, rwr-r-, uint32, 32 bit, "Shift Time" 0x1c33:04, r-r-r-, uint16, 16 bit, "Synchronization Types supported" 0x1c33:05, r-r-r-, uint32, 32 bit, "Minimum Cycle Time" 0x1c33:06, r-r-r-, uint32, 32 bit, "Calc and Copy Time" 0x1c33:0c, r-r-r-, uint16, 16 bit, "Cycle Time Too Small"] but i get errors saying that the masting is trying to read 1c33:07 for example, i have 31 devices on the buss and its taking about 15 minutes for all the errors to resolve and then i can write sdos and use the system, can anyone help ? :)