I, like many others, am having issues getting the Orin AGX on Jetpack 6 to work. I’ve gotten to the point where I have a device tree overlay and can see it as an option in the expansion header configuration screen of jetson-io.py. However, I cannot get it to mark the pin as used in any way.
Below is the relevant portion of the dts file. It should be setting the pin 18 on the 40 pin header to be gpio (I need it as input).
Please also share this information so that I can know your state.
It is not supported currently.
Jetson-IO tool can only help you to enable some functions on expansion header.
By default, the unused pins are configured as GPIO/Input.
You can simply check pinmux spreadsheet for them.
So, now knowing that the default state of the pin is what I was looking for I dug into the issue a bit more. I tried declaring the pin usage though another method. It seems the BCM style pin declaration is not what I thought it was. My understanding is that it was the pin number NOT the GPIO number on the Raspberry Pi header. Big difference. So pin 18 is GPIO 24 according to this pinout document
Thank you for your time.
PIN18 of 40-pins expansion header is GPIO35.
And you can refer to the following image for details, it is also PH.00 which you may want to use in device tree.
That was my understanding. But as you can see in the code below that is NOT how it works. Following that I thought it must have meant the physical pin. That doesn’t throw an error, but it maps to the wrong pin. Only setting it as 24 (the gpio used for that pin on the raspberry pi) gives me correct output.
Python 3.10.12 (main, Feb 4 2025, 14:57:36) [GCC 11.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import Jetson.GPIO as GPIO
>>> import time
>>>
>>> # For RPi style header
>>> pin_index_mode = GPIO.BCM
>>> channel = 35
>>>
>>> GPIO.setmode(pin_index_mode)
>>> GPIO.setup(channel, GPIO.IN)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 333, in setup
ch_infos = _channels_to_infos(channels, need_gpio=True)
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 124, in _channels_to_infos
return [_channel_to_info_lookup(c, need_gpio, need_pwm)
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 124, in <listcomp>
return [_channel_to_info_lookup(c, need_gpio, need_pwm)
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 110, in _channel_to_info_lookup
raise ValueError("Channel %s is invalid" % str(channel))
ValueError: Channel 35 is invalid
>>> sig_in = GPIO.input(channel)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 393, in input
ch_info = _channel_to_info(channel, need_gpio=True)
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 119, in _channel_to_info
return _channel_to_info_lookup(channel, need_gpio, need_pwm)
File "/usr/lib/python3/dist-packages/Jetson/GPIO/gpio.py", line 110, in _channel_to_info_lookup
raise ValueError("Channel %s is invalid" % str(channel))
ValueError: Channel 35 is invalid
>>> print(f"Input on pin {channel}:\t{sig_in}")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'sig_in' is not defined
>>>