Hi, I'm having some problems with interrupts. I want the available pin GIO to trigger an interrupt in my code. So far I have started with bdk_blinky and been able to read the pin configured as such:
Sys_DIO_Config(PIN_GIO_SPARE, DIO_NO_PULL | DIO_LPF_ENABLE | DIO_MODE_GPIO_IN_0);
I am trying to understand the API on how to configure interrupts. I have tried this:
Sys_DIO_IntConfig(0,
DIO_DEBOUNCE_ENABLE |
DIO_SRC_DIO_0 |
DIO_EVENT_HIGH_LEVEL,
DIO_DEBOUNCE_SLOWCLK_DIV32,
0);
experimenting with the parameters. I have implemented:
void DIO0_IRQHandler(void){
LED_On(LED_BLUE);
}
with breakpoint. It never hits.
Can anyone explain what index and DIO_SRC_DIO_* means in this context and what I can use? Should I use another library?
I tried to modify the bdk_button to use the PIN_GIO_SPARE pin instead of button0, but to no avail.