[etherlab-users] Problems with Setting up the System

+BigNose bignose at bluewin.ch
Sun Nov 13 12:37:47 CET 2011

Further Update:

I downloaded now the latest package. The other one, was a version, a
few weeks ago. And now, the master does do the bus scan and goes into

Now I only have one problem left: When I compile the RTAI examples,
somehow the references are not correctly made, so the linker doesn't
find them. Although I indicated the correct rtai dir on configure.

BTW: Is it normal. That the usual "make" and "make modules" do not
compile the RTAI examples? (even if the rtai dir is told on configure)

I tried to do a "make modules" directly in the rtai example dir, which
worked, but only with the problem of the missing references in the
linker. And so the produced module is unusable.
Any hint about that problem?

B> Short Update:

B> Silly me! My udev daemon wasn't running correctly. When I fixed this,
B> the Ethercat entry showed up in the /dev directory. And now the
B> ethercat tool works. Isn't it possible to run it without udev and
B> instead have a fixed /dev entry?
B> But it still doesn't do what it should do according to the PDF.
B> It remains in Init-state. And doesn't scan the bus topology.
B> Therefore a "ethercat config" doesn't output anything. And an "ethercat
B> graph" only lists an empty graph.
B> How do I get this running?

B> BTW a "ethercat master" outputs the following:

B> Master0
B>   Phase: Idle
B>   Active: no
B>   Slaves: 0
B>   Ethernet devices:
B>     Main: 00:18:7d:02:ad:ce (attached)
B>       Link: UP
B>       Tx frames:   305287
B>       Rx frames:   305286
B>       Lost frames: 0
B>       Tx bytes:    18317220
B>       Tx errors:   0
B>       Tx frame rate [1/s]:    300    300    300
B>       Tx rate [KByte/s]:     17.6   17.6   17.5
B>       Loss rate [1/s]:          0      0      0
B>       Frame loss [%]:         0.0    0.0    0.0

B>     Backup: None.
B>   Distributed clocks:
B>     Reference clock: None
B>     Application time: 0
B>                       2000-01-01 00:00:00.000000000

B> The strange thing is. Here it displays slaves=0, although it says upon
B> the module loading 3 slaves found???

B>> I tried to install the ethercat drivers as in the pdf manual. I
B>> encountered the following problems:

B>> * First it didn't work at all. Probabely the problem was, that I
B>> compiled the kernel with integrated 8139too driver. When I recompiled
B>> the Kernel, but this time with the driver in module form. It worked
B>> better. Is this really like that, that it only works, if the original
B>> 8139too drivers are not compiled into the kernel? If yes, It should
B>> really be mentioned in the PDF!

B>> *Second problem. I then was able to start the "ethercat start" script
B>> in init.d. But on my system, this script only loads the ec_master
B>> module. I additionally have to do a "modprobe ec_8139too" to load the
B>> net drivers, which then starts the master, and my connected test slave
B>> (Beckhoff EK1100+EL1008+EL2008) starts to blink. And I get the message
B>> that 3 slaves are found and that they are in init state. But in the
B>> PDF is says, they should be in PreOp state and there should be a bus
B>> scan. But this doesn't happen.
B>> Also the /dev/EtherCAT0 entry doesn't show up in the /dev directory.
B>> Therefore all tries to find out about the state with the ethercat tool
B>> is simply aborted with the error message, that /dev/EtherCAT0 is
B>> invalid.
B>> I also tried the additional udev rule file, like mentioned in the PDF.
B>> It didn't work. Then I tried to manually create an /dev/EtherCAT0 with mknod
B>> (252,0). But it still doesn't work.

B>> What could be the problem? And how can I resolve it?

B>> Would be really grateful for any hint.

B>>                 Thanks
B>>                   Shanti

B>> BTW:
B>> This is the output after a "/etc/init.d/ethercat start":

B>> [   10.351303] EtherCAT: Master driver devel unknown
B>> [   10.353821] EtherCAT: 1 master waiting for devices.

B>> And this after a "modprobe ec_8139too":

B>> [   10.396659] ec_8139too EtherCAT-capable Fast Ethernet driver 0.9.28, master devel unknown
B>> [   10.402873] EtherCAT: Accepting device 00:18:7D:02:AD:CE for master 0.
B>> [   10.408646] ec0: RealTek RTL8139 at 0xf600, 00:18:7d:02:ad:ce, IRQ 5
B>> [   10.411143] ec0:  Identified 8139 chip type 'RTL-8100B/8139D'
B>> [   10.411224] EtherCAT 0: Link state changed to UP.
B>> [   10.413647] EtherCAT 0: Starting EtherCAT-IDLE thread.
B>> [   10.421289] eth0: RealTek RTL8139 at 0xf800, 00:18:7d:02:ad:cd, IRQ 10
B>> [   10.423397] EtherCAT 0: 3 slave(s) responding.
B>> [   10.428669] EtherCAT 0: Slave states: INIT.
B>> [   10.430463] eth0:  Identified 8139 chip type 'RTL-8100B/8139D'
B>> [   10.443372] eth0: link down

B>> And this is the error message I get, when I try to use the ethercat
B>> tool e.g. "ethercat config":

B>> Failed to obtain number of masters: Failed to open master device /dev/EtherCAT0: Invalid argument

B>> I got a vanilla linux with rtai 3.7.1.
B>> I downloaded the newest etherlab sources for compile.


B>> --------------------------------------------------- 
B>> Nothing is as serious as it seems,
B>> so keep smiling ;-)
B>>                           mailto:bignose at bluewin.ch

B>> _______________________________________________
B>> etherlab-users mailing list
B>> etherlab-users at etherlab.org
B>> http://lists.etherlab.org/mailman/listinfo/etherlab-users

B> _______________________________________________
B> etherlab-users mailing list
B> etherlab-users at etherlab.org
B> http://lists.etherlab.org/mailman/listinfo/etherlab-users

More information about the Etherlab-users mailing list