how to change the configuration of gpio cfg file

I want to change the configuration of gpio cfg file.
But I do not know whitch file will flash to the xavier.

or other files.

Thank you !

hello Jason_888,

you could check the whole flashing messages, you’ll found the cfg file after --pinmux commands.
hence, it’s using tegra19x-mb1-pinmux-p2888-0000-a04-p2822-0000-b01.cfg.
you might also check documentation, Pinmux and GPIO Configuration for details.

Thank you!
I have tried to modify this file,it worked.

Can I control gpio at the application layer?

like below

echo 28 > /sys/class/gpio/export
echo "out" > /sys/class/gpio/gpio28/direction
echo 1 > /sys/class/gpio/gpio28/value

If we can do this,how to calculate the number of gpio? If I want to contol the gpio of N1(H52 GPIO27).

Thank you!

hello Jason_888,

  1. you may using below kernel function calls to control GPIO pins,
    for example,

  2. please refer to Jetson AGX Xavier Platform Adaptation and Bring-Up Guide,
    you may check [GPIO Changes] chapter for the examples to calculate the GPIO numbers.