refer to the attachment, i have a question to ask regarding ripple in the nagative feedback system.
The result waveform of the current sinking at PMOS is showing some ripples, hence the voltage at the gate to the PMOS is showing some ripples too. But they are antiphase. Will the ripple of the voltage at the gate cause the feedback system not working or will it causes instability? The ripple is about 100mV. If i reduce the capacitor size, the ripple even bigger around 400mV! Is it dangerous?
It seems to me the system is already oscillating. You have no compensation in the loop. Did you actually do a stability analysis?
One other thing to try is insert some resistance (1kΩ) in series with the gate of the MOSFET. If the oscillations are due to the opamp seeing too high a capacitive load, then this resistor should eliminate them.
But most likely you will need to do a stability analysis and compensate the opamp adequately.
It seems to me the system is already oscillating. You have no compensation in the loop. Did you actually do a stability analysis?
One other thing to try is insert some resistance (1kΩ) in series with the gate of the MOSFET. If the oscillations are due to the opamp seeing too high a capacitive load, then this resistor should eliminate them.
But most likely you will need to do a stability analysis and compensate the opamp adequately.
Actually the phase margin for that loop is 70 degree. From the waveform, it look like the voltage at PMOS gate is more like ripple compare to oscillting.