Jetson AGX Orin enable CAN3

Hi,

I’m trying to enable CAN3 on our own designed carrier board

but I can’t find any document related to it

I check the pinmux spreadsheet and find out CAN3 is unused by default

Can anyone help me about this

Thanks

Kevin

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

Enabling CAN3 on a custom-designed carrier board for Jetson AGX Orin requires careful consideration of several factors. Since you’ve already checked the pinmux spreadsheet and found that CAN3 is unused by default, I’ll provide a step-by-step guide to help you enable it.

Prerequisites:

  1. Familiarize yourself with the Jetson AGX Orin Module Adaptation and Bring-Up guide, specifically the section on “Configuring the Jetson Expansion Headers”.
  2. Ensure you have the latest Jetson AGX Orin datasheet and pinmux spreadsheet.

Step 1: Pinmux Configuration

  1. Open the pinmux spreadsheet and locate the CAN3 pins (TX and RX).
  2. Verify that the CAN3 pins are not used by any other peripheral or function.
  3. Configure the pinmux to assign the CAN3 pins to the CAN3 peripheral.

Step 2: Device Tree Configuration

  1. Modify the device tree file (e.g., tegra194-p2888-0001-p2822-0000.dtb) to enable CAN3.
  2. Add the following node to the device tree:
&can3 {
    status = "okay";
    nvidia,can-ctrl = <0x01>;
};

This node enables the CAN3 controller and sets the control register to 0x01.

Step 3: Kernel Configuration

  1. Ensure that the CAN3 driver is enabled in the kernel configuration.
  2. Modify the kernel configuration file (e.g., config) to include the following line:
CONFIG_CAN_J721E=y

This enables the CAN driver for the Jetson AGX Orin.

Step 4: CAN3 Clock Configuration

  1. Verify that the CAN3 clock is enabled in the clock configuration.
  2. Modify the clock configuration file (e.g., clocks.txt) to include the following line:
can3_clk: can3 {
    compatible = "nvidia,can-clk";
    clocks = <&bpmp TEGRA194_CLK_CAN3>;
    clock-names = "can3";
};

This enables the CAN3 clock.

Step 5: Testing and Validation

  1. Compile and flash the modified device tree and kernel to your carrier board.
  2. Use a CAN bus analyzer or a CAN-enabled device to test the CAN3 interface.

Comparison with Other Jetson Modules

The process of enabling CAN3 on Jetson AGX Orin is similar to that of other Jetson modules, such as Jetson Orin NX and Nano. However, the specific pinmux and device tree configurations may vary depending on the module and carrier board design.

Additional Resources

For more information on CAN bus configuration and troubleshooting, refer to the following resources:

  • Jetson AGX Orin Module Adaptation and Bring-Up guide
  • Jetson AGX Orin datasheet
  • Linux CAN bus documentation

I hope this helps you enable CAN3 on your custom-designed carrier board for Jetson AGX Orin. If you have further questions or need additional assistance, feel free to ask!

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

Hi

I can’t the key work above such as tegra194-p2888-0001-p2822-0000.dtb, CONFIG_CAN_J721E, TEGRA194_CLK_CAN3

I did find TEGRA234_CLK_CAN2 definition under

nv-public/include/kernel/dt-bindings/clock/tegra234-clock.h

But there is no TEGRA234_CLK_CAN3

Can I just simply add one to it ?

Thanks

Kevin

Hi kevintseng83,

What’s the Jetpack version in use?

There’re only 2 CAN interfaces(CAN0 and CAN1) available for AGX Orin.
Please share how did you configure related pins in pinmux spreadsheet.

Hi kevin

we just follow can0 pinmux setting

Please share the result of the following command on your board.

$ cat /etc/nv_tegra_release
$ cat /etc/nv_boot_control.conf

Those pins can not be used for CAN, they(e.g. CAN3_DOUT) are just the naming.
I guess you configured the can3 for nvidia,function in pinmux dtsi manually as there’s no option available for CAN in pinmux spreadsheet as following.

Here is the result

Yes we notice that from pinmux spreadsheet all CAN3 pin show unused

and we don’t know how to change from spreadsheet since all the function group is undefined

do you mean we can not enable CAN3 through changing these config?

Kevin

Yes, CAN3 can not be used for CAN usage.

Please refer to Chapter 16. CAN of AGX Orin Design guide, there’re only 2 CAN interfaces(CAN0 and CAN1) can be used.

Hi,

Thanks for the promptly reply, we got it

Thanks

Kevin