Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

SDO Read Causes Slave PLC To Reset

mccabehm
2015-02-24
2015-02-25
  • mccabehm - 2015-02-24

    I have an IFM CR0032 PLC configured (using CoDeSys v2.3) as a CANopen slave. When the master does an SDO read of 0x100A (SW version) the PLC resets . Bus trace:

    can0 701 [1] 05 // slave heartbeat, operational
    <more traffic="">
    can0 601 [8] 40 0A 10 00 00 00 00 00 // master initiates read
    can0 77E [1] 05 // master heartbeat, operational
    can0 701 [1] 00 // slave heartbeat, initialization implies reset</more>

    I can also verify that a PLC reset takes place because I hear the internal relays clicking. In the CoDeSys project the variable associated with 0x100A is STRING(3) := '24T', read-only. I expect (and have elsewhere seen) a response of a 4-byte, null-terminated string.

    Anyone have experience with this? Or have insight into why the PLC reacts this way?

     

    Related

    Talk.ru: 1
    Talk.ru: 8

  • mccabehm - 2015-02-25

    It appears that CANopen for the IFM CR0032 (slave) does not handle SDOs for STRING(n) where n < 4. I verified this on several OD entries. For STRING(n) with n >= 4 an object of 5 or more bytes results, so a segmented SDO is needed rather than expedited. For now this seems to be a reasonable workaround.

     
  • mccabehm - 2015-02-25

    Further evidence... create a project using the IFM template for CR0032 CANopen slave. In the Objekt1xxxh PRG change ManufacturerSoftwareVersion to be "STRING(3) := '123';". Run PLC. Read 0x100A via SDO. 5 out of 5 times the PLC resets.

     

Log in to post a comment.