AWRL6844EVM: MCAN demo

Part Number: AWRL6844EVM

Tool/software:

Hello,
So, I've been working with various demos on the WRL6844 EVM demo board. Mostly going well. Trying to get the MCAN External Read Write to work. Have the Read Me file of course.
I can see it spit out the first CAN message, right now I have it on the scope. So, then, I know that it will be waiting for a response but doesn't get to that point. Below is from can_external_read_write.c.  Right after line 173 I see the message transmit on the scope. There is no assert on line 174 and it passes to line 177 waiting for TX completion. It never returns from that call.
Any ideas what is going on? Also trying to step into that function SemaphoreP_pend but CCS can't find Semaphore_nortos.c. I feel like there is a way to pull in paths for files but can't figure it out.
Thanks.
Mike
  • Hey Mike,

    Thanks for posting your question regarding MCAN. My guess is here that you're either not getting an acknowledgement of the CAN message or a bit error is occurring during message transmission. Listed below are a few notes on design needs or possible error causes, though I would also recommend reviewing the following application note on CAN physical requirements:

    • There must be at least two CAN nodes for acknowledgement
    • Both ends of the CAN line should be terminated with a 120 ohm resistor between the CAN low and CAN high lines to prevent reflections from impedance mismatching
    • There must be isolated common ground for the bus to prevent noise injection
    • Ensure the bus length does not exceed the supported baud rate
      • The High-Speed ISO 11898 Standard specifications are given for a maximum signaling rate of 1 Mbps with a bus length of 40 m with a maximum of 30 nodes. It also recommends a maximum unterminated stub length of 0.3 m
    • Incorrect baud rate
      • This can either be from a mismatch in the bit timing parameters or caused by tolerances in the reference CAN clock
      • In the case of the latter, note that different bit timings will require different clock tolerances

    Let me know if any of this helps or if there are further issues.

    Cheers,

    Kristien

  • Hi Kristien,

    Thank you for your response. I will review all of that although we have been developing products with CAN for many, many years. I will ask specifically though if the code never returning from line 177 would indicate no ACK or a bit error. It seems that this point in the code we are just waiting for the transmission to complete. And I do see the data string on the scope. I have stepped into SemaphoreP_pend and don't see any code that is looking for an ACK. But ... I'll keep trying.

    Regards,

    Mike

  • Hey Mike,

    I will ask specifically though if the code never returning from line 177 would indicate no ACK or a bit error.

    Yes, this will cause the code to effectively stall since the semaphore is only posted on successful transmission, and this example does not handle CAN errors.

    And I do see the data string on the scope.

    Can you verify if there is any NACKs or bit errors based on scope shots? That would be the more direct approach rather than checking the CAN registers or additional software debug.

    Regards,

    Kristien