Hello,
i have configured a timer interrupt an it seems like that interrupt preempt another adc interrupt.
I configured the timer interrupt like that:
NVIC_SetPriority(TIM1_BRK_IRQn, 2U);
NVIC_SetPriority(TIM1_UP_IRQn, 2U);
and the adc interrupt like that:
NVIC_SetPriority(ADC1_2_IRQn, 1U);
So my expectation would be that no preemption occurs from timer interrupt because priority is 2 (priority lower then ADC interrupt priority).
To check if the interrupt priority of timer interrupt is the root cause of preemption i set it to 8 and 9 and the adc interrupt with prio 1.
In this case the preemption from timer interrupt i measured has been gone. For my understanding it should make no difference setting the timer interrupt priority to 2, 8 or 9 because in all cases the priority is higher then adc interrupt with priority 1.
Additional hints:
Priogroup has been set to 0 for all implementations.
There is no other interrupt that might cause some trouble here
I attached some files that are showing the register configurations.
Best regards
Shaheen