[etherlab-dev] Failed to register PDO entry: No such file or directory -- PDO entry 0x7030:01 is not mapped

Matthys Schnetler Matthys at tubecon.co.za
Thu Feb 23 09:20:37 CET 2012


Hi All,

I am hoping that someone can help me with a PDO registration issue I have.

System information:

- Ethercat version: IgH EtherCAT master 1.5.1 0f7a243b03e4
-Operating System: Ubuntu (lucid Lynix with Kernel 2.6.38.8 patched with xenomai 2.6.0)
-My remote I/O set is made up of EK1100, EL2004 (x4), EL1014 (x4), EL5101, EL4132 in this order

Problem:

When I use the ethercat tool (under /opt/etherlab/bin) and I execute the command ./ethercat cstruct I get the following information

/* Master 0, Slave 1, "EL2004"
 * Vendor ID:       0x00000002
 * Product code:    0x07d43052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_1_pdo_entries[] = {
    {0x7000, 0x01, 1}, /* Output */
    {0x7010, 0x01, 1}, /* Output */
    {0x7020, 0x01, 1}, /* Output */
    {0x7030, 0x01, 1}, /* Output */
};

ec_pdo_info_t slave_1_pdos[] = {
    {0x1600, 1, slave_1_pdo_entries + 0}, /* Channel 1 */
    {0x1601, 1, slave_1_pdo_entries + 1}, /* Channel 2 */
    {0x1602, 1, slave_1_pdo_entries + 2}, /* Channel 3 */
    {0x1603, 1, slave_1_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_1_syncs[] = {
    {0, EC_DIR_OUTPUT, 4, slave_1_pdos + 0, EC_WD_ENABLE},
    {0xff}
};

/* Master 0, Slave 2, "EL2004"
 * Vendor ID:       0x00000002
 * Product code:    0x07d43052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_2_pdo_entries[] = {
    {0x7000, 0x01, 1}, /* Output */
    {0x7010, 0x01, 1}, /* Output */
    {0x7020, 0x01, 1}, /* Output */
    {0x7030, 0x01, 1}, /* Output */
};

ec_pdo_info_t slave_2_pdos[] = {
    {0x1600, 1, slave_2_pdo_entries + 0}, /* Channel 1 */
    {0x1601, 1, slave_2_pdo_entries + 1}, /* Channel 2 */
    {0x1602, 1, slave_2_pdo_entries + 2}, /* Channel 3 */
    {0x1603, 1, slave_2_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_2_syncs[] = {
    {0, EC_DIR_OUTPUT, 4, slave_2_pdos + 0, EC_WD_ENABLE},
    {0xff}
};

/* Master 0, Slave 3, "EL2004"
 * Vendor ID:       0x00000002
 * Product code:    0x07d43052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_3_pdo_entries[] = {
    {0x7000, 0x01, 1}, /* Output */
    {0x7010, 0x01, 1}, /* Output */
    {0x7020, 0x01, 1}, /* Output */
    {0x7030, 0x01, 1}, /* Output */
};

ec_pdo_info_t slave_3_pdos[] = {
    {0x1600, 1, slave_3_pdo_entries + 0}, /* Channel 1 */
    {0x1601, 1, slave_3_pdo_entries + 1}, /* Channel 2 */
    {0x1602, 1, slave_3_pdo_entries + 2}, /* Channel 3 */
    {0x1603, 1, slave_3_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_3_syncs[] = {
    {0, EC_DIR_OUTPUT, 4, slave_3_pdos + 0, EC_WD_ENABLE},
    {0xff}
};

/* Master 0, Slave 4, "EL2004"
 * Vendor ID:       0x00000002
 * Product code:    0x07d43052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_4_pdo_entries[] = {
    {0x7000, 0x01, 1}, /* Output */
    {0x7010, 0x01, 1}, /* Output */
    {0x7020, 0x01, 1}, /* Output */
    {0x7030, 0x01, 1}, /* Output */
};

ec_pdo_info_t slave_4_pdos[] = {
    {0x1600, 1, slave_4_pdo_entries + 0}, /* Channel 1 */
    {0x1601, 1, slave_4_pdo_entries + 1}, /* Channel 2 */
    {0x1602, 1, slave_4_pdo_entries + 2}, /* Channel 3 */
    {0x1603, 1, slave_4_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_4_syncs[] = {
    {0, EC_DIR_OUTPUT, 4, slave_4_pdos + 0, EC_WD_ENABLE},
    {0xff}
};

/* Master 0, Slave 5, "EL1014"
 * Vendor ID:       0x00000002
 * Product code:    0x03f63052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_5_pdo_entries[] = {
    {0x6000, 0x01, 1}, /* Input */
    {0x6010, 0x01, 1}, /* Input */
    {0x6020, 0x01, 1}, /* Input */
    {0x6030, 0x01, 1}, /* Input */
};

ec_pdo_info_t slave_5_pdos[] = {
    {0x1a00, 1, slave_5_pdo_entries + 0}, /* Channel 1 */
    {0x1a01, 1, slave_5_pdo_entries + 1}, /* Channel 2 */
    {0x1a02, 1, slave_5_pdo_entries + 2}, /* Channel 3 */
    {0x1a03, 1, slave_5_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_5_syncs[] = {
    {0, EC_DIR_INPUT, 4, slave_5_pdos + 0, EC_WD_DISABLE},
    {0xff}
};

/* Master 0, Slave 6, "EL1014"
 * Vendor ID:       0x00000002
 * Product code:    0x03f63052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_6_pdo_entries[] = {
    {0x6000, 0x01, 1}, /* Input */
    {0x6010, 0x01, 1}, /* Input */
    {0x6020, 0x01, 1}, /* Input */
    {0x6030, 0x01, 1}, /* Input */
};

ec_pdo_info_t slave_6_pdos[] = {
    {0x1a00, 1, slave_6_pdo_entries + 0}, /* Channel 1 */
    {0x1a01, 1, slave_6_pdo_entries + 1}, /* Channel 2 */
    {0x1a02, 1, slave_6_pdo_entries + 2}, /* Channel 3 */
    {0x1a03, 1, slave_6_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_6_syncs[] = {
    {0, EC_DIR_INPUT, 4, slave_6_pdos + 0, EC_WD_DISABLE},
    {0xff}
};

/* Master 0, Slave 7, "EL1014"
 * Vendor ID:       0x00000002
 * Product code:    0x03f63052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_7_pdo_entries[] = {
    {0x6000, 0x01, 1}, /* Input */
    {0x6010, 0x01, 1}, /* Input */
    {0x6020, 0x01, 1}, /* Input */
    {0x6030, 0x01, 1}, /* Input */
};

ec_pdo_info_t slave_7_pdos[] = {
    {0x1a00, 1, slave_7_pdo_entries + 0}, /* Channel 1 */
    {0x1a01, 1, slave_7_pdo_entries + 1}, /* Channel 2 */
    {0x1a02, 1, slave_7_pdo_entries + 2}, /* Channel 3 */
    {0x1a03, 1, slave_7_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_7_syncs[] = {
    {0, EC_DIR_INPUT, 4, slave_7_pdos + 0, EC_WD_DISABLE},
    {0xff}
};

/* Master 0, Slave 8, "EL1014"
 * Vendor ID:       0x00000002
 * Product code:    0x03f63052
 * Revision number: 0x00100000
 */

ec_pdo_entry_info_t slave_8_pdo_entries[] = {
    {0x6000, 0x01, 1}, /* Input */
    {0x6010, 0x01, 1}, /* Input */
    {0x6020, 0x01, 1}, /* Input */
    {0x6030, 0x01, 1}, /* Input */
};

ec_pdo_info_t slave_8_pdos[] = {
    {0x1a00, 1, slave_8_pdo_entries + 0}, /* Channel 1 */
    {0x1a01, 1, slave_8_pdo_entries + 1}, /* Channel 2 */
    {0x1a02, 1, slave_8_pdo_entries + 2}, /* Channel 3 */
    {0x1a03, 1, slave_8_pdo_entries + 3}, /* Channel 4 */
};

ec_sync_info_t slave_8_syncs[] = {
    {0, EC_DIR_INPUT, 4, slave_8_pdos + 0, EC_WD_DISABLE},
    {0xff}
};

/* Master 0, Slave 9, "EL5101"
 * Vendor ID:       0x00000002
 * Product code:    0x13ed3052
 * Revision number: 0x03fc0000
 */

ec_pdo_entry_info_t slave_9_pdo_entries[] = {
    {0x7000, 0x01, 8}, /* Ctrl */
    {0x7000, 0x02, 16}, /* Value */
    {0x6000, 0x01, 8}, /* Status */
    {0x6000, 0x02, 16}, /* Value */
    {0x6000, 0x03, 16}, /* Latch */
};

ec_pdo_info_t slave_9_pdos[] = {
    {0x1600, 2, slave_9_pdo_entries + 0}, /* RxPDO-Map Outputs */
    {0x1a00, 3, slave_9_pdo_entries + 2}, /* TxPDO-Map Inputs */
};

ec_sync_info_t slave_9_syncs[] = {
    {0, EC_DIR_OUTPUT, 0, NULL, EC_WD_DISABLE},
    {1, EC_DIR_INPUT, 0, NULL, EC_WD_DISABLE},
    {2, EC_DIR_OUTPUT, 1, slave_9_pdos + 0, EC_WD_DISABLE},
    {3, EC_DIR_INPUT, 1, slave_9_pdos + 1, EC_WD_DISABLE},
    {0xff}
};

/* Master 0, Slave a, "EL4132"
 * Vendor ID:       0x00000002
 * Product code:    0x10243052
 * Revision number: 0x03fa0000
 */

ec_pdo_entry_info_t slave_10_pdo_entries[] = {
    {0x3001, 0x01, 16}, /* Output */
    {0x3002, 0x01, 16}, /* Output */
};

ec_pdo_info_t slave_10_pdos[] = {
    {0x1600, 1, slave_10_pdo_entries + 0}, /* RxPDO 01 mapping */
    {0x1601, 1, slave_10_pdo_entries + 1}, /* RxPDO 02 mapping */
};

ec_sync_info_t slave_10_syncs[] = {
    {0, EC_DIR_OUTPUT, 0, NULL, EC_WD_DISABLE},
    {1, EC_DIR_INPUT, 0, NULL, EC_WD_DISABLE},
    {2, EC_DIR_OUTPUT, 2, slave_10_pdos + 0, EC_WD_DISABLE},
    {3, EC_DIR_INPUT, 0, NULL, EC_WD_DISABLE},
    {0xff}
};


With this information I create my PDO information in my program and I use it to configure my slaves.

The slaves configure without any errors but the moment I execute:

            if (ecrt_domain_reg_pdo_entry_list(domain1, domain1_regs)) {
                        ec_Error=1;
                        fprintf(stderr,"Failed configure Domain PDOS.\n");
            }

The information displayed allong with this in the Terminal is:

"Failed to register PDO entry: No such file or directory"

When I dmesg i get the following:

[12589.249840] EtherCAT: Requesting master 0...
[12589.249850] EtherCAT: Successfully requested master 0.
[12589.250526] EtherCAT ERROR 0 28672:257: PDO entry 0x7030:01 is not mapped.
[12592.174416] EtherCAT 0: Releasing master...
[12592.174465] EtherCAT 0: Released.

Also when i execute ./ethercat PDOS I get:

=== Master 0, Slave 1 ===
SM0: PhysAddr 0x0f00, DefaultSize    0, ControlRegister 0x44, Enable 9
  RxPDO 0x1600 "Channel 1"
    PDO entry 0x7000:01,  1 bit, "Output"
  RxPDO 0x1601 "Channel 2"
    PDO entry 0x7010:01,  1 bit, "Output"
  RxPDO 0x1602 "Channel 3"
    PDO entry 0x7020:01,  1 bit, "Output"
  RxPDO 0x1603 "Channel 4"
    PDO entry 0x7030:01,  1 bit, "Output"
=== Master 0, Slave 2 ===
SM0: PhysAddr 0x0f00, DefaultSize    0, ControlRegister 0x44, Enable 9
  RxPDO 0x1600 "Channel 1"
    PDO entry 0x7000:01,  1 bit, "Output"
  RxPDO 0x1601 "Channel 2"
    PDO entry 0x7010:01,  1 bit, "Output"
  RxPDO 0x1602 "Channel 3"
    PDO entry 0x7020:01,  1 bit, "Output"
  RxPDO 0x1603 "Channel 4"
    PDO entry 0x7030:01,  1 bit, "Output"
=== Master 0, Slave 3 ===
SM0: PhysAddr 0x0f00, DefaultSize    0, ControlRegister 0x44, Enable 9
  RxPDO 0x1600 "Channel 1"
    PDO entry 0x7000:01,  1 bit, "Output"
  RxPDO 0x1601 "Channel 2"
    PDO entry 0x7010:01,  1 bit, "Output"
  RxPDO 0x1602 "Channel 3"
    PDO entry 0x7020:01,  1 bit, "Output"
  RxPDO 0x1603 "Channel 4"
    PDO entry 0x7030:01,  1 bit, "Output"
=== Master 0, Slave 4 ===
SM0: PhysAddr 0x0f00, DefaultSize    0, ControlRegister 0x44, Enable 9
  RxPDO 0x1600 "Channel 1"
    PDO entry 0x7000:01,  1 bit, "Output"
  RxPDO 0x1601 "Channel 2"
    PDO entry 0x7010:01,  1 bit, "Output"
  RxPDO 0x1602 "Channel 3"
    PDO entry 0x7020:01,  1 bit, "Output"
  RxPDO 0x1603 "Channel 4"
    PDO entry 0x7030:01,  1 bit, "Output"
=== Master 0, Slave 5 ===
SM0: PhysAddr 0x1000, DefaultSize    1, ControlRegister 0x00, Enable 1
  TxPDO 0x1a00 "Channel 1"
    PDO entry 0x6000:01,  1 bit, "Input"
  TxPDO 0x1a01 "Channel 2"
    PDO entry 0x6010:01,  1 bit, "Input"
  TxPDO 0x1a02 "Channel 3"
    PDO entry 0x6020:01,  1 bit, "Input"
  TxPDO 0x1a03 "Channel 4"
    PDO entry 0x6030:01,  1 bit, "Input"
=== Master 0, Slave 6 ===
SM0: PhysAddr 0x1000, DefaultSize    1, ControlRegister 0x00, Enable 1
  TxPDO 0x1a00 "Channel 1"
    PDO entry 0x6000:01,  1 bit, "Input"
  TxPDO 0x1a01 "Channel 2"
    PDO entry 0x6010:01,  1 bit, "Input"
  TxPDO 0x1a02 "Channel 3"
    PDO entry 0x6020:01,  1 bit, "Input"
  TxPDO 0x1a03 "Channel 4"
    PDO entry 0x6030:01,  1 bit, "Input"
=== Master 0, Slave 7 ===
SM0: PhysAddr 0x1000, DefaultSize    1, ControlRegister 0x00, Enable 1
  TxPDO 0x1a00 "Channel 1"
    PDO entry 0x6000:01,  1 bit, "Input"
  TxPDO 0x1a01 "Channel 2"
    PDO entry 0x6010:01,  1 bit, "Input"
  TxPDO 0x1a02 "Channel 3"
    PDO entry 0x6020:01,  1 bit, "Input"
  TxPDO 0x1a03 "Channel 4"
    PDO entry 0x6030:01,  1 bit, "Input"
=== Master 0, Slave 8 ===
SM0: PhysAddr 0x1000, DefaultSize    1, ControlRegister 0x00, Enable 1
  TxPDO 0x1a00 "Channel 1"
    PDO entry 0x6000:01,  1 bit, "Input"
  TxPDO 0x1a01 "Channel 2"
    PDO entry 0x6010:01,  1 bit, "Input"
  TxPDO 0x1a02 "Channel 3"
    PDO entry 0x6020:01,  1 bit, "Input"
  TxPDO 0x1a03 "Channel 4"
    PDO entry 0x6030:01,  1 bit, "Input"
=== Master 0, Slave 9 ===
SM0: PhysAddr 0x1800, DefaultSize   48, ControlRegister 0x26, Enable 1
SM1: PhysAddr 0x1880, DefaultSize   48, ControlRegister 0x22, Enable 1
SM2: PhysAddr 0x1000, DefaultSize    3, ControlRegister 0x24, Enable 1
  RxPDO 0x1600 "RxPDO-Map Outputs"
    PDO entry 0x7000:01,  8 bit, "Ctrl"
    PDO entry 0x7000:02, 16 bit, "Value"
SM3: PhysAddr 0x1100, DefaultSize    5, ControlRegister 0x20, Enable 1
  TxPDO 0x1a00 "TxPDO-Map Inputs"
    PDO entry 0x6000:01,  8 bit, "Status"
    PDO entry 0x6000:02, 16 bit, "Value"
    PDO entry 0x6000:03, 16 bit, "Latch"
=== Master 0, Slave 10 ===
SM0: PhysAddr 0x1800, DefaultSize  246, ControlRegister 0x26, Enable 1
SM1: PhysAddr 0x18f6, DefaultSize  246, ControlRegister 0x22, Enable 1
SM2: PhysAddr 0x1000, DefaultSize    4, ControlRegister 0x24, Enable 1
  RxPDO 0x1600 "RxPDO 01 mapping"
    PDO entry 0x3001:01, 16 bit, "Output"
  RxPDO 0x1601 "RxPDO 02 mapping"
    PDO entry 0x3002:01, 16 bit, "Output"
SM3: PhysAddr 0x1100, DefaultSize    0, ControlRegister 0x20, Enable 0


What I have come to find is that it moans about the EL2004 0x7030:01 and when I remove these settings it then moans about the EL1014's 0x6030:01 value.

By removing these above mentioned values Ethercat does not complain anymore and all slaves go into OP state.

How is it possible for ethercat give me an error on this when it actually supplies me with the information and it corresponds with the PDO info?

Also note that executing ./ethercat config it returns nothing on all arguments.

Thanking you in advance

Regards

Matthys
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.etherlab.org/pipermail/etherlab-dev/attachments/20120223/81b4a69d/attachment-0001.html>


More information about the etherlab-dev mailing list