keever50 commented on PR #16281:
URL: https://github.com/apache/nuttx/pull/16281#issuecomment-2840225926
Okay gave it another shot, it was my USB port that decided it was tired
today.
I apologize for the removal of the previous message, it wasn't accurate
anymore.
@linguini1
I'm not able to get this to trigger an interrupt. Is this code correct?
Is it possible that you can give me a testing code / snippet to run that
also worked for you?
This way we can make sure nothing breaks.
```C
int rp2040gpio_interrupt(int irq, FAR void *context, FAR void *arg)
{
syslog(LOG_DEBUG, "HELLO!");
rp2040_gpio_put(BOARD_GPIO_LED_PIN, false);
return 0;
}
void rp2040_boardinitialize(void)
{
#ifdef CONFIG_ARCH_BOARD_COMMON
rp2040_common_initialize();
#endif
/* --- Place any board specific initialization here --- */
rp2040_gpio_init(2);
rp2040_gpio_setdir(2, false);
int ret = rp2040_gpio_irq_attach(2,
RP2040_GPIO_INTR_EDGE_HIGH |
RP2040_GPIO_INTR_EDGE_LOW,
rp2040gpio_interrupt,
NULL);
rp2040_gpio_enable_irq(2);
}
```
I expected the LED to turn off and a message to appear after an interrupt on
pin 2.
This did not happen and it appears the ``rp2040gpio_interrupt`` is not
triggered.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]