Unsolved gpio error
-
@SGaist
thank you for the reply
Sorry its Emteria.os
i was told to
the gpios are accessable
Make sure those files are accessible from your application. Check Linux file permissions. and how do i check for these permissions? -
@tinashe said in gpio error:
and how do i check for these permissions?
ls -lh /sys/class/gpio/unexport
You should read about UNIX/Linux basics.
To get access for the group your user is in:chmod g+rw /sys/class/gpio/unexport
For user
chmod u+rw /sys/class/gpio/unexport
-
@jsulm
thank you very much
how do i run this in my main file or c++ file because i have seen these commands run in cmd terminal. -
@tinashe said in gpio error:
how do i run this in my main file or c++ file because i have seen these commands run in cmd terminal
Why do you want to do it in your app? Just do it once in a terminal...
The commands I provided to set access rights need root access (via sudo for example):sudo chmod g+rw /sys/class/gpio/unexport
So, your app will not be able to do this.
But you should really check how access rights are handled in Emteria.os -
@jsulm said in gpio error:
For user
unfortunately i can not do it on the terminal.
or can i do this in the cmd.txt found in boot folder? -
@jsulm
unfortunately the ssh server is locked for demo which am using currently -
@tinashe See "man 2 chmod".
But most probably your user will need to start the app as root (sudo for example). -
i was told to do permission seeting in /data/init.d
-
@jsulm
chmod g+rw /sys/class/gpio/unexport
cd /etc/udev/rules.d/
touch local.rules
ACTION=="add", KERNEL=="gpio", MODE="0666"
and did notwork -
@tinashe This does not have anything to do with Qt now, please find out how to do this with Linux.
-
@jsulm
thank you very much will do that