0

i have a Hyperpixel 4.0 Touchscreen, which i use one my Raspberry PI 3b+ This Touchscreen is attached directly on the 40 GPIO-Pins and a few Pins have some special Alt-modes. Out of personal Interest, I want to know more about which GPIO pin has which alt mode. Is someone able to provide me this information or tell me, how or where i can search the Alt-Mode on my raspberry pi?

Thanks

2 Answers2

1

pigs (part of the pigpio suite) will let you find the current state.

E.g. pigs mg 23 # get mode of GPIO 23

See mg

Also look at raspi-gpio.

E.g. raspi-gpio get 23

These utilities may be pre-installed on your system.

joan
  • 71,852
  • 5
  • 76
  • 108
1

Probably the simplest is to use raspi-gpio e.g.

raspi-gpio get 1 displays GPIO 1: level=1 fsel=3 alt=4 func=RXD2 pull=UP

raspi-gpio get 0-27 displays all pins on the header.

I use my program gpioreadall which lists all pins in an easily readable format.
In addition to displaying the ALT mode it decodes this into the actual function - here "TXD2"

| 0 | TXD2 | ALT4 | 1 | 27 |

Milliways
  • 62,573
  • 32
  • 113
  • 225