how to enter LPIT0_Ch1_IRQHandler interrupt

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

how to enter LPIT0_Ch1_IRQHandler interrupt

1,639件の閲覧回数
jerryxie1
Contributor II

hi 

   I want to use LPIT0_Ch1, modify demo hello_interrupts,initial config  is as follow, enable interrupt  flag lpit_ch1,but can not enter LPIT0_Ch1_IRQHandler ,  how to enter LPIT0_Ch1_IRQHandler interrupt? TKS

pastedImage_1.png

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

1,297件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

Did you enable the interrupt?

void NVIC_init_IRQs (void) {
  S32_NVIC->ICPR[1] = 1 << (49 % 32);  /* IRQ49-LPIT0 ch1: clr any pending IRQ*/
  S32_NVIC->ISER[1] = 1 << (49 % 32);  /* IRQ49-LPIT0 ch1: enable IRQ */
  S32_NVIC->IP[49] = 0xA0;             /* IRQ49-LPIT0 ch1: priority 10 of 0-15*/
}

Also, it needs to be enabled in LPIT0_MIER register

LPIT0->MIER = 0x00000003;‍

 

Regards,

Daniel

0 件の賞賛
返信

1,297件の閲覧回数
jerryxie1
Contributor II

interrupt NVIC has enable, interrupt falg is set, LPIT0->MIER = 0x00000003,can not enter LPIT0_Ch1_IRQHandler, but can enter interrupt LPIT0_Ch0_IRQHandler!,puzzled...

0 件の賞賛
返信

1,297件の閲覧回数
yrson7
Contributor I

Dear . Daniel 

Thank you  your advice. 
I am OK, timer both LPIT0_Ch1 and LPIT0_Ch1. 

pastedImage_1.png

pastedImage_2.png

0 件の賞賛
返信

1,297件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

I don't see any reason for this.

Did you really enable NVIC interrupts 48 and 49?

Regards,

Daniel

0 件の賞賛
返信