Fixed small bug with the code that generates pwm using TMR1