connect interrupt to gpio

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

connect interrupt to gpio

跳至解决方案
840 次查看
mehdikarimibiuk
Contributor V

I have a K10 (MK10DN512ZVLL10) chip. I would like to know how I can enable interrupts, so that whenever my PTC7 goes high, my chip interrupts trigger?

I am doing a bareboard project for this with using PE.

I want to see something like this:

PTC7 = interrupt()  -------> interrupt () { do something when interrupt happens}

can you please let me know how to do this, either by using PE or without using it, whichever is better.

Thanks

Mehdi

标记 (2)
0 项奖励
回复
1 解答
628 次查看
Petr_H
NXP Employee
NXP Employee

Hi,

this can be easily handled by ExtInt_LDD component with Processor Expert where you configure which pins do you want to use and its parameters. Processor Expert generates for you a driver code and a skeleton of an event routine (into the events.c) that you can fill with your code.

If you are not familiar with Processor Expert and are using CodeWarrior 10.5 :

  1. Select the Help > Cheat sheets… from the CodeWarrior menu.
  2. Unfold the CodeWarrior Processor Expert Features and select Processor Expert Basics for CodeWarrior for MCUs. Click OK.
  3. Click the Go to Creating Project link in the Processor Expert Basics and follow the shown steps.

Best regards

Petr Hradsky

Processor Expert Support Team

在原帖中查看解决方案

0 项奖励
回复
2 回复数
629 次查看
Petr_H
NXP Employee
NXP Employee

Hi,

this can be easily handled by ExtInt_LDD component with Processor Expert where you configure which pins do you want to use and its parameters. Processor Expert generates for you a driver code and a skeleton of an event routine (into the events.c) that you can fill with your code.

If you are not familiar with Processor Expert and are using CodeWarrior 10.5 :

  1. Select the Help > Cheat sheets… from the CodeWarrior menu.
  2. Unfold the CodeWarrior Processor Expert Features and select Processor Expert Basics for CodeWarrior for MCUs. Click OK.
  3. Click the Go to Creating Project link in the Processor Expert Basics and follow the shown steps.

Best regards

Petr Hradsky

Processor Expert Support Team

0 项奖励
回复
628 次查看
mehdikarimibiuk
Contributor V

I got it. Thanks for your support.

Mehdi

0 项奖励
回复