Compensation for a switching regulator is attained by developing a
compensation signal for a switching regulator that is independent of
changes in the switching frequency. The regulator operational frequency
is established in accordance with a repetitive ramp signal of constant
slope and adjustable frequency. The voltage of the ramp signal is
monitored and an offset signal is derived therefrom. The peak value of
the ramp signal, detected during monitoring, is used to derive the offset
signal. Initiation of the compensation occurs at the same duty cycle
point during each switching cycle and thus is independent of switching
frequency. The compensation signal may have a linear or non-linear slope.