INTM not working as expected

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

INTM not working as expected

827 次查看
Janeting123
Contributor I

I have a very confusing problem here.

My chip model is S32K312.

The clock configuration selected is option B. The STM clock is 48M, and the INTM clock is 60M

When the STM timing interrupt is 100ms, my test is as follows:

Janeting123_0-1731391143271.png

 

Janeting123_1-1731391155138.png

 

(0x00DBBC06 - 0x00927E0A)/ 48000 = 99.99    According to the value of STM.CNT, we can know that the STM interrupt is triggered as expected, but INTM_STATUS is still 0.

The value of INTM_LATENCY needs to be further reduced before INTM_STATUS changes to 1.

Janeting123_2-1731391170323.png

 

 

This is also the case when the STM timer interrupt interval is 300ms

Janeting123_3-1731391198265.png

 

 

Janeting123_4-1731391212037.png

 

Janeting123_5-1731391230455.png

 

 

I think already I have been very careful to use the INTM interface, but I still don't know where the problem lies

Janeting123_6-1731391255802.png

 

 

 

 

 

 
0 项奖励
回复
3 回复数

792 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi

INTM allows you to set a maximum timer count for the interrupt latency from interrupt request to interrupt acknowledge. This mechanism monitors the latency of interrupt sources to ensure that these critical interrupts execute within the expected time frame, increasing the reliability of the chip.

Try adding a delay before INTM_IACK instead of increasing the timer period.

Best Regards,
Robin
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 项奖励
回复

763 次查看
Janeting123
Contributor I

I saw your private message, but I can't reply there.

here is my answer

这个帖子我早就看过了,INTM这个模块并不复杂,只有几个寄存器,功能也比较简单,容易理解,但最后就是出现了令人费解的问题,你提到的这个可能性是不存在的,我提问的截图里有STM_CNT的数值,我的断点就是打在了callback中的Intm_Ip_AckIrq函数上,证明两次运行到Intm_Ip_AckIrq的间隔是符合预期的。我也怀疑过难不成STM坏了,改去监控PIT的中断,用STM_CNT作辅助验证,最后还是一样,PIT中断是预期触发,监控结果却总是出错,我注意到一个很奇怪的现象,观察寄存器,STATUS要想为1TIMER必须大于LATENCY的值,理论上,中断的周期是固定的情况下TIMER的数值每次应该相差不大,但我发现,在监控PIT的时候TIMER的数值会随LATENCY变化而不是中断周期,在监控STM的时候,STM周期变化很大,TIMER的值却几乎不变

附截图

0 项奖励
回复

760 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport
0 项奖励
回复