You and I think alike I suggested that here:
On a high level, Interrupting every 50ms to run a 5-6ms background task will also add randomly 5-6ms delays in your user code, unless you wrap sensitive code with __disable_irq(); and __enable_irq();
__disable_irq();
__enable_irq();