[etherlab-users] Slave does not provide mailbox sync manager configurations

Zhiyong Weng zhiyong.weng at gmail.com
Sun Feb 9 13:36:56 CET 2014


hi,

    I give up tring to rewrite eeprom. I follow below post, hardcode esi
binary to fsm_sii.c
    Now etherlab can find the sm2 and sm3.
    I use "ethercat cstruct" generate the pdo codes. and the code can run
without error. (attached source code)

but new problem is pdo data is all zero. and I also find "datagram UNMATCHED
!" warning in log.

pls help.

Thank you so much Jeroen.

Regards,
Max

https://www.mail-archive.com/etherlab-users@etherlab.org/msg00305.html

Feb  9 18:06:21 MAX kernel: [307207.731351] EtherCAT: Requesting master 0...
Feb  9 18:06:21 MAX kernel: [307207.731354] EtherCAT DEBUG 0: IDLE ->
OPERATION.
Feb  9 18:06:21 MAX kernel: [307207.731355] EtherCAT: Successfully
requested master 0.
Feb  9 18:06:21 MAX kernel: [307207.731358] EtherCAT DEBUG 0:
ecrt_master_create_domain(master = 0xffff880194dbc000)
Feb  9 18:06:21 MAX kernel: [307207.731360] EtherCAT DEBUG 0: Created
domain 0.
Feb  9 18:06:21 MAX kernel: [307207.731363] EtherCAT DEBUG 0:
ecrt_master_slave_config(master = 0xffff880194dbc000, alias = 0, position =
0, vendor_id = 0x000000e4, product_code = 0x00001133)
Feb  9 18:06:21 MAX kernel: [307207.731365] EtherCAT DEBUG 0: Creating
slave configuration for 0:0, 0x000000E4/0x00001133.
Feb  9 18:06:21 MAX kernel: [307207.731368] EtherCAT DEBUG 0 0:0: Attached
slave 0.
Feb  9 18:06:21 MAX kernel: [307207.731405] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_sync_manager(sc = 0xffff8800a00f9000, sync_index = 0, dir
= 1, watchdog_mode = 2)
Feb  9 18:06:21 MAX kernel: [307207.731408] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_sync_manager(sc = 0xffff8800a00f9000, sync_index = 1, dir
= 2, watchdog_mode = 2)
Feb  9 18:06:21 MAX kernel: [307207.731410] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_sync_manager(sc = 0xffff8800a00f9000, sync_index = 2, dir
= 1, watchdog_mode = 2)
Feb  9 18:06:21 MAX kernel: [307207.731413] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_assign_clear(sc = 0xffff8800a00f9000, sync_index = 2)
Feb  9 18:06:21 MAX kernel: [307207.731417] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_assign_add(sc = 0xffff8800a00f9000, sync_index = 2,
pdo_index = 0x1600)
Feb  9 18:06:21 MAX kernel: [307207.731419] EtherCAT DEBUG 0 0:0: Loading
default mapping for PDO 0x1600.
Feb  9 18:06:21 MAX kernel: [307207.731421] EtherCAT DEBUG 0 0:0: Found PDO
name "Outputs".
Feb  9 18:06:21 MAX kernel: [307207.731423] EtherCAT DEBUG 0 0:0: Entry
0x6040:00.
Feb  9 18:06:21 MAX kernel: [307207.731424] EtherCAT DEBUG 0 0:0: Entry
0x6060:00.
Feb  9 18:06:21 MAX kernel: [307207.731425] EtherCAT DEBUG 0 0:0: Entry
0x6098:00.
Feb  9 18:06:21 MAX kernel: [307207.731426] EtherCAT DEBUG 0 0:0: Entry
0x607A:00.
Feb  9 18:06:21 MAX kernel: [307207.731427] EtherCAT DEBUG 0 0:0: Entry
0x60FF:00.
Feb  9 18:06:21 MAX kernel: [307207.731428] EtherCAT DEBUG 0 0:0: Entry
0x6071:00.
Feb  9 18:06:21 MAX kernel: [307207.731431] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_clear(sc = 0xffff8800a00f9000, pdo_index =
0x1600)
Feb  9 18:06:21 MAX kernel: [307207.731434] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x6040, entry_subindex = 0x00, entry_bit_length = 16)
Feb  9 18:06:21 MAX kernel: [307207.731437] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x6060, entry_subindex = 0x00, entry_bit_length = 8)
Feb  9 18:06:21 MAX kernel: [307207.731440] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x6098, entry_subindex = 0x00, entry_bit_length = 8)
Feb  9 18:06:21 MAX kernel: [307207.731443] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x607A, entry_subindex = 0x00, entry_bit_length = 32)
Feb  9 18:06:21 MAX kernel: [307207.731446] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x60FF, entry_subindex = 0x00, entry_bit_length = 32)
Feb  9 18:06:21 MAX kernel: [307207.731449] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1600, entry_index = 0x6071, entry_subindex = 0x00, entry_bit_length = 16)
Feb  9 18:06:21 MAX kernel: [307207.731452] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_sync_manager(sc = 0xffff8800a00f9000, sync_index = 3, dir
= 2, watchdog_mode = 2)
Feb  9 18:06:21 MAX kernel: [307207.731454] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_assign_clear(sc = 0xffff8800a00f9000, sync_index = 3)
Feb  9 18:06:21 MAX kernel: [307207.731457] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_assign_add(sc = 0xffff8800a00f9000, sync_index = 3,
pdo_index = 0x1A00)
Feb  9 18:06:21 MAX kernel: [307207.731458] EtherCAT DEBUG 0 0:0: Loading
default mapping for PDO 0x1A00.
Feb  9 18:06:21 MAX kernel: [307207.731460] EtherCAT DEBUG 0 0:0: Found PDO
name "Inputs".
Feb  9 18:06:21 MAX kernel: [307207.731462] EtherCAT DEBUG 0 0:0: Entry
0x6041:00.
Feb  9 18:06:21 MAX kernel: [307207.731463] EtherCAT DEBUG 0 0:0: Entry
0x6064:00.
Feb  9 18:06:21 MAX kernel: [307207.731464] EtherCAT DEBUG 0 0:0: Entry
0x6061:00.
Feb  9 18:06:21 MAX kernel: [307207.731465] EtherCAT DEBUG 0 0:0: Entry
0x1001:00.
Feb  9 18:06:21 MAX kernel: [307207.731466] EtherCAT DEBUG 0 0:0: Entry
0x606C:00.
Feb  9 18:06:21 MAX kernel: [307207.731467] EtherCAT DEBUG 0 0:0: Entry
0x6077:00.
Feb  9 18:06:21 MAX kernel: [307207.731469] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_clear(sc = 0xffff8800a00f9000, pdo_index =
0x1A00)
Feb  9 18:06:21 MAX kernel: [307207.731472] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x6041, entry_subindex = 0x00, entry_bit_length = 16)
Feb  9 18:06:21 MAX kernel: [307207.731474] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x6064, entry_subindex = 0x00, entry_bit_length = 32)
Feb  9 18:06:21 MAX kernel: [307207.731477] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x6061, entry_subindex = 0x00, entry_bit_length = 8)
Feb  9 18:06:21 MAX kernel: [307207.731480] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x1001, entry_subindex = 0x00, entry_bit_length = 8)
Feb  9 18:06:21 MAX kernel: [307207.731483] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x606C, entry_subindex = 0x00, entry_bit_length = 32)
Feb  9 18:06:21 MAX kernel: [307207.731486] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_pdo_mapping_add(sc = 0xffff8800a00f9000, pdo_index =
0x1A00, entry_index = 0x6077, entry_subindex = 0x00, entry_bit_length = 16)
Feb  9 18:06:21 MAX kernel: [307207.731490] EtherCAT DEBUG 0:
ecrt_master_slave_config(master = 0xffff880194dbc000, alias = 0, position =
0, vendor_id = 0x000000e4, product_code = 0x00001133)
Feb  9 18:06:21 MAX kernel: [307207.731493] EtherCAT DEBUG 0 0:0:
ecrt_slave_config_reg_pdo_entry(sc = 0xffff8800a00f9000, index = 0x6060,
subindex = 0x00, domain = 0xffff8801b2d7ae00, bit_position =
0xffff880121515ca4)
Feb  9 18:06:21 MAX kernel: [307207.731496] EtherCAT DEBUG 0: Domain 0:
Added 14 bytes, total 14.
Feb  9 18:06:21 MAX kernel: [307207.731531] EtherCAT DEBUG 0:
ecrt_domain_external_memory(domain = 0xffff8801b2d7ae00, mem =
0xffffc9001979e000)
Feb  9 18:06:21 MAX kernel: [307207.731534] EtherCAT DEBUG 0:
ecrt_master_callbacks(master = 0xffff880194dbc000, send_cb =
0xffffffffa055e8f0, receive_cb = 0xffffffffa055f020, cb_data =
0xffff880194dbc000)
Feb  9 18:06:21 MAX kernel: [307207.731536] EtherCAT DEBUG 0:
ecrt_master_activate(master = 0xffff880194dbc000)
Feb  9 18:06:21 MAX kernel: [307207.731539] EtherCAT DEBUG 0: Adding
datagram pair with expected WC 1.
Feb  9 18:06:21 MAX kernel: [307207.731541] EtherCAT 0: Domain0: Logical
address 0x00000000, 14 byte, expected working counter 1.
Feb  9 18:06:21 MAX kernel: [307207.731543] EtherCAT 0:   Datagram
domain0-0-main: Logical offset 0x00000000, 14 byte, type LWR.
Feb  9 18:06:21 MAX kernel: [307207.731544] EtherCAT DEBUG 0: Stopping
master thread.
Feb  9 18:06:21 MAX kernel: [307207.731587] EtherCAT DEBUG 0: Master IDLE
thread exiting...
Feb  9 18:06:21 MAX kernel: [307207.731623] EtherCAT 0: Master thread
exited.
Feb  9 18:06:21 MAX kernel: [307207.731627] EtherCAT DEBUG 0: FSM datagram
is ffff880194dbc678.
Feb  9 18:06:21 MAX kernel: [307207.731628] EtherCAT 0: Starting
EtherCAT-OP thread.
Feb  9 18:06:21 MAX kernel: [307207.731785] EtherCAT DEBUG 0: mmap()
Feb  9 18:06:21 MAX kernel: [307207.731790] EtherCAT DEBUG 0: Vma fault,
virtual_address = 00007fb546e08000, offset = 0, page = ffffea0006c38080
Feb  9 18:06:21 MAX kernel: [307207.731812] EtherCAT DEBUG 0: Operation
thread running with fsm interval = 4000 us, max data size=45000
Feb  9 18:06:21 MAX kernel: [307207.731822] EtherCAT WARNING 0: 1 datagram
UNMATCHED!
Feb  9 18:06:22 MAX kernel: [307208.742647] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:23 MAX kernel: [307209.752308] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:23 MAX kernel: [307209.752379] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:24 MAX kernel: [307210.761948] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:24 MAX kernel: [307210.762016] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:25 MAX kernel: [307211.771628] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:25 MAX kernel: [307211.771691] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:26 MAX kernel: [307212.781304] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:26 MAX kernel: [307212.781366] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:27 MAX kernel: [307213.791026] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:27 MAX kernel: [307213.791094] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:28 MAX kernel: [307214.800652] EtherCAT WARNING: Datagram
ffff88012daee258 (domain0-0-main) was SKIPPED 1 time.
Feb  9 18:06:28 MAX kernel: [307214.800713] EtherCAT DEBUG 0: Datagram
ffff88012daee258 already queued (skipping).
Feb  9 18:06:28 MAX kernel: [307215.024247] EtherCAT 0: Releasing master...
Feb  9 18:06:28 MAX kernel: [307215.024251] EtherCAT DEBUG 0:
ecrt_master_deactivate(master = 0xffff880194dbc000)
Feb  9 18:06:28 MAX kernel: [307215.024253] EtherCAT DEBUG 0: Stopping
master thread.
Feb  9 18:06:28 MAX kernel: [307215.024266] EtherCAT DEBUG 0: Master OP
thread exiting...
Feb  9 18:06:28 MAX kernel: [307215.024344] EtherCAT 0: Master thread
exited.
Feb  9 18:06:28 MAX kernel: [307215.024353] EtherCAT 0: Starting
EtherCAT-IDLE thread.
Feb  9 18:06:28 MAX kernel: [307215.024403] EtherCAT DEBUG 0: OPERATION ->
IDLE.
Feb  9 18:06:28 MAX kernel: [307215.024406] EtherCAT 0: Released.
Feb  9 18:06:28 MAX kernel: [307215.024408] EtherCAT DEBUG 0: Idle thread
running with send interval = 4000 us, max data size=45000
Feb  9 18:06:28 MAX kernel: [307215.024417] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024420] EtherCAT DEBUG: 0B 12 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024431] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024440] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024442] EtherCAT DEBUG: 0B 13 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024451] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024457] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024458] EtherCAT DEBUG: 0B 14 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024466] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024471] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024472] EtherCAT DEBUG: 0B 15 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024480] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024485] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024486] EtherCAT DEBUG: 0B 16 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024494] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024499] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024500] EtherCAT DEBUG: 0B 17 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024507] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024513] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024514] EtherCAT DEBUG: 0B 18 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024521] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024527] EtherCAT DEBUG 0: UNMATCHED
datagram:
Feb  9 18:06:28 MAX kernel: [307215.024528] EtherCAT DEBUG: 0B 19 00 00 00
00 0E 00 00 00 00 00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024536] EtherCAT DEBUG: 00 00 00 00 00
00 00 00 00 00
Feb  9 18:06:28 MAX kernel: [307215.024542] EtherCAT DEBUG 0: Configuration
changed.
Feb  9 18:06:28 MAX kernel: [307215.024544] EtherCAT DEBUG 0: No app_time
received up to now.
Feb  9 18:06:28 MAX kernel: [307215.031381] EtherCAT DEBUG 0-0: Changing
state from PREOP to PREOP (forced).
Feb  9 18:06:28 MAX kernel: [307215.031385] EtherCAT DEBUG 0-0:
Configuring...
Feb  9 18:06:28 MAX kernel: [307215.031682] EtherCAT DEBUG 0-0: Now in INIT.
Feb  9 18:06:28 MAX kernel: [307215.031683] EtherCAT DEBUG 0-0: Clearing
FMMU configurations...
Feb  9 18:06:28 MAX kernel: [307215.031799] EtherCAT DEBUG 0-0: Clearing
sync manager configurations...
Feb  9 18:06:28 MAX kernel: [307215.031916] EtherCAT DEBUG 0-0: Configuring
mailbox sync managers...
Feb  9 18:06:28 MAX kernel: [307215.031920] EtherCAT DEBUG 0-0: SM0: Addr
0x1800, Size  16, Ctrl 0x26, En 1
Feb  9 18:06:28 MAX kernel: [307215.031922] EtherCAT DEBUG 0-0: SM1: Addr
0x1900, Size  16, Ctrl 0x12, En 1
Feb  9 18:06:28 MAX kernel: [307215.032281] EtherCAT DEBUG 0-0: Now in
PREOP.
Feb  9 18:06:28 MAX kernel: [307215.032283] EtherCAT DEBUG 0-0: Finished
configuration.
Feb  9 18:06:44 MAX AptDaemon: INFO: Quitting due to inactivity
Feb  9 18:06:44 MAX AptDaemon: INFO: Quitting was requested
Feb  9 18:06:44 MAX dbus[858]: [system] Activating service
name='org.debian.apt' (using servicehelper)
Feb  9 18:06:45 MAX AptDaemon: INFO: Initializing daemon
Feb  9 18:06:45 MAX dbus[858]: [system] Successfully activated service
'org.debian.apt'
Feb  9 18:06:45 MAX AptDaemon.PackageKit: INFO: Initializing PackageKit
compat layer


2014-02-09 19:46 GMT+08:00 Jeroen Van den Keybus <
jeroen.vandenkeybus at gmail.com>:

> The 0x0700 at word offset 0x3e normally indicates that your EEPROM size is
> 1kB. Still, the master seems to assume 128 bytes. Please check the dmesg
> log after the device scan is performed.
>
> J.
>
>
> 2014-02-09 9:08 GMT+01:00 Zhiyong Weng <zhiyong.weng at gmail.com>:
>
> Hi,
>>
>>    I have new problem. "sii_write" can not update slaves's sii.
>>
>>    I generated new sii binary file (1024 byte), base on xml file in
>> twincat.
>>    use etherlab cmd "sii_write" write the bin file to slave without any
>> error info.
>> sudo ./ethercat sii_write -p 0 sii-new.bin
>>    power off motor and restart etherlab, power on motor.
>>
>>    check slave's sii content, still same. it is 128 byes.
>>
>>    sudo ./ethercat sii_read -v
>> SII Area:
>>   08 00 00 08 00 00 00 00 00 00 00 00 00 00 f5 00
>>   e4 00 00 00 33 11 00 00 00 00 02 00 00 00 00 00
>>   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>   00 18 10 00 00 19 10 00 04 00 00 00 00 00 00 00
>>   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>   00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>   00 00 00 00 00 00 00 00 00 00 00 00 07 00 01 00
>>
>>
>> Regards,
>> Max
>>
>>
>>
>>
>> 2014-02-04 19:01 GMT+08:00 Jeroen Van den Keybus <
>> jeroen.vandenkeybus at gmail.com>:
>>
>>> It looks like your SII only contains the mandatory items. Beckhoff
>>> TwinCAT relies on this information in combination with the .XML description
>>> file to derive the full config. But EtherLab requires the full config in
>>> the SII. You can use the Beckhoff TwinCAT software to create this SII image
>>> and write it into the SII EEPROM (provided it is large enough to hold it).
>>>
>>> J.
>>>
>>>
>>>
>>> 2014-02-04 Zhiyong Weng <zhiyong.weng at gmail.com>:
>>>
>>>> Hi ALL,
>>>>
>>>>    I am newbie for ethercat and trying to use etherlab to exchange data
>>>> with a motor.
>>>>
>>>>    After installing etherlab, I managed to read some device info from
>>>> the motor, with command line tools, like "ethercat slaves". also can
>>>> conduct SDO access successfully.
>>>>
>>>>    So I wrote a piece of code to send the PDOs. but failed and get
>>>> errors in syslog as below.
>>>>     My guess is the motor's slave controller missing sync manager(2
>>>> and 3) addresses in the SII, as it only show sm0, sm1.
>>>>  But in the xml provied by vendor, it do has 4 sm. file attached.
>>>>  Pls help!
>>>>
>>>> Regards,
>>>> Max
>>>>
>>>> Feb  4 17:59:12 MAX kernel: [13654.005940] EtherCAT DEBUG 0-0: *Slave
>>>> does not provide mailbox sync manager configurations.*
>>>> Feb  4 17:59:12 MAX kernel: [13654.005943] EtherCAT DEBUG 0-0: SM0:
>>>> Addr 0x1800, Size  16, Ctrl 0x26, En 1
>>>> Feb  4 17:59:12 MAX kernel: [13654.005944] EtherCAT DEBUG 0-0: SM1:
>>>> Addr 0x1900, Size  16, Ctrl 0x22, En 1
>>>>
>>>> *sm info in xml: *
>>>> <Sm MinSize="6" MaxSize="40" DefaultSize="16" StartAddress="#x1800"
>>>> ControlByte="#x26" Enable="1">MBoxOut</Sm>
>>>> <Sm MinSize="6" MaxSize="40" DefaultSize="16" StartAddress="#x1900"
>>>> ControlByte="#x12" Enable="1">MBoxIn</Sm>
>>>> <Sm StartAddress="#x1600" ControlByte="#x24" Enable="1">Outputs</Sm>
>>>> <Sm StartAddress="#x1A00" ControlByte="#x10" Enable="1">Inputs</Sm>
>>>>
>>>> *my PDO configure:*
>>>>
>>>> const static ec_pdo_entry_reg_t domain1_regs[] = {
>>>>
>>>>     {AliasAndPositon,  VendorID_ProductCode, 0x1A00, 4, &off_1A00},
>>>>
>>>>     {}
>>>>
>>>> };
>>>>
>>>> ec_pdo_entry_info_t duetfl80_channel1[] = {
>>>>
>>>>     {0x1A00, 4,  32} // modes_of_operation_display
>>>>
>>>> };
>>>>
>>>> static ec_pdo_info_t duetfl80_pdos[] = {
>>>>
>>>>     {0x1900,1 , duetfl80_channel1}    // pdo index input 0x1A00?
>>>>
>>>> };
>>>>
>>>> static ec_sync_info_t duetfl80_syncs[] = {
>>>>
>>>>     {3, EC_DIR_INPUT, 1, duetfl80_pdos},
>>>>
>>>>     {0xff}
>>>>
>>>> };
>>>>
>>>> *ethercat slaves*
>>>> 0 0:0 PREOP + 0x000000e4:0x00001133
>>>>
>>>> *ethercat slaves -v*
>>>> === Master 0, Slave 0 ===
>>>> Device: Main
>>>> State: PREOP
>>>> Flag: +
>>>> Identity:
>>>> Vendor Id: 0x000000e4
>>>> Product code: 0x00001133
>>>> Revision number: 0x00020000
>>>> Serial number: 0x00000000
>>>> DL information:
>>>> FMMU bit operation: no
>>>> Distributed clocks: no
>>>> Port Type Link Loop Signal NextSlave
>>>> 0 N/A up open yes -
>>>> 1 N/A down closed no -
>>>> 2 N/A down closed no -
>>>> 3 N/A down closed no -
>>>> Mailboxes:
>>>> Bootstrap RX: 0x0000/0, TX: 0x0000/0
>>>> Standard RX: 0x1800/16, TX: 0x1900/16
>>>> Supported protocols: CoE
>>>>
>>>> *ethercat sii_read -v*
>>>> SII Area:
>>>> 08 00 00 08 00 00 00 00 00 00 00 00 00 00 f5 00
>>>> e4 00 00 00 33 11 00 00 00 00 02 00 00 00 00 00
>>>> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>>> 00 18 10 00 00 19 10 00 04 00 00 00 00 00 00 00
>>>> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>>> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>>> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>>>> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> etherlab-users mailing list
>>>> etherlab-users at etherlab.org
>>>> http://lists.etherlab.org/mailman/listinfo/etherlab-users
>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.etherlab.org/pipermail/etherlab-users/attachments/20140209/1830593a/attachment-0004.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: etherlab_master.cpp
Type: text/x-c++src
Size: 12821 bytes
Desc: not available
URL: <http://lists.etherlab.org/pipermail/etherlab-users/attachments/20140209/1830593a/attachment-0005.cpp>


More information about the Etherlab-users mailing list