I am using ATmega8.
I am trying to understand pwm set-up. I read many tutorials but I want confirmation that I undestand it.
For pwm, timer goes up and down to a TOP value, there is a compare level (OCR1AH, OCR1AL). When the timer reach this levels, a flag is shown.
So for me, the compare level set the duty cycle and the TOP level the frequency.
However, I do not understand how to set the actual value of the TOP... I dont understand where this is define.
Sorry for this stupid question... :oops: