how to set up a keyboard interruption to a gpio pin?

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

how to set up a keyboard interruption to a gpio pin?

跳至解决方案
1,902 次查看
carlesls
Contributor II

carlesls_0-1731922632278.png

How do you set up a keyboard interruption to the PTA1 and PTA3 pins?

Thank you. 

标签 (1)
0 项奖励
回复
1 解答
1,846 次查看
Celeste_Liu
NXP Employee
NXP Employee

Hello carlesls,

Thanks for your post. 

Regarding how to configure PTA1 and PTA3 as KBI Pins, you can use the pin tool of the MCUXpresso Configuration Tool to complete it. For specific operations, you can refer to the attached video recording.

For more configuration questions, you can refer to the following web pages. I believe they will be very helpful.

Kinetis Processor Expert Keyboard Interrupt - NXP Community

Solved: External interrupts on KBI pins of MKE04Z - NXP Community

If this post answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!

Best Regards,

Celeste

在原帖中查看解决方案

3 回复数
1,783 次查看
carlesls
Contributor II

Should I add this? Thank you. 

 

SIM->SCGC |= SIM_SCGC_KBI0_MASK;

KBI0->PE |= KBI_PE_KBIPE_MASK;

 

KBI0->ES |= KBI_ES_KBEDG_MASK;

 

KBI0->SC |= KBI_SC_KBMOD_MASK;

 

NVIC_EnableIRQ(KBI0_IRQn);

0 项奖励
回复
1,735 次查看
Celeste_Liu
NXP Employee
NXP Employee

Yes, I think you should add this.

0 项奖励
回复
1,847 次查看
Celeste_Liu
NXP Employee
NXP Employee

Hello carlesls,

Thanks for your post. 

Regarding how to configure PTA1 and PTA3 as KBI Pins, you can use the pin tool of the MCUXpresso Configuration Tool to complete it. For specific operations, you can refer to the attached video recording.

For more configuration questions, you can refer to the following web pages. I believe they will be very helpful.

Kinetis Processor Expert Keyboard Interrupt - NXP Community

Solved: External interrupts on KBI pins of MKE04Z - NXP Community

If this post answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!

Best Regards,

Celeste