All,
Trying to track down an issue with setting up "Flexible PDOs"
on the Kollmorgan AKD2Gs. I have tried various methods to get these to be
configured reliably, but nothing yet.
The baseline code calls ecrt_domain_reg_pdo_entry_list(mDomain,domain1_regs),
and that works around 90% of the time. However, it fails ~10% of the time.
This problem makes life "fun" when you have 6 motor controllers with each one
randomly not configuring properly.
In looking at the logs on the master with dmesg, we get a timeout on waiting
for SDO responses. Also, looking at the SDO logs inside the AKD2G (but still
working that angle), it also appears that either SDOs are not being received
from the master (or the AKD2G is ignoring them??).
I have even written scripts that does the SDOs setup by hand (ie ethercat
-p0 --type uint8 download 0x1C12 0 0), and I also get random results of getting
the configuration setup correctly.
The CStruct is as follows:
ec_pdo_entry_info_t akd2g_pdo_entries_current[] = {
/* RxPdo 0x1600 */
{ 0x5003, 0x05, 32 }, /* current */
{ 0x6040, 0x00, 16 }, /* DS402 command word */
};
ec_pdo_entry_info_t akd2g_pdo_entries_received[] = {
/* TxPDO 0x1a00 */
{ 0x6063, 0x00, 32 }, /* position */
{ 0x6041, 0x00, 16 }, /* DS402 Status Word*/
/* TxPDO 0x1a01 */
{ 0x606c, 0x00, 32 }, /* actual velocity, in milli rpm */
{ 0x500A, 0x01, 32 }, /* actual current */
{ 0x60E4, 0x01, 32 }, /* Feedback 1 Position */
};
ec_pdo_info_t akd2g_pdos_current[] = {
{ 0x1600, 2, akd2g_pdo_entries_current + 0 },
{ 0x1a00, 2, akd2g_pdo_entries_received + 0 },
{ 0x1a01, 3, akd2g_pdo_entries_received + 2 },
};
ec_sync_info_t akd2g_syncs_current[] = {
{ 0, EC_DIR_OUTPUT, 0, NULL, EC_WD_DISABLE },
{ 1, EC_DIR_INPUT, 0, NULL, EC_WD_DISABLE },
{ 2, EC_DIR_OUTPUT, 1, akd2g_pdos_current + 0, EC_WD_DISABLE },
{ 3, EC_DIR_INPUT, 2, akd2g_pdos_current + 1, EC_WD_DISABLE },
{ 0xFF }
};
Still working to get a Wireshark dump (on a headless system), so working
through this to see if it tells me anything.
Questions:
1. Has anybody experienced similar issues and how they where able to resolve
this?
2. I have tried things that where mentioned in other posts like increasing
EC_WAIT_SDO_DICT from 3 to 30 seconds. Any other settings I should be looking
at?
3. I am currently using version 1.5.x. I looked at the release notes for
1.6 and didn't see anything that looked obvious. Anything in the update that
may help?
4. It seems (as a stop gap) that if I attempt to configure all 6 motor
controllers, eventually it will work. The method right now is to:
* Ecrt_release_master(mMaster)
* Run a script that will restart ethercat (ie.
/usr/local/etc/init.d/ethercat restart)
* But when I attempt to get the master (ecrt_master_activate(mMaster)),
domain (ie. ecrt_domain_data(mDomain)) all is good
* BUT FAILS on ecrt_domain_reg_pdo_entry_list(mDomain, domain_regs)
* Anybody have some actual or sudo code that would allow for me to try
again...either fall all motor controllers or the specific motor controller that
didn't setup the PDOs correctly?
Thanks in advance for anything you can provide,
Mike W
--
Etherlab-users mailing list
Etherlab-users@etherlab.org
https://lists.etherlab.org/mailman/listinfo/etherlab-users