How to access GPIO on Android


您好,关于gpio的number号,是如何计算的?为什么GPIOH5: 176



I understand how to get to root with su for the GPIO.

For the other options, how do you do it ?

2 Let the 3rd application as system process

Is this one just putting the app in priv-app in the rom ?

3 Open the permission for 3rd application on system

This one i don’t know how. Can you point me in the right direction ?



You also need a system signature for the app.

You need to modify source code of the direction system/sepolicy


Thank you, I will try the 2nd way.


Hello Terry ,
My understanding is that the gpio path in linux systems is “/sys/class/gpio/”.

I would like to know is it the same for even android systems?


Yes, it’s the same. :grinning:


Thank you very much Terry.