Error amplifier with compensation questions
1) Why should the amplifier be designed to have a high gain at low frequencies and a low gain at high frequencies ?


Any real amplifier will have this characteristic because its maximum operating frequency is limited. 


  2) What is meant by crossover frequency ?


Crossover frequency in this context is the frequency at which the open-loop gain crosses 0 dB.


  3) What is meant by phase margin ?


Phase margin is the phase of the open loop gain at the crossover frequency. Low phase margin (below 45 degrees) tends to indicate ringing behavior in the control loop. High phase margin tends to indicate monotonic response to disturbances or changes in the reference input to the error amp.


  4) What is the difference between a type 2 and type 1 error amp ?


We usually talk about type 1 and type 2 compensation filters, not type 1 and type 2 error amps. 

A type 1 compensation filter is a simple integrator (it has a single pole at 0 frequency)

A type 2 compensation filter has one pole and one zero.


  5) What would be the simplest error amp I should consider looking into ?


Op-amps are commonly used as error amplifiers. They may not be simple to design, but they are widely available, affordable, and simple to use.


  Also how is the frequency changing if both the input voltages to the error amp are DC which is the reference voltage and Vout ?, is it because of the ripple on Vout ?


In simple designs, the error amplifier controls the duty cycle of the switching circuit, not the frequency. In "fixed on-time" or "fixed off-time" designs, it might control the frequency, which indirectly controls the duty cycle.

The error amplifier might have to produce a correction signal because a temperature change caused the circuit behavior to change, or because the current drawn by the load changed.

Normally, the control loop is designed so that the ripple frequency is well above the cut-off frequency of the control loop. The ripple magnitude is managed by output capacitance, not by the control loop.