Hello, i am running AN5413 s32k14x Series Cookbook examples, more exactly i trIed the s32k144_Project_HelloInterrupts. First i run the code with S32 Design Studio and the lpit0 interrupt is working, but when i try to run with IAR ide same code, the lpit0 interrupt can't be reached by the breakpoint. Did anyone tried to test lpit0 interrupt in IAR? Could anyone explain me what i should do?
Thank you.
Hi, PTD0 LED stays high(lit) all the time. I run the app and the interrupt is enabled, timer is counting and resets:
LPIT0_MIER->TIE0 1
LPIT0_TCTRL->T_EN 1
NVIC_ICPR[1] - 0x00004000
NVIC_ISER[1] - 0x00010000
PCC_LPIT - 0xC6000000
-PR 1
-CGC 1
-PCS 0x6
I can't figure it out why the same code doesn't work in IAR, maybe do i have to set something specific in IAR configuration?
Thank you for reply.
Hello,
Please check PRIMASK core register.
Thanks,
Daniel
Hi, the PRIMASK register is 0 all the time, maybe this will help?
Hello,
Unfortunately, I don't use IAR, so I can't test it.
But if you get an exception, you can debug that.
There are many documents describing Cortex M4 exceptions on the internet.
For example: IAR Debugging a HardFault on Cortex-M
Regards,
Daniel
Hello,
Is the LPIT ISR toggling the PTD0 output?
Can you check the LPIT and NVIC registers in IAR whether the interrupt is enabled or not?
Thanks,
Daniel