Hello Guys,
Without using Android Things I need to access some GPIO ports on a custom board i.e. not supported by Android things. I have gone as far as using the ADB shell toggling the IO, so I know the hardware works.
I have written some code which uses the FileWriter to send a 1 or 0 to the value file. I have also set direction to out. I created the GPIO export using ADB shell. When I do run my app I get a "Permission Denied" in the logcat.
I have tried several options e.g. changing the init.rc to add these files as 0777 permissive but the changes never seem to happen using the init.rc. I have manually set the top level sys/class/gpio >>>> all the way down to the files but still I get the permission denied error.
What am I doing wrong ? What am I missing ? I have spent 8 days reading almost every bit of information I can. I see guys doing on Raspberry PI etc and I can do it with a Raspberry PI but not with Android based project. I am using Android 9.
I don't want my app to use bluetooth or wifi to connect to another device and then control the GPIO on that external device. I want to toggle a local pin on the devices ARM processor and see an LED go on or off.
If I am missing something to tell you or you want to see my code etc, I will gladly post it it but for now any suggestions,tips or pointing to a direction I will take. Many Thanks
Kind Regards
Jeranio