Electronics > Projects, Designs, and Technical Stuff
LM358 Buck Regulator with Voltage & Current control
FromSkyToEnd:
Hello all, I've been fiddling a bit with electronics lately, and decided to try an design a buck regulator using a 555 timer chip for pwm control... Got that working but it didn't have any feedback, so I started playing around with an op-amp to control the 555 timer but at one point I though, what if I drive the mosfett directly from the op-amp? I though that would be way too simple but I gave it a try and to my surprised the circuit worked!
https://www.circuitlab.com/circuit/aq2pdvpy4bw5/lm358-buck-regulator/
As far as I know I have not seen any buck regulator circuits that used a simple op-amp to control switching, at least from what I could find. So I decided to share my circuit, I will be using this as my bench power supply for other electronic devices. the high current parts was salvaged from old atx power supplies.
I would love some feedback! I've not really made many circuits and I'm kinda impressed this one works but hey, I'm sure there's room for improvement or perhaps I'm doing something very wrong! After all I wonder why I don't find circuits similar to this.
description from the schematic:
--- Code: ---Provides 0v-20v DC with current limiting function from 24v and 5v DC input
M1, D1, L1 and R7 will determine the max current.
R7 is the sense resistor so should be able to handle getting hot since it can be dissipating over 10w of heat at 10a loads
D3 should give somewhat of an indication when current limiting is applied
The circuit employs M2 as a signal inverter as well to be able to drive a high power MOSFETT from a 5v signal but this also means that the switch will be normally closed if the op amp circuit fails and might cause an issue if you care about that.
The main logic of this circuit is the op-amp will turn off to raise the output voltage and turn on to lower the output voltage. This allows to combine voltage and current limiting without more logic I think. Since this circuit acts as an oscillator the frequency is limited by C3
Due to the high capacity of C2 it's possible when changing load or adjusting voltage/current that it delivers more voltage/current than desired for a short time, could probably improve on the output filtering but I opted for large capacity in cases when I wanted more current
Strongly suggest using active cooling for M1 and D1. M2 should have passive heatsink
--- End code ---
T3sl4co1l:
Yikes! Not sure what timestep and duration to run for. Seems to be very slow (<1kHz?) and still very high ripple. Which is as one should expect from that op-amp.
Why not LM393?
Here's an example using a 555, that follows good design practice (peak current mode control):
https://www.seventransistorlabs.com/Images/555%20Boost.pdf
Beware that various resistors/setpoints/bias may not work so well at different supply voltages...
Here's one with no ICs*, just transistors; okay over a modest supply range (say 8-16V):
https://www.seventransistorlabs.com/Images/Discrete_Tube_Supply.png
*TL431 hardly counts as an IC, it's a transistor with 2.50V Vbe, trust me! ;)
Tim
FromSkyToEnd:
Oh! Thanks for the examples :) I agree the switching frequency isn't super high, but I managed to get 10khz to 18khz when i was using a 47n cap on my breadboard, but yes there is ripple there, especially in higher/changing loads! But for my purposes I'll mark it as acceptable, seems to be okay usually, but "okay" is certainly not a high bar here. I haven't managed to have a collection of op-amps, LM358 are what i had on hand but I'll have to investigate getting something better!
As for the circuitsim i have not prepared it for simulation, I've built the circuit on breadboard before putting it in the circuit, here's what my newbie soldering work looks like :P in the picture I'm powering an LED straight from it
I know I'm missing a lot of the technical knowledge around coils and buck regulator but I'm happy to learn from mistakes!
Edit: I think one of my issue with the 555 and why I decided to try without it is I couldn't get mine to oscillate stably at high frequencies, likely due to the breadboard stray capacitance
FromSkyToEnd:
Welp just tried the LM393 and now the mosfett is always on... I either need to go back to the drawing board or I got a defective chip
T3sl4co1l:
Note that LM393 needs a pullup on its output.
Tim
Navigation
[0] Message Index
[#] Next page
Go to full version