Hi,
We use custom board using i.MX8M Mini.
And we try to change OS based on Linux for i.MX (Linux 5.4.70_2.3.0).
We have some additional GPIO for output and input.
Could you please let us know how to set these direction in kernel?
We need to change device tree? Could you please show example?
Also, we need to get and set the value of GPIO in user space.
Any help would be appreciated.
Thank you.
Best regards,
Solved! Go to Solution.
Hi TANAKA
>Could you please let us know how to set these direction in kernel?
>We need to change device tree? Could you please show example?
not possible to set direction and set the value of GPIO in device tree, one can
set them in uboot, example:
>Also, we need to get and set the value of GPIO in user space.
one can look at example
https://variwiki.com/index.php?title=MX8M_GPIO&release=RELEASE_HARDKNOTT_V1.0_DART-MX8M-MINI
Best regards
igor
Hi TANAKA
>Could you please let us know how to set these direction in kernel?
>We need to change device tree? Could you please show example?
not possible to set direction and set the value of GPIO in device tree, one can
set them in uboot, example:
>Also, we need to get and set the value of GPIO in user space.
one can look at example
https://variwiki.com/index.php?title=MX8M_GPIO&release=RELEASE_HARDKNOTT_V1.0_DART-MX8M-MINI
Best regards
igor
Hi,
Thank you for your reply.
We referred to your URL and could set GPIO in uboot.
Also, we could set and get the value GPIO via /sys/class/gpio.
Best regards,