I’m working with updating pinmux for Jetson Xavier NX. I follow the threads and the documentaion and I tried to update pinmux.
- From excel → dtsi files
- From pinmux tool inside sdk —> cfg file
- Update system using “flash.sh”
I have a question regarding the command line export for the new configuration inside /sys/class/gpio. It seems that the pinmux direction remain the old one. I’m able to change manually but I want to understand why this happen.
Take GPIO01 for example. His references are:
- GPIO01 on schematic
- SOC_GPIO41 Ball name
- Letter Q, position 5 → offset 133
- Base GPIO: 288
- Gpio command line to export: 421
In the original pinmux .cfg file (tegra19x-mb1-pinmux-p3668-a01) this was an input
pinmux.0x02430028 = 0x0000005a; # soc_gpio41_pq5: rsvd2, pull-up, tristate-enable, input-enable, io_high_voltage-disable, lpdr-disable
In new config file this is an output
pinmux.0x02430028 = 0x00000406; # soc_gpio41_pq5: rsvd2, pull-down, tristate-disable, input-disable, io_high_voltage-disable, lpdr-disable
I checked if I really applied these modifications (if pinmux really was updated using flash) typing the following command on command line:
root@videosystems-jnx-ing:/home/videosystems# cat /sys/kernel/debug/tegra_pinctrl_reg | grep "soc_gpio41" Bank: 0 Reg: 0x02430028 Val: 0x00000406 -> soc_gpio41_pq5
As I see, the configuration is applied. Going to /sys/class/gpio, I exported the gpio421. As I see the gpio is configured as “Input” and not like I’m expected “Output”.
root@videosystems-jnx-ing:/sys/class/gpio/gpio421# cat direction in
I checked all the others (from GPIO01 to GPIO14) and all are compliant with the original gpio configuration not with my new configuration.
Where is my mistake?