How to use the GPIO External IO Expander on I.MX8M Plus EVK as GPIO interrupt ?

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

How to use the GPIO External IO Expander on I.MX8M Plus EVK as GPIO interrupt ?

ソリューションへジャンプ
1,333件の閲覧回数
Jimmychea
Contributor III

Hi, i had tried to use the IOCTL in linux to set the GPIO pin on External IO Expander on I.MX8M Plus EVK to became Interrupt pin (Rising edge trigger), but i got the error message on terminal which unable to set the rising on that GPIO pin. May i know how to solve it ?

ラベル(2)
0 件の賞賛
返信
1 解決策
1,165件の閲覧回数
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @Jimmychea,

I hope you are doing well.

Sorry for not getting back to you sooner.
 
Yes, it is possible.
 
As mentioned in the README file, the libgpiod package also uses the IOCTL within it.
Implementing the IOCTL command for the custom application is also possible.  For that one needs to make changes inside the driver to constantly monitor the interrupt on a pin. 
and the IOCTL should be answered upon the interrupt.
 
Thanks & Regards,
Dhruvit Vasavada

元の投稿で解決策を見る

0 件の賞賛
返信
5 返答(返信)
1,287件の閲覧回数
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @Jimmychea,

I hope you are doing well
 
For the configuration of the interrupt on the IO expander, One can refer to the below thread for the IMX8MM.
 
To use the particular GPIO as an interrupt(IOEXP_nINT), kindly refer to the Design files of the IMX8M Plus EVK rev. you are using.
 
Thanks & Regards,
Dhruvit Vasavada
0 件の賞賛
返信
1,269件の閲覧回数
Jimmychea
Contributor III

Expander GPIO already exposed to /dev/gpiochip5, i intend to use IOCTL command to monitor interrupt pin 8 on /dev/gpiochip5, may i know how to do that ?

0 件の賞賛
返信
1,243件の閲覧回数
Dhruvit
NXP TechSupport
NXP TechSupport
 
I hope you are doing well.
 
To monitor the event on the GPIO pin, one can use the 'gpiomon' command from the libgpiod package.  
 
Please refer to the below file for more information 
 
Thanks & Regards,
Dhruvit Vasavada

0 件の賞賛
返信
1,240件の閲覧回数
Jimmychea
Contributor III

Cannot be using IOCTL command ?

0 件の賞賛
返信
1,166件の閲覧回数
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @Jimmychea,

I hope you are doing well.

Sorry for not getting back to you sooner.
 
Yes, it is possible.
 
As mentioned in the README file, the libgpiod package also uses the IOCTL within it.
Implementing the IOCTL command for the custom application is also possible.  For that one needs to make changes inside the driver to constantly monitor the interrupt on a pin. 
and the IOCTL should be answered upon the interrupt.
 
Thanks & Regards,
Dhruvit Vasavada

0 件の賞賛
返信