AnsweredAssumed Answered

MPC5748g of Processor Expert add External Interrupt question

Question asked by kris ke on Aug 2, 2018

Dear Sir

 

I use the DEVKIT-MPC5748G to do external interrupt and the DEVKIT of button are PTA3 and PTE12.

 

 

 

I am stuck for a while with External interrupt, I can trigger PTE12 into interrupt, but the PA3 can't trigger interrupt.

 

I use S32_SDK_MPC574xx_BETA_0.9.0 of enet_ping sample code.

 

 

Below is my initial code.

 

void GPIOInit(void)

{

    /* Set Output value LEDs */

    PINS_DRV_ClearPins(LED_PORT, (1 << LED0) | (1 << LED1));

 

    SIUL2->IMCR[155] = SIUL2_IMCR_SSS(1U);

    SIUL2->IMCR[144] = SIUL2_IMCR_SSS(1U);

 

    /* Install buttons ISR */

    INT_SYS_InstallHandler(SIUL_EIRQ_00_07_IRQn, &buttonISR, NULL);

    INT_SYS_InstallHandler(SIUL_EIRQ_08_15_IRQn, &buttonISR, NULL);

 

    INT_SYS_SetPriority(SIUL_EIRQ_00_07_IRQn, 4);

    INT_SYS_SetPriority(SIUL_EIRQ_08_15_IRQn, 5);

 

    /* Enable buttons interrupt */

    INT_SYS_EnableIRQ(SIUL_EIRQ_00_07_IRQn);

    INT_SYS_EnableIRQ(SIUL_EIRQ_08_15_IRQn);

}

 

1.

And setting the "pin_mux:PingSettings" of PE.

I set the External interrupt 0 is PA3 and  External interrupt 11 is PE12.

 

 

 

2. Change Interrupt Edge to be "Rising edge"

 

3. GPIO Set to be input

 

4. Pin assigned to be SUL2/eirq/0 and SUL2/eirq11.

 

Any suggestions please.

 

 

Kris

Outcomes