MKE16Z LPIT timer is not working.

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

MKE16Z LPIT timer is not working.

617件の閲覧回数
KumarBalaji
Contributor I

Dear Friend,

                I am using MKE16Z MCU in my project. In that, I am using LPIT0 for periodic interrupt operation. I have taken the code reference from the SDK example. 

               Interrupt operation is not working, but the LPIT0 counter is running. Also, LPIT0 counter interrupt operation flag is set. Even I have enabled the interrupt in NVIC vectors.

  debug_bug.png

SDK Version: 2.11.0

IDE Version  : 11.5.0

 

Thank in advance.

                

 

0 件の賞賛
返信
3 返答(返信)

160件の閲覧回数
PlsDontDisturbMe
Contributor I

Sorry but can i have your code to configure LPIT please? I have tried but cant make it work. I set PCS,CGC and then turn on M_CEN, but i still not get access to configure the rest of the module like MSR, SETTEN, CLRTEN, TCTRL

 
0 件の賞賛
返信

601件の閲覧回数
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi,

I suppose that you do not enable interrupt. Pls add the lines:

__NVIC_EnableIRQ(PIT_CH0_IRQn);

__NVIC_SetPriority(PIT_CH0_IRQn,0x00);

__asm("cpsie i");

Pls have a try

Hope it is helpful

BR

Xiangjun Rong

 

596件の閲覧回数
KumarBalaji
Contributor I

Hello Xiangjun,
Thanks for your reply.
I will try your solution. Also, I have come up with one more solution,
I have removed a grounding resistor on Pin no.33(PTD2).
Previously it was pulled to the ground by a 22kohm resistor, after removing it the Interrupt started working.


BR
Kumar Balaji

0 件の賞賛
返信