Adding configuration for user defined baudrate. Cleaning the code.