There is an SPIM unexpected interrupt issue which I have replicated in a totally bare-bones piece of code using no Nordic library drivers. In my bare-bones SPI code I get 2 interrupts instead of the expected 1 at the end of every SPI transaction when only the EVENTS_END interrupt is enabled. This is checked by having a volatile counter which never resets; the count should match the expected number of SPI interrupts but in fact shows double (2x) the expected number. I suspect this to be an SPI errata, but have been too busy to chase it down.
With the same setup and function code, the following handler results in double interrupts for every transaction:
Modifying the interrupt handler to this code removes the problem, keep in mind EVENTS_ENDRX and EVENTS_ENDTX are not enabled::
The other odd thing is that either clearing ENDRX or clearing ENDTX fixes the issue; both do not need to be cleared.
This is the initialisation and repeated transfer code in both the above cases:
I will post this code in the bare-bones Git repo as I'm sure others will find it useful. Meanwhile I would like to not have the extra instructions in the interrupt handler in the interests of reducing cpu cycles