* Misc fixes and improvements
- Get rid of most critical sections on the Serial port drivers for AVR and DUE. Proper usage of FIFOs should allow interrupts to stay enabled without harm to queuing and dequeuing.
Also, with 8-bit indices (for AVR) and up to 32-bit indices (for ARM), there is no need to protect reads and writes to those indices.
- Simplify the XON/XOFF logic quite a bit. Much cleaner now (both for AVR and ARM)
- Prevent a race condition (edge case) that could happen when estimating the proper value for the stepper timer (by reading it) and writing the calculated value for the time to the next ISR by disabling interrupts in those critical and small sections of the code - The problem could lead to lost steps.
- Fix dual endstops not properly homing bug (maybe).
* Set position immediately when possible
* Work around for serial buffer over run
PronterFace sends a lot of M105 commands. During long operations such
as UBL's G29 P1, G29 P2, G29 P4 and G26 this can over run the serial
buffer. This results (very often) in a M1 (actually a M1M105) ending
up in the command queue.
Until we figure out a better way to resolve this issue, this will keep
the UBL commands from experiencing bogus commands at thier completion.