UART refactoring.