implementing soft usart + timer2 driver