MPC5604B can not enter the interrupt service routine

cancel
Showing results for 
Search instead for 
Did you mean: 

MPC5604B can not enter the interrupt service routine

443 Views
jeffcharles
Contributor III

Hi,

PIT channel 0 can work in the debug mode, the status of  related registers are shown in the attachments. But it can not enter the ISR, my configurations and ISR about INTC like this, the whole codes are in the attachments.

void intc_init(void)
{    
    /* Initialization of the exception handlers and INTC */
    EXCEP_InitExceptionHandlers();
    INTC_InitINTCInterrupts();
    
    /* Enable interrupts in INTC:
     * PIT channel 0
     *
     */
    INTC_InstallINTCInterruptHandler(pit_ch0_isr, 59, 0);    /* PIT channel 0 priority: 0 */
    
    /* Lower current priority - to enable INTC to process interrupts */
    INTC.CPR.R = 0x0;
}


/*    
 *    PIT channel 0 interrupt handler
 */
void pit_ch0_isr(void)
{
    PIT.CH[0].TFLG.R = 0x1;
    SIU.GPDO[0].B.PDO = ~ SIU.GPDO[0].B.PDO;
}

Please help me to solve the problem,thanks!

Labels (1)
Tags (2)
2 Replies

272 Views
petervlna
NXP Employee
NXP Employee

Hi,

You have to have PIT interrupt priority other then 0 if you want to trigger IVOR4 (external interrupt).

pastedImage_1.png

Peter

272 Views
jeffcharles
Contributor III

Hi Peter,

Thank you! The problem has been solved.

0 Kudos