Optimizing UARTReader implementation

Applying limits to integer ranges so that we don't waste memory. Also
removing some conditions and using a proper shift register instead.