Hello Nordic support,
I was referring to the RTC example in nrf52 SDK where an interrupt is triggered on Compare Counter event. In the example, the interrupt is triggered just once , i.e 3 s after boot. I would like to modify the example to trigger interrupt every 3 seconds.
To achieve this, I call the function nrf_drv_rtc_cc_set() in rtc_handler as follows:
static void rtc_handler(nrf_drv_rtc_int_type_t int_type) { if (int_type == NRF_DRV_RTC_INT_COMPARE0) { nrf_gpio_pin_toggle(COMPARE_EVENT_OUTPUT); nrf_drv_rtc_cc_set(&rtc,0,COMPARE_COUNTERTIME * 8,true); } }
However, this does not have any effect and the interrupt is triggered only once after boot.
Can you please let me know how to achieve the RTC trigger an interrupt at regular interval?
Thanks,
Anusha