Well, if you're into scrolling thru 500+ lines of code.....
I'm just trying to make things simpler
who wants that . 500 lines of chicken scratching's, no way i would even look at it

post the simplest compliable program that shows the problem. [if you can 99.99% odds you cannot ]
code snippets generally don't cut it, we need to see the config settings, osc speed var declarations , port settings etc....
[use code tags] please
its not hard

just going through the process of making a provable example will help you confirm that the problem
is elsewhere

you keep trying to claim compiler errors , i have not seen one in core code for at least 10 years