I.MX 8M MINI SYSFS GPIO Control Issue

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

I.MX 8M MINI SYSFS GPIO Control Issue

ソリューションへジャンプ
1,260件の閲覧回数
dan_hilgert
Contributor II

I am trying to use GPIO1_IO11 as a digital output.

Here are the commands I using in kernel space:

echo 11 > /sys/class/gpio/export

echo out > /sys/class/gpio/gpio11/direction

echo 0 > /sys/class/gpio/gpio11/value

The pin state is high no matter what.

I cat the files in /sys/class/gpio/gpio11/ and I don't see anything obviously wrong. 

I have verified the pin is not being used by any other nodes in the device tree. 

Has anyone ran into this before? Can anyone point me in the right direction to identify what I am doing wrong here? 

Thanks 

0 件の賞賛
返信
1 解決策
1,253件の閲覧回数
igorpadykov
NXP Employee
NXP Employee
0 件の賞賛
返信
2 返答(返信)
1,243件の閲覧回数
dan_hilgert
Contributor II

igor, thanks for the pointer. 

I had added the specific pin node with the info for the pin I wanted to control.

dan_hilgert_1-1608145762250.png

 


However, I was not adding the pinctl-0 property in the iomuxc node.

dan_hilgert_0-1608145626314.png

Once I did that, I had full control over the pin. 

Thanks again,

Dan

 

0 件の賞賛
返信
1,254件の閲覧回数
igorpadykov
NXP Employee
NXP Employee

Hi dan_hilgert

 

for i.MX8M Mini gpio usage one can look at:

https://variwiki.com/index.php?title=DART-MX8M_GPIO&release=RELEASE_DUNFELL_V1.0_DART-MX8M-MINI

 

Best regards
igor

0 件の賞賛
返信