Patent ID: 8213203

Claim:
A controller for a switched mode power supply (SMPS) including a transformer having a primary winding equipped with a switch, the controller comprising: an output terminal for providing a power supply control signal to turn on and off the switch in the primary side of the power supply; a first input terminal for receiving a feedback signal related to an output current of the power supply, the feedback signal exhibiting a ringing waveform when the flow of the output current substantially stops; a second input terminal for receiving a current sensing signal, which is related to a current in the primary winding; a constant voltage control circuit coupled to the first and second input terminals and configured to produce a constant voltage control signal; a current flow detector circuit coupled to the first input terminal and configured to produce a conduction time interval signal; a time ratio signal generator circuit configured to produce a fixed time ratio signal the time ratio signal generator circuit having a conduction time compensation circuit configured to receive the conduction time interval signal and produce a compensated conduction time interval signal; a flip-flop configured to provide a constant current control signal in response to the conduction time interval signal and the fixed time ratio signal; and a first logic gate coupled to the constant voltage control signal and the constant current control signal and configured to produce the power supply control signal.