Refactoring uart to a class