Move some of the gcode processing into a simple task loop.
This should avoid lockups when we need to wait for something to complete (blocks other ISRs).
The majority of the system is still interrupt driven.