[etherlab-users] Problem with Beckhoff EL1502
Hammer, Günter
Guenter.Hammer at ids.de
Fri Dec 19 16:15:37 CET 2008
Hello Florian
I made the following changes:
- I removed the sdo requests, and try to get the counter values only via pdo
- I added outputs to the pdo-entries
The pdo-entries now are:
static ec_pdo_entry_info_t cCI70A_pdo_entries[] = {
{0x7020, 1, 1}, //
{0x7020, 2, 1}, //
{0x7020, 3, 1}, //
{0x7020, 4, 1}, //
{0x0000, 0, 12}, //
{0x7020, 17, 32}, //
{0x6020, 1, 1}, // output function enabled
{0x6020, 2, 1}, // status of output
{0x6020, 3, 1}, // set counter done
{0x6020, 4, 1}, // counter inhibited
{0x6020, 5, 1}, // status of input UD
{0x6020, 6, 1}, // status of input clock
{0x0000, 0, 7}, //
{0x1C32, 32, 1}, //
{0x0000, 0, 1}, //
{0x1802, 9, 1}, //
{0x6020, 17, 32} // counter value
};
static ec_pdo_info_t cCI70A_pdos[] = {
{0x1602, 6, cCI70A_pdo_entries},
{0x1A02, 11, cCI70A_pdo_entries + 6}
// {0x1602, 5, cCI70A_pdo_entries},
// {0x1A02, 7, cCI70A_pdo_entries + 5}
};
static ec_sync_info_t cCI70A_syncs[] = {
{2, EC_DIR_OUTPUT, 1, cCI70A_pdos},
{3, EC_DIR_INPUT, 1, cCI70A_pdos + 1},
{0xff}
};
As you can see in the following log, the slave puts a counter-value in the Ecat frame, but it is allways
the counter value from the start. The value never changes until i restart the master.
Then i get once a new value where i can see, that the slave has counted my inputs before i made the restart.
<7>[ 143.980385] EtherCAT DEBUG: sending frame:
<7>[ 143.980401] EtherCAT DEBUG: c30b301e:
<4>[ 143.980415] 20 10 0A CC 00 00 00 00 06 80 00 00 00 00 00 00 <---- i set the counter value to 0 in the sending frame
<7>[ 143.980472] EtherCAT DEBUG: 00 00 00 00 07 CD 00 00 30 01 02 00 00 00 00 00
<7>[ 143.980533] EtherCAT DEBUG: 00 00 00 00 00 00 00 00 00 00 00 00 00 00
<7>[ 143.981037] EtherCAT DEBUG: Received frame:
<7>[ 143.981083] EtherCAT DEBUG: c3373420:
<4>[ 143.981099] 20 10 0A CC 00 00 00 00 06 80 00 00 00 80 6A FF <----- the slave puts a value into the frame
<7>[ 143.981156] EtherCAT DEBUG: FF FF 01 00 07 CD 02 00 30 01 02 00 00 00 0A 00
<7>[ 143.981219] EtherCAT DEBUG: 02 00 00 00 00 00 00 00 00 00 00 00 00 00
<7>[ 143.981300] EtherCAT DEBUG: ec_master_send_datagrams
<7>[ 143.981321] EtherCAT DEBUG: adding datagram 0xCE
<7>[ 143.981341] EtherCAT DEBUG: frame size: 46
<7>[ 143.981359] EtherCAT DEBUG: sending frame:
<7>[ 143.981376] EtherCAT DEBUG: c302d81e:
<4>[ 143.981390] 12 10 0A CE 00 00 00 00 06 00 00 00 00 00 00 00
<7>[ 143.981447] EtherCAT DEBUG: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
<7>[ 143.981508] EtherCAT DEBUG: 00 00 00 00 00 00 00 00 00 00 00 00 00 00
<7>[ 143.982043] EtherCAT DEBUG: Received frame:
<7>[ 143.982091] EtherCAT DEBUG: c3373420:
<4>[ 143.982106] 12 10 0A CE 00 00 00 00 06 00 00 00 00 80 6A FF <----- the slave puts a value into the frame
<7>[ 143.982163] EtherCAT DEBUG: FF FF 01 00 00 00 00 00 00 00 00 00 00 00 00 00
<7>[ 143.982224] EtherCAT DEBUG: 00 00 00 00 00 00 00 00 00 00 00 00 00 00
I attached the startup log-file.
Although i added outputs to the pdo-entries, the communication still goes via LRD intstead of LRW commands (log file Line 354)
In line 379 i can read once a counter value change.
If i could read any further change i can see it in the log file, but there are none.
The only thing that looks strange for me in the log file is in line 17:
EtherCAT WARNING: Unknown category type 0x003C in slave 1.
I think the communication between master and slave works, but there is any trigger missing to make the slave
put the actual counter value into the ecat frames.
Best regards
Günter Hammer
What do I wrong in my postings, because every posting starts with a new thread in the archieve and is not attached to the older ones ?
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Startverhalten.txt
URL: <http://lists.etherlab.org/pipermail/etherlab-users/attachments/20081219/05301b9c/attachment-0004.txt>
More information about the Etherlab-users
mailing list