We tried the command "gpioget -c gpiochip4 17" and got the following log:
root@imx8ulpevk:~# gpioget -c gpiochip4 17
"17"=active
When we press the button, it also shows the active state. I checked on the EVK, and when the button is pressed, the voltage goes from 1.8V to 0V.
When I enter the gpioinfo command, I get this output:
gpiochip4 - 32 lines:
line 0: unnamed input
line 1: unnamed input
line 2: unnamed input
line 3: unnamed input
line 4: unnamed input
line 5: unnamed input
line 6: unnamed input
line 7: unnamed input
line 8: unnamed input
line 9: unnamed input
line 10: unnamed input
line 11: unnamed input active-low consumer=PowerOn
line 12: unnamed input
line 13: unnamed input
line 14: unnamed input
line 15: unnamed input
line 16: unnamed input
line 17: unnamed input
line 18: unnamed input
line 19: unnamed input
line 20: unnamed input
line 21: unnamed input
line 22: unnamed input
line 23: unnamed input
line 24: unnamed input
line 25: unnamed input
line 26: unnamed input
line 27: unnamed input
line 28: unnamed input
line 29: unnamed input
line 30: unnamed input
line 31: unnamed input
From the log, I can see that pin 17 on gpiochip4 is set as an input. What should I check to get the correct state of the pin? I'm using a pre-built Yocto image. Please let me know if I need to make any changes to the Yocto image.
Thanks