configure GPIO as input in imx8mp

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

configure GPIO as input in imx8mp

2,039 次查看
DEEPIKA19
Contributor I

Hi team

I would like to use the GPIO5_IO25 as a input pin in our design. By default when exported from sysfs I am getting the following value.

 

root@root:/sys/class/gpio/gpio153# cat direction

in

root@root:/sys/class/gpio/gpio153# cat value

0

 

The GPIO5_IO05 is connected to a 10k pullup but the value is 0. Please could someone suggest me on how to debug this. Should any dts changes be added for this?

 

Regards,

Deepika

0 项奖励
回复
5 回复数

2,021 次查看
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @DEEPIKA19,

In the case of the GPIO5_IO25, it should be mentioned that when a GPIO is exported in the sysfs, by default, the direction of the GPIO is set as "input," and the value is set to "zero." The processor itself drives the voltage level of that particular GPIO.

 

For the GPIO5_IO05, please confirm the voltage at the processor side of the GPIO5_IO05 before and after exporting the GPIO. 

And also, please confirm if the GPIO5_IO05 is not used in the device tree by any other peripheral.

 

Thanks & Regards,
Dhruvit.

0 项奖励
回复

1,977 次查看
DEEPIKA19
Contributor I

hi @Dhruvit ,

Thanks for your reply.

 

Regards,

Deepika

0 项奖励
回复

1,929 次查看
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @DEEPIKA19 

If this issue is resolved, then Can I mark this case to close state?

Thanks & Regards

Dhruvit Vasavda

0 项奖励
回复

1,919 次查看
DEEPIKA19
Contributor I

hi @Dhruvit ,

The issue is not resolved.

I tried to add device_init_wakeup(&client->dev, 1) as suggested but i am still facing the the same issue.

Regards,

Deepika

0 项奖励
回复

1,898 次查看
DEEPIKA19
Contributor I

Thanks for your support @Dhruvit ,

The issues is resolved making driver change in reference with similar touch drivers .

 

Regards,

Deepika

0 项奖励
回复