Skip to content

Instantly share code, notes, and snippets.

@Scott31393
Last active April 2, 2021 08:46
Show Gist options
  • Save Scott31393/188c8d67c2160323bf55701398175cbb to your computer and use it in GitHub Desktop.
Save Scott31393/188c8d67c2160323bf55701398175cbb to your computer and use it in GitHub Desktop.

Note about Gpio Numbering in Common CPU

NXP i.MX8

U-Boot

gpio_n = (((port) * 32) + ((index) & 31))

Kernel

gpio_n = 480 - ((bank_n * 32)  + pin_n)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment