Orin pinmux update

When I set up pinmux through the command line, it works normally. But every time I need to execute relevant commands after booting up, and root permission is always required, which will lead me to give root permission to the exec file. Considering security, is there a more secure way, such as modifying the device tree.
According to pinmux-changes guide, i downloaded Orin Series Pinmux,modified the definition of some pins like this:

According to this link How to change uart to gpio in orin? - #7 by KevinFFF, the sub table choose correct.

In last process of generating a cfg file at the end, according by this link compiling-kernel-for-nvidia-jetson-xavier-nx, when i use python to generate cfg file, error had happen


I modified pinmux-dts2cfg.py to line 184 to line = line.replace("TEGRA234_MAIN_GPIO(",""), and face another error:

My question is have I made a mistake in a certain step or whether orin does not need to generate a cfg file? Can I use regular user privileges to enable gpio?

this is my gpio.dtsi and pinmux.dtsi
gpio.dtsi (3.8 KB)
pinmux.dtsi (65.8 KB)

Hi alive,

What’s your carrier board for Orin NX?
What’s your Jetpack version in use?

What commands do you run after boot up everytime?
May I know what’s your use case?

Yes, Orin series doesn’t need to use pinmux-dts2cfg.py to generate the .cfg file.
Please refer to the following instruction to update custom pinmux for Orin NX.
(You just need to put the three dtsi files to correct directory respectively)
Jetson Orin NX and Nano Series — Generating the Pinmux dtsi Files

it’s customed carries board for jetson orin nx,Jetpack version is JetPack_5.1.2.
The command used is like this:
image
i want reuse gpio pin in camera trigger, and it need to init gpio pin output the high and low levels.

Something I’m confused about is how to implement board.conf

You could just refer to this instruction step-by-step to configure the custom pinmux for your desired pins.
You don’t need to use python script to generate .cfg file. (that is for T194 series).

Is there any issue when you are generating dtsi from pinmux spreadsheet?

After I move the generated files to the specified directory, my flash job failed.

sudo ./tools/kernel_flash/l4t_initrd_flash.sh --external-device nvme0n1p1 -c tools/kernel_flash/flash_l4t_external.xml -p "-c bootloader/t186ref/cfg/flash_t234_qspi.xml" --showlogs --network usb0 p3509-a02+p3767-0000 internal

what let me confused is that:

After copying the files, ensure that you point these files to the new board.conf file that you created for your board. Refer to Flashing the Build Image for more information.

how to point these files to the board.conf? how to found the board.conf file?

<Linux_for_Tegra>/p3509-a02+p3767-0000.conf is the board config you are using to flash your board.

Could you flash the board successfully with the command you provided before any changes?

yes,the system boot smoothly

Sorry about what I said flash job failed, because i had chosen the wrong folder.
when i can flash job with two modified gpio.dtsi and pinmux.dtsi copy, the system not have any change, in /sys/class/gpio/export folder not show new sub directory, not have new gpio node appear.

Update the pinmux is just update the default pin configuration like input/output, high/low.
It would not affect the stuff under /sys/class/gpio/export.
You still need to export them before you want to control them, but you will find their default state according to the pinmux configuration.

May I know what is your use case?

Do you know how to use command line install cuda env to orin, both connect with a USB cable. i’m not want to use sdkmanager to install, because i want to partition the hard disk.

understand. so my driver should run with root privileges

You could use the following commands on your board to install nvidia-jetpack, which should include cuda.

$ sudo apt update
$ sudo apt install nvidia-jetpack
1 Like

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