Because of the Thanksgiving holiday in the U.S., TI E2E™ design support forum responses may be delayed the week of November 23.

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.

TMS320F28P650DK: CAN bit timing issue

Part Number: TMS320F28P650DK

Hello TI support Team,

I am working on CAN and CAN FD protocol.

In my product i need to do CAN FD to FO conversion.

I select MOXA ICF1171I device to convert CAN FD to FO but it is working fine when i tried to send CAN frame but whenever i tried with CAN FD frame it is given error every time and also in MOXA ICF 1171I has few setting to changing arbitration rate and data rate so it is done as per baud rate but still it is giving error at transmit side so suggest me what should i do and how to calculate baud rate as well and FYI i tried with your example mcan_ex9_transmit which is 500kbps arbitration rate and 1mbps data rate but still it is not working.

so look into this and help me out from this.

Thank you in advance and if anything required more information let me know.

Thank,

Rutvik Kajavadra

  • Hi Rutvik,

    Your issue is almost certainly a data phase bit timing mismatch between the TMS320F28P650DK and the MOXA converter. Classic CAN frames work because they only use nominal (arbitration) bit timing. CAN FD frames fail because they additionally require the data phase timing parameters to match precisely between both nodes.

    A known problem with the TI SDK examples (including mcan_ex9_transmit) is that the default bit timing parameters are irrational values that produce incorrect bit rates (e.g., 615 Mbps instead of the intended rates) 1. Even if the MOXA device is configured for 500 kbps / 1 Mbps, the actual timing on the TI side won't match.

    What You Need To Do

    1. Recalculate Bit Timing Parameters

    Do not rely on the default example values. Use TI's MCAN Bit Timing Calculator to generate correct values for your setup:

    • Tool: Calculator for CAN Bit Timing Parameters (SPRAC35) 1
    • Inputs needed: Your MCAN clock frequency (CPU clock ÷ MCAN clock divider), target nominal rate (500 kbps), and target data rate (1 Mbps)
    • Outputs: Correct values for nomRatePrescalar, nomTimeSeg1, nomTimeSeg2, nomSynchJumpWidth, dataRatePrescalar, dataTimeSeg1, dataTimeSeg2, dataSynchJumpWidth

    2. Match Sample Points

    Ensure the sample point percentage on both devices is identical. Typical CAN FD configurations use ~80% sample point for arbitration and ~75-80% for data phase. Check the MOXA ICF1171I settings and match accordingly.

    3. Enable Transmitter Delay Compensation (TDC)

    For CAN FD data phase operation, you likely need TDC enabled. Set the MCAN_DBTP.TDC bit to 1 and configure MCAN_TDCR.TDCO (offset) to approximately half your data phase bit time in time quanta 2. Without TDC, if the transceiver loop delay exceeds TSEG1 of the data phase, a bit error is detected on every CAN FD frame.

    4. Verify CAN FD Mode Configuration

    Confirm these bits are set in your MCAN configuration 2:

    • MCAN_CCCR.FDOE = 1 (CAN FD operation enabled)
    • MCAN_CCCR.BRSE = 1 (bit rate switching enabled)
    • FDF and BRS bits set in your Tx Buffer element

    5. Additional Checks

    • Ensure your CAN transceiver supports CAN FD signaling rates
    • Verify 120Ω termination at both ends of the bus
    • Confirm the MOXA device's CAN FD settings match your calculated timing exactly

    Information Needed From You

    To provide more specific guidance, please share:

    • Your MCAN clock divider setting (e.g., SYSCTL_MCANCLK_DIV_5)
    • The exact arbitration/data rate settings configured in the MOXA ICF1171I
    • Any error status register values from the MCAN module (MCAN_PSR register)

    Follow up: Can you share the exact bit timing register values (NBTP and DBTP) currently programmed in your code, along with your MCAN clock divider setting, so we can verify whether the calculated bit rates actually match 500 kbps / 1 Mbps?


    1. TMS320F28P650DK: MCAN communication - Issue Receiving Classic CAN (E2E Forum)
    2. TMS320F28P65x Technical Reference Manual - MCAN Bit Timing
    3. C2000 MCAN Application Report (SPRACU9)
    4. TMS320F28P65x Datasheet - MCAN Overview

    Best Regards,

    Zackary Fleenor

  • Hi Rutvik,

    Any feedback or additional information needed to help your proceed? Can you share the requested information here?

    Best Regards,

    Zackary Fleenor