# Non Inverting Type 2 and 3 compensators

I'm looking for the topology and transfer function of a non-inverting type 2 and 3 compensators (PID controller). they are used in CC and CV feedback control in charging/Discharging circuits of batteries. I did not find documents that can help me to design them. Could you please help me find somthing important about designing these compensators ?? Here is descriptif circuit of this kind of compensators

Not familiar with the name "compensator" but both of them are integrators, with the type 2 also doubling as a low pass filter,

Any voltage difference across the inputs will cause the output to maintain a constant ramp up or down, which is usually used to trim out small offsets over time, in these circuits a small DC bias on the input will lead to a DC offset on the output that grows with time

Type 2 as such tends to cancel out most of the higher frequencies, as the change does not stick around long enough for it to change the output much,

Type 3 adds the extra capacitors to allow a AC gain of greater than one,, assuming C1 and C3 are roughly equal in size and C2 is small, you have a capacitor divider, so Vout =~ Vin, technically this can be used to make the AC signal larger or smaller, where Type 2 can only make the AC signal smaller,

VSET looks to be a DC bias adjustment possibly to keep the integrator trimmed towards 0V or some other level, I would expect this to be a quite small voltage,

Due to this, I would say a Type 2 is for adding a pole where you desire, while a Type 3 is for adding a zero where you desire (eventually the op amps own bandwidth will add back in a pole)

As for designing them for your application, if you want to plot out how they will behave, your adjusting the capacitors to have certain impedance at certain frequencies, from there you can use something like this to work out what that gain will be for that frequency,

Differential op amp gain calculation

There are better tools such as using spice "bode plots", however as I have not used them myself, I am not familiar with how involved they are to set up. this just gives you a pole / zero plot for the circuit, if you set up what the pole/zeros of your input is you can then see how they combine.