[etherlab-users] "Invalid mailbox configuration", how to configure?
Stefan Löfgren
stlo at dontdownload.com
Tue Mar 18 08:43:40 CET 2008
Good morning!
Yes, I tried updating the SII. Using
"cat /sys/ethercat/master0/slave000/sii > slavesii"
Using a hexeditor to change the values and
"cp slavesii > /sys/ethercat/master0/slave000/sii"
Restarting the slave and the master and now the SII seems to be ok.
(well, also removing the hardcoded stuff in fsm_slave_scan.c that I added to
fix this).
I also did "echo 1 > /sys/ethercat/master0/debug_level" at startup just
after the modprobe. (for some strange reason I forgot to set the option for
module unload the the kernel... :( )..
But I can't get it to work.
Can you see if this is a problem in the slave?
/Stefan
root at lablinux:~# hexdump /sys/ethercat/master0/slave000/sii
0000000 0009 0400 2710 0000 0000 0000 0000 0063
0000010 0014 0000 06c9 0000 0003 0000 0000 0000
0000020 0000 0000 0000 0000 0000 0000 0000 0000
0000030 1800 0014 1832 0014 0004 0000 0000 0000 <-- Fixed data
0000040 0000 0000 0000 0000 0000 0000 0000 0000
*
0000070 0000 0000 0000 0000 0000 0000 0007 0001
0000080 0028 0001 0201 0029 0004 1800 0014 0026
0000090 0001 0029 0004 1832 0014 0022 0001 0029
00000a0 0004 1000 0008 0024 0001 0029 0004 1100
00000b0 0008 0020 0001 ffff
00000b8
root at lablinux:~# cat /sys/ethercat/master0/slave000/info
Ring position: 0
State: PREOP (PREOP)
Flags: ok
Data link status:
Port 0: Phy 255 (unknown), Link up, Loop open, Signal detected
Port 1: Phy 255 (unknown), Link down, Loop closed, No signal
Port 2: Phy 255 (unknown), Link down, Loop closed, No signal
Port 3: Phy 255 (unknown), Link down, Loop closed, No signal
Identity:
Vendor ID: 0x00000014 (20)
Product code: 0x000006C9 (1737)
Revision number: 0x00000003 (3)
Serial number: 0x00000000 (0)
Mailboxes:
RX: 0x1800/20, TX: 0x1832/20 <--- Not hardcoded anymore..
Supported protocols: CoE
Sync managers / Pdo mapping:
SM0: addr 0x1800, size 20, control 0x26, enable
No Pdos mapped.
SM1: addr 0x1832, size 20, control 0x22, enable
No Pdos mapped.
SM2: addr 0x1000, size 8, control 0x24, enable
No Pdos mapped.
SM3: addr 0x1100, size 8, control 0x20, enable
No Pdos mapped.
/var/log/messages:
Mar 18 09:54:16 lablinux kernel: EtherCAT: Master driver 1.4.0-pre trunk r1088
Mar 18 09:54:16 lablinux kernel: EtherCAT: 1 master waiting for devices.
Mar 18 09:54:16 lablinux kernel: EtherCAT: Master debug level set to 1.
Mar 18 09:54:16 lablinux kernel: ec_8139too EtherCAT-capable Fast Ethernet
driver 0.9.27, master 1.4.0-pre trunk r1088
Mar 18 09:54:16 lablinux kernel: PCI: Found IRQ 9 for device 0000:00:02.0
Mar 18 09:54:16 lablinux kernel: eth0: RealTek RTL8139 at 0xc000,
00:d0:c9:97:05:e7, IRQ 9
Mar 18 09:54:16 lablinux kernel: PCI: Found IRQ 9 for device 0000:00:09.0
Mar 18 09:54:16 lablinux kernel: EtherCAT: Accepting device 00:D0:C9:97:05:E6
for master 0.
Mar 18 09:54:16 lablinux kernel: ec0: RealTek RTL8139 at 0xd000,
00:d0:c9:97:05:e6, IRQ 9
Mar 18 09:54:16 lablinux kernel: EtherCAT: Link state changed to UP.
Mar 18 09:54:16 lablinux kernel: EtherCAT: Starting master thread.
Mar 18 09:54:16 lablinux kernel: EtherCAT: 1 slave responding.
Mar 18 09:54:16 lablinux kernel: EtherCAT: Slave states: PREOP.
Mar 18 09:54:16 lablinux kernel: EtherCAT: Scanning bus.
Mar 18 09:54:16 lablinux kernel: EtherCAT: Bus scanning completed in 26 ms.
/var/log/syslog:
Mar 18 09:54:16 lablinux kernel: EtherCAT ERROR: Mailbox error response
received from slave 0 - Code 0x0004: "MBXERR_SERVICENOTSUPPORTED".
Mar 18 09:54:16 lablinux kernel: EtherCAT ERROR: Failed to read number of
mapped Pdos from slave 0.
Mar 18 09:54:16 lablinux kernel: EtherCAT ERROR: Mailbox error response
received from slave 0 - Code 0x0002: "MBXERR_UNSUPPORTEDPROTOCOL".
---------- Original Message -----------
From: Florian Pose <fp at igh-essen.com>
To: etherlab-users at lists.etherlab.org
Sent: Mon, 17 Mar 2008 16:09:10 +0100
Subject: Re: [etherlab-users] "Invalid mailbox configuration", how to configure?
> On Mon, Mar 17, 2008 at 03:45:08PM +0100, Stefan Löfgren wrote:
> > You bet I'll make another try. Seems to be working (se below).
> > Do you also have an explaination to the message in syslog:
> >
> > Mar 17 16:08:07 lablinux kernel: EtherCAT ERROR: Mailbox error response
> > received from slave 0 - Code 0x0002: "MBXERR_UNSUPPORTEDPROTOCOL".
> > Mar 17 16:08:07 lablinux kernel: EtherCAT ERROR: Failed to read mapped Pdo
> > index from slave 0.
> > Mar 17 16:08:07 lablinux kernel: EtherCAT ERROR: Mailbox error response
> > received from slave 0 - Code 0x0004: "MBXERR_SERVICENOTSUPPORTED".
> >
> > [snip]
> >
> > Mailboxes:
> > RX: 0x0000/0, TX: 0x0000/0
> > Supported protocols: CoE
>
> I think this is the problem. Probably, the master tries to configure
> the slave with a zero-sized mailbox. Perhaps the slave doesn't like this.
>
> Do you have the possibility to update the SII data?
>
> If this is not possible, please post the logs with the debug level
> set to 1, so we can have a look, which operation causes the error
> messages:
>
> rcethercat restart && echo 1 > /sys/ethercat/master0/debug_level
>
> --
> Best regards,
> Florian Pose
>
> http://etherlab.org
> _______________________________________________
> etherlab-users mailing list
> etherlab-users at lists.etherlab.org
> http://lists.etherlab.org/mailman/listinfo/etherlab-users
------- End of Original Message -------
More information about the Etherlab-users
mailing list