Missing the most important Rule of Thumb.
This is an embedded device. It has a _known_ purpose.
Every software design decision should be based around this.
This clears up any code goes here (ISR/Task), or 'Use this algo'.
Literally the main point of 'Embedded'.