How can I set automatically export and change direction of GPIO at start Android (5.0.2). I want to avoid the need to manual entering:
echo 140 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio140/direction
commands in root console.
Problem solved - by mistake I put code in wrong section of init.rc:
write /sys/class/gpio/export 142
write /sys/class/gpio/gpio142/direction out
chmod 777 /sys/class/gpio/gpio142/value
Hello,
In which section did you insert these commands in the init.rc?
on boot?