Skip to main content
Visitor II
September 18, 2025
Solved

STR73x: CAN behavior in loopback mode

  • September 18, 2025
  • 1 reply
  • 778 views

STR73xx MCU's are old, but I think the CAN operation is similar to newer parts.

This part supports loopback and loopback with silent options. I am interested in the one called just 'loopback'.

In loopback, the TX pin is active, but RX pin is disconnected from the CAN bus. TX is looped back into the RX logic.

My question is about what happens when connected to a live CAN bus, one that has traffic from other nodes.

Clearly, my MCU will not hear any external traffic, the RX logic will only hear what my MCU is sending.

But, will my MCU still honor bus state detection and arbitration, so when I tell it to transmit (and the TX pin is active) it will not collide with external bus traffic?

mark

 

 

    This topic has been closed for replies.
    Best answer by mƎALLEm

    @mafredette wrote:

    thanks for the quick reply,

    I did read and understand what you found.

    My question is whether the CAN controller will still honor the bus state and activity so the loop back transmission will not collide with other bus traffic? Or, will the CAN controller will just activate the TX pin no matter what is happening on the CAN bus, and then possibly collide with bus traffic?

    If the RX pin is completely disconnected from the bus, I guess the CAN controller will not see traffic and will just transmit when it wants. This will be a problem for me. But, if the RX pin remains connected to the collision and arbitration logic, all should be ok for me. 

    mark


    Yes this is what I'm saying. There is no monitoring on the bus since the Rx is completely disconnected from the bus. So no matter what happens on the bus that node starts to send frames at any time and that induces a collision and may be erros. So I think, that mode needs to be used for debug mode and needs to be disconnected from the bus or at least no node is transmitting on the bus except the one in the loopback mode.

    1 reply

    Technical Moderator
    September 18, 2025

    Hello,

    This is what was said in the STR73x reference manual:

    mALLEm_0-1758198846916.png

    In loopback mode, Rx sees what was sent on Tx. It doesn't care about the bus state and the arbitration as well as what is available in Normal mode where the node monitors the bus state and start of frame on Rx. Since CAN_Rx pin is disconnected from the bus and it's looped back to Tx.

    "The actual value of the CAN_RX input pin is disregarded by the CAN Core", that means neither the bus state nor the arbitration is monitored on Rx input.

    Visitor II
    September 18, 2025

    thanks for the quick reply,

    I did read and understand what you found.

    My question is whether the CAN controller will still honor the bus state and activity so the loop back transmission will not collide with other bus traffic? Or, will the CAN controller will just activate the TX pin no matter what is happening on the CAN bus, and then possibly collide with bus traffic?

    If the RX pin is completely disconnected from the bus, I guess the CAN controller will not see traffic and will just transmit when it wants. This will be a problem for me. But, if the RX pin remains connected to the collision and arbitration logic, all should be ok for me.

     

    mark

     

     

     

    mƎALLEmAnswer
    Technical Moderator
    September 18, 2025

    @mafredette wrote:

    thanks for the quick reply,

    I did read and understand what you found.

    My question is whether the CAN controller will still honor the bus state and activity so the loop back transmission will not collide with other bus traffic? Or, will the CAN controller will just activate the TX pin no matter what is happening on the CAN bus, and then possibly collide with bus traffic?

    If the RX pin is completely disconnected from the bus, I guess the CAN controller will not see traffic and will just transmit when it wants. This will be a problem for me. But, if the RX pin remains connected to the collision and arbitration logic, all should be ok for me. 

    mark


    Yes this is what I'm saying. There is no monitoring on the bus since the Rx is completely disconnected from the bus. So no matter what happens on the bus that node starts to send frames at any time and that induces a collision and may be erros. So I think, that mode needs to be used for debug mode and needs to be disconnected from the bus or at least no node is transmitting on the bus except the one in the loopback mode.