Part Number:MSP432P401R
Hi,
I have a motion sensor attached with Digital Output of the sensor is connected to PM0 of controller.
I have configured the PM0 pin for edge triggered but my ISR is not being invoked.
Is it allowed to raise interrupt for PM0? (If I scan the input pin PM0, I see that level changes as expected but does not trigger interrupt)
My code snippet :
int myVar; int main(void) { /* Call driver init functions */ Board_init(); motionSensorInit(); /* Initialize the GPIO since multiple threads are using it */ GPIO_init(); setupOneSecTimer(); /* Start the TI-RTOS scheduler */ BIOS_start(); return (0); } void gpioMotionSensorInt(uint_least8_t index) { myVar++; } void motionSensorInit() { myVar = 0; GPIO_setConfig(GPIO_MOTION_SENSOR, GPIO_CFG_IN_PU | /*GPIO_CFG_IN_INT_RISING*/ GPIO_CFG_IN_INT_BOTH_EDGES); GPIO_setCallback(GPIO_MOTION_SENSOR, gpioMotionSensorInt); GPIO_enableInt(GPIO_MOTION_SENSOR); }