Skip to content
View in the app

A better way to browse. Learn more.

Learn more

How to match GPIO number for export?

Featured Replies

Hi,

 

Armbian_21.02.3_Odroidc1_focal_current_5.10.21

 

how do I find out which number do I need to provide to gpio export command?

Let's say I have physical pin 16, which is labeled by the manufacturer as `GPIOX.5` or `102`.

But that doesn't work with Armbian:

echo 102  > /sys/class/gpio/export

 

[ 1602.030617] export_store: invalid GPIO 102

How do I know the value to provide for /sys/class/gpio/export?

 

# cat /sys/kernel/debug/gpio
gpiochip1: GPIOs 413-428, parent: platform/c8100084.pinctrl, aobus-banks:
 gpio-416 (                    |TF_IO               ) out lo
 gpio-417 (                    |usb-hub-reset       ) out hi
 gpio-426 (                    |c1:blue:alive       ) out hi ACTIVE LOW

gpiochip0: GPIOs 429-511, parent: platform/c1109880.pinctrl, cbus-banks:
 gpio-456 (                    |regulator-tflash_vdd) out lo
 gpio-470 (                    |PHY reset           ) out hi ACTIVE LOW
 gpio-482 (                    |cd                  ) in  hi ACTIVE LOW
 gpio-492 (                    |reset               ) out hi ACTIVE LOW

Thanks

Edited by cvxx

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.