Processor Expert Generated Interrupts

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

Processor Expert Generated Interrupts

跳至解决方案
1,297 次查看
eduardoumana
Contributor III

I created a KDS Project for the K22F Board. Under "Components" I see there are Interrupts and gpio pins already added. I am trying to toggle the RGB LED with interrupts so I went through I/O and renamed some pins etc... I also enabled an interrupt on rising edge for SW2 as seen in the image below:

16160_16160.jpgInterrupt.JPG.jpg

I expected to see an interrupt service routine function in Events.c to write my code but there isn't any. How can you auto generate this code?

 

As a side question, can anybody point me to a good resource for developing with KDS?

标签 (1)
标记 (3)
0 项奖励
1 解答
728 次查看
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Eduardo:

Your observation is correct. Right now PEx + KSDK does not generate ISR functions. If you open one of the KSDK examples (C:\Freescale\KSDK_1.0.0\demos) you will see that the interrupt functions are declared in a fsl_xxx_irq.c file, where xxx is the module. In your case you need to add or copy the file fsl_gpio_irq.c from (C:\Freescale\KSDK_1.0.0\platform\drivers\gpio) to your project.

By the way, I think this will be improved in the next release of PEx for KSDK and the interrupt handlers will be included automatically in Events.c as you suggested.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

在原帖中查看解决方案

0 项奖励
2 回复数
729 次查看
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Eduardo:

Your observation is correct. Right now PEx + KSDK does not generate ISR functions. If you open one of the KSDK examples (C:\Freescale\KSDK_1.0.0\demos) you will see that the interrupt functions are declared in a fsl_xxx_irq.c file, where xxx is the module. In your case you need to add or copy the file fsl_gpio_irq.c from (C:\Freescale\KSDK_1.0.0\platform\drivers\gpio) to your project.

By the way, I think this will be improved in the next release of PEx for KSDK and the interrupt handlers will be included automatically in Events.c as you suggested.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
728 次查看
bosleymusic_com
Contributor IV

I can't answer the PE question, as I've avoided that like the plague as it just seems like one more layer of abstraction away from the hardware where something could go wrong.

As far as the side question, there's a blog I found and was later also pointed to by one of the freescale employees : MCU on Eclipse | Everything on Eclipse, Microcontrollers and Software

There are lots of entries on various topics, but many related to FRDM, Eclipse, KDS, etc...

There's also the documentation for the SDK API and demo applications in the docs folder of the respective root directories.

0 项奖励