A PWM controller compensates a maximum output power of a power converter
having a power switch. The PWM controller includes an oscillator for
generating a saw signal and a pulse signal, a power limiter coupled to
the oscillator for generating a saw-limited signal in response to the saw
signal, and a PWM unit coupled to the power limiter and the oscillator to
generate a PWM signal for controlling the power switch in response to the
saw-limited signal and the pulse signal. The saw-limited signal has a
level being flattened during a period of time before an output voltage is
generated, and is then transformed to a saw-limited waveform after the
period of time.