lpcware

LPC43xx Interrupts with PINTSEL1 are not working

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by sadfsdf on Wed Oct 21 03:18:15 MST 2015
Hello guys,
i was working with with Proximity Sensor and I need to get interrupt from it.
the problem is that I already have 4 interrupts so PINTSEL0 is full. And i tried to do the same with PINTSEL1..but it s not working. And When i try to change it to PINTSEL0 it works. Do you have any ideas about that. Here is my code.
void proximityInt_init(const DRV_EXTERNAL_INTERRUPT_CALLBACK newProximityInt1Callback)
{
proximityInt1Callback = newProximityInt1Callback;
nvicDisableVector(PIN_INT7_IRQn);
/* Setup GPIO6 Pin 15 */
palSetPadMode(6, 12, PAL_MODE_INPUT);
/* Set up GPIO6 Pin 15 as interrupt */
//LPC_SCU->PINTSEL1 |= ((0x6 << 5) | 0xc) << 24;
LPC_SCU->PINTSEL1 |= (6 << 29) | (0xC << 24);
LPC_GPIO_PIN_INT->IST |= 0x80; // Clear interrupts
LPC_GPIO_PIN_INT->ISEL &= ~0x80; // Edge sensitive
LPC_GPIO_PIN_INT->SIENR |= 0x80; // Enable rising interrupts
LPC_GPIO_PIN_INT->SIENF |= 0x80; // Enable falling interrupts
/* Enable interrupts */
nvicEnableVector(PIN_INT7_IRQn, CORTEX_PRIORITY_MASK(2));
}

Outcomes