DC to DC buck converter

DC to DC buck converter

A buck converter (step-down converter) is a DC-to-DC power converter which steps down voltage (while stepping up current) from its input (supply) to its output (load). It is a class of switched-mode power supply (SMPS) typically containing at least two semiconductors (a diode and a transistor, although modern buck converters frequently replace the diode with a second transistor used for synchronous rectification) and at least one energy storage element, a capacitor, inductor, or the two in combination. To reduce voltage ripple, filters made of capacitors (sometimes in combination with inductors) are normally added to such a converter’s output (load-side filter) and input (supply-side filter).

In this tutorial we will learn how to build and how a DC to DC buck converter works. The circuit is very basic using just one diode, an inductor and a capacitor. The switch will be a MOSFET transistor and to create the PWM signal we will use a 555 timer in the PWM configuration, boost adjustable controller or one Arduino NANO. But first let’s study a little bit of theory. We have the Buck converter circuit in the next figure where we can see the switch, inductor and capacitor and of course we add a load to the output.

2.0 Buck converter theory

Ok, so we have the next circuit. In order to study how it works, we will divide it in two stages. The ON and OFF stages. In the ON part, the switch is closed as we can see in the next figure where the diode is open becasue the cathode voltage is higher than the anode. When the switch is first closed (on-state), the current will begin to increase, and the inductor will produce an opposing voltage across its terminals in response to the changing current. This voltage drop counteracts the voltage of the source and therefore reduces the net voltage across the load. Over time, the rate of change of current decreases, and the voltage across the inductor also then decreases, increasing the voltage at the load. During this time, the inductor stores energy in the form of a magnetic field. If the switch is opened while the current is still changing, then there will always be a voltage drop across the inductor, so the net voltage at the load will always be less than the input voltage source. When the switch is ON the inductor will charge up and the voltage on the inductor will be the difference between the output and the input. But we also know that the inductor voltage is the inductance L multiplied by the inductor current derivate. As we can see in the next figure we obtain the ON current through the inductor.

When the switch is opened again (off-state), the voltage source will be removed from the circuit, and the current will decrease. The decreasing current will produce a voltage drop across the inductor (opposite to the drop at on-state), and now the inductor becomes a Current Source. The stored energy in the inductor’s magnetic field supports the current flow through the load. This current, flowing while the input voltage source is disconnected, when concatenated with the current flowing during on-state, totals to current greater than the average input current (being zero during off-state). The “increase” in average current makes up for the reduction in voltage, and ideally preserves the power provided to the load. During the off-state, the inductor is discharging its stored energy into the rest of the circuit. If the switch is closed again before the inductor fully discharges (on-state), the voltage at the load will always be greater than zero.

In this case the voltage across the inductor is the output voltage. So once again using the next figure formulas we obtain the current of the OFF part.

Ok, now if we want to obtain the output depending on the input and the duty cycle of the PWM all we have to do is to make the sum of the On and Off current equal to 0. That means that the On current is equal to the Off current. So the will give us:

So we’ve obtain that the output is the input multiplied by the duty cycle. The duty cycle of the PWM can have values between 0 and 1. So te only posible output will be equal or lower than the input. That’s why this configuration is called step down converter.

3.0 Buck converter Arduino NANO

Sincerely, this circuit has no other sense but to learn. The Arduino NANO already has a 5V linear voltage regulator that will lower the efficiency of the circuit. So the main goal is to learn how the circuit, the feedback and the PWM signal work in order to achive the desired output.
See the full part list here: 

3.1 NO FeedBack

As you can see in the schematic above we have a potentiometer connected to the analog input A0. With this potentiometer we will choose the output value between 1 and 12 volts since the maximum input voltage in this case is 12V. With the Arduino’s ADC we will read a value between 0 and 1024, next, in the code we map that value from 1 to 244 which are the values used with the analogWrite function of the arduino. With this we will apply a PWM signal on pin D3 where 1 is the lowest duty cycle and 244 the maximum. Since the arduino digital value is 5V we add a small BJT driver using one S8050 NPN and two resitors of 10k and 1k. The output of this driver is connected to the gate of the IRF4905 P-MOSFET.

Connect everything as in the schematic above and upload the next code to your Arduino and start moving the potentiometer. Observe the otput on the oscilloscope.
Download the NO FEEDBACK code here: 

Ok so ,this circuit could increase and decrease the voltage and keep that value steady for the same LOAD, in this case a 100 ohm resistor, as we can see in the picture below. But if we change the output load the discharge time of the output will change as well since for lower loads there will be a higher amount of current passing. So if the discharging time is faster or slower the duty cycle should change as well. For that we should add a feedback system to our circuit that would sense the output voltage and correct the PWM duty in order to keep the same desired value.

3.2 FeedBack

Let’s add the feedback to our circuit. As you can see in the schematic below we have a potentiometer connected to the analog input A0 as before. With this potentiometer we will choose the desired output value between 1 and 12 volts since the maximum input voltage in this case is 12V. At the output of the circuit we have nowa voltage divider that will lower the voltage from 12V to under 5 volts because that’s the maximum input voltage of the Arduino ADCs. Check the formula below to understand how the voltage divider works. If you apply a higher voltage to the input than 12V you should change the values of R1 and R2 in order to always have a voltage below 5V for the ADC.


In the code we compare this two voltages and increase or decrease the PWM width in order to keep the output constant. Just copy and upload the next code to the Arduino for this example.
Connect everything as in the schematic above and upload the next code to your Arduino and start moving the potentiometer. Observe the otput on the oscilloscope.

int potentiometer = A0;
int feedback = A1;
int PWM = 3;
int pwm = 0;

void setup() {
  pinMode(potentiometer, INPUT);
  pinMode(feedback, INPUT);
  pinMode(PWM, OUTPUT);  
  TCCR2B = TCCR2B & B11111000 | B00000001;    // pin 3 and 11 PWM frequency of 31372.55 Hz
}

void loop() {  
  float voltage = analogRead(potentiometer);
  float output  = analogRead(feedback);

  if (voltage > output)
   {
    pwm = pwm-1;
    pwm = constrain(pwm, 1, 254);
   }

  if (voltage < output)
   {
    pwm = pwm+1;
    pwm = constrain(pwm, 1, 254);
   }

   analogWrite(PWM,pwm);
}

Buck converter LM2576T-ADJ circuit

With this component we have feedback and the output will stay the same using different loads. Just make the connections, add the input capacitor to have a steady input and you’re done.

The input could be in range of 5 to 55 volts. Don’t apply higher voltage or you could burn LM2576T-ADJ component. In this case we need no external switch since the LM2576T-ADJ already has it inside it. With the feedback pin connected to the output voltage divider, the LM2576T-ADJ will change the width of the pulse depending of the output in order to keep it constant. In this case use a Schottky Barrier Rectifier diode because it has a low forward voltage. This diode will live the current flow when the switch is open.

3.0 Buck converter circuit 555 timer

This 555 configuration will create a PWM signatl and apply that signal to the MOSFET gate. The circuit works ok but it has a big problem. The output will change if we change the output load because the circuit has no feedback. Ok so we will use the next schematic for our buck converter. To create the PWM signal we will use the 555 timer with the PWM configuration. With the P1 potentiometer we can change the duty cycle of the PWM signal, and at the same time the output value. For the MOSFET you could use the IRF4905 P channel mosfet. You could always try different inductance values for the inductor and see the results.

The input could be in range of 5 to 15 volts. Don’t apply higher voltage or you could burn the 555 timer. Connect the PWM (pin 3 of the 555 timer) to the MOSFET (switch) gate. Add an output load and test the circuit. You could obtain output valuew between 1V and 15V.

143 thoughts on “DC to DC buck converter

  1. I’ve been surfing on-line more than 3 hours as of late, yet I never found
    any attention-grabbing article like yours. It is beautiful price sufficient for me.
    In my view, if all site owners and bloggers made just right
    content as you did, the web will likely be a lot more helpful than ever
    before.

  2. Heya! I know this is sort of off-topic however I had to ask.
    Does operating a well-established website like yours require a large amount of work?
    I am brand new to operating a blog but I do write in my journal on a daily basis.
    I’d like to start a blog so I will be able to share my personal experience and views
    online. Please let me know if you have any kind of ideas or tips for new aspiring bloggers.
    Appreciate it!

  3. Howdy! Do you know if they make any plugins to assist with Search Engine Optimization? I’m
    trying to get my blog to rank for some targeted keywords but I’m
    not seeing very good results. If you know of any please share.
    Appreciate it!

  4. Definitely imagine that that you said. Your favorite reason appeared
    to be at the web the simplest thing to be mindful
    of. I say to you, I certainly get annoyed even as people think about worries that they plainly don’t recognise about.
    You controlled to hit the nail upon the top as well as defined out
    the entire thing without having side-effects , other folks could take a signal.
    Will probably be again to get more. Thanks

  5. how to rape a man,viagra,1 month ago,arms,buttocks,cp,heroin,homosexual,penis enlargement
    surgery,sheila,sperm,wilma melrose,yetişkin videosu,18,
    18+ video,cannabis,child porn,cocaine,ecstasy,go url,
    how to molest,iptal,ketamine,laurence sampson,lsd,mephedrone,
    rebbeca parer,sex,sex toys,sexual enhancers,sexual
    fetish lingerie,shawn mchugh,telek?z,telekız,
    vaginal laser rejuvenation,viagra satın al,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi
    satın alındit,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi
    satın alın,xxx,çocuk pornosu,çocuk pornosudiz

  6. Great article! This is the kind of information that are supposed to be
    shared around the internet. Shame on Google for now not positioning this publish upper!
    Come on over and visit my web site . Thank you =)

  7. Do you mind if I quote a couple of your articles as long asI provide credit and sources back to your website?My blog site is in the very same niche as yours and my users would certainly benefit from some of the information you present here.Please let me know if this okay with you. Thanks!

  8. how to rape a man,viagra,1 month ago,arms,buttocks,cp,heroin,homosexual,penis enlargement surgery,sheila,sperm,wilma melrose,yetişkin videosu,18,
    18+ video,cannabis,child porn,cocaine,ecstasy,go url,how
    to molest,iptal,ketamine,laurence sampson,lsd,mephedrone,rebbeca parer,sex,sex toys,sexual
    enhancers,sexual fetish lingerie,shawn mchugh,telek?z,telekız,vaginal laser rejuvenation,viagra satın al,viagrayı çevrimiçi
    satın alın,viagrayı çevrimiçi satın alındit,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alın,xxx,çocuk pornosu,çocuk pornosudiz

  9. Great blog here! Also your website loads up fast!
    What host are you using? Can I get your affiliate link to your host?

    I wish my site loaded up as fast as yours lol

  10. Wow that was strange. I just wrote an really long comment but
    after I clicked submit my comment didn’t appear.
    Grrrr… well I’m not writing all that over again. Anyways, just wanted to say superb blog!

  11. how to rape a man,viagra,1 month ago,arms,buttocks,
    cp,heroin,homosexual,penis enlargement surgery,sheila,sperm,wilma melrose,yetişkin videosu,18,18+ video,cannabis,child porn,cocaine,
    ecstasy,go url,how to molest,iptal,ketamine,laurence sampson,lsd,mephedrone,
    rebbeca parer,sex,sex toys,sexual enhancers,sexual fetish lingerie,shawn mchugh,telek?z,telekız,vaginal laser rejuvenation,viagra satın al,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alındit,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alın,xxx,çocuk pornosu,çocuk pornosudiz

  12. I was suggested this website by my cousin. I am no longer certain whether or not this post is
    written by means of him as no one else know such detailed about my difficulty.
    You are incredible! Thanks!

  13. I’m extremely impressed with your writing skills as well as with
    the layout on your blog. Is this a paid theme or did you modify it yourself?
    Either way keep up the nice quality writing, it is rare to see a
    great blog like this one today.

  14. Normally I do not read article on blogs, but I would like to say that this write-up very compelled me to
    check out and do it! Your writing style has been surprised
    me. Thank you, quite nice article.

  15. Greetings! Very useful advice within this article!
    It’s the little changes which will make the most
    significant changes. Many thanks for sharing!

  16. you are in reality a excellent webmaster. The website loading pace is
    amazing. It sort of feels that you’re doing any unique trick.
    Furthermore, The contents are masterwork. you have done a magnificent task on this
    matter!

  17. Its such as you learn my mind! You appear to understand a lot approximately this, such as you wrote the
    guide in it or something. I feel that you simply can do with some percent to pressure the message home a bit, but other than that,
    that is magnificent blog. An excellent read. I’ll definitely be back.

  18. how to rape a man,viagra,1 month ago,arms,buttocks,cp,heroin,homosexual,penis
    enlargement surgery,sheila,sperm,wilma melrose,yetişkin videosu,18,18+ video,cannabis,child porn,cocaine,ecstasy,go url,how to molest,iptal,ketamine,laurence sampson,lsd,mephedrone,rebbeca parer,sex,sex
    toys,sexual enhancers,sexual fetish lingerie,shawn mchugh,telek?z,telekız,vaginal laser
    rejuvenation,viagra satın al,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alındit,
    viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alın,xxx,çocuk
    pornosu,çocuk pornosudiz

  19. I just could not go away your website prior to suggesting that I really loved
    the standard info an individual supply in your visitors?
    Is gonna be back often to investigate cross-check
    new posts

  20. I love your blog.. very nice colors & theme.
    Did you design this website yourself or did you hire someone to do it
    for you? Plz reply as I’m looking to construct my own blog and would like to find out where u got this from.
    many thanks

  21. Excellent beat ! I would like to apprentice while you amend your website,
    how could i subscribe for a blog site? The account helped me a acceptable
    deal. I had been tiny bit acquainted of this your broadcast provided bright clear idea

  22. Hi, i read your blog occasionally and i own a similar one
    and i was just curious if you get a lot of spam comments? If so how do you protect against
    it, any plugin or anything you can suggest? I get so much lately it’s driving me mad so any assistance is very much appreciated.

  23. Awesome blog! Do you have any recommendations for aspiring writers?
    I’m planning to start my own blog soon but I’m a little
    lost on everything. Would you suggest starting with a free platform
    like WordPress or go for a paid option? There are so
    many options out there that I’m totally overwhelmed .. Any tips?
    Bless you!

  24. You have made some really good points there. I checked on the internet to find out more about the issue and found most individuals will go along
    with your views on this site.

  25. เราได้คัดสรรแต่สิ่งดีๆมาเพื่อลูกค้าทุกท่านโดยเฉพาะ
    หากคุณมองหา เว็บหวย ที่ราคาดี
    เชื่อถือได้ เราแนะนำ
    หวยนาคา เว็บหวยออนไลน์ ที่จ่ายหนักที่สุด

  26. how to rape a man,viagra,1 month ago,arms,buttocks,
    cp,heroin,homosexual,penis enlargement surgery,sheila,sperm,wilma melrose,yetişkin videosu,18,
    18+ video,cannabis,child porn,cocaine,ecstasy,go url,
    how to molest,iptal,ketamine,laurence sampson,lsd,
    mephedrone,rebbeca parer,sex,sex toys,sexual enhancers,sexual fetish lingerie,shawn mchugh,
    telek?z,telekız,vaginal laser rejuvenation,viagra satın al,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alındit,viagrayı çevrimiçi satın alın,viagrayı çevrimiçi satın alın,xxx,çocuk pornosu,
    çocuk pornosudiz

  27. When I initially commented I clicked the “Notify me when new comments are added” checkbox and now each time a comment is added I get three emails with the
    same comment. Is there any way you can remove people from that service?
    Many thanks!

  28. Hello excellent blog! Does running a blog like this
    require a great deal of work? I have virtually no understanding of programming but I had been hoping to start my own blog soon. Anyways,
    if you have any ideas or techniques for new blog owners please
    share. I understand this is off subject however I simply had
    to ask. Many thanks!

  29. I enjoy what you guys are usually up too. Such clever work and exposure!
    Keep up the terrific works guys I’ve you guys
    to blogroll.

  30. Superb website you have here but I was curious if you knew of any discussion boards that cover the same
    topics talked about here? I’d really like to be a
    part of group where I can get feedback from other
    experienced people that share the same interest. If you have any suggestions, please let me know.

    Thanks!

  31. I need to to thank you for this excellent read!! I certainly enjoyed
    every bit of it. I have you book-marked to look at
    new things you post…

  32. Yoou аctually mаke іt appear ѕo easy togethеr witһ y᧐ur presentation however
    I to fіnd this topic to be actually ᧐ne thing which I believe I might by
    no means understand. Ιt kind of feels too complicated аnd extremely broad for
    me. I’m taking ɑ look foirward for yur subsequent post, Ι’ll try to ɡet the hang of it!

    Feel freee tߋ surf to my website; game (bancavn.org)

  33. First of all I would like to say awesome blog! I had a quick question in which
    I’d like to ask if you don’t mind. I was interested to find out how you center yourself and clear your thoughts prior
    to writing. I’ve had trouble clearing my
    thoughts in getting my ideas out there. I truly do take pleasure in writing but it just seems like the first 10 to 15
    minutes are wasted just trying to figure out how to begin. Any recommendations or hints?
    Many thanks!

  34. When I initially commented I clicked the “Notify me when new comments are added” checkbox and now each time a comment is added I get several e-mails with
    the same comment. Is there any way you can remove people
    from that service? Bless you!

  35. I blog frequently and I truly thank you for your content. Your
    article has really peaked my interest. I’m going to take a note of your blog and keep checking for
    new information about once per week. I subscribed to
    your RSS feed too.

  36. Thanks for one’s marvelous posting! I certainly enjoyed reading it, you
    will be a great author. I will always bookmark your blog and will eventually come back from
    now on. I want to encourage you to definitely continue your
    great writing, have a nice morning!

  37. вождь с ноутбуком – просто супер


    Извините, что не могу сейчас поучаствовать в дискуссии – очень занят. Но вернусь – обязательно напишу что я думаю по этому вопросу. versen видеонаблюдение, видеонаблюдение картинки и https://cheeseandwinepaintingclub.com/wordpress-resources-at-siteground/ программы видеонаблюдения

  38. หากคุณมองหา เว็บหวย ที่ราคาดี เชื่อถือได้ เราแนะนำ
    หวยนาคา เว็บหวยออนไลน์ ที่จ่ายหนักที่สุด
    3ตัวบาทละ 960
    2ตัวบาทละ 97

  39. If you wish for to obtain a great deal from this post then you have to apply
    such techniques to your won webpage.

  40. Pingback: ipsychologos
  41. I do believe all the ideas you have presented in your post.
    They are very convincing and will definitely work. Still, the posts
    are very short for novices. May you please prolong them a
    little from next time? Thanks for the post.

  42. naturally like your web site but you need to check the spelling on quite a
    few of your posts. Many of them are rife with spelling problems and I to find it very bothersome
    to inform the truth then again I’ll certainly come
    again again.

  43. Nice blog here! Additionally your web site loads up very fast!
    What host are you the use of? Can I am getting your affiliate hyperlink to
    your host? I wish my website loaded up as fast as
    yours lol

  44. We are a group of volunteers and starting a new scheme in our community.
    Your website provided us with valuable info to work on. You’ve done an impressive job and our entire community will be thankful to you.

  45. I’m not sure where you’re getting your info, but great topic.
    I needs to spend some time learning much more or understanding more.
    Thanks for fantastic info I was looking for this
    info for my mission.

  46. After I initially commented I seem to have clicked on the -Notify me
    when new comments are added- checkbox and now whenever a comment is added I get four emails with the same comment.

    There has to be an easy method you are able to remove me from that service?
    Cheers!

  47. It’s actually very complicated in this active life to
    listen news on Television, therefore I just use the web
    for that reason, and take the most recent news.

  48. Thank you for the auspicious writeup. It in truth was
    once a amusement account it. Look advanced to more delivered agreeable from you!
    By the way, how could we be in contact?

  49. Right now it seems like BlogEngine is the preferred blogging platform available right now.

    (from what I’ve read) Is that what you are using on your blog?

  50. I’ve been browsing online more than three hours
    today, yet I never found any interesting article like yours.
    It’s pretty worth enough for me. In my view, if all web owners and bloggers made good content as you did, the internet will be a lot more useful than ever before.

  51. Hello, i read your blog occasionally and i own a similar one and i was just
    curious if you get a lot of spam comments? If so how do
    you protect against it, any plugin or anything you can suggest?

    I get so much lately it’s driving me mad so any assistance
    is very much appreciated.

  52. Write more, thats all I have to say. Literally, it seems as though you relied on the video to make your point.

    You obviously know what youre talking about, why waste your intelligence on just posting videos to your blog when you could be
    giving us something informative to read?

  53. Hi there, i read your blog from time to time and i own a
    similar one and i was just wondering if you get a lot of spam comments?
    If so how do you protect against it, any plugin or anything
    you can advise? I get so much lately it’s driving me crazy so any support is
    very much appreciated.

  54. My coder is trying to persuade me to move to .net from PHP.
    I have always disliked the idea because of the
    costs. But he’s tryiong none the less. I’ve been using Movable-type on a number of websites
    for about a year and am nervous about switching
    to another platform. I have heard good things about
    blogengine.net. Is there a way I can import all my wordpress posts into it?

    Any help would be greatly appreciated!

  55. Having read this I believed it was extremely informative. I appreciate
    you taking the time and energy to put this short article together.
    I once again find myself spending a lot of time both reading
    and commenting. But so what, it was still worthwhile!

  56. My spouse and I stumbled over here from a different page and
    thought I may as well check things out. I like what I see so i am just following you.

    Look forward to looking into your web page for a second time.

  57. Wow, marvelous blog layout! How long have you been blogging for?
    you made blogging look easy. The overall look of your web site is
    fantastic, let alone the content!

  58. What’s up to all, the contents existing at this web page are truly remarkable for people knowledge, well, keep up the good
    work fellows.

  59. Heya i am for the primary time here. I found this board and I to find It
    truly helpful & it helped me out a lot. I am hoping to give one thing again and help others like you helped me.

Leave a Reply

Your email address will not be published. Required fields are marked *