FRDM-KL26Z development board: are the two possible TPM interrupts individual?

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

FRDM-KL26Z development board: are the two possible TPM interrupts individual?

跳至解决方案
611 次查看
gabrielflueran
Contributor I

Hello everybody.

I am currently working on a FRDM-KL26Z development board  and trying to implement an input signal's Dutycycle measurement using the INPUT CAPTURE function of a TPM. However, the same TPM may have some channels configured for PWM signal generation in the meantime, using its EPWM function.
By my question I mean, if I set the TOIE flag and a CHnIE flag, will both of the interrupts (timer overflow & channel interrupt) be generated and possibly be treated in the same handler?

Thank you in advance for your responses.
Gabi F

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

Hello Gabriel Flueran:

The two interrupts are independent, so they both can be activated.

Actually the interrupt vector is the same, so the interrupt handler must be shared and you need to check the flags to see which interrupt triggered.

I hope this helps.


Regards!,
Jorge Gonzalez

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

在原帖中查看解决方案

0 项奖励
1 回复
423 次查看
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Gabriel Flueran:

The two interrupts are independent, so they both can be activated.

Actually the interrupt vector is the same, so the interrupt handler must be shared and you need to check the flags to see which interrupt triggered.

I hope this helps.


Regards!,
Jorge Gonzalez

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

0 项奖励