I am using the nRF52 Preview board, PCA 10036. I need to provide a high-frequency clock signal to a peripheral. Anything between 1 and 4 MHz will work. However, I don't need and don't want the CPU to receive an interrupt on every clock pulse.
I think that the GPIOTE example in the SDK is relevant to my needs. (I'm using SDK 0.9.2.) However: the code has a function called timer_dummy_handler(). While this function does nothing, the code does connect it to a timer event, with a call to nrf_drv_timer_init(). The documentation for nrf_drv_timer_init() says that an event handler function is a required argument.
The GPIOTE example code has a timer frequency of 200 milliseconds. Calling a quick and useless function five times/second is harmless. Calling that same function 1-4 million times / second would be a nightmare.
Is that function call actually used?
Can I avoid attaching a function call to a timer event, if I program at a lower level?