CAN0 send cause bus off error, Bit0 Error

  • Basic Info:

hardware: jetson-agx-orin-devkit
JetPack : 6.2
Jetson Linux : 36.4.3

  • cansetup:

ip link set can0 up type can bitrate 500000 restart-ms 100 berr-reporting on
ip link set can1 up type can bitrate 500000 restart-ms 100 berr-reporting on

can0/ can1 pinmux is already config as wiki

0x0c303018 ==> 0x0000C458
0x0c303010 ==> 0x0000C400
0x0c303008 ==> 0x0000C458
0x0c303000 ==> 0x0000C400

  • test case

in my custom carrier board, short the can0 and can1 to test

test case1: can0 receive and can1 send test fine, can0 can receive all the data from can1

candump can0

cansend can1

test case2: can1 receive and can0 send test failed with bus off and Bit0 Error as below

candump can1

cansend can0

[ 684.018315] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.018348] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.018402] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.018455] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.018509] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.018574] mttcan c310000.mttcan can0: entered bus off state
[ 684.018576] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 684.139862] mttcan c310000.mttcan can0: Bit0 Error Detected

any idea for this bug? seems like the official carrier board also have this issue. which i measure the carrier board signal

I also try using a usb-can box to test:(usb-can-box and can0, can1 all link in)

usb-can-box send, can0 and can1 both can receive data

can1 send, usb-can-box and can0 bot can receive data

can0 send, the issue above is trigger

what if I try

cansend can0 123#12345678 in the while loop, I got below errors

[ 735.090912] mttcan c310000.mttcan can0: entered error warning state
[ 735.090915] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.090919] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 5 is occupied!
[ 735.090930] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 6 is occupied!
[ 735.090932] mttcan c310000.mttcan can0: entered error passive state
[ 735.090939] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 7 is occupied!
[ 735.090949] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 8 is occupied!
^C
root@ubuntu:~# [ 735.090959] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 9 is occupied!
[ 735.090965] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.090968] mttcan c310000.mttcan can0: can_put_echo_skb: BUG! echo_skb 10 is occupied!
[ 735.091019] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091072] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091127] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091182] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091235] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091289] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091343] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091396] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091450] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091504] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091558] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091612] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091666] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.091735] mttcan c310000.mttcan can0: entered bus off state
[ 735.091736] mttcan c310000.mttcan can0: Bit0 Error Detected
[ 735.206292] mttcan c310000.mttcan can0: Bit0 Error Detected

I mainly test on 64G module, also try on 32G module and got the same error too

*** Please note that this reply is generated by LLM automatically ***

Based on the provided context, it appears that you are experiencing an issue with the CAN bus on your custom carrier board for the Jetson AGX Orin. Specifically, when you try to send data from CAN0 to CAN1, it works fine, but when you try to send data from CAN1 to CAN0, it fails with a “Bit0 Error” and the CAN bus enters a “bus off” state.

After reviewing the provided information, I noticed that there are several other threads and discussions related to CAN bus issues on the Jetson Orin platform. Here are a few potential leads to investigate:

  1. CAN bit rate: In one of the threads, it is mentioned that the CAN bit rate needs to be set correctly. You have already set the bit rate to 500000, which is the same as the default value. However, you may want to try setting it to a different value to see if it makes a difference.
  2. Pinmux configuration: You mentioned that the pinmux is already configured as per the wiki. However, it’s possible that there is an issue with the pinmux configuration. You may want to double-check the configuration and try resetting it to its default values.
  3. CAN transceiver: The CAN transceiver is a critical component in the CAN bus setup. You may want to check if the transceiver is properly configured and if it’s working correctly.
  4. Signal integrity: You mentioned that you measured the signal on the official carrier board and it seems to have the same issue. This could indicate a problem with the signal integrity on the CAN bus. You may want to try using a different cable or connector to see if it makes a difference.
  5. Software configuration: It’s possible that there is an issue with the software configuration. You may want to try updating the JetPack version or reinstalling the CAN bus drivers.

In comparison to other threads, it seems that there are similar issues reported on the Jetson Orin platform. For example, in the thread “Jetson Orin Nano - CAN RX not working, CAN TX only works with Loopback enabled”, the user is experiencing a similar issue where the CAN RX is not working. However, in that case, the user was able to resolve the issue by enabling the loopback mode.

In another thread, “CAN bus sample code for Jetson AGX Orin somewhere?”, the user is asking for sample code for the CAN bus on the Jetson AGX Orin. While this thread is not directly related to your issue, it may be useful to review the sample code provided in the thread to see if it helps resolve your issue.

In summary, it’s likely that the issue is related to the CAN bus configuration or signal integrity. You may want to try troubleshooting the issue by checking the pinmux configuration, CAN transceiver, and signal integrity. Additionally, you may want to try updating the JetPack version or reinstalling the CAN bus drivers. If none of these solutions work, you may want to try contacting NVIDIA support for further assistance.

*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***

Hi m_o_bz,

How do you short them?
Do you connect them through 2 CAN transceivers or you just connect CAN0_TX to CAN1_RX and CAN0_RX to CAN1_TX?

Connect the CAN_H and CAN_L not the CAN_TX and CAN_RX

Do you mean that you have 2 CAN transceivers added in your case and you’ve connected CAN-H to CAN-H and CAN-L to CAN-L already?
If so, what’s the CAN transceiver in use?

Have you also verified the internal loopback test for CAN?

can0 ←→ tja1057 ←→ TD501MCAN ←→ can1

CAN0 internal loopback test is fine

Can you use the same CAN transceivers to verify?

Do you have 120Ohm resistor as terminator in your setup?

test case 1:

on the original design, just swap the can0 and can1

can1 ←→ tja1057 ←→ TD501MCAN ←→ can

the result is : can0 receive and send fine, but can1 can only receive, can not send

which means the issue maybe lies in the tja1057

test case 2: replace the tja1057

  can0 ←→ TD501MCAN ←→ TD501MCAN ←→ can1

the result is the same: can0 can only receive, can1 receive and send fine

maybe two TD501MCAN can not work fine together

Yes , on both end, there are 120 ohm resistor

Have you tried using 2 tja1057?

How did you determine can0 can not send?
Do you get a scope to check its signal? Or you hit the similar bus off issue in original post?

Nope, haven’t test with two tja1057 yet

Test using command below

candump can0 & cansend via can1

In the scope the signal is wired and the message is same as below, the same busoff error as the original post

Please also verify if 2 tja1057 can work.

Could you also specify the data bitrate in the command as following?

$ sudo rmmod mttcan
$ sudo modprobe mttcan
$ sudo ip link set can0 up type can bitrate 500000 dbitrate 1000000 berr-reporting on 

I would suggest you reload the mttcan driver once you get the bus off issue.

How do you determine that CAN1 receive fine while CAN0 cannot send?

Please share the details of your waveform for further check.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.