From: etherlab-users [mailto:[email protected]] On Behalf Of 
Roland Pastorino
Sent: Sunday, 11 January 2015 12:31 p.m.
To: [email protected]
Subject: [etherlab-users] Enhanced mode for EL5101

Hello everyone,
I have prepared an application using an EK1101 and an EL5101, both from 
Beckhoff.
Everything works as expected.
Now I would like to use the enhanced operating mode of the EL5101 in order to 
get a 32 bit value for the encoder.
Despite many hours of searching and reading I haven't found a single piece of 
information in the Beckhoff manuals that explains how to do that.
Could someone give me a hint on how to enable the enhanced operating mode?
Thanks you.
Best Regards

P.S.: this question has already been asked in 2011 but it has no answer 
(http://lists.etherlab.org/pipermail/etherlab-users/2011/001390.html)

Roland Pastorino

Hi,

I’m using the following pdo entries:

// revision 0x03FF0000 and newer
ec_pdo_entry_info_t EL5101_current_pdoEntries[] = {
                          // control (rw)
    {0x7010, 0x01, 1},    //   enableLatchC
    {0x7010, 0x02, 1},    //   enableLatchExternP
    {0x7010, 0x03, 1},    //   setCounter
    {0x7010, 0x04, 1},    //   enableLatchExternN
    {0x0000, 0x00, 4},    //   spacer
    {0x0000, 0x00, 8},    //   spacer
    {0x7010, 0x11, 32},   // setCounterPos (rw)

                          // status (r)
    {0x6010, 0x01, 1},    //   latchCValid
    {0x6010, 0x02, 1},    //   latchExternValid
    {0x6010, 0x03, 1},    //   setCounterDone
    {0x6010, 0x04, 1},    //   counterUnderflow
    {0x6010, 0x05, 1},    //   counterOverflow
    {0x6010, 0x06, 1},    //   statusOfInputStatus
    {0x6010, 0x07, 1},    //   openCircuit
    {0x6010, 0x08, 1},    //   extrapolationStall
    {0x6010, 0x09, 1},    //   statusOfInputA
    {0x6010, 0x0A, 1},    //   statusOfInputB
    {0x6010, 0x0B, 1},    //   statusOfInputC
    {0x6010, 0x0C, 1},    //   statusOfInputGate
    {0x6010, 0x0D, 1},    //   statusOfExternLatch
    {0x6010, 0x0E, 1},    //   syncError       // for revision 0x03ff0000
    {0x6010, 0x0F, 1},    //   txPDOState      // for revision 0x03ff0000
    {0x6010, 0x10, 1},    //   txPDOToggle     // for revision 0x03ff0000
    {0x6010, 0x11, 32},   // actual position (r)
    {0x6010, 0x12, 32},   // latchPos (r)
};

ec_pdo_info_t EL5101_current_pdos[] = {
    {0x1603, 7, EL5101_current_pdoEntries + 0},
    {0x1a04, 18, EL5101_current_pdoEntries + 7},
};

ec_sync_info_t EL5101_current_syncs[] = {
    {0, EC_DIR_OUTPUT, 0, NULL, EC_WD_DISABLE},
    {1, EC_DIR_INPUT, 0, NULL, EC_WD_DISABLE},
    {2, EC_DIR_OUTPUT, 1, EL5101_current_pdos + 0, EC_WD_ENABLE},
    {3, EC_DIR_INPUT, 1, EL5101_current_pdos + 1, EC_WD_DISABLE},
    {0xff}
};


Using 0x1603 and 0x1a04 gives you access to the enhanced 32 bit data.  However, 
I have not figured out how to actually put it into enhanced mode, which is 
required if you want to use the distributed clock.

Also of note, the above pdo configuration is for revision 0x03FF0000 and newer 
modules.  For revision 0x03fe0000 and older modules three of the entries are 
different:

    {0x1C32, 0x20, 1},    //   syncError     // for revision 0x03fe0000 and 
older
    {0x1804, 0x07, 1},    //   txPDOState    // for revision 0x03fe0000 and 
older
    {0x1804, 0x09, 1},    //   txPDOToggle   // for revision 0x03fe0000 and 
older


Let us know if you figure out how to set up enhanced mode for the distributed 
clocks.


Regards,
Graeme.



_______________________________________________
etherlab-users mailing list
[email protected]
http://lists.etherlab.org/mailman/listinfo/etherlab-users

Reply via email to