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.

TMS320F28335: CAN not working. CANREC question

Part Number: TMS320F28335


Tool/software:

I'm trying to communicate two f28335 via CAN-A. I'm using the Spectrum Digital EzDSP board.

At this first moment im trying to send one message from node A to node B. The node B will just ACK the message.. I'm not reading it. So I'm setting the TRS bit on node A and im waiting for the TA bit to be set.

Both are configured with the same bit timing. I tried with 1Mbps and with 250kbps.

Its not working at all. It seems do be no activity on the bus.  The TA is never set and the TRS is never cleared. Both DSPs  indicates Error Passive State (EP) and Warning Status (EW).

The bus off bit (BO) is never set.

The CANTEC and CANREC for both of the controllers goes up and down up and down, and so on... 

Why does the CANREC for the transmitter keeps going up?? It never acts as a receiver ! (its bit TM is 1 all the time and RM is always zero).

  • Hi,

    The CAN protocol has the capability of detecting the error. But it can't correct the error if it happens. If the error happens the detected node will send an error frame to the CAN bus.

    When the TEC equals or exceeds 128, or when the REC equals or exceeds 128, the node becomes error passive and the EP flag of status register (CAN_ES) is set. The EWarn of CAN_ES register is set when TEC or REC reaches 96. 

    CAN Bus protocol defines several specific error types, each indicating a particular issue within the system. These include:

    1. Bit error

    2. Stuff error

    3. Form error

    4. CRC error

    5. ACK error

    Please check the LEC bit field of CAN_ES register. LEC indicates the last error on the CAN bus.

    The physical disruptions like faulty wiring, poor connections, or damaged cables are common sources of errors because they can corrupt data being transmitted across the network.

    The CAN transceivers are required for both CANA and CANB nodes. Does your setup include the transceivers for both CAN controllers? 

    Does TRS mean TX request (TXRQST) bit of IFxCMD register? What is TA in your message? What did you write to IFxCMD when sending the message?