Need help with GPIO on Jetson Orin Nano dev kit, does not work

Hi! I have a jetson orin nano dev kit that I can’t get GPIO to work. I am using jetpack 6.1. (Tried reinstall a few times)
I need suggestions to how I can get it to work.

This time I followed this tutorial (GPIO Initial Setup):

# Update the system packages
sudo apt update
sudo apt upgrade

# Install Python development tools
sudo apt install python3-dev python3-pip

# Install Jetson.GPIO globally
sudo pip3 install Jetson.GPIO

# Add the current user to the GPIO group for non-root access
sudo groupadd -f gpio
sudo usermod -aG gpio $USER        # $USER -> tor
sudo chmod 770 /dev/gpiochip*

# Log out and log back in to apply group changes

Then I checked with code under, which gave expected result:

python3 -c "import Jetson.GPIO as GPIO; print(GPIO.VERSION)"

I tested with the provided code, pin 12 did not work as expected. No blinking of led connected with a resistor. Multimeter did not show “blinking” either. Code was saved as a .py then got run in a terminal. Code was looping inside the “while True:” section until stopped with “ctrl+c”:

import Jetson.GPIO as GPIO
import time

# Pin Definitions
output_pin = 12  # BCM pin number

# Pin Setup
GPIO.setmode(GPIO.BCM)  # BCM pin-numbering scheme
GPIO.setup(output_pin, GPIO.OUT, initial=GPIO.LOW)

print("Press CTRL+C to exit")
try:
    while True:
        GPIO.output(output_pin, GPIO.HIGH)
        time.sleep(1)
        GPIO.output(output_pin, GPIO.LOW)
        time.sleep(1)
except KeyboardInterrupt:
    print("Exiting program")
finally:
    GPIO.cleanup()

Tested with some other pins to. Used this site to find pin overview (Pins view).
The led light does light up when connected to 3.3V pin to ground with a resistor.
Can I get some help to find out what is going wrong. Assume I am not the smartest as I can’t figure it out by reading the other posts about the same issue. Thanks :)

You will have to enable the GPIO in the pinmux spreadsheet then update the .dtb for the gpio to work. Also, you will need to build a hardware interface if your load on that pin is other than a scope probe.

So I found the Generating the Pinmux dtsi Files and have generated the dtsi files. Changed GPIO 7, 12, 13 → Output.

I do have some questions.
Copy the padvoltage.dtsi and pinmux.dtsi files to the <l4t_top>/bootloader/generic/BCT/ directory and copy the gpio.dtsi file to the <l4t_top>/bootloader/ directory.
and

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.

First: I do not have any other ubuntu running PC. Is this needed to change the pinmux?

Second: If that is the case. How do I do it without another ubuntu pc?

Last: If that is not the case. Where do I begin with the flashing process. Flashing help.

The spreadsheet will only run on a windows box, its in excel.
All we run is debian or ubuntu. I highly doubt that you will be able to use the tools in windows compatibility mode. Working with embedded you will need a linux box.

You don’t need a new or fancy box. An older dell 3420 workstation with NVMe installed works just fine, you can buy those all day long for under $100 on eBay. Get a KVM switch and use your monitor and keyboard on both machines. That dell 3420 is very stable compared to others even the new dells. We did use VMware but have dropped them and went back to using dedicated machines, much less headaches.

I ended up with buying a dell workstation to try with. Wille see how it goes when I get it.

1 Like