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

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

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

Jump to solution
489 Views
carlesls
Contributor II

carlesls_0-1731922632278.png

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

Thank you. 

Labels (1)
0 Kudos
Reply
1 Solution
436 Views
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

View solution in original post

3 Replies
373 Views
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 Kudos
Reply
325 Views
Celeste_Liu
NXP Employee
NXP Employee

Yes, I think you should add this.

0 Kudos
Reply
437 Views
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