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.

TMS320F280049: CAN-A data in buffer is different with the data sending out

Part Number: TMS320F280049

Hi,

CAN-A (CAN_OUT) and CAN-B (CAN_IN) share one interruption function in boot-loader. It needs CAN-A and CAN-B during firmware upgrade.

The data in CAN-A buffer is not same with the data sending out. The error data in buffer is 06 00 2C.

Check other registers are correct, except it read CAN-B register when get base address. 

Here is the code.

2577.code.docx

Actual data:

The reading base address is CANB's.

  • Hi Daniel,

    Do you intend to use CAN A and CAN B in the example you shared?

    If yes you are configuring the ISR to get interrupt on CAN B in DCDC_CANMBOXS_Init(). That is something i can't see in the code shared. I thing you are configuring CAN B as receive that is why you are seeing the base address in Read Message.

    Again your question is not clear.

    Regards
    Harshmeet
  • Hi,

    It can jump into interruption 0. My question is why it can't jump into interruption 1 when it has configured CAN-A and CAN-B interruption. Thanks.
  • Hi Daniel,

    What do you mean by interruption 0?

    Thanks and Regards
    Harshmeet Singh
  • Hi Harshmeet,

    interruption 0 is CAN_INT_IE0
    interruption 1 is CAN_INT_IE1
  • Hi Harshmeet,

    Is there any comment? Is it the code setting problem? Thanks.
  • Daniel

    Regarding interrupts, each CAN instance (ex: CANA or CANB) has its own set of interrupt lines 0 and 1. CANA can be setup to use its own line0 interrupt and CANB can be setup to use its own line0 interrupt. These interrupt lines won't be shared. Not sure why you are using line1 for CANB.

    Now if you're trying to trigger an interrupt based on CAN status or CAN error, then only interrupt line 0 can be used.

    It isn't clear what is trying to be accomplished. Can you clarify the following:
    1. What is the responsibility/tasks of CAN-A
    2. What is the responsibility/tasks of CAN-B
    3. What is a summary of the problem that is being observed?

    Best regards
    Chris
  • Hi

    I haven’t heard from you for 2 weeks, so I’m assuming you were able to resolve your issue. If this isn’t the case, please reject this resolution and reply to this thread. If this thread locks, please click the "Ask a related question" button and in the new thread describe the current status of your issue and any additional details you may have to assist us in helping to solve your issues.

    Regards,
    Chris