This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F2812: how to reset eCAN after CAN errors occur

Part Number: TMS320F2812


Hello Champs,

Would you please kindly suggest how to reset F2812 eCAN module to resume normal transfer/receive function after CAN errors occur?

Unlike SCI which has SCI reset bit in SCI control register, there is no such bit which can reset eCAN.

Disabling the eCAN clock and then enabling it after several us delay still cannot resume normal transfer/receive.

Would you please kindly help? Thanks! 

Best Regards,

Linda

  • Linda,

                There is a software-reset (SRES) bit in CANMC register. Note, however, that this bit does not modify the error counters. So, it is important to understand the nature of these errors. Exactly what kind of errors are we talking about here? Is it a bus-off condition?

  • Linda

    I haven’t heard from you for a while, so I’m assuming you were able to resolve your issue. If this isn’t the case, please reject this resolution or reply to this thread. If this thread locks, please make a new thread describing the current status of your issue.
  • Hello Hareesh,

    This issue has been found out that not the eCAN error but that the CCE bit has been set when three or more than three nodes have been linked together.

    It cannot be cleared according to eCAN manual related description. Would you please kindly help? Thanks!

    Best Regards,

    Linda

  • Linda,
    CCE bit is set in response to CCR bit being set. CCR bit can either be set manually (before configuring the Bit-timing registers, for example) or it is set by the CAN module upon a bus-off condition. It is likely the node is going into bus-off, which is what is causing CCR bit to be set and CCE bit as well. Could customer confirm if node is indeed in bus-off condition? Were error-frames noticed before this happening. Please look at the debug tips in my app.note SPRS876 and check if any point is applicable in this situation.

    Were the 3 nodes operating properly for sometime before this problem is seen?
    Any problem seen with the other 2 nodes?
  • Linda,

     

    I need clear answers to the following questions before we can make any progress:

     

    1. Could you confirm if node is in bus-off condition? If this is the case, node will not participate in communication.
    2. Any problem seen with the other 2 nodes?
    3. Were error-frames noticed on the bus before this happening?
    4. Were the 3 nodes operating properly for some time before this problem is seen?

  • Hello Hareesh,

    Please kindly find my update:

    1.Could you confirm if node is in bus-off condition? If this is the case, node will not participate in communication.

    A: Yes, it's in bus-off condition.

    2.Any problem seen with the other 2 nodes?
    3.Were error-frames noticed on the bus before this happening?
    4.Were the 3 nodes operating properly for some time before this problem is seen?

    A: There are 3 slave nodes(all are F2812) on the CANopen bus. When the master hasn't been connected into the bus, all these 3 slave nodes are OK for sending data(send one data per second). But when the master is connected, only one slave node can send data but the other two cannot send data anymore and CCE bit has been set together with that FE and CRCE bits are set.

    Would you please kindly help? Thanks!

    Best Regards,
    Linda
  • Linda,

                You have not answered my question #3 (about error frames).

     

    Let's call the slave nodes A, B & C and the master node as "D". You are saying nodes A, B & C communicate with each other without any problem, but once the Master (D) is connected, two nodes go into  a bus-off condition.

    1. Is this correct?
    2. What happens if you connect the Master (D) to each one of the slaves at a time? i.e. only one slave node at a time?
    3. Did you review the debug checklist in my app.note? Specifically the one pertaining to termination?

     

    Please answer each one of the above questions clearly.

  • Hello Hareesh,

    Customer has found out this issue has been related with PCB layout and they are still doing further test. Thank you for your kind help.

    Best Regards,

    Linda