DuinOS: small and simple rtos

One thing you should be aware of which may or may not be the problem here is that the macro that replaces delay in DuinOS assumes the task scheduler has already been started and the task scheduler is not started until after setup is called. If any code calls the delay routine in Setup your app will freeze.