AnsweredAssumed Answered

LPC1549 GPIO Interrupt Not Invoking

Question asked by Shantanu Dhar on Aug 4, 2016
Latest reply on Oct 25, 2016 by Shantanu Dhar

I a not getting interrupt even after setting configurations. Can anybody help me finding out what wrong am I doing in the code below ?

 

#defineTEST_INT_GPIO_PORT

(1)

#defineTEST_INT_GPIO_PIN(9)

 

Chip_GPIO_SetPinDIRInput(LPC_GPIO, TEST_INT_GPIO_PORT/*port*/, TEST_INT_GPIO_PIN/*pin*/);

 

Chip_PININT_Init(LPC_GPIO_PIN_INT);

 

 

Chip_IOCON_PinMuxSet(LPC_IOCON, TEST_INT_GPIO_PORT, TEST_INT_GPIO_PIN, (IOCON_DIGMODE_EN | IOCON_MODE_INACT) );

 

 

/* Configure interrupt channel for the GPIO pin in INMUX block */
Chip_INMUX_PinIntSel(PININTCH0, TEST_INT_GPIO_PORT, TEST_INT_GPIO_PIN);

 

 

/* Enable interrupt in the NVIC */
NVIC_ClearPendingIRQ(PIN_INT0_IRQn);
NVIC_EnableIRQ(PIN_INT0_IRQn);

 

 

/* Configure channel interrupt as edge sensitive and falling edge interrupt */
Chip_PININT_ClearIntStatus(LPC_GPIO_PIN_INT, PININTCH0);
Chip_PININT_SetPinModeEdge(LPC_GPIO_PIN_INT, PININTCH0);
Chip_PININT_EnableIntLow(LPC_GPIO_PIN_INT, PININTCH0);

 

 

 

Now, when I am pressing the SW3 in LPCXpresso1549 board, I am not getting any interrupt generated. What am I doing wrong ?

Outcomes