GPIO with Android

Hi All!
Is there a possibility to control GPIO on Rock PI 4 with an Android java application? I’ve seen there are some old versions with GPIO drivers, but is there Android 7 or above image with tested GPIO capability?

bump
Anyone knows something on the subj?

You can control gpio by reading and writing ‘/sys/class/gpio’ files

Great!, can you give a detailed example of how to control each of the 40 pins? and how to set up the i2c, Spi, and serial outputs?

Kind regards

We have plans to port libmraa to android, just wait for the good news

2 Likes

I found some GPIO libraries while browsing the Armbian forums, maybe they can help:

Is there any update on this topic?
I am running Rock Pi 4B in Android 10 and want to access the GPIO, I2C, SPI etc…

Any update on this? I am considering changing from Odroid to this board due to the official Android 12 support, but I don’t know why this hasn’t been handled out of the box from the beginning.
On the Odroid, google.android.things are available for use, enabled by some make files before building aosp.